/* ── Title Screen ────────────────────────────────────────────────────────── */
.title-screen {
  position: fixed;
  inset: 0;
  background: radial-gradient(ellipse at top, #1a1a2e 0%, #0a0a0f 60%);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 500;
  opacity: 1;
  transition: opacity 0.5s ease, transform 0.5s ease;
  overflow: hidden;
}

.title-screen.hidden {
  opacity: 0;
  pointer-events: none;
  transform: scale(0.96);
}

.title-glow {
  position: absolute;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(230, 57, 70, 0.18) 0%, rgba(255, 214, 10, 0.08) 40%, transparent 70%);
  border-radius: 50%;
  filter: blur(40px);
  animation: titleGlow 8s ease-in-out infinite;
  pointer-events: none;
}

@keyframes titleGlow {
  0%, 100% { transform: scale(1) rotate(0deg); opacity: 0.7; }
  50%      { transform: scale(1.15) rotate(180deg); opacity: 1; }
}

.title-content {
  position: relative;
  text-align: center;
  z-index: 1;
  padding: 0 24px;
  animation: titleFadeIn 0.7s cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

.title-logo {
  font-size: clamp(3.5rem, 11vw, 6.5rem);
  font-weight: 900;
  letter-spacing: -2px;
  background: linear-gradient(90deg, #e63946 0%, #ff8c00 50%, #ffd60a 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-shadow: 0 0 60px rgba(230, 57, 70, 0.3);
  margin-bottom: 4px;
  line-height: 1;
}

.title-tagline {
  font-size: clamp(0.95rem, 1.8vw, 1.2rem);
  font-weight: 600;
  color: rgba(255, 255, 255, 0.7);
  letter-spacing: 0.5px;
  margin-bottom: 36px;
  line-height: 1.4;
}

.title-best {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  padding: 8px 20px;
  margin-bottom: 28px;
}

.title-best-label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--muted);
}

.title-best-val {
  font-size: 1.1rem;
  font-weight: 900;
  color: var(--gold);
}

.btn-play {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: linear-gradient(90deg, #e63946 0%, #ff6b6b 100%);
  border: none;
  color: #fff;
  font-family: inherit;
  font-size: 1.1rem;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 18px 60px;
  border-radius: 16px;
  cursor: pointer;
  margin: 0 auto 14px;
  box-shadow: 0 8px 28px rgba(230, 57, 70, 0.45);
  transition: transform 0.15s ease, box-shadow 0.25s ease;
  animation: btnPulse 2.5s ease-in-out infinite;
}

.btn-play:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 12px 36px rgba(230, 57, 70, 0.6);
}

.btn-play:active {
  transform: translateY(0) scale(1);
}

.btn-play-icon {
  font-size: 0.85rem;
  display: inline-block;
  margin-right: 2px;
}

@keyframes btnPulse {
  0%, 100% { box-shadow: 0 8px 28px rgba(230, 57, 70, 0.45); }
  50%      { box-shadow: 0 8px 38px rgba(230, 57, 70, 0.7); }
}

.btn-daily {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.06);
  border: 1.5px solid rgba(255, 214, 10, 0.4);
  color: var(--gold);
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  padding: 14px 40px;
  border-radius: 14px;
  cursor: pointer;
  margin: 0 auto 16px;
  transition: background 0.25s ease, border-color 0.25s ease, transform 0.1s ease;
  position: relative;
}

.btn-daily:hover {
  background: rgba(255, 214, 10, 0.1);
  border-color: var(--gold);
  transform: translateY(-1px);
}

.btn-daily.completed {
  border-color: rgba(55, 210, 130, 0.5);
  color: var(--green);
}

.btn-daily.completed:hover {
  background: rgba(55, 210, 130, 0.08);
  border-color: var(--green);
}

.btn-daily-icon {
  font-size: 1rem;
}

.daily-badge {
  font-size: 0.65rem;
  font-weight: 700;
  background: rgba(55, 210, 130, 0.2);
  color: var(--green);
  border-radius: 99px;
  padding: 2px 8px;
  margin-left: 6px;
  letter-spacing: 0.3px;
  text-transform: none;
}

.title-actions-row {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-bottom: 32px;
  flex-wrap: wrap;
}

