/* Sign-in, sign-up, invite, password and code screens (/login) in the site's design code, v1.
   Loads only on cabinet/login.html, after cabinet.css and verify.css. Two themes on html[data-theme];
   the ds.css names the cabinet uses are mapped onto the landing palette. The cabinet itself is not affected. */
html[data-theme="dark"], html:not([data-theme]) {
  --bg: #0A0B0D; --bg-2: #0E0F12; --surface: #131417; --surface-2: #1A1C20; --surface-3: #24272D; --float: #1C1E23;
  --text: #F2F0EB; --muted: #B1AFA9; --dim: #8C8A85; --fg-rgb: 242 240 235;
  --line: rgba(242, 240, 235, .09); --line-2: rgba(242, 240, 235, .16); --line-3: rgba(242, 240, 235, .28);
  --accent-2: #FF7A4D; --accent-soft: rgba(255, 90, 38, .14);
  --inv: #F2F0EB; --on-inv: #0B0C0E;
  --sh-float: 0 1px 0 rgba(255, 255, 255, .05) inset, 0 20px 44px -22px rgba(0, 0, 0, .8);
  color-scheme: dark;
}
html[data-theme="light"] {
  --bg: #FFFFFF; --bg-2: #FFFFFF; --surface: #F4F3F0; --surface-2: #ECEAE6; --surface-3: #E2E0DB; --float: #FFFFFF;
  --text: #0A0B0D; --muted: #53524D; --dim: #6B6964; --fg-rgb: 10 11 13;
  --line: rgba(10, 11, 13, .08); --line-2: rgba(10, 11, 13, .15); --line-3: rgba(10, 11, 13, .26);
  --accent-2: #BD3D0C; --accent-soft: rgba(255, 90, 38, .12);
  --ok: #09713F; --ok-soft: rgba(11, 127, 74, .1); --wait: #8F5200; --wait-soft: rgba(196, 122, 0, .12);
  --err: #C02626; --err-soft: rgba(207, 48, 48, .1); --info: #105AB0; --info-soft: rgba(22, 104, 199, .1);
  --inv: #0A0B0D; --on-inv: #F2F0EB;
  --sh-float: 0 0 0 1px rgba(10, 11, 13, .04), 0 14px 34px -16px rgba(38, 32, 22, .2);
  --shadow-1: 0 0 0 1px rgba(10, 11, 13, .04), 0 10px 30px -18px rgba(38, 32, 22, .25);
  --shadow-2: 0 0 0 1px rgba(10, 11, 13, .04), 0 30px 60px -30px rgba(38, 32, 22, .3);
  color-scheme: light;
}
:root { --f-display: "Onest", system-ui, -apple-system, "Segoe UI", sans-serif; --r-card: clamp(26px, 2.6vw, 34px); }
html.theme-anim *, html.theme-anim *::before, html.theme-anim *::after { transition: background-color .35s ease, color .35s ease, border-color .35s ease, box-shadow .35s ease, fill .35s ease, stroke .35s ease !important; }
body { background: var(--bg); color: var(--text); font-family: var(--f-ui); }
body :focus-visible { outline: 2px solid var(--accent-2); outline-offset: 3px; }

/* Theme button, top right */
.lg-theme { position: fixed; top: 16px; right: 16px; z-index: 30; display: grid; place-items: center; width: 46px; height: 46px; border: 0; border-radius: 50%; background: var(--surface); color: var(--text); cursor: pointer; transition: background-color .2s; }
.lg-theme:hover { background: var(--surface-2); }
.lg-theme svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
html[data-theme="light"] .lg-sun, html:not([data-theme="light"]) .lg-moon { display: none; }

/* Page and card: a flat field on the page, no glow */
.auth, .invite { background: var(--bg); }
.card, .invite-card { background: var(--surface); border: 0; border-radius: var(--r-card); box-shadow: none; }
.card { width: min(440px, 100%); padding: clamp(26px, 3vw, 36px) clamp(22px, 2.6vw, 32px); }
.brand { font: 600 19px/1 var(--f-display); letter-spacing: -.045em; }
.brand-mark { border-radius: 8px; }

/* Tabs: a segmented pill */
.tabs { gap: 2px; padding: 4px; border: 0; border-radius: 999px; background: var(--float); box-shadow: var(--sh-float); }
.tabs button { min-height: 40px; border-radius: 999px; font-weight: 500; }
.tabs button:hover { background: rgb(var(--fg-rgb) / .05); }
.tabs button.on { background: var(--inv); color: var(--on-inv); }

/* Fields */
.field { color: var(--muted); }
.field input, .field textarea, .field select { min-height: 50px; border: 1px solid transparent; border-radius: 14px; background-color: var(--float); box-shadow: var(--sh-float); color: var(--text); font-size: 15.5px; }
.field input:focus, .field textarea:focus, .field select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); outline: 0; }
.check input { accent-color: var(--accent); }

/* Buttons: one pill shape */
.btn, .ghost { border-radius: 999px; font-weight: 600; }
.btn { color: #0A0B0D; }
.btn:hover { background: #FF7A4D; border-color: #FF7A4D; }
.auth .card .row .btn, .auth .card .btn, .invite-card .btn { min-height: 52px; font-size: 15.5px; }
.link-btn, .invite-switch { color: var(--muted); }
.forgot-row .link-btn { color: var(--accent-2); text-decoration: none; font-weight: 600; }
.reg-perk { border-radius: 16px; background: var(--float); box-shadow: var(--sh-float); }
.join-hint { border-radius: 16px; }
.tg-btn { width: 100%; min-height: 52px; border: 0; border-radius: 999px; background: #2AABEE; color: #fff; }
.tg-btn:hover { background: #1F98D8; border: 0; }
.tg-btn svg { fill: #fff; }
.tg-login .or::before, .tg-login .or::after { background: var(--line-2); }


/* Invite: the copy on the page, the form on a card */
.invite-kicker { display: inline-flex; align-items: center; gap: 9px; width: fit-content; padding: 7px 14px 7px 11px; border-radius: 999px; background: var(--surface); color: var(--muted); font-size: 13.5px; }
.invite-kicker::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.invite-copy h1 { font: 600 clamp(38px, 5vw, 72px)/1 var(--f-display); letter-spacing: -.05em; }
.invite-code { border: 0; border-radius: 999px; background: var(--surface); }
.invite-perks { border-top-color: var(--line-2); }
.invite-perks article { border-bottom-color: var(--line-2); }

/* Code and password screens (verify.css) */
body.ap-login .otp-card .otp-title { font-family: var(--f-display); letter-spacing: -.04em; }
body.ap-login .otp-cell { border-radius: 16px; }
html[data-theme="light"] body.ap-login .lock-body { fill: var(--surface-3); stroke: var(--line-2); }

@media (max-width: 560px) {
  .lg-theme { top: 10px; right: 10px; width: 42px; height: 42px; }
  .auth { padding: 64px 12px 24px; place-items: start center; }
}
