/* ============================================================
   EL TRIVIA — "Intellect Grid" Design System
   ============================================================ */

/* --- Fonts --- */
@import url('https://fonts.googleapis.com/css2?family=Lexend:wght@300;400;500;600;700&family=Space+Grotesk:wght@400;500;600;700&display=swap');

/* --- Custom Properties --- */
:root {
  /* Palette */
  --indigo: #4F46E5;
  --indigo-light: #6366F1;
  --indigo-dark: #3730A3;
  --indigo-glow: rgba(79, 70, 229, 0.35);
  --gold: #F59E0B;
  --gold-light: #FBBF24;
  --gold-dark: #D97706;
  --gold-glow: rgba(245, 158, 11, 0.3);
  --navy: #0F172A;
  --navy-light: #1E293B;
  --navy-lighter: #273549;
  --navy-surface: #162032;
  --paper: #F8FAFC;
  --paper-dim: #CBD5E1;
  --paper-muted: #94A3B8;
  --correct: #10B981;
  --correct-glow: rgba(16, 185, 129, 0.25);
  --incorrect: #EF4444;
  --incorrect-glow: rgba(239, 68, 68, 0.25);

  /* Typography */
  --font-body: 'Lexend', sans-serif;
  --font-heading: 'Space Grotesk', sans-serif;

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

  /* Radii */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;

  /* Glass */
  --glass-bg: rgba(15, 23, 42, 0.6);
  --glass-border: rgba(248, 250, 252, 0.08);
  --glass-blur: 20px;

  /* Transitions */
  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --duration-fast: 150ms;
  --duration-med: 300ms;
  --duration-slow: 500ms;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  font-weight: 400;
  color: var(--paper);
  background-color: var(--navy);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

/* --- Blueprint Dot Matrix Background --- */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 0;
  background-image:
    radial-gradient(circle, rgba(79, 70, 229, 0.12) 1px, transparent 1px);
  background-size: 28px 28px;
  pointer-events: none;
}

body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 0;
  background:
    linear-gradient(180deg,
      rgba(15, 23, 42, 0) 0%,
      rgba(15, 23, 42, 0.4) 50%,
      rgba(15, 23, 42, 0.8) 100%);
  pointer-events: none;
}

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

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.15;
  color: var(--paper);
}

h1 { font-size: clamp(2rem, 5vw, 3.25rem); }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.25rem); }
h3 { font-size: clamp(1.15rem, 2.5vw, 1.5rem); }

a {
  color: var(--indigo-light);
  text-decoration: none;
  transition: color var(--duration-fast) ease;
}
a:hover { color: var(--gold); }

/* --- Layout Shell --- */
.page-wrapper {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.container--narrow {
  max-width: 800px;
}

/* ============================================================
   NAVBAR
   ============================================================ */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  padding: var(--space-md) 0;
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--glass-border);
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-lg);
}

.navbar__brand {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  text-decoration: none;
}

.navbar__logo {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, var(--indigo), var(--indigo-light));
  border-radius: var(--radius-sm);
  display: grid;
  place-items: center;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--paper);
  position: relative;
  overflow: hidden;
}

.navbar__logo::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent 40%, rgba(255,255,255,0.15));
}

.navbar__title {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--paper);
  letter-spacing: -0.02em;
}

.navbar__title span {
  color: var(--gold);
}

.navbar__nav {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  list-style: none;
}

.navbar__link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: var(--space-sm) var(--space-md);
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--paper-dim);
  transition: all var(--duration-fast) ease;
}

.navbar__link:hover {
  color: var(--paper);
  background: rgba(248, 250, 252, 0.06);
}

.navbar__link--active {
  color: var(--paper);
  background: rgba(79, 70, 229, 0.15);
}

.navbar__streak {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid rgba(245, 158, 11, 0.2);
  border-radius: 100px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--gold);
  white-space: nowrap;
}

.navbar__streak svg {
  flex-shrink: 0;
}

/* Mobile nav toggle */
.navbar__toggle {
  display: none;
  background: none;
  border: none;
  color: var(--paper);
  cursor: pointer;
  padding: var(--space-sm);
}

@media (max-width: 768px) {
  .navbar__toggle { display: block; }
  .navbar__nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    padding: var(--space-md) var(--space-lg);
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
  }
  .navbar__nav--open { display: flex; }
  .navbar__link { width: 100%; padding: var(--space-md); }
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 28px;
  border: none;
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--duration-fast) var(--ease-out-expo);
  position: relative;
  overflow: hidden;
  text-decoration: none;
  white-space: nowrap;
}

