/* ============================================
   FOOTY BETS 2026 — Design Tokens & Components
   Dark-first sports betting aesthetic
   ============================================ */

/* --- Type Scale --- */
:root {
  --text-xs:   clamp(0.75rem,  0.7rem  + 0.25vw, 0.875rem);
  --text-sm:   clamp(0.875rem, 0.8rem  + 0.35vw, 1rem);
  --text-base: clamp(1rem,     0.95rem + 0.25vw, 1.125rem);
  --text-lg:   clamp(1.125rem, 1rem    + 0.75vw, 1.5rem);
  --text-xl:   clamp(1.5rem,   1.2rem  + 1.25vw, 2.25rem);
  --text-2xl:  clamp(2rem,     1.2rem  + 2.5vw,  3.5rem);
  --text-3xl:  clamp(2.5rem,   1rem    + 4vw,    5rem);
  --text-hero: clamp(3rem,     0.5rem  + 7vw,    8rem);

  /* --- Spacing (4px base) --- */
  --space-1:  0.25rem;
  --space-2:  0.5rem;
  --space-3:  0.75rem;
  --space-4:  1rem;
  --space-5:  1.25rem;
  --space-6:  1.5rem;
  --space-8:  2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;
  --space-32: 8rem;

  /* --- Content widths --- */
  --content-narrow: 640px;
  --content-default: 960px;
  --content-wide: 1200px;
  --content-full: 100%;

  /* --- Radius --- */
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  --radius-full: 9999px;

  /* --- Transition --- */
  --transition-interactive: 180ms cubic-bezier(0.16, 1, 0.3, 1);

  /* --- Fonts --- */
  --font-display: 'Cabinet Grotesk', 'Arial Black', sans-serif;
  --font-body: 'General Sans', 'Helvetica Neue', sans-serif;
}

/* ============================================
   DARK MODE (Default — Footy Bets is dark-first)
   ============================================ */
:root, [data-theme="dark"] {
  --color-bg:             #0a0e17;
  --color-surface:        #111827;
  --color-surface-2:      #1a2332;
  --color-surface-offset: #0f1520;
  --color-surface-offset-2: #162033;
  --color-surface-dynamic: #1e293b;
  --color-divider:        #1e293b;
  --color-border:         #2d3a4f;

  --color-text:           #e2e8f0;
  --color-text-muted:     #94a3b8;
  --color-text-faint:     #64748b;
  --color-text-inverse:   #0a0e17;

  /* AFL Green-Gold accent */
  --color-primary:        #22c55e;
  --color-primary-hover:  #16a34a;
  --color-primary-active: #15803d;
  --color-primary-highlight: #16301f;

  /* Odds Gold */
  --color-gold:           #f59e0b;
  --color-gold-hover:     #d97706;

  /* Win/Loss */
  --color-success:        #22c55e;
  --color-error:          #ef4444;
  --color-warning:        #f59e0b;

  /* Blues for accent */
  --color-blue:           #3b82f6;
  --color-blue-hover:     #2563eb;

  --shadow-sm: 0 1px 2px oklch(0 0 0 / 0.3);
  --shadow-md: 0 4px 12px oklch(0 0 0 / 0.4);
  --shadow-lg: 0 12px 32px oklch(0 0 0 / 0.5);
}

/* ============================================
   LIGHT MODE
   ============================================ */
[data-theme="light"] {
  --color-bg:             #f1f5f9;
  --color-surface:        #ffffff;
  --color-surface-2:      #f8fafc;
  --color-surface-offset: #e2e8f0;
  --color-surface-offset-2: #cbd5e1;
  --color-surface-dynamic: #e2e8f0;
  --color-divider:        #e2e8f0;
  --color-border:         #cbd5e1;

  --color-text:           #0f172a;
  --color-text-muted:     #475569;
  --color-text-faint:     #94a3b8;
  --color-text-inverse:   #f8fafc;

  --color-primary:        #16a34a;
  --color-primary-hover:  #15803d;
  --color-primary-active: #166534;
  --color-primary-highlight: #dcfce7;

  --color-gold:           #d97706;
  --color-gold-hover:     #b45309;

  --color-success:        #16a34a;
  --color-error:          #dc2626;
  --color-warning:        #d97706;

  --color-blue:           #2563eb;
  --color-blue-hover:     #1d4ed8;

  --shadow-sm: 0 1px 2px oklch(0.2 0.01 250 / 0.06);
  --shadow-md: 0 4px 12px oklch(0.2 0.01 250 / 0.08);
  --shadow-lg: 0 12px 32px oklch(0.2 0.01 250 / 0.12);
}


