/* The door, the sign-in link, the welcome and the e-mail preferences, in the new look (SKI-1279;
   portal/wide, portal/phone, portalSmallPages/linkWide, welcomeWide, doorMessages,
   preferencesWide). Every value reads a variable of css/tokens.css; nothing moves. */

/* ── the door ──────────────────────────────────────────────
   On the ground (css/frame.css), the card in the window's middle; under it, the proof line and
   the legal links, 36 above the window's foot. 112 above the card is Souki's room (her picture's
   top 31 is empty), and the same below keeps the card in the middle of a 900 window, as drawn. */
.door {
  position: relative;
  display: grid;
  place-items: center;
  padding: 112px 16px;
}
.door-stage {
  position: relative;
  width: min(460px, 100%);
}
.door-stage.wide {
  width: min(560px, 100%);
}

/* Souki happy, 152, sits on the card's top edge at its right: her base is that edge, and the card,
   drawn after her, covers the picture's foot. Her three little ones stand on the same edge at her
   left, their flat bases on it, the nearest the biggest: 31, 21 and 13 wide, 13, 7 and 5 apart
   (portalKit.KIDS). */
.door-souki {
  position: absolute;
  top: -119px;
  right: 32px;
  width: 152px;
  height: 152px;
}
.door-kid {
  position: absolute;
  fill: var(--color-butter-mid);
}
.door-kid.k1 {
  top: -24px;
  right: 176px;
  width: 31px;
  height: 25px;
}
.door-kid.k2 {
  top: -16px;
  right: 214px;
  width: 21px;
  height: 17px;
}
.door-kid.k3 {
  top: -10px;
  right: 240px;
  width: 13px;
  height: 11px;
}

/* The card: paper, corners of 32, 32 inside. The logo, then « Espace revendeurs » as an Overline
   in rose's deep, « Bienvenue » in Black, the lead in Body; the message, the field, the main
   button the card's width, the foot lines. */
.door .panel {
  --door-gap: 24px;
  position: relative;
  padding: 32px;
  border-radius: var(--radius-32);
}
.door .panel .brandline {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--door-gap);
  margin-bottom: 10px;
}
.door .brandline .eyebrow {
  color: var(--color-rose-deep);
  font-size: var(--text-overline);
  font-weight: var(--font-weight-bold);
  line-height: var(--leading-overline);
  letter-spacing: var(--tracking-overline);
  text-transform: uppercase;
}
.door-title {
  margin-bottom: 10px;
  color: var(--color-ink);
  font-size: var(--text-title);
  font-weight: var(--font-weight-black);
  line-height: var(--leading-title);
  letter-spacing: var(--tracking-title);
}
.door-lead {
  margin-bottom: var(--door-gap);
  color: var(--color-ink-2);
  font-size: var(--text-body);
  line-height: var(--leading-body);
}
.door .notice {
  margin-bottom: var(--door-gap);
}
.door label {
  display: block;
  margin-bottom: 8px;
  color: var(--color-ink);
  font-size: var(--text-label);
  font-weight: var(--font-weight-medium);
  line-height: var(--leading-label);
}
.door .input {
  width: 100%;
}
.door .btn.primary {
  width: 100%;
}
.door .input + .btn.primary {
  margin-top: 12px;
}
/* The foot lines: a Small in muted, each after its line icon of 14; « Écrivez à Kawtar »
   underlined in ink. */
.door .foot {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: var(--door-gap);
  color: var(--color-muted);
  font-size: var(--text-small);
  line-height: var(--leading-small);
}
.door .foot > span {
  position: relative;
  padding-left: 22px;
}
.door .foot .ph {
  position: absolute;
  top: 2px;
  left: 0;
  width: 14px;
  height: 14px;
}
.door-contact {
  color: var(--color-ink);
  text-decoration: underline 1px;
  text-underline-offset: 3px;
}

/* Under the card: the proof line as a Small in muted, and the legal links. */
.door .proof {
  position: absolute;
  right: 0;
  bottom: 36px;
  left: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 0 16px;
  color: var(--color-muted);
  font-size: var(--text-small);
  line-height: var(--leading-small);
  text-align: center;
}
.door .proof .legal-links {
  margin: 0;
}

