/* One quiet player; the full chapter list is available on demand. */
.journey-bottom {
  max-width: 800px;
  margin-inline: auto;
  grid-template-columns: 136px minmax(120px, 1fr) 190px;
  align-items: center;
  gap: 28px;
  bottom: calc(36px + env(safe-area-inset-bottom, 0px));
}
.journey-bottom .story-transport {
  position: static;
  gap: 0;
}
.journey-bottom .story-transport button { font-size: 14px; min-height: 44px; }
.journey-bottom .story-transport button > #play-symbol { width: 44px; height: 44px; }
.journey-bottom .timeline { height: 44px; padding: 0; }
.journey-bottom .timeline-track { top: 22px; }
.journey-bottom .timeline input { top: 0; height: 44px; min-height: 44px; }
.story-chapters { position: relative; min-width: 0; }
.story-chapters > summary {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  min-height: 44px;
  padding: 8px 4px 8px 8px;
  border-radius: 6px;
  font-size: 14px;
  line-height: 1.4;
  cursor: pointer;
  list-style: none;
}
.story-chapters > summary::-webkit-details-marker { display: none; }
.story-chapters > summary::marker { content: ''; }
.chapter-chevron { width: 18px; height: 18px; flex: 0 0 18px; fill: none; stroke: currentColor; stroke-width: 1.5; }
.story-chapters[open] .chapter-chevron { rotate: 180deg; }
.journey-bottom .story-chapters .chapters {
  position: absolute;
  right: 0;
  bottom: calc(100% + 12px);
  width: 250px;
  max-width: 80vw;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: stretch;
  gap: 2px;
  padding: 8px;
  border: 1px solid color-mix(in srgb, currentColor 30%, transparent);
  border-radius: 12px;
  background: var(--scene-bg);
  color: var(--scene-ink);
  box-shadow: 0 12px 36px #0003;
}
/* Explicitly retain native disclosure visibility when overriding nav display. */
.journey-bottom .story-chapters:not([open]) .chapters { display: none; }
.journey-bottom .story-chapters .chapters button {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border-radius: 6px;
  font-size: 14px;
  line-height: 1.4;
  text-align: left;
  white-space: normal;
  opacity: 1;
  translate: none;
  box-shadow: none;
}
.journey-bottom .story-chapters .chapters button span { flex: 0 0 18px; font-size: 12px; margin: 0; }
.story-chapters > summary:focus-visible,
.journey-bottom .story-chapters .chapters button:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 3px;
  box-shadow: none;
}
@media (hover: hover) and (pointer: fine) {
  .story-chapters > summary:hover #current-chapter { text-decoration: underline; text-underline-offset: 4px; }
  .journey-bottom .story-chapters .chapters button:hover { background: color-mix(in srgb, currentColor 10%, transparent); }
}
@media (max-width: 600px) {
  .journey-bottom {
    grid-template-columns: auto minmax(0, 1fr);
    gap: 0 16px;
    bottom: calc(20px + env(safe-area-inset-bottom, 0px));
  }
  .journey-bottom .timeline { grid-column: 1 / -1; grid-row: 2; height: 32px; }
  .journey-bottom .timeline-track { top: 22px; }
  .journey-bottom .timeline input { top: 0; }
  .journey-bottom .story-transport { grid-column: 1; grid-row: 1; }
  .story-chapters { grid-column: 2; grid-row: 1; }
  .journey-bottom .story-transport button, .story-chapters > summary { font-size: 13px; }
}
@media (forced-colors: active) {
  .journey-bottom .story-chapters .chapters { border-color: ButtonText; }
  .story-chapters > summary:focus-visible,
  .journey-bottom .story-chapters .chapters button:focus-visible { outline-color: Highlight; }
}
