/* Native document first. Enhancement only changes presentation, never authors content. */
.storybook .site-header{position:relative}
.home-page.storybook{--header-h:56px}
.home-page.storybook .header-inner{min-height:56px;padding-block:0}
.home-page.storybook .brand img{width:160px;max-height:42px;object-fit:contain}
.home-page.storybook .nav-links a{font-size:12px;font-weight:500;color:#536258}
.home-page.storybook .nav-links a:hover,.home-page.storybook .nav-links a.is-current{color:#286044}
.home-page.storybook .nav-links{gap:18px}
.story-page{position:relative;background:#fff8ed;padding:0 6% 48px;scroll-margin-top:80px}
.story-scene{position:relative;margin:0 -6.82% 32px;height:55vh;min-height:280px;overflow:hidden;background:#cad9ba}
.scene-camera{width:100%;height:100%;object-fit:cover;display:block}
.scene-light{display:none}
.scene-layer,.story-demo{max-width:650px;margin:24px auto}
.storybook .story-headline{font-size:clamp(32px,4.3vw,66px);line-height:1.08;letter-spacing:-.035em}
.story-narration{font-size:clamp(17px,1.65vw,23px);line-height:1.55}
.story-detail{font-size:14px;line-height:1.5}
.story-actions{display:flex;gap:12px;flex-wrap:wrap}
.scene-character{display:block;width:160px;height:280px;object-fit:contain}
.scene-message{font:italic 26px/1.3 Georgia,serif}
.reading-contents{display:flex;flex-wrap:wrap;justify-content:center;gap:24px;padding:24px;background:#fff8ed}
.story-controls[hidden],.page-corner[hidden]{display:none}
.story-controls{display:flex;gap:18px;align-items:center;justify-content:center;padding:10px;z-index:20}
.story-controls button{font:inherit;font-size:12px;color:inherit;border:0;border-bottom:1px solid currentColor;background:none;cursor:pointer;padding:8px 3px;min-height:44px}
.story-controls button:disabled{opacity:.35;cursor:default}
.story-cue{font-size:11px;letter-spacing:.06em;pointer-events:none}
.story-reading .story-controls{position:sticky;bottom:0;color:#344c3b;background:#fff8ed}
.story-reading [data-previous],.story-reading .story-cue{display:none}
html.story-active{overflow:hidden;scroll-behavior:auto}
.story-active body{height:100dvh;overflow:hidden}
.story-active .site-header{position:absolute;inset:0 0 auto;height:56px;background:linear-gradient(#f8f7edee,#f8f7edc9);z-index:30}
.story-active #main{position:relative;height:100dvh;overflow:hidden}
.story-active .story-page{position:absolute;inset:0;padding:0;height:100%;overflow:hidden;visibility:hidden;isolation:isolate;background:#c1d4ba}
.story-active .story-page.is-active,.story-active .story-page.is-turning{visibility:visible}
.story-active .story-scene{position:absolute;inset:0;margin:0;height:100%;min-height:0;z-index:0}
.story-active .scene-camera{position:absolute;inset:0;object-position:var(--scene-focus,50% 50%);transform-origin:var(--scene-focus,50% 50%)}
.story-active .scene-light{display:block;position:absolute;inset:0;z-index:1;background:var(--scene-shade,linear-gradient(90deg,#102617e8,transparent 85%));pointer-events:none}
.story-active .scene-layer,.story-active .story-demo{position:absolute;z-index:2;margin:0}
.story-active .scene-layer:not(.story-dialogue):not(.scene-character){color:#fffbed;text-shadow:0 2px 12px #142018b0}
.story-active .scene-layer a:not(.btn){color:inherit}
.story-active .eyebrow{left:7%;top:20%;font-size:12px;letter-spacing:.16em}
.story-active .story-headline{max-width:650px}
.story-active .story-narration{max-width:520px}
.story-active .story-detail{max-width:510px}
.story-active .story-actions{text-shadow:none!important}
.story-active .site-footer,.story-active .reading-contents{display:none}
.story-active .story-controls{position:fixed;bottom:max(12px,env(safe-area-inset-bottom));left:28px;right:130px;justify-content:flex-start;color:#fff9e8;text-shadow:0 1px 5px #000;background:none;padding:0}
.story-active .story-controls:before{content:"";position:fixed;inset:auto 0 0;height:100px;z-index:-1;pointer-events:none;background:linear-gradient(transparent,#13251a99)}
.story-active .story-controls [data-reading]{margin-left:auto}
.page-corner{position:fixed;right:0;bottom:0;width:108px;height:94px;z-index:25;border:0;background:none;cursor:grab;touch-action:none;color:#584322}
.page-corner span{position:absolute;bottom:14px;right:4px;font-size:10px;transform:rotate(-40deg)}
@media(max-width:800px){
 .storybook .header-inner{width:92%}
 .story-active .site-header{height:52px}
 .home-page.storybook{--header-h:52px}
 .home-page.storybook .header-inner{min-height:52px}
 .home-page.storybook .brand img{width:145px;max-height:38px}
 .story-active .story-headline{font-size:clamp(28px,7.5vw,42px);max-width:88%}
 .story-active .story-narration{font-size:16px;line-height:1.5;max-width:88%}
 .story-active .story-detail{font-size:12px;max-width:88%}
 .story-active .scene-message{font-size:24px;max-width:85%}
 .story-active .eyebrow{top:18%;left:6%;font-size:10px}
 .story-active .story-controls{left:14px;right:84px;gap:10px;bottom:max(10px,env(safe-area-inset-bottom))}
 .story-controls button{font-size:10px}.story-cue{font-size:9px;max-width:90px}
 .page-corner{width:76px;height:72px}.page-corner span{font-size:8px;bottom:11px}
 .storybook .story-actions .btn{min-height:44px;font-size:14px;padding:12px 17px}
}
@media print{
 html.story-active,.story-active body{height:auto;overflow:visible}
 .site-header,.story-controls,.page-corner,.reading-contents{display:none!important}
 .story-active #main{height:auto;overflow:visible}
 .story-active .story-page{position:relative;height:auto;visibility:visible;padding:24px;background:#fff;break-inside:avoid}
 .story-active .story-scene{position:relative;height:260px}
 .story-active .scene-layer,.story-active .story-demo{position:static;max-width:none;margin:16px 0;opacity:1!important;visibility:visible!important;transform:none!important;color:#24312c!important;text-shadow:none!important}
 .story-active .scene-light,.story-active .scene-character{display:none}
}

.page-corner:before{content:"";position:absolute;inset:0;background:linear-gradient(135deg,transparent 48%,#b6a17e 50%,#fffcf0 54%,#ead9b6);clip-path:polygon(100% 0,100% 100%,0 100%);pointer-events:none}
