/* The Great Wildcat Escape styles. One deliberate look: a lockdown at night.
   Layout: phone-first dossier for students, wide workspace for admin, giant type for the commons projector. */
:root {
  /* Black base with Eagan Wildcats accents: royal blue, kelly green, silver */
  --green: #5ACD24;          /* kelly green: primary actions, earned pieces */
  --teal: #C9D0DC;           /* silver: labels, focus */
  --alarm: #4F7BFF;          /* royal blue (bright for black): countdown, stamps */
  --royal: #1E4BD2;          /* royal blue: The Final Door card, stripes */
  --bg: #0B0C0F;
  --surface: #15171C;
  --surface-2: #1F232B;
  --ink: #F4F6FA;
  --ink-2: #A7AFBD;
  --line: #2C313B;
  --good: #6BD84A; --good-bg: #13301A;
  --warn: #FFC857; --warn-bg: #352A0E;
  --bad: #FF7A70; --bad-bg: #3B1518;
  --info: #8FB0FF; --info-bg: #14234D;
  --on-accent: #08200C;
  --shadow: 0 1px 2px rgba(0,0,0,.4), 0 10px 30px rgba(0,0,0,.35);
  --f-display: "Big Shoulders Stencil Display", "Impact", "Arial Narrow", sans-serif;
  --f-body: "Atkinson Hyperlegible", "Segoe UI", system-ui, -apple-system, sans-serif;
  --f-mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  color-scheme: dark;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { background: var(--bg); color: var(--ink); font-family: var(--f-body); font-size: 16px; line-height: 1.5; margin: 0; }
h1, h2, h3 { font-family: var(--f-display); line-height: 1.1; text-wrap: balance; margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
.page { padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
:focus-visible { outline: 3px solid var(--teal); outline-offset: 2px; }
.mono { font-family: var(--f-mono); }
.eyebrow { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--teal); }
.muted { color: var(--ink-2); }
.tabnum { font-variant-numeric: tabular-nums; }

/* buttons + fields */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid transparent; border-radius: 12px; padding: 12px 18px; font-weight: 700; cursor: pointer; background: var(--green); color: var(--on-accent); text-decoration: none; }
.btn:hover { filter: brightness(1.06); }
.btn:disabled { opacity: .55; cursor: not-allowed; filter: none; }
.btn.secondary { background: var(--surface); color: var(--ink); border-color: var(--line); }
.btn.ghost { background: transparent; color: var(--teal); border-color: transparent; padding-inline: 10px; }
.btn.danger { background: var(--bad); color: #fff; }
.btn.small { padding: 7px 12px; border-radius: 9px; font-size: 14px; }
.btn.block { width: 100%; }
.field { display: grid; gap: 6px; }
.field > span { font-weight: 700; font-size: 14px; }
.field small { color: var(--ink-2); font-size: 13px; }
.input, select.input, textarea.input { width: 100%; border: 1.5px solid var(--line); background: var(--surface); border-radius: 12px; padding: 12px 14px; }
textarea.input { resize: vertical; min-height: 64px; }
.input:focus { border-color: var(--teal); outline: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--teal) 25%, transparent); }

.banner { border-radius: 14px; padding: 12px 14px; display: grid; gap: 2px; }
.banner strong { font-family: var(--f-display); font-size: 17px; }
.banner.good { background: var(--good-bg); color: var(--good); }
.banner.warn { background: var(--warn-bg); color: var(--warn); }
.banner.bad { background: var(--bad-bg); color: var(--bad); }
.banner.info { background: var(--info-bg); color: var(--info); }
.banner p { margin: 0; color: var(--ink); font-size: 15px; }

