/* ==========================================================================
   KOSLEP LAN 2026
   Broadcast-style stat site. Dark, high contrast, team-coloured accents.
   ========================================================================== */

:root {
  --bg: #07090f;
  --bg-alt: #0b0f18;
  --panel: #10151f;
  --panel-2: #151b28;
  --panel-3: #1b2231;
  --line: #232c3d;
  --line-soft: #1a2130;

  --text: #e8edf7;
  --text-dim: #97a3b8;
  --text-faint: #616d82;

  --sven: #ff5c2b;
  --sven-soft: rgba(255, 92, 43, 0.14);
  --awisavi: #00d5ff;
  --awisavi-soft: rgba(0, 213, 255, 0.14);

  --gold: #ffc94d;
  --good: #45e08a;
  --bad: #ff4d6a;

  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 18px 40px -20px rgba(0, 0, 0, 0.9);

  --font: "Rajdhani", "Barlow Condensed", "Inter", system-ui, -apple-system,
    "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", "SF Mono", ui-monospace, Menlo, monospace;

  --maxw: 1240px;
}

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

[v-cloak] {
  display: none;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  background-image: radial-gradient(
      ellipse 900px 500px at 15% -5%,
      rgba(255, 92, 43, 0.13),
      transparent 60%
    ),
    radial-gradient(
      ellipse 900px 500px at 85% -5%,
      rgba(0, 213, 255, 0.13),
      transparent 60%
    );
  background-repeat: no-repeat;
}

h1,
h2,
h3,
h4 {
  margin: 0;
  font-weight: 700;
  letter-spacing: -0.01em;
}

a {
  color: inherit;
}

/* ---------- layout ------------------------------------------------------- */

.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

section.section {
  padding: 72px 0 24px;
}

.section-head {
  display: flex;
  align-items: baseline;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 26px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.section-head h2 {
  font-size: clamp(28px, 4vw, 40px);
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.section-head .eyebrow {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.section-head p {
  margin: 0;
  color: var(--text-dim);
  font-size: 15px;
  max-width: 62ch;
}

.subhead {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 40px 0 16px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.subhead::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line-soft);
}

/* ---------- nav ---------------------------------------------------------- */

.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(7, 9, 15, 0.82);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  height: 62px;
}

.nav-brand {
  display: flex;
  align-items: baseline;
  gap: 9px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-size: 15px;
  white-space: nowrap;
}

.nav-brand span {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.24em;
  color: var(--sven);
}

.nav-links {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;
}

.nav-links::-webkit-scrollbar {
  display: none;
}

.nav-links a {
  padding: 7px 13px;
  border-radius: 999px;
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-dim);
  white-space: nowrap;
  transition: background 0.15s, color 0.15s;
}

.nav-links a:hover {
  color: var(--text);
  background: var(--panel-2);
}

.nav-links a.active {
  color: #07090f;
  background: var(--text);
}

/* ---------- hero --------------------------------------------------------- */

.hero {
  padding: 64px 0 8px;
  text-align: center;
}

