/* Layout: arena at night. Rafters banner wall up top, then a broadcast-style stack of sections in one centered column. Dark-first. */
:root {
  --bg: #140b0d;
  --surface: #1e1114;
  --surface-2: #2a181c;
  --fg: #f6ecea;
  --muted: #b39b97;
  --line: #3b2428;
  --red: #e2452f;
  --red-deep: #8f1d18;
  --gold: #dcb44e;
  --on-red: #fff6f2;
  --stripe: color-mix(in srgb, var(--red) 9%, transparent);
  --display: "Graduate", "Rockwell", "Georgia", serif;
  --body: "Barlow", "Segoe UI", system-ui, sans-serif;
  --cond: "Barlow Condensed", "Arial Narrow", "Segoe UI", sans-serif;
  color-scheme: dark;
}
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --bg: #fbf6f5; --surface: #ffffff; --surface-2: #f4e8e6; --fg: #231215; --muted: #6f5853;
    --line: #e7d4d1; --red: #c9321f; --red-deep: #8f1d18; --gold: #9c7816; --on-red: #fff6f2;
    color-scheme: light;
  }
}
:root[data-theme="light"] {
  --bg: #fbf6f5; --surface: #ffffff; --surface-2: #f4e8e6; --fg: #231215; --muted: #6f5853;
  --line: #e7d4d1; --red: #c9321f; --red-deep: #8f1d18; --gold: #9c7816; --on-red: #fff6f2;
  color-scheme: light;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--bg); color: var(--fg); font-family: var(--body); font-size: 16px; line-height: 1.5; }
