/* Self-hosted, Latin-subset webfonts — see fonts/ (also used by make_preview.py) */
@font-face {
  font-family: 'Anton';
  src: url('fonts/Anton-latin.woff2') format('woff2');
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Hanken Grotesk';
  src: url('fonts/HankenGrotesk-latin.woff2') format('woff2');
  font-weight: 100 900; font-style: normal; font-display: swap;
}
:root {
  --bg: #0c0d11;
  --bg-2: #111319;
  --surface: #15171f;
  --surface-2: #1b1e28;
  --line: #262a36;
  --line-2: #313646;
  --text: #f3f4f8;
  --text-dim: #99a0b2;
  --text-mute: #6b7187;
  --accent: #3d6dff;
  --accent-bright: #6f92ff;   /* lighter accent for small mono labels — legible on dark + banner */
  --accent-ink: #f5f8ff;
  --accent-soft: rgba(61,109,255,0.15);
  --accent-line: rgba(61,109,255,0.5);
  --gold: #e8b53a;
  --gold-ink: #15110a;
  --gold-soft: rgba(232,181,58,0.14);
  --gold-line: rgba(232,181,58,0.5);
  --radius: 16px;
  --maxw: 1180px;
  --gap: 18px;
  --pad: 22px;
  --font-hero: 'Anton', 'Hanken Grotesk', sans-serif;
  --font-display: 'Hanken Grotesk', system-ui, sans-serif;
  /* repointed off Space Mono to Hanken — kept the name to avoid churn at call sites */
  --font-mono: 'Hanken Grotesk', system-ui, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-display);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
}
button { font-family: var(--font-display); }

.page-glow {
  position: fixed; top: -340px; left: 50%; transform: translateX(-50%);
  width: 1100px; height: 720px;
  background: radial-gradient(ellipse at center, var(--accent-soft), transparent 62%);
  pointer-events: none; z-index: 0; opacity: 0.9;
}
.grain {
  position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: 0.4;
  background-image:
    linear-gradient(transparent 0, transparent calc(100% - 1px), rgba(255,255,255,0.018) 100%),
    linear-gradient(90deg, transparent 0, transparent calc(100% - 1px), rgba(255,255,255,0.018) 100%);
  background-size: 46px 46px, 46px 46px;
  mask-image: radial-gradient(ellipse at 50% 0%, #000 30%, transparent 80%);
}

.wrap { position: relative; z-index: 1; max-width: var(--maxw); margin: 0 auto; padding: 0 22px 90px; }
.boot { position: fixed; inset: 0; display: grid; place-items: center; color: var(--text-mute); font-family: var(--font-mono); font-size: 13px; letter-spacing: 0.08em; }

@keyframes riseIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: translateY(0); } }
@keyframes pulseDot { 0%, 100% { opacity: 1; } 50% { opacity: 0.25; } }
@keyframes popCheck { 0% { transform: scale(0.4); opacity: 0; } 60% { transform: scale(1.15); } 100% { transform: scale(1); opacity: 1; } }

::selection { background: var(--accent); color: var(--accent-ink); }

/* ---------- USERNAME GATE ---------- */
.gate-overlay { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 24px;
  background: radial-gradient(ellipse at 50% -10%, var(--accent-soft), transparent 55%), var(--bg); }
.gate-card { width: min(440px, 100%); background: var(--surface); border: 1px solid var(--line); border-radius: 20px;
  padding: 34px 32px 30px; box-shadow: 0 30px 80px -30px rgba(0,0,0,0.8); animation: riseIn 0.5s cubic-bezier(.2,.8,.2,1) both; }