.hero-eyebrow {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.hero h1 {
  margin: 14px 0 4px;
  font-size: clamp(46px, 10vw, 104px);
  line-height: 0.92;
  letter-spacing: -0.03em;
  text-transform: uppercase;
  background: linear-gradient(100deg, var(--sven), var(--gold) 45%, var(--awisavi));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-sub {
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--text-dim);
}

/* scoreline */

.scoreline {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 18px;
  margin: 40px 0 8px;
  padding: 30px 26px;
  background: linear-gradient(180deg, var(--panel), var(--bg-alt));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.scoreline .side {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.scoreline .side.left {
  align-items: flex-end;
  text-align: right;
}

.scoreline .side.right {
  align-items: flex-start;
  text-align: left;
}

.scoreline .team-name {
  font-size: clamp(26px, 5vw, 46px);
  line-height: 1;
  text-transform: uppercase;
  letter-spacing: -0.01em;
}

.scoreline .team-name.sven {
  color: var(--sven);
}

.scoreline .team-name.awisavi {
  color: var(--awisavi);
}

.scoreline .team-tag {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.scoreline .maps {
  font-family: var(--mono);
  font-size: clamp(34px, 7vw, 60px);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.02em;
}

.scoreline .center {
  text-align: center;
  padding: 0 10px;
}

.scoreline .vs {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.24em;
  color: var(--text-faint);
  margin-bottom: 6px;
}

.champ-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-top: 4px;
  padding: 4px 11px;
  border-radius: 999px;
  background: rgba(255, 201, 77, 0.14);
  border: 1px solid rgba(255, 201, 77, 0.4);
  color: var(--gold);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

/* ---------- generic panels ---------------------------------------------- */

.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
}

.panel.tight {
  padding: 16px;
}

.panel-title {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin-bottom: 14px;
}

.grid {
  display: grid;
  gap: 16px;
}

.grid.cols-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid.cols-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.grid.cols-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

/* ---------- stat tiles --------------------------------------------------- */

.tile {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 18px 16px;
  overflow: hidden;
}

.tile::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  background: var(--line);
}

.tile.sven::before {
  background: var(--sven);
}

.tile.awisavi::before {
  background: var(--awisavi);
}

.tile.gold::before {
  background: var(--gold);
}

.tile .k {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.17em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.tile .v {
  font-size: 32px;
  font-weight: 700;
  line-height: 1.1;
  margin: 5px 0 2px;
  font-variant-numeric: tabular-nums;
}

.tile .v small {
  font-size: 15px;
  color: var(--text-dim);
  font-weight: 600;
}

.tile .d {
  font-size: 13px;
  color: var(--text-dim);
  line-height: 1.35;
}

/* featured headline tiles — the two stats the page leads with */

.tile.feature {
  padding: 26px 24px;
  background: linear-gradient(150deg, var(--panel-2), var(--panel) 62%);
  border-color: var(--line);
}

.tile.feature::before {
  width: 5px;
}

.tile.feature .k {
  font-size: 11px;
  letter-spacing: 0.22em;
}

.tile.feature .v {
  font-size: 62px;
  margin: 10px 0 6px;
  letter-spacing: -0.02em;
}

.tile.feature .v small {
  font-size: 24px;
}

.tile.feature .d {
  font-size: 14.5px;
}

.feature-with-face {
  display: flex;
  align-items: center;
  gap: 16px;
}

.tie-tag {
  margin-left: 8px;
  padding: 2px 7px;
  border-radius: 999px;
  background: rgba(255, 201, 77, 0.14);
  border: 1px solid rgba(255, 201, 77, 0.32);
  color: var(--gold);
  font-size: 8.5px;
  letter-spacing: 0.12em;
}

/* ---------- clutch record ------------------------------------------------ */

.clutch-row {
  display: grid;
  /* keep the fixed columns narrow — this panel is only half-width on desktop,
     and anything wider collapses the name column to nothing */
  grid-template-columns: 30px minmax(52px, 1fr) 44px 44px 34px 46px;
  align-items: center;
  gap: 8px;
  padding: 9px 0;
  border-bottom: 1px solid var(--line-soft);
}

.clutch-row:last-child {
  border-bottom: 0;
}

/* the record list needs real width for names — stack it earlier than cols-2 does */
@media (max-width: 1120px) {
  .grid.clutch-grid {
    grid-template-columns: 1fr;
  }
}

.cr-name {
  font-size: 13px;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cr-cell {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  line-height: 1.15;
}

.cr-cell span {
  font-family: var(--mono);
  font-size: 8.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.cr-cell b {
  font-family: var(--mono);
  font-size: 12.5px;
  font-variant-numeric: tabular-nums;
}

.cr-pct {
  font-family: var(--mono);
  font-size: 13.5px;
  font-weight: 700;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

/* ---------- callout ------------------------------------------------------ */

.callout {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  padding: 20px 22px;
  background: linear-gradient(
    100deg,
    rgba(255, 201, 77, 0.09),
    rgba(255, 201, 77, 0.02)
  );
  border: 1px solid rgba(255, 201, 77, 0.28);
  border-radius: var(--radius-sm);
}

.callout .big {
  font-family: var(--mono);
  font-size: 40px;
  font-weight: 700;
  line-height: 1;
  color: var(--gold);
}

.callout h4 {
  font-size: 17px;
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.callout p {
  margin: 0;
  color: var(--text-dim);
  font-size: 14px;
  max-width: 70ch;
}

/* ---------- MVP card ----------------------------------------------------- */

.mvp {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  gap: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--panel);
}

.mvp-left {
  padding: 26px;
  background: linear-gradient(150deg, var(--sven-soft), transparent 70%);
  border-right: 1px solid var(--line);
}

.mvp-left .label {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
}

.mvp-left .name {
  font-size: clamp(30px, 5vw, 44px);
  line-height: 1.02;
  margin: 8px 0 6px;
  text-transform: uppercase;
}

.mvp-left .team-pill {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 999px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.mvp-left p {
  margin: 14px 0 0;
  color: var(--text-dim);
  font-size: 14px;
}

.mvp-right {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
}

.mvp-stat {
  padding: 18px 16px;
  border-right: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
}

.mvp-stat .k {
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.mvp-stat .v {
  font-size: 26px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}

/* ---------- podium ------------------------------------------------------- */

.podium {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.podium-card {
  position: relative;
  padding: 20px 18px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: var(--panel);
  overflow: hidden;
}

.podium-card .rank {
  position: absolute;
  top: -12px;
  right: 10px;
  font-family: var(--mono);
  font-size: 62px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.045);
  line-height: 1;
}

.podium-card.p1 {
  border-color: rgba(255, 201, 77, 0.45);
  background: linear-gradient(160deg, rgba(255, 201, 77, 0.1), var(--panel) 60%);
}

.podium-card .pname {
  font-size: 22px;
  text-transform: uppercase;
  line-height: 1.1;
}

.podium-card .pstat {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--text-dim);
  margin-top: 8px;
}

.podium-card .pstat b {
  color: var(--text);
  font-size: 15px;
}

/* ---------- team pills / colours ---------------------------------------- */

.pill {
  display: inline-block;
  padding: 2px 9px;
  border-radius: 999px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  white-space: nowrap;
}

.pill.sven {
  background: var(--sven-soft);
  color: var(--sven);
  border: 1px solid rgba(255, 92, 43, 0.35);
}

.pill.awisavi {
  background: var(--awisavi-soft);
  color: var(--awisavi);
  border: 1px solid rgba(0, 213, 255, 0.35);
}

.pill.win {
  background: rgba(69, 224, 138, 0.14);
  color: var(--good);
  border: 1px solid rgba(69, 224, 138, 0.32);
}

.pill.loss {
  background: rgba(255, 77, 106, 0.12);
  color: var(--bad);
  border: 1px solid rgba(255, 77, 106, 0.3);
}

.pill.ot {
  background: rgba(255, 201, 77, 0.14);
  color: var(--gold);
  border: 1px solid rgba(255, 201, 77, 0.35);
}

.c-sven {
  color: var(--sven);
}

.c-awisavi {
  color: var(--awisavi);
}

/* ---------- avatars ------------------------------------------------------ */

.av {
  border-radius: 50%;
  object-fit: cover;
  background: var(--panel-3);
  flex: none;
  display: block;
}

.av.ring-sven {
  box-shadow: 0 0 0 2px var(--bg), 0 0 0 3.5px var(--sven);
}

.av.ring-awisavi {
  box-shadow: 0 0 0 2px var(--bg), 0 0 0 3.5px var(--awisavi);
}

.av.xs {
  width: 22px;
  height: 22px;
}

.av.sm {
  width: 34px;
  height: 34px;
}

.av.md {
  width: 52px;
  height: 52px;
}

.av.lg {
  width: 92px;
  height: 92px;
}

.av.xl {
  width: 124px;
  height: 124px;
}

.av-stack {
  display: flex;
  align-items: center;
}

.av-stack .av {
  margin-left: -9px;
  box-shadow: 0 0 0 2px var(--panel);
}

.av-stack .av:first-child {
  margin-left: 0;
}

/* ---------- team compare ------------------------------------------------- */

.compare-row {
  display: grid;
  grid-template-columns: 90px 1fr 150px 1fr 90px;
  align-items: center;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line-soft);
}

.compare-row:last-child {
  border-bottom: 0;
}

.compare-row .val {
  font-family: var(--mono);
  font-size: 17px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.compare-row .val.left {
  text-align: right;
  color: var(--sven);
}

.compare-row .val.right {
  text-align: left;
  color: var(--awisavi);
}

.compare-row .label {
  text-align: center;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.bar-track {
  height: 8px;
  border-radius: 999px;
  background: var(--panel-3);
  overflow: hidden;
  display: flex;
}

.bar-track.rtl {
  justify-content: flex-end;
}

.bar-fill {
  height: 100%;
  border-radius: 999px;
  transition: width 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.bar-fill.sven {
  background: linear-gradient(90deg, rgba(255, 92, 43, 0.45), var(--sven));
}

.bar-fill.awisavi {
  background: linear-gradient(90deg, var(--awisavi), rgba(0, 213, 255, 0.45));
}

/* ---------- map record grid --------------------------------------------- */

.map-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(168px, 1fr));
  gap: 12px;
}

.map-cell {
  padding: 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: var(--panel);
}

.map-cell .mname {
  font-size: 16px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.map-cell .mplayed {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text-faint);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 10px;
}

.map-cell .mrec {
  display: flex;
  align-items: baseline;
  gap: 6px;
  font-family: var(--mono);
  font-size: 22px;
  font-weight: 700;
}

.map-split {
  display: flex;
  height: 6px;
  border-radius: 999px;
  overflow: hidden;
  margin-top: 10px;
  background: var(--panel-3);
}

.map-split i {
  display: block;
  height: 100%;
}

.map-split i.s {
  background: var(--sven);
}

.map-split i.a {
  background: var(--awisavi);
}

/* ---------- tables ------------------------------------------------------- */

.table-scroll {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-variant-numeric: tabular-nums;
  min-width: 900px;
}

thead th {
  position: sticky;
  top: 0;
  background: var(--panel-2);
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--text-faint);
  text-align: right;
  padding: 12px 12px;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
  cursor: pointer;
  user-select: none;
  transition: color 0.15s;
}

thead th:first-child {
  text-align: left;
}

thead th:hover {
  color: var(--text);
}

thead th.sorted {
  color: var(--gold);
}

thead th.sorted::after {
  content: " ▾";
  font-size: 9px;
}

thead th.sorted.asc::after {
  content: " ▴";
}

tbody td {
  padding: 11px 12px;
  text-align: right;
  border-bottom: 1px solid var(--line-soft);
  font-size: 14px;
  white-space: nowrap;
}

tbody td:first-child {
  text-align: left;
  font-weight: 600;
}

tbody tr:last-child td {
  border-bottom: 0;
}

tbody tr:hover td {
  background: var(--panel-2);
}

td.hl {
  color: var(--gold);
  font-weight: 700;
}

.tname {
  display: inline-flex;
  align-items: center;
  gap: 9px;
}

.dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex: none;
}

.dot.sven {
  background: var(--sven);
}

.dot.awisavi {
  background: var(--awisavi);
}

/* ---------- controls ----------------------------------------------------- */

.controls {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 18px;
}

.chip {
  padding: 7px 13px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--text-dim);
  font-family: var(--font);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: all 0.15s;
}

.chip:hover {
  border-color: var(--text-faint);
  color: var(--text);
}

.chip.active {
  background: var(--text);
  border-color: var(--text);
  color: #07090f;
}

/* ---------- ranked bar chart -------------------------------------------- */

.rank-list {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.rank-row {
  display: grid;
  grid-template-columns: 132px 1fr 78px;
  align-items: center;
  gap: 12px;
}

.rank-row .rname {
  font-size: 14px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.rank-row .rname span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-row .rbar {
  height: 26px;
  border-radius: 5px;
  background: var(--panel-3);
  overflow: hidden;
}

.rank-row .rbar i {
  display: block;
  height: 100%;
  border-radius: 5px;
  transition: width 0.55s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.rank-row .rbar i.sven {
  background: linear-gradient(90deg, rgba(255, 92, 43, 0.5), var(--sven));
}

.rank-row .rbar i.awisavi {
  background: linear-gradient(90deg, rgba(0, 213, 255, 0.5), var(--awisavi));
}

.rank-row .rval {
  font-family: var(--mono);
  font-size: 15px;
  font-weight: 700;
  text-align: right;
}

.rank-row.leader .rval {
  color: var(--gold);
}

/* ---------- player cards ------------------------------------------------- */

.player-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 14px;
}

.pcard {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  padding: 18px;
}

.pcard header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 14px;
}

.pcard .pn {
  font-size: 20px;
  text-transform: uppercase;
  line-height: 1.1;
}

.pcard .pr {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text-faint);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.pcard-body {
  display: grid;
  grid-template-columns: 132px 1fr;
  gap: 14px;
  align-items: center;
}

.pcard-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px 12px;
}

.pcard-stats div {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-size: 13px;
  border-bottom: 1px solid var(--line-soft);
  padding-bottom: 5px;
}

.pcard-stats span {
  color: var(--text-faint);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.pcard-stats b {
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
}

.pcard-maps {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 14px;
}

.pm {
  display: flex;
  flex-direction: column;
  gap: 1px;
  padding: 9px 11px;
  border-radius: var(--radius-sm);
  background: var(--panel-2);
  border-left: 2px solid var(--line);
  min-width: 0;
}

.pm.best {
  border-left-color: var(--good);
}

.pm.worst {
  border-left-color: var(--bad);
}

.pm-k {
  font-family: var(--mono);
  font-size: 8.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.pm-v {
  font-size: 15px;
  font-weight: 700;
  text-transform: uppercase;
  line-height: 1.15;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pm-d {
  font-family: var(--mono);
  font-size: 10.5px;
  color: var(--text-dim);
  white-space: nowrap;
}

.spark-wrap {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--line-soft);
}

.spark-wrap .sl {
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin-bottom: 6px;
  display: flex;
  justify-content: space-between;
}

/* ---------- match cards -------------------------------------------------- */

.match-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(330px, 1fr));
  gap: 14px;
}

.mcard {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  overflow: hidden;
}

.mcard-head {
  width: 100%;
  display: block;
  text-align: left;
  padding: 16px 18px;
  background: transparent;
  border: 0;
  color: inherit;
  font: inherit;
  cursor: pointer;
  transition: background 0.15s;
}

.mcard-head:hover {
  background: var(--panel-2);
}

.mcard-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.mcard-map {
  font-size: 17px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.mcard-id {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text-faint);
  letter-spacing: 0.12em;
}

.mcard-score {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 10px;
}

.mcard-score .t {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.mcard-score .n {
  font-family: var(--mono);
  font-size: 30px;
  font-weight: 700;
  line-height: 1;
}

.mcard-score .n.w {
  color: var(--text);
}

.mcard-score .n.l {
  color: var(--text-faint);
}

.mcard-score .right {
  text-align: right;
}

.mcard-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 12px;
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text-faint);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  align-items: center;
}

.mcard-body {
  display: none;
  border-top: 1px solid var(--line);
  padding: 4px 0 8px;
}

.mcard.open .mcard-body {
  display: block;
}

.mcard.open .mcard-head {
  background: var(--panel-2);
}

.sb-team {
  padding: 12px 14px 4px;
}

.sb-team h5 {
  margin: 0 0 8px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

table.sb {
  min-width: 0;
  font-size: 13px;
}

table.sb th {
  position: static;
  cursor: default;
  padding: 5px 6px;
  font-size: 9px;
  background: transparent;
  border-bottom: 1px solid var(--line-soft);
}

table.sb td {
  padding: 6px;
  font-size: 13px;
  border-bottom: 1px solid var(--line-soft);
}

table.sb tr:last-child td {
  border-bottom: 0;
}

.expand-hint {
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: 0.14em;
  color: var(--text-faint);
  text-transform: uppercase;
}

/* ---------- charts ------------------------------------------------------- */

.chart-box {
  width: 100%;
  overflow-x: auto;
}

.chart-box svg {
  display: block;
  max-width: 100%;
  height: auto;
}

.legend {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 12px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.legend i {
  display: inline-block;
  width: 14px;
  height: 3px;
  border-radius: 2px;
  margin-right: 6px;
  vertical-align: middle;
}

/* ---------- records list ------------------------------------------------- */

.rec-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

/* full-width records panel splits into two columns when there is room */
@media (min-width: 860px) {
  .rec-list.two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: 34px;
  }

  .rec-list.two-col .rec:nth-last-child(2):nth-child(odd) {
    border-bottom: 0;
  }
}

.rec {
  display: grid;
  grid-template-columns: 92px 1fr;
  gap: 14px;
  align-items: baseline;
  padding: 11px 0;
  border-bottom: 1px solid var(--line-soft);
}

.rec:last-child {
  border-bottom: 0;
}

.rec-v {
  font-family: var(--mono);
  font-size: 20px;
  font-weight: 700;
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.rec-t {
  font-size: 15px;
  font-weight: 600;
  line-height: 1.25;
  display: flex;
  align-items: center;
  gap: 8px;
}

.rec-d {
  font-size: 13px;
  color: var(--text-dim);
  margin-top: 3px;
  line-height: 1.4;
}

/* ---------- best / worst ------------------------------------------------- */

.bw {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.bw-row {
  display: grid;
  grid-template-columns: 62px 1fr;
  gap: 13px;
  align-items: start;
}

.bw-row b {
  font-size: 17px;
  text-transform: uppercase;
}

.bw-score {
  font-family: var(--mono);
  font-size: 15px;
  font-weight: 700;
  color: var(--text-dim);
  margin-left: 9px;
}

.bw-d {
  font-size: 12.5px;
  color: var(--text-faint);
  font-family: var(--mono);
  letter-spacing: 0.03em;
  margin-top: 3px;
}

/* ---------- charts ------------------------------------------------------- */

.echart {
  width: 100%;
}

/* ---------- notes / footer ---------------------------------------------- */

.note {
  padding: 16px 18px;
  border-left: 2px solid var(--line);
  background: var(--bg-alt);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  color: var(--text-dim);
  font-size: 13.5px;
}

.note b {
  color: var(--text);
}

footer.foot {
  margin-top: 72px;
  padding: 30px 0 50px;
  border-top: 1px solid var(--line);
  color: var(--text-faint);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

/* ---------- responsive --------------------------------------------------- */

@media (max-width: 900px) {
  .grid.cols-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .grid.cols-3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .mvp {
    grid-template-columns: 1fr;
  }
  .mvp-left {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .podium {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .wrap {
    padding: 0 16px;
  }
  section.section {
    padding: 52px 0 16px;
  }
  .grid.cols-2,
  .grid.cols-3,
  .grid.cols-4 {
    grid-template-columns: 1fr;
  }
  .compare-row {
    grid-template-columns: 60px 1fr 92px 1fr 60px;
    gap: 7px;
  }
  .compare-row .val {
    font-size: 14px;
  }
  .rank-row {
    grid-template-columns: 100px 1fr 62px;
  }
  .pcard-body {
    grid-template-columns: 1fr;
  }
  /* the three-column scoreline cannot fit a phone — stack it instead */
  .scoreline {
    grid-template-columns: 1fr;
    padding: 24px 16px;
    gap: 18px;
    text-align: center;
  }

  .scoreline .side.left,
  .scoreline .side.right {
    align-items: center;
    text-align: center;
  }

  .scoreline .center {
    order: -1;
    padding: 0;
  }

  .scoreline .team-name {
    font-size: 36px;
  }

  .scoreline .maps {
    font-size: 52px;
  }
}
