/* Podcast-Detailseite: lokal begrenzt, Farben wie die Podcastliste (redaktionelles Blau des Design Systems). */
.hwx-podcast-detail {
  --podcast-action: #164f9e;
  --podcast-ink: #0c3247;
  --podcast-line: #dbe3e8;
  --podcast-surface: #f5f8fa;
  --podcast-on-stage: #fff;
  --podcast-on-stage-muted: rgb(255 255 255 / 82%);
  display: grid;
  grid-column: main;
  gap: 1.5rem;
  inline-size: 100%;
  max-inline-size: 1200px;
  min-inline-size: 0;
  margin-inline: auto;
  padding-block: 1.5rem 2.5rem;
  overflow-wrap: anywhere;
}

.hwx-podcast-detail [hidden] {
  display: none !important;
}

.hwx-podcast-detail__back {
  margin: 0;
  font-weight: 600;
}

.hwx-podcast-detail .hwx-podcast-detail__back a {
  color: var(--podcast-action);
  text-underline-offset: .2em;
}

.hwx-podcast-detail__back i {
  margin-inline-end: .5rem;
  font-size: .8125rem;
}

/* Bühne: unscharfes Cover als Stimmung, darüber deckende Fläche für lesbaren Text auf jedem Motiv. */
.hwx-podcast-stage {
  position: relative;
  display: grid;
  grid-template-columns: minmax(14rem, 22rem) minmax(0, 1fr);
  align-items: start;
  gap: 2.5rem;
  padding: 2rem;
  overflow: hidden;
  border-radius: 1.25rem;
  background: var(--podcast-ink);
  color: var(--podcast-on-stage);
  box-shadow: 0 .75rem 2rem rgb(12 50 71 / 18%);
  isolation: isolate;
}

.hwx-podcast-stage::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: rgb(12 50 71 / 80%);
}

.hwx-podcast-stage__backdrop {
  position: absolute;
  inset: -3rem;
  z-index: -2;
  inline-size: calc(100% + 6rem);
  max-inline-size: none;
  block-size: calc(100% + 6rem);
  object-fit: cover;
  filter: blur(3rem) saturate(1.3);
}

.hwx-podcast-stage__cover {
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: .875rem;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23a7b4bd' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='9' y='2' width='6' height='12' rx='3'/%3E%3Cpath d='M5 11a7 7 0 0 0 14 0M12 18v4M8 22h8'/%3E%3C/svg%3E") center / 5rem no-repeat,
    var(--podcast-surface);
  box-shadow: 0 1rem 2.5rem rgb(0 0 0 / 35%);
}

.hwx-podcast-stage__cover img {
  display: block;
  inline-size: 100%;
  max-inline-size: none;
  block-size: 100%;
  margin: 0;
  object-fit: cover;
  color: transparent;
}

.hwx-podcast-stage__content {
  display: grid;
  gap: 1.25rem;
  min-inline-size: 0;
}

.hwx-podcast-stage header {
  display: grid;
  justify-items: start;
  gap: .5rem;
}

/* Schlägt main :is(p, span):not(.readmore); :where hält die Regel für die Klassen darunter überschreibbar. */
.hwx-podcast-detail .hwx-podcast-stage :where(p, span) {
  margin: 0;
  background: transparent;
  color: inherit;
}

.hwx-podcast-stage h1 {
  margin: 0;
  background: transparent;
  padding: 0;
  border: 0;
  color: var(--podcast-on-stage);
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  line-height: 1.2;
  text-wrap: balance;
}

.hwx-podcast-stage h1::before,
.hwx-podcast-stage h1::after {
  display: none;
}

.hwx-podcast-detail .hwx-podcast-stage__show {
  padding: .125rem .75rem;
  border-radius: 9999px;
  background: var(--podcast-on-stage);
  color: var(--podcast-ink);
  font-size: .8125rem;
  font-weight: 700;
  line-height: 1.5;
}

.hwx-podcast-stage__subtitle {
  font-size: 1.125rem;
  line-height: 1.4;
}

.hwx-podcast-detail .hwx-podcast-stage__meta {
  color: var(--podcast-on-stage-muted);
  font-size: .875rem;
  line-height: 1.4;
}

/* Player */
.hwx-podcast-player audio {
  display: block;
  inline-size: 100%;
}

.hwx-podcast-player__ui {
  display: grid;
  gap: .5rem;
}

.hwx-podcast-player input[type="range"] {
  --progress: 0%;
  display: block;
  inline-size: 100%;
  block-size: 2.75rem;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  appearance: none;
}