/* Header background per theme */
[data-theme="light"] .header { background: rgba(241, 245, 249, 0.95); }
@media (prefers-color-scheme: light) {
  :root:not([data-theme]) {
    --color-bg:             #f1f5f9;
    --color-surface:        #ffffff;
    --color-surface-2:      #f8fafc;
    --color-surface-offset: #e2e8f0;
    --color-surface-offset-2: #cbd5e1;
    --color-surface-dynamic: #e2e8f0;
    --color-divider:        #e2e8f0;
    --color-border:         #cbd5e1;
    --color-text:           #0f172a;
    --color-text-muted:     #475569;
    --color-text-faint:     #94a3b8;
    --color-text-inverse:   #f8fafc;
    --color-primary:        #16a34a;
    --color-primary-hover:  #15803d;
    --color-primary-active: #166534;
    --color-primary-highlight: #dcfce7;
    --color-gold:           #d97706;
    --color-gold-hover:     #b45309;
    --color-success:        #16a34a;
    --color-error:          #dc2626;
    --color-warning:        #d97706;
    --color-blue:           #2563eb;
    --color-blue-hover:     #1d4ed8;
    --shadow-sm: 0 1px 2px oklch(0.2 0.01 250 / 0.06);
    --shadow-md: 0 4px 12px oklch(0.2 0.01 250 / 0.08);
    --shadow-lg: 0 12px 32px oklch(0.2 0.01 250 / 0.12);
  }
}

/* ============================================
   GLOBAL STYLES
   ============================================ */

a { color: var(--color-primary); text-decoration: none; }
a:hover { color: var(--color-primary-hover); }

.container {
  max-width: var(--content-wide);
  margin-inline: auto;
  padding-inline: var(--space-4);
}

/* ============================================
   HEADER / NAV
   ============================================ */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10, 14, 23, 0.95);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--color-border);
  padding: var(--space-3) 0;
}

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

.logo {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: var(--text-lg);
  color: var(--color-text);
  text-decoration: none;
}
.logo:hover { color: var(--color-text); }
.logo .afl { color: var(--color-primary); }
.logo .bet { color: var(--color-gold); }

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

.nav a {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-text-muted);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-md);
  text-decoration: none;
  white-space: nowrap;
}
.nav a:hover, .nav a.active {
  color: var(--color-text);
  background: var(--color-surface-dynamic);
}

.nav-toggle {
  display: none;
  color: var(--color-text);
  padding: var(--space-2);
}

.theme-toggle {
  color: var(--color-text-muted);
  padding: var(--space-2);
  border-radius: var(--radius-md);
}
.theme-toggle:hover { color: var(--color-text); background: var(--color-surface-dynamic); }

@media (max-width: 900px) {
  .nav-toggle { display: block; }
  .nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-surface);
    border-bottom: 1px solid var(--color-border);
    padding: var(--space-4);
    flex-direction: column;
    align-items: stretch;
    gap: var(--space-1);
  }
  .nav.open { display: flex; }
  .nav a { padding: var(--space-3) var(--space-4); }
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero {
  position: relative;
  padding: clamp(var(--space-10), 6vw, var(--space-20)) 0;
  overflow: hidden;
  text-align: center;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 20% 50%, oklch(0.4 0.15 145 / 0.15) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 30%, oklch(0.5 0.12 45 / 0.1) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 80%, oklch(0.3 0.1 250 / 0.08) 0%, transparent 60%);
  z-index: 0;
}

.hero .container { position: relative; z-index: 1; }

.hero h1 {
  font-family: var(--font-display);
  font-size: var(--text-hero);
  font-weight: 800;
  line-height: 1.05;
  margin-bottom: var(--space-4);
  letter-spacing: -0.03em;
}
.hero h1 .green { color: var(--color-primary); }
.hero h1 .gold { color: var(--color-gold); }

.hero p {
  font-size: var(--text-lg);
  color: var(--color-text-muted);
  max-width: 60ch;
  margin-inline: auto;
  margin-bottom: var(--space-8);
}

.hero-cta {
  display: flex;
  gap: var(--space-4);
  justify-content: center;
  flex-wrap: wrap;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 600;
  padding: var(--space-3) var(--space-6);
  border-radius: var(--radius-lg);
  text-decoration: none;
  cursor: pointer;
  border: none;
}

.btn-primary {
  background: var(--color-primary);
  color: #fff;
}
.btn-primary:hover { background: var(--color-primary-hover); color: #fff; }

.btn-outline {
  background: transparent;
  color: var(--color-text);
  border: 1px solid var(--color-border);
}
.btn-outline:hover { background: var(--color-surface-dynamic); color: var(--color-text); }

.btn-gold {
  background: var(--color-gold);
  color: #000;
}
.btn-gold:hover { background: var(--color-gold-hover); color: #000; }

.btn-sm {
  font-size: var(--text-xs);
  padding: var(--space-2) var(--space-4);
}

/* ============================================
   SECTION STYLES
   ============================================ */
.section {
  padding: clamp(var(--space-8), 4vw, var(--space-16)) 0;
}

.section-header {
  margin-bottom: var(--space-8);
}

.section-header h2 {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 700;
  margin-bottom: var(--space-2);
}

.section-header p {
  color: var(--color-text-muted);
  font-size: var(--text-base);
}

.section-header .overline {
  display: inline-block;
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-primary);
  margin-bottom: var(--space-2);
}

/* ============================================
   CARDS
   ============================================ */
.card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  transition: box-shadow var(--transition-interactive), border-color var(--transition-interactive);
}
.card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--color-primary);
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(320px, 100%), 1fr));
  gap: var(--space-6);
}

.card-grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(280px, 100%), 1fr));
  gap: var(--space-4);
}

/* ============================================
   LADDER TABLE
   ============================================ */
.ladder-table {
  overflow-x: auto;
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
}

.ladder-table table {
  min-width: 700px;
}

