/* World Cup 2026 colour palette */
:root {
  --navy:   #0a1628;
  --navy2:  #122040;
  --gold:   #c8a951;
  --gold2:  #e8c96b;
  --white:  #ffffff;
  --muted:  #8898b0;
  --red:    #c5203e;
  --yellow: #f5c518;
  --green:  #1a7a3a;
  --card-bg:#111e35;
  --border: #1e2f4a;
}

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

html { font-size: 16px; }

body {
  background: var(--navy);
  color: var(--white);
  font-family: 'Segoe UI', Arial, Helvetica, sans-serif;
  line-height: 1.5;
  min-height: 100vh;
}

/* ── Header ── */
.site-header {
  background: linear-gradient(135deg, var(--navy2) 0%, #0d1f3c 100%);
  border-bottom: 3px solid var(--gold);
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  position: sticky;
  top: 0;
  z-index: 100;
}

.site-header .trophy { font-size: 2rem; }

.site-header h1 {
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: var(--gold);
  text-transform: uppercase;
}

.site-header .subtitle {
  font-size: 0.78rem;
  color: var(--muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.site-header .last-updated {
  margin-left: auto;
  font-size: 0.72rem;
  color: var(--muted);
  text-align: right;
}

/* ── Layout ── */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 1.5rem 1rem 3rem;
}

.section-title {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.75rem;
  padding-bottom: 0.4rem;
  border-bottom: 1px solid var(--border);
}

section { margin-bottom: 2.5rem; }

/* ── Today's Fixtures ── */
.fixtures-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 0.75rem;
}

.fixture-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.9rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.fixture-card .fixture-stage {
  font-size: 0.65rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.fixture-teams {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.fixture-team {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-weight: 600;
  font-size: 0.9rem;
}

.fixture-team.away { flex-direction: row-reverse; text-align: right; }

.fixture-score {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--gold);
  min-width: 56px;
  justify-content: center;
}

.fixture-score .vs {
  font-size: 0.75rem;
  color: var(--muted);
  font-weight: 400;
}

.fixture-score .sep {
  color: var(--muted);
  font-size: 1rem;
}

.fixture-time {
  font-size: 0.72rem;
  color: var(--muted);
  text-align: center;
}

.badge-live {
  display: inline-block;
  background: var(--red);
  color: var(--white);
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  padding: 0.1rem 0.4rem;
  border-radius: 3px;
  vertical-align: middle;
  margin-left: 0.3rem;
  animation: pulse 1.5s infinite;
}

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

.no-fixtures {
  color: var(--muted);
  font-size: 0.9rem;
  padding: 1rem 0;
}

/* ── Leaderboards ── */
.leaderboards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

@media (max-width: 640px) {
  .leaderboards { grid-template-columns: 1fr; }
}

.leaderboard {}

.lb-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}

.lb-table th {
  text-align: left;
  padding: 0.45rem 0.6rem;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  border-bottom: 1px solid var(--border);
}

.lb-table th.right, .lb-table td.right { text-align: right; }

.lb-table tr.lb-row:nth-child(odd)  { background: var(--card-bg); }
.lb-table tr.lb-row:nth-child(even) { background: transparent; }

.lb-table tr.lb-row:first-child .rank { color: var(--gold); font-weight: 800; }
.lb-table tr.lb-row:nth-child(2) .rank { color: #9eaabc; }
.lb-table tr.lb-row:nth-child(3) .rank { color: #c47a3a; }

.lb-table td {
  padding: 0.55rem 0.6rem;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

.lb-table .rank {
  width: 28px;
  color: var(--muted);
  font-weight: 700;
  font-size: 0.8rem;
}

.lb-table .participant { font-weight: 600; }

.lb-table .teams {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  margin-top: 0.15rem;
}

.team-pill {
  font-size: 0.65rem;
  color: var(--muted);
  background: rgba(255,255,255,0.06);
  border-radius: 3px;
  padding: 0.05rem 0.35rem;
}

.lb-table .score-val {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--gold);
}

/* card icon colours */
.icon-yellow { color: var(--yellow); }
.icon-red    { color: var(--red); }

/* ── Loading / error states ── */
.state-msg {
  color: var(--muted);
  font-size: 0.9rem;
  padding: 2rem 0;
  text-align: center;
}

.error-msg { color: var(--red); }
