:root {
  --ground: #0b0b0d;
  --surface: #15151a;
  --surface-2: #1d1d24;
  --line: rgba(240, 232, 216, 0.1);
  --line-strong: rgba(240, 232, 216, 0.2);
  --text: #f1ece2;
  --muted: #9a9486;
  --accent: #dcb878;
  --keep: #3ddc97;
  --watch: #f5a524;
  --bench: #f25c54;
  --link: #dcb878;
  --radius: 14px;
  --font: -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 64px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--ground);
  color: var(--text);
  font: 15px/1.5 var(--font);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4, p, dl, dd, ul { margin: 0; }
ul { padding: 0; list-style: none; }
button { font: inherit; color: inherit; }
[hidden] { display: none !important; }
.muted { color: var(--muted); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 8px; }

/* top bar */

.topbar {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px max(16px, calc((100vw - 1040px) / 2));
  background: rgba(11, 11, 13, 0.82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.wordmark { font-weight: 700; letter-spacing: -0.01em; white-space: nowrap; }
.topnav { display: flex; gap: 16px; font-size: 13px; white-space: nowrap; overflow-x: auto; scrollbar-width: none; }
.topnav a { color: var(--muted); }
.topnav a:hover { color: var(--text); text-decoration: none; }

.wrap { max-width: 1072px; margin: 0 auto; padding: 0 16px; }

/* lede */

.lede { padding: 40px 0 28px; }
.eyebrow { font-size: 13px; color: var(--accent); font-weight: 600; }
.lede h1 {
  margin-top: 10px;
  max-width: 24em;
  font-size: clamp(26px, 4.2vw, 40px);
  line-height: 1.14;
  letter-spacing: -0.022em;
  font-weight: 700;
  text-wrap: balance;
}
.meta { margin-top: 18px; font-size: 13px; }

/* sections */

.section-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 12px; margin-bottom: 14px; }
.section-head h2 { font-size: 18px; font-weight: 700; letter-spacing: -0.01em; }
.head-controls { display: flex; flex-wrap: wrap; gap: 8px; }
.board { padding: 32px 0; border-top: 1px solid var(--line); }
.board-sub { margin: -4px 0 16px; font-size: 13px; }

.btn {
  padding: 6px 14px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: transparent;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
}
.btn:hover { background: var(--surface-2); }
.btn-primary { background: var(--text); color: var(--ground); border-color: var(--text); }
.btn-primary:hover { background: var(--accent); border-color: var(--accent); }

.segmented { display: inline-flex; padding: 3px; border-radius: 999px; background: var(--surface-2); }
.segmented button {
  padding: 5px 13px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s, color 0.15s;
}
.segmented button[aria-pressed="true"] { background: var(--text); color: var(--ground); }

/* pool */

.pool-band {
  padding: 18px;
  margin-bottom: 16px;
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--line);
}
.pool-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); gap: 16px 8px; }
.pool-hero { display: flex; flex-direction: column; align-items: center; gap: 2px; color: var(--text); text-align: center; }
.pool-hero:hover { text-decoration: none; }
.pool-name { margin-top: 5px; font-size: 13px; line-height: 1.25; }

/* portraits and rings */

.portrait {
  --ring: var(--line-strong);
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--surface-2);
  box-shadow: 0 0 0 2.5px var(--ring);
  overflow: hidden;
  transition: transform 0.15s ease;
}
.portrait img { width: 100%; height: 100%; object-fit: cover; object-position: top; display: block; }
.v-keep { --ring: var(--keep); }
.v-watch { --ring: var(--watch); }
.v-bench { --ring: var(--bench); }
.v-neutral { --ring: var(--line-strong); }
.initials { font-size: 15px; font-weight: 700; color: var(--muted); }

.badge { font-size: 11px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: var(--muted); }
.badge.v-keep { color: var(--keep); }
.badge.v-watch { color: var(--watch); }
.badge.v-bench { color: var(--bench); }
.badge.dir-buff { color: var(--keep); }
.badge.dir-nerf { color: var(--bench); }
.badge.m-major { color: var(--bench); }
.badge.m-moderate { color: var(--watch); }