.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.12), transparent);
  opacity: 0;
  transition: opacity var(--duration-fast) ease;
}

.btn:hover::after { opacity: 1; }

.btn:active {
  transform: scale(0.97);
  transition-duration: 80ms;
}

.btn--primary {
  background: linear-gradient(135deg, var(--indigo), var(--indigo-light));
  color: var(--paper);
  box-shadow: 0 4px 20px var(--indigo-glow), inset 0 1px 0 rgba(255,255,255,0.1);
}

.btn--primary:hover {
  box-shadow: 0 6px 30px var(--indigo-glow), inset 0 1px 0 rgba(255,255,255,0.15);
  transform: translateY(-1px);
}

.btn--gold {
  background: linear-gradient(135deg, var(--gold), var(--gold-light));
  color: var(--navy);
  box-shadow: 0 4px 20px var(--gold-glow);
}

.btn--gold:hover {
  box-shadow: 0 6px 30px var(--gold-glow);
  transform: translateY(-1px);
}

.btn--ghost {
  background: rgba(248, 250, 252, 0.05);
  color: var(--paper-dim);
  border: 1px solid var(--glass-border);
}

.btn--ghost:hover {
  background: rgba(248, 250, 252, 0.08);
  color: var(--paper);
  border-color: rgba(248, 250, 252, 0.15);
}

.btn--sm {
  padding: 8px 18px;
  font-size: 0.8rem;
  border-radius: var(--radius-sm);
}

.btn--lg {
  padding: 16px 36px;
  font-size: 1.05rem;
  border-radius: var(--radius-lg);
}

/* ============================================================
   GLASS CARD
   ============================================================ */
.glass {
  background: var(--glass-bg);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
}

.card {
  background: var(--navy-surface);
  border: 1px solid rgba(248, 250, 252, 0.05);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  transition: all var(--duration-med) var(--ease-out-expo);
}

.card:hover {
  border-color: rgba(79, 70, 229, 0.2);
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.2);
  transform: translateY(-2px);
}

/* ============================================================
   BADGE / TAG
   ============================================================ */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 100px;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.badge--indigo {
  background: rgba(79, 70, 229, 0.15);
  color: var(--indigo-light);
  border: 1px solid rgba(79, 70, 229, 0.25);
}

.badge--gold {
  background: rgba(245, 158, 11, 0.12);
  color: var(--gold);
  border: 1px solid rgba(245, 158, 11, 0.2);
}

.badge--green {
  background: rgba(16, 185, 129, 0.12);
  color: var(--correct);
  border: 1px solid rgba(16, 185, 129, 0.2);
}

/* ============================================================
   HOME — HERO
   ============================================================ */
.hero {
  padding: var(--space-3xl) 0 var(--space-2xl);
  text-align: center;
  position: relative;
}

.hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.18);
  border-radius: 100px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--gold);
  margin-bottom: var(--space-lg);
  animation: fadeSlideUp 0.6s var(--ease-out-expo) both;
}

.hero__title {
  margin-bottom: var(--space-md);
  animation: fadeSlideUp 0.6s var(--ease-out-expo) 0.1s both;
}

.hero__title em {
  font-style: normal;
  background: linear-gradient(135deg, var(--indigo-light), var(--gold));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero__subtitle {
  max-width: 540px;
  margin: 0 auto var(--space-xl);
  font-size: 1.05rem;
  font-weight: 300;
  color: var(--paper-muted);
  line-height: 1.7;
  animation: fadeSlideUp 0.6s var(--ease-out-expo) 0.2s both;
}

.hero__actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-md);
  flex-wrap: wrap;
  animation: fadeSlideUp 0.6s var(--ease-out-expo) 0.3s both;
}

/* Ambient glow behind hero */
.hero::before {
  content: '';
  position: absolute;
  top: -120px;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 400px;
  background: radial-gradient(ellipse, var(--indigo-glow), transparent 70%);
  pointer-events: none;
  z-index: -1;
}

/* ============================================================
   HOME — STATS ROW
   ============================================================ */
.stats-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: var(--space-md);
  padding: var(--space-xl) 0;
  animation: fadeSlideUp 0.6s var(--ease-out-expo) 0.4s both;
}

.stat-card {
  text-align: center;
  padding: var(--space-lg);
}

.stat-card__value {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 700;
  color: var(--paper);
  line-height: 1.1;
}

.stat-card__value--gold { color: var(--gold); }
.stat-card__value--indigo { color: var(--indigo-light); }

