.storybook{box-sizing:border-box;width:min(720px,calc(100vw - 20px));height:min(900px,calc(100dvh - 24px));max-width:100%;max-height:calc(100dvh - 24px);padding:12px;border:0;border-radius:16px;background:#694250;color:#342b32;box-shadow:0 24px 80px #0008;font-family:Georgia,serif;overflow:hidden}
.storybook[open]{display:flex;flex-direction:column;gap:8px}.storybook::backdrop{background:#171326b8;backdrop-filter:blur(4px)}
.storybook header,.storybook nav{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-shrink:0;color:#fff4df}.book-title{font-size:15px;padding-left:8px}.storybook button{min-width:48px;min-height:48px;border:0;border-radius:12px;background:#fff5df;color:#4e3041;font:24px Georgia,serif;cursor:pointer}.storybook button:disabled{opacity:.35;cursor:default}.storybook button:focus-visible{outline:3px solid #e7bd60;outline-offset:2px}
.book-leaf{position:relative;flex:1;min-height:0;overflow-y:auto;overscroll-behavior:contain;touch-action:pan-y;padding:clamp(18px,5vw,44px);border-radius:3px 10px 10px 3px;background:linear-gradient(90deg,#d6c4a3 0,#f2e6ce 3%,#fff8e8 12%,#fffaf0 90%,#eee0c6);box-shadow:3px 3px 0 #dfd1b8,6px 6px 0 #cbbd9f;transform-origin:left center}
.book-leaf h2{font-size:clamp(24px,5.5vw,36px);font-weight:normal;line-height:1.18;margin:0 0 18px}.book-leaf p{font-size:clamp(20px,4.8vw,25px);line-height:1.55;margin:16px 0}.book-leaf img{width:100%;max-height:230px;object-fit:contain;border-radius:8px}.book-leaf .book-note{font-size:17px;color:#796d61;font-style:italic}.book-cover{display:flex;flex-direction:column;justify-content:center;text-align:center}.book-cover h2{font-size:clamp(32px,8vw,52px)}.book-emblem{font-size:90px;color:#aa7e37}.book-blank{background:repeating-linear-gradient(0deg,transparent 0 34px,#a9916b16 35px 36px),#fff8e8}.book-blank p{margin-top:40%;text-align:center}.book-count{font-size:16px}.book-leaf .sw.on{background:#ffe18a;border-radius:4px}.book-leaf .speak.on{background:#ffe18a}.book-leaf .speak{position:sticky;bottom:0;float:right;box-shadow:0 2px 10px #55332230}
@media(prefers-reduced-motion:reduce){.book-leaf{animation:none!important;transition:none!important}}
.storybook button{width:auto;display:inline-block;margin:0}.storybook .book-close{flex:0 0 48px}.storybook .book-count{white-space:nowrap}.storybook .book-next,.storybook .book-prev{min-width:64px}

.storybook .book-archive{flex-wrap:wrap;gap:8px}.storybook .book-archive button{flex:1 1 130px;min-width:0;max-width:100%;padding:8px;font-size:17px;line-height:1.25;overflow-wrap:anywhere}