.legend { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; margin-bottom: 22px; font-size: 12px; }
.dot { width: 9px; height: 9px; border-radius: 50%; background: var(--ring); margin-left: 8px; }
.dot:first-child { margin-left: 0; }
.legend-sep { margin-left: 14px; }

/* biggest changes */

.big-grid { display: flex; flex-wrap: wrap; gap: 10px; }
.big-card {
  flex: 1 1 280px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 14px 16px;
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--line), inset 3px 0 0 var(--edge, var(--line-strong));
  color: var(--text);
}
a.big-card:hover { background: var(--surface-2); text-decoration: none; }
.big-card.fx-up { --edge: var(--keep); }
.big-card.fx-down { --edge: var(--bench); }
.big-card.fx-neutral { --edge: var(--watch); }
.big-top { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.big-kind { font-size: 11px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }
.big-rank { font-size: 13px; font-weight: 700; color: var(--muted); font-variant-numeric: tabular-nums; }
.big-main { display: flex; align-items: flex-start; gap: 12px; }
.big-art { flex: none; }
.big-art .portrait, .big-art .item-icon { width: 40px; height: 40px; }
.big-art .item-icon { border-radius: 9px; }
.big-text { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.big-title { font-size: 15.5px; font-weight: 700; line-height: 1.28; letter-spacing: -0.01em; }
.big-why { font-size: 13px; line-height: 1.45; }

/* game plan */

.plan-text { max-width: 44em; margin-bottom: 16px; font-size: 15px; }

/* tier board */

.tier-row { display: flex; align-items: flex-start; gap: 14px; padding: 12px 0; }
.tier-row + .tier-row { border-top: 1px solid var(--line); }
.tier-letter {
  flex: none;
  min-width: 42px;
  padding: 9px 6px;
  border-radius: 10px;
  background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--line);
  font-size: 22px;
  font-weight: 800;
  line-height: 1;
  text-align: center;
}
.tier-letter.t-s { color: var(--accent); }
.tier-letter.t-a { color: var(--keep); }
.tier-letter.t-b { color: #6fc3d8; }
.tier-letter.t-c { color: var(--muted); }
.tier-letter.t-d { color: var(--bench); }
.tier-letter.t-unrated { padding-top: 14px; font-size: 10px; font-weight: 700; letter-spacing: 0.07em; text-transform: uppercase; color: var(--muted); }
.tier-tiles { display: flex; flex-wrap: wrap; gap: 10px 4px; min-width: 0; }
.tier-tile { width: 62px; gap: 3px; }
.tier-tile .portrait { width: 44px; height: 44px; }
.tier-tile .tile-name { font-size: 11.5px; }
.tier-moved { font-size: 10px; font-weight: 700; letter-spacing: 0.02em; }
.tier-moved.up { color: var(--keep); }
.tier-moved.down { color: var(--bench); }
.tier-note { margin-top: 14px; font-size: 12px; }
.tier-wr { font-size: 10.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.rank-switch { margin-bottom: 14px; }
.tier-stats { margin: 0 0 16px; display: grid; gap: 4px; font-size: 13px; }
.tier-stats div { display: flex; flex-wrap: wrap; gap: 4px 10px; }
.tier-stats dt { color: var(--muted); min-width: 72px; }
.tier-stats dd { margin: 0; }

/* small changes */

.small-changes { margin-top: 16px; border-radius: var(--radius); box-shadow: inset 0 0 0 1px var(--line); }
.small-changes summary { display: flex; align-items: center; gap: 8px; padding: 12px 16px; font-size: 14px; font-weight: 600; cursor: pointer; list-style: none; }
.small-changes summary::-webkit-details-marker { display: none; }
.small-changes summary::after { content: "+"; color: var(--muted); font-weight: 400; font-size: 18px; line-height: 1; }
.small-changes[open] summary::after { content: "–"; }
.small-changes .tile-grid, .small-changes .system-grid { padding: 4px 16px 16px; }

/* boards */

.hero-group + .hero-group { margin-top: 26px; }
.group-head {
  display: flex;
  align-items: center;
  gap: 7px;
  padding-bottom: 8px;
  margin-bottom: 16px;
  font-size: 14px;
  font-weight: 700;
  border-bottom: 1px solid var(--line);
}
.count { margin-left: auto; font-size: 12px; font-weight: 600; color: var(--muted); font-variant-numeric: tabular-nums; }
.g-buff .group-head { color: var(--keep); border-color: color-mix(in srgb, var(--keep) 45%, transparent); }
.g-nerf .group-head { color: var(--bench); border-color: color-mix(in srgb, var(--bench) 45%, transparent); }
.g-rework .group-head { color: var(--accent); border-color: color-mix(in srgb, var(--accent) 45%, transparent); }
.g-adjusted .group-head { color: var(--text); border-color: var(--line-strong); }
.g-indirect .group-head, .g-unchanged .group-head { color: var(--muted); }

.tile-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 18px 6px; }
.tile-grid.items { grid-template-columns: repeat(auto-fill, minmax(72px, 1fr)); gap: 14px 4px; }
.tile { display: flex; flex-direction: column; align-items: center; gap: 8px; color: var(--text); text-align: center; }
.tile:hover { text-decoration: none; }
.tile:hover .portrait, .tile:hover .item-icon { transform: translateY(-2px); }
.tile-art { position: relative; display: inline-flex; }
.tile-name { font-size: 12.5px; line-height: 1.25; }
.g-indirect .portrait, .g-unchanged .portrait { width: 52px; height: 52px; }
.g-indirect .tile-name, .g-unchanged .tile-name { color: var(--muted); }

.chev {
  position: absolute;
  right: -5px;
  bottom: -3px;
  display: inline-flex;
  flex-direction: column;
  gap: 1.5px;
  padding: 3px;
  border-radius: 6px;
  background: var(--ground);
}
.chev i { display: block; width: 0; height: 0; border-left: 5px solid transparent; border-right: 5px solid transparent; }
.chev.d-up i, .chev.d-buff i { border-bottom: 6px solid var(--keep); }
.chev.d-down i, .chev.d-nerf i { border-top: 6px solid var(--bench); }
.chev.d-neutral i, .chev.d-rework i { width: 9px; height: 2.5px; border: 0; border-radius: 2px; background: var(--muted); }

.item-columns { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; }
.cat {
  padding-bottom: 8px;
  margin-bottom: 14px;
  font-size: 14px;
  font-weight: 700;
  text-transform: capitalize;
  border-bottom: 1px solid var(--line);
}
.cat-weapon .cat { color: #e9a05d; border-color: rgba(233, 160, 93, 0.4); }
.cat-spirit .cat { color: #b79cf0; border-color: rgba(183, 156, 240, 0.4); }
.cat-vitality .cat { color: #93d46a; border-color: rgba(147, 212, 106, 0.4); }
.item-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  width: 54px;
  height: 54px;
  border-radius: 12px;
  background: var(--surface-2);
  overflow: hidden;
  transition: transform 0.15s ease;
}
.item-icon img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tile-art .dir-badge.d-rework { color: var(--accent); }
.dir-badge {
  position: absolute;
  right: -5px;
  bottom: -4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 6px;
  background: var(--ground);
  color: var(--text);
  font-size: 12px;
  line-height: 1;
}

/* systems */

.pace {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
  gap: 16px 40px;
  padding: 18px;
  margin-bottom: 14px;
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--line);
}
.pace-label { margin-bottom: 12px; font-size: 14px; font-weight: 600; }
.gauge { position: relative; height: 6px; border-radius: 3px; background: linear-gradient(90deg, #e9a05d, var(--surface-2) 50%, #b79cf0); }
.gauge-mark {
  position: absolute;
  top: 50%;
  width: 16px;
  height: 16px;
  margin: -8px 0 0 -8px;
  border-radius: 50%;
  background: var(--text);
  box-shadow: 0 0 0 3px var(--surface);
}
.gauge-ends { display: flex; justify-content: space-between; margin-top: 10px; font-size: 12px; }
.arche-none { font-size: 13px; }
.arche-list { display: flex; flex-wrap: wrap; gap: 6px; }
.arche-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 4px 11px 4px 8px;
  border-radius: 999px;
  background: var(--surface-2);
  font-size: 13px;
  text-transform: capitalize;
}
.arche-chip .chev { position: static; padding: 0; background: none; }

.system-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.system-tile {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px;
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--line);
  color: var(--text);
  transition: background 0.15s;
}
.system-tile:hover { background: var(--surface-2); text-decoration: none; }
.system-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.system-name { font-size: 14px; font-weight: 600; line-height: 1.3; }
.system-head .badge { flex: none; line-height: 1.7; }
.system-summary { font-size: 13px; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.deltas { display: flex; flex-wrap: wrap; gap: 10px 24px; }
.delta { display: flex; flex-direction: column; gap: 1px; min-width: 0; max-width: 100%; }
.delta-value { font-size: 19px; line-height: 1.2; font-weight: 700; font-variant-numeric: tabular-nums; letter-spacing: -0.01em; white-space: nowrap; }
.delta-label { font-size: 12px; line-height: 1.3; }

/* sheet */

.sheet, .picker {
  color: var(--text);
  background: var(--surface);
  border: 0;
  box-shadow: 0 0 0 1px var(--line-strong), 0 24px 70px rgba(0, 0, 0, 0.6);
}
.sheet::backdrop, .picker::backdrop { background: rgba(5, 5, 7, 0.7); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
.sheet {
  width: min(660px, calc(100vw - 32px));
  max-height: min(84dvh, 860px);
  padding: 0;
  border-radius: 18px;
  overflow: hidden;
}
.sheet[open] { display: flex; flex-direction: column; animation: sheet-in 0.2s cubic-bezier(0.2, 0.8, 0.2, 1); }
@keyframes sheet-in { from { opacity: 0; transform: translateY(10px) scale(0.985); } to { opacity: 1; transform: none; } }
.sheet-bar { display: flex; align-items: center; gap: 4px; flex: none; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.sheet-pos { margin-left: 8px; font-size: 12px; font-variant-numeric: tabular-nums; }
.sheet-close { margin-left: auto; }
.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}
.icon-btn:hover:not(:disabled) { background: var(--surface-2); }
.icon-btn:disabled { color: var(--line-strong); cursor: default; }
.sheet:focus, .sheet-body:focus { outline: none; }
.icon-btn:focus-visible { outline: 1.5px solid var(--line-strong); outline-offset: 1px; }
.sheet-body { padding: 18px 20px 24px; overflow-y: auto; overscroll-behavior: contain; }

.sheet-head { display: flex; align-items: flex-start; gap: 16px; margin-bottom: 16px; padding: 2px 2px 16px; border-bottom: 1px solid var(--line); }
.hero-line { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; }
.hero-line h3 { font-size: 20px; line-height: 1.25; font-weight: 700; letter-spacing: -0.01em; }
.kind-line { margin-top: 2px; font-size: 12px; font-weight: 700; color: var(--muted); }
.k-buff { color: var(--keep); }
.k-nerf { color: var(--bench); }
.k-rework { color: var(--accent); }
.one-liner { margin-top: 4px; font-size: 14px; line-height: 1.4; }
.tier-chip {
  padding: 1px 8px;
  border-radius: 7px;
  background: var(--surface-2);
  font-size: 12px;
  font-weight: 700;
  color: var(--accent);
}

.row-group { margin-bottom: 14px; }
.ability-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 0;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
}
.ability-icon { width: 22px; height: 22px; object-fit: contain; }
.row {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
  gap: 12px;
  padding: 8px 0;
  border-top: 1px solid var(--line);
  font-size: 14px;
  line-height: 1.35;
}
.row-label { color: var(--muted); }
.row-value { min-width: 0; overflow-wrap: anywhere; font-variant-numeric: tabular-nums; }
.row-value s.old { color: var(--muted); }
.row-value .arrow { color: var(--muted); margin: 0 3px; }
.row-value b { font-weight: 700; }
.e-good { color: var(--keep); }
.e-bad { color: var(--bench); }
.e-neutral { color: var(--text); }

.sub { margin: 18px 0 8px; font-size: 12px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: var(--muted); }
.reasons { display: grid; gap: 8px; font-size: 14px; line-height: 1.45; }
.reasons li { position: relative; padding-left: 14px; }
.reasons li::before { content: ""; position: absolute; left: 0; top: 0.6em; width: 5px; height: 5px; border-radius: 50%; background: var(--line-strong); }
.prose { font-size: 14px; line-height: 1.5; }
.sheet-card .prose, .sheet-card .reasons { color: var(--muted); }

.affected { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 12px 6px; }
.affected-hero { display: flex; flex-direction: column; align-items: center; gap: 6px; color: var(--text); text-align: center; font-size: 12px; line-height: 1.25; }
.affected-hero:hover { text-decoration: none; }
.affected-hero .portrait { width: 44px; height: 44px; }
.affected-hero.in-pool .portrait { --ring: var(--accent); }
.affected-name i { font-style: normal; font-size: 9px; }

/* picker */

.picker { width: min(620px, calc(100vw - 32px)); max-height: 84dvh; padding: 18px; border-radius: 18px; }
.picker-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); gap: 12px 4px; }
.picker-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 6px 2px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  font-size: 12px;
  line-height: 1.25;
  color: var(--muted);
  cursor: pointer;
}
.picker-hero .portrait { width: 52px; height: 52px; opacity: 0.55; filter: saturate(0.5); transition: opacity 0.15s, filter 0.15s; }
.picker-hero.selected { color: var(--text); }
.picker-hero.selected .portrait { --ring: var(--accent); opacity: 1; filter: none; }

/* season page */

.season-banner {
  display: block;
  margin-top: 14px;
  padding: 10px 14px;
  border-radius: 10px;
  background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--line);
  color: var(--text);
  font-size: 13.5px;
}
a.season-banner:hover { background: var(--surface-2); text-decoration: none; }