.ladder-table th {
  font-size: var(--text-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-text-muted);
  padding: var(--space-3) var(--space-4);
  text-align: left;
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  white-space: nowrap;
  position: sticky;
  top: 0;
}

.ladder-table td {
  font-size: var(--text-sm);
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--color-divider);
  white-space: nowrap;
  font-variant-numeric: tabular-nums lining-nums;
}

.ladder-table tr:hover td {
  background: var(--color-surface-dynamic);
}

.ladder-table .pos { font-weight: 700; width: 40px; text-align: center; }
.ladder-table .team-name { font-weight: 600; }

.top-8 td:first-child {
  border-left: 3px solid var(--color-primary);
}

.form-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 700;
  margin-right: 2px;
}
.form-w { background: var(--color-success); color: #fff; }
.form-l { background: var(--color-error); color: #fff; }

/* ============================================
   ODDS DISPLAY
   ============================================ */
.odds-value {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--color-gold);
  font-variant-numeric: tabular-nums;
}

.odds-pill {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  background: var(--color-surface-dynamic);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  font-weight: 600;
}

/* ============================================
   TEAM CARDS
   ============================================ */
.team-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: box-shadow var(--transition-interactive), transform var(--transition-interactive);
}
.team-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

.team-card-header {
  padding: var(--space-4) var(--space-6);
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--color-divider);
}

.team-card-header h3 {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 700;
}

.team-card-body {
  padding: var(--space-4) var(--space-6);
}

.team-card-body p {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.6;
  margin-bottom: var(--space-3);
}

.team-stat-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-2) 0;
  border-bottom: 1px solid var(--color-divider);
  font-size: var(--text-sm);
}
.team-stat-row:last-child { border-bottom: none; }
.team-stat-row .label { color: var(--color-text-muted); }
.team-stat-row .value { font-weight: 600; font-variant-numeric: tabular-nums; }

/* ============================================
   FIXTURE CARDS
   ============================================ */
.fixture-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-4) var(--space-6);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: var(--space-4);
  margin-bottom: var(--space-3);
  transition: border-color var(--transition-interactive);
}
.fixture-card:hover { border-color: var(--color-primary); }

.fixture-team {
  display: flex;
  flex-direction: column;
}
.fixture-team.away { text-align: right; }
.fixture-team-name {
  font-weight: 600;
  font-size: var(--text-sm);
}
.fixture-team-record {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
}

.fixture-vs {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-1);
}
.fixture-vs .vs-text {
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--color-text-faint);
  text-transform: uppercase;
}
.fixture-vs .odds-display {
  display: flex;
  gap: var(--space-2);
}

.fixture-result {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.fixture-score {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 700;
}
.fixture-score .winner { color: var(--color-primary); }

/* ============================================
   STRATEGY / TIPS CONTENT
   ============================================ */
.strategy-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
}

.strategy-card h3 {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 700;
  margin-bottom: var(--space-3);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.strategy-card p, .strategy-card li {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.7;
  margin-bottom: var(--space-2);
}

.strategy-card ul {
  list-style: none;
  padding: 0;
}
.strategy-card ul li {
  padding-left: var(--space-5);
  position: relative;
}
.strategy-card ul li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--color-primary);
  font-weight: 600;
}

/* ============================================
   TIPS / PREDICTIONS
   ============================================ */
.prediction-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
}

.prediction-card .matchup {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-4);
}

.prediction-card .team-info {
  text-align: center;
}
.prediction-card .team-info.right { text-align: right; }

.prediction-card .team-name-lg {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--text-base);
}

.prediction-card .tip-label {
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-primary);
  margin-bottom: var(--space-1);
}

.prediction-card .confidence-bar {
  height: 6px;
  background: var(--color-surface-dynamic);
  border-radius: var(--radius-full);
  overflow: hidden;
  margin-top: var(--space-3);
}

.prediction-card .confidence-fill {
  height: 100%;
  background: var(--color-primary);
  border-radius: var(--radius-full);
  transition: width 0.6s ease;
}

/* ============================================
   STAT BADGES / TAGS
   ============================================ */
.badge {
  display: inline-flex;
  align-items: center;
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  font-weight: 600;
}
.badge-green { background: oklch(from var(--color-success) l c h / 0.15); color: var(--color-success); }
.badge-red { background: oklch(from var(--color-error) l c h / 0.15); color: var(--color-error); }
.badge-gold { background: oklch(from var(--color-gold) l c h / 0.15); color: var(--color-gold); }
.badge-blue { background: oklch(from var(--color-blue) l c h / 0.15); color: var(--color-blue); }

/* ============================================
   TABS
   ============================================ */
.tabs {
  display: flex;
  gap: var(--space-1);
  border-bottom: 1px solid var(--color-border);
  margin-bottom: var(--space-6);
  overflow-x: auto;
}
.tab {
  padding: var(--space-3) var(--space-5);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-text-muted);
  border-bottom: 2px solid transparent;
  cursor: pointer;
  white-space: nowrap;
  background: none;
  border-top: none;
  border-left: none;
  border-right: none;
}
.tab:hover { color: var(--color-text); }
.tab.active {
  color: var(--color-primary);
  border-bottom-color: var(--color-primary);
}

.tab-content { display: none; }
.tab-content.active { display: block; }

