:root {
  --bg: #0f1220;
  --panel: #1a1e33;
  --panel-2: #232844;
  --text: #e8eaf2;
  --muted: #9aa1b8;
  --gold: #f5c518;
  --green: #35c47e;
  --red: #ff5d5d;
  --blue: #4d8bff;
  --line: #2c3350;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.45;
}
header {
  padding: 28px 24px 20px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, #151a30, #0f1220);
}
.brand { font-size: 26px; font-weight: 800; letter-spacing: .3px; }
.subtitle { color: var(--muted); margin-top: 4px; }
main { max-width: 1080px; margin: 0 auto; padding: 20px 24px 60px; }
section { margin: 34px 0; }
h2 { font-size: 19px; margin: 0 0 14px; border-left: 4px solid var(--blue); padding-left: 10px; }
h3 { font-size: 15px; margin: 0 0 8px; color: var(--muted); }
.hint { color: var(--muted); font-size: 13px; margin: 0 0 10px; }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px 16px;
}
.card .num { font-size: 24px; font-weight: 800; }
.card .lbl { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .6px; margin-top: 2px; }
.card .sub { font-size: 13px; margin-top: 4px; color: var(--text); }
.gold { color: var(--gold); }
.green { color: var(--green); }
.red { color: var(--red); }
.blue { color: var(--blue); }
.champions { display: flex; flex-wrap: wrap; gap: 10px; }
.champ {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px 16px;
  min-width: 180px;
}
.champ .year { font-weight: 800; color: var(--gold); }
.champ .team { margin-top: 2px; font-weight: 600; }
.champ .owner { color: var(--muted); font-size: 13px; }
.champ .meta { font-size: 13px; margin-top: 4px; }
.table-wrap { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; font-size: 14px; background: var(--panel); border-radius: 12px; overflow: hidden; }
th, td { padding: 8px 12px; text-align: right; border-bottom: 1px solid var(--line); white-space: nowrap; }
th { background: var(--panel-2); color: var(--muted); font-weight: 600; font-size: 12px; text-transform: uppercase; letter-spacing: .5px; }
td:first-child, th:first-child { text-align: left; }
tr:last-child td { border-bottom: none; }
tr:hover td { background: var(--panel-2); }
.pos { font-weight: 700; }
.heat-wrap { overflow-x: auto; }
.heat { border-collapse: collapse; font-size: 13px; }
.heat th, .heat td { text-align: center; padding: 5px 9px; }
.heat th:first-child, .heat td:first-child { text-align: left; }
.chart svg { width: 100%; height: auto; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; }
.bar { fill: var(--blue); }
.bar:hover { fill: var(--gold); }
.barlabel, .xlabel, .ylabel, .gridlabel { font-size: 11px; fill: var(--muted); text-anchor: middle; }
.grid { stroke: var(--line); stroke-dasharray: 3 3; }
.champ-cell { background: #b78f0b !important; color: #1a1200; font-weight: 800; }
.playoff-cell { background: rgba(53,196,126,.55); }
.empty-cell { color: transparent; }
.toggle { display: inline-block; margin-bottom: 10px; font-size: 14px; color: var(--muted); }
select {
  background: var(--panel-2); color: var(--text); border: 1px solid var(--line);
  border-radius: 8px; padding: 7px 12px; font-size: 14px; margin-bottom: 12px;
}
.cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 18px; }
.cols ol { margin: 0; padding-left: 20px; }
.cols li { margin-bottom: 6px; font-size: 14px; }
.cols li .muted { color: var(--muted); font-size: 12px; }
footer { color: var(--muted); font-size: 13px; text-align: center; padding: 24px; border-top: 1px solid var(--line); }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--muted); margin-top: 8px; }
.legend span::before { content: ""; display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 5px; }
@media (max-width: 640px) {
  .brand { font-size: 20px; }
  main { padding: 12px 14px 40px; }
}
.season-nav { display: flex; align-items: center; gap: 8px; margin: 0 0 14px; flex-wrap: wrap; }
.season-nav button {
  height: 36px;
  background: var(--panel-2); color: var(--text); border: 1px solid var(--line);
  border-radius: 8px; font-size: 18px; line-height: 1; padding: 0 12px; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
}
.season-nav button:hover { background: var(--panel); }
.season-nav select {
  height: 36px;
  margin: 0;
  padding: 0 26px 0 10px;
  font-size: 14px;
}
.season-nav select:focus { border-color: var(--blue); outline: none; }
#season-sub { color: var(--muted); font-size: 13px; padding-bottom: 1px; }
.week-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0 12px; }
.chip {
  border: 1px solid var(--line); background: var(--panel); color: var(--text);
  border-radius: 999px; padding: 4px 11px; font-size: 12px; cursor: pointer; font-family: inherit;
}
.chip.active { background: var(--blue); border-color: var(--blue); }
.chip.changed { border-color: var(--gold); color: var(--gold); }
.rename {
  display: flex; gap: 14px; align-items: baseline; background: var(--panel);
  border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; margin-bottom: 8px;
}
.rname { font-weight: 700; min-width: 150px; white-space: nowrap; }
.rchips { display: flex; flex-wrap: wrap; gap: 6px; }
.gold-text { color: var(--gold); }
