/* ============================================================
   LES OMBRES DE CLICHY — Style Sheet
   Theme: WWII French Resistance · Mobile-first
   ============================================================ */

/* ---------- CSS Custom Properties ---------- */
:root {
  /* Palette */
  --clr-bg:        #1e1e16;
  --clr-bg-warm:   #2b2a1f;
  --clr-surface:   #3a3828;
  --clr-paper:     #f5f0e1;
  --clr-paper-alt: #eae3ce;
  --clr-ink:       #f7f2e4;
  --clr-ink-dim:   #d6cfb4;
  --clr-accent:    #c0392b;
  --clr-accent-light: #e74c3c;
  --clr-success:   #27ae60;
  --clr-warning:   #f39c12;
  --clr-nav-bg:    #1a2633;
  --clr-nav-accent:#3498db;

  /* Typography */
  --font-body:    'Special Elite', cursive;
  --font-heading: 'Merriweather', serif;

  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;

  /* Sizing */
  --max-width: 640px;
  --radius: 6px;
  --radius-lg: 12px;
}

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

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  background-color: var(--clr-bg);
  color: var(--clr-ink);
  line-height: 1.7;
  min-height: 100dvh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Subtle paper-grain texture overlay */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='100' height='100' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100' height='100' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 9999;
}

img { max-width: 100%; display: block; }
button { cursor: pointer; font-family: inherit; }
a { color: var(--clr-accent-light); }

/* ---------- Utility ---------- */
.hidden { display: none !important; }
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); border: 0;
}

/* ---------- Pages ---------- */
.page {
  display: none;
  min-height: 100dvh;
}
.page.active {
  display: flex;
  flex-direction: column;
  animation: fadeIn 0.4s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ============================================================
   WELCOME SCREEN
   ============================================================ */
.welcome-wrapper {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: var(--space-xl) var(--space-lg);
  text-align: center;
  max-width: var(--max-width);
  margin: 0 auto;
}

.welcome-emblem {
  width: clamp(2.5rem, 8vw, 3.8rem);
  height: auto;
  color: var(--clr-accent);
  margin-bottom: var(--space-sm);
  filter: drop-shadow(0 0 18px rgba(192,57,43,0.4));
  animation: pulse 3s ease-in-out infinite;
}
.welcome-emblem svg {
  width: 100%;
  height: auto;
  fill: currentColor;
  display: block;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50%      { transform: scale(1.05); opacity: 0.8; }
}

.welcome-title {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 7vw, 3.2rem);
  font-weight: 900;
  line-height: 1.15;
  letter-spacing: 0.02em;
  color: var(--clr-paper);
  margin-bottom: var(--space-sm);
}

.welcome-subtitle {
  font-size: clamp(0.95rem, 3vw, 1.15rem);
  color: var(--clr-ink-dim);
  font-style: italic;
  margin-bottom: var(--space-lg);
}

.welcome-divider {
  width: 60px;
  height: 2px;
  background: var(--clr-accent);
  margin: 0 auto var(--space-lg);
  border-radius: 1px;
}

.welcome-intro {
  font-size: clamp(0.9rem, 2.5vw, 1.05rem);
  max-width: 480px;
  color: var(--clr-ink-dim);
  margin-bottom: var(--space-xl);
  line-height: 1.8;
}
.welcome-intro strong {
  color: var(--clr-paper);
}

/* Resume prompt */
.resume-prompt {
  background: var(--clr-surface);
  border: 1px solid var(--clr-accent);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  margin-bottom: var(--space-lg);
  width: 100%;
  max-width: 400px;
}
.resume-prompt p {
  margin-bottom: var(--space-md);
  color: var(--clr-paper);
}
.resume-buttons {
  display: flex;
  gap: var(--space-md);
  justify-content: center;
}

/* Rules section */
.rules-section {
  width: 100%;
  max-width: 560px;
  margin-bottom: var(--space-lg);
}

.rules-title {
  font-family: var(--font-heading);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--clr-ink-dim);
  text-align: center;
  margin-bottom: var(--space-sm);
  letter-spacing: 0.3px;
}

.rules-grid {
  display: flex;
  flex-direction: column;
  border: 1px solid rgba(192, 57, 43, 0.25);
  border-radius: var(--radius);
  overflow: hidden;
}

/* Mobile : icône + titre sur la 1re ligne, description dessous */
.rule-card {
  display: grid;
  grid-template-columns: 1.6rem 1fr;
  grid-template-rows: auto auto;
  column-gap: var(--space-sm);
  row-gap: 1px;
  padding: 6px var(--space-md);
  background: var(--clr-surface);
  border-bottom: 1px solid rgba(255,255,255,0.04);
  transition: background 0.2s ease;
}

