/* ul-login — the BodyshopConnect "Log in to your workspace" screens.
   Ported from the Dev Handoff Figma ("Login Screen" page): desktop is a split with the
   photo on the left, tablet puts the photo in a banner on top, mobile lays the form on a
   rounded sheet over a shorter banner. Light-only, painted explicitly so it holds on any
   host ground. */

:root{
  --font:"Inter",ui-sans-serif,system-ui,-apple-system,"Segoe UI",Roboto,sans-serif;

  --brand:#f5461e;        /* primary button, logo orange */
  --brand-hover:#de3b15;
  --brand-ring:rgba(245,70,30,.18);

  --heading:#16191d;      /* screen titles, footer */
  --ink:#131e29;          /* labels, field text, language menu */
  --muted:#556b81;        /* supporting copy, "Remember me", control borders */
  --placeholder:#94a3b8;
  --field-line:#cbd5e1;
  --check-fill:#f5f7f9;
  --link:#000000;         /* underlined text links, button labels */
  --rule:#161616;         /* footer separator */
  --divider:#e5e5e5;
  --row-line:#e2e6ea;     /* picker: lines between rows */
  --row-hover:#f8fafc;    /* picker: row hover / focus fill */
  --white:#ffffff;
  --danger-bg:#fef2f2; --danger-ink:#b91c1c; --danger-line:#fecaca;
  --ok-bg:#f0fdf4; --ok-ink:#166534; --ok-line:#bbf7d0;

  --column:460px;         /* desktop form column */
  --control-h:40px;       /* inputs, buttons, language menu */
}
*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0; font-family:var(--font); color:var(--ink); background:var(--white);
  -webkit-font-smoothing:antialiased; font-size:16px; line-height:1.5;
}
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0 0 0 0);border:0}

/* the photo is 709 of the 1726px Figma frame */
.split{min-height:100vh; display:grid; grid-template-columns:minmax(0,41.08%) 1fr}

