/* The refreshed public pages: homepage (static/index-next), sign-in, and the pages that follow.
   Outside the legacy bundles on purpose; page-specific styles stay in each view. */

/* Manrope, self-hosted: the variable font from Fontsource 5.3.0 (@fontsource-variable/manrope),
   Latin and Latin Extended only. Licence: public/fonts/manrope/OFL.txt. */
@font-face {
    font-family: Manrope;
    font-style: normal;
    font-display: swap;
    font-weight: 200 800;
    src: url("../fonts/manrope/manrope-latin-wght-normal.woff2") format("woff2-variations"),
         url("../fonts/manrope/manrope-latin-wght-normal.woff2") format("woff2");
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
    font-family: Manrope;
    font-style: normal;
    font-display: swap;
    font-weight: 200 800;
    src: url("../fonts/manrope/manrope-latin-ext-wght-normal.woff2") format("woff2-variations"),
         url("../fonts/manrope/manrope-latin-ext-wght-normal.woff2") format("woff2");
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
    --ground: #f4f6f9;
    --surface: #ffffff;
    --ink: #1b2540;
    --ink-2: #4a5578;
    --muted: #5f6987;
    --line: #e6e9f0;
    --line-soft: #eef1f6;
    --navy-hover: #2c3a62;
    --line-strong: #c9cfdd;
    --chrome: #eceef2;   /* the browser frame's title bar */

    --setup-tint: #e9ebf1;   --setup-text: #1b2540;   --setup-dot: #64708f;
    --forms-tint: #e5ebfb;   --forms-text: #2f4fa8;   --forms-dot: #5b7bd5;
    --obs-tint: #e3f1ea;     --obs-text: #2d6f53;     --obs-dot: #5fa58a;
    --eval-tint: #efe8fa;    --eval-text: #5c3f99;    --eval-dot: #9a7bd0;
    --results-tint: #fbe9e2; --results-text: #a24d2c; --results-dot: #e0896b;

    --radius-lg: 24px;
    --radius-md: 16px;
    --radius-sm: 12px;
    --shadow-panel: 0 1px 2px rgba(27, 37, 64, .06), 0 24px 48px -24px rgba(27, 37, 64, .18);
    --shadow-pill: 0 1px 2px rgba(27, 37, 64, .08);
    --gutter: clamp(16px, 5vw, 72px);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scrollbar-color: #c3c9d8 var(--ground); }
body {
    margin: 0; background: var(--ground); color: var(--ink);
    font: 16px/1.6 Manrope, system-ui, sans-serif; font-variant-numeric: tabular-nums;
    -webkit-font-smoothing: antialiased; caret-color: var(--forms-dot);
}
::selection { background: var(--forms-tint); color: var(--ink); }
a { color: inherit; text-underline-offset: .22em; text-decoration-thickness: 1px; }
:focus-visible { outline: 3px solid var(--forms-dot); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3 { letter-spacing: -.025em; text-wrap: balance; }
.sample { font-size: 14px; color: var(--muted); }

/* ---------- Nav ---------- */
.nav { display: flex; justify-content: space-between; align-items: center; padding: 24px var(--gutter); }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 800; font-size: 20px; letter-spacing: .05em; }
.brand svg { width: 24px; height: 24px; }
.links { display: flex; align-items: center; gap: 32px; list-style: none; margin: 0; padding: 0; }
.links a { text-decoration: none; font-weight: 500; color: var(--ink-2); }
.links a:hover { color: var(--ink); }
.links .signin { color: var(--ink); font-weight: 700; }

.btn { display: inline-block; background: var(--ink); color: #fff; text-decoration: none; font-weight: 700; font-size: 16px; padding: 15px 24px; border-radius: var(--radius-sm); transition: background .15s, transform .15s; }
.btn:hover { background: var(--navy-hover); transform: translateY(-1px); }
.btn-light { background: #fff; color: var(--ink); }
.btn-light:hover { background: var(--forms-tint); }

/* ---------- Footer ---------- */
footer { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding: 36px var(--gutter) 40px; font-size: 14px; color: var(--muted); }
footer nav { display: flex; gap: 24px; }
footer a { text-decoration: none; }
footer a:hover { color: var(--ink); text-decoration: underline; }

@media (max-width: 640px) {
    .links li:not(:last-child) { display: none; }
}
@media (prefers-reduced-motion: reduce) { .btn { transition: none; } html { scroll-behavior: auto; } }

/* ---------- Sign-in and the other account pages ---------- */
.panel { background: var(--surface); border-radius: var(--radius-lg); box-shadow: var(--shadow-panel); }
.auth { display: grid; justify-items: center; padding: clamp(24px, 6vw, 72px) var(--gutter) clamp(48px, 8vw, 112px); }
.auth-card { width: min(100%, 420px); padding: clamp(28px, 4vw, 40px); }
.auth-card h1 { margin: 0 0 24px; font-size: 32px; line-height: 1.1; font-weight: 700; }
.auth-card form { display: grid; gap: 18px; }
.field { display: grid; gap: 6px; }
.field span { font-size: 14px; font-weight: 600; color: var(--ink-2); }
.field input { font: inherit; color: var(--ink); background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--radius-sm); padding: 12px 14px; transition: border-color .15s, box-shadow .15s; }
.field input:hover { border-color: var(--muted); }
.field input:focus { outline: none; border-color: var(--forms-dot); box-shadow: 0 0 0 3px var(--forms-tint); }
.field input[aria-invalid=true] { border-color: var(--results-dot); }
.btn-full { display: block; width: 100%; margin-top: 6px; border: 0; font-family: inherit; cursor: pointer; }
.auth-alt { margin: 22px 0 0; text-align: center; font-size: 15px; }
.auth-alt a { color: var(--forms-text); font-weight: 600; text-decoration: none; }
.auth-alt a:hover { text-decoration: underline; }
.notice { margin: 0 0 20px; padding: 12px 16px; border-radius: var(--radius-sm); font-size: 15px; font-weight: 500; }
.notice p { margin: 0; }
.notice p + p { margin-top: 4px; }
.notice-ok { background: var(--obs-tint); color: var(--obs-text); }
.notice-error { background: var(--results-tint); color: var(--results-text); }
.links a[aria-current=page] { color: var(--ink); text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: 2px; }
.page-auth { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }
.page-auth .auth { flex: 1; align-content: center; }
.auth-card h1 + .auth-intro { margin-top: -12px; }
.auth-intro { margin: 0 0 22px; color: var(--ink-2); font-size: 16px; }
.auth-intro strong { color: var(--ink); }
.field input:disabled { background: var(--ground); color: var(--muted); border-color: var(--line); cursor: not-allowed; }

/* ---------- Forms beyond sign-in (support) ---------- */
.field select, .field textarea { font: inherit; color: var(--ink); background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--radius-sm); padding: 12px 14px; transition: border-color .15s, box-shadow .15s; }
.field textarea { resize: vertical; min-height: 128px; }
.field select { appearance: none; padding-right: 40px; background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%235f6987' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 16px center / 12px; }
.field select:hover, .field textarea:hover { border-color: var(--muted); }
.field select:focus, .field textarea:focus { outline: none; border-color: var(--forms-dot); box-shadow: 0 0 0 3px var(--forms-tint); }
.choice { border: 0; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 24px; }
.choice legend { width: 100%; padding: 0; margin-bottom: 8px; font-size: 14px; font-weight: 600; color: var(--ink-2); }
.choice label { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; }
.choice input { width: 18px; height: 18px; margin: 0; accent-color: var(--ink); }
.stack-form { display: grid; gap: 20px; }
.stack-form:has(#email:checked) .when-phone, .stack-form:has(#phone:checked) .when-email { display: none; }

.section-page { padding: clamp(24px, 5vw, 64px) var(--gutter) clamp(64px, 8vw, 112px); }
.section-page h1 { margin: 0 0 14px; font-size: clamp(36px, 4vw, 52px); line-height: 1.08; font-weight: 700; }
.section-page .intro { margin: 0; font-size: 18px; color: var(--ink-2); max-width: 32em; }
/* Stacked, so L4's "fill out the form below" stays true */
.support { display: grid; gap: 28px; width: min(100%, 640px + 2 * var(--gutter)); margin: 0 auto; }
.support-card { padding: clamp(24px, 4vw, 40px); }
.auth-alt-tight { margin-top: 10px; }
/* Demo sign-up (demo-site only) */
.auth-card-wide { width: min(100%, 560px); }
.field-group { border: 0; margin: 0; padding: 18px 0 0; border-top: 1px solid var(--line); display: grid; gap: 14px; }
.field-group legend { float: left; width: 100%; padding: 0; margin-bottom: 2px; font-size: 16px; font-weight: 700; color: var(--ink); }
.field-group legend + * { clear: left; }
.field-help { margin: -6px 0 0; font-size: 14px; color: var(--muted); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 480px) { .field-row { grid-template-columns: 1fr; } }