.rule-card:last-child {
  border-bottom: none;
}

.rule-card:nth-child(even) {
  background: var(--clr-bg-warm);
}

.rule-card:hover {
  background: rgba(192, 57, 43, 0.1);
}

.rule-icon {
  grid-column: 1;
  grid-row: 1;
  font-size: 0.95rem;
  line-height: 1.6;
  text-align: center;
}

.rule-card h3 {
  grid-column: 2;
  grid-row: 1;
  font-family: var(--font-heading);
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--clr-paper);
  line-height: 1.6;
}

.rule-card p {
  grid-column: 1 / -1;
  grid-row: 2;
  font-size: 0.78rem;
  color: var(--clr-ink-dim);
  line-height: 1.55;
  padding-left: calc(1.6rem + var(--space-sm));
}

/* Desktop : tout sur une seule ligne */
@media (min-width: 520px) {
  .rule-card {
    grid-template-columns: 1.6rem auto 1fr;
    grid-template-rows: auto;
    align-items: baseline;
  }

  .rule-card h3 {
    white-space: nowrap;
  }

  .rule-card p {
    grid-column: 3;
    grid-row: 1;
    padding-left: 0;
  }
}

.rule-card strong {
  color: var(--clr-accent-light);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: 0.75em 1.5em;
  border: 2px solid transparent;
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: clamp(0.9rem, 2.5vw, 1rem);
  text-decoration: none;
  transition: all 0.25s ease;
  -webkit-tap-highlight-color: transparent;
}

.btn-primary {
  background: var(--clr-accent);
  color: #fff;
  border-color: var(--clr-accent);
}
.btn-primary:hover, .btn-primary:focus-visible {
  background: var(--clr-accent-light);
  border-color: var(--clr-accent-light);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(192,57,43,0.35);
}
.btn-primary:active {
  transform: translateY(0);
}
.btn-primary:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.btn-secondary {
  background: transparent;
  color: var(--clr-ink-dim);
  border-color: var(--clr-ink-dim);
}
.btn-secondary:hover, .btn-secondary:focus-visible {
  color: var(--clr-paper);
  border-color: var(--clr-paper);
}

.btn-ghost {
  background: transparent;
  color: var(--clr-ink-dim);
  border: 1px dashed var(--clr-ink-dim);
  font-size: 0.85rem;
  padding: 0.5em 1em;
}
.btn-ghost:hover, .btn-ghost:focus-visible {
  color: var(--clr-paper);
  border-color: var(--clr-paper);
}

/* Hint action button */
.btn-hint-action {
  background: rgba(243,156,18,0.08);
  color: var(--clr-warning);
  border: 1px solid rgba(243,156,18,0.3);
  border-radius: var(--radius);
  padding: 0.65em 1.2em;
  font-size: 0.85rem;
  font-family: var(--font-body);
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
}
.btn-hint-action:hover:not(:disabled) {
  background: rgba(243,156,18,0.18);
  border-color: var(--clr-warning);
  transform: translateY(-1px);
}
.btn-hint-action:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Reveal action button */
.btn-reveal-action {
  background: rgba(240,234,214,0.05);
  color: var(--clr-ink-dim);
  border: 1px solid rgba(240,234,214,0.15);
  border-radius: var(--radius);
  padding: 0.65em 1.2em;
  font-size: 0.85rem;
  font-family: var(--font-body);
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
}
.btn-reveal-action:hover {
  background: rgba(240,234,214,0.1);
  border-color: rgba(240,234,214,0.3);
  transform: translateY(-1px);
}

/* Explanation button */
.btn-explanation {
  background: rgba(39,174,96,0.08);
  color: #6fdc9f;
  border: 1px solid rgba(39,174,96,0.3);
  border-radius: var(--radius);
  padding: 0.65em 1.2em;
  font-size: 0.85rem;
  font-family: var(--font-body);
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
  margin-top: var(--space-sm);
}
.btn-explanation:hover {
  background: rgba(39,174,96,0.18);
  border-color: var(--clr-success);
  transform: translateY(-1px);
}

.btn-cost {
  font-size: 0.75em;
  opacity: 0.6;
}

.btn-start {
  font-size: clamp(1rem, 3vw, 1.15rem);
  padding: 0.9em 2em;
  margin-top: var(--space-md);
  margin-bottom: var(--space-lg);
}

/* Add spacing below the restart button on the end screen so it
   doesn't sit flush against the footer */
#page-end .btn-start {
  margin-bottom: var(--space-xl);
}

