/* V59.8: a film cover invitation and a restrained viewing surface. */
#detail.stage-detail {
  width: 320px; height: fit-content; bottom: auto; max-height: calc(100% - 110px);
  padding: 12px; border: 1px solid #fff9; border-radius: 16px;
  background: #faf9f5; box-shadow: 0 10px 40px #18332a1c; overflow: auto;
}
#detail.stage-detail .detail-top {
  position: static; display: flex; justify-content: space-between; align-items: center;
  min-height: 36px; padding: 0 0 8px 6px; margin: 0; background: none;
}
#detail.stage-detail h2 {
  margin: 0; color: #626c60; font: 500 11px/1.5 var(--sans, sans-serif); letter-spacing: .12em;
}
#detail.stage-detail .close-button {
  display: grid; place-items: center; width: 36px; height: 36px; min-width: 36px;
  padding: 0; border: 0; border-radius: 50%; background: transparent; color: #67705f;
  font: 300 25px/1 var(--sans, sans-serif); box-shadow: none;
}
#detail.stage-detail .close-button:hover { background: #eaece4; }
#detail.stage-detail .stage-film-launch { display: block; width: 100%; padding: 0; text-align: left; border: 0; background: transparent; border-radius: 10px; box-shadow: none; }
#detail.stage-detail .stage-film-launch:hover { filter: none; }
#detail.stage-detail .stage-film-cover { display: block; position: relative; aspect-ratio: 16 / 9; overflow: hidden; border-radius: 9px; background: #28302c; }
#detail.stage-detail .stage-film-cover img { display: block; width: 100%; height: 100%; object-fit: cover; }
#detail.stage-detail .stage-film-play {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%;
  color: #fff; background: #ffffff1f; border: 1px solid #ffffffba;
  backdrop-filter: blur(6px); transition: background .18s ease, border-color .18s ease;
}
#detail.stage-detail .stage-film-play svg { width: 21px; height: 21px; fill: currentColor; margin-left: -2px; }
#detail.stage-detail .stage-film-launch:hover .stage-film-play { background: #ffffff40; border-color: #fff; }
#detail.stage-detail .stage-film-caption { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 6px 0; }
#detail.stage-detail .stage-film-name { font: 500 23px/1.4 "Songti SC", "Noto Serif SC", SimSun, serif; color: #263e35; letter-spacing: .04em; }
#detail.stage-detail .stage-film-action { flex-shrink: 0; font: 500 11px/1.5 var(--sans, sans-serif); color: #52684f; }
#detail.stage-detail .stage-film-description { margin: 9px 6px 6px; color: #687163; font: 400 12px/1.8 var(--sans, sans-serif); }
#detail.stage-detail :is(button, h2):focus-visible { outline: 2px solid #527565; outline-offset: 3px; }

