/* Buyside waitlist page. Dark only, like the game (a night-shift trading floor). Tokens copied from the game's index.html. */
@font-face { font-family: 'Press Start 2P'; src: url('assets/fonts/PressStart2P-Regular.ttf') format('truetype'); font-display: swap; }
@font-face { font-family: 'VT323'; src: url('assets/fonts/VT323-Regular.ttf') format('truetype'); font-display: swap; }

:root {
  color-scheme: dark;
  --bg: #0c1020; --bg2: #121830; --panel: #161d33; --panel2: #1e2744; --panel3: #263156;
  --line: #2e3a62; --line2: #435489; --shadow: #04060d;
  --text: #ede7d6; --muted: #9ba5c3; --dim: #6c7699;
  --gold: #e3b04b; --gold2: #f7d88c; --goldInk: #2a1c05; --goldDeep: #7d5717;
  --good: #63d497; --bad: #ff7171;
  --f-pixel: 'Press Start 2P', 'Courier New', monospace;
  --f-body: 'VT323', 'Courier New', monospace;
  --gutter: 16px;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0; min-height: 100vh; overflow-x: hidden;
  background-color: var(--bg);
  /* a few pixel stars over a navy sky */
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240' shape-rendering='crispEdges'%3E%3Cg fill='%23f7d88c'%3E%3Crect x='18' y='30' width='3' height='3'/%3E%3Crect x='150' y='12' width='3' height='3'/%3E%3Crect x='204' y='150' width='3' height='3'/%3E%3C/g%3E%3Cg fill='%236c7699'%3E%3Crect x='96' y='66' width='3' height='3'/%3E%3Crect x='60' y='180' width='3' height='3'/%3E%3Crect x='180' y='90' width='3' height='3'/%3E%3Crect x='126' y='210' width='3' height='3'/%3E%3C/g%3E%3C/svg%3E"),
    linear-gradient(#060918, var(--bg) 640px);
  background-repeat: repeat, no-repeat;
  color: var(--text); font-family: var(--f-body); font-size: 22px; line-height: 1.2;
  -webkit-font-smoothing: none; font-smooth: never;
}
img { display: block; max-width: 100%; height: auto; }
a { color: var(--gold2); text-underline-offset: 3px; }
a:hover { color: #fff3cf; }
:focus-visible { outline: 3px solid var(--gold2); outline-offset: 3px; }

.skip { position: absolute; left: var(--gutter); top: -60px; z-index: 10; background: var(--gold); color: var(--goldInk); font-family: var(--f-pixel); font-size: 10px; padding: 10px 12px; text-decoration: none; }
.skip:focus { top: 8px; }

/* header */
.top { display: flex; align-items: center; justify-content: space-between; gap: 12px; max-width: 1180px; margin: 0 auto; padding: max(14px, env(safe-area-inset-top)) var(--gutter) 6px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--gold2); font-family: var(--f-pixel); font-size: 11px; }
.brand img { width: 32px; height: 32px; image-rendering: pixelated; border: 2px solid var(--gold); box-shadow: 2px 2px 0 var(--shadow); }
.play { font-family: var(--f-pixel); font-size: 9px; line-height: 1.5; text-transform: uppercase; color: var(--text); text-decoration: none; padding: 9px 10px; border: 2px solid var(--line2); background: var(--panel2); box-shadow: 0 3px 0 var(--shadow); white-space: nowrap; }
.play:hover { background: var(--panel3); color: var(--text); }

/* hero: title, trailer, form. Phone: stacked in that order; desktop: copy + form on the left, trailer on the right */
.hero { max-width: 1180px; margin: 0 auto; padding: 18px var(--gutter) 28px; display: grid; gap: 22px; grid-template-columns: minmax(0, 1fr); grid-template-areas: 'title' 'media' 'form'; }
.hero-title { grid-area: title; text-align: center; }
.hero-media { grid-area: media; }
.hero-form { grid-area: form; }

.wordmark {
  margin: 8px 0 0; font-family: var(--f-pixel); font-weight: normal; line-height: 1.1;
  font-size: clamp(38px, 11.5vw, 76px); letter-spacing: 0;
  /* banded gold, like the game's title, with a hard pixel drop shadow */
  color: var(--gold);
  background: linear-gradient(#fff3cf 0 22%, var(--gold2) 22% 46%, var(--gold) 46% 72%, #b8832a 72% 100%);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 4px 0 var(--goldDeep)) drop-shadow(4px 4px 0 var(--shadow));
}
.tagline { margin: 14px 0 0; font-family: var(--f-pixel); font-size: clamp(10px, 3vw, 14px); letter-spacing: 2px; text-transform: uppercase; color: var(--text); text-shadow: 2px 2px 0 var(--shadow); }
.hook { margin: 16px auto 0; max-width: 34ch; font-size: clamp(22px, 5.6vw, 28px); color: var(--muted); text-wrap: balance; }

/* trailer frame */
.frame { position: relative; margin: 0 auto; aspect-ratio: 16 / 9; width: 100%; background: var(--shadow); border: 4px solid var(--line2); box-shadow: 0 0 0 4px var(--shadow), 8px 8px 0 4px rgba(4, 6, 13, .7); overflow: hidden; }
.frame video, .frame .fallback { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.frame .fallback { image-rendering: pixelated; }
.frame.portrait { aspect-ratio: 9 / 16; width: min(100%, calc(64vh * 9 / 16)); width: min(100%, calc(64svh * 9 / 16)); }
.frame.square { aspect-ratio: 1 / 1; width: min(100%, 64vh); width: min(100%, 64svh); }
.vidbtn { position: absolute; right: 8px; bottom: 8px; font-family: var(--f-pixel); font-size: 8px; text-transform: uppercase; color: var(--text); background: rgba(12, 16, 32, .85); border: 2px solid var(--line2); padding: 7px 8px; cursor: pointer; }
.vidbtn:hover { border-color: var(--gold); }

/* waitlist card */
.card { background: var(--panel); border: 4px solid var(--line2); box-shadow: 0 0 0 4px var(--shadow), 8px 8px 0 4px rgba(4, 6, 13, .7); padding: 20px 18px 16px; max-width: 560px; margin: 0 auto; }
.card-title { margin: 0; font-family: var(--f-pixel); font-weight: normal; font-size: 14px; line-height: 1.4; color: var(--gold2); }
.card-sub { margin: 8px 0 14px; color: var(--muted); }
.lbl { display: block; font-family: var(--f-pixel); font-size: 9px; letter-spacing: 1px; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.row { display: flex; gap: 10px; }
#email, .field input, .field select { width: 100%; flex: 1 1 auto; min-width: 0; height: 52px; padding: 0 12px; font-family: var(--f-body); font-size: 26px; color: var(--text); background: var(--shadow); border: 2px solid var(--line2); border-radius: 0; box-shadow: inset 3px 3px 0 rgba(0, 0, 0, .5); -webkit-appearance: none; appearance: none; }
#email::placeholder, .field input::placeholder { color: var(--dim); }
#email:focus, .field input:focus, .field select:focus { outline: none; border-color: var(--gold2); box-shadow: inset 3px 3px 0 rgba(0, 0, 0, .5), 0 0 0 2px var(--gold2); }
#email[aria-invalid='true'], .field input[aria-invalid='true'] { border-color: var(--bad); }
.btn-gold { flex: 0 0 auto; height: 52px; padding: 0 18px; font-family: var(--f-pixel); font-size: 13px; text-transform: uppercase; color: var(--goldInk); background: var(--gold); border: 2px solid var(--gold2); border-radius: 0; box-shadow: 0 4px 0 var(--goldDeep), 0 4px 0 2px var(--shadow); cursor: pointer; -webkit-appearance: none; appearance: none; }
.btn-gold:hover:not(:disabled) { background: var(--gold2); }
.btn-gold:active:not(:disabled) { transform: translateY(3px); box-shadow: 0 1px 0 var(--goldDeep), 0 1px 0 2px var(--shadow); }
.btn-gold:focus-visible { outline: 3px solid #fff3cf; outline-offset: 3px; }
.btn-gold:disabled { opacity: .6; cursor: progress; }

.consent { display: flex; align-items: flex-start; gap: 12px; margin-top: 16px; }
.consent label { font-size: 21px; line-height: 1.15; color: var(--text); cursor: pointer; }
#consent { flex: 0 0 auto; width: 24px; height: 24px; margin: 0; -webkit-appearance: none; appearance: none; background: var(--shadow); border: 2px solid var(--line2); border-radius: 0; cursor: pointer; display: grid; place-items: center; }
#consent::after { content: ''; width: 12px; height: 12px; background: var(--gold); box-shadow: 2px 2px 0 var(--goldDeep); transform: scale(0); }
#consent:checked { border-color: var(--gold); }
#consent:checked::after { transform: scale(1); }
#consent:focus-visible { outline: 3px solid var(--gold2); outline-offset: 2px; }
#consent[aria-invalid='true'] { border-color: var(--bad); }

.hp { position: absolute !important; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }

.msg { margin: 12px 0 0; font-size: 21px; }
.msg:empty { margin: 0; }
.msg.err { color: var(--bad); }
.msg.err::before { content: '! '; font-family: var(--f-pixel); font-size: 12px; }
.fine { margin: 6px 0 0; font-size: 18px; color: var(--dim); }

.done { outline: none; }
.done-title { margin: 4px 0 10px; font-family: var(--f-pixel); font-size: 13px; line-height: 1.5; color: var(--good); }
.done p { margin-top: 0; }
.done:focus-visible { outline: 3px solid var(--gold2); outline-offset: 6px; }

.alt { text-align: center; margin: 18px 0 0; color: var(--muted); font-size: 21px; }

/* features */
.features { max-width: 1180px; margin: 0 auto; padding: 22px var(--gutter) 34px; }
.section-title { margin: 0 0 22px; text-align: center; font-family: var(--f-pixel); font-weight: normal; font-size: clamp(12px, 3.4vw, 18px); line-height: 1.5; color: var(--gold2); text-shadow: 3px 3px 0 var(--shadow); }
.tiles { list-style: none; margin: 0; padding: 0; display: grid; gap: 22px; grid-template-columns: minmax(0, 1fr); }
.tile { background: var(--panel); border: 4px solid var(--line); box-shadow: 6px 6px 0 var(--shadow); padding: 10px 10px 16px; }
.tile img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; border: 2px solid var(--shadow); background: var(--shadow); }
.tile h3 { margin: 14px 6px 8px; font-family: var(--f-pixel); font-weight: normal; font-size: 11px; line-height: 1.6; color: var(--gold2); }
.tile p { margin: 0 6px; color: var(--muted); font-size: 21px; }
.again { text-align: center; margin: 30px 0 0; }
.btn-outline { display: inline-block; font-family: var(--f-pixel); font-size: 11px; text-transform: uppercase; text-decoration: none; color: var(--gold2); border: 2px solid var(--gold); background: #2c2512; padding: 14px 16px; box-shadow: 0 4px 0 var(--shadow); }
.btn-outline:hover { background: #3a3016; color: #fff3cf; }

.foot { border-top: 2px solid var(--line); padding: 18px var(--gutter) max(22px, env(safe-area-inset-bottom)); text-align: center; color: var(--dim); font-size: 19px; }
.foot p { margin: 0; }

/* tablet and up */
@media (min-width: 640px) {
  :root { --gutter: 24px; }
  .card { padding: 24px 24px 18px; }
  .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tile:last-child { grid-column: 1 / -1; }
}
@media (min-width: 960px) {
  .hero { padding-top: 34px; column-gap: 40px; row-gap: 26px; align-items: start;
    grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); grid-template-areas: 'title media' 'form media'; }
  .hero-title { text-align: left; }
  .wordmark { font-size: clamp(40px, 5.4vw, 64px); }
  .hook { margin-left: 0; }
  .hero-media { align-self: center; }
  .card { margin: 0; }
  .alt { text-align: left; }
  .tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .tile:last-child { grid-column: auto; }
}

/* the policy page */
.doc { max-width: 760px; margin: 0 auto; padding: 18px var(--gutter) 40px; }
.doc h1 { font-family: var(--f-pixel); font-weight: normal; font-size: clamp(16px, 4.6vw, 24px); line-height: 1.4; color: var(--gold2); margin: 18px 0 6px; text-shadow: 3px 3px 0 var(--shadow); }
.doc h2 { font-family: var(--f-pixel); font-weight: normal; font-size: 11px; line-height: 1.6; color: var(--gold2); margin: 30px 0 8px; }
.doc p, .doc li { color: var(--text); font-size: 22px; }
.doc ul { padding-left: 22px; }
.doc .meta { color: var(--dim); margin-top: 0; }
.doc .todo { color: var(--goldInk); background: var(--gold); padding: 0 6px; }

/* waitlist intake: name, email, optional phone and role */
.field { margin-top: 14px; }
.field:first-child { margin-top: 0; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 14px; }
.field-row .field { margin-top: 0; }
@media (max-width: 460px) { .field-row { grid-template-columns: 1fr; } }
.opt { color: var(--dim); text-transform: none; letter-spacing: 0; font-family: var(--f-body); font-size: 16px; }
.field select { font-size: 22px; cursor: pointer; padding-right: 36px;
  background-image: linear-gradient(45deg, transparent 50%, var(--gold2) 50%), linear-gradient(135deg, var(--gold2) 50%, transparent 50%);
  background-position: calc(100% - 20px) 22px, calc(100% - 14px) 22px; background-size: 6px 6px, 6px 6px; background-repeat: no-repeat; }
.btn-block { display: block; width: 100%; height: 56px; margin-top: 18px; }