.btn-icon {
  font-size: 0.8em;
}

/* ---------- Footer ---------- */
.welcome-footer {
  margin-top: auto;
  padding-top: var(--space-xl);
  padding-bottom: var(--space-sm);
  border-top: 1px solid rgba(240,234,214,0.12);
  font-size: 0.82rem;
  color: var(--clr-ink-dim);
  text-align: center;
  line-height: 1.8;
}
.welcome-footer a {
  color: var(--clr-ink-dim);
  text-decoration: underline;
  text-decoration-color: var(--clr-accent);
  text-underline-offset: 3px;
  font-weight: bold;
  transition: color 0.2s;
}
.welcome-footer a:hover {
  color: var(--clr-paper);
}
.footer-logo {
  display: block;
  margin: 0 auto var(--space-md);
  width: 120px;
  height: auto;
  opacity: 0.85;
  border-radius: 4px;
}

/* Game footer (abbreviated) */
.game-footer {
  text-align: center;
  font-size: 0.72rem;
  color: var(--clr-ink-dim);
  border-top: 1px solid rgba(240,234,214,0.08);
  padding: var(--space-sm) var(--space-md) var(--space-md);
  letter-spacing: 0.02em;
}
.game-footer a {
  color: var(--clr-ink-dim);
  text-decoration: underline;
  text-decoration-color: var(--clr-accent);
  text-underline-offset: 3px;
  font-weight: bold;
  transition: color 0.2s;
}
.game-footer a:hover {
  color: var(--clr-paper);
}

/* ============================================================
   GAME SCREEN
   ============================================================ */

/* --- Sticky Header --- */
.game-header {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
  padding: var(--space-sm) var(--space-md);
  background: rgba(30,30,22,0.95);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(240,234,214,0.08);
}

.header-stat {
  display: flex;
  align-items: center;
  gap: 0.3em;
  font-size: clamp(0.8rem, 2.5vw, 0.95rem);
  color: var(--clr-ink-dim);
  white-space: nowrap;
}
.header-icon {
  color: var(--clr-accent);
  font-size: 1em;
}

.header-progress {
  flex: 1;
  max-width: 200px;
  text-align: center;
}
#header-progress-text {
  font-size: 0.75rem;
  color: var(--clr-ink-dim);
  display: block;
  margin-bottom: 3px;
}
.progress-bar-track {
  height: 4px;
  background: var(--clr-surface);
  border-radius: 2px;
  overflow: hidden;
}
.progress-bar-fill {
  height: 100%;
  background: var(--clr-accent);
  border-radius: 2px;
  transition: width 0.5s ease;
}

/* --- Game Content Area --- */
.game-content {
  flex: 1;
  padding: var(--space-lg) var(--space-md);
  max-width: var(--max-width);
  margin: 0 auto;
  width: 100%;
  animation: slideUp 0.35s ease;
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* --- Step Card --- */
.step-card {
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  margin-bottom: var(--space-md);
}

/* Type badge */
.step-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
  font-size: 0.7rem;
  font-family: var(--font-body);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 0.3em 0.8em;
  border-radius: 50px;
  margin-bottom: var(--space-md);
}

