/* ==========================================================================
   episode.css — loads after site.css, only on the episode watch page
   ========================================================================== */

/* Breadcrumb */
.crumbs {
  font-family: var(--font-util);
  font-size: 0.6875rem;
  font-weight: 300;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--type-3);
  padding-block: 1rem 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.crumbs a { border-bottom: 1px solid transparent; }
.crumbs a:hover, .crumbs a:focus-visible { border-bottom-color: var(--line-2); color: var(--navy); }
.crumbs__now { color: var(--type-2); }

/* Video stage — primary content, but capped so it doesn't eat the viewport.
   960px keeps a 16:9 frame at ~540px tall, which leaves the headline visible
   above the fold on a laptop. */
.ep__stage { padding-bottom: 1.5rem; }

.ep__video {
  position: relative;
  aspect-ratio: 16 / 9;
  max-height: 68vh;
  max-width: calc(68vh * 16 / 9);
  margin-inline: auto;
  background: var(--navy);
  border-radius: var(--r);
  overflow: hidden;
}

.ep__video::before {
  content: "Video unavailable — check that embeds aren't blocked";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 1rem;
  font-family: var(--font-util);
  font-size: 0.75rem;
  font-weight: 300;
  letter-spacing: 0.08em;
  color: var(--on-dark-2);
}

.ep__video iframe,
.ep__video img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  object-fit: cover;
}

/* Fallback for browsers without aspect-ratio */
@supports not (aspect-ratio: 16 / 9) {
  .ep__video { height: 0; padding-bottom: 56.25%; }
}

/* Two-column body */
.ep__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.9fr) minmax(0, 1fr);
  gap: 2.5rem;
  padding-bottom: 3rem;
}

.ep__head { padding-bottom: 1.1rem; border-bottom: 1px solid var(--line); }

.ep__kicker {
  font-family: var(--font-util);
  font-size: 0.6875rem;
  font-weight: 400;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--type-3);
  margin-bottom: 0.5rem;
}

.ep__title {
  font-size: 1.875rem;
  line-height: 1.15;
  max-width: 26ch;
}

.ep__meta {
  font-family: var(--font-util);
  font-size: 0.8125rem;
  font-weight: 300;
  letter-spacing: 0.05em;
  color: var(--type-3);
  margin-top: 0.6rem;
}

/* Audio */
.ep__listen {
  background: var(--surface);
  border-radius: var(--r);
  padding: 0.9rem 1rem 1rem;
  margin-top: 1.4rem;
}

.ep__listenLabel {
  font-family: var(--font-util);
  font-size: 0.6875rem;
  font-weight: 400;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--type-3);
  margin-bottom: 0.55rem;
}

.ep__listen audio { width: 100%; display: block; }

.ep__download {
  margin-top: 0.6rem;
  font-size: 0.875rem;
  color: var(--type-2);
}

.ep__download a {
  color: var(--navy);
  border-bottom: 1px solid var(--line-2);
}

.ep__download a:hover,
.ep__download a:focus-visible { border-bottom-color: var(--navy); }

/* Body copy */
.ep__prose { margin-top: 1.6rem; }

.ep__prose p {
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--type);
  margin-bottom: 1rem;
  max-width: 68ch;
}

/* Transcript — on the page, collapsed, so Google indexes it either way */
.ep__transcript { margin-top: 2rem; border-top: 1px solid var(--line); padding-top: 1.5rem; }

.ep__transcript summary {
  font-family: var(--font-util);
  font-size: 0.8125rem;
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--navy);
  cursor: pointer;
  list-style: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border: 1px solid var(--line-2);
  border-radius: var(--r);
  padding: 0.55rem 1.1rem;
  transition: background 0.18s var(--ease), border-color 0.18s var(--ease);
}

.ep__transcript summary::-webkit-details-marker { display: none; }

.ep__transcript summary::after {
  content: "+";
  font-size: 1rem;
  line-height: 1;
}

.ep__transcript details[open] summary::after { content: "\2212"; }

.ep__transcript summary:hover,
.ep__transcript summary:focus-visible { background: var(--surface); border-color: var(--navy); }

.ep__transcriptBody {
  margin-top: 1.25rem;
  padding-left: 1rem;
  border-left: 2px solid var(--line);
  border-radius: 0;
}

.ep__transcriptBody p {
  font-size: 0.9375rem;
  line-height: 1.75;
  color: var(--type-2);
  margin-bottom: 0.9rem;
  max-width: 70ch;
}

/* Rail */
.ep__rail { display: flex; flex-direction: column; gap: 2rem; }

.ep__rail .rail__head {
  font-family: var(--font-util);
  font-size: 0.6875rem;
  font-weight: 400;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--type-2);
  padding-bottom: 0.6rem;
  border-bottom: 2px solid var(--gold);
  margin-bottom: 0.6rem;
}

/* Chapters */
.chapters__list { list-style: none; margin: 0; padding: 0; counter-reset: none; }

.chapters__item {
  display: flex;
  gap: 0.75rem;
  align-items: baseline;
  width: 100%;
  text-align: left;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line);
  padding: 0.65rem 0.4rem 0.65rem 0;
  transition: background 0.16s var(--ease), padding-left 0.16s var(--ease);
}

.chapters__item:hover,
.chapters__item:focus-visible { background: var(--surface); padding-left: 0.4rem; }

.chapters__time {
  flex-shrink: 0;
  font-family: var(--font-util);
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--navy-3);
  font-variant-numeric: tabular-nums;
  min-width: 3.2em;
}

.chapters__label {
  font-size: 0.875rem;
  line-height: 1.4;
  color: var(--type);
}

/* Tags */
.eptags__list { display: flex; flex-wrap: wrap; gap: 0.4rem; }

.eptag {
  font-family: var(--font-util);
  font-size: 0.6875rem;
  font-weight: 300;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--type-2);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 0.3rem 0.65rem;
  transition: border-color 0.18s var(--ease), color 0.18s var(--ease);
}

.eptag:hover, .eptag:focus-visible { border-color: var(--navy); color: var(--navy); }

/* Related */
.related__list { list-style: none; margin: 0; padding: 0; }

.related__list li { border-bottom: 1px solid var(--line); }

.related__list a {
  display: block;
  padding: 0.8rem 0;
  transition: padding-left 0.18s var(--ease);
}

.related__list a:hover,
.related__list a:focus-visible { padding-left: 0.4rem; }

.related__title {
  display: block;
  font-family: var(--font-display);
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.35;
}

.related__list a:hover .related__title { color: var(--navy-3); }

.related__meta {
  display: block;
  font-family: var(--font-util);
  font-size: 0.6875rem;
  font-weight: 300;
  letter-spacing: 0.06em;
  color: var(--type-3);
  margin-top: 0.25rem;
}

/* Responsive */
@media (max-width: 900px) {
  .ep__grid { grid-template-columns: 1fr; gap: 2rem; }
  .ep__title { font-size: 1.625rem; max-width: none; }
}

@media (max-width: 620px) {
  .ep__stage { padding-inline: 0; }
  .ep__video { border-radius: 0; }
  .ep__title { font-size: 1.375rem; }
  .ep__prose p { font-size: 1rem; }
}
