/* @import MUST precede all other rules (CSS spec) — tokens + components
    are the foundation everything below references. */
@import url("../../design/tokens.css");
@import url("../../design/components/buttons.css");
@import url("../../design/components/cards.css");
@import url("../../design/components/badges.css");
@import url("../../design/components/stats.css");
@import url("../../design/components/forms.css");
@import url("../../design/components/rows.css");

/* ── Canvas FX palette (DS-12 theme family) ─────────────────────────────
   Surface aliases composed ONLY from system tokens — themes re-skin the
   game canvas (game.js reads these via getComputedStyle in fxColor())
   with no surface or theme edits. win/loss map to the win/loss semantics;
   info maps to the rare-tier indigo (purge/strike cues, a cool signal
   distinct from the accent). */
:root {
    --fx-win:  var(--accent);
    --fx-loss: var(--loss);
    --fx-info: var(--tier-rare);

    /* Gameplay boards (DS-12 family): token KEYS resolved at draw time by
       modes/palette.js — board state stores keys, never pixels, so theme
       switches re-skin every canvas with zero JS edits. Composed only from
       system tokens (win/loss/tier ramp + the L1 gameplay categorical raws). */
    --pk-i:      var(--color-cyan);
    --pk-o:      var(--tier-legendary);
    --pk-t:      var(--tier-epic);
    --pk-l:      var(--color-orange);
    --pk-j:      var(--win);
    --pk-s:      var(--loss);
    --pk-z:      var(--color-sky);
    --pk-g:      var(--color-red-deep);
    --pk-win:    var(--win);
    --pk-danger: var(--loss);
    --pk-cyan:   var(--color-cyan);
    --pk-violet: var(--tier-epic);
    --pk-amber:  var(--tier-legendary);
    --pk-orange: var(--color-orange);
    --pk-gold:   var(--tier-legendary);
    --pk-cursed: var(--color-sky);
    --pk-slow:   var(--text-muted);
    --pk-muted:  var(--text-muted);
    --pk-dim:    var(--text-dim);
    --pk-text:   var(--text);
    --board-bg:  var(--bg-deep);
}

/* ── Skip Link for Accessibility ─────────────────────────────────────────── */
.skip-link {
    position: absolute;
    top: -100px;
    left: 50%;
    transform: translateX(-50%);
    padding: 12px 24px;
    background: var(--bg-card);
    color: var(--text);
    border-radius: var(--radius-md);
    font-weight: 600;
    z-index: 1000;
    transition: top 0.2s ease;
}
.skip-link:focus {
    top: 12px;
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* Vendored MIT pixel font (copy-best: TakWolf/ark-pixel-font — the arcade
    display voice; falls back to system fonts if the woff2 fails to load). */
@font-face {
    font-family: 'Ark Pixel';
    src: url('fonts/ark-pixel-10-proportional.woff2') format('woff2');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

/* ── Reset & Base ─────────────────────────────────────────── */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}


body {
    font-family: var(--font-body);
    background: var(--bg-deep);
    color: var(--text);
    min-height: 100vh;
    padding: var(--space-md);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

/* ── Background Mesh ─────────────────────────────────────── */
.bg-mesh {
    position: fixed;
    inset: 0;
    z-index: -1;
    background:
        radial-gradient(ellipse 80% 60% at 20% 10%, var(--color-glow-green-08) 0%, transparent 60%),
        radial-gradient(ellipse 60% 50% at 80% 90%, var(--color-indigo-glow-06) 0%, transparent 60%),
        radial-gradient(ellipse 50% 40% at 50% 50%, var(--color-amber-glow-04) 0%, transparent 50%);
    pointer-events: none;
}

/* ── Game Container ──────────────────────────────────────── */
.game-container {
    max-width: 560px;
    margin: 0 auto;
    overflow: hidden;
}

/* ── Shell chrome (DS-12 family: no one-off inline styles) ───────────────
   Challenge banner + dismiss + effects toggle used to carry inline
   layout literals; they now consume the house spacing tokens so a family
   theme switch re-skins them like everything else. */
#challenge-banner {
    margin: var(--space-sm);
    padding: var(--space-sm);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#challenge-dismiss {
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
}

#juice-toggle {
    margin-left: var(--space-sm);
}