.season-chip {
  display: inline-block; margin-right: 6px; padding: 2px 9px; border-radius: 999px;
  background: rgba(220, 184, 120, 0.14); color: var(--accent); font-size: 12px; font-weight: 700;
}
.season-headline { margin-top: 10px; max-width: 640px; font-size: 17px; color: var(--text); opacity: 0.88; }

.timeline { margin-top: 26px; max-width: 640px; }
.tl-track { position: relative; height: 10px; border-radius: 999px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line); }
.tl-fill { height: 100%; border-radius: inherit; background: linear-gradient(90deg, rgba(220, 184, 120, 0.35), var(--accent)); min-width: 10px; }
.tl-now {
  position: absolute; top: 50%; width: 18px; height: 18px; margin: -9px 0 0 -9px; border-radius: 50%;
  background: var(--text); box-shadow: 0 0 0 4px rgba(220, 184, 120, 0.35);
}
.tl-labels { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-top: 10px; font-size: 13px; }
.tl-labels small { display: block; color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: 0.05em; }
.tl-left { align-self: center; padding: 3px 10px; border-radius: 999px; background: var(--surface-2); font-weight: 700; color: var(--accent); }
.tl-end { text-align: right; }

.tally { margin-top: 22px; max-width: 640px; }
.tally-bar { display: flex; gap: 3px; height: 8px; }
.tally-bar span { border-radius: 999px; }
.tally-bar .t-easier, .t-key.t-easier i { background: var(--keep); }
.tally-bar .t-harsher, .t-key.t-harsher i { background: var(--bench); }
.tally-bar .t-neutral, .t-key.t-neutral i { background: var(--muted); }
.tally-legend { display: flex; flex-wrap: wrap; gap: 4px 14px; margin-top: 8px; font-size: 13px; }
.t-key { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; }
.t-key i { width: 8px; height: 8px; border-radius: 50%; }