.step-point-label {
  font-size: 0.7rem;
  color: var(--clr-ink-dim);
  margin-bottom: var(--space-xs);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.step-title {
  font-family: var(--font-heading);
  font-size: clamp(1.25rem, 4vw, 1.6rem);
  font-weight: 700;
  margin-bottom: var(--space-md);
  line-height: 1.3;
}

.step-body {
  font-size: clamp(0.9rem, 2.5vw, 1rem);
  line-height: 1.85;
  white-space: pre-line;
}
.step-body strong {
  color: var(--clr-paper);
}
.step-body em {
  color: #c8c0a4;
}

/* ---------- STORY Card ---------- */
.step-card--story {
  background: linear-gradient(135deg, #3a3520 0%, #2e2d1f 100%);
  border-left: 4px solid var(--clr-warning);
}
.step-card--story .step-badge {
  background: rgba(243,156,18,0.15);
  color: var(--clr-warning);
  border: 1px solid rgba(243,156,18,0.3);
}
.step-card--story .step-title {
  color: var(--clr-paper);
}

/* ---------- NAVIGATION Card ---------- */
.step-card--navigation {
  background: linear-gradient(135deg, var(--clr-nav-bg) 0%, #1a2030 100%);
  border-left: 4px solid var(--clr-nav-accent);
}
.step-card--navigation .step-badge {
  background: rgba(52,152,219,0.15);
  color: var(--clr-nav-accent);
  border: 1px solid rgba(52,152,219,0.3);
}
.step-card--navigation .step-title {
  color: #cce5ff;
}
.step-card--navigation .step-body {
  color: #d0e6f8;
}
.step-card--navigation .step-body strong {
  color: #edf5ff;
}

/* ---------- QUESTION Card ---------- */
.step-card--question {
  background: linear-gradient(135deg, #3a2020 0%, #2e1f1f 100%);
  border-left: 4px solid var(--clr-accent);
}
.step-card--question .step-badge {
  background: rgba(192,57,43,0.15);
  color: var(--clr-accent-light);
  border: 1px solid rgba(192,57,43,0.3);
}
.step-card--question .step-title {
  color: var(--clr-paper);
}

/* --- Question zone --- */
.question-text {
  font-family: var(--font-heading);
  font-size: clamp(1rem, 3vw, 1.15rem);
  font-weight: 700;
  color: var(--clr-paper);
  background: rgba(0,0,0,0.2);
  padding: var(--space-md);
  border-radius: var(--radius);
  margin: var(--space-md) 0;
  line-height: 1.5;
  border: 1px solid rgba(192,57,43,0.2);
}

.answer-form {
  display: flex;
  gap: var(--space-sm);
  margin-top: var(--space-md);
}

.answer-input {
  flex: 1;
  padding: 0.7em 1em;
  font-family: var(--font-body);
  font-size: 1rem;
  background: rgba(0,0,0,0.3);
  color: var(--clr-paper);
  border: 2px solid var(--clr-surface);
  border-radius: var(--radius);
  outline: none;
  transition: border-color 0.2s;
}
.answer-input:focus {
  border-color: var(--clr-accent);
}
.answer-input:disabled {
  opacity: 0.5;
}
.answer-input::placeholder {
  color: var(--clr-ink-dim);
  opacity: 0.5;
}

.btn-submit {
  padding: 0.7em 1.2em;
  background: var(--clr-accent);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: 1rem;
  transition: background 0.2s;
}
.btn-submit:hover { background: var(--clr-accent-light); }
.btn-submit:disabled { opacity: 0.4; cursor: not-allowed; }

/* --- Feedback --- */
.feedback {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-md);
  border-radius: var(--radius);
  margin-top: var(--space-md);
  font-size: 0.95rem;
  animation: popIn 0.3s ease;
}

@keyframes popIn {
  from { opacity: 0; transform: scale(0.95); }
  to   { opacity: 1; transform: scale(1); }
}

.feedback--correct {
  background: rgba(39,174,96,0.15);
  border: 1px solid rgba(39,174,96,0.3);
  color: #6fdc9f;
}
.feedback--incorrect {
  background: rgba(192,57,43,0.15);
  border: 1px solid rgba(192,57,43,0.3);
  color: #e88;
}
.feedback--revealed {
  background: rgba(243,156,18,0.12);
  border: 1px solid rgba(243,156,18,0.25);
  color: var(--clr-warning);
}

.feedback-icon {
  font-size: 1.3rem;
  flex-shrink: 0;
}

/* --- Question action buttons (hint, reveal) --- */
.question-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  margin-top: var(--space-md);
}

/* --- Hint box --- */
.hint-box {
  background: rgba(243,156,18,0.1);
  border: 1px dashed var(--clr-warning);
  border-radius: var(--radius);
  padding: var(--space-md);
  margin-top: var(--space-md);
  color: var(--clr-warning);
  font-size: 0.9rem;
  animation: popIn 0.3s ease;
}
.hint-box::before {
  content: '💡 Indice : ';
  font-weight: bold;
}

/* --- Explanation box --- */
.explanation-box {
  background: rgba(39,174,96,0.08);
  border: 1px solid rgba(39,174,96,0.2);
  border-radius: var(--radius);
  padding: var(--space-md);
  margin-top: var(--space-md);
  color: #a5d6b8;
  font-size: 0.9rem;
  line-height: 1.7;
  animation: popIn 0.3s ease;
}
.explanation-box strong {
  color: #6fdc9f;
}
.explanation-box::before {
  content: '📖 Explication : ';
  font-weight: bold;
  display: block;
  margin-bottom: var(--space-xs);
  color: #6fdc9f;
}

/* --- Points indicator --- */
.points-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3em;
  font-size: 0.75rem;
  color: var(--clr-ink-dim);
  margin-top: var(--space-sm);
}
.points-badge--earned {
  color: var(--clr-success);
}
.points-badge--half {
  color: var(--clr-warning);
}
.points-badge--zero {
  color: var(--clr-accent-light);
}

/* --- Game Nav --- */
.game-nav {
  display: flex;
  justify-content: space-between;
  gap: var(--space-md);
  padding: var(--space-md);
  max-width: var(--max-width);
  margin: 0 auto;
  width: 100%;
  padding-bottom: calc(var(--space-md) + env(safe-area-inset-bottom, 0px));
}

.btn-nav {
  flex: 1;
  max-width: 180px;
}
.btn-nav:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

/* Finish button animation */
.btn-finish-pulse {
  animation: finishPulse 1.6s ease-in-out infinite;
  font-size: clamp(1rem, 3.2vw, 1.2rem);
  padding: 1em 2em;
  letter-spacing: 0.04em;
  width: 100%;
  max-width: 320px;
}
@keyframes finishPulse {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(192,57,43,0.6),
                0 4px 24px rgba(192,57,43,0.25);
    transform: scale(1);
  }
  50% {
    box-shadow: 0 0 0 12px rgba(192,57,43,0),
                0 4px 32px rgba(192,57,43,0.45);
    transform: scale(1.03);
  }
}