.gate-live { display: inline-flex; align-items: center; gap: 7px; font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.14em; color: var(--accent); margin-bottom: 20px; }
.gate-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); animation: pulseDot 1.4s infinite; }
.gate-brand { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.22em; color: var(--text-mute); margin-bottom: 6px; }
.gate-h1 { margin: 0 0 10px; font-size: 34px; font-weight: 700; letter-spacing: -0.02em; }
.gate-p { margin: 0 0 22px; color: var(--text-dim); font-size: 14.5px; line-height: 1.55; }
.gate-p strong { color: var(--text); font-weight: 600; }
.gate-field { display: flex; align-items: center; gap: 4px; background: var(--bg-2); border: 1px solid var(--line-2); border-radius: 12px; padding: 0 14px; margin-bottom: 14px; }
.gate-at { font-family: var(--font-mono); color: var(--text-mute); font-size: 18px; }
.gate-input { flex: 1; background: transparent; border: none; outline: none; color: var(--text); font-family: var(--font-display); font-size: 18px; padding: 15px 6px; letter-spacing: 0.01em; }
.gate-btn { width: 100%; border: none; border-radius: 12px; background: var(--accent); color: var(--accent-ink); font-size: 16px; font-weight: 600; padding: 15px; letter-spacing: 0.01em; transition: transform 0.15s, opacity 0.2s; cursor: pointer; }
.gate-btn:disabled { opacity: 0.4; cursor: not-allowed; }
.gate-fine { text-align: center; margin-top: 16px; font-family: var(--font-mono); font-size: 10.5px; color: var(--text-mute); letter-spacing: 0.04em; }

/* ---------- TOP BAR ---------- */
.topbar { display: flex; justify-content: space-between; align-items: center; padding: 22px 0 20px; border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 20; background: linear-gradient(var(--bg) 78%, transparent); backdrop-filter: blur(6px); }
.tb-left { display: flex; align-items: center; gap: 16px; }
.tb-live { display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.12em; color: var(--accent); border: 1px solid var(--accent-line); border-radius: 100px; padding: 4px 9px; }
.tb-live.closed { color: var(--text-mute); border-color: var(--line-2); }
.tb-livedot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); animation: pulseDot 1.4s infinite; }
.tb-live.closed .tb-livedot { animation: none; background: var(--text-mute); }
.tb-brand { font-weight: 700; font-size: 19px; letter-spacing: -0.01em; }
.tb-slash { color: var(--accent); margin: 0 1px; }
.tb-sub { color: var(--text-mute); font-family: var(--font-mono); font-size: 13px; letter-spacing: 0.1em; }
/* admin-only quick links (results preview / raffle) — see buildAdminNav() */
.tb-admin { display: inline-flex; align-items: center; gap: 8px; }
.tb-adminlink { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--text-mute); text-decoration: none; border: 1px solid var(--line-2); border-radius: 100px; padding: 4px 10px;
  transition: color 0.15s, border-color 0.15s; }
.tb-adminlink:hover { color: var(--accent); border-color: var(--accent-line); }
.tb-right { display: flex; align-items: center; gap: 18px; }
.tb-progress { text-align: right; border-radius: 10px; padding: 4px 0; transition: transform 0.3s; }
.tb-progress.flash { transform: scale(1.08); }
.tb-prognum { font-family: var(--font-mono); font-size: 17px; font-weight: 700; color: var(--text); }
.tb-progslash { color: var(--text-mute); font-weight: 400; font-size: 13px; }
.tb-proglbl { display: block; font-family: var(--font-mono); font-size: 9.5px; letter-spacing: 0.12em; color: var(--text-mute); text-transform: uppercase; }
.tb-user { display: flex; align-items: center; gap: 10px; }
.tb-avatar { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; background: var(--accent-soft); border: 1px solid var(--accent-line); color: var(--accent); font-weight: 700; font-size: 16px; }
.tb-meta { display: flex; flex-direction: column; line-height: 1.25; }
.tb-name { font-size: 14px; font-weight: 600; }
.tb-signout { background: none; border: none; padding: 0; text-align: left; color: var(--text-mute); font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.04em; cursor: pointer; }
.tb-signout:hover { color: var(--text-dim); }

