:root {
  --bg: #f6f7fb; --panel: #ffffff; --text: #1c2030; --muted: #667085; --line: #e4e7ef; --accent: #0070d1;
  --platinum: #7f9cc0; --gold: #c9971c; --silver: #8d939e; --bronze: #b06a35; --bar: #e8ebf2;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1218; --panel: #171b24; --text: #e7eaf1; --muted: #98a2b3; --line: #262c39; --accent: #4aa3ff;
    --platinum: #a9c3e6; --gold: #f0c04a; --silver: #c3c8d1; --bronze: #d58a52; --bar: #232937;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text);
  font: 16px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
code { font: 0.9em ui-monospace, SFMono-Regular, Consolas, monospace; background: var(--bar); padding: 0.1em 0.35em; border-radius: 4px; }

.top { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
  max-width: 960px; margin: 0 auto; padding: 1rem; }
.brand { color: var(--text); font-size: 1.15rem; display: flex; align-items: center; gap: 0.5rem; }
.brand:hover { text-decoration: none; }
.cup { width: 1.1rem; height: 1.1rem; border-radius: 0 0 50% 50%; background: var(--gold); display: inline-block; }
nav a { margin-left: 1rem; color: var(--muted); }
nav a:first-child { margin-left: 0; }

main { max-width: 960px; margin: 0 auto; padding: 0 1rem 2rem; }
section { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 1.25rem; margin-bottom: 1rem; }
h1 { font-size: 1.6rem; margin: 0 0 0.75rem; }
h2 { font-size: 1.15rem; margin: 0 0 0.75rem; }
.muted { color: var(--muted); }
.small { font-size: 0.85rem; }

.table-wrap { overflow-x: auto; }
table.board { width: 100%; border-collapse: collapse; min-width: 560px; }
.board th, .board td { padding: 0.6rem 0.5rem; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
.board th { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.04em; color: var(--muted); font-weight: 600; }
.board tr:last-child td { border-bottom: 0; }
.num { text-align: right !important; font-variant-numeric: tabular-nums; }
.rank { color: var(--muted); width: 2rem; font-variant-numeric: tabular-nums; }

.grades { display: inline-flex; gap: 0.4rem; flex-wrap: wrap; }
.g { display: inline-flex; align-items: center; gap: 0.3rem; font-variant-numeric: tabular-nums; font-weight: 600; }
.g::before { content: ""; width: 0.7rem; height: 0.7rem; border-radius: 50%; background: currentColor; opacity: 0.9; }
.g.platinum { color: var(--platinum); } .g.gold { color: var(--gold); }
.g.silver { color: var(--silver); } .g.bronze { color: var(--bronze); }
.g.dot::before { width: 0.75rem; height: 0.75rem; }

.feed { list-style: none; margin: 0; padding: 0; }
.feed li { display: flex; align-items: baseline; gap: 0.6rem; padding: 0.5rem 0; border-bottom: 1px solid var(--line); }
.feed li:last-child { border-bottom: 0; }
.feed .what { flex: 1; }
.feed time { color: var(--muted); font-size: 0.85rem; white-space: nowrap; }

.stats { display: flex; flex-wrap: wrap; gap: 0.5rem 1.25rem; align-items: center; }

.games { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.9rem; }
.games li { padding-bottom: 0.9rem; border-bottom: 1px solid var(--line); }
.games li:last-child { border-bottom: 0; padding-bottom: 0; }
.game-head, .game-foot { display: flex; justify-content: space-between; gap: 1rem; align-items: baseline; flex-wrap: wrap; }
.game-name { font-weight: 600; }
.bar { height: 8px; background: var(--bar); border-radius: 99px; overflow: hidden; margin: 0.4rem 0; }
.fill { display: block; height: 100%; background: var(--accent); border-radius: 99px; }
.fill.p100 { background: var(--platinum); }
.p0{width:0}.p5{width:5%}.p10{width:10%}.p15{width:15%}.p20{width:20%}.p25{width:25%}.p30{width:30%}
.p35{width:35%}.p40{width:40%}.p45{width:45%}.p50{width:50%}.p55{width:55%}.p60{width:60%}.p65{width:65%}
.p70{width:70%}.p75{width:75%}.p80{width:80%}.p85{width:85%}.p90{width:90%}.p95{width:95%}.p100{width:100%}

.prose { max-width: 70ch; }
.prose ul { padding-left: 1.2rem; }
footer { max-width: 960px; margin: 0 auto; padding: 0 1rem 2rem; color: var(--muted); font-size: 0.85rem; }
@media (max-width: 600px) { section { padding: 1rem; border-radius: 10px; } h1 { font-size: 1.35rem; } }
