:root {
  --bg: #0e1424;
  --surface: #161e34;
  --surface-2: #1a2240;
  --border: #1f2842;
  --text: #e8eaf2;
  --muted: #8b91a8;
  --gold: #c9a24a;
  --gold-bright: #e2b95a;
  --diag: #2a3354;

  --radius: 12px;
  --radius-sm: 8px;
  --gutter: 20px;
  --max-w: 920px;

  --font-ui: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, 'SF Mono', monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-ui);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: 'cv11';
}
.gold { color: var(--gold); }
a { color: var(--gold); text-decoration: none; transition: color .15s ease; }
a:hover { color: var(--gold-bright); }
.tabular { font-variant-numeric: tabular-nums; }

main { display: block; padding: 0 var(--gutter); }
.section { max-width: var(--max-w); margin: 64px auto; }
.section__header { margin-bottom: 24px; }
.section__label {
  display: inline-block; font-size: 11px; letter-spacing: 2px; text-transform: uppercase;
  color: var(--muted); font-weight: 500; margin-bottom: 6px;
}
.section__title {
  margin: 0 0 6px; font-size: 28px; font-weight: 600; letter-spacing: -.4px;
}
.section__sub { margin: 0; color: var(--muted); font-size: 14px; }

@media (min-width: 720px) {
  :root { --gutter: 32px; }
  .section__title { font-size: 34px; }
}

.hero {
  position: relative;
  min-height: 88vh;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  background: var(--bg);
}
.hero__media {
  position: absolute; inset: 0;
  background: url('assets/statue/header.jpg') center/cover no-repeat;
  filter: saturate(1.05) brightness(.75);
}
.hero::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(14,20,36,.2) 0%, rgba(14,20,36,.85) 70%, var(--bg) 100%);
  pointer-events: none;
}
.hero__overlay {
  position: relative; z-index: 1;
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 32px var(--gutter) 48px;
  display: grid; gap: 18px;
}
.hero__eyebrow {
  display: inline-block;
  font-size: 11px; letter-spacing: 3px; text-transform: uppercase;
  color: var(--gold); font-weight: 600;
}
.hero__title {
  margin: 6px 0 0;
  font-size: 38px; line-height: 1.05;
  font-weight: 700; letter-spacing: -.8px;
}
.hero__tagline { margin: 6px 0 0; color: var(--muted); font-size: 14px; max-width: 460px; }
.hero__cta {
  display: inline-block; align-self: start;
  padding: 10px 16px; border: 1px solid var(--border);
  border-radius: 999px; font-size: 13px; color: var(--text);
  background: rgba(255,255,255,.04);
  transition: background .15s ease, border-color .15s ease;
}
.hero__cta:hover { background: rgba(201,162,74,.1); border-color: var(--gold); color: var(--gold); }

.hero__scoreboard {
  display: grid; grid-template-columns: 1fr 1fr 1fr;
  gap: 1px; background: var(--border);
  border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden;
}
.hero__scoreboard > div {
  background: rgba(14,20,36,.85); padding: 12px 14px;
  display: flex; flex-direction: column; gap: 4px;
}
.hero__scoreboard .nm { font-size: 11px; color: var(--muted); letter-spacing: 1px; text-transform: uppercase; }
.hero__scoreboard .val {
  font-family: var(--font-mono); font-variant-numeric: tabular-nums;
  font-size: 22px; font-weight: 600;
}
.hero__scoreboard .lead .val { color: var(--gold); }

@media (min-width: 720px) {
  .hero__title { font-size: 56px; }
  .hero__overlay { padding: 32px var(--gutter) 64px; gap: 24px; }
}

.cup__title { font-size: 28px; font-weight: 600; margin: 0 0 4px; }
.cup__sub { color: var(--muted); font-size: 13px; }

