/* The prospect's menu page. Tokens follow the RaceProX admin's dark theme
   (apps/admin/src/styles/globals.css): near-black surfaces, cyan primary,
   Anybody Black Italic for display type. */
@font-face {
    font-family: "Anybody";
    src: url("/fonts/Anybody-BlackItalic.ttf") format("truetype");
    font-weight: 900;
    font-style: italic;
    font-display: swap;
}
:root {
    --bg: #0a0a0f; --surface: #141419; --raised: #1e1e26; --border: #27272a; --border-strong: #3a3a42;
    --text: #f5f5f5; --muted: #a1a1aa; --subtle: #71717a;
    --primary: #00f9ff; --primary-ink: #001a1b; --primary-muted: rgba(0, 249, 255, 0.12);
    --must: #4ade80; --nice: #00f9ff; --more: #a78bfa; --no: #8b8b96; --danger: #f87171;
    --radius: 12px; --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
    color-scheme: dark;
}
* { box-sizing: border-box; }
html { scroll-padding-top: 88px; }
body { margin: 0; min-height: 100vh; font: 16px/1.55 Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif; color: var(--text); background: var(--bg); -webkit-font-smoothing: antialiased; }
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 16px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
[hidden] { display: none !important; }

/* Header and progress */
.top { position: sticky; top: 0; z-index: 5; background: rgba(10, 10, 15, 0.82); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--border); }
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 60px; }
.brand { font: italic 900 22px/1 "Anybody", Inter, sans-serif; letter-spacing: 0.01em; }
.brand span { color: var(--primary); }
.for { color: var(--muted); font-size: 13px; text-align: right; }
.for strong { color: var(--text); font-weight: 600; }
.progress { height: 2px; background: transparent; }
.progress-bar { height: 100%; background: linear-gradient(90deg, var(--primary), #7cf7c8); transform: scaleX(0); transform-origin: left; transition: transform 0.6s var(--ease); box-shadow: 0 0 12px rgba(0, 249, 255, 0.6); }

/* Layout */
.layout { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 48px; padding-top: 40px; padding-bottom: 140px; }
main.wrap { padding-top: 56px; padding-bottom: 96px; }

/* Step rail */
.steps { position: sticky; top: 100px; align-self: start; max-height: calc(100vh - 200px); overflow-y: auto; }
.steps ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.steps a { display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; gap: 8px; align-items: baseline; padding: 8px 10px; border-radius: 8px; color: var(--muted); text-decoration: none; font-size: 14px; line-height: 1.3; transition: color 0.2s, background 0.2s; }
.steps a:hover { color: var(--text); background: var(--surface); }
.steps .n { font-size: 11px; font-weight: 700; letter-spacing: 0.06em; color: var(--subtle); }
.steps .c { font-size: 11px; color: var(--subtle); font-variant-numeric: tabular-nums; }
.steps .c.is-complete { color: var(--must); }
.steps a.is-done .n { color: var(--primary); }
.steps a.is-current { color: var(--text); background: var(--surface); box-shadow: inset 2px 0 0 var(--primary); }
.steps a.is-current .n { color: var(--primary); }

/* Type */
h1 { font: italic 900 clamp(40px, 7vw, 76px)/0.98 "Anybody", Inter, sans-serif; letter-spacing: -0.01em; margin: 0 0 20px; text-transform: uppercase; }
h1 em { font-style: inherit; color: var(--primary); }
h2 { font: italic 900 clamp(28px, 4vw, 40px)/1.05 "Anybody", Inter, sans-serif; margin: 0 0 12px; text-transform: uppercase; }
h1:focus, h2:focus { outline: none; }
h3 { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.12em; color: var(--subtle); margin: 36px 0 12px; }
h4 { margin: 0 0 4px; font-size: 17px; font-weight: 600; }
.eyebrow { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.16em; color: var(--primary); margin: 0 0 14px; }
.lead { font-size: 19px; color: var(--muted); max-width: 620px; margin: 0 0 32px; }
.intro { color: var(--muted); max-width: 720px; margin: 0 0 28px; font-size: 17px; }
.desc { color: var(--muted); margin: 0; font-size: 15px; }
.fine { color: var(--subtle); font-size: 14px; margin-top: 24px; }

/* Landing (bare domain) */
main.landing { max-width: 820px; }
.open { display: flex; gap: 10px; margin: 8px 0 0; }
.open input { flex: 1; min-width: 0; font: inherit; color: var(--text); background: rgba(255, 255, 255, 0.04); border: 1px solid var(--border-strong); border-radius: 999px; padding: 13px 20px; }
.open input::placeholder { color: var(--subtle); }
.open input:focus { outline: none; border-color: var(--primary); background: rgba(0, 249, 255, 0.04); }
.form-error { color: var(--danger); margin: 14px 0 0; font-weight: 600; }

/* Welcome */
.hero { position: relative; overflow: hidden; border: 1px solid var(--border); border-radius: 20px; padding: clamp(28px, 6vw, 72px); background:
    radial-gradient(900px 420px at 85% -10%, rgba(0, 249, 255, 0.20), transparent 60%),
    radial-gradient(600px 400px at 0% 120%, rgba(167, 139, 250, 0.14), transparent 60%),
    var(--surface); }
.hero::before { content: ""; position: absolute; inset: 0; background-image: linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px); background-size: 44px 44px; mask-image: radial-gradient(ellipse at 80% 0%, #000 0%, transparent 70%); -webkit-mask-image: radial-gradient(ellipse at 80% 0%, #000 0%, transparent 70%); pointer-events: none; }
.hero::after { content: ""; position: absolute; top: -40%; right: -10%; width: 46%; height: 180%; background: linear-gradient(100deg, transparent 0 46%, rgba(0, 249, 255, 0.10) 46% 50%, transparent 50% 56%, rgba(0, 249, 255, 0.06) 56% 58%, transparent 58%); transform: skewX(-18deg); animation: sweep 9s var(--ease) infinite alternate; pointer-events: none; }
.hero > * { position: relative; z-index: 1; }
.how { list-style: none; padding: 0; margin: 20px 0 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.how li { border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); padding: 20px; }
.how h3 { margin: 10px 0 6px; color: var(--text); font-size: 15px; letter-spacing: 0.02em; text-transform: none; }
.how p { margin: 0; color: var(--muted); font-size: 14px; }
.how-n { font: italic 900 22px/1 "Anybody", Inter, sans-serif; color: var(--primary); }

/* Buttons */
button, .cta { font: inherit; font-weight: 700; color: var(--primary-ink); background: var(--primary); border: 0; border-radius: 999px; padding: 12px 26px; cursor: pointer; white-space: nowrap; text-decoration: none; display: inline-block; transition: transform 0.2s var(--ease), box-shadow 0.2s, background 0.2s; }
button:hover:not(:disabled), .cta:hover { transform: translateY(-1px); box-shadow: 0 8px 28px rgba(0, 249, 255, 0.35); }
button:active:not(:disabled), .cta:active { transform: translateY(0); }
button:disabled { opacity: 0.5; cursor: default; }
button.ghost { background: transparent; color: var(--text); box-shadow: inset 0 0 0 1px var(--border-strong); }
button.ghost:hover:not(:disabled) { box-shadow: inset 0 0 0 1px var(--text); }
.cta { font-size: 17px; padding: 14px 34px; }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 3px; }

/* Items */
.item { border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); padding: 20px 22px; margin-bottom: 12px; transition: border-color 0.25s, background 0.25s, box-shadow 0.25s; }
.item:hover { border-color: var(--border-strong); }
.item:focus-within { border-color: var(--border-strong); background: var(--raised); }
.item[data-choice="must"] { box-shadow: inset 3px 0 0 var(--must); }
.item[data-choice="nice"] { box-shadow: inset 3px 0 0 var(--nice); }
.item[data-choice="more"] { box-shadow: inset 3px 0 0 var(--more); }
.item[data-choice="no"] { box-shadow: inset 3px 0 0 var(--no); }
.item[data-choice="no"] .item-text { opacity: 0.55; }
.item-text { margin-bottom: 14px; }
.question { font-weight: 600; font-size: 17px; margin: 0 0 8px; }
.item-question .desc { margin-bottom: 10px; }
.chips { border: 0; padding: 0; margin: 0 0 10px; display: flex; flex-wrap: wrap; gap: 8px; }
.chip { position: relative; cursor: pointer; }
.chip input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.chip span { display: inline-block; padding: 8px 16px; border-radius: 999px; border: 1px solid var(--border-strong); color: var(--muted); font-size: 14px; font-weight: 600; transition: color 0.18s, background 0.18s, border-color 0.18s, transform 0.18s var(--ease); }
.chip:hover span { color: var(--text); border-color: var(--subtle); }
.chip input:focus-visible + span { outline: 2px solid var(--primary); outline-offset: 2px; }
.chip input:checked + span { color: #0a0a0f; transform: scale(1.03); }
.chip-must input:checked + span { background: var(--must); border-color: var(--must); }
.chip-nice input:checked + span { background: var(--nice); border-color: var(--nice); }
.chip-more input:checked + span { background: var(--more); border-color: var(--more); }
.chip-no input:checked + span { background: var(--no); border-color: var(--no); }
.chip input:disabled + span { cursor: default; opacity: 0.7; }
textarea { width: 100%; font: inherit; font-size: 15px; color: var(--text); background: rgba(255, 255, 255, 0.03); border: 1px solid var(--border); border-radius: 8px; padding: 10px 12px; resize: vertical; min-height: 42px; transition: border-color 0.2s, background 0.2s; }
textarea::placeholder { color: var(--subtle); }
textarea:focus { outline: none; border-color: var(--primary); background: rgba(0, 249, 255, 0.04); }
textarea:disabled { color: var(--muted); }

/* Review */
.tiles { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; margin: 24px 0 8px; }
.tile { border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); padding: 18px 16px; }
.tile strong { display: block; font: italic 900 38px/1 "Anybody", Inter, sans-serif; font-variant-numeric: tabular-nums; }
.tile span { color: var(--muted); font-size: 13px; }
.tile-must strong { color: var(--must); }
.tile-nice strong { color: var(--nice); }
.tile-more strong { color: var(--more); }
.tile-no strong { color: var(--no); }
.musts ul { margin: 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 8px; }
.musts li { border: 1px solid rgba(74, 222, 128, 0.4); color: var(--must); border-radius: 999px; padding: 5px 12px; font-size: 13px; }
.next { color: var(--muted); padding-left: 20px; margin: 0 0 32px; }
.next li { margin-bottom: 8px; }
.banner { background: rgba(251, 191, 36, 0.12); color: #fbbf24; border: 1px solid rgba(251, 191, 36, 0.3); border-radius: 10px; padding: 12px 16px; font-weight: 600; margin: 0 0 24px; }

/* Bottom bar */
.bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 5; background: rgba(10, 10, 15, 0.88); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-top: 1px solid var(--border); }
.bar .wrap { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 16px; padding-top: 12px; padding-bottom: 12px; min-height: 68px; }
.bar #back { justify-self: start; }
.bar #next { justify-self: end; grid-column: 3; }
#save-status { grid-column: 2; font-size: 13px; color: var(--subtle); text-align: center; }
#save-status[data-tone="ok"] { color: var(--must); }
#save-status[data-tone="error"] { color: var(--danger); }

/* One step at a time, once the script is running */
.js .step:not(.is-active) { display: none; }
.step { margin-bottom: 72px; }
.js .step { margin-bottom: 0; }
.js .step.is-active { animation: step-in 0.5s var(--ease) both; }
.js .step.is-active.from-left { animation-name: step-back; }
.js .step.is-active .item, .js .step.is-active .how li, .js .step.is-active .tile { animation: rise 0.55s var(--ease) both; }
.js .step.is-active .item:nth-child(n + 1), .js .step.is-active .how li:nth-child(1), .js .step.is-active .tile:nth-child(1) { animation-delay: 0.04s; }
.js .step.is-active .item:nth-child(n + 5), .js .step.is-active .how li:nth-child(2), .js .step.is-active .tile:nth-child(2) { animation-delay: 0.09s; }
.js .step.is-active .item:nth-child(n + 6), .js .step.is-active .how li:nth-child(3), .js .step.is-active .tile:nth-child(3) { animation-delay: 0.14s; }
.js .step.is-active .item:nth-child(n + 7), .js .step.is-active .tile:nth-child(4) { animation-delay: 0.19s; }
.js .step.is-active .item:nth-child(n + 8), .js .step.is-active .tile:nth-child(5) { animation-delay: 0.24s; }
.js .step.is-active .item:nth-child(n + 9) { animation-delay: 0.28s; }
.step-review.is-sent .cta { background: var(--must); }
@keyframes step-in { from { opacity: 0; transform: translateX(24px); } to { opacity: 1; transform: none; } }
@keyframes step-back { from { opacity: 0; transform: translateX(-24px); } to { opacity: 1; transform: none; } }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes sweep { from { transform: skewX(-18deg) translateX(-6%); opacity: 0.7; } to { transform: skewX(-18deg) translateX(10%); opacity: 1; } }

@media (max-width: 900px) {
    .layout { grid-template-columns: minmax(0, 1fr); gap: 0; padding-top: 24px; }
    .steps { display: none; }
    .how { grid-template-columns: minmax(0, 1fr); }
    .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .for { font-size: 12px; }
    .bar .wrap { grid-template-columns: auto 1fr auto; }
    #save-status { grid-column: 2; }
    .bar #next { grid-column: 3; }
    .chip span { padding: 8px 13px; }
    .open { flex-direction: column; }
    .open button { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; }
}
@media print {
    :root { --bg: #fff; --surface: #fff; --raised: #fff; --text: #111; --muted: #444; --subtle: #666; --border: #ccc; --border-strong: #999; }
    .top, .bar, .steps, .hero::before, .hero::after { display: none; }
    .layout { display: block; padding: 0; }
    .js .step:not(.is-active) { display: block; }
    .step { margin-bottom: 32px; }
    .item { break-inside: avoid; }
    .chip input:checked + span { color: #000; }
}