/* Anchor jumps land below the sticky top bar. */
html { scroll-padding-top: calc(env(safe-area-inset-top, 0px) + 72px); }
@media (max-width: 720px) { html { scroll-padding-top: calc(env(safe-area-inset-top, 0px) + 100px); } }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.wrap { max-width: 1120px; margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
h1, h2, h3 { text-wrap: balance; margin: 0; }
.eyebrow { font-family: var(--cond); font-weight: 600; letter-spacing: .14em; text-transform: uppercase; font-size: 13px; color: var(--gold); }
.num { font-variant-numeric: tabular-nums; }
.mlink { text-decoration: none; border-bottom: 1px solid color-mix(in srgb, currentColor 30%, transparent); }
.mlink:hover { border-color: var(--red); }

/* Top bar */
/* The bar's own top padding fills the phone's status-bar area, so nothing sits behind it. */
.top { position: sticky; top: 0; z-index: 5; background: var(--surface); border-bottom: 1px solid var(--line); padding-top: env(safe-area-inset-top, 0px); }
.top .wrap { display: flex; align-items: center; gap: 8px 20px; padding-block: 10px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; text-decoration: none; }
.brand img { height: 30px; width: auto; display: block; }
/* Logo art comes in two inks: white lettering on the dark theme, dark lettering on the light one. */
.on-light { display: none !important; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .on-dark { display: none !important; } :root:not([data-theme="dark"]) .on-light { display: block !important; } }
:root[data-theme="light"] .on-dark { display: none !important; }
:root[data-theme="light"] .on-light { display: block !important; }
.nav { display: flex; gap: 4px 18px; flex-wrap: wrap; font-family: var(--cond); font-weight: 600; text-transform: uppercase; letter-spacing: .08em; font-size: 14px; }
.nav a { text-decoration: none; color: var(--muted); padding: 4px 0; border-bottom: 2px solid transparent; }
.nav a:hover { color: var(--fg); border-color: var(--red); }
.nav a[aria-current="page"] { color: var(--fg); border-color: var(--gold); }
/* Phones: the tabs are one swipeable row instead of three wrapped rows, keeping the sticky bar short. */
@media (max-width: 720px) {
  .top .wrap { padding-block: 8px 0; row-gap: 2px; }
  .nav { position: relative; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; width: calc(100% + 32px); margin-inline: -16px; padding: 0 16px 6px;
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 16px, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(90deg, transparent, #000 16px, #000 calc(100% - 28px), transparent); }
  .nav::-webkit-scrollbar { display: none; }
  .nav a { white-space: nowrap; flex: none; }
}

/* Page header for inner pages */
.pagehead { padding-block: 40px 8px; }
.pagehead h1 { font-family: var(--display); font-weight: 400; font-size: clamp(32px, 5vw, 56px); line-height: 1.04; margin-top: 8px; }
.pagehead p { color: var(--muted); font-size: 18px; max-width: 60ch; margin: 12px 0 0; }

/* Hero */
.hero { padding-block: clamp(40px, 8vh, 96px) 28px; display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 40px; align-items: center; }
.hero h1 { font-family: var(--display); font-weight: 400; font-size: clamp(34px, 5.6vw, 64px); line-height: 1.02; margin-top: 12px; }
.hero h1 em { font-style: normal; color: var(--red); }
.hero p.lede { color: var(--muted); font-size: 18px; max-width: 52ch; margin: 18px 0 0; }
.tally { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; margin-top: 30px; border-top: 1px solid var(--line); }
.tally div { padding: 14px 12px 0 0; }
.tally strong { display: block; font-family: var(--cond); font-weight: 700; font-size: clamp(24px, 3.2vw, 36px); line-height: 1; }
.tally span { font-family: var(--cond); text-transform: uppercase; letter-spacing: .1em; font-size: 12px; color: var(--muted); }

/* Champion card: a taped-up picture-day portrait over a trophy-case plaque. */
.champ { position: relative; background: radial-gradient(120% 70% at 50% 0%, #b8322a, var(--red-deep) 45%, #3a0c0d 100%); color: var(--on-red); border-radius: 8px; padding: 26px 22px 20px; border: 3px solid var(--gold); box-shadow: 0 24px 48px -20px rgba(0,0,0,.65); }
.portrait { margin: 0 auto; max-width: 300px; position: relative; background: #f7f1e3; padding: 10px 10px 34px; transform: rotate(-2.5deg); box-shadow: 0 14px 22px -8px rgba(0,0,0,.6); transition: transform .35s ease; }
.champ:hover .portrait { transform: rotate(0deg) scale(1.02); }
.portrait img { display: block; width: 100%; height: auto; filter: saturate(1.05) contrast(1.04); }
.portrait figcaption { position: absolute; left: 0; right: 0; bottom: 7px; text-align: center; color: #3a2a20; font-family: "Segoe Print", "Bradley Hand", "Comic Sans MS", cursive; font-size: 15px; }
.portrait .tape { position: absolute; top: -10px; width: 74px; height: 22px; background: rgba(240, 225, 170, .72); box-shadow: 0 1px 2px rgba(0,0,0,.2); }
.portrait .tape.l { left: -16px; transform: rotate(-32deg); }
.portrait .tape.r { right: -16px; transform: rotate(28deg); }
.plaque { margin-top: 22px; text-align: center; border-top: 2px solid var(--gold); padding-top: 14px; }
.champ .label { font-family: var(--cond); letter-spacing: .16em; text-transform: uppercase; font-size: 13px; color: #f3d77e; }
.champ .who { font-family: var(--display); font-size: 44px; line-height: 1.05; text-shadow: 0 3px 0 rgba(0,0,0,.3); }
.champ .who a { text-decoration: none; }
.champ .sub { font-size: 15px; opacity: .85; }


section.block { padding-block: 56px 8px; }
.head { display: flex; justify-content: space-between; align-items: end; gap: 12px 24px; flex-wrap: wrap; margin-bottom: 22px; }
.head h2 { font-family: var(--display); font-weight: 400; font-size: clamp(26px, 3.6vw, 40px); line-height: 1.05; margin-top: 6px; }
.head p { color: var(--muted); margin: 0; max-width: 48ch; }
.more { font-family: var(--cond); font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--red); text-decoration: none; }
.more:hover { text-decoration: underline; }

/* Banner wall */
.rafters { position: relative; padding-top: 14px; }
.rafters::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 6px; border-radius: 3px; background: linear-gradient(var(--line), var(--surface-2)); }
.banners { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 26px 12px; }
@media (min-width: 560px) { .banners { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
@media (min-width: 900px) { .banners { grid-template-columns: repeat(7, minmax(0, 1fr)); } }
/* Arena championship banner: gold trim, spotlight glow from the top, swallowtail cut, lifts toward you on hover. */
.banner { appearance: none; border: 0; display: block; width: 100%; padding: 0 0 44px; cursor: pointer; font: inherit; text-align: center; text-decoration: none; color: var(--on-red);
  background: radial-gradient(120% 60% at 50% 0%, #e85a40 0%, var(--red) 35%, var(--red-deep) 100%);
  clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 86%, 0 100%); filter: drop-shadow(0 12px 14px rgba(0,0,0,.4)); transition: transform .25s ease, filter .25s ease; }
.banner:hover { transform: translateY(-6px) scale(1.03); filter: drop-shadow(0 18px 18px rgba(0,0,0,.45)) brightness(1.08); }
.banner[aria-pressed="true"] { background: radial-gradient(120% 60% at 50% 0%, #fff1bf 0%, #e8c766 35%, #a8811c 100%); color: #2a1a06; transform: translateY(-6px); }
.banner > span { display: block; }
.banner .trim { height: 8px; background: linear-gradient(#f3d77e, #a8811c); }
.banner .trim.lo { margin: 12px auto 0; height: 4px; width: 70%; }
.banner .cap { font-family: var(--cond); font-weight: 700; font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: #f3d77e; margin-top: 12px; padding: 0 4px; }
.banner .yr { font-family: var(--display); font-size: 32px; line-height: 1; margin-top: 4px; }
.banner .nm { font-family: var(--cond); font-weight: 700; font-size: 17px; text-transform: uppercase; letter-spacing: .06em; margin-top: 6px; }
.banner .tm { font-size: 11.5px; opacity: .8; margin-top: 2px; padding: 0 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.banner .st { color: #f3d77e; font-size: 13px; letter-spacing: 2px; margin-top: 6px; }
.banner[aria-pressed="true"] .cap, .banner[aria-pressed="true"] .st { color: #6b4a08; }
.banner[aria-pressed="true"] .trim { background: linear-gradient(#fff6d6, #c99a2a); }
@media (max-width: 559px) { .banner .cap { font-size: 9px; letter-spacing: .08em; } .banner .yr { font-size: 26px; } .banner .nm { font-size: 15px; } }
.banner-note { margin-top: 18px; padding: 14px 18px; background: var(--surface); border-left: 3px solid var(--gold); border-radius: 0 4px 4px 0; min-height: 52px; }
.hooker-count { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.chip { font-family: var(--cond); font-weight: 600; font-size: 14px; letter-spacing: .04em; padding: 5px 10px; border-radius: 999px; background: var(--surface-2); color: var(--fg); white-space: nowrap; text-decoration: none; }
.chip b { color: var(--gold); margin-left: 4px; }

/* Game cards (classics, weekly awards) */
.classics { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 14px; }
.game { background: var(--surface); border: 1px solid var(--line); border-radius: 6px; padding: 16px 18px; display: grid; gap: 6px; align-content: start; }
.game .tag { font-family: var(--cond); text-transform: uppercase; letter-spacing: .12em; font-size: 12px; color: var(--muted); }
.game .big { font-family: var(--cond); font-weight: 700; font-size: 34px; line-height: 1; color: var(--red); }
.game .big.gold { color: var(--gold); }
.game .line { font-size: 15px; }
.game .line b { font-weight: 700; }
.game .note { margin-top: 0; }

/* Manager roster tiles (home) */
.roster { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.mgr { text-decoration: none; color: inherit; background: var(--surface); border: 1px solid var(--line); border-radius: 6px; padding: 12px 14px; display: grid; gap: 2px; transition: border-color .15s, transform .15s; }
.mgr:hover { border-color: var(--red); transform: translateY(-2px); }
.mgr .n { font-family: var(--cond); font-weight: 700; font-size: 20px; letter-spacing: .02em; display: flex; justify-content: space-between; gap: 6px; }
.mgr .n i { font-style: normal; color: var(--gold); font-size: 15px; letter-spacing: .1em; }
.mgr .r { color: var(--muted); font-size: 14px; }

/* Managers index */
.mgrgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); gap: 14px; }
.mcard { text-decoration: none; color: inherit; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; overflow: hidden; display: grid; grid-template-rows: auto 1fr; transition: border-color .15s, transform .15s; }
.mcard:hover { border-color: var(--gold); transform: translateY(-3px); }
.mcard .top-band { background: linear-gradient(160deg, var(--red-deep), #2c0a0b); color: var(--on-red); padding: 14px 16px 12px; display: flex; justify-content: space-between; align-items: end; gap: 10px; }
.mcard h3 { font-family: var(--display); font-weight: 400; font-size: 28px; line-height: 1; }
.mcard .stars { color: var(--gold); font-size: 16px; letter-spacing: .12em; white-space: nowrap; }
.mcard .body { padding: 12px 16px 16px; display: grid; gap: 10px; align-content: start; }
.mcard .rec { font-family: var(--cond); font-weight: 700; font-size: 22px; }
.mcard .rec small { font-weight: 500; font-size: 15px; color: var(--muted); margin-left: 6px; }
.mcard .meta { color: var(--muted); font-size: 14px; }
.mcard .top-badge { font-size: 14px; }
.mcard .top-badge b { font-family: var(--cond); text-transform: uppercase; letter-spacing: .08em; color: var(--gold); margin-right: 6px; }
.former { margin-top: 28px; }
.former h3 { font-family: var(--cond); text-transform: uppercase; letter-spacing: .12em; font-size: 14px; color: var(--muted); margin-bottom: 10px; }

/* Finish-by-season bars */
.finishes { display: flex; align-items: end; gap: 3px; height: 150px; padding-top: 18px; }
.finishes .yr { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; align-items: center; justify-content: end; height: 100%; gap: 4px; }
.finishes .b { width: 100%; max-width: 34px; border-radius: 3px 3px 0 0; background: color-mix(in srgb, var(--muted) 30%, transparent); position: relative; }
.finishes .b.po { background: var(--red); }
.finishes .b.ch { background: var(--gold); }
.finishes .b.now { background: repeating-linear-gradient(135deg, var(--muted) 0 3px, transparent 3px 7px); }
.finishes .f { font-family: var(--cond); font-weight: 700; font-size: 13px; line-height: 1; color: var(--muted); }
.finishes .b.ch + .y, .finishes .yr.ch .f { color: var(--gold); }
.finishes .y { font-family: var(--cond); font-size: 12px; color: var(--muted); line-height: 1; }
.finishes .gap { flex: 1 1 0; }
.finishes.mini { height: 44px; padding-top: 0; gap: 2px; }
.finishes.mini .f, .finishes.mini .y { display: none; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 12px; font-size: 13px; color: var(--muted); }
.legend span::before { content: ""; display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 6px; vertical-align: -1px; background: color-mix(in srgb, var(--muted) 30%, transparent); }
.legend .now::before { background: repeating-linear-gradient(135deg, var(--muted) 0 2px, transparent 2px 4px); }
.legend .ch::before { background: var(--gold); }
.legend .po::before { background: var(--red); }

/* Manager profile */
.profile { margin-top: 24px; background: linear-gradient(160deg, var(--red-deep), #2c0a0b 75%); color: var(--on-red); border-radius: 8px; padding: 26px 24px; display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 24px 32px; border: 2px solid color-mix(in srgb, var(--gold) 60%, transparent); }
.profile h1 { font-family: var(--display); font-weight: 400; font-size: clamp(40px, 7vw, 72px); line-height: 1; margin-top: 6px; }
.profile .rec { font-family: var(--cond); font-weight: 700; font-size: 32px; margin-top: 8px; }
.profile .rec small { font-weight: 500; font-size: 18px; opacity: .8; margin-left: 8px; }
.profile .trophies { margin-top: 4px; }
.profile .badges { margin-top: 16px; }
.profile .kpis { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 18px; align-content: start; }
.profile .kpis span { display: block; font-family: var(--cond); text-transform: uppercase; letter-spacing: .1em; font-size: 12px; opacity: .75; }
.profile .kpis strong { font-family: var(--cond); font-weight: 700; font-size: 26px; line-height: 1.1; }
.profile .kpis em { display: block; font-style: normal; font-size: 13px; opacity: .75; }
.trophies { font-family: var(--cond); letter-spacing: .06em; color: var(--gold); font-weight: 600; }
.badges { display: flex; flex-wrap: wrap; gap: 8px; }
.badge { background: rgba(0,0,0,.28); border: 1px solid color-mix(in srgb, var(--gold) 55%, transparent); border-radius: 4px; padding: 6px 9px; }
.badge b { display: block; font-family: var(--cond); text-transform: uppercase; letter-spacing: .08em; font-size: 14px; color: var(--gold); }
.badge span { font-size: 13px; opacity: .9; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 18px 20px; min-width: 0; }
.stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 14px 18px; }
.stat span { display: block; font-family: var(--cond); text-transform: uppercase; letter-spacing: .1em; font-size: 12px; color: var(--muted); }
.stat strong { font-family: var(--cond); font-weight: 700; font-size: 24px; }
.rivals { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; margin-bottom: 18px; }
.lists { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; }
.list h4, .names h4, .h2h h4 { margin: 0 0 8px; font-family: var(--cond); text-transform: uppercase; letter-spacing: .12em; font-size: 13px; color: var(--muted); font-weight: 600; }
.list ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.list li { display: grid; grid-template-columns: 70px minmax(0, 1fr); gap: 10px; align-items: baseline; }
.list li strong { font-family: var(--cond); font-weight: 700; font-size: 20px; text-align: right; }
.list li span { font-size: 14px; }
.list li small { display: block; color: var(--muted); font-size: 12px; }
.list.good strong { color: var(--gold); }
.list.bad strong { color: var(--red); }
.names div { display: flex; flex-wrap: wrap; gap: 6px; }
.names span { font-size: 14px; padding: 3px 9px; border: 1px solid var(--line); border-radius: 999px; }
.pager { display: flex; justify-content: space-between; gap: 12px; margin-top: 40px; flex-wrap: wrap; }
.pager a { font-family: var(--cond); font-weight: 700; text-transform: uppercase; letter-spacing: .08em; text-decoration: none; padding: 10px 14px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); }
.pager a:hover { border-color: var(--red); }
.pager.top { margin-top: 24px; }

/* Luck lab */
.lab { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 24px; align-items: start; }
.chartbox { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 12px; min-width: 0; }
.chartbox svg { width: 100%; height: auto; display: block; }
.ax { stroke: var(--line); }
.axl { fill: var(--muted); font-family: var(--cond); font-size: 16px; }
.pt { fill: var(--red); stroke: var(--surface); stroke-width: 2; }
.q.up { fill: color-mix(in srgb, var(--gold) 7%, transparent); }
.q.up.strong { fill: color-mix(in srgb, var(--gold) 17%, transparent); }
.q.down { fill: color-mix(in srgb, var(--red) 5%, transparent); }
.q.down.strong { fill: color-mix(in srgb, var(--red) 14%, transparent); }
.even { stroke: var(--fg); stroke-width: 1.5; opacity: .55; }
.avg { stroke: var(--muted); stroke-width: 1; stroke-dasharray: 4 5; }
.zone.dim { opacity: .55; }
.pt-logo .ring { stroke-width: 3; fill: var(--surface); }
.pt-logo.up .ring { stroke: var(--gold); }
.pt-logo.down .ring { stroke: var(--red); }
.pt-init { fill: var(--fg); font-family: var(--cond); font-weight: 700; font-size: 14px; }
.ptl.quiet { font-weight: 500; font-size: 15px; fill: var(--muted); }
.ptl { fill: var(--fg); font-family: var(--cond); font-weight: 600; font-size: 17px; paint-order: stroke; stroke: var(--surface); stroke-width: 4px; stroke-linejoin: round; }
.zone { fill: var(--muted); font-family: var(--display); font-size: 22px; letter-spacing: .04em; text-transform: uppercase; }
.zone.up, .ptl .up { fill: var(--gold); }
.zone.down, .ptl .down { fill: var(--red); }
.zsub { fill: var(--muted); font-family: var(--cond); font-size: 14px; }
.zfill.up { fill: color-mix(in srgb, var(--gold) 9%, transparent); }
.zfill.down { fill: color-mix(in srgb, var(--red) 7%, transparent); }
.stem { stroke-width: 2.5; stroke-linecap: round; opacity: .55; }
.stem.up { stroke: var(--gold); }
.stem.down { stroke: var(--red); }
.pt.up { fill: var(--gold); }
.pt.down { fill: var(--red); }
.verdicts { display: grid; gap: 12px; }
.verdict { background: var(--surface); border: 1px solid var(--line); border-radius: 6px; padding: 14px 16px; }
.verdict .k { font-family: var(--cond); text-transform: uppercase; letter-spacing: .12em; font-size: 12px; color: var(--muted); }
.verdict .v { font-family: var(--cond); font-weight: 700; font-size: 22px; }
.verdict .v.good { color: var(--gold); }
.verdict .v.bad { color: var(--red); }
.verdict p { margin: 4px 0 0; font-size: 14px; color: var(--muted); }

/* Tabs and tables */
.tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.tab { appearance: none; font: inherit; cursor: pointer; font-family: var(--cond); font-weight: 600; text-transform: uppercase; letter-spacing: .08em; font-size: 14px; padding: 8px 14px; border-radius: 4px; border: 1px solid var(--line); background: transparent; color: var(--muted); }
.tab[aria-selected="true"] { background: var(--red); border-color: var(--red); color: var(--on-red); }
.tablewrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); }
table { border-collapse: collapse; width: 100%; font-variant-numeric: tabular-nums; font-size: 15px; }
th, td { padding: 9px 12px; text-align: right; white-space: nowrap; }
th:first-child, td:first-child { text-align: left; }
th { font-family: var(--cond); text-transform: uppercase; letter-spacing: .08em; font-size: 13px; font-weight: 600; color: var(--muted); border-bottom: 1px solid var(--line); position: sticky; top: 0; background: var(--surface); }
table.sortable th { cursor: pointer; user-select: none; }
table.sortable th:hover { color: var(--fg); }
th[aria-sort] { color: var(--gold); }
th[aria-sort="descending"]::after { content: " ▼"; font-size: 10px; }
th[aria-sort="ascending"]::after { content: " ▲"; font-size: 10px; }
tbody tr:nth-child(odd) { background: var(--stripe); }
td:first-child { font-weight: 600; }
td.left, th.left { text-align: left; }
td.lead { color: var(--gold); font-weight: 700; }
.note { color: var(--muted); font-size: 14px; margin-top: 10px; }
td small { display: block; font-size: 12px; color: var(--muted); font-weight: 400; }
.h2h .tablewrap { max-height: 420px; overflow: auto; }
.h2h table { font-size: 14px; }
.h2h td, .h2h th { padding: 6px 10px; }
td.up { color: var(--gold); font-weight: 700; }
td.down { color: var(--red); font-weight: 700; }
tr.cut td { border-bottom: 2px dashed var(--gold); }
tr.champ-row td:first-child::after { content: " ★"; color: var(--gold); }

/* This Season */
.weekbar { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 16px; }
.weekbar .tab { min-width: 44px; text-align: center; }
.board { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 12px; }
.matchup { background: var(--surface); border: 1px solid var(--line); border-radius: 6px; overflow: hidden; }
.matchup .side { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 12px; padding: 10px 14px; align-items: center; border-left: 4px solid transparent; }
.matchup .side + .side { border-top: 1px solid var(--line); }
.matchup .side.win { border-left-color: var(--gold); }
.matchup .who { font-family: var(--cond); font-weight: 700; font-size: 18px; line-height: 1.1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.matchup .team { grid-column: 1; font-size: 13px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.matchup .pts { grid-row: 1 / span 2; grid-column: 2; text-align: right; font-family: var(--cond); font-weight: 700; font-size: 26px; line-height: 1; }
.matchup .side:not(.win) .pts { color: var(--muted); }
/* Yahoo team logos (current season): round avatars beside the name */
.tlogo { display: inline-block; border-radius: 50%; object-fit: cover; background: var(--surface-2); flex: none; }
.tlogo.sm { width: 22px; height: 22px; margin-right: 8px; vertical-align: -6px; }
.tlogo.md { width: 34px; height: 34px; margin-right: 10px; vertical-align: -6px; border: 2px solid var(--gold); }
.tlogo.lg { width: clamp(56px, 9vw, 84px); height: clamp(56px, 9vw, 84px); margin-right: 16px; vertical-align: -10%; border: 3px solid var(--gold); }
.matchup .side.has-logo { grid-template-columns: 40px minmax(0, 1fr) auto; }
.matchup .side.has-logo .tlogo { grid-row: 1 / span 2; width: 40px; height: 40px; }
.matchup .side.has-logo .team { grid-column: 2; }
.matchup .side.has-logo .pts { grid-column: 3; }
.matchup .pts small { display: block; font-size: 12px; font-weight: 500; color: var(--muted); }
.matchup .foot { padding: 6px 14px; font-size: 12px; color: var(--muted); background: var(--surface-2); font-family: var(--cond); letter-spacing: .06em; text-transform: uppercase; }
.awards { margin-top: 18px; }
.bracket { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 16px; align-items: center; }
.round { display: grid; gap: 12px; align-content: center; }
.round h3 { font-family: var(--cond); text-transform: uppercase; letter-spacing: .1em; font-size: 15px; font-weight: 700; color: var(--muted); display: flex; justify-content: space-between; gap: 8px; }
.round h3 small { font-weight: 500; letter-spacing: .06em; }
.round.final h3 { color: var(--gold); }
.round.final .matchup { border: 2px solid var(--gold); box-shadow: 0 12px 30px -16px color-mix(in srgb, var(--gold) 60%, transparent); }
.round .note { margin: 0; }
.power { display: grid; gap: 8px; counter-reset: pr; }
.prow { display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; gap: 4px 14px; align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: 6px; padding: 10px 14px; }
.prow .rk { font-family: var(--display); font-size: 24px; line-height: 1; text-align: center; }
.prow .nm { font-family: var(--cond); font-weight: 700; font-size: 19px; }
.prow .nm small { font-family: var(--body); font-weight: 400; font-size: 13px; color: var(--muted); margin-left: 8px; }
.prow .why { grid-column: 2; font-size: 14px; color: var(--muted); }
.prow .mv { grid-row: 1 / span 2; grid-column: 3; font-family: var(--cond); font-weight: 700; font-size: 16px; text-align: right; min-width: 44px; }
.mv.up { color: var(--gold); }
.mv.down { color: var(--red); }
.mv.same { color: var(--muted); }
.heat td.cell { color: var(--fg); font-weight: 600; }
.heat td.cell.hot { color: #24150a; }

/* Rivalries */
.h2hgrid { font-size: 13px; }
.h2hgrid th, .h2hgrid td { padding: 3px; text-align: center; }
.h2hgrid th[scope="row"] { text-align: left; padding: 3px 10px 3px 8px; font-family: var(--cond); font-size: 15px; font-weight: 700; color: var(--fg); text-transform: none; letter-spacing: 0; position: sticky; left: 0; background: var(--surface); z-index: 1; }
.h2hgrid tbody tr:nth-child(odd) { background: transparent; }
.h2hgrid th.corner { text-align: left; font-size: 11px; vertical-align: bottom; position: sticky; left: 0; z-index: 2; }
.h2hgrid th.colh { height: 92px; vertical-align: bottom; padding-bottom: 8px; }
.h2hgrid th.colh span { writing-mode: vertical-rl; transform: rotate(180deg); white-space: nowrap; font-size: 13px; color: var(--fg); }
.h2hgrid td.self { background: repeating-linear-gradient(135deg, var(--line) 0 2px, transparent 2px 6px); }
.h2hgrid td.empty { color: var(--muted); }
.h2hcell { appearance: none; font: inherit; font-variant-numeric: tabular-nums; font-weight: 600; color: var(--fg); width: 100%; min-width: 52px; padding: 7px 4px; border: 1px solid transparent; border-radius: 4px; cursor: pointer; }
.h2hcell:hover { border-color: var(--fg); }
.picker { display: flex; flex-wrap: wrap; align-items: end; gap: 10px; margin-bottom: 14px; }
.picker label { display: grid; gap: 4px; flex: 1 1 160px; }
.picker label span { font-family: var(--cond); text-transform: uppercase; letter-spacing: .1em; font-size: 12px; color: var(--muted); }
.picker select { font: inherit; font-family: var(--cond); font-weight: 700; font-size: 18px; padding: 8px 10px; border-radius: 6px; border: 1px solid var(--line); background: var(--surface); color: var(--fg); }
.picker .tab { font-size: 18px; padding: 8px 14px; }
.tale { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: 12px; }
.tale .side-a, .tale .side-b { display: flex; align-items: center; gap: 14px; min-width: 0; }
.tale .side-b { justify-content: end; }
.tale a { font-family: var(--display); font-size: clamp(22px, 4vw, 40px); line-height: 1; text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tale strong { font-family: var(--cond); font-weight: 700; font-size: clamp(40px, 7vw, 64px); line-height: 1; }
.tale .side-a strong { color: var(--gold); margin-left: auto; }
.tale .side-b strong { color: var(--red); margin-right: auto; }
.tale .mid { text-align: center; font-family: var(--cond); text-transform: uppercase; letter-spacing: .08em; font-size: 13px; color: var(--muted); }
.strip { display: flex; flex-wrap: wrap; gap: 3px; margin-top: 18px; }
.strip span { width: 14px; height: 22px; border-radius: 2px; }
.strip .w, .legend .w::before { background: var(--gold); }
.strip .l, .legend .l::before { background: var(--red); }
.strip .t { background: var(--muted); }
.strip .po { box-shadow: inset 0 -5px 0 color-mix(in srgb, var(--fg) 70%, transparent); }
.legend .po::before { background: var(--surface-2); box-shadow: inset 0 -4px 0 color-mix(in srgb, var(--fg) 70%, transparent); }
@media (max-width: 520px) {
  .tale { grid-template-columns: 1fr; text-align: center; }
  .tale .side-a, .tale .side-b { justify-content: space-between; }
  .tale .side-b { flex-direction: row-reverse; }
}

/* Luck Lab schedule swap */
.swapgrid td { padding: 7px 6px; font-weight: 600; }
.swapgrid td.actual { outline: 2px solid var(--fg); outline-offset: -3px; border-radius: 4px; }
.swapgrid td.hi { background: color-mix(in srgb, var(--gold) 45%, transparent); }
.swapgrid td.lo { background: color-mix(in srgb, var(--red) 40%, transparent); }
.swapgrid td small { font-weight: 400; }
.picker label.narrow, #swap .picker label { flex: 0 1 200px; }

/* Record Book */
.filters { position: sticky; top: calc(env(safe-area-inset-top, 0px) + 57px); z-index: 4; background: var(--bg); padding: 12px 0 4px; margin-top: 20px; border-bottom: 1px solid var(--line); }
.filters .picker { margin-bottom: 0; }
.filters .note { margin: 6px 0 4px; }
tr.picked td { background: color-mix(in srgb, var(--gold) 18%, transparent); }
@media (max-width: 900px) { .filters { position: static; } }

/* Calorie Counter */
.rushmore { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 14px; }
.face { position: relative; display: grid; gap: 6px; align-content: start; padding: 22px 20px 20px; min-height: 230px; border-radius: 10px 10px 4px 4px; text-decoration: none; color: var(--fg);
  background: linear-gradient(170deg, color-mix(in srgb, var(--fg) 10%, var(--surface)) 0%, var(--surface) 70%); border: 1px solid var(--line); border-top: 4px solid var(--gold); overflow: hidden; }
.face:hover { border-color: var(--gold); }
.face .rk { position: absolute; right: 14px; top: 2px; font-family: var(--display); font-size: 88px; line-height: 1; color: color-mix(in srgb, var(--gold) 22%, transparent); }
.face .nm { position: relative; font-family: var(--display); font-size: clamp(26px, 3.2vw, 36px); line-height: 1.05; margin-top: 18px; }
.face .sc { position: relative; font-family: var(--cond); font-weight: 700; font-size: 30px; color: var(--gold); line-height: 1; }
.face .sc small { font-size: 14px; font-weight: 500; color: var(--muted); letter-spacing: .04em; }
.face .why { position: relative; font-size: 14px; color: var(--muted); }
.face .new { position: relative; justify-self: start; font-family: var(--cond); text-transform: uppercase; letter-spacing: .08em; font-size: 12px; font-weight: 700; padding: 3px 8px; border-radius: 3px; background: var(--red); color: var(--on-red); }
.presets { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.tab[aria-pressed="true"] { background: var(--red); border-color: var(--red); color: var(--on-red); }
.sliders { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 10px 28px; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 18px 20px; }
.slider { display: grid; grid-template-columns: minmax(0, 1fr) 56px; gap: 2px 12px; align-items: center; }
.slider span { grid-column: 1 / -1; font-size: 14px; color: var(--muted); }
.slider input { width: 100%; accent-color: var(--red); min-height: 28px; }
.slider output { font-family: var(--cond); font-weight: 700; font-size: 20px; text-align: right; }
.callegend { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-bottom: 10px; font-size: 13px; color: var(--muted); }
.callegend span { display: inline-flex; align-items: center; gap: 6px; }
.callegend i { width: 12px; height: 12px; border-radius: 2px; display: inline-block; }
.barcol { min-width: 260px; width: 34%; }
.calbar { display: flex; height: 16px; }
.calbar .neg { display: flex; justify-content: flex-end; border-right: 1px solid var(--muted); }
.calbar .pos { display: flex; flex: 1; }
.calbar i { display: block; height: 100%; }
.c-titles { background: var(--gold); }
.c-finals { background: color-mix(in srgb, var(--gold) 50%, var(--surface)); }
.c-trips { background: var(--red); }
.c-powins { background: color-mix(in srgb, var(--red) 50%, var(--surface)); }
.c-seeds { background: var(--fg); }
.c-pf { background: color-mix(in srgb, var(--fg) 55%, var(--surface)); }
.c-over { background: color-mix(in srgb, var(--fg) 25%, var(--surface)); }
.c-lasts { background: repeating-linear-gradient(135deg, var(--red) 0 3px, transparent 3px 6px); }
#calTable tr.mount td:first-child { color: var(--gold); }

/* Drafts & Trades */
.grades { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.grade { display: grid; grid-template-columns: auto auto; gap: 0 8px; align-items: center; padding: 6px 12px 6px 8px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); text-decoration: none; color: var(--fg); }
.grade b { grid-row: 1 / span 2; font-family: var(--display); font-size: 22px; color: var(--gold); min-width: 30px; text-align: center; }
.grade span { font-family: var(--cond); font-weight: 700; font-size: 15px; line-height: 1.1; }
.grade small { font-size: 12px; color: var(--muted); }
.grade.picked { border-color: var(--gold); background: color-mix(in srgb, var(--gold) 14%, var(--surface)); }
.draftwrap { max-height: 78vh; }
.draftboard { font-size: 13px; }
.draftboard th, .draftboard td { padding: 3px; text-align: left; vertical-align: top; }
.draftboard thead th { padding: 8px 6px; z-index: 2; }
.draftboard thead th .mlink { color: var(--fg); }
.draftboard th[scope="row"] { position: sticky; left: 0; z-index: 1; background: var(--surface); text-align: center; vertical-align: middle; color: var(--muted); }
.draftboard th.corner { position: sticky; left: 0; z-index: 3; }
.draftboard tbody tr:nth-child(odd) { background: transparent; }
.draftboard td:first-child { font-weight: inherit; }
.draftboard th.picked, .draftboard td.picked { background: color-mix(in srgb, var(--gold) 12%, transparent); }
.dp { min-width: 118px; max-width: 150px; padding: 5px 7px; border-radius: 4px; background: var(--surface-2); border-left: 3px solid transparent; }
.dp + .dp { margin-top: 3px; }
.dp b { display: block; font-weight: 600; overflow: hidden; text-overflow: ellipsis; }
.dp small { display: block; color: var(--muted); font-size: 11px; font-family: var(--cond); letter-spacing: .04em; }
.dp.steal { background: color-mix(in srgb, var(--gold) 34%, var(--surface-2)); border-left-color: var(--gold); }
.dp.good { border-left-color: var(--gold); }
.dp.bust { background: color-mix(in srgb, var(--red) 30%, var(--surface-2)); border-left-color: var(--red); }
.dp.poor { border-left-color: var(--red); }
.dp.steal small, .dp.bust small { color: var(--fg); }
.dp.err { background: transparent; border: 1px dashed var(--muted); opacity: .75; }
.draftboard tr.keeprow td { border-bottom: 2px solid var(--gold); padding-bottom: 6px; }
.draftboard tr.keeprow th[scope="row"] { color: var(--gold); }
.mix span.fr { background: transparent; color: var(--fg); box-shadow: inset 0 0 0 2px var(--muted); }
.mix .pos-RB.fr { box-shadow: inset 0 0 0 2px var(--red); }
.mix .pos-WR.fr { box-shadow: inset 0 0 0 2px var(--gold); }
.trend td { vertical-align: middle; }
.mix { display: flex; gap: 3px; }
.mix span { font-family: var(--cond); font-weight: 700; font-size: 11px; width: 32px; text-align: center; padding: 3px 0; border-radius: 3px; background: var(--surface-2); color: var(--fg); }
.mix .pos-RB { background: var(--red); color: var(--on-red); }
.mix .pos-WR { background: var(--gold); color: #24150a; }
.mix .pos-QB { background: var(--fg); color: var(--bg); }
.trade .team { white-space: normal; }
.trade .team small { color: var(--muted); font-family: var(--cond); }

/* Roadmap */
.next { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }
.next div { border-top: 3px solid var(--red); padding-top: 12px; }
.next h3 { font-family: var(--cond); font-weight: 700; font-size: 20px; text-transform: uppercase; letter-spacing: .04em; }
.next p { margin: 6px 0 0; color: var(--muted); font-size: 15px; }
footer { margin-top: 64px; border-top: 1px solid var(--line); }
footer .wrap { padding-block: 26px 40px; color: var(--muted); font-size: 14px; display: flex; justify-content: space-between; align-items: center; gap: 12px 24px; flex-wrap: wrap; }
.foot-logo img { height: 56px; width: auto; display: block; }

@media (max-width: 820px) {
  .hero { grid-template-columns: 1fr; padding-top: 28px; }
  .brand img { height: 24px; }
  .lab { grid-template-columns: 1fr; }
  .profile { grid-template-columns: 1fr; }
  .tally { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 520px) {
  .finishes .f { font-size: 11px; }
  .finishes .y { font-size: 10px; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}

/* Recaps */
.recap { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 40px; margin-top: 12px; align-items: start; }
.story p { font-size: 18px; line-height: 1.65; margin: 0 0 18px; max-width: 66ch; }
.story p:first-child::first-letter { font-family: var(--display); float: left; font-size: 62px; line-height: .9; padding: 6px 10px 0 0; color: var(--red); }
.recap-side .side-h { font-family: var(--cond); font-weight: 700; font-size: 15px; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); margin-bottom: 10px; }
.power.mini { gap: 4px; }
.power.mini .prow { grid-template-columns: 26px minmax(0, 1fr) 40px 32px; padding: 6px 10px; gap: 8px; }
.power.mini .rk { font-size: 18px; }
.power.mini .nm { font-size: 16px; }
.power.mini .mv { grid-row: auto; grid-column: auto; font-size: 13px; min-width: 0; }
.power.mini .sc { text-align: right; color: var(--muted); font-size: 14px; }
.tally.wk { margin-top: 8px; }
@media (max-width: 860px) {
  .recap { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .story p { font-size: 17px; }
}

/* A league ruling noted with a season */
.ruling { display: block; margin-top: 10px; padding-left: 12px; border-left: 3px solid var(--gold); font-size: 16px; }