/* ============================================
   FOOTER
   ============================================ */
.footer {
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
  padding: var(--space-12) 0 var(--space-8);
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(200px, 100%), 1fr));
  gap: var(--space-8);
  margin-bottom: var(--space-8);
}

.footer h4 {
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 700;
  margin-bottom: var(--space-4);
  color: var(--color-text);
}

.footer ul { list-style: none; padding: 0; }
.footer ul li { margin-bottom: var(--space-2); }
.footer ul a {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}
.footer ul a:hover { color: var(--color-primary); }

.footer-bottom {
  border-top: 1px solid var(--color-border);
  padding-top: var(--space-6);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-4);
  font-size: var(--text-xs);
  color: var(--color-text-faint);
}

.gambling-disclaimer {
  background: var(--color-surface-offset);
  border: 1px solid var(--color-warning);
  border-radius: var(--radius-lg);
  padding: var(--space-4) var(--space-6);
  margin-bottom: var(--space-6);
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  line-height: 1.6;
}
.gambling-disclaimer strong { color: var(--color-warning); }

/* ============================================
   UTILITIES
   ============================================ */
.text-center { text-align: center; }
.text-primary { color: var(--color-primary); }
.text-gold { color: var(--color-gold); }
.text-muted { color: var(--color-text-muted); }
.text-faint { color: var(--color-text-faint); }
.fw-700 { font-weight: 700; }
.mb-4 { margin-bottom: var(--space-4); }
.mb-6 { margin-bottom: var(--space-6); }
.mb-8 { margin-bottom: var(--space-8); }
.mt-4 { margin-top: var(--space-4); }
.mt-6 { margin-top: var(--space-6); }
.mt-8 { margin-top: var(--space-8); }

.two-col {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(480px, 100%), 1fr));
  gap: var(--space-8);
}

/* Page title area */
.page-hero {
  padding: var(--space-12) 0 var(--space-8);
  border-bottom: 1px solid var(--color-border);
  margin-bottom: var(--space-8);
}
.page-hero h1 {
  font-family: var(--font-display);
  font-size: var(--text-2xl);
  font-weight: 800;
  margin-bottom: var(--space-2);
}
.page-hero p {
  font-size: var(--text-base);
  color: var(--color-text-muted);
  max-width: 60ch;
}

/* Animate in */
.animate-in {
  opacity: 0;
  transform: translateY(16px);
  animation: fadeInUp 0.5s ease forwards;
}
@keyframes fadeInUp {
  to { opacity: 1; transform: translateY(0); }
}

/* Scroll reveal */
.reveal-disabled {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal-disabled.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Featured banner */
.featured-banner {
  background: linear-gradient(135deg, var(--color-surface-2), var(--color-surface));
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: var(--space-8);
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: var(--space-6);
}
@media (max-width: 600px) {
  .featured-banner { grid-template-columns: 1fr; text-align: center; }
}

.featured-banner h3 {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 700;
  margin-bottom: var(--space-2);
}
.featured-banner p {
  color: var(--color-text-muted);
  font-size: var(--text-sm);
}

/* Quick stats row */
.quick-stats {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(160px, 100%), 1fr));
  gap: var(--space-4);
}

.quick-stat {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-4);
  text-align: center;
}
.quick-stat .stat-value {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: var(--space-1);
}
.quick-stat .stat-label {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* Team color accents (via inline style or class) */
.team-accent { border-left: 4px solid var(--team-color, var(--color-primary)); }

/* Rating stars */
.rating { color: var(--color-gold); font-size: var(--text-sm); letter-spacing: 2px; }

/* Responsive odds grid */
.odds-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(200px, 100%), 1fr));
  gap: var(--space-3);
}

.odds-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-4);
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: border-color var(--transition-interactive);
}
.odds-card:hover { border-color: var(--color-gold); }
.odds-card .team { font-weight: 600; font-size: var(--text-sm); }
.odds-card .price {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--text-base);
  color: var(--color-gold);
}

/* ============================================
   SEARCH OVERLAY
   ============================================ */
.search-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: oklch(from var(--color-bg) l c h / 0.95);
  backdrop-filter: blur(20px);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 15vh;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}
.search-overlay.active {
  opacity: 1;
  pointer-events: all;
}
.search-overlay input {
  width: min(90%, 600px);
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 700;
  background: transparent;
  border: none;
  border-bottom: 2px solid var(--color-primary);
  color: var(--color-text);
  padding: var(--space-4) 0;
  outline: none;
}
.search-overlay input::placeholder { color: var(--color-text-faint); }
.search-overlay .search-results {
  width: min(90%, 600px);
  margin-top: var(--space-6);
  max-height: 50vh;
  overflow-y: auto;
}
.search-result-item {
  display: block;
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  color: var(--color-text);
  text-decoration: none;
  transition: background 0.15s ease;
}
.search-result-item:hover { background: var(--color-surface-dynamic); color: var(--color-text); }
.search-result-item .result-title { font-weight: 600; }
.search-result-item .result-desc { font-size: var(--text-xs); color: var(--color-text-muted); }
.search-close {
  position: absolute;
  top: var(--space-6);
  right: var(--space-6);
  color: var(--color-text-muted);
  padding: var(--space-3);
  border-radius: var(--radius-md);
  cursor: pointer;
  background: none;
  border: none;
}
.search-close:hover { color: var(--color-text); background: var(--color-surface-dynamic); }