.btn-secondary-title {
  background: transparent;
  border: 1.5px solid rgba(255, 255, 255, 0.18);
  color: var(--text);
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.4px;
  padding: 10px 24px;
  border-radius: 12px;
  cursor: pointer;
  transition: background 0.25s ease, border-color 0.25s ease;
}

.btn-secondary-title:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.35);
}

/* ── Title Mosaic (background grid of character portraits) ─────────────── */
.title-mosaic {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  grid-auto-rows: 1fr;
  gap: 4px;
  z-index: 0;
  filter: blur(1.5px) saturate(1.1);
  opacity: 0.35;
  pointer-events: none;
}

.mosaic-tile {
  background-size: cover;
  background-position: center 25%;
  background-color: #1a1a2e;
  width: 100%;
  height: 100%;
  min-height: 120px;
  animation: mosaicFloat 14s ease-in-out infinite;
}

@keyframes mosaicFloat {
  0%, 100% { transform: scale(1); opacity: 0.85; }
  50%      { transform: scale(1.03); opacity: 1; }
}

.title-mosaic-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at center, rgba(10,10,15,0.35) 0%, rgba(10,10,15,0.85) 60%, rgba(10,10,15,0.97) 100%),
    linear-gradient(180deg, rgba(10,10,15,0.6) 0%, rgba(10,10,15,0.4) 50%, rgba(10,10,15,0.85) 100%);
  z-index: 0;
  pointer-events: none;
}

@media (max-width: 720px) {
  .title-mosaic { grid-template-columns: repeat(4, 1fr); }
  .mosaic-tile { min-height: 100px; }
}

.title-credit {
  font-size: 0.75rem;
  color: var(--muted);
  letter-spacing: 0.3px;
}

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

:root {
  --bg: #0a0a0f;
  --surface: #15151f;
  --accent: #e63946;
  --gold: #ffd60a;
  --green: #37d282;
  --text: #f0f0f4;
  --muted: #9898b0;
  --radius: 20px;
  --trans: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

html, body {
  height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: 'Poppins', 'Segoe UI', sans-serif;
}

body { overflow: auto; }

/* ── Header ────────────────────────────────────────────────────────────────── */
header {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 14px 24px;
  background: rgba(10,10,15,0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  position: sticky;
  top: 0;
  z-index: 100;
}

.logo-wrap        { justify-self: start; }
header .scores    { justify-self: center; }
.header-buttons   { justify-self: end; }

.logo-wrap {
  display: flex;
  flex-direction: column;
  gap: 1px;
  line-height: 1;
}

.logo {
  font-size: 1.4rem;
  font-weight: 900;
  letter-spacing: -0.5px;
  background: linear-gradient(90deg, #e63946, #ffd60a);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.tagline {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.3px;
  color: var(--muted);
  margin-top: 2px;
}

@media (max-width: 480px) {
  .tagline { display: none; }
}

.scores {
  display: flex;
  gap: 20px;
  align-items: center;
}

.score-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.score-label {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--muted);
}

.score-val {
  font-size: 1.6rem;
  font-weight: 800;
  line-height: 1;
}

.score-val-row {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.streak-fire {
  font-size: 1.1rem;
  opacity: 0;
  transform: scale(0.4);
  transition: opacity 0.2s ease, transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
  filter: drop-shadow(0 0 6px rgba(255, 140, 0, 0.6));
}

.streak-fire.visible {
  opacity: 1;
  transform: scale(1);
  animation: fireFlicker 1.4s ease-in-out infinite;
}

.streak-fire.milestone {
  animation: fireBurst 0.7s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes fireFlicker {
  0%, 100% { transform: scale(1) rotate(-2deg); filter: drop-shadow(0 0 6px rgba(255, 140, 0, 0.6)); }
  50%      { transform: scale(1.1) rotate(2deg);  filter: drop-shadow(0 0 12px rgba(255, 60, 0, 0.85)); }
}

@keyframes fireBurst {
  0%   { transform: scale(1); }
  40%  { transform: scale(1.8) rotate(-8deg); filter: drop-shadow(0 0 24px rgba(255, 60, 0, 1)); }
  100% { transform: scale(1) rotate(0); }
}

#score { color: var(--gold); }
#high-score { color: var(--accent); }

.score-val.pulse {
  animation: scorePop 0.3s ease;
}

@keyframes scorePop {
  0%   { transform: scale(1); }
  50%  { transform: scale(1.4); }
  100% { transform: scale(1); }
}

.how-to-btn {
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.12);
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  padding: 6px 14px;
  border-radius: 20px;
  cursor: pointer;
  transition: background var(--trans), color var(--trans);
}

.how-to-btn:hover { background: rgba(255,255,255,0.14); color: var(--text); }

.header-buttons {
  display: flex;
  align-items: center;
  gap: 8px;
}

.icon-btn {
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.12);
  color: var(--muted);
  font-size: 0.95rem;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background var(--trans);
  padding: 0;
  line-height: 1;
}

.icon-btn:hover {
  background: rgba(255,255,255,0.14);
}

/* ── Main Layout ───────────────────────────────────────────────────────────── */
main {
  display: flex;
  height: calc(100vh - 65px);
  min-height: 600px;
  position: relative;
}

/* ── Cards ─────────────────────────────────────────────────────────────────── */
.card {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 36px 40px;
  position: relative;
  overflow: hidden;
  transition: background var(--trans);
}

/* Full-bleed character image */
.card-image {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center 18%;
  background-repeat: no-repeat;
  /* Sharpening: boost saturation + contrast + subtle unsharp-mask via filter */
  filter: saturate(1.15) contrast(1.08) brightness(1.02);
  /* Hint to browsers to use higher-quality scaling */
  image-rendering: -webkit-optimize-contrast;
  image-rendering: crisp-edges;
  z-index: 0;
  transition: transform 0.6s ease;
  will-change: transform;
  /* Slight backdrop blur on extreme zoom helps mask pixelation */
  backface-visibility: hidden;
  transform: translateZ(0); /* GPU layer */
}

.card:hover .card-image {
  transform: scale(1.04);
}

/* Dark gradient overlay so text is readable on top of the image */
.card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(0,0,0,0.92) 0%,
    rgba(0,0,0,0.65) 35%,
    rgba(0,0,0,0.15) 70%,
    rgba(0,0,0,0.05) 100%
  );
  z-index: 1;
}