/* ============================================================
   END SCREEN
   ============================================================ */
.end-wrapper {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: var(--space-xl) var(--space-lg);
  text-align: center;
  max-width: var(--max-width);
  margin: 0 auto;
}

.end-emblem {
  width: clamp(2rem, 6vw, 3rem);
  height: auto;
  color: var(--clr-success);
  margin-bottom: var(--space-md);
  filter: drop-shadow(0 0 14px rgba(39,174,96,0.35));
}
.end-emblem svg {
  width: 100%;
  height: auto;
  fill: currentColor;
  display: block;
}

.end-title {
  font-family: var(--font-heading);
  font-size: clamp(1.5rem, 5vw, 2.2rem);
  font-weight: 900;
  color: var(--clr-paper);
  margin-bottom: var(--space-xl);
}

.end-stats {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-lg);
  margin-bottom: var(--space-xl);
  flex-wrap: wrap;
}

.end-stat {
  text-align: center;
}
.end-stat-value {
  display: block;
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 6vw, 2.5rem);
  font-weight: 900;
  color: var(--clr-paper);
}
.end-stat-label {
  font-size: 0.75rem;
  color: var(--clr-ink-dim);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.end-stat-divider {
  width: 1px;
  height: 40px;
  background: var(--clr-surface);
}

/* --- Recap --- */
.end-recap {
  width: 100%;
  margin-bottom: var(--space-xl);
  text-align: left;
}

.recap-row {
  display: flex;
  align-items: flex-start;
  gap: var(--space-md);
  padding: var(--space-md) 0;
  border-bottom: 1px solid rgba(240,234,214,0.06);
}
.recap-row:last-child { border-bottom: none; }

.recap-icon {
  font-size: 1.2rem;
  flex-shrink: 0;
  margin-top: 2px;
}

.recap-details {
  flex: 1;
  min-width: 0;
}

.recap-question {
  font-size: 0.85rem;
  color: var(--clr-paper);
  margin-bottom: 2px;
}

.recap-answer {
  font-size: 0.8rem;
  color: var(--clr-ink-dim);
}

.recap-meta {
  font-size: 0.7rem;
  color: var(--clr-ink-dim);
  opacity: 0.6;
  margin-top: 2px;
}

.recap-points {
  font-size: 0.8rem;
  white-space: nowrap;
  flex-shrink: 0;
}
.recap-points--full { color: var(--clr-success); }
.recap-points--half { color: var(--clr-warning); }
.recap-points--zero { color: var(--clr-accent-light); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 480px) {
  :root {
    --space-lg: 1.2rem;
    --space-xl: 1.5rem;
  }

  .game-header {
    padding: var(--space-xs) var(--space-sm);
  }

  .step-card {
    padding: var(--space-md);
    border-radius: var(--radius);
  }

  .answer-form {
    flex-direction: column;
  }

  .btn-submit {
    width: 100%;
  }

  .end-stats {
    gap: var(--space-md);
  }

  .end-stat-divider {
    display: none;
  }
}

@media (min-width: 768px) {
  .game-content {
    padding: var(--space-xl) var(--space-lg);
  }

  .step-card {
    padding: var(--space-xl);
  }
}

/* ---------- Focus styles for accessibility ---------- */
:focus-visible {
  outline: 2px solid var(--clr-accent);
  outline-offset: 2px;
}

/* ---------- Selection ---------- */
::selection {
  background: var(--clr-accent);
  color: #fff;
}

/* ---------- Scrollbar (subtle) ---------- */
::-webkit-scrollbar {
  width: 6px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: var(--clr-surface);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--clr-ink-dim);
}