#stage-media-panel.stage-cinema {
  --cinema-ink: #f1f1e9; --cinema-muted: #a0a5a1; --cinema-line: #ffffff18;
  position: fixed; inset: 0; width: min(1200px, 94vw, calc((100svh - 160px) * 16 / 9));
  max-width: none; min-width: 280px; height: fit-content; max-height: calc(100svh - 32px);
  margin: auto; padding: 0; border: 1px solid #ffffff16; border-radius: 14px;
  color: var(--cinema-ink); background: #141817; box-shadow: 0 28px 100px #0009;
  overflow: auto; overscroll-behavior: contain; color-scheme: dark;
}
#stage-media-panel.stage-cinema:not([open]), #stage-media-panel [hidden] { display: none !important; }
#stage-media-panel::backdrop { background: #0a100edb; backdrop-filter: blur(8px); }
#stage-media-panel .cinema-header {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  height: 64px; min-height: 64px; padding: 10px 20px; background: #141817;
}
#stage-media-panel .cinema-eyebrow { display: block; margin-bottom: 3px; color: #9ca69c; font: 400 10px/1.4 var(--sans, sans-serif); letter-spacing: .12em; }
#stage-media-panel h2 { margin: 0; color: var(--cinema-ink); font: 500 17px/1.4 var(--sans, sans-serif); letter-spacing: .07em; }
#stage-media-panel button {
  display: grid; place-items: center; flex: 0 0 44px; width: 44px; height: 44px; min-height: 44px;
  padding: 0; border: 0; border-radius: 50%; background: transparent; color: var(--cinema-ink);
  box-shadow: none; cursor: pointer; touch-action: manipulation;
}
#stage-media-panel button:hover { background: #ffffff0f; filter: none; }
#stage-media-panel :is(button, input):focus-visible { outline: 2px solid #d5dfc6; outline-offset: 2px; }
#stage-media-panel svg { display: block; width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
#stage-media-panel #stage-media-close { margin-right: -8px; color: #c1c6be; }
#stage-media-panel .cinema-screen { position: relative; background: #080a09; }
#stage-media-panel .stage-video-host { width: 100%; aspect-ratio: 16 / 9; margin: 0; border-radius: 0; background: #080a09; }
#stage-media-panel .stage-video-host video { display: block; width: 100%; height: 100%; object-fit: contain; }
#stage-media-panel #media-status { position: absolute; left: 50%; bottom: 16px; transform: translateX(-50%); width: max-content; max-width: calc(100% - 32px); margin: 0; padding: 10px 16px; border-radius: 6px; background: #111a16e6; color: #e3e7df; font-size: 13px; text-align: center; }
#stage-media-panel #media-status:not(.media-status-notice), #stage-media-panel .cinema-sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap;
}
#stage-media-panel .media-controls { display: flex; align-items: center; gap: 12px; height: 64px; margin: 0; padding: 10px 16px; }
#stage-media-panel #media-play { background: #ffffff0c; }
#stage-media-panel #media-play:hover { background: #ffffff1a; }
#stage-media-panel .icon-play { fill: currentColor; stroke: none; }
#stage-media-panel .icon-pause { stroke-width: 2.4; }
#stage-media-panel #media-play:not(.is-playing) .icon-pause,
#stage-media-panel #media-play.is-playing .icon-play,
#stage-media-panel #media-mute[aria-pressed="true"] .icon-sound,
#stage-media-panel #media-mute[aria-pressed="false"] .icon-muted { display: none; }
#stage-media-panel .media-progress-label { display: flex; flex: 1; align-items: center; gap: 18px; margin: 0; min-width: 0; color: var(--cinema-muted); font-size: 11px; }
#stage-media-panel #media-time { flex-shrink: 0; float: none; color: #b9c0b8; font: 400 11px/1.5 ui-monospace, monospace; font-variant-numeric: tabular-nums; white-space: nowrap; }
#stage-media-panel input[type="range"] { appearance: none; -webkit-appearance: none; display: block; flex: 1; width: 100%; min-width: 0; height: 32px; margin: 0; padding: 0; border: 0; border-radius: 0; box-shadow: none; background: transparent; cursor: pointer; }
#stage-media-panel input[type="range"]::-webkit-slider-runnable-track { height: 2px; border-radius: 2px; background: #707c7366; }
#stage-media-panel input[type="range"]::-moz-range-track { height: 2px; border-radius: 2px; background: #707c7366; }
#stage-media-panel input[type="range"]::-webkit-slider-thumb { appearance: none; -webkit-appearance: none; width: 9px; height: 9px; margin-top: -3.5px; border: 0; border-radius: 50%; background: #d4ddca; }
#stage-media-panel input[type="range"]::-moz-range-thumb { width: 9px; height: 9px; border: 0; border-radius: 50%; background: #d4ddca; }
#stage-media-panel .media-audio { display: flex; align-items: center; gap: 2px; }
#stage-media-panel .media-volume-label { display: block; width: 62px; margin: 0; }
#stage-media-panel .stage-program-list:not([hidden]) { padding: 12px 20px; }
#stage-media-panel .stage-program-list button { display: flex; width: 100%; justify-content: space-between; border-radius: 6px; padding: 0 12px; }

