.auto-story{position:relative;display:grid;grid-template-rows:auto minmax(260px,1fr) auto auto 3px;height:calc(100svh - 100px);min-height:640px;max-height:1040px;background:#10272f;color:#fff;margin:15px 0 30px;overflow:hidden}.story-chapters{display:flex;gap:0;background:#132a33}.story-chapters button{flex:1;border:0;border-bottom:3px solid transparent;background:transparent;color:#c4d5d7;padding:13px 16px;font:inherit;font-size:13px;cursor:pointer}.story-chapters button[aria-pressed=true]{color:#ffdb39;border-color:#ffdb39}.story-stage{position:relative;min-height:0;overflow:hidden;background:#10272f;isolation:isolate}#story-backdrop{position:absolute;inset:-25px;z-index:-1;background-size:cover;background-position:center;filter:blur(24px) brightness(.3)}#story-image,#story-video{display:block;object-fit:contain;width:100%;height:100%;margin:0}#story-image[hidden],#story-video[hidden]{display:none}#story-image{animation:photo-enter 1.8s ease-out}.story-era{position:absolute;top:14px;left:14px;padding:5px 10px;background:#10272fc9;font-size:11px;letter-spacing:.04em}.story-caption{padding:18px 30px 14px;min-height:185px;background:#10272f;overflow:hidden}.story-label{color:#a6c7c9;font-size:10px;letter-spacing:.12em;margin:0 0 6px}.story-caption h2{font-size:clamp(20px,2.5vw,29px);margin:0 0 9px;line-height:1.5;color:#ffdb39}.story-caption #story-copy{margin:0;max-width:850px;font-size:clamp(13px,1.5vw,16px);line-height:2;white-space:pre-line;animation:telop-flow 24s linear both}.story-caption.is-paused #story-copy{animation-play-state:paused}.story-toolbar{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:10px 20px;background:#172f37;font-size:11px;flex-wrap:wrap}.story-buttons{display:flex;gap:8px}.story-buttons button{font:inherit;color:#fff;border:1px solid #67848a;background:transparent;padding:7px 11px;cursor:pointer;border-radius:2px;min-height:36px}.story-toolbar a{color:#fff;text-underline-offset:4px}.story-track{height:3px;background:#41585d}#story-progress{height:100%;background:#ffdb39;width:0;transition:width .15s linear}.story-status{position:absolute;top:80px;left:20px;right:20px;pointer-events:none;font-size:12px;background:#10272fdb;margin:0}.story-status:empty{display:none}.thanks{padding:25px;background:#e7eded;border-left:3px solid #007785;margin:30px 0}.thanks p{margin:0}.reflection{border-block:1px solid #c8d2ce;margin-top:30px;padding-bottom:35px}.gratitude h2{color:#006c77}@keyframes telop-flow{0%{opacity:0;transform:translateY(16px)}12%{opacity:1}88%{opacity:1}100%{opacity:.7;transform:translateY(-8px)}}@keyframes photo-enter{from{opacity:.4}to{opacity:1}}@media(max-width:700px){.auto-story{margin:10px -22px 25px;height:calc(100svh - 75px);min-height:650px;max-height:1000px;grid-template-rows:auto minmax(240px,1fr) auto auto 3px}.story-caption{padding:17px 22px 12px;min-height:200px}.story-caption h2{font-size:23px}.story-caption #story-copy{font-size:14px;line-height:1.9}.story-toolbar{padding:10px 12px;gap:8px}.story-buttons{gap:5px}.story-buttons button{padding:7px 9px}.story-era{font-size:10px}}@media(prefers-reduced-motion:reduce){#story-image,.story-caption #story-copy{animation:none}}

/* Immersive presentation: each scene fills the viewport. */
.auto-story{width:100vw;margin-left:calc(50% - 50vw);margin-right:calc(50% - 50vw);height:100svh;min-height:480px;max-height:none;display:block;position:relative;background:#07151c;scroll-margin-top:0}
.story-stage{position:absolute;inset:0;height:100%;width:100%}#story-image,#story-video{object-fit:cover;object-position:center 42%;width:100%;height:100%}
.story-chapters{position:absolute;top:0;left:0;right:0;z-index:4;background:linear-gradient(#07151ce8,#07151c70);padding-top:env(safe-area-inset-top,0px)}
.story-chapters button{font-size:13px;padding:13px}.story-era{top:68px;left:clamp(20px,5vw,80px);background:#07151c99}
.story-caption{position:absolute;bottom:62px;left:0;right:0;min-height:0;padding:70px max(24px,calc((100vw - 1100px)/2)) 22px;background:linear-gradient(transparent,#07151cbd 32%,#07151ce8);z-index:2;pointer-events:none}.story-label{font-size:11px;color:#c7dedf}.story-caption h2{font-size:clamp(25px,3.2vw,43px);text-shadow:0 2px 5px #0008;margin-bottom:9px}.story-caption #story-copy{font-size:clamp(15px,1.7vw,20px);max-width:1000px;line-height:1.9;text-shadow:0 1px 5px #000;animation:telop-flow 16s linear both}
.story-toolbar{position:absolute;bottom:3px;left:0;right:0;min-height:59px;padding:9px max(20px,calc((100vw - 1100px)/2));z-index:3;background:#07151ce8}.story-track{position:absolute;bottom:0;left:0;right:0;z-index:4}.story-status{top:110px;z-index:5}.story-buttons button{border-color:#c1d8dd88;background:#07151c66}
@keyframes telop-flow{0%{opacity:0;transform:translateY(12px)}8%{opacity:1}94%{opacity:1}100%{opacity:.85;transform:translateY(-5px)}}
@media(max-width:700px){.auto-story{height:100svh;min-height:580px;max-height:none;margin-top:0;margin-bottom:30px}.story-caption{bottom:75px;padding:65px 22px 20px}.story-caption h2{font-size:26px}.story-caption #story-copy{font-size:15px;line-height:1.8}.story-toolbar{padding:10px 12px;min-height:72px;gap:6px}.story-chapters button{font-size:12px;padding:12px 8px}.story-era{top:64px;left:16px}.story-buttons button{min-height:36px;font-size:11px;padding:7px 9px}.story-caption .story-label{font-size:10px}}@media(prefers-reduced-motion:reduce){.story-caption #story-copy{animation:none}}

.auto-story{width:var(--story-screen-width,100vw);margin-left:calc((100% - var(--story-screen-width,100vw))/2);margin-right:0}body{overflow-x:hidden}

.voice-note{font-size:13px;color:#52646a;line-height:1.9}.narration-transcript{max-width:740px;margin:35px auto;padding:20px;border-block:1px solid #cad5cf}.narration-transcript summary{font-weight:700;cursor:pointer}.narration-transcript p{font-size:15px;line-height:2.1;margin:20px 0}#story-sound{border-color:#ffdb39;color:#ffdb39}
/* Keep the outgoing picture visible until the next one is ready. */
.story-media-layer{position:absolute;inset:0;z-index:1;opacity:0;transition:opacity .85s ease-in-out;overflow:hidden;pointer-events:none}.story-media-layer.is-active{opacity:1;z-index:2}.story-scene-media{display:block;width:100%;height:100%;object-fit:cover;object-position:center 42%;transform:scale(1.01);will-change:transform}.story-media-layer.is-active .story-scene-media{animation:story-drift var(--scene-seconds,15s) linear both}.is-paused .story-scene-media{animation-play-state:paused!important}.story-era{z-index:5}.story-caption #story-copy{animation:none!important;opacity:1;transform:none}.scene-caption-enter{animation:story-caption-enter .65s ease-out both}.is-paused .scene-caption-enter{animation-play-state:paused}.story-caption{min-height:0}@keyframes story-drift{from{transform:scale(1.01)}to{transform:scale(1.055)}}@keyframes story-caption-enter{from{opacity:.2;transform:translateY(7px)}to{opacity:1;transform:translateY(0)}}@media(prefers-reduced-motion:reduce){.story-media-layer{transition:none}.story-media-layer.is-active .story-scene-media,.scene-caption-enter{animation:none}}

.story-media-layer.is-leaving{opacity:1;z-index:1;transition:none}

/* Narration-led edit: brief captions follow the single speech timeline. */
.story-media-layer{transition:opacity .45s ease-in-out}.scene-caption-enter{animation:story-caption-enter .28s ease-out both}.story-caption h2{font-size:clamp(19px,2.1vw,28px);margin-bottom:8px;color:#d3dedf}.story-caption #story-copy{font-size:clamp(20px,2.8vw,34px);font-weight:650;line-height:1.65;max-width:1100px}.story-caption{padding-top:80px}.story-label{font-size:11px}@media(max-width:700px){.story-caption h2{font-size:17px}.story-caption #story-copy{font-size:21px;line-height:1.6}.story-caption{bottom:75px;padding-bottom:18px}}
/* Caption timing belongs to the continuous narration, independently of images. */
.story-caption.scene-caption-enter{animation:none}
#story-copy{min-height:3.2em;white-space:pre-line}
/* Compact, text-free playback controls. */
.story-buttons button{width:40px;height:40px;min-height:40px;padding:8px;display:inline-flex;align-items:center;justify-content:center;border:0;border-radius:50%;background:#07151c55}
.story-buttons button svg{display:block;width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
#story-toggle .icon-play,#story-toggle.is-stopped .icon-pause{display:none}
#story-toggle.is-stopped .icon-play{display:block}
#story-sound[aria-pressed=false] .icon-volume,#story-sound[aria-pressed=true] .icon-mute{display:none}
.story-buttons button:focus-visible{outline:2px solid #ffdb39;outline-offset:3px}