/* ── the welcome: the door's card, 560 wide, with the three points ── */
.welcome-points {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin: 0 0 var(--door-gap);
  padding: 0;
  list-style: none;
}
.welcome-points li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  color: var(--color-ink-2);
  font-size: var(--text-body);
  line-height: var(--leading-body);
}
.welcome-points .ph-duotone {
  flex: none;
  width: 20px;
  height: 20px;
  margin-top: 3px;
  color: var(--color-ink);
}
.welcome-terms {
  margin-bottom: 14px;
  color: var(--color-muted);
  line-height: var(--leading-small);
}
.welcome-terms a {
  color: var(--color-ink-2);
  text-decoration: underline 1px;
  text-underline-offset: 3px;
}

/* ── the e-mail preferences (preferencesWide) ───────────────
   One card, 760 at most, 28 inside, 28 between its parts: each part's name a Name, its hint a
   Small in muted; the three choices as pills 44 high with their radio, the chosen one on rose's
   soft; the alerts under the thin edge, a tick box and its sentence in Body; the note a Small in
   muted; the main button. */
.prefs {
  display: flex;
  flex-direction: column;
  gap: 28px;
  max-width: 760px;
  padding: 28px;
}
.prefs .field {
  margin: 0;
}
.prefs .field > span {
  margin-bottom: 4px;
  color: var(--color-ink);
  font-size: var(--text-name);
  font-weight: var(--font-weight-bold);
  line-height: var(--leading-name);
}
.prefs .field > .small {
  margin-bottom: 14px;
  color: var(--color-muted);
  line-height: var(--leading-small);
}
.prefs .field + .field {
  padding-top: 24px;
  border-top: 1px solid var(--color-edge);
}
.prefs .field + .field > span {
  margin-bottom: 14px;
}
.prefs .roles {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.prefs .rolecard {
  display: flex;
  align-items: center;
  gap: 10px;
  height: var(--spacing-control);
  padding: 0 20px 0 16px;
  border-color: var(--color-edge-pill);
  border-radius: var(--radius-pill);
}
.prefs .rolecard input {
  margin: 0;
}
.prefs .rolecard b {
  color: var(--color-ink-2);
}
.prefs .rolecard:has(input:checked) b {
  color: var(--color-ink);
}
.checkrow {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  color: var(--color-ink-2);
  font-size: var(--text-body);
  line-height: var(--leading-body);
  cursor: pointer;
}
.checkrow input {
  margin-top: 2px;
}
.prefs > .tiny {
  color: var(--color-muted);
  font-size: var(--text-small);
  line-height: var(--leading-small);
}

/* ── a short window: the proof line and the legal links follow the card ── */
@media (max-height: 720px) {
  .door {
    grid-template-rows: 1fr auto;
    padding-bottom: 0;
  }
  .door .proof {
    position: static;
    padding: 32px 16px 36px;
  }
}

/* ── a phone (portal/phone): the card 116 from the top, 28 and 24 inside, 22 between its parts;
   Souki at 132 and her little ones 27, 18 and 11 wide; the proof line and the links under the
   card. The clouds placed as the phone's board places them. ── */
@media (max-width: 600px) {
  .door {
    grid-template-rows: auto auto;
    align-content: start;
    padding: 116px 20px 36px;
  }
  .door.ground {
    background-image:
      radial-gradient(
        ellipse 80% 34% at 0% 12% in oklab,
        color-mix(in oklab, var(--color-rose-mid) 30%, transparent) 0%,
        transparent 70%
      ),
      radial-gradient(
        ellipse 80% 36% at 100% 92% in oklab,
        color-mix(in oklab, var(--color-butter-mid) 26%, transparent) 0%,
        transparent 70%
      ),
      radial-gradient(
        ellipse 60% 26% at 100% 0% in oklab,
        color-mix(in oklab, var(--color-sky-mid) 20%, transparent) 0%,
        transparent 70%
      );
  }
  .door .panel {
    --door-gap: 22px;
    padding: 28px 24px;
  }
  .door .proof {
    position: static;
    padding: 24px 8px 0;
  }
  .door-souki {
    top: -103px;
    right: 22px;
    width: 132px;
    height: 132px;
  }
  .door-kid.k1 {
    top: -21px;
    right: 147px;
    width: 27px;
    height: 22px;
  }
  .door-kid.k2 {
    top: -14px;
    right: 180px;
    width: 18px;
    height: 15px;
  }
  .door-kid.k3 {
    top: -8px;
    right: 203px;
    width: 11px;
    height: 9px;
  }
}