/* ---------- INTRO ---------- */
.intro { display: flex; justify-content: space-between; align-items: flex-end; gap: 30px; flex-wrap: wrap; margin-top: 44px; }
.intro-season { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.22em; color: var(--accent); margin-bottom: 14px; }
.intro-main { min-width: 0; }
.intro-h1row { display: flex; align-items: center; gap: clamp(16px, 3vw, 40px); }
.intro-h1 { margin: 0; font-family: var(--font-hero); font-size: clamp(48px, 7vw, 84px); font-weight: 400; text-transform: uppercase; letter-spacing: 0.01em; line-height: 0.92; }
.intro-img { height: clamp(72px, 11vw, 132px); width: auto; flex-shrink: 0; }
.intro-em { color: var(--accent); font-style: normal; }
.intro-p { margin: 16px 0 0; max-width: 560px; color: var(--text-dim); font-size: 15px; line-height: 1.6; text-wrap: pretty; }
.status-card { display: flex; align-items: center; gap: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 16px 20px 16px 16px; }
.status-ring { position: relative; width: 80px; height: 80px; display: grid; place-items: center; }
.ring-num { position: absolute; font-family: var(--font-mono); font-size: 20px; font-weight: 700; }
.ring-den { color: var(--text-mute); font-size: 12px; }
.status-text { max-width: 120px; font-size: 12.5px; color: var(--text-dim); font-family: var(--font-mono); line-height: 1.45; }

/* ---------- GRID ---------- */
.vote-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: var(--gap); margin-top: 26px; }

/* ---------- CARD ---------- */
.cat-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: var(--pad);
  display: flex; flex-direction: column; animation: riseIn 0.55s cubic-bezier(.2,.8,.2,1) both; }
.card-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; margin-bottom: 16px; }
.card-tag { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.16em; color: var(--accent); }
.card-title { margin: 8px 0 4px; font-size: 21px; font-weight: 700; letter-spacing: -0.01em; }
.card-sub { margin: 0; font-size: 13px; color: var(--text-dim); line-height: 1.4; }
.card-total { text-align: right; flex-shrink: 0; display: flex; flex-direction: column; }
.card-totalnum { font-family: var(--font-mono); font-size: 16px; font-weight: 700; color: var(--text); }
.card-totallbl { font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-mute); }
.lock-badge { flex-shrink: 0; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.1em; color: var(--accent); border: 1px solid var(--accent-line); border-radius: 100px; padding: 5px 10px; white-space: nowrap; }
.card-rows { display: flex; flex-direction: column; gap: 8px; }
.card-foot { margin-top: 16px; padding-top: 13px; border-top: 1px solid var(--line); min-height: 44px; display: flex; align-items: center; }
.voted-tag { display: inline-flex; align-items: center; gap: 8px; font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.03em; color: var(--accent); }
.voted-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.open-tag { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.03em; color: var(--text-mute); }
.lock-btn { width: 100%; border: 1px solid var(--accent-line); border-radius: 10px; background: var(--accent-soft); color: var(--accent); font-size: 14px; font-weight: 600; padding: 11px; transition: opacity 0.2s, background 0.2s; cursor: pointer; }
.lock-btn:disabled { opacity: 0.38; cursor: not-allowed; }
.lock-btn:not(:disabled):hover { background: rgba(61,109,255,0.2); }
.confirm-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; flex-wrap: wrap; }
.confirm-text { font-family: var(--font-mono); font-size: 11.5px; color: var(--text); letter-spacing: 0.02em; }
.confirm-btns { display: flex; gap: 8px; margin-left: auto; }
.cancel-btn { border: 1px solid var(--line-2); border-radius: 9px; background: transparent; color: var(--text-dim); font-size: 13px; font-weight: 500; padding: 8px 13px; cursor: pointer; }
.cancel-btn:hover { color: var(--text); border-color: var(--text-mute); }
.confirm-btn { border: none; border-radius: 9px; background: var(--accent); color: var(--accent-ink); font-size: 13px; font-weight: 600; padding: 8px 15px; cursor: pointer; }