@media (max-width: 700px) {
  #detail.stage-detail { width: auto; top: auto; bottom: max(80px, calc(env(safe-area-inset-bottom) + 68px)); left: 12px; right: 12px; padding: 10px 12px 12px; max-height: calc(100% - 210px); }
  #detail.stage-detail .detail-top { min-height: 36px; padding: 0 0 4px 2px; }
  #detail.stage-detail .close-button { width: 44px; height: 44px; }
  #detail.stage-detail .stage-film-launch { display: grid; grid-template-columns: 122px 1fr; align-items: center; gap: 16px; }
  #detail.stage-detail .stage-film-caption { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; padding: 0; }
  #detail.stage-detail .stage-film-name { font-size: 21px; }
  #detail.stage-detail .stage-film-play { width: 34px; height: 34px; }
  #detail.stage-detail .stage-film-play svg { width: 17px; height: 17px; }
  #detail.stage-detail .stage-film-description { margin: 10px 2px 0; font-size: 11px; }
  #stage-media-panel.stage-cinema { width: 100%; min-width: 0; height: 100%; height: 100dvh; max-height: none; margin: 0; border: 0; border-radius: 0; padding: env(safe-area-inset-top, 0px) 0 env(safe-area-inset-bottom, 0px); }
  #stage-media-panel.stage-cinema[open] { display: flex; flex-direction: column; }
  #stage-media-panel .cinema-header { height: 70px; flex-shrink: 0; padding: 10px 18px; }
  #stage-media-panel .cinema-screen { margin-top: auto; flex-shrink: 0; }
  #stage-media-panel .media-controls { flex-shrink: 0; height: auto; display: grid; grid-template-columns: 44px 1fr 44px 44px; gap: 0 8px; padding: 4px 12px 12px; margin-bottom: auto; }
  #stage-media-panel .media-progress-label { grid-row: 1; grid-column: 1 / -1; gap: 14px; }
  #stage-media-panel #media-play { grid-row: 2; grid-column: 1; }
  #stage-media-panel .media-audio { grid-row: 2; grid-column: 3; }
  #stage-media-panel #media-fullscreen { grid-row: 2; grid-column: 4; }
  #stage-media-panel .media-volume-label { display: none; }
}
@media (max-width: 359px) {
  #detail.stage-detail .stage-film-launch { grid-template-columns: 104px 1fr; gap: 12px; }
  #detail.stage-detail .stage-film-name { font-size: 19px; }
}
@media (orientation: landscape) and (max-height: 540px) {
  #detail.stage-detail { left: auto; right: 12px; top: calc(var(--header-height, 60px) + 64px); bottom: auto; width: min(300px, 45vw); padding: 8px 12px; max-height: calc(100% - var(--header-height, 60px) - 80px); }
  #detail.stage-detail .detail-top { min-height: 30px; padding-bottom: 2px; }
  #detail.stage-detail .stage-film-launch { display: grid; grid-template-columns: 100px 1fr; gap: 12px; align-items: center; }
  #detail.stage-detail .stage-film-caption { padding: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
  #detail.stage-detail .stage-film-name { font-size: 19px; }
  #detail.stage-detail .stage-film-description { margin: 8px 2px 2px; font-size: 11px; }
  #stage-media-panel.stage-cinema { width: 100%; height: 100%; height: 100dvh; max-height: none; min-width: 0; margin: 0; padding: env(safe-area-inset-top, 0px) env(safe-area-inset-right, 0px) env(safe-area-inset-bottom, 0px) env(safe-area-inset-left, 0px); border: 0; border-radius: 0; }
  #stage-media-panel.stage-cinema[open] { display: flex; flex-direction: column; }
  #stage-media-panel .cinema-header { height: 44px; min-height: 44px; flex-shrink: 0; padding: 0 12px; }
  #stage-media-panel .cinema-eyebrow { display: none; }
  #stage-media-panel h2 { font-size: 14px; }
  #stage-media-panel .cinema-screen { display: flex; flex: 1; min-height: 0; align-items: center; justify-content: center; margin: 0; }
  #stage-media-panel .stage-video-host { height: 100%; width: 100%; aspect-ratio: auto; }
  #stage-media-panel .media-controls { flex-shrink: 0; display: flex; align-items: center; height: 48px; gap: 8px; margin: 0; padding: 2px 8px; }
  #stage-media-panel .media-progress-label { flex: 1; gap: 10px; }
  #stage-media-panel .media-volume-label { display: none; }
}
@media (prefers-reduced-motion: reduce) { #detail.stage-detail .stage-film-play { transition: none; } }