.hwx-podcast-player input[type="range"]:disabled {
  cursor: default;
  opacity: .6;
}

.hwx-podcast-player input[type="range"]::-webkit-slider-runnable-track {
  block-size: .375rem;
  border-radius: 9999px;
  background: linear-gradient(#fff 0 0) 0 / var(--progress) 100% no-repeat, rgb(255 255 255 / 45%);
}

.hwx-podcast-player input[type="range"]::-moz-range-track {
  block-size: .375rem;
  border-radius: 9999px;
  background: linear-gradient(#fff 0 0) 0 / var(--progress) 100% no-repeat, rgb(255 255 255 / 45%);
}

.hwx-podcast-player input[type="range"]::-webkit-slider-thumb {
  inline-size: 1rem;
  block-size: 1rem;
  margin-block-start: -.3125rem;
  border-radius: 50%;
  background: #fff;
  appearance: none;
}

.hwx-podcast-player input[type="range"]::-moz-range-thumb {
  inline-size: 1rem;
  block-size: 1rem;
  border: 0;
  border-radius: 50%;
  background: #fff;
}

.hwx-podcast-player__times {
  display: flex;
  justify-content: space-between;
  margin-block-start: -.375rem;
  color: var(--podcast-on-stage-muted);
  font-size: .8125rem;
  font-variant-numeric: tabular-nums;
}

.hwx-podcast-detail .hwx-podcast-player__resume {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0 .5rem;
  font-size: .875rem;
}

.hwx-podcast-player button[data-restart] {
  padding-inline: .25rem;
  font-size: .875rem;
  text-decoration: underline;
  text-underline-offset: .2em;
}

.hwx-podcast-player__controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: .5rem 1.5rem;
}

.hwx-podcast-player__transport,
.hwx-podcast-player__extras {
  display: flex;
  align-items: center;
  gap: .5rem;
}

.hwx-podcast-player__extras input[type="range"] {
  inline-size: 6rem;
}

.hwx-podcast-player button {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .25rem;
  min-inline-size: 2.75rem;
  min-block-size: 2.75rem;
  padding: 0 .5rem;
  border: 0;
  border-radius: 9999px;
  background: transparent;
  color: var(--podcast-on-stage);
  font-size: .8125rem;
  font-weight: 700;
  line-height: 1;
  transition: background-color .15s ease, transform .15s ease;
}

.hwx-podcast-player button i {
  font-size: 1.125rem;
}

.hwx-podcast-player button.hwx-podcast-player__speed {
  min-inline-size: 3.25rem;
  font-size: .9375rem;
  font-variant-numeric: tabular-nums;
}

.hwx-podcast-player button.hwx-podcast-player__play {
  inline-size: 4rem;
  block-size: 4rem;
  padding: 0;
  background: #fff;
  color: var(--podcast-ink);
}

.hwx-podcast-player button.hwx-podcast-player__play i {
  font-size: 1.5rem;
}

/* Das Dreieck wirkt mittig gesetzt nach links versetzt. */
.hwx-podcast-player:not(.is-playing) .hwx-podcast-player__play i {
  margin-inline-start: .1875rem;
}

.hwx-podcast-player.is-loading .hwx-podcast-player__play::after {
  content: "";
  position: absolute;
  inset: -.25rem;
  border: 3px solid transparent;
  border-block-start-color: #fff;
  border-radius: 50%;
  animation: hwx-podcast-spin .8s linear infinite;
}

@keyframes hwx-podcast-spin {
  to {
    transform: rotate(360deg);
  }
}

.hwx-podcast-detail .hwx-podcast-player__status {
  margin-block-start: .75rem;
  padding: .625rem .875rem;
  border-radius: .5rem;
  background: #fff;
  color: var(--podcast-ink);
  font-size: .875rem;
}

.hwx-podcast-detail .hwx-podcast-player__status a {
  color: var(--podcast-action);
  font-weight: 700;
}

/* Beschreibung */
.hwx-podcast-stage__text {
  font-size: 1rem;
  line-height: 1.6;
}

.hwx-podcast-detail .hwx-podcast-stage__text > * {
  margin: 0 0 .75rem;
  color: inherit;
}

.hwx-podcast-detail .hwx-podcast-stage__text > :last-child {
  margin-block-end: 0;
}

.hwx-podcast-stage__text :is(h2, h3, h4) {
  padding: 0;
  background: transparent;
  color: inherit;
  font-size: 1.125rem;
}

.hwx-podcast-detail .hwx-podcast-stage__text a {
  color: inherit;
  text-decoration: underline;
}

.hwx-podcast-stage__text.is-clamped {
  max-block-size: 8rem;
  overflow: hidden;
  mask-image: linear-gradient(#000 60%, transparent);
}

.hwx-podcast-stage__more {
  justify-self: start;
  min-block-size: 2.75rem;
  margin-block-start: -.75rem;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--podcast-on-stage);
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: .2em;
}

/* Fokus */
.hwx-podcast-detail__back a:focus-visible {
  outline: 3px solid var(--podcast-action);
  outline-offset: 4px;
}

.hwx-podcast-stage :is(a, button, input):focus-visible {
  outline: 3px solid #fff;
  outline-offset: 3px;
}

.hwx-podcast-player__status a:focus-visible {
  outline-color: var(--podcast-action) !important;
}

@media (hover: hover) {
  .hwx-podcast-player button:hover {
    background: rgb(255 255 255 / 16%);
  }

  .hwx-podcast-player button.hwx-podcast-player__play:hover {
    background: #fff;
    transform: scale(1.06);
  }
}

/* Verknüpfte Inhalte: vorhandene Slider auf die Kartenform des Design Systems bringen. */
.hwx-podcast-detail__more {
  display: grid;
  gap: 2rem;
  min-inline-size: 0;
}

.hwx-podcast-detail .hwx-podcast-detail__more h2 {
  margin: 0 0 1rem;
  padding: 0;
  background: transparent;
  color: var(--podcast-ink);
  font-size: clamp(1.375rem, 2.35vw, 2rem);
}

/* Als Grid wäre der Slider-Viewport nur eine Spalte breit und zeigte eine einzige Folge. */
.hwx-podcast-detail__more .hwx-lmdb-detail-item-additional-content-items {
  display: block;
}

/* Feste Zellenbreite: Das Slider-CSS rechnet sonst in Prozent der nun vollen Breite. */
.hwx-podcast-detail__more .carousel-cell {
  inline-size: min(16.5rem, 78vw);
  margin-inline-end: .75rem;
}

.hwx-podcast-detail__more .carousel-cell .hwx-lmdb-list-item-imageblock {
  inline-size: 100%;
  block-size: auto;
  aspect-ratio: 1;
}

.hwx-podcast-detail__more .carousel-cell .hwx-lmdb-list-item-imageblock :is(.hwx-lmdb-list-item-image, img) {
  inline-size: 100%;
  max-inline-size: none;
  block-size: 100%;
}

.hwx-podcast-detail__more .carousel-cell .hwx-lmdb-list-item-content-wrapper {
  background: #fff;
}

.hwx-podcast-detail__more .hwx-lmdb-list-item {
  overflow: hidden;
  border: 1px solid var(--podcast-line);
  border-radius: .875rem;
  background: #fff;
}

/* Nur wenige Folgen haben einen Text; er würde alle Karten des Sliders strecken. */
.hwx-podcast-detail__more .hwx-lmdb-detail-item-podcastsblock .hwx-lmdb-list-item-content-description {
  display: none;
}

/* Immer zwei Titelzeilen: So sind alle Karten gleich hoch und die Dauer steht auf einer Linie. */
.hwx-podcast-detail__more .hwx-lmdb-detail-item-podcastsblock .hwx-lmdb-list-item-content-title-text {
  display: -webkit-box;
  min-block-size: 2.6em;
  margin: 0;
  overflow: hidden;
  line-height: 1.3;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
}

.hwx-podcast-detail .carousel-cell .hwx-podcast-duration {
  display: block;
  padding-block-start: .5rem;
  color: #596975;
  font-size: .8125rem;
}

.hwx-podcast-detail .carousel-cell .hwx-podcast-duration span {
  color: inherit;
}

@media (max-width: 767.98px) {
  .hwx-podcast-stage {
    grid-template-columns: minmax(0, 1fr);
    gap: 1.25rem;
    padding: 1.25rem;
  }

  .hwx-podcast-stage__cover {
    inline-size: min(100%, 16rem);
    justify-self: center;
  }

  .hwx-podcast-player__controls {
    justify-content: center;
  }

  /* Auf Mobilgeräten regeln die Gerätetasten die Lautstärke. */
  .hwx-podcast-player__extras input[type="range"] {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hwx-podcast-player button {
    transition: none;
  }

  .hwx-podcast-player button.hwx-podcast-player__play:hover {
    transform: none;
  }

  .hwx-podcast-player.is-loading .hwx-podcast-player__play::after {
    animation: none;
  }
}

.hwx-podcast-detail ::selection {
  background: var(--podcast-action);
  color: #fff;
}