/* ── Header ──────────────────────────────────────────────── */
header {
    padding: var(--space-lg) var(--space-lg) var(--space-md);
    text-align: center;
    border-bottom: 1px solid var(--border);
    background: linear-gradient(180deg, var(--color-glow-green-06) 0%, transparent 100%);
}

.header-top {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-sm);
    flex-wrap: wrap;
}

header h1 {
    font-family: var(--font-display);
    font-size: 1.6rem;
    font-weight: 700;
    letter-spacing: -.02em;
    color: var(--text);
}

/* ── Stats Panel ─────────────────────────────────────────── */
.stats-panel {
    display: flex;
    justify-content: space-around;
    padding: var(--space-md) var(--space-lg);
    background: var(--bg-card-alt);
    border-bottom: 1px solid var(--border);
}


.streak-icon {
    font-size: 1.1rem;
    margin-left: 4px;
    transition: transform .3s var(--ease);
}

/* ── Game Area ───────────────────────────────────────────── */
.game-area {
    padding: var(--space-xl) var(--space-lg) var(--space-lg);
    text-align: center;
}

/* ── Skill Match panel (Phase 0: coin flip removed — luck contradicts the
      "Skill pays" thesis; this is the honest tournament surface) ──────── */
.skill-panel {
    max-width: 480px;
    margin: 0 auto;
    padding: var(--space-lg);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    background: var(--bg-card);
}

.skill-title {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: var(--space-sm);
}

.skill-desc {
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: var(--space-lg);
}

.skill-cta {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-sm);
}

/* ── Mode selector + game canvas (Phase 0 game build) ─────────────────── */
.mode-selector {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-xs);
    justify-content: center;
    margin-bottom: var(--space-md);
}

.mode-btn {
    padding: 6px 14px;
    border: 1px solid var(--border-default);
    border-radius: var(--radius-sm);
    background: var(--bg-card-alt);
    color: var(--text-secondary);
    font-size: .85rem;
    font-weight: 600;
    cursor: pointer;
    transition: background .15s var(--ease), color .15s var(--ease), border-color .15s var(--ease);
}
.mode-btn:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 2px;
}

.mode-btn--active {
    background: var(--accent);
    color: var(--bg-deep);
    border-color: var(--accent);
}

.game-canvas {
    width: 100%;
    max-width: 460px;
    height: auto;
    aspect-ratio: 8 / 9;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-default);
    background: var(--bg-deep);
    margin: 0 auto var(--space-md);
    display: block;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

/* ── Board duo: player board + adversary ghost panel (Phase 0) ─────────── */
.board-duo {
    display: flex;
    gap: var(--space-sm);
    justify-content: center;
    align-items: flex-start;
    margin: 0 auto var(--space-md);
    max-width: 760px;
}

.board-duo .game-canvas {
    flex: 0 1 auto;
    /* Default board: the 320x360 (8:9) bitmap every mode except Blocks uses.
       The tall 8/17 column is opt-in via .board-duo--tall (set by the shell
       when Blocks is selected) — the old fixed 8/17 aspect stretched the
       other modes' boards and circles. */
    height: auto;
    width: 100%;
    max-width: 520px;
    margin: 0;
    aspect-ratio: 8 / 9;
}

.board-duo--tall .game-canvas {
    /* Blocks: the board is a 10-wide x 20-row field plus a 3-cell preview
       strip -> a 10/23 bitmap. Width derives from that aspect so the tall
       board fills the screen height at Guideline proportions (defect 09-09:
       the old 8-col board drew cells ~2x too large for the field). */
    height: min(84vh, 820px);
    width: auto;
    max-width: 520px;
    aspect-ratio: 10 / 23;
}

