/* Basketball Coach Podcast: the coaching whiteboard. */
:root {
  --board: #f6f8f7;
  --board-edge: #e3e8e6;
  --ink: #1d3fae;          /* dry-erase blue */
  --ink-soft: #dfe6fb;
  --marker-red: #c4232c;   /* used only for the live play state */
  --graphite: #23272c;
  --graphite-2: #545b63;
  --line: #c7ced4;
  --wave: #c7ced4;
  --paper: #ffffff;
  --focus: #1d3fae;
  --display: "Big Shoulders Display", "Arial Narrow", sans-serif;
  --body: "Public Sans", system-ui, sans-serif;
  --measure: 68ch;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --board: #15191d; --board-edge: #23292f; --ink: #8fa8ff; --ink-soft: #1f2a4d;
    --marker-red: #ff6b6b; --graphite: #e8ecef; --graphite-2: #a9b1b9; --line: #3a424a; --wave: #5d6873;
    --paper: #1b2025; --focus: #8fa8ff;
  }
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--board); color: var(--graphite);
  font: 400 1.0625rem/1.65 var(--body); overflow-x: hidden;
}
a { color: var(--ink); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 4px; }
.wrap { width: min(100% - 32px, 1080px); margin-inline: auto; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 16px; top: 12px; background: var(--paper); padding: 8px 12px; z-index: 10; }

/* Header */
.top { border-bottom: 1px solid var(--board-edge); }
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-block: 14px; }
.mark { font: 800 1.5rem/1 var(--display); color: var(--graphite); text-decoration: none; letter-spacing: 0.01em; }
.mark span { color: var(--ink); }
.mark { display: inline-flex; align-items: center; gap: 10px; }
.mark img { flex: none; border-radius: 8px; }
.nav { display: flex; gap: 20px; font-weight: 600; font-size: 0.95rem; }
.nav a { color: var(--graphite); text-decoration: none; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--ink); }

/* Type scale: 1.0625 body, 1.25, 1.6, 2.4, clamp display */
h1, h2, h3 { font-family: var(--display); font-weight: 800; line-height: 1.02; letter-spacing: 0.005em; margin: 0; }
h1 { font-size: clamp(2.6rem, 7.2vw, 5.4rem); max-width: 18ch; text-wrap: balance; }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.4rem); margin-top: 2.4rem; }
h3 { font-size: 1.6rem; }
p { margin: 0.9rem 0; max-width: var(--measure); }

/* Hero (index) */
.hero { padding-block: clamp(40px, 8vw, 96px) 28px; }
.hero .lede { font-size: 1.25rem; color: var(--graphite-2); max-width: 46ch; }
.host { display: flex; align-items: center; gap: 10px; color: var(--graphite-2); font-size: 0.95rem; margin-top: 18px; }
.host b { color: var(--graphite); }

/* The waveform player: the one loud element */
.player { margin-top: 28px; background: var(--paper); border: 1px solid var(--board-edge); border-radius: 18px; padding: 18px; }
.player-row { display: grid; grid-template-columns: 64px 1fr; gap: 16px; align-items: center; }
.play {
  width: 64px; height: 64px; border-radius: 50%; border: 0; cursor: pointer;
  background: var(--ink); color: var(--paper); display: grid; place-items: center;
}
.play svg { width: 26px; height: 26px; fill: currentColor; }
.play[aria-pressed="true"] { background: var(--marker-red); }
.wave { position: relative; height: 72px; cursor: pointer; touch-action: none; }
.wave svg { width: 100%; height: 100%; display: block; }
.wave rect { fill: var(--wave); }
.wave .played rect { fill: var(--ink); }
.player-meta { display: flex; justify-content: space-between; gap: 12px; margin-top: 8px; font-size: 0.875rem; color: var(--graphite-2); font-variant-numeric: tabular-nums; }
.ai-note { font-size: 0.9rem; color: var(--graphite-2); margin: 12px 0 0; }
.player.no-audio .player-row { grid-template-columns: 1fr; }