.stat-card__label {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--paper-muted);
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ============================================================
   HOME — DAILY CHALLENGE
   ============================================================ */
.daily-challenge {
  padding: var(--space-xl) 0;
}

.daily-challenge__card {
  position: relative;
  overflow: hidden;
  padding: var(--space-2xl);
  background: linear-gradient(135deg, var(--navy-surface), var(--navy-light));
  border: 1px solid rgba(79, 70, 229, 0.15);
}

.daily-challenge__card::before {
  content: '';
  position: absolute;
  top: -60px;
  right: -60px;
  width: 240px;
  height: 240px;
  background: radial-gradient(circle, var(--indigo-glow), transparent 70%);
  pointer-events: none;
}

.daily-challenge__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-lg);
  margin-bottom: var(--space-lg);
  flex-wrap: wrap;
}

.daily-challenge__meta {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.daily-challenge__tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  width: fit-content;
}

.daily-challenge__title {
  font-size: 1.5rem;
}

.daily-challenge__desc {
  color: var(--paper-muted);
  font-size: 0.95rem;
  max-width: 500px;
  line-height: 1.6;
}

.daily-challenge__info {
  display: flex;
  align-items: center;
  gap: var(--space-xl);
  margin-top: var(--space-lg);
  flex-wrap: wrap;
}

.daily-challenge__detail {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--paper-dim);
}

.daily-challenge__detail svg {
  color: var(--paper-muted);
  flex-shrink: 0;
}

.daily-challenge__timer {
  text-align: right;
}

.daily-challenge__timer-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--paper-muted);
  margin-bottom: 4px;
}

.daily-challenge__timer-value {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--gold);
  font-variant-numeric: tabular-nums;
}

/* ============================================================
   HOME — CATEGORIES GRID
   ============================================================ */
.categories {
  padding: var(--space-2xl) 0;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-xl);
  flex-wrap: wrap;
  gap: var(--space-md);
}

.section-header h2 {
  font-size: 1.35rem;
}

.categories__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: var(--space-md);
}

.category-card {
  padding: var(--space-lg);
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.category-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--cat-color, var(--indigo-glow)), transparent);
  opacity: 0;
  transition: opacity var(--duration-med) ease;
}

.category-card:hover::before { opacity: 1; }

.category-card__icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  display: grid;
  place-items: center;
  font-size: 1.4rem;
  margin-bottom: var(--space-md);
  background: rgba(248, 250, 252, 0.05);
  border: 1px solid var(--glass-border);
  position: relative;
  z-index: 1;
}

.category-card__name {
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1rem;
  margin-bottom: 4px;
  position: relative;
  z-index: 1;
}

.category-card__count {
  font-size: 0.78rem;
  color: var(--paper-muted);
  position: relative;
  z-index: 1;
}

/* Category color accents */
.category-card--science  { --cat-color: rgba(59, 130, 246, 0.08); }
.category-card--history  { --cat-color: rgba(245, 158, 11, 0.08); }
.category-card--geo      { --cat-color: rgba(16, 185, 129, 0.08); }
.category-card--arts     { --cat-color: rgba(168, 85, 247, 0.08); }
.category-card--sports   { --cat-color: rgba(239, 68, 68, 0.08); }
.category-card--tech     { --cat-color: rgba(79, 70, 229, 0.08); }

/* ============================================================
   HOME — LEADERBOARD
   ============================================================ */
.leaderboard {
  padding: var(--space-2xl) 0;
}

.leaderboard__table {
  width: 100%;
  border-collapse: collapse;
}

.leaderboard__table thead th {
  font-family: var(--font-heading);
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--paper-muted);
  padding: var(--space-sm) var(--space-md);
  text-align: left;
  border-bottom: 1px solid rgba(248, 250, 252, 0.06);
}

.leaderboard__table thead th:last-child {
  text-align: right;
}

.leaderboard__table tbody td {
  padding: var(--space-md);
  border-bottom: 1px solid rgba(248, 250, 252, 0.03);
  font-size: 0.9rem;
  vertical-align: middle;
}

.leaderboard__table tbody td:last-child {
  text-align: right;
}

.leaderboard__table tbody tr {
  transition: background var(--duration-fast) ease;
}

.leaderboard__table tbody tr:hover {
  background: rgba(248, 250, 252, 0.02);
}

.leaderboard__rank {
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--paper-muted);
  width: 40px;
}