.reset-pill { padding: 4px 11px; border-radius: 999px; background: rgba(242, 92, 84, 0.12); color: var(--bench); font-size: 13px; font-weight: 700; }

.ladder { display: grid; gap: 4px; padding: 26px 0 0; }
.rung {
  position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px;
  padding: 12px 2px 10px; border-radius: 10px; background: var(--surface);
  box-shadow: inset 0 -3px 0 var(--rank);
}
.rung img { width: 40px; height: 40px; object-fit: contain; }
.rung-dot { width: 26px; height: 26px; border-radius: 50%; background: var(--rank); }
.rung-name { font-size: 11px; color: var(--muted); max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rung.no-shield { background: rgba(242, 92, 84, 0.1); box-shadow: inset 0 -3px 0 var(--rank), inset 0 0 0 1px rgba(242, 92, 84, 0.45); }
.rung.in-stretch { background: rgba(61, 220, 151, 0.1); }
.rung.no-shield.in-stretch { background: linear-gradient(180deg, rgba(61, 220, 151, 0.14), rgba(242, 92, 84, 0.12)); }
.pin {
  position: absolute; top: -11px; left: 50%; transform: translateX(-50%); padding: 1px 7px; border-radius: 999px;
  font-size: 10px; font-weight: 800; letter-spacing: 0.03em; text-transform: uppercase; white-space: nowrap;
}
.pin-new { background: var(--keep); color: #06281a; }
.pin-old { background: var(--surface-2); color: var(--muted); box-shadow: inset 0 0 0 1px var(--line-strong); text-decoration: line-through; }
.ladder-key { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 14px; font-size: 13px; color: var(--muted); }
.ladder-key li { display: inline-flex; align-items: center; gap: 7px; }
.ladder-key i { width: 12px; height: 12px; border-radius: 4px; }
.k-shield { background: rgba(242, 92, 84, 0.25); box-shadow: inset 0 0 0 1px var(--bench); }
.k-stretch { background: rgba(61, 220, 151, 0.3); }
.k-old { background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--line-strong); }

.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; margin: 26px 0 0; padding: 0; list-style: none; counter-reset: none; }
.step { display: flex; gap: 12px; padding: 14px; border-radius: var(--radius); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.step h3 { font-size: 14.5px; font-weight: 700; }
.step p { margin-top: 3px; font-size: 13px; }
.step-num {
  flex: none; display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%;
  background: var(--accent); color: var(--ground); font-weight: 800; font-size: 13px;
}

.rule-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 10px; }
.rule {
  --fx: var(--muted);
  display: flex; flex-direction: column; gap: 10px; padding: 16px; border-radius: var(--radius);
  background: var(--surface); box-shadow: inset 3px 0 0 var(--fx), inset 0 0 0 1px var(--line);
}
.rule.e-easier { --fx: var(--keep); }
.rule.e-harsher { --fx: var(--bench); }
.rule-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.rule-cat { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: var(--muted); }
.rule-cat svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.effect { padding: 2px 9px; border-radius: 999px; font-size: 12px; font-weight: 700; color: var(--fx); background: color-mix(in srgb, var(--fx) 14%, transparent); white-space: nowrap; }
.rule h3 { font-size: 16px; font-weight: 700; letter-spacing: -0.01em; }
.pips { display: flex; flex-wrap: wrap; gap: 6px; }
.pip { width: 18px; height: 18px; border-radius: 50%; background: var(--text); opacity: 0.85; }
.pip.p-lost { background: transparent; opacity: 1; box-shadow: inset 0 0 0 2px var(--bench); position: relative; }
.pip.p-lost::after { content: ""; position: absolute; inset: 8px 3px; background: var(--bench); transform: rotate(-45deg); border-radius: 2px; }
.pip.p-gained { background: var(--keep); opacity: 1; box-shadow: 0 0 0 3px rgba(61, 220, 151, 0.25); }
.bars { display: grid; gap: 6px; }
.bar-row { display: grid; grid-template-columns: 48px 1fr; align-items: center; gap: 8px; font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: 0.04em; }
.bar { height: 10px; border-radius: 999px; background: var(--surface-2); overflow: hidden; }
.bar span { display: block; height: 100%; border-radius: inherit; }
.bar-old { background: var(--line-strong); }
.bar-new { background: var(--fx); }
.rule-values { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; font-size: 15px; }
.rule-values s { color: var(--muted); }
.rule-values b { font-size: 18px; }
.rule-values .arrow { color: var(--muted); }
.new-tag { padding: 1px 7px; border-radius: 6px; background: var(--surface-2); font-size: 11px; font-weight: 700; text-transform: uppercase; color: var(--accent); }
.rule-note { font-size: 13px; margin-top: -2px; }