.ghost-canvas {
    flex: 0 0 150px;
    width: 150px;
    height: auto;
    aspect-ratio: 4 / 9;
    border-radius: var(--radius-sm, 8px);
    border: 1px solid var(--color-loss-glow-30);
    background: var(--bg-deep);
    display: block;
    touch-action: none;
}

@media (max-width: 480px) {
    .board-duo { gap: var(--space-xs); }
    .ghost-canvas { flex-basis: 96px; width: 96px; }
    .board-duo .game-canvas { max-width: 100%; }
    /* Blocks on a phone: width-drive the tall board (viewport minus the
       96px adversary panel + gap) so 10 columns stay visible and reachable. */
    .board-duo--tall .game-canvas {
        height: auto;
        width: 100%;
        max-width: calc(100vw - 130px);
        aspect-ratio: 10 / 23;
    }
}

/* ── Touch controls (Blocks) — real buttons, not invisible zones ───────── */
.ctrl-bar {
    display: flex;
    gap: var(--space-sm);
    justify-content: center;
    margin: 0 auto var(--space-md);
    max-width: 320px;
}

.ctrl-btn {
    flex: 1 1 0;
    padding: 14px 0;
    font-size: 1.3rem;
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    background: var(--bg-card-alt);
    color: var(--text-primary);
    cursor: pointer;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
    transition: background .1s var(--ease), transform .05s var(--ease);
}
.ctrl-btn:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 2px;
}

.ctrl-btn:active {
    background: var(--accent);
    color: var(--bg-deep);
    transform: scale(.95);
}

/* ── Ceremony overlay (round intro / elimination / match verdict) ──────── */
.ceremony {
    position: fixed;
    inset: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-scrim-82);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    animation: ceremony-fade .18s ease-out;
}

.ceremony-card {
    text-align: center;
    padding: var(--space-xl);
    max-width: 340px;
    width: 90%;
}

.ceremony-kicker {
    font-size: .8rem;
    font-weight: 700;
    letter-spacing: .18em;
    color: var(--accent);
    text-transform: uppercase;
    margin-bottom: var(--space-sm);
}

.ceremony-title {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: var(--space-sm);
    line-height: 1.25;
}

.ceremony-sub {
    font-size: .95rem;
    color: var(--text-secondary);
    margin-bottom: var(--space-lg);
}

/* Round title animation */
.ceremony-title.animate-round {
    animation: round-title-anim 0.4s ease-out;
}
@keyframes round-title-anim {
    from { opacity: 0; transform: scale(0.8); }
    to { opacity: 1; transform: scale(1); }
}

/* Ghost attack anticipation cue */
.attack-anticipation {
    box-shadow: 0 0 0 4px var(--loss) inset;
    transition: box-shadow 0.4s ease-out;
}

.ceremony-bar {
    height: 4px;
    border-radius: 2px;
    background: var(--border-default);
    overflow: hidden;
}

.ceremony-bar-inner {
    height: 100%;
    width: 0%;
    background: var(--accent);
    transition: width .05s linear;
}

@keyframes ceremony-fade {
    from { opacity: 0; }
    to { opacity: 1; }
}

.ceremony.ceremony--danger .ceremony-kicker { color: var(--loss); }
.ceremony.ceremony--danger .ceremony-bar-inner { background: var(--loss); }

/* ── Countdown overlay (ready → 3‑2‑1) ─────────────────────────────────────── */
.countdown-overlay {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-scrim-82);
  backdrop-filter: blur(4px);
}
#countdown-text {
  font-family: var(--font-display);
  font-size: 3rem;
  font-weight: 700;
  color: var(--accent);
}

.skill-note {
    font-size: .85rem;
    color: var(--text-muted);
}