.leaderboard__rank--gold { color: var(--gold); }
.leaderboard__rank--silver { color: #94A3B8; }
.leaderboard__rank--bronze { color: #CD7F32; }

.leaderboard__player {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.leaderboard__avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--indigo), var(--indigo-light));
  display: grid;
  place-items: center;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--paper);
  flex-shrink: 0;
}

.leaderboard__score {
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--gold);
}

.leaderboard__accuracy {
  color: var(--correct);
  font-weight: 500;
  font-size: 0.82rem;
}

/* ============================================================
   QUIZ PAGE — LAYOUT
   ============================================================ */
.quiz-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: var(--space-xl);
  padding: var(--space-xl) 0 var(--space-3xl);
  align-items: start;
}

@media (max-width: 900px) {
  .quiz-layout {
    grid-template-columns: 1fr;
  }
}

/* ============================================================
   QUIZ — PROGRESS BAR
   ============================================================ */
.quiz-progress {
  margin-bottom: var(--space-xl);
}

.quiz-progress__bar {
  width: 100%;
  height: 6px;
  background: var(--navy-lighter);
  border-radius: 100px;
  overflow: hidden;
}

.quiz-progress__fill {
  height: 100%;
  background: linear-gradient(90deg, var(--indigo), var(--indigo-light));
  border-radius: 100px;
  transition: width var(--duration-med) var(--ease-out-expo);
  box-shadow: 0 0 12px var(--indigo-glow);
}

.quiz-progress__text {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: var(--space-sm);
  font-size: 0.78rem;
  color: var(--paper-muted);
}

.quiz-progress__text span {
  font-weight: 600;
  color: var(--paper-dim);
}

/* ============================================================
   QUIZ — QUESTION CARD
   ============================================================ */
.question-card {
  padding: var(--space-2xl);
  position: relative;
  overflow: hidden;
}

.question-card__number {
  font-family: var(--font-heading);
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--indigo-light);
  margin-bottom: var(--space-sm);
}

.question-card__category {
  margin-bottom: var(--space-lg);
}

.question-card__text {
  font-size: 1.35rem;
  font-weight: 500;
  line-height: 1.5;
  color: var(--paper);
  margin-bottom: var(--space-2xl);
}

/* ============================================================
   QUIZ — ANSWER OPTIONS
   ============================================================ */
.answers {
  display: grid;
  gap: var(--space-md);
}

.answer-option {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  width: 100%;
  padding: var(--space-lg);
  background: var(--navy-lighter);
  border: 2px solid rgba(248, 250, 252, 0.06);
  border-radius: var(--radius-md);
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--paper-dim);
  text-align: left;
  transition: all var(--duration-fast) var(--ease-out-expo);
  position: relative;
  overflow: hidden;
}

.answer-option::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.03), transparent);
  opacity: 0;
  transition: opacity var(--duration-fast) ease;
}

.answer-option:hover {
  border-color: rgba(79, 70, 229, 0.4);
  background: rgba(79, 70, 229, 0.06);
  color: var(--paper);
  transform: translateX(4px);
}

.answer-option:hover::before { opacity: 1; }

.answer-option:active {
  transform: translateX(4px) scale(0.99);
  transition-duration: 60ms;
}

.answer-option__key {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  background: rgba(248, 250, 252, 0.05);
  border: 1px solid rgba(248, 250, 252, 0.08);
  display: grid;
  place-items: center;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.8rem;
  color: var(--paper-muted);
  flex-shrink: 0;
  transition: all var(--duration-fast) ease;
}

.answer-option:hover .answer-option__key {
  background: rgba(79, 70, 229, 0.15);
  border-color: rgba(79, 70, 229, 0.3);
  color: var(--indigo-light);
}

/* Correct state */
.answer-option--correct {
  border-color: var(--correct) !important;
  background: var(--correct-glow) !important;
  color: var(--paper) !important;
  animation: answerCorrect 0.4s var(--ease-spring) both;
}

.answer-option--correct .answer-option__key {
  background: var(--correct);
  border-color: var(--correct);
  color: var(--paper);
}

/* Incorrect state */
.answer-option--incorrect {
  border-color: var(--incorrect) !important;
  background: var(--incorrect-glow) !important;
  color: var(--paper) !important;
  animation: answerIncorrect 0.4s ease both;
}

.answer-option--incorrect .answer-option__key {
  background: var(--incorrect);
  border-color: var(--incorrect);
  color: var(--paper);
}

/* Disabled after answer */
.answer-option--disabled {
  pointer-events: none;
  opacity: 0.5;
}

/* ============================================================
   QUIZ — SIDEBAR SCOREBOARD (Glassmorphism)
   ============================================================ */