.standings { display: flex; flex-direction: column; gap: 10px; margin-top: 18px; }
.standings__row {
  display: grid; grid-template-columns: 32px 1fr auto;
  align-items: center; gap: 14px;
  padding: 14px 16px;
  background: var(--surface);
  border: 1px solid var(--border); border-radius: var(--radius);
}
.standings__pos {
  font-family: var(--font-mono); font-variant-numeric: tabular-nums;
  font-size: 12px; color: var(--muted);
}
.standings__main { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.standings__name { font-weight: 500; font-size: 15px; }
.standings__bar {
  height: 4px; background: var(--surface-2); border-radius: 2px; overflow: hidden;
}
.standings__bar > span {
  display: block; height: 100%;
  background: linear-gradient(90deg, #8b6c2a, var(--gold));
  border-radius: 2px;
  transition: width .4s ease;
}
.standings__val {
  font-family: var(--font-mono); font-variant-numeric: tabular-nums;
  font-size: 18px; font-weight: 600; color: var(--text);
}
.standings__row.lead .standings__val { color: var(--gold); }
.standings__row.lead .standings__pos { color: var(--gold); }
.standings__remaining {
  font-family: var(--font-mono); font-size: 11px; color: var(--muted);
  letter-spacing: .5px;
}
.standings__remaining.complete { color: var(--gold); }

.days { display: flex; flex-direction: column; gap: 10px; }
.day {
  display: grid; grid-template-columns: 80px 1fr auto;
  gap: 14px; align-items: center;
  padding: 14px 16px;
  background: var(--surface);
  border: 1px solid var(--border); border-radius: var(--radius);
}
.day__date {
  font-family: var(--font-mono); font-size: 12px; color: var(--muted);
  font-variant-numeric: tabular-nums; letter-spacing: .5px;
}
.day__main { min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.day__players { font-size: 13px; color: var(--muted); }
.day__winner {
  font-size: 15px; font-weight: 600; color: var(--gold);
}
.day__matches {
  font-family: var(--font-mono); font-variant-numeric: tabular-nums;
  font-size: 12px; color: var(--muted);
  display: flex; flex-direction: column; gap: 2px;
}
.day__note { font-size: 12px; color: var(--muted); font-style: italic; margin-top: 2px; }
.day__badge {
  font-family: var(--font-mono); font-size: 11px; color: var(--muted);
  border: 1px solid var(--border); border-radius: 999px;
  padding: 2px 8px;
}

.h2h {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--border);
  display: grid;
  grid-template-columns: 110px repeat(3, 1fr);
  gap: 1px;
}
.h2h__cell {
  background: var(--surface);
  padding: 14px 12px;
  text-align: center;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-size: 16px;
  font-weight: 600;
}
.h2h__head {
  background: var(--surface-2);
  font-family: var(--font-ui); font-weight: 500;
  font-size: 12px; color: var(--muted);
  letter-spacing: .5px; text-transform: uppercase;
  padding: 12px 10px;
  display: flex; align-items: center; justify-content: center;
}
.h2h__row-head { justify-content: flex-start; padding-left: 14px; }
.h2h__diag { background: var(--diag); color: var(--muted); font-weight: 400; }
.h2h__lead { color: var(--gold); }
@media (max-width: 520px) {
  .h2h { grid-template-columns: 80px repeat(3, 1fr); }
  .h2h__head { font-size: 10px; padding: 10px 6px; }
  .h2h__cell { font-size: 14px; padding: 10px 6px; }
}

.players {
  display: grid; grid-template-columns: 1fr; gap: 16px;
}
@media (min-width: 640px) { .players { grid-template-columns: repeat(3, 1fr); } }

.player {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex; flex-direction: column;
}
.player__photo {
  aspect-ratio: 3 / 4;
  width: 100%;
  object-fit: cover;
  display: block;
  background: var(--surface-2);
}
.player__body { padding: 16px; display: flex; flex-direction: column; gap: 8px; }
.player__name { margin: 0; font-size: 18px; font-weight: 600; }
.player__bio { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.5; }
.player__stats {
  display: flex; gap: 14px; margin-top: 6px;
  font-family: var(--font-mono); font-variant-numeric: tabular-nums;
  font-size: 12px; color: var(--muted);
}
.player__stat b { display: block; color: var(--text); font-size: 16px; font-weight: 600; }

.rules { display: grid; grid-template-columns: 1fr; gap: 16px; }
@media (min-width: 720px) { .rules { grid-template-columns: 1fr 1fr; } }
.rules__mode {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
}
.rules__mode h3 {
  margin: 0 0 10px; font-size: 16px; font-weight: 600;
  color: var(--gold); letter-spacing: .2px;
}
.rules__mode p, .rules__mode ol { margin: 0; color: var(--text); font-size: 14px; line-height: 1.6; }
.rules__mode ol { padding-left: 20px; display: flex; flex-direction: column; gap: 6px; }

.footer {
  max-width: var(--max-w);
  margin: 80px auto 40px;
  padding: 24px var(--gutter);
  border-top: 1px solid var(--border);
  display: flex; flex-direction: column; gap: 8px;
  color: var(--muted); font-size: 13px;
}
.footer__row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.footer__joke { margin: 0; font-size: 12px; opacity: .7; }