/* ── Reaction-timing game controls (Phase 0) ─────────────────────────── */
.btn-go {
    min-width: 220px;
    font-size: 1.15rem;
    letter-spacing: .04em;
    transition: transform .15s var(--ease), background .15s var(--ease);
}
.btn-go:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 2px;
}

.btn-go.go-hot {
    background: var(--accent);
    color: var(--bg-deep);
    transform: scale(1.06);
    animation: pulse-cue .5s ease-in-out infinite alternate;
}

@keyframes pulse-cue {
    from { box-shadow: 0 0 0 0 var(--color-glow-green-4); }
    to   { box-shadow: 0 0 0 14px transparent; }
}

.btn-go:disabled {
    opacity: .75;
    cursor: not-allowed;
    transform: none;
}
#juice-toggle:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 2px;
}

.skill-round {
    font-size: .9rem;
    font-weight: 600;
    color: var(--text-secondary);
    min-height: 1.2em;
}

.rank-result {
    margin-top: var(--space-md);
    padding: var(--space-md);
    border-top: 1px solid var(--border-default);
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
}

.rank-line {
    font-size: .95rem;
    color: var(--text-secondary);
}

.rank-line strong {
    color: var(--text-primary);
}

/* ── Live BR HUD ─────────────────────────────────────── */
 .hud {
   position: absolute;
   top: var(--space-sm);
   right: var(--space-sm);
   background: var(--bg-card-alt);
   padding: var(--space-xs) var(--space-sm);
   border-radius: var(--radius-sm);
   font-size: .85rem;
   color: var(--text-primary);
   z-index: 30;
   /* Jank fix: the HUD crammed a dozen labels (FIELD/RANK/AVG/BEST/STREAK/
      SPS/FLOW/PERFECT/ACC/combo/b2b/attack) onto one unbroken line. Wrap
      them with consistent gaps; empty spans already collapse via JS
      textContent=''. */
   display: flex;
   flex-wrap: wrap;
   align-items: center;
   gap: 0 .75rem;
   max-width: min(92vw, 560px);
 }

 /* HUD badges (DS-12 family): semantic tokens instead of inline hex, so
    themes re-skin them. attack matches game.js's runtime fxColor('loss')
    INCOMING cue; shield takes the rare-tier indigo (the cool signal). */
 #hud-attack {
   position: relative;
   color: var(--loss);
 }

 #hud-shield {
   color: var(--tier-rare);
   margin-left: var(--space-sm);
 }
 
 /* ── Field feed (BR illusion) ────────────────────────────────────── */
 .qp-field-feed {
   position: absolute;
   top: calc(var(--space-sm) + 30px); /* below HUD */
   right: var(--space-sm);
   width: 200px;
   max-height: 60px;
   overflow: hidden;
   font-size: .75rem;
   line-height: 1.2;
   color: var(--text-secondary);
   z-index: 30;
   pointer-events: none;
 }
 
 .qp-field-feed .feed-line {
   opacity: 1;
   animation: feed-fade 4s forwards;
 }
 
 @keyframes feed-fade {
   0% { opacity: 1; }
   80% { opacity: 1; }
   100% { opacity: 0; transform: translateY(-0.5rem); }
 }

/* ── Coin ────────────────────────────────────────────────── */
.coin-container {
    margin-bottom: var(--space-xl);
    position: relative;
}