.scoreboard {
  position: sticky;
  top: 80px;
  padding: var(--space-xl);
}

.scoreboard__title {
  font-family: var(--font-heading);
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--paper-muted);
  margin-bottom: var(--space-lg);
}

.scoreboard__score {
  text-align: center;
  margin-bottom: var(--space-xl);
}

.scoreboard__score-value {
  font-family: var(--font-heading);
  font-size: 3rem;
  font-weight: 700;
  color: var(--gold);
  line-height: 1;
  text-shadow: 0 0 30px var(--gold-glow);
}

.scoreboard__score-label {
  font-size: 0.78rem;
  color: var(--paper-muted);
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.scoreboard__stats {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.scoreboard__stat {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: var(--space-md);
  border-bottom: 1px solid rgba(248, 250, 252, 0.05);
}

.scoreboard__stat:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.scoreboard__stat-label {
  font-size: 0.82rem;
  color: var(--paper-muted);
}

.scoreboard__stat-value {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--paper);
}

.scoreboard__stat-value--correct { color: var(--correct); }
.scoreboard__stat-value--incorrect { color: var(--incorrect); }

/* ============================================================
   QUIZ — TIMER
   ============================================================ */
.quiz-timer {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-lg);
}

.quiz-timer__bar {
  flex: 1;
  height: 4px;
  background: var(--navy-lighter);
  border-radius: 100px;
  overflow: hidden;
}

.quiz-timer__fill {
  height: 100%;
  background: linear-gradient(90deg, var(--correct), var(--gold), var(--incorrect));
  border-radius: 100px;
  transition: width 1s linear;
}

.quiz-timer__text {
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--paper-dim);
  font-variant-numeric: tabular-nums;
  min-width: 36px;
  text-align: right;
}

.quiz-timer__text--warning { color: var(--gold); }
.quiz-timer__text--danger { color: var(--incorrect); animation: pulse 1s ease infinite; }

/* ============================================================
   QUIZ — RESULT FEEDBACK
   ============================================================ */
.feedback-bar {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md) var(--space-lg);
  border-radius: var(--radius-md);
  margin-top: var(--space-lg);
  font-weight: 500;
  font-size: 0.9rem;
  animation: feedbackSlideIn 0.3s var(--ease-out-expo) both;
}

.feedback-bar--correct {
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.2);
  color: var(--correct);
}

.feedback-bar--incorrect {
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.2);
  color: var(--incorrect);
}

.feedback-bar__icon {
  flex-shrink: 0;
}

.feedback-bar__text strong {
  display: block;
  margin-bottom: 2px;
}

.feedback-bar__text span {
  font-size: 0.82rem;
  font-weight: 400;
  opacity: 0.85;
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  margin-top: auto;
  padding: var(--space-xl) 0;
  border-top: 1px solid rgba(248, 250, 252, 0.05);
}

.footer .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-md);
}

.footer__copy {
  font-size: 0.78rem;
  color: var(--paper-muted);
}

.footer__links {
  display: flex;
  gap: var(--space-lg);
  list-style: none;
}

.footer__links a {
  font-size: 0.78rem;
  color: var(--paper-muted);
}

.footer__links a:hover {
  color: var(--paper);
}

/* ============================================================
   ANIMATIONS
   ============================================================ */
@keyframes fadeSlideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes answerCorrect {
  0% { transform: translateX(0) scale(1); }
  30% { transform: translateX(4px) scale(1.02); }
  100% { transform: translateX(4px) scale(1); }
}

@keyframes answerIncorrect {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-6px); }
  40% { transform: translateX(6px); }
  60% { transform: translateX(-4px); }
  80% { transform: translateX(4px); }
}

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

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

@keyframes scorePopIn {
  0% { transform: scale(0.8); opacity: 0; }
  60% { transform: scale(1.15); }
  100% { transform: scale(1); opacity: 1; }
}

@keyframes dotPulse {
  0%, 100% { opacity: 0.12; }
  50% { opacity: 0.25; }
}

.score-pop {
  animation: scorePopIn 0.4s var(--ease-spring) both;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 640px) {
  .hero { padding: var(--space-2xl) 0 var(--space-xl); }
  .question-card { padding: var(--space-xl); }
  .question-card__text { font-size: 1.15rem; }
  .daily-challenge__card { padding: var(--space-xl); }
  .stats-row { grid-template-columns: repeat(2, 1fr); }
  .categories__grid { grid-template-columns: 1fr; }
}