/* ---- photo ---- */
.hero{
  background:#12151c 62% 0/cover no-repeat;
  position:relative; overflow:hidden;
}
.hero-fallback{
  position:absolute; inset:0; display:flex; flex-direction:column;
  align-items:flex-start; justify-content:flex-end; gap:.75rem; padding:2.5rem;
  color:#fff;
  background:
    radial-gradient(120% 80% at 20% 10%, rgba(245,70,30,.45), transparent 60%),
    linear-gradient(160deg, #1b2430 0%, #0f1420 55%, #2a1408 100%);
}
.hero-mark{font-weight:700; font-style:italic; font-size:1.7rem; letter-spacing:-.01em}
.hero-mark span{color:var(--brand)}
.hero-tag{margin:0; font-size:1rem; color:rgba(255,255,255,.82); max-width:22rem}

/* ---- right pane ---- */
.pane{
  display:flex; flex-direction:column; min-height:100vh;
  padding:50px 65px 43px; background:var(--white);
  border:1px solid var(--divider);
}
.pane-top{display:flex; justify-content:flex-end}
.lang{display:flex; align-items:center; gap:8px; margin:0}
.lang-go{
  height:var(--control-h); padding:0 12px; font-family:inherit; font-size:14px; color:var(--ink);
  background:var(--white); border:1px solid var(--muted); border-radius:6px; cursor:pointer;
}
.lang select{
  font-family:inherit; font-size:16px; line-height:24px; color:var(--ink);
  height:var(--control-h); min-width:117px;
  border:1px solid var(--muted); border-radius:6px; padding:0 40px 0 16px;
  background:var(--white)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='7' viewBox='0 0 12 7' fill='none' stroke='%23131E29' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 1l5 5 5-5'/%3E%3C/svg%3E")
    no-repeat right 20px center;
  -webkit-appearance:none; appearance:none; cursor:pointer;
}

.pane-body{flex:1; display:flex; align-items:center; justify-content:center; padding:46px 0 32px}
.card{width:100%; max-width:var(--column)}

/* logo: the wordmark, plus the product marks row on the AI variant */
.logo{display:flex; flex-direction:column; align-items:center; gap:17px; margin-bottom:74px}
.logo-word{display:block; width:460px; max-width:none; height:auto}
.logo-marks{display:block; width:248px; height:auto}
.has-ai .logo{gap:18px; margin-bottom:88px}

/* headings */
.title{
  text-align:center; font-size:24px; line-height:32px; font-weight:600;
  color:var(--heading); margin:0 0 46px;
}
.title + .sub{margin-top:-32px}
.sub{text-align:center; color:var(--muted); font-size:16px; line-height:24px; margin:0 0 41px}
.sub + .btn{margin-top:-8px}
.sub strong{font-weight:600; overflow-wrap:anywhere}

.alert{
  background:var(--danger-bg); color:var(--danger-ink); border:1px solid var(--danger-line);
  border-radius:6px; padding:10px 14px; font-size:14px; line-height:20px; margin:0 0 24px;
}
.alert-ok{background:var(--ok-bg); color:var(--ok-ink); border-color:var(--ok-line)}

/* form */
.label{display:block; font-size:14px; line-height:20px; font-weight:500; color:var(--ink); margin:0 0 8px}
.input{
  display:block; width:100%; height:var(--control-h); padding:0 16px;
  font-size:16px; font-family:inherit; color:var(--ink);
  background:var(--white); border:1px solid var(--field-line); border-radius:6px;
  margin:0 0 25px; transition:border-color .15s ease, box-shadow .15s ease;
}
.input::placeholder{color:var(--placeholder); opacity:1}
.input + .btn{margin-top:-1px}
.input:focus{outline:none; border-color:var(--brand); box-shadow:0 0 0 3px var(--brand-ring)}
.input-wrap{position:relative}
.input-wrap .input{padding-right:48px}
.reveal{
  position:absolute; top:calc(var(--control-h) / 2); right:8px; transform:translateY(-50%);
  display:flex; align-items:center; justify-content:center;
  width:32px; height:32px; padding:0; border:0; background:transparent;
  color:var(--muted); cursor:pointer; border-radius:6px;
}
.reveal:hover{color:var(--ink)}

.row{display:flex; align-items:center; justify-content:space-between; gap:16px; margin:30px 0}
.remember{
  display:inline-flex; align-items:center; gap:8px; padding-left:8px;
  font-size:14px; line-height:20px; color:var(--muted); cursor:pointer;
}
.remember input{
  -webkit-appearance:none; appearance:none; flex:none; margin:0;
  width:16px; height:16px; border:1px solid var(--muted); border-radius:4px;
  background:var(--check-fill) no-repeat center/10px 8px; cursor:pointer;
}
.remember input:checked{
  background-color:var(--brand); border-color:var(--brand);
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 8' fill='none' stroke='%23fff' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 4l2.8 2.8L9 1.2'/%3E%3C/svg%3E");
}
.link{color:var(--link); font-size:12px; line-height:16px; font-weight:500; text-decoration:underline; text-underline-offset:2px}
.link:hover{color:var(--brand)}
.link-button{border:0; padding:0; background:none; font-family:inherit; cursor:pointer}

.btn{
  display:flex; align-items:center; justify-content:center;
  width:100%; height:var(--control-h); padding:0 20px;
  font-family:inherit; font-size:16px; line-height:24px; font-weight:500;
  color:var(--link); background:var(--brand); border:0; border-radius:12px;
  text-decoration:none; cursor:pointer; transition:background-color .15s ease;
}
.btn:hover{background:var(--brand-hover)}
.btn:focus-visible{border-radius:12px}

.after{text-align:center; margin:41px 0 0; font-size:12px; line-height:16px; color:var(--muted)}
.btn + .after.resend,.after.resend{margin-top:34px}
.after form{display:inline}
.after.resend .link,.after.different .link{margin-left:6px}

/* picker ("Choose a network", Dev Handoff "Shop selector"): one box, a row per network,
   a row picks at once. The design's row component: white with a muted arrow, hover a pale
   fill with an ink arrow; keyboard focus gets the same fill plus the usual outline, inset. */
.screen-picker .title{margin-bottom:33px}
.networks{border:1px solid var(--field-line); border-radius:8px; overflow:hidden; background:var(--white)}
.networks-for{
  margin:0; padding:10px 16px; border-bottom:1px solid var(--row-line);
  font-size:14px; line-height:20px; color:var(--muted); overflow-wrap:anywhere;
}
.networks-for strong{font-weight:500; color:var(--ink)}
/* a long list scrolls inside its box, on every layout; the "Networks for" line stays put. The
   box is as tall as the window leaves room for: the window's height less everything else on the
   page (--picker-rest, per layout below), and never under three and a half rows, so the row cut
   in half shows there is more. The phone layout keeps the fixed height its frame draws. */
.destinations{
  list-style:none; margin:0; padding:0;
  max-height:max(168px, calc(100vh - var(--picker-rest)));
  max-height:max(168px, calc(100dvh - var(--picker-rest)));
  overflow-y:auto; overscroll-behavior:contain;
}
.destinations li + li{border-top:1px solid var(--row-line)}
.dest{
  display:flex; align-items:center; justify-content:space-between; gap:12px;
  width:100%; min-height:47px; margin:0; padding:11px 16px 12px;
  font-family:inherit; font-size:16px; line-height:24px; font-weight:400; color:var(--ink); text-align:left;
  background:var(--white); border:0; border-radius:0; cursor:pointer; transition:background-color .15s ease;
}
.dest-name{min-width:0; overflow-wrap:anywhere}
.dest-arrow{flex:none; display:block; color:var(--muted); transition:color .15s ease}
.dest:hover,.dest:focus-visible{background:var(--row-hover)}
.dest:hover .dest-arrow,.dest:focus-visible .dest-arrow{color:var(--ink)}
.dest:focus-visible{outline-offset:-2px; border-radius:0}
.after.different{margin-top:33px}
.back{text-align:center; margin:40px 0 0}

/* footer */
.pane-foot{
  width:100%; max-width:var(--column); margin:0 auto;
  display:flex; align-items:center; justify-content:space-between; gap:16px;
  font-size:14px; line-height:20px; color:var(--heading);
}
.pane-foot a{color:var(--heading); text-decoration:none}
.pane-foot a:hover{text-decoration:underline}
.legal{display:inline-flex; gap:10px; align-items:center}
.legal .sep{display:block; width:1px; height:12px; background:var(--rule)}

/* focus */
:focus-visible{outline:2px solid var(--brand); outline-offset:2px; border-radius:6px}
.input:focus-visible{outline:none}

/* the picker frame draws the logo 10px closer to the title than the sign-in screens, on desktop only */
@media (min-width:1024px){
  :root{--picker-rest:572px}
  .screen-picker .logo{margin-bottom:64px}
  .screen-picker.has-ai .logo{margin-bottom:78px}
}

/* ---- short desktop windows (not in the Figma): tighten the vertical padding ---- */
@media (min-width:1024px) and (max-height:800px){
  :root{--picker-rest:481px}
  .pane{padding-top:24px; padding-bottom:24px}
  .pane-body{padding:16px 0}
}

/* ---- tablet: photo banner on top, form below ---- */
@media (max-width:1023px){
  :root{--control-h:48px; --column:414px; --picker-rest:828px}
  .split{display:block; min-height:100vh}
  .hero{height:360px; background-position:center}
  .pane{min-height:calc(100vh - 360px); padding:51px 24px 41px; border:0}
  .pane-top{position:absolute; top:32px; right:33px; z-index:1}
  /* reset and other screens: content centred above a footer pinned to the bottom */
  .pane-body{padding:0 0 24px}
  /* sign-in screens: content and footer move as one centred stack */
  .screen-login .pane{justify-content:center; padding:40px 24px 30px}
  /* the 146px gap from the frame shrinks with the viewport height, down to 40px */
  .screen-login .pane-body{flex:none; padding:0 0 clamp(40px, calc(100vh - 979px), 146px)}
  .logo{margin-bottom:42px}
  .has-ai .logo{margin-bottom:55px}
  .title{color:var(--ink); margin-bottom:26px}
  .title + .sub{margin-top:-12px}
  .row{margin:34px 0}
  .remember{padding-left:12px; gap:12px}
  .sub + .btn{margin-top:0}
  .btn + .after.resend,.after.resend{margin-top:42px}
  .screen-picker .title{margin-bottom:41px}
  .after.different{margin-top:41px}
  .lang select{background-size:13.2px 7.7px; background-position:right 19.4px center}
  .pane-foot{max-width:none; justify-content:center; gap:71px}
  /* the Figma links row sits 2.5px left of centre on tablet and mobile */
  .legal{margin-right:5px}
}

/* ---- landscape phones (not in the Figma): a shorter banner keeps the form in view ---- */
@media (min-width:600px) and (max-width:1023px) and (max-height:600px){
  :root{--picker-rest:628px}
  .hero{height:160px}
  .pane{min-height:calc(100vh - 160px)}
}

/* ---- mobile: shorter banner, the form sits on a rounded sheet ---- */
@media (max-width:599px){
  :root{--banner-h:240px; --sheet-overlap:24px}
  .hero{height:var(--banner-h)}
  .pane,.screen-login .pane{
    position:relative; margin-top:calc(-1 * var(--sheet-overlap)); justify-content:flex-start;
    min-height:calc(100vh - var(--banner-h) + var(--sheet-overlap));
    padding:24px 24px 40px; border-radius:24px 24px 0 0;
  }
  /* the sheet is the positioned box here, so lift the menu back onto the banner */
  .pane-top{top:calc(32px - var(--banner-h) + var(--sheet-overlap)); right:24px}
  /* every screen: content centred on the sheet above a footer pinned to the bottom */
  .pane-body,.screen-login .pane-body{flex:1; padding:0 0 26px}
  .logo{margin-bottom:34px}
  .has-ai .logo{gap:12px; margin-bottom:41px}
  .logo-word{width:309px; max-width:100%; margin:0 auto}
  .logo-marks{width:168px}
  .title{font-size:20px; line-height:28px; margin-bottom:22px}
  .title + .sub{margin-top:-8px}
  .sub{margin-bottom:33px}
  .sub + .btn{margin-top:-1px}
  .input{margin-bottom:21px}
  .row{margin:30px 0}
  .after{margin-top:33px}
  .btn + .after.resend,.after.resend{margin-top:34px}
  .screen-picker .title{margin-bottom:34px}
  /* the frame's five and a half rows */
  .destinations{max-height:264px}
  .after.different{margin-top:31px}
  .pane-foot{flex-direction:column-reverse; gap:8px}
}
@media (prefers-reduced-motion:reduce){*{transition:none!important}}