.coin-container::after {
    content: '';
    position: absolute;
    bottom: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 8px;
    background: radial-gradient(ellipse, var(--accent-glow) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.coin {
    width: 140px;
    height: 140px;
    margin: 0 auto var(--space-md);
    perspective: 800px;
    cursor: pointer;
}

.coin.flipping {
    animation: flip 1s ease-in-out infinite;
}

@keyframes flip {
    0%   { transform: rotateY(0); }
    100% { transform: rotateY(360deg); }
}

/* Vestibular safety (WCAG 2.3.3): users who request reduced motion get a
   static, non-animated experience — no flip/ceremony/pulse/flash loops. */
 @media (prefers-reduced-motion: reduce) {
    .coin.flipping,
    .ceremony,
    .pulse-cue,
    .flash-win,
    .flash-loss,
    *[class*="animate"] {
        animation: none !important;
        transition: none !important;
    }
}

.coin .side {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    color: var(--bg-deep);
    box-shadow:
        0 8px 32px var(--color-glow-green-18),
        0 0 0 3px var(--color-glow-green-12),
        inset 0 2px 8px var(--color-white-15);
}

.coin .side-front {
    background: linear-gradient(145deg, var(--color-accent) 0%, var(--color-accent-deep) 100%);
    transform: rotateY(0deg);
    font-size: 2.6rem;
    letter-spacing: .04em;
}

.coin .side-back {
    background: linear-gradient(145deg, var(--color-indigo) 0%, var(--color-indigo-deep) 100%);
    transform: rotateY(180deg);
    font-size: 1.1rem;
    letter-spacing: .12em;
}

.coin-label {
    font-size: .92rem;
    color: var(--text-dim);
    font-weight: 500;
    min-height: 1.4em;
}

/* ── Bet Controls ────────────────────────────────────────── */
.bet-controls {
    margin-top: var(--space-md);
}



/* ── Radio Cards ─────────────────────────────────────────── */
.radio-group {
    display: flex;
    gap: var(--space-sm);
}

.radio-card {
    flex: 1;
    cursor: pointer;
}

.radio-card input {
    display: none;
}

.radio-card-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 12px 8px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--bg-card-alt);
    transition: all .2s var(--ease);
}

.radio-label {
    font-size: .85rem;
    font-weight: 600;
    color: var(--text);
}

.radio-sub {
    font-size: .72rem;
    color: var(--text-muted);
    margin-top: 2px;
}

.radio-card input:checked + .radio-card-inner {
    border-color: var(--accent);
    background: var(--color-glow-green-08);
    box-shadow: 0 0 0 1px var(--accent-glow);
}

.radio-card input:checked + .radio-card-inner .radio-label {
    color: var(--accent);
}

.btn-primary {
    outline: 2px solid currentColor;
    outline-offset: 2px;
}

/* ── History Panel ───────────────────────────────────────── */
.history-panel {
    padding: var(--space-lg);
    background: var(--bg-card-alt);
    border-top: 1px solid var(--border);
}

.history-panel h3 {
    font-size: .78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: var(--text-muted);
    margin-bottom: var(--space-md);
}

.history-list {
    max-height: 220px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--border) transparent;
}

.history-list::-webkit-scrollbar {
    width: 4px;
}

.history-list::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 4px;
}

.history-content {
    display: flex;
    gap: var(--space-md);
    align-items: center;
}

.result {
    font-weight: 600;
    color: var(--text);
}

.amount {
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.row--win .amount {
    color: var(--win);
}

.row--loss .amount {
    color: var(--loss);
}

.time {
    font-size: .75rem;
    color: var(--text-muted);
}


.history-item.empty {
    text-align: center;
    color: var(--text-muted);
    background: transparent;
    border: none;
    border-left: none;
    font-style: italic;
    font-size: .82rem;
}

/* ── Ad Banner ───────────────────────────────────────────── */
.ad-banner {
    padding: var(--space-lg);
    background: linear-gradient(135deg, var(--color-slate) 0%, var(--color-bg-card-alt) 100%);
    color: var(--text-dim);
    text-align: center;
    border-top: 1px solid var(--border);
}

.ad-label {
    display: inline-block;
    font-size: .68rem;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--text-muted);
    background: var(--color-gray-muted-15);
    padding: 3px 10px;
    border-radius: var(--radius-full);
    margin-bottom: var(--space-sm);
}

.ad-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-sm);
}