/* ===================== Student phone app ===================== */
.esc-play { max-width: 520px; margin: 0 auto; padding-block: 20px 32px; display: grid; gap: 18px; }
.pl-top { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.pl-event { font-family: var(--f-display); font-weight: 700; font-size: 15px; color: var(--teal); }
.pl-who { font-size: 14px; color: var(--ink-2); min-width: 0; overflow-wrap: anywhere; }
.pl-hero { display: grid; gap: 8px; padding-top: 8px; }
.pl-hero h1 { font-size: clamp(30px, 8vw, 40px); }
.pl-hero p { margin: 0; color: var(--ink-2); }

.trail { display: flex; gap: 6px; align-items: center; }
.trail i { flex: 1; height: 10px; border-radius: 99px; background: var(--surface-2); border: 1px solid var(--line); }
.trail i.on { background: var(--green); border-color: var(--green); }
.trail i.now { background: transparent; border: 2px dashed var(--teal); }
.trail-label { display: flex; justify-content: space-between; font-size: 14px; color: var(--ink-2); margin-top: 6px; }

.clue-card { position: relative; background: var(--surface); border-radius: 20px; padding: 22px 20px 24px; box-shadow: var(--shadow); border: 1px solid var(--line); display: grid; gap: 10px; overflow: hidden; }
.clue-card::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 6px; background: repeating-linear-gradient(90deg, var(--green) 0 18px, var(--teal) 18px 36px); }
.clue-text { font-family: var(--f-display); font-size: clamp(22px, 6vw, 27px); font-weight: 600; line-height: 1.25; margin: 0; overflow-wrap: anywhere; }
.pl-tip { display: flex; gap: 10px; align-items: flex-start; font-size: 15px; color: var(--ink-2); }
.pl-tip svg { flex: none; margin-top: 2px; color: var(--teal); }