/* ---------- OPTION ROW ---------- */
.opt-row { position: relative; width: 100%; text-align: left; border: 1px solid var(--line); border-radius: 11px; overflow: hidden;
  padding: 0; background: var(--surface-2); transition: border-color 0.2s, background 0.2s, opacity 0.3s; cursor: default; }
.opt-row.live { cursor: pointer; }
.opt-row.highlight { border-color: var(--accent-line); background: var(--accent-soft); }
.opt-row.dim { opacity: 0.5; }
.opt-row.live:hover { border-color: var(--accent-line); }
.opt-row.live:hover .opt-pick { color: var(--accent); }
.opt-row.live:active { transform: translateY(1px); }
.opt-fill { position: absolute; left: 0; top: 0; bottom: 0; width: 0; transition: width 0.7s cubic-bezier(.2,.8,.2,1), opacity 0.4s; border-radius: 11px 0 0 11px; }
.opt-content { position: relative; display: flex; align-items: center; gap: 12px; padding: 11px 14px; }
.opt-radio { width: 18px; height: 18px; border-radius: 50%; flex-shrink: 0; border: 2px solid var(--line-2); display: grid; place-items: center; transition: border-color 0.2s; }
.opt-radio.on { border-color: var(--accent); }
.opt-radiodot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.opt-avatar { width: 30px; height: 30px; border-radius: 8px; flex-shrink: 0; display: grid; place-items: center; background: var(--bg-2); border: 1px solid var(--line-2); font-family: var(--font-mono); font-weight: 700; font-size: 13px; color: var(--text-mute); }
.opt-avatar.on { border-color: var(--accent-line); color: var(--accent); }
/* optional square icon (JSON `img`) fills the avatar slot */
.opt-avatar.opt-img { padding: 0; overflow: hidden; background: var(--bg-2); }
.opt-avatar.opt-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
/* optional wide art (JSON `banner`) as a row background, behind fill + content */
.opt-banner { position: absolute; inset: 0; z-index: 0; background-size: cover; background-position: center; }
.opt-banner::after { content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, var(--surface-2) 0%, rgba(0,0,0,0.55) 45%, rgba(0,0,0,0.3) 100%); }
.opt-row.has-banner { background: var(--bg-2); }
.opt-row.has-banner .opt-content { min-height: 34px; }
.opt-row.has-banner .opt-name { color: #fff; text-shadow: 0 1px 3px rgba(0,0,0,0.7); }
.opt-row.has-banner .opt-note { color: rgba(255,255,255,0.85); text-shadow: 0 1px 3px rgba(0,0,0,0.7); }
.opt-row.has-banner.highlight { background: var(--accent-soft); }
/* right-side cluster (%, count, LOCKED, ✓) sits over the lightly-scrimmed right edge of
   the banner, which can be bright art — white fill + a strong dark shadow keeps it legible
   over both light and dark regions (a single-colour outline only works over one or the other). */
.opt-row.has-banner .opt-pct { color: #fff; text-shadow: 0 1px 2px rgba(0,0,0,0.9), 0 0 5px rgba(0,0,0,0.55); }
.opt-row.has-banner .opt-pct.mine { color: #cdd9ff; }
.opt-row.has-banner .opt-count { color: rgba(255,255,255,0.88); text-shadow: 0 1px 2px rgba(0,0,0,0.9), 0 0 5px rgba(0,0,0,0.55); }
.opt-row.has-banner .opt-locked { color: #fff; text-shadow: 0 1px 2px rgba(0,0,0,0.9), 0 0 5px rgba(0,0,0,0.55); }
.opt-row.has-banner .opt-pick { color: #fff; text-shadow: 0 1px 2px rgba(0,0,0,0.9), 0 0 5px rgba(0,0,0,0.55); }
.opt-row.has-banner .opt-check { color: #fff; text-shadow: 0 1px 2px rgba(0,0,0,0.9), 0 0 5px rgba(0,0,0,0.55); }
.opt-label { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.opt-name { font-size: 14.5px; font-weight: 600; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.opt-note { font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.04em; color: var(--text-mute); margin-top: 1px; }
.opt-check { color: var(--accent); font-size: 15px; font-weight: 700; animation: popCheck 0.4s cubic-bezier(.2,.8,.2,1) both; }
.opt-crown { font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.14em; color: var(--accent-ink); background: var(--accent); border-radius: 4px; padding: 3px 6px; flex-shrink: 0; }
.opt-right { margin-left: auto; display: flex; align-items: baseline; gap: 8px; flex-shrink: 0; }
.opt-pct { font-family: var(--font-mono); font-size: 15px; font-weight: 700; color: var(--text); }
.opt-pct.mine { color: var(--accent-bright); }
.opt-count { font-family: var(--font-mono); font-size: 10px; color: var(--text-dim); }
.opt-pick { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.1em; color: var(--text-mute); }
.opt-locked { font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.1em; color: var(--accent-bright); }
/* selected/winner row sits on the blue --accent-soft fill — lift the muted subtext a notch
   (banner rows keep their white .has-banner treatment) */
.opt-row.highlight:not(.has-banner) .opt-note { color: var(--text-dim); }

/* ---------- CHANNEL / CTA ROW ---------- */
/* "chan-" not "social-" on purpose: ad-blocker cosmetic filters hide .social-* as
   tracking widgets. Keep these names ad-blocker-neutral. */
.chan-row { margin-top: 48px; display: flex; align-items: center; justify-content: center;
  flex-wrap: wrap; gap: 18px 24px; }
.chan-lead { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--text-mute); }
.chan-list { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.chan-link { display: inline-flex; align-items: center; gap: 11px; text-decoration: none;
  background: var(--surface); border: 1px solid var(--line); border-radius: 12px;
  padding: 10px 16px; color: var(--text-dim);
  transition: border-color 0.15s, background 0.15s, color 0.15s, transform 0.1s; }
.chan-link:hover { border-color: var(--accent-line); background: var(--surface-2);
  color: var(--text); transform: translateY(-1px); }
.chan-link:active { transform: translateY(0); }
.chan-link.icon-only { padding: 10px; }
.chan-glyph { display: flex; flex-shrink: 0; color: var(--accent); }
.chan-glyph svg { width: 20px; height: 20px; display: block; fill: currentColor; }
.chan-text { display: flex; flex-direction: column; line-height: 1.2; }
.chan-name { font-size: 14px; font-weight: 600; color: var(--text); }
.chan-handle { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.04em;
  color: var(--text-mute); margin-top: 1px; }

/* ---------- FOOTER ---------- */
.site-foot { margin-top: 60px; }
.foot-line { height: 1px; background: var(--line); }
.foot-row { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; padding-top: 18px; }
.foot-copy { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.04em; color: var(--text-mute); max-width: 640px; }
.foot-brand { display: flex; align-items: center; gap: 14px; }
.foot-img { height: 46px; width: auto; flex-shrink: 0; }
.foot-credit { display: flex; flex-direction: column; gap: 3px; text-align: right; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.04em; color: var(--text-mute); flex-shrink: 0; }
.foot-name { color: var(--accent); text-decoration: none; }
.foot-reset { background: none; border: 1px solid var(--line-2); border-radius: 8px; padding: 7px 12px; color: var(--text-dim); font-family: var(--font-mono); font-size: 11px; cursor: pointer; letter-spacing: 0.04em; flex-shrink: 0; }
.foot-reset:hover { border-color: var(--text-mute); color: var(--text); }

/* ---------- TWITCH AUTH ---------- */
.tw-connect { display: inline-flex; align-items: center; gap: 8px; background: #9146ff; color: #fff; border: none; border-radius: 10px; padding: 10px 16px; font-size: 14px; font-weight: 600; cursor: pointer; transition: background 0.15s, transform 0.1s; }
.tw-connect:hover { background: #7d2ff5; }
.tw-connect:active { transform: translateY(1px); }
.tw-glyph { width: 15px; height: 15px; display: block; fill: currentColor; }
.tb-loginwrap { display: flex; flex-direction: column; align-items: flex-end; gap: 5px; }
.tb-hint { font-family: var(--font-mono); font-size: 9.5px; letter-spacing: 0.06em; color: var(--text-mute); }

.browse-cta { width: 100%; display: flex; align-items: center; justify-content: center; gap: 9px; border: 1px solid var(--line-2); border-radius: 10px; background: var(--surface-2); color: var(--text-dim); font-size: 13px; font-weight: 600; padding: 11px; cursor: pointer; transition: border-color 0.2s, color 0.2s, background 0.2s; }
.browse-cta:hover { border-color: #9146ff; color: #fff; background: rgba(145,70,255,0.08); }
.browse-cta .tw-glyph { color: #9146ff; width: 14px; height: 14px; }

/* ---------- SIGN-IN MODAL ---------- */
.modal-overlay { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; padding: 24px; background: rgba(6,7,10,0.72); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); animation: fadeIn 0.2s ease; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.modal-card { width: min(420px, 100%); background: var(--surface); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; box-shadow: 0 30px 80px -30px rgba(0,0,0,0.85); animation: riseIn 0.4s cubic-bezier(.2,.8,.2,1) both; }
.modal-top { background: #9146ff; padding: 18px 24px; display: flex; align-items: center; gap: 10px; color: #fff; }
.modal-top .tw-glyph { width: 20px; height: 20px; }
.modal-top b { font-size: 15px; font-weight: 700; letter-spacing: 0.01em; }
.modal-body { padding: 24px; }
.modal-h { margin: 0 0 8px; font-size: 21px; font-weight: 700; letter-spacing: -0.01em; }
.modal-p { margin: 0 0 18px; color: var(--text-dim); font-size: 14px; line-height: 1.55; }
.perm { display: flex; align-items: center; gap: 10px; padding: 11px 12px; background: var(--bg-2); border: 1px solid var(--line); border-radius: 10px; margin-bottom: 16px; font-size: 12.5px; color: var(--text-dim); }
.perm svg { flex-shrink: 0; color: #9146ff; }
.modal-label { display: block; font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-mute); margin-bottom: 7px; }
.modal-field { display: flex; align-items: center; gap: 4px; background: var(--bg-2); border: 1px solid var(--line-2); border-radius: 10px; padding: 0 12px; margin-bottom: 18px; }
.modal-at { font-family: var(--font-mono); color: var(--text-mute); font-size: 16px; }
.modal-input { flex: 1; background: transparent; border: none; outline: none; color: var(--text); font-family: var(--font-display); font-size: 16px; padding: 13px 4px; }
.tw-btn { width: 100%; display: flex; align-items: center; justify-content: center; gap: 8px; border: none; border-radius: 10px; background: #9146ff; color: #fff; font-size: 15px; font-weight: 600; padding: 14px; cursor: pointer; transition: background 0.15s; }
.tw-btn .tw-glyph { width: 16px; height: 16px; }
.tw-btn:hover { background: #7d2ff5; }
.tw-btn:disabled { opacity: 0.45; cursor: not-allowed; }
.modal-cancel { width: 100%; margin-top: 8px; background: none; border: none; color: var(--text-mute); font-family: var(--font-mono); font-size: 11.5px; padding: 10px; cursor: pointer; letter-spacing: 0.04em; }
.modal-cancel:hover { color: var(--text-dim); }
.modal-fine { text-align: center; margin-top: 14px; font-family: var(--font-mono); font-size: 10px; color: var(--text-mute); letter-spacing: 0.02em; line-height: 1.6; }
.modal-error { background: rgba(255,77,141,0.12); border: 1px solid rgba(255,77,141,0.4); color: #ff9bbd; border-radius: 10px; padding: 10px 12px; font-size: 12.5px; line-height: 1.45; margin-bottom: 16px; }
.modal-form { display: block; }
.redir-note { margin-top: 14px; background: var(--bg-2); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; }
.redir-lbl { display: block; font-family: var(--font-mono); font-size: 9.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-mute); margin-bottom: 5px; }
.redir-url { display: block; font-family: var(--font-mono); font-size: 11px; color: var(--text-dim); word-break: break-all; line-height: 1.4; }
.modal-or { text-align: center; font-family: var(--font-mono); font-size: 10.5px; color: var(--text-mute); margin: 14px 0 4px; letter-spacing: 0.1em; }
.modal-link { width: 100%; background: none; border: none; color: var(--accent); font-family: var(--font-display); font-size: 13.5px; font-weight: 600; padding: 8px; cursor: pointer; }
.modal-link:hover { text-decoration: underline; }
.tb-avatar { overflow: hidden; }
.tb-avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: 9px; display: block; }

@media (max-width: 640px) {
  .intro { flex-direction: column; align-items: flex-start; }
  .vote-grid { grid-template-columns: 1fr; }
  /* Stack the topbar so the admin links don't overflow: left group (badge +
     brand + admin nav) on one wrapping row, right group (progress + user) below. */
  .topbar { flex-wrap: wrap; gap: 12px 16px; }
  .tb-left { flex: 1 1 100%; flex-wrap: wrap; gap: 10px 12px; }
  .tb-right { flex: 1 1 100%; justify-content: space-between; }
}

/* --- Royal blue + gold: gold reserved for emphasis, eyebrows & winners --- */
.intro-em, .gate-headline em, .intro-season, .gate-eyebrow, .done-eyebrow, .card-tag { color: var(--gold); }
.opt-crown { background: var(--gold); color: var(--gold-ink); }

/* ---------- RAFFLE (admin draw page — see raffle.html / raffle-app.js) ---------- */
.raffle-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: var(--gap); margin-top: 26px; }
.raffle-stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; text-align: center; }
.raffle-stat-num { font-family: var(--font-hero); font-size: clamp(30px, 4.5vw, 42px); line-height: 1; color: var(--text); }
.raffle-stat-lbl { margin-top: 9px; font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-mute); }
.raffle-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: var(--pad); margin-top: var(--gap); }
.raffle-stage { display: grid; place-items: center; text-align: center; min-height: 150px; padding: 30px 20px;
  background: var(--bg-2); border: 1px dashed var(--line-2); border-radius: 14px; margin-bottom: 18px; }
.raffle-placeholder { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.1em; color: var(--text-mute); }
.raffle-rolling { animation: pulseDot 0.7s infinite; color: var(--accent); }
.raffle-winner-lbl { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold); margin-bottom: 12px; }
.raffle-winner-name { font-family: var(--font-hero); font-size: clamp(34px, 6vw, 62px); text-transform: uppercase; letter-spacing: 0.01em; line-height: 0.95; color: var(--text); word-break: break-word; animation: popCheck 0.4s cubic-bezier(.2,.8,.2,1) both; }
.raffle-draw { width: 100%; border: none; border-radius: 12px; background: var(--accent); color: var(--accent-ink); font-size: 16px; font-weight: 700; padding: 15px; letter-spacing: 0.01em; cursor: pointer; transition: background 0.2s, opacity 0.2s, transform 0.1s; }
.raffle-draw:hover:not(:disabled) { background: #2f5be0; }
.raffle-draw:active:not(:disabled) { transform: translateY(1px); }
.raffle-draw:disabled { opacity: 0.45; cursor: not-allowed; }
.raffle-count { margin-top: 12px; text-align: center; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.08em; color: var(--text-mute); }
.raffle-hist { margin-top: 32px; }
.raffle-hist-h { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-mute); margin-bottom: 12px; }
.raffle-hist-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 11px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-2); margin-bottom: 8px; }
.raffle-hist-name { font-size: 14.5px; font-weight: 600; color: var(--text); }
.raffle-hist-meta { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.04em; color: var(--text-mute); text-align: right; }
.raffle-empty { font-family: var(--font-mono); font-size: 11.5px; color: var(--text-mute); }
a.tb-signout { text-decoration: none; }