/* ============================================
   SEARCH TOGGLE (NAV BAR)
   ============================================ */
.search-toggle {
  color: var(--color-text-muted);
  padding: var(--space-2);
  border-radius: var(--radius-md);
  background: none;
  border: none;
  cursor: pointer;
}
.search-toggle:hover { color: var(--color-text); background: var(--color-surface-dynamic); }

/* ============================================
   BREADCRUMBS
   ============================================ */
.breadcrumbs {
  padding: var(--space-4) 0 var(--space-2);
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.breadcrumbs a { color: var(--color-text-muted); }
.breadcrumbs a:hover { color: var(--color-primary); }

/* ============================================
   BACK TO TOP BUTTON
   ============================================ */
.back-to-top {
  position: fixed;
  bottom: var(--space-6);
  right: var(--space-6);
  z-index: 50;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-full);
  background: var(--color-primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  box-shadow: var(--shadow-md);
}
.back-to-top.visible {
  opacity: 1;
  transform: translateY(0);
}
.back-to-top:hover { background: var(--color-primary-hover); }

/* ============================================
   READING PROGRESS BAR
   ============================================ */
.reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: var(--color-primary);
  z-index: 101;
  transition: width 50ms linear;
  width: 0%;
}

/* ============================================
   CALCULATOR INPUTS (shared)
   ============================================ */
.calc-input, .calc-select {
  background: var(--color-surface-2);
  border: 1px solid var(--color-border);
  color: var(--color-text);
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-size: var(--text-base);
  width: 100%;
  transition: border-color var(--transition-interactive), box-shadow var(--transition-interactive);
}
.calc-input:focus, .calc-select:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px oklch(from var(--color-primary) l c h / 0.15);
}
.calc-input::placeholder { color: var(--color-text-faint); }

.input-group { margin-bottom: var(--space-4); }
.input-group label {
  display: block;
  font-size: var(--text-sm);
  font-weight: 600;
  margin-bottom: var(--space-2);
  color: var(--color-text);
}

.calc-result {
  background: var(--color-primary-highlight);
  border: 1px solid var(--color-primary);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  text-align: center;
}
.calc-result .result-value {
  font-family: var(--font-display);
  font-size: var(--text-2xl);
  font-weight: 800;
  color: var(--color-primary);
}
.calc-result .result-label {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  margin-top: var(--space-1);
}

/* ============================================
   QUIZ COMPONENTS
   ============================================ */
.quiz-progress {
  height: 6px;
  background: var(--color-surface-dynamic);
  border-radius: var(--radius-full);
  overflow: hidden;
  margin-bottom: var(--space-6);
}
.quiz-progress-fill {
  height: 100%;
  background: var(--color-primary);
  border-radius: var(--radius-full);
  transition: width 0.4s ease;
}

.quiz-option {
  display: block;
  width: 100%;
  text-align: left;
  padding: var(--space-4) var(--space-5);
  background: var(--color-surface);
  border: 2px solid var(--color-border);
  border-radius: var(--radius-lg);
  color: var(--color-text);
  font-size: var(--text-sm);
  font-weight: 500;
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease;
  margin-bottom: var(--space-3);
  font-family: var(--font-body);
}
.quiz-option:hover { border-color: var(--color-primary); background: var(--color-surface-2); }
.quiz-option.correct {
  border-color: var(--color-success);
  background: oklch(from var(--color-success) l c h / 0.1);
}
.quiz-option.incorrect {
  border-color: var(--color-error);
  background: oklch(from var(--color-error) l c h / 0.1);
}
.quiz-option.disabled { pointer-events: none; opacity: 0.7; }

.quiz-timer {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--text-lg);
  border: 3px solid var(--color-primary);
  color: var(--color-primary);
}
.quiz-timer.warning { border-color: var(--color-gold); color: var(--color-gold); }
.quiz-timer.danger { border-color: var(--color-error); color: var(--color-error); }

/* ============================================
   GLOSSARY COMPONENTS
   ============================================ */
.letter-nav {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1);
  padding: var(--space-4) 0;
  border-bottom: 1px solid var(--color-border);
  margin-bottom: var(--space-6);
  position: sticky;
  top: 56px;
  background: var(--color-bg);
  z-index: 10;
}
.letter-nav a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  font-weight: 700;
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  text-decoration: none;
}
.letter-nav a:hover { background: var(--color-surface-dynamic); color: var(--color-text); }
.letter-nav a.active { background: var(--color-primary); color: #fff; }
.letter-nav a.disabled { opacity: 0.3; pointer-events: none; }

.glossary-term {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-5) var(--space-6);
  margin-bottom: var(--space-3);
}
.glossary-term h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--text-base);
  margin-bottom: var(--space-2);
  display: flex;
  align-items: center;
  gap: var(--space-3);
}
.glossary-term .definition {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.65;
  margin-bottom: var(--space-3);
}
.glossary-term .example {
  background: var(--color-surface-2);
  border-left: 3px solid var(--color-gold);
  padding: var(--space-3) var(--space-4);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  line-height: 1.6;
}
.glossary-term .related {
  margin-top: var(--space-3);
  font-size: var(--text-xs);
  color: var(--color-text-faint);
}
.glossary-term .related a { color: var(--color-primary); }