.who-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 10px; }
.who { padding: 16px; border-radius: var(--radius); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.who-win { box-shadow: inset 0 3px 0 var(--keep), inset 0 0 0 1px var(--line); }
.who-lose { box-shadow: inset 0 3px 0 var(--bench), inset 0 0 0 1px var(--line); }
.who-head { font-size: 12px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; margin-bottom: 10px; }
.who-win .who-head { color: var(--keep); }
.who-lose .who-head { color: var(--bench); }
.who li { display: grid; gap: 2px; padding: 10px 0; border-top: 1px solid var(--line); font-size: 14px; }
.who li:first-child { border-top: 0; padding-top: 0; }
.who li .muted { font-size: 13px; }

@media (max-width: 640px) {
  .ladder { gap: 3px; }
  .rung { padding: 10px 0 8px; }
  .rung img { width: 26px; height: 26px; }
  .rung-name { display: none; }
  .pin { font-size: 8.5px; padding: 1px 4px; }
  .rule-grid { grid-template-columns: 1fr; }
}

/* archive */

.archive-page .lede { padding-bottom: 12px; }
.archive { padding-bottom: 24px; }
.archive li { border-top: 1px solid var(--line); }
.archive a { display: flex; flex-direction: column; gap: 2px; padding: 16px 0; color: var(--text); }
.archive a:hover { text-decoration: none; }
.archive a:hover .archive-title { color: var(--accent); }
.archive-date { font-size: 13px; }
.archive-title { font-size: 16px; font-weight: 600; }
.archive-head { font-size: 14px; }

.footer { max-width: 1072px; margin: 16px auto 0; padding: 24px 16px 40px; border-top: 1px solid var(--line); font-size: 12px; line-height: 1.5; }
.footer p + p { margin-top: 6px; }

/* phones */

@media (max-width: 760px) {
  .lede { padding: 28px 0 22px; }
  .item-columns { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .pace, .system-grid { grid-template-columns: minmax(0, 1fr); }
  .tile-grid { grid-template-columns: repeat(auto-fill, minmax(72px, 1fr)); }
  .board { padding: 26px 0; }
  .wordmark { font-size: 14px; }
  .topnav { gap: 12px; }
  .sheet {
    width: 100vw;
    max-width: 100vw;
    max-height: 90dvh;
    margin: auto 0 0;
    border-radius: 18px 18px 0 0;
  }
  .sheet[open] { animation-name: sheet-up; animation-duration: 0.26s; }
  @keyframes sheet-up { from { transform: translateY(40px); opacity: 0; } to { transform: none; opacity: 1; } }
  .picker { width: 100vw; max-width: 100vw; margin: auto 0 0; border-radius: 18px 18px 0 0; }
  .legend-sep { width: 100%; margin-left: 0; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}