.card-content {
  position: relative;
  z-index: 2;
}

.card-label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: rgba(255,255,255,0.6);
  margin-bottom: 8px;
}

.char-name {
  font-size: clamp(1.7rem, 3.6vw, 2.9rem);
  font-weight: 900;
  line-height: 1.1;
  margin-bottom: 4px;
  text-shadow: 0 3px 18px rgba(0,0,0,0.85);
  letter-spacing: -0.5px;
}

.char-anime {
  font-size: clamp(0.8rem, 1.5vw, 1.05rem);
  font-weight: 600;
  color: rgba(255,255,255,0.7);
  margin-bottom: 16px;
  letter-spacing: 0.3px;
  text-shadow: 0 2px 10px rgba(0,0,0,0.7);
}

.char-desc {
  font-size: clamp(0.75rem, 1.2vw, 0.9rem);
  color: rgba(255,255,255,0.65);
  line-height: 1.5;
  max-width: 360px;
  margin-top: 14px;
  text-shadow: 0 2px 10px rgba(0,0,0,0.7);
}

/* ── Value (Popularity) Display ─────────────────────────────────────────────── */
.value-wrap {
  display: inline-block;
}

.value-display {
  font-size: clamp(2.4rem, 5.5vw, 4.2rem);
  font-weight: 900;
  line-height: 1;
  background: linear-gradient(90deg, var(--gold), #ffaa00);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-shadow: 0 4px 30px rgba(255, 214, 10, 0.3);
  letter-spacing: -1px;
}

.value-wrap:not(.revealed) .value-display {
  background: linear-gradient(90deg, #888, #ccc);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.value-tag {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: rgba(255,255,255,0.55);
  margin-top: 4px;
  display: block;
}

.value-wrap.revealed .value-display {
  animation: revealValue 0.55s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes revealValue {
  from { transform: scale(0.5) translateY(15px); opacity: 0; }
  to   { transform: scale(1) translateY(0); opacity: 1; }
}

.value-wrap.pulse .value-display {
  animation: revealValue 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* ── VS Divider ─────────────────────────────────────────────────────────────── */
.vs-divider {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 80px;
  flex-shrink: 0;
  z-index: 10;
  gap: 18px;
  position: relative;
  background: var(--bg);
}

.vs-divider::before {
  content: '';
  position: absolute;
  top: 0; bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 2px;
  background: linear-gradient(to bottom, transparent, rgba(255,255,255,0.18), transparent);
}

.vs-ring {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid rgba(255,255,255,0.18);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 1.1rem;
  letter-spacing: 1px;
  color: var(--muted);
  z-index: 1;
  box-shadow: 0 0 32px rgba(0,0,0,0.6);
}

/* ── Action Buttons ─────────────────────────────────────────────────────────── */
.btn-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 1;
}

.btn-action {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.14);
  color: var(--text);
  font-family: inherit;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 12px 22px;
  border-radius: 12px;
  cursor: pointer;
  transition: background var(--trans), transform 0.1s, border-color var(--trans);
  white-space: nowrap;
  backdrop-filter: blur(4px);
}

.btn-action:hover:not(:disabled) {
  background: rgba(255,255,255,0.16);
  border-color: rgba(255,255,255,0.3);
  transform: scale(1.06);
}

.btn-action:active:not(:disabled) { transform: scale(0.97); }

.btn-action:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.btn-more   { border-color: rgba(55, 210, 130, 0.45); color: var(--green); }
.btn-more:hover:not(:disabled) { background: rgba(55, 210, 130, 0.18); border-color: var(--green); }

.btn-less   { border-color: rgba(230, 57, 70, 0.45); color: var(--accent); }
.btn-less:hover:not(:disabled) { background: rgba(230, 57, 70, 0.18); border-color: var(--accent); }

/* ── Result Banner ──────────────────────────────────────────────────────────── */
.result-banner {
  position: fixed;
  top: 84px;
  left: 50%;
  transform: translateX(-50%) translateY(-20px);
  background: var(--surface);
  border: 2px solid rgba(255,255,255,0.1);
  border-radius: 50px;
  padding: 12px 32px;
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  opacity: 0;
  transition: opacity 0.2s, transform 0.2s;
  z-index: 200;
  pointer-events: none;
  box-shadow: 0 8px 32px rgba(0,0,0,0.4);
}

.result-banner.visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.result-banner.correct { color: var(--green); border-color: var(--green); }
.result-banner.wrong   { color: var(--accent); border-color: var(--accent); }

/* ── Slide Animations ───────────────────────────────────────────────────────── */
.slide-out  { animation: slideOutLeft 0.38s ease forwards; }
.slide-in-left { animation: slideInLeft 0.38s ease forwards; }

@keyframes slideOutLeft {
  to { transform: translateX(-120%); opacity: 0; }
}

@keyframes slideInLeft {
  from { transform: translateX(-80px); opacity: 0; }
  to   { transform: translateX(0); opacity: 1; }
}

/* ── Game Over Screen ───────────────────────────────────────────────────────── */
.game-over-screen {
  position: fixed;
  inset: 0;
  background: rgba(8, 8, 12, 0.92);
  backdrop-filter: blur(16px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 300;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}

.game-over-screen.visible {
  opacity: 1;
  pointer-events: all;
}

.game-over-box {
  background: var(--surface);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 28px;
  padding: 48px 52px;
  text-align: center;
  max-width: 420px;
  width: 90%;
  animation: popIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

.game-over-emoji { font-size: 3.5rem; margin-bottom: 12px; }
.game-over-box h2 { font-size: 1.8rem; font-weight: 900; margin-bottom: 6px; }
.game-over-box p  { color: var(--muted); font-size: 0.9rem; margin-bottom: 28px; }

.stat-row {
  display: flex;
  justify-content: center;
  gap: 32px;
  margin-bottom: 32px;
}

.stat-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.stat-label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--muted);
}

.stat-val {
  font-size: 2.8rem;
  font-weight: 900;
  line-height: 1;
}

#final-score { color: var(--gold); }
#final-high  { color: var(--accent); }

.btn-primary {
  background: linear-gradient(90deg, var(--accent), #ff6b6b);
  border: none;
  color: #fff;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  padding: 14px 32px;
  border-radius: 14px;
  cursor: pointer;
  width: 100%;
  margin-bottom: 12px;
  transition: opacity var(--trans), transform 0.1s;
}

.btn-primary:hover { opacity: 0.9; transform: translateY(-1px); }

.btn-secondary {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  color: var(--text);
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 700;
  padding: 12px 32px;
  border-radius: 14px;
  cursor: pointer;
  width: 100%;
  transition: background var(--trans);
}

.btn-secondary:hover { background: rgba(255,255,255,0.12); }

/* ── How To Modal ───────────────────────────────────────────────────────────── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 10, 15, 0.85);
  backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 600;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
}

.modal-overlay.visible {
  opacity: 1;
  pointer-events: all;
}

.modal-box {
  background: var(--surface);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 24px;
  padding: 40px 44px;
  max-width: 420px;
  width: 90%;
  animation: popIn 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal-box h3 { font-size: 1.4rem; font-weight: 800; margin-bottom: 20px; }

/* ── Stats Modal ─────────────────────────────────────────────────────────── */
.stats-box {
  text-align: center;
  max-width: 460px;
}

.stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 10px;
  margin-bottom: 28px;
}

.stats-cell {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 16px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.stats-cell.highlight {
  background: rgba(255, 214, 10, 0.06);
  border-color: rgba(255, 214, 10, 0.2);
}

.stats-cell-val {
  font-size: 1.9rem;
  font-weight: 900;
  color: var(--gold);
  line-height: 1;
}

.stats-cell.highlight .stats-cell-val {
  background: linear-gradient(90deg, var(--gold), #ff8c00);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.stats-cell-label {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--muted);
  text-align: center;
  line-height: 1.3;
}

@media (max-width: 480px) {
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .stats-cell-val { font-size: 1.6rem; }
}

.how-to-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 28px;
}

.how-to-list li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  font-size: 0.9rem;
  color: rgba(255,255,255,0.8);
  line-height: 1.5;
}

.how-to-list li span:first-child {
  font-size: 1.3rem;
  flex-shrink: 0;
  width: 28px;
}

.shortcut-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 28px;
  align-items: center;
}

kbd {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 0.75rem;
  font-family: monospace;
  font-weight: 700;
  color: var(--muted);
}

/* ── Ad Slots ───────────────────────────────────────────────────────────────── */
.ad-slot {
  background: rgba(255,255,255,0.03);
  border: 1px dashed rgba(255,255,255,0.08);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.ad-slot-bottom {
  height: 90px;
  width: 100%;
  max-width: 728px;
  margin: 0 auto;
}

.ad-footer {
  padding: 10px 16px;
  background: rgba(0,0,0,0.4);
  border-top: 1px solid rgba(255,255,255,0.04);
}

footer {
  text-align: center;
  padding: 6px 16px 10px;
  font-size: 0.7rem;
  color: var(--muted);
  background: rgba(0,0,0,0.3);
}

footer a { color: var(--muted); text-decoration: underline; }

/* ── Responsive ─────────────────────────────────────────────────────────────── */
@media (max-width: 720px) {
  html, body { overflow: auto; }

  main {
    flex-direction: column;
    height: auto;
    min-height: unset;
  }

  .card {
    min-height: 360px;
    padding: 28px 22px;
  }

  .vs-divider {
    flex-direction: row;
    width: 100%;
    height: 60px;
    flex-shrink: 0;
    gap: 14px;
  }

  .vs-divider::before {
    top: 50%; bottom: auto;
    left: 0; right: 0;
    width: 100%; height: 2px;
    transform: translateY(-50%);
  }

  .btn-group {
    flex-direction: row;
    justify-content: center;
    flex-wrap: wrap;
  }

  .char-name { font-size: 1.5rem; }
  .value-display { font-size: 2.4rem; }
}

@media (max-width: 480px) {
  header { padding: 10px 14px; }
  .logo { font-size: 1.05rem; }
  .score-val { font-size: 1.3rem; }
  .game-over-box { padding: 32px 24px; }
  .modal-box { padding: 28px 20px; }
}