.letter-section h2 {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 800;
  color: var(--color-primary);
  margin-bottom: var(--space-4);
  padding-top: var(--space-6);
}

/* ============================================
   EXPANDED NAV FOR 9 ITEMS (MORE/DROPDOWN on mobile)
   ============================================ */
@media (max-width: 1100px) and (min-width: 901px) {
  .nav a { font-size: var(--text-xs); padding: var(--space-2); }
}

/* ============================================
   CONFETTI (quiz results)
   ============================================ */
@keyframes confetti-fall {
  0% { transform: translateY(-100vh) rotate(0deg); opacity: 1; }
  100% { transform: translateY(100vh) rotate(720deg); opacity: 0; }
}
.confetti-piece {
  position: fixed;
  width: 10px;
  height: 10px;
  z-index: 300;
  animation: confetti-fall 3s ease-in forwards;
}

/* ============================================
   GLOSSARY SEARCH
   ============================================ */
.glossary-search {
  position: relative;
  margin-bottom: var(--space-4);
}
.glossary-search input {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  color: var(--color-text);
  padding: var(--space-4) var(--space-4) var(--space-4) var(--space-12);
  border-radius: var(--radius-lg);
  font-family: var(--font-body);
  font-size: var(--text-base);
  width: 100%;
}
.glossary-search input:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px oklch(from var(--color-primary) l c h / 0.15);
}
.glossary-search svg {
  position: absolute;
  left: var(--space-4);
  top: 50%;
  transform: translateY(-50%);
  color: var(--color-text-faint);
}
.glossary-count {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  margin-bottom: var(--space-4);
}

/* ============================================
   TEAM LOGOS
   ============================================ */
.team-logo {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-sm);
  object-fit: contain;
  flex-shrink: 0;
  vertical-align: middle;
}
.team-logo-lg {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  object-fit: contain;
  flex-shrink: 0;
}
.team-logo-xl {
  width: 96px;
  height: 96px;
  border-radius: var(--radius-md);
  object-fit: contain;
  flex-shrink: 0;
}

/* ============================================
   SPACING FIXES — Tighter category pages
   ============================================ */
.breadcrumbs + .page-hero,
.breadcrumbs + .section {
  padding-top: var(--space-4);
}
.page-hero {
  padding: var(--space-8) 0 var(--space-6);
  margin-bottom: var(--space-6);
}
/* Reduce gap between breadcrumbs and content */
.breadcrumbs {
  padding: var(--space-3) 0 0;
  margin-bottom: 0;
}

/* ============================================
   DROPDOWN NAV — Cleaner navigation
   ============================================ */
.nav-item {
  position: relative;
}
.nav-item > a,
.nav-item > button {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-text-muted);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-md);
  text-decoration: none;
  white-space: nowrap;
  background: none;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: var(--font-body);
}
.nav-item > a:hover, .nav-item > button:hover,
.nav-item > a.active, .nav-item > button.active,
.nav-item.open > button {
  color: var(--color-text);
  background: var(--color-surface-dynamic);
}
.nav-item .caret {
  transition: transform 0.2s ease;
}
.nav-item.open .caret {
  transform: rotate(180deg);
}
.nav-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  min-width: 200px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-2);
  box-shadow: var(--shadow-lg);
  z-index: 110;
}
.nav-item.open .nav-dropdown {
  display: block;
}
.nav-dropdown a {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-md);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--color-text-muted);
  text-decoration: none;
  white-space: nowrap;
}
.nav-dropdown a:hover {
  color: var(--color-text);
  background: var(--color-surface-dynamic);
}
.nav-dropdown a.active {
  color: var(--color-primary);
  background: var(--color-primary-highlight);
}
.nav-dropdown .dd-icon {
  width: 18px;
  height: 18px;
  color: var(--color-text-faint);
  flex-shrink: 0;
}
.nav-dropdown .dd-label {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  padding: var(--space-2) var(--space-3) var(--space-1);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.nav-dropdown .dd-divider {
  height: 1px;
  background: var(--color-border);
  margin: var(--space-2) var(--space-2);
}

/* Mobile: flatten dropdowns */
@media (max-width: 900px) {
  .nav-item { width: 100%; }
  .nav-item > button { width: 100%; justify-content: space-between; padding: var(--space-3) var(--space-4); }
  .nav-dropdown {
    position: static;
    box-shadow: none;
    border: none;
    padding: 0 0 0 var(--space-4);
    background: transparent;
    min-width: 0;
  }
  .nav-dropdown a { padding: var(--space-2) var(--space-4); }
}

/* ============================================
   TABLE MOBILE FIX — No overlap, no truncation
   ============================================ */
.ladder-table table { min-width: 0; width: 100%; }
.ladder-table th, .ladder-table td { padding: var(--space-2) var(--space-3); }
.ladder-table .team-name { white-space: normal; word-break: normal; }

/* Mobile: stack or hide less important columns */
@media (max-width: 640px) {
  .ladder-table th, .ladder-table td { padding: var(--space-2); font-size: 12px; }
  .ladder-table .hide-mobile { display: none; }
  .ladder-table .team-name { font-size: 13px; }
  .team-logo { width: 20px; height: 20px; }
}

/* Homepage tips table — card layout on mobile */
.tips-table-card { display: none; }
@media (max-width: 900px) {
  .tips-table-desktop { display: none; }
  .tips-table-card { display: block; }
}

/* Fixture cards mobile fix */
@media (max-width: 600px) {
  .fixture-card {
    grid-template-columns: 1fr;
    text-align: center;
    gap: var(--space-2);
  }
  .fixture-team, .fixture-team.away { text-align: center; }
  .fixture-vs { padding: var(--space-1) 0; }
}

/* ============================================
   ACCORDION / CONCERTINA
   ============================================ */
details.accordion {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  margin-bottom: var(--space-3);
  overflow: hidden;
}
details.accordion summary {
  padding: var(--space-4) var(--space-5);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--text-base);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  list-style: none;
  user-select: none;
  color: var(--color-text);
}
details.accordion summary::-webkit-details-marker { display: none; }
details.accordion summary::after {
  content: '+';
  font-size: var(--text-lg);
  font-weight: 400;
  color: var(--color-text-faint);
  flex-shrink: 0;
  transition: transform 0.2s ease;
}
details.accordion[open] summary::after {
  content: '\2212';
}
details.accordion .accordion-body {
  padding: 0 var(--space-5) var(--space-5);
}

