/* The chapter illustration belongs to the menu; each puzzle is its own page. */
.story-pages{display:block;min-height:calc(100svh - 145px)}
.chapter-menu{display:grid;grid-template-columns:minmax(0,1.08fr) minmax(350px,1fr);align-items:start}
.chapter-menu[hidden],#puzzlePanel[hidden],#continueChapter[hidden]{display:none}
.chapter-menu>.world{position:sticky;top:0;height:calc(100svh - 80px);min-height:620px;max-height:1050px}
.chapter-select{min-width:0;padding:38px clamp(24px,4.5vw,64px) 42px;background:radial-gradient(ellipse at 40% 15%,#23443c88,#0c2329 80%)}
.chapter-menu-heading h2{font:35px/1.15 Georgia,serif;letter-spacing:-.6px;margin:12px 0 24px;color:var(--paper)}
.chapter-select .chapter-choices{margin-bottom:24px}
.chapter-select .dialog-intro{margin-bottom:18px}
.chapter-select .book-progress{margin:22px 0 25px}
.stage-select-title{margin:0 0 13px}
.chapter-select .page-list{gap:9px}
.chapter-select .page-entry{min-height:72px}
.chapter-select.glasswater-book{background:radial-gradient(ellipse at 35% 15%,#24495d,#102139 85%)}
.playing-page .story-pages{background:radial-gradient(ellipse at 50% 30%,#193a35,#091d24 78%)}
.glasswater.playing-page .story-pages{background:radial-gradient(ellipse at 50% 30%,#214559,#0e1e32 78%)}
.story-pages>#puzzlePanel{width:100%;max-width:560px;min-height:calc(100svh - 145px);margin:0 auto;padding:32px 38px 25px;justify-content:flex-start;border-inline:1px solid #b7bd8410}
#puzzleTitle:focus,#bookTitle:focus{outline:none}
.turn-back{isolation:isolate;background:#102d30;color:#f2e7c9;padding:28px}
.turn-back>img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;z-index:-2;filter:brightness(.5)}
.turn-back:after{content:'';position:absolute;inset:0;z-index:-1;background:linear-gradient(#08212d44,#071c25e6)}
.turn-back>span{font:9px/1.8 Arial,sans-serif;letter-spacing:2.5px;color:#e7d29e}
.turn-back>i{font-size:65px;color:#e7d29e;margin:12px 0}
.turn-back>p{font:30px/1.2 Georgia,serif;max-width:330px;margin:0 0 16px}
.turn-back>small{font:italic 13px/1.6 Georgia,serif;color:#b7c8bd}
.turn-front .chapter-menu>.world{position:relative;top:auto}
@media(max-width:760px){
 .chapter-menu{display:block}
 .chapter-menu>.world{position:relative;height:245px;min-height:0;max-height:none}
 .chapter-select{padding:26px 6% 32px}
 .chapter-menu-heading h2{font-size:30px;margin:10px 0 20px}
 .chapter-select .chapter-choice{min-height:115px}
 .chapter-select .chapter-choice strong{font-size:18px}
 .chapter-select .book-progress{margin:20px 0}
 .story-pages>#puzzlePanel{min-height:calc(100svh - 110px);max-width:510px;padding:22px 6% 20px;border:0}
 .large-board .story-pages>#puzzlePanel{padding-left:14px;padding-right:14px}
 .playing-page .story-pages{min-height:calc(100svh - 110px)}
}
@media(max-width:380px){
 .chapter-menu>.world{height:225px}
 .chapter-menu-heading h2{font-size:28px}
 .chapter-select .chapter-choice strong{font-size:17px}
 .chapter-select .chapter-choice{padding:12px 9px}
}
