/* Chunking Chopper — division split-dividend ("chunking") Habit-Breaker.
   Layered on top of math-rounds.css + number_bonds.css (mode badge, ladder,
   band, lesson carousel, keypad reused). The interaction itself is the
   UNIFIED step-entry pattern (`.hb-steps`, TRAINER_UNIFICATION_SPEC §A) which
   lives in math-rounds.css — this file only keeps the trainer-local extras:
   the speed ghost, the per-level mastery bar, and the boss badge. */

/* ── Mobile no-scroll compaction (spec §A NO-SCROLL RULE) ──
   At 390×844 the problem + current step + keypad must ALL fit with zero
   scrolling (the reference page overflowed by ~100px — caught by the
   equal_addition replicator's viewport assertion). Scoped via .hb-compact
   on .math-rounds-container; desktop untouched. */
@media (max-width: 480px) {
  .hb-compact { margin: 8px auto; }
  .hb-compact .math-rounds-header { margin-bottom: 6px; }
  .hb-compact .math-rounds-header h1 { font-size: 1.15rem; }
  .hb-compact .subtitle { font-size: 0.78rem; margin: 2px 0 0; }
  .hb-compact #game-panel { padding: 10px 12px; }
  .hb-compact .nb-ladder { margin-bottom: 4px; }
  .hb-compact .nb-band { font-size: 0.78rem; margin-bottom: 4px; }
  .hb-compact .hud { margin-bottom: 6px; font-size: 0.82rem; }
  .hb-compact .question-box { gap: 8px; }
  .hb-compact .question { font-size: 1.7rem; margin: 0; }
  .hb-compact .hb-steps { margin: 4px auto 0; gap: 8px; }
  .hb-compact .cc-meta { margin-top: 0; }
  .hb-compact .cc-mastery { margin: 4px auto 0; }
  .hb-compact .keypad { gap: 6px; margin-top: 2px; }
  .hb-compact .keypad button { padding: 9px; font-size: 1.1rem; border-radius: 10px; }
}

/* ── Speed ghost + mastery bar ── */
.cc-meta {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin: 10px auto 2px;
    font-size: 0.78rem;
    color: var(--faint, #6b7799);
}
.cc-ghost.beat { color: var(--accent-bright, #34d399); }

.cc-mastery {
    width: 100%;
    max-width: 280px;
    height: 8px;
    margin: 6px auto 2px;
    border-radius: 6px;
    background: var(--surface2, #15291f);
    border: 1px solid var(--border, rgba(255, 255, 255, 0.09));
    overflow: hidden;
}
.cc-mastery-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg,
        color-mix(in srgb, var(--accent, #10b981) 70%, transparent),
        var(--teal, #2dd4bf));
    transition: width 0.3s ease;
}

/* Boss banner */
.cc-boss-badge {
    display: inline-block;
    margin-left: 8px;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    color: #0c1a13;
    background: var(--teal, #2dd4bf);
}