/* Verdict box — prominent, green header */
.verdict-box {
  background: var(--color-primary-highlight);
  border: 2px solid var(--color-primary);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: var(--space-4);
}
.verdict-header {
  background: var(--color-primary);
  color: #fff;
  padding: var(--space-3) var(--space-5);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--text-base);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.verdict-body {
  padding: var(--space-5);
}

/* Stat bars — remove orange, use blue for away */
.stat-bar-away {
  background: #3b82f6 !important;
  color: #fff !important;
}

/* ============================================
   HOMEPAGE TIP CARDS — MOBILE STACK
   ============================================ */
@media (max-width: 768px) {
  .card[style*="grid-template-columns: auto 1fr auto"],
  .card[style*="grid-template-columns:auto 1fr auto"] {
    grid-template-columns: 1fr !important;
    gap: var(--space-3) !important;
    padding: var(--space-4) !important;
  }
}

/* ============================================
   MENU & THEME FIXES
   ============================================ */
/* Ensure header works in both modes */
.header {
  background: rgba(10, 14, 23, 0.97) !important;
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}
[data-theme="light"] .header {
  background: rgba(255, 255, 255, 0.97) !important;
}

/* Nav items — cleaner styling */
.nav > a, .nav-item > button {
  font-size: 14px !important;
  padding: 8px 14px !important;
  border-radius: 8px;
  color: var(--color-text-muted);
  transition: color 0.15s, background 0.15s;
}
.nav > a:hover, .nav > a.active,
.nav-item > button:hover, .nav-item.open > button {
  color: var(--color-text) !important;
  background: var(--color-surface-dynamic) !important;
}
.nav > a.active {
  color: #fff !important;
  background: var(--color-primary) !important;
}

/* Dropdown — better contrast */
.nav-dropdown {
  background: var(--color-surface) !important;
  border: 1px solid var(--color-border) !important;
  box-shadow: 0 8px 30px rgba(0,0,0,0.3) !important;
}
[data-theme="light"] .nav-dropdown {
  box-shadow: 0 8px 30px rgba(0,0,0,0.1) !important;
}

/* Theme toggle — ensure visibility */
.theme-toggle {
  background: none !important;
  border: none !important;
  cursor: pointer;
  padding: 8px;
  border-radius: 8px;
  color: var(--color-text-muted);
  display: flex;
  align-items: center;
}
.theme-toggle:hover {
  color: var(--color-text);
  background: var(--color-surface-dynamic) !important;
}

/* ============================================
   STAT BAR CONTRAST FIX
   ============================================ */
.stat-bar-home {
  background: #16a34a !important;
  color: #fff !important;
  font-weight: 800 !important;
  font-size: 13px !important;
  text-shadow: 0 1px 2px rgba(0,0,0,0.3);
  min-height: 32px;
}
.stat-bar-away {
  background: #1d4ed8 !important;
  color: #fff !important;
  font-weight: 800 !important;
  font-size: 13px !important;
  text-shadow: 0 1px 2px rgba(0,0,0,0.3);
  min-height: 32px;
}
.stat-bar-label {
  font-weight: 600 !important;
  font-size: 12px !important;
  color: var(--color-text) !important;
}

/* ============================================
   COMPREHENSIVE MOBILE UX FIX
   ============================================ */