.ad-content p {
    font-size: .95rem;
    margin: 0;
    color: var(--text-dim);
}


/* ── Mobile ──────────────────────────────────────────────── */
@media (max-width: 480px) {
    body {
        padding: 0;
    }

    .game-container {
        border-radius: 0;
        min-height: 100vh;
        box-shadow: none;
    }

    header {
        padding: var(--space-md);
    }

    header h1 {
        font-size: 1.3rem;
    }

    .game-area {
        padding: var(--space-lg) var(--space-md);
    }

    .coin {
        width: 100px;
        height: 100px;
    }

    .coin .side-front {
        font-size: 1.8rem;
    }

    .coin .side-back {
        font-size: .85rem;
    }

    .stats-panel {
        padding: var(--space-sm) var(--space-md);
    }

        .history-panel {
        padding: var(--space-md);
    }
}

/* ── Win / Loss flash ────────────────────────────────────── */
.flash-win {
    animation: flashGreen .6s ease;
}

.flash-loss {
    animation: flashRed .6s ease;
}

@keyframes flashGreen {
    0%, 100% { background: var(--bg-card); }
    30%      { background: var(--color-glow-green-12); }
}

@keyframes flashRed {
    0%, 100% { background: var(--bg-card); }
    30%      { background: var(--color-loss-glow-10); }
}

/* ── Win screen (share moment, C5) ─────────────────────────── */
.hidden {
    display: none !important;
}

.win-screen {
    position: fixed;
    inset: 0;
    z-index: 20;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-scrim-82);
    backdrop-filter: blur(4px);
    padding: var(--space-md);
}

.win-screen-card {
    border-top: 2px solid var(--accent);
    box-shadow: var(--shadow-lg), 0 0 0 1px var(--accent-glow) inset;
    max-width: 400px;
    width: 100%;
    text-align: center;
}

.win-screen-card h2 {
    font-family: var(--font-display);
    font-size: 1.8rem;
    color: var(--win);
    margin-bottom: var(--space-xs);
}

.win-amount {
    font-size: 2rem;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    color: var(--text);
    margin-bottom: var(--space-md);
}

.win-breakdown {
    font-size: .85rem;
    color: var(--text-dim);
    font-variant-numeric: tabular-nums;
    margin-bottom: var(--space-md);
}

.win-share-text {
    font-size: .9rem;
    color: var(--text-dim);
    line-height: 1.5;
    margin-bottom: var(--space-lg);
}

.win-actions {
    display: flex;
    gap: var(--space-sm);
}

.win-actions .btn-primary {
    margin-top: 0;
    flex: 1;
}

.win-actions .btn-control {
    flex: 1;
}

@media (max-width: 480px) {
    .win-actions {
        flex-direction: column;
    }
}
/* ── Rewarded-ad overlay (simulated sponsored break) ─────────────────── */
.qp-ad-overlay{position:fixed;inset:0;background:var(--color-scrim-94);z-index:9999;display:flex;align-items:center;justify-content:center;}
.qp-ad-card{text-align:center;padding:2rem 3rem;border:1px solid var(--border);border-radius:var(--radius-lg);background:var(--bg-card);box-shadow:var(--shadow-lg);}
.qp-ad-label{font-size:.75rem;letter-spacing:.12em;color:var(--text-dim);margin-bottom:.75rem;}
.qp-ad-count{font-size:3rem;font-weight:800;color:var(--accent);}
.qp-ad-bar{width:220px;height:6px;background:var(--bg-input);border-radius:3px;margin:1rem auto;overflow:hidden;}
.qp-ad-bar-fill{height:100%;width:0;background:var(--accent);transition:width 1s linear;}
.qp-ad-sub{font-size:.8rem;color:var(--text-muted);}

/* ── Match lock: mode tabs disabled during a live match ──────────────── */
.mode-btn[aria-disabled="true"]{opacity:.45;pointer-events:none;}