.hint-box { border: 1.5px dashed var(--line); border-radius: 16px; padding: 14px 16px; display: grid; gap: 10px; }
.hint-wait { display: flex; align-items: center; gap: 12px; color: var(--ink-2); font-size: 15px; }
.hint-wait b { color: var(--ink); font-variant-numeric: tabular-nums; }
.hint-text { margin: 0; font-size: 17px; }
.hint-ring { --p: 0; width: 34px; height: 34px; border-radius: 50%; flex: none; background: conic-gradient(var(--teal) calc(var(--p) * 1%), var(--surface-2) 0); mask: radial-gradient(circle, transparent 10px, #000 11px); -webkit-mask: radial-gradient(circle, transparent 10px, #000 11px); }

.seg { display: grid; grid-template-columns: 1fr 1fr; background: var(--surface-2); border-radius: 14px; padding: 4px; gap: 4px; }
.seg label { text-align: center; padding: 10px; border-radius: 10px; font-weight: 700; cursor: pointer; color: var(--ink-2); }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg label:has(input:checked) { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.seg label:has(input:focus-visible) { outline: 3px solid var(--teal); }
.reg-form { display: grid; gap: 14px; background: var(--surface); padding: 20px; border-radius: 20px; border: 1px solid var(--line); box-shadow: var(--shadow); }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 360px) { .two { grid-template-columns: 1fr; } }
.form-error { color: var(--bad); font-weight: 700; margin: 0; }

/* congrats */
.done { text-align: center; display: grid; gap: 14px; justify-items: center; padding: 26px 18px; border-radius: 24px; color: #fff;
  background: linear-gradient(135deg, var(--green), var(--teal), var(--green)); background-size: 300% 300%; animation: drift 6s ease-in-out infinite; position: relative; overflow: hidden; }
.done h1 { font-size: clamp(34px, 10vw, 48px); color: #fff; }
.done .done-name { font-family: var(--f-display); font-size: 22px; font-weight: 700; overflow-wrap: anywhere; }
.badge { width: 104px; height: 104px; border-radius: 50%; display: grid; place-items: center; position: relative; }
.badge::before { content: ""; position: absolute; inset: 0; border-radius: 50%; background: conic-gradient(#fff 0 25%, transparent 0 50%, #fff 0 75%, transparent 0); animation: spin 3s linear infinite; mask: radial-gradient(circle, transparent 44px, #000 46px); -webkit-mask: radial-gradient(circle, transparent 44px, #000 46px); }
.badge span { width: 80px; height: 80px; border-radius: 50%; background: rgba(255,255,255,.18); display: grid; place-items: center; }
.done-stats { display: grid; grid-template-columns: repeat(3, 1fr); width: 100%; background: rgba(0,0,0,.16); border-radius: 16px; padding: 12px 6px; }
.done-stats div { display: grid; gap: 2px; }
.done-stats dt { font-size: 11px; letter-spacing: .1em; text-transform: uppercase; opacity: .85; }
.done-stats dd { margin: 0; font-family: var(--f-display); font-weight: 700; font-size: 20px; font-variant-numeric: tabular-nums; }
.place { font-family: var(--f-display); font-weight: 800; font-size: 26px; background: #fff; color: var(--teal); padding: 4px 18px; border-radius: 99px; }
.code-card { background: #fff; color: #13211a; border-radius: 16px; padding: 12px 20px; display: grid; gap: 2px; }
.code-card span { font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: #4d5e55; }
.code-card strong { font-family: var(--f-mono); font-size: 40px; letter-spacing: .18em; }
.live { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-variant-numeric: tabular-nums; }
.live i { width: 10px; height: 10px; border-radius: 50%; background: #fff; animation: pulse 1s ease-in-out infinite; }
.done p { margin: 0; }
@keyframes drift { 0%,100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pulse { 50% { opacity: .2; } }

/* ===================== Admin ===================== */
.esc-admin { max-width: 1180px; margin: 0 auto; padding-block: 20px 60px; display: grid; gap: 20px; }
.ad-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; flex-wrap: wrap; }
.ad-head h1 { font-size: 28px; }
.tabs { display: flex; gap: 4px; flex-wrap: wrap; border-bottom: 1px solid var(--line); }
.tabs button { background: none; border: none; padding: 10px 14px; font-weight: 700; color: var(--ink-2); border-bottom: 3px solid transparent; cursor: pointer; margin-bottom: -1px; }
.tabs button[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--green); }
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 640px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 14px 16px; }
.stat b { display: block; font-family: var(--f-display); font-size: 30px; font-variant-numeric: tabular-nums; }
.stat span { color: var(--ink-2); font-size: 14px; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 18px; display: grid; gap: 14px; min-width: 0; }
.panel-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.panel-head h2 { font-size: 20px; }
.dash-grid { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 16px; align-items: start; }
@media (max-width: 900px) { .dash-grid { grid-template-columns: minmax(0, 1fr); } }
.table-wrap { overflow-x: auto; }
table.grid { width: 100%; border-collapse: collapse; font-size: 14px; }
table.grid th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-2); padding: 8px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
table.grid td { padding: 10px; border-bottom: 1px solid var(--line); vertical-align: middle; white-space: nowrap; }
table.grid td.name { white-space: normal; min-width: 140px; font-weight: 700; }
.pbar { display: flex; align-items: center; gap: 8px; }
.pbar i { display: block; width: 90px; height: 8px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.pbar i b { display: block; height: 100%; background: var(--green); }
.pill { white-space: nowrap; display: inline-block; font-size: 12px; font-weight: 700; padding: 2px 9px; border-radius: 99px; background: var(--surface-2); color: var(--ink-2); }
.pill.good { background: var(--good-bg); color: var(--good); }
.pill.warn { background: var(--warn-bg); color: var(--warn); }
.pill.bad { background: var(--bad-bg); color: var(--bad); }
.pill.info { background: var(--info-bg); color: var(--info); }
.feed { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; max-height: 520px; overflow: auto; font-size: 14px; }
.feed li { display: grid; grid-template-columns: 62px 1fr; gap: 8px; padding: 7px 0; border-bottom: 1px solid var(--line); }
.feed time { color: var(--ink-2); font-variant-numeric: tabular-nums; }
.empty { color: var(--ink-2); text-align: center; padding: 28px 10px; }

.settings { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; align-items: start; }
@media (max-width: 820px) { .settings { grid-template-columns: minmax(0, 1fr); } }
.settings .panel { gap: 16px; }
.toggle { display: flex; justify-content: space-between; align-items: center; gap: 14px; }
.toggle > span { display: grid; gap: 2px; }
.toggle > span b { font-size: 15px; }
.toggle > span small { color: var(--ink-2); font-size: 13px; }
.switch { position: relative; width: 48px; height: 28px; flex: none; }
.switch input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; z-index: 1; }
.switch i { position: absolute; inset: 0; border-radius: 99px; background: var(--line); transition: background .15s; }
.switch i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; transition: transform .15s; box-shadow: 0 1px 3px rgba(0,0,0,.25); }
.switch input:checked + i { background: var(--green); }
.switch input:checked + i::after { transform: translateX(20px); }
.switch input:focus-visible + i { outline: 3px solid var(--teal); outline-offset: 2px; }
.radio-cards { display: grid; gap: 8px; }
.radio-cards label { display: flex; gap: 10px; align-items: flex-start; border: 1.5px solid var(--line); border-radius: 12px; padding: 10px 12px; cursor: pointer; }
.radio-cards label:has(input:checked) { border-color: var(--green); background: color-mix(in srgb, var(--green) 8%, var(--surface)); }
.radio-cards input { margin-top: 4px; accent-color: var(--green); }
.radio-cards b { display: block; font-size: 15px; }
.radio-cards small { color: var(--ink-2); font-size: 13px; }
.count-picker { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 6px; }
.count-picker label { position: relative; text-align: center; padding: 9px 0; border: 1.5px solid var(--line); border-radius: 10px; font-weight: 700; cursor: pointer; font-variant-numeric: tabular-nums; }
.count-picker input { position: absolute; opacity: 0; pointer-events: none; }
.count-picker label:has(input:checked) { background: var(--green); border-color: var(--green); color: var(--on-accent); }
.count-picker label:has(input:focus-visible) { outline: 3px solid var(--teal); }
.savebar { position: sticky; bottom: 0; background: color-mix(in srgb, var(--bg) 92%, transparent); backdrop-filter: blur(6px); padding-block: 12px calc(12px + env(safe-area-inset-bottom, 0px)); display: flex; gap: 12px; align-items: center; flex-wrap: wrap; border-top: 1px solid var(--line); }
.danger-zone { border-color: color-mix(in srgb, var(--bad) 45%, var(--line)); }

.items { display: grid; gap: 12px; }
.item-row { display: grid; grid-template-columns: 54px minmax(0, 1fr); gap: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 14px; }
.item-num { width: 46px; height: 46px; border-radius: 12px; background: var(--teal); color: #fff; display: grid; place-items: center; font-family: var(--f-display); font-weight: 800; font-size: 20px; }
.item-fields { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; }
.item-fields .wide { grid-column: 1 / -1; }
@media (max-width: 700px) { .item-fields { grid-template-columns: minmax(0, 1fr); } }
.token-line { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 13px; color: var(--ink-2); }
.route { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: 14px; }
.route span { background: var(--surface-2); border-radius: 8px; padding: 3px 9px; font-weight: 700; font-variant-numeric: tabular-nums; }

.qr-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 14px; }
.qr-card { background: #fff; color: #13211a; border: 1px solid var(--line); border-radius: 16px; padding: 16px; display: grid; gap: 8px; justify-items: center; text-align: center; }
.qr-card .qr { width: 100%; max-width: 200px; aspect-ratio: 1; }
.qr-card .qr svg { width: 100%; height: 100%; display: block; }
.qr-card h3 { font-size: 26px; color: #1E4BD2; font-family: var(--f-display); }

.qr-card p { margin: 0; font-size: 13px; color: #4d5e55; }
.qr-card .url { font-family: var(--f-mono); font-size: 10px; color: #4d5e55; overflow-wrap: anywhere; }
.verify { display: flex; gap: 10px; flex-wrap: wrap; }
.verify .input { max-width: 220px; font-family: var(--f-mono); font-size: 24px; letter-spacing: .2em; text-transform: uppercase; }

.modal-back { position: fixed; inset: 0; background: rgba(8, 15, 12, .55); display: grid; place-items: center; padding: 16px; z-index: 50; }
.modal { background: var(--surface); border-radius: 20px; padding: 20px; width: min(460px, 100%); max-height: 90vh; overflow: auto; display: grid; gap: 14px; box-shadow: 0 20px 60px rgba(0,0,0,.35); }
.modal h2 { font-size: 22px; }
.modal .actions { display: flex; gap: 8px; flex-wrap: wrap; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; font-size: 15px; margin: 0; }
.kv dt { color: var(--ink-2); }
.kv dd { margin: 0; font-weight: 700; overflow-wrap: anywhere; }
.login { max-width: 380px; margin: 10vh auto 0; display: grid; gap: 14px; }
.flash { font-weight: 700; }
.flash.good { color: var(--good); }
.flash.bad { color: var(--bad); }

/* ===================== Leaderboard (TV) ===================== */
.esc-board { max-width: 1300px; margin: 0 auto; padding-block: 28px; display: grid; gap: 24px; }
.board-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.board-head h1 { font-size: clamp(30px, 5vw, 56px); }
.board-head .counts { font-size: clamp(16px, 2vw, 22px); color: var(--ink-2); font-variant-numeric: tabular-nums; }
.board-cols { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 22px; align-items: start; }
@media (max-width: 860px) { .board-cols { grid-template-columns: minmax(0, 1fr); } }
.ranks { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.ranks li { display: grid; grid-template-columns: 64px minmax(0, 1fr) auto; align-items: center; gap: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 12px 18px; }
.ranks .pl { font-family: var(--f-display); font-weight: 800; font-size: clamp(24px, 3vw, 36px); color: var(--teal); font-variant-numeric: tabular-nums; }
.ranks li:nth-child(1) { background: var(--green); border-color: var(--green); color: var(--on-accent); }
.ranks li:nth-child(1) .pl, .ranks li:nth-child(1) .sub { color: var(--on-accent); }
.ranks .nm { font-family: var(--f-display); font-weight: 700; font-size: clamp(20px, 2.4vw, 30px); overflow-wrap: anywhere; }
.ranks .sub { font-size: 14px; color: var(--ink-2); }
.ranks .tm { font-family: var(--f-mono); font-size: clamp(18px, 2.2vw, 28px); font-variant-numeric: tabular-nums; }
.racers { display: grid; gap: 10px; }
.racer { display: grid; gap: 4px; }
.racer-top { display: flex; justify-content: space-between; gap: 10px; font-size: clamp(15px, 1.6vw, 20px); }
.racer-top b { overflow-wrap: anywhere; }
.racer .trail i { height: 12px; }

@media print {
  body { background: #fff; }
  .no-print, .tabs, .ad-head, .savebar { display: none !important; }
  .esc-admin { padding: 0; max-width: none; }
  .qr-grid { grid-template-columns: 1fr 1fr; gap: 0; }
  .qr-card { border: 1px dashed #999; border-radius: 0; break-inside: avoid; padding: 28px; min-height: 48vh; align-content: center; }
  .qr-card .qr { max-width: 280px; }
  .qr-card h3 { font-size: 34px; }
}
@media (prefers-reduced-motion: reduce) {
  .done, .badge::before, .live i { animation: none; }
}

/* ===================== Escape specifics ===================== */
h1, h2, h3 { letter-spacing: .02em; }
.btn { text-transform: uppercase; letter-spacing: .06em; }
.input { background: var(--surface-2); }
.caution { height: 10px; border-radius: 4px; background: repeating-linear-gradient(-45deg, var(--green) 0 12px, var(--royal) 12px 24px); }
.countdown { display: flex; justify-content: space-between; align-items: center; gap: 10px; font-family: var(--f-mono); font-size: 13px; color: var(--ink-2); }
.countdown b { color: var(--alarm); font-size: 15px; font-variant-numeric: tabular-nums; }
.dossier { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; }
.dossier-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding: 16px 18px 12px; border-bottom: 1px dashed var(--line); }
.dossier-head h2 { font-size: 28px; overflow-wrap: anywhere; }
.stamp { font-family: var(--f-display); font-size: 15px; letter-spacing: .1em; color: var(--alarm); border: 2px solid var(--alarm); border-radius: 6px; padding: 2px 8px; transform: rotate(4deg); white-space: nowrap; }
.dossier-body { padding: 14px 18px 18px; display: grid; gap: 14px; }
.meta { display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; font-family: var(--f-mono); font-size: 13px; margin: 0; }
.meta dt { color: var(--ink-2); text-transform: uppercase; }
.meta dd { margin: 0; overflow-wrap: anywhere; }
.code-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(52px, 1fr)); gap: 8px; }
.piece { aspect-ratio: 1; border-radius: 12px; border: 1.5px solid var(--line); background: var(--surface-2); display: grid; place-items: center; align-content: center; gap: 2px; position: relative; }
.piece svg { width: 18px; height: 18px; color: var(--teal); }
.piece b { font-family: var(--f-mono); font-size: 22px; line-height: 1; }
.piece.empty { border-style: dashed; background: transparent; color: var(--ink-2); }
.piece.empty b { font-size: 18px; opacity: .5; }
.piece.new { animation: drop .6s cubic-bezier(.2, 1.6, .4, 1); border-color: var(--green); }
@keyframes drop { from { transform: scale(.3) rotate(-20deg); opacity: 0; } to { transform: none; opacity: 1; } }
.next-card { background: var(--green); color: var(--on-accent); border-radius: 18px; padding: 18px; display: grid; gap: 4px; }
.next-card .eyebrow { color: var(--on-accent); opacity: .75; }
.next-card h2 { font-size: 34px; }
.next-card p { margin: 0; font-weight: 700; }
.next-card.final { background: var(--royal); color: #fff; }
.next-card.final .eyebrow { color: #fff; }
.next-card.wait { background: var(--surface-2); color: var(--ink); }
.next-card.wait .eyebrow { color: var(--ink-2); }
.puzzle { background: var(--surface); border: 2px solid var(--green); border-radius: 18px; padding: 18px; display: grid; gap: 12px; }
.puzzle-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.puzzle-head h2 { font-size: 26px; }
.puzzle-head svg { width: 28px; height: 28px; color: var(--teal); flex: none; }
.puzzle p.prompt { margin: 0; font-size: 19px; line-height: 1.4; overflow-wrap: anywhere; }
.answer-row { display: flex; gap: 8px; }
.answer-row .input { flex: 1; min-width: 0; font-family: var(--f-mono); font-size: 18px; text-transform: uppercase; }
.lockout { text-align: center; padding: 12px; border-radius: 12px; background: var(--bad-bg); color: var(--bad); font-weight: 700; }
.lockout b { font-family: var(--f-mono); font-variant-numeric: tabular-nums; }
.team-code { display: flex; align-items: center; justify-content: space-between; gap: 10px; background: var(--surface-2); border-radius: 12px; padding: 10px 14px; }
.team-code strong { font-family: var(--f-mono); font-size: 26px; letter-spacing: .2em; color: var(--green); }
.remaining { display: grid; gap: 6px; font-size: 14px; margin: 0; padding: 0; list-style: none; }
.remaining li { display: flex; justify-content: space-between; gap: 10px; border-bottom: 1px solid var(--line); padding: 6px 0; }
.seg3 { grid-template-columns: repeat(3, 1fr); }
.done { background: repeating-linear-gradient(-45deg, #171A20 0 18px, #111317 18px 36px); border: 3px solid var(--green); color: var(--ink); animation: none; }
.done h1 { color: var(--green); font-size: clamp(38px, 12vw, 52px); max-width: 100%; overflow-wrap: anywhere; }
.done .place { background: var(--green); color: var(--on-accent); }
.done-stats { background: rgba(0,0,0,.35); }
.live i { background: var(--alarm); }
.badge::before { background: conic-gradient(var(--green) 0 25%, transparent 0 50%, var(--green) 0 75%, transparent 0); }
.badge span { background: rgba(76,187,23,.16); }
.denied { animation: shake .4s; }
@keyframes shake { 20%, 60% { transform: translateX(-8px); } 40%, 80% { transform: translateX(8px); } }
.sym-pick { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 4px; }
.sym-pick label { position: relative; display: grid; place-items: center; aspect-ratio: 1; border: 1.5px solid var(--line); border-radius: 8px; cursor: pointer; color: var(--ink-2); }
.sym-pick input { position: absolute; opacity: 0; pointer-events: none; }
.sym-pick label:has(input:checked) { border-color: var(--green); color: var(--green); background: var(--surface-2); }
.sym-pick svg { width: 18px; height: 18px; }
.poster { background: #fff; color: #111; border-radius: 12px; padding: 28px; display: grid; gap: 18px; text-align: center; }
.poster h3 { font-family: var(--f-display); font-size: 40px; color: #1E4BD2; }
.poster-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.poster-row span { width: 64px; height: 64px; border: 3px solid #111; border-radius: 10px; display: grid; place-items: center; }
.poster-row svg { width: 36px; height: 36px; color: #111; }
.zone-load { display: grid; gap: 6px; font-size: 14px; }
.zone-load div { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; align-items: center; }
.big-clock { font-family: var(--f-mono); font-size: clamp(56px, 11vw, 150px); font-weight: 700; color: var(--alarm); font-variant-numeric: tabular-nums; line-height: 1; }
.esc-board .ranks li:nth-child(1) { background: var(--green); border-color: var(--green); }
.esc-board .ranks .pl { color: var(--green); }
.winner-reveal { text-align: center; padding: 24px; border-radius: 16px; background: var(--surface-2); display: grid; gap: 6px; }
.winner-reveal strong { font-family: var(--f-display); font-size: clamp(32px, 6vw, 54px); color: var(--green); }
@media print {
  .poster { border: 4px solid #111; }
}
@media (prefers-reduced-motion: reduce) { .piece.new, .denied { animation: none; } }
.zone-load span { display: grid; gap: 0; }
.zone-load span .muted { font-size: 12px; }