/* Episode list */
.list { list-style: none; margin: 8px 0 0; padding: 0; border-top: 1px solid var(--line); }
.list li { border-bottom: 1px solid var(--line); }
.row { display: grid; grid-template-columns: 3.2rem 1fr auto; gap: 14px; align-items: baseline; padding: 22px 0; color: inherit; text-decoration: none; }
.row .num { font: 800 1.6rem/1 var(--display); color: var(--ink); font-variant-numeric: tabular-nums; }
.row h3 { font-size: clamp(1.45rem, 3vw, 1.9rem); }
.row p { margin: 6px 0 0; color: var(--graphite-2); font-size: 0.98rem; }
.row .len { color: var(--graphite-2); font-size: 0.9rem; white-space: nowrap; font-variant-numeric: tabular-nums; }
.row:hover h3 { color: var(--ink); }
.search { margin-top: 36px; display: flex; gap: 10px; align-items: center; }
.search input { flex: 1; font: inherit; padding: 12px 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--paper); color: var(--graphite); min-width: 0; }

/* Episode page */
.crumbs { font-size: 0.9rem; color: var(--graphite-2); padding-top: 28px; }
.crumbs a { color: var(--graphite-2); }
.ep-meta { color: var(--graphite-2); font-size: 0.95rem; margin: 18px 0 14px; font-variant-numeric: tabular-nums; }
.short { margin-top: 32px; border-left: 6px solid var(--ink); padding: 4px 0 4px 20px; }
.short h2 { margin-top: 0; font-size: 1.6rem; }
.short p { font-size: 1.25rem; line-height: 1.55; }
.cols { display: grid; gap: 8px 48px; grid-template-columns: 1fr; }
@media (min-width: 900px) { .cols { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); } }
ul.plain { padding-left: 1.1rem; max-width: var(--measure); }
ul.plain li { margin: 0.4rem 0; }
.versions { display: grid; gap: 14px; margin-top: 14px; }
.version { background: var(--paper); border: 1px solid var(--board-edge); border-radius: 12px; padding: 16px 18px; }
.version h3 { font-size: 1.35rem; color: var(--ink); }
.version p { margin: 6px 0 0; }
.deeper { background: var(--ink-soft); border-radius: 16px; padding: 20px 22px; margin-top: 2.4rem; }
.deeper h2 { margin-top: 0; font-size: 1.6rem; }
.deeper ul { list-style: none; padding: 0; margin: 12px 0 0; display: grid; gap: 10px; }
.deeper a { font-weight: 600; }
details.transcript { margin-top: 2.4rem; border-top: 1px solid var(--line); padding-top: 16px; }
details.transcript summary { cursor: pointer; font: 800 1.7rem/1.1 var(--display); list-style: none; }
details.transcript summary::-webkit-details-marker { display: none; }
details.transcript summary::after { content: " +"; color: var(--ink); }
details.transcript[open] summary::after { content: " \2212"; }
.transcript-body p { max-width: var(--measure); }

.subscribe { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.subscribe a { border: 1px solid var(--line); border-radius: 999px; padding: 8px 14px; text-decoration: none; font-weight: 600; background: var(--paper); }

footer { margin-top: 72px; border-top: 1px solid var(--board-edge); padding: 28px 0 48px; color: var(--graphite-2); font-size: 0.92rem; }
footer p { margin: 6px 0; }

@media (max-width: 560px) {
  .nav { gap: 14px; font-size: 0.9rem; }
  .mark { font-size: 1.2rem; max-width: 9ch; }
  .row { grid-template-columns: 2.4rem 1fr; }
  .row .len { grid-column: 2; }
  .player-row { grid-template-columns: 56px 1fr; }
  .play { width: 56px; height: 56px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

.chapters { margin-top: 24px; }
.chapters h2 { font-size: 1.4rem; }
.chapters ol { list-style: none; padding: 0; margin: 8px 0 0; display: grid; gap: 4px; }
.chapters button { font: inherit; color: inherit; background: none; border: 0; padding: 6px 0; cursor: pointer; text-align: left; min-height: 44px; }
.chapters button span { display: inline-block; min-width: 3.4em; font-weight: 600; color: var(--ink); }
.chapters button:hover, .chapters button:focus-visible { text-decoration: underline; }
