/*!
 * CHL PUBLISHING ROUND 3 · T7 — PODCAST DESIGNS: structural base.
 *
 * Loaded FIRST by every podcast Design, never on its own. It carries the
 * geometry the three Designs share — the artwork block, the episode grid, the
 * player frame, the transcript rhythm — so each expressive sheet differs by
 * intent rather than by restating layout.
 *
 * ⛔ EVERY RULE IS SCOPED UNDER [class*="pubfmt-pod-d--"]. A podcast page with
 *    no Design chosen loads none of this and reads exactly as it does today;
 *    the plain reader is the floor and must stay byte-identical.
 * ⛔ THIS SHEET STYLES THE PLAYER, IT NEVER REPLACES IT. The listen markup is
 *    emitted solely by chl_podcast_listen_html(): a native <audio> for a
 *    direct audio file, a link card for every other provider. There is no
 *    iframe to style because there is no iframe branch, and none is added.
 * ⛔ No `display:none` on .pubfmt-pod-player, .pubfmt-pod-audio,
 *    .pubfmt-pod-launch or .pubfmt-pod-launch-note: a Design may never hide
 *    the player, the provider host or the "opens in a new tab" disclosure.
 * ⛔ No custom properties: three sheets share one asset path and a token
 *    defined by one would leak into the others.
 */

[class*="pubfmt-pod-d--"] .pubfmt-wrap { max-width: 1100px; }

/* ── artwork ─────────────────────────────────────────────────────────────── */
[class*="pubfmt-pod-d--"] .pubfmt-pod-art,
[class*="pubfmt-pod-d--"] .pubfmt-pod-epart {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
  aspect-ratio: 1 / 1;              /* podcast artwork is square by convention */
  background: #eceff3;
}
[class*="pubfmt-pod-d--"] .pubfmt-pod-head {
  display: flex;
  flex-wrap: wrap;
  gap: clamp(16px, 3vw, 34px);
  align-items: flex-end;
}
[class*="pubfmt-pod-d--"] .pubfmt-pod-head > div { flex: 1 1 300px; min-width: 0; }
[class*="pubfmt-pod-d--"] .pubfmt-pod-art { flex: 0 0 auto; width: clamp(120px, 22vw, 260px); }

/* ── episode list → cards ────────────────────────────────────────────────── */
[class*="pubfmt-pod-d--"] .pubfmt-ep-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
[class*="pubfmt-pod-d--"] .pubfmt-ep-item { min-width: 0; }
[class*="pubfmt-pod-d--"] .pubfmt-ep-link { text-decoration: none; display: block; }
[class*="pubfmt-pod-d--"] .pubfmt-ep-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: baseline;
  margin: 6px 0 0;
}
[class*="pubfmt-pod-d--"] .pubfmt-pod-meta-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: baseline;
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
}

/* ── the player frame (styling only) ────────────────────────────────────── */
[class*="pubfmt-pod-d--"] .pubfmt-pod-player { margin: clamp(18px, 3vw, 30px) 0; }
[class*="pubfmt-pod-d--"] .pubfmt-pod-audio {
  display: block;
  width: 100%;
  min-height: 44px;                  /* a real touch target on every Design */
}
[class*="pubfmt-pod-d--"] .pubfmt-pod-fallback { font-size: 14px; }
[class*="pubfmt-pod-d--"] .pubfmt-pod-launch {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
  align-items: baseline;
  text-decoration: none;
  min-height: 44px;
  padding: 12px 16px;
}
[class*="pubfmt-pod-d--"] .pubfmt-pod-launch-action { font-weight: 650; }
[class*="pubfmt-pod-d--"] .pubfmt-pod-launch-host { font-size: 14px; opacity: .8; }
[class*="pubfmt-pod-d--"] .pubfmt-pod-launch-note { margin: 8px 0 0; font-size: 13px; }

/* ── show notes + transcript rhythm ─────────────────────────────────────── */
[class*="pubfmt-pod-d--"] .pubfmt-prose { max-width: 42rem; }
[class*="pubfmt-pod-d--"] .pubfmt-pod-chapter {
  display: flex;
  gap: 12px;
  align-items: baseline;
  margin: 22px 0 10px;
}
[class*="pubfmt-pod-d--"] .pubfmt-pod-chapter-at {
  flex: 0 0 auto;
  font-variant-numeric: tabular-nums;
  font-size: 13px;
}
[class*="pubfmt-pod-d--"] .pubfmt-pod-cue {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 12px;
  margin: 0 0 10px;
}
[class*="pubfmt-pod-d--"] .pubfmt-pod-cue-at {
  font-variant-numeric: tabular-nums;
  font-size: 13px;
  white-space: nowrap;
}
[class*="pubfmt-pod-d--"] .pubfmt-pod-cue-speaker { grid-column: 2; }
[class*="pubfmt-pod-d--"] .pubfmt-pod-cue-text { grid-column: 2; }
[class*="pubfmt-pod-d--"] .pubfmt-pod-quote { margin: 26px 0; padding: 0 0 0 18px; }
[class*="pubfmt-pod-d--"] .pubfmt-pod-cite { font-size: 14px; opacity: .75; }
[class*="pubfmt-pod-d--"] .pubfmt-pod-divider { border: 0; border-top: 1px solid currentColor; opacity: .14; margin: 30px 0; }

/* ── focus is never removed, only restyled ─────────────────────────────── */
[class*="pubfmt-pod-d--"] a:focus-visible,
[class*="pubfmt-pod-d--"] audio:focus-visible {
  outline: 3px solid currentColor;
  outline-offset: 2px;
}

/* ── mobile ─────────────────────────────────────────────────────────────── */
@media (max-width: 640px) {
  /* ⛔ formats.css:140 flips .pubfmt-pod-head to `flex-direction: column` at
     this width. In a column flex container `flex-basis` is a HEIGHT, so the
     `flex: 1 1 300px` above gave the masthead text a 300px-tall basis and
     opened a ~250px void under the title. Caught in a 390px screenshot, not
     in review. The basis is released here; the shared base owns the
     direction and this sheet must not fight it. */
  [class*="pubfmt-pod-d--"] .pubfmt-pod-head { gap: 16px; align-items: flex-start; }
  [class*="pubfmt-pod-d--"] .pubfmt-pod-head > div { flex: 0 1 auto; }
  [class*="pubfmt-pod-d--"] .pubfmt-pod-art { width: clamp(104px, 36vw, 150px); }
  [class*="pubfmt-pod-d--"] .pubfmt-pod-cue { grid-template-columns: 1fr; }
  [class*="pubfmt-pod-d--"] .pubfmt-pod-cue-at { grid-column: 1; }
  [class*="pubfmt-pod-d--"] .pubfmt-pod-cue-speaker,
  [class*="pubfmt-pod-d--"] .pubfmt-pod-cue-text { grid-column: 1; }
  [class*="pubfmt-pod-d--"] .pubfmt-pod-launch { padding: 12px 14px; }
}