/* Stat bars — stack on mobile */
@media (max-width: 640px) {
  .stat-bar-row {
    flex-direction: column;
    gap: 4px;
    margin-bottom: var(--space-3);
    padding-bottom: var(--space-3);
    border-bottom: 1px solid var(--color-divider);
  }
  .stat-bar-label {
    width: 100%;
    text-align: left;
    font-weight: 700;
    font-size: 11px;
    margin-bottom: 2px;
  }
  .stat-bar-row > div[style*="flex:1"] {
    width: 100%;
  }
  .stat-bar-home, .stat-bar-away {
    min-height: 28px;
    font-size: 12px !important;
  }
  
  /* Team logos smaller on mobile */
  .team-logo-xl { width: 64px !important; height: 64px !important; }
  
  /* Tip card teams tighter */
  .tip-card-teams img { width: 36px !important; height: 36px !important; }
  .tip-card-team-name { font-size: 13px !important; }
  .tip-card-score { font-size: var(--text-lg) !important; }
  
  /* Tables — wrap text, smaller font */
  .ladder-table th, .ladder-table td { 
    padding: 6px 8px; 
    font-size: 12px; 
  }
  
  /* Predictions compact */
  .prediction-card .matchup { flex-direction: column; gap: var(--space-2); }
  
  /* Player props table scroll */
  .player-props-table { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .player-props-table table { min-width: 500px; }
  
  /* Section spacing tighter */
  .section { padding: var(--space-6) 0 !important; }
  .section-header { margin-bottom: var(--space-4); }
  .section-header h2 { font-size: var(--text-lg); }
  
  /* Container padding */
  .container { padding-inline: var(--space-3); }
  
  /* Cards tighter */
  .card { padding: var(--space-4); }
  
  /* Footer compact */
  .footer-grid { gap: var(--space-4); }
  
  /* Hide non-essential columns */
  .hide-mobile { display: none !important; }
}

/* Player props — make scrollable on all screens */
.player-props-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
}
.player-props-wrap table {
  min-width: 500px;
  width: 100%;
}

/* General table improvement */
table { border-collapse: collapse; width: 100%; }
th { position: sticky; top: 0; }

/* Tighter section spacing globally */
.section-header h2 { margin-bottom: var(--space-1); }
.section-header p { margin-bottom: 0; }

/* ============================================
   EXPANDED FOOTER — Publication quality
   ============================================ */
@media (max-width: 768px) {
  .footer-top-grid {
    grid-template-columns: 1fr !important;
    gap: var(--space-4) !important;
  }
  .footer-top-grid > div:last-child {
    justify-content: flex-start !important;
  }
}
.footer h4 {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: var(--space-3);
}
.footer ul li {
  margin-bottom: var(--space-1);
}
.footer ul a {
  font-size: 13px;
  line-height: 1.6;
}

/* ============================================
   TIP CARDS — EQUAL HEIGHT
   ============================================ */
.tips-grid {
  align-items: stretch;
}
.tip-card {
  display: flex !important;
  flex-direction: column;
  height: 100%;
}
.tip-card-header {
  flex-shrink: 0;
}
.tip-card-body {
  flex: 1;
  display: flex;
  flex-direction: column;
}
.tip-card-summary {
  flex: 1;
}
.tip-card-cta {
  flex-shrink: 0;
  margin-top: auto;
}

/* ============================================
   NWG DESIGN SYSTEM — Applied to Footy Bets
   ============================================ */

/* Callout boxes for founder quotes */
.callout {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-left: 4px solid var(--color-primary);
  border-radius: var(--radius-md);
  padding: var(--space-4) var(--space-5);
  margin: var(--space-5) 0;
}
.callout-header {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-3);
}
.callout-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}
.callout-name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--text-sm);
}
.callout-role {
  font-size: 11px;
  color: var(--color-text-faint);
}
.callout-body {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.65;
  font-style: italic;
}

/* Prose content — for long-form articles */
.prose { max-width: 720px; }
.prose h2 {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 700;
  margin: var(--space-8) 0 var(--space-4);
}
.prose h3 {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 700;
  margin: var(--space-6) 0 var(--space-3);
}
.prose p {
  font-size: var(--text-base);
  line-height: 1.7;
  color: var(--color-text-muted);
  margin-bottom: var(--space-4);
}
.prose ul, .prose ol {
  padding-left: var(--space-5);
  margin-bottom: var(--space-4);
}
.prose li {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.65;
  margin-bottom: var(--space-2);
}
.prose strong { color: var(--color-text); }

/* Worked example boxes */
.worked-example {
  background: var(--color-surface-2, var(--color-surface));
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  margin: var(--space-5) 0;
}
.worked-example-header {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--text-sm);
  color: var(--color-primary);
  margin-bottom: var(--space-3);
}
.worked-example-header svg { flex-shrink: 0; }

/* Content layout with sidebar */
.content-layout--sidebar {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
}
@media (min-width: 900px) {
  .content-layout--sidebar {
    grid-template-columns: 1fr 320px;
  }
}
.content-sidebar {
  position: sticky;
  top: 80px;
  align-self: start;
}

/* Alt section background rhythm */
.section-alt { background: var(--color-surface-offset, var(--color-surface-2, #0f1520)); }
[data-theme="light"] .section-alt { background: #f0f2f5; }

/* Improved card hover — NWG style */
.card {
  transition: box-shadow 0.2s ease, border-color 0.2s ease;
}
.card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--color-primary);
}

/* Pill buttons */
.btn--pill {
  border-radius: var(--radius-full);
  padding: var(--space-2) var(--space-5);
  font-size: var(--text-sm);
  font-weight: 600;
}

/* TOC sidebar */
.toc {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-4);
}
.toc h4 {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-text-faint);
  margin-bottom: var(--space-3);
}
.toc a {
  display: block;
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  padding: var(--space-1) 0;
  text-decoration: none;
}
.toc a:hover { color: var(--color-primary); }
