@font-face{font-family:ShrineGungseo;src:url('assets/fonts/gungseo.woff') format('woff');font-display:swap}@font-face{font-family:ShrineSans;src:url('assets/fonts/sans.woff');font-display:swap}@font-face{font-family:ShrineSans;src:url('assets/fonts/sans-bold.woff');font-weight:700;font-display:swap}
:root{--ink:#211b20;--paper:#f5eddf;--gold:#cfb483;--red:#a53e39;--muted:#b6a6a0;--serif:ShrineGungseo,Gungsuh,'궁서',serif;--sans:ShrineSans,sans-serif}*{box-sizing:border-box}html,body{margin:0;min-height:100%;color:var(--paper);background:var(--ink);font-family:var(--sans)}body{cursor:url('assets/ui/cursor.png') 3 2,auto}button,select,input{font:inherit}button{color:inherit;background:none;border:0;cursor:url('assets/ui/cursor-active.png') 3 2,pointer;touch-action:manipulation}button:disabled{cursor:default;opacity:.4}button,input,select{-webkit-tap-highlight-color:transparent}button:focus-visible,input:focus-visible,select:focus-visible{outline:2px solid #edc994;outline-offset:4px}button:not(:disabled){transition:background-color .18s,color .18s,box-shadow .18s,filter .18s,transform .16s}button:hover:not(:disabled){color:#ffe1a5}button:active:not(:disabled){transform:translateY(1px);filter:brightness(1.15)}button.clicked{animation:button-glow .35s ease-out}@keyframes button-glow{25%{box-shadow:0 0 0 2px #e6bd7c88,0 0 22px #d4a36e55}}[hidden]{display:none!important}.novel{position:relative;isolation:isolate;display:grid;grid-template-rows:auto minmax(420px,1fr) auto auto;gap:0;min-height:740px;height:100svh;padding:30px 5% 22px;overflow:hidden}.scenery,.scene-shade,.frame{position:absolute;inset:0;pointer-events:none}.scenery{z-index:-4;background:url('assets/backgrounds/shrine.webp') center 52%/cover;transform:scale(1.015);transition:background-image .5s}.scene-shade{z-index:-3;background:linear-gradient(90deg,#201b22f5 0%,#30202acc 30%,#35212c55 63%,#1d14252b),linear-gradient(0deg,#201820dc,transparent 55%,#24182280)}.frame{inset:13px;border:1px solid #c6a67188;z-index:15;box-shadow:inset 0 0 0 4px #291e2655}.frame i{position:absolute;width:22px;height:22px;border-style:solid;border-color:#d5b782}.frame i:nth-child(1){top:-2px;left:-2px;border-width:3px 0 0 3px}.frame i:nth-child(2){top:-2px;right:-2px;border-width:3px 3px 0 0}.frame i:nth-child(3){bottom:-2px;left:-2px;border-width:0 0 3px 3px}.frame i:nth-child(4){bottom:-2px;right:-2px;border-width:0 3px 3px 0}.topbar{z-index:20;position:relative;display:flex;align-items:center;gap:30px;min-height:44px;padding-bottom:15px;border-bottom:1px solid #cdb38438}.brand{display:flex;align-items:center;gap:10px;text-align:left;margin-right:auto;padding:0;white-space:nowrap}.brand img{width:31px;height:31px;filter:sepia(1) saturate(.65) brightness(1.5)}.brand>span{font:19px var(--serif);letter-spacing:.08em}.brand small{display:block;font:9px var(--sans);color:#ddbd93;letter-spacing:.19em;margin-top:4px}.topbar nav{display:flex;gap:24px;align-items:center}.topbar nav button{font:16px var(--serif);padding:8px 0;border-bottom:1px solid transparent;white-space:nowrap}.topbar nav button[aria-current=page]{border-color:#d2ac75;color:#f9cd97}.sound{position:relative;display:flex;align-items:center;gap:8px}.sound>button{font:10px var(--sans);letter-spacing:.03em;padding:8px 9px;border:1px solid #bda07770;white-space:nowrap}.sound-icon{font-size:14px;margin-right:6px}.sound #sfx-toggle{font-size:9px;border-color:#ad938559}.volume{position:absolute;right:0;top:100%;width:180px;background:#2a1d27f7;border:1px solid #b6a07399;padding:13px;font-size:10px;visibility:hidden;opacity:0;transition:opacity .15s}.volume input{width:100%;display:block;margin-top:10px;accent-color:#b86550}.sound:has(#sound-toggle:focus-visible) .volume,.volume:focus-within{visibility:visible;opacity:1}@media(hover:hover){.sound:has(#sound-toggle:hover) .volume,.volume:hover{visibility:visible;opacity:1}}.stage{position:relative;isolation:isolate;container-type:size;min-height:0;overflow:hidden;margin-bottom:20px}.actor{position:absolute;inset:0;margin:0;pointer-events:none;z-index:-1;overflow:hidden}.actor img{position:absolute;max-width:none;height:auto;filter:drop-shadow(-7px 7px 17px #21102042);will-change:transform,opacity}@keyframes actor-in{from{opacity:.2;transform:translateX(7px)}to{opacity:1;transform:none}}.scene-panel{position:absolute;left:2.5%;top:5%;width:48%;max-height:92%;overflow-y:auto;scrollbar-width:thin;scrollbar-color:#a78661 transparent;padding:10px 5px 16px 0}.eyebrow{display:flex;align-items:center;gap:10px;font-size:10px;letter-spacing:.17em;color:#e2bd8d;margin-bottom:17px}.eyebrow>span{width:25px;height:1px;background:#d1b081}h1,h2,p{margin:0}h1{font:clamp(31px,8.4cqh,57px)/1.25 var(--serif);letter-spacing:-.055em;text-shadow:0 3px 18px #1c1223}h1>span{display:block}h1 em{font-style:normal;color:#f7c7b2}h1 b{font-weight:400;color:#f5d49d}h1 .title-small{font-size:.5em;letter-spacing:.05em;margin:5px 0}.title-punct{font-size:.72em;color:#ed8970;letter-spacing:-.12em;margin-left:.08em}.title-panel{top:8%;max-height:92%;overflow-y:auto}.title-rule{display:flex;align-items:center;gap:14px;width:80%;margin:18px 0 22px;font-size:9px;color:#d9ba8b;letter-spacing:.23em}.title-rule i{flex:1;background:linear-gradient(90deg,#c8a879a6,transparent);height:1px}.title-rule>span:last-child{font:14px var(--serif)}.begin{display:inline-flex;justify-content:space-between;align-items:center;gap:30px;padding:13px 19px;min-width:220px;background:#9e3e36;border:1px solid #d5af7b;font:19px var(--serif);box-shadow:4px 4px #20141d88}.begin:hover{background:#b04b3e;box-shadow:4px 4px #20141d88,0 0 22px #d2a67b25}.scene-panel h2{font:clamp(29px,7cqh,45px)/1.5 var(--serif);letter-spacing:-.04em;white-space:pre-line}.choice-panel{top:13%;width:45%}.choices{display:grid;gap:12px;margin-top:24px}.choices button{display:grid;grid-template-columns:32px 1fr 20px;gap:12px;align-items:center;padding:15px 18px;text-align:left;border:1px solid #c6a67a8a;background:#2e202aea;font:20px/1.35 var(--serif)}.choices button:hover{background:#5a302deb;transform:translateX(4px)}.choices small{font:10px var(--sans);color:#d0ae7c;border-right:1px solid #aa8d6855}.choices button>span{color:#d3ad7d}.story-panel{top:15%;width:43%}.story-divider{width:42px;height:1px;background:#c7a97b;margin:20px 0}.story-panel p,.intro-panel p{font:15px/1.85 var(--sans);white-space:pre-line;color:#eadfcf;max-width:95%;text-wrap:pretty}.story-chapters{display:flex;gap:10px;margin-top:23px}.story-chapters button{width:35px;height:35px;font-size:12px;border:1px solid #bb9e7377;background:#291e25cc}.story-chapters button[aria-pressed=true]{background:#9e4139;border-color:#e0c08f;color:#fff1cf}.cast-panel{top:0;left:0;width:57%;height:100%;max-height:100%;padding:15px 14px 8px 0;display:grid;grid-template-rows:auto auto minmax(0,1fr) auto;overflow:hidden}.cast-groups{display:flex;gap:25px;align-items:center;margin-bottom:8px}.cast-groups button{font:19px var(--serif);padding:5px 0;border-bottom:1px solid transparent;color:#d6c8b7}.cast-groups button[aria-pressed=true]{color:#f7cb94;border-color:#c5a572}.name-rail{display:flex;flex-wrap:wrap;gap:6px;margin-bottom:12px}.name-rail button{padding:7px 11px;background:#31232bd9;border:1px solid #a68b6266;font:15px/1.2 var(--serif);white-space:nowrap}.name-rail button[aria-pressed=true]{background:#9a3d37;border-color:#d5b480;color:#fff0d4}.card-wrap{min-height:0;position:relative;display:flex;align-items:center;justify-content:flex-start}.card-wrap>img{display:block;width:100%;height:100%;object-fit:contain;object-position:left center;filter:drop-shadow(0 8px 14px #1d111b66)}#card-status{position:absolute;top:12px;left:12px;background:#32212cea;padding:7px 11px;font-size:11px;border:1px solid #c4a576}.card-tools{display:flex;justify-content:space-between;align-items:center;gap:15px;margin-top:10px;min-height:31px}.outfits{display:flex;gap:6px}.outfits button{padding:6px 14px;font:16px var(--serif);border:1px solid #b99c7077;background:#2d202bcc}.outfits button[aria-pressed=true]{color:#f6ca8c;border-color:#dbc295}.card-tools label{display:flex;align-items:center;gap:10px;margin-left:auto;font-size:11px;color:#e0cba4}.card-tools select{background:#30212b;color:#efdcba;border:1px solid #bba07399;padding:6px 9px;font-size:11px}.places-panel{top:6%;width:48%;height:88%;display:flex;flex-direction:column;overflow:hidden}.place-photo{position:relative;min-height:0;flex:1;border:1px solid #c3a572;padding:5px;background:#2d2228}.place-photo img{width:100%;height:100%;display:block;object-fit:cover}.place-photo:after{content:'';position:absolute;inset:5px;background:linear-gradient(0deg,#281c29e0,transparent 75%);pointer-events:none}.place-photo h2{position:absolute;left:25px;bottom:20px;z-index:1;font-size:30px}.place-tabs{display:flex;gap:7px;margin-top:12px;flex-wrap:wrap}.place-tabs button{flex:1;white-space:nowrap;font:15px var(--serif);padding:10px 7px;border:1px solid #b59a7377;background:#31212bdc}.place-tabs button[aria-pressed=true]{background:#953f37;border-color:#d4b37f}.intro-panel{top:12%;width:42%}.intro-panel h2{font-size:clamp(32px,8.3cqh,53px);line-height:1.35}.intro-panel p{margin:20px 0 25px}.chapter-links{display:flex;gap:9px;margin-top:16px}.chapter-links button{padding:8px;font-size:11px;color:#e3c594;border-bottom:1px solid #b89c6c88}.dialogue{position:relative;z-index:10;min-height:172px;color:#352a2a;border:1px solid #c8a675;background:linear-gradient(115deg,#f7f0e4fc,#f0e3d3f7);box-shadow:0 10px 35px #1e132466,inset 0 0 0 5px #dfc6a44d;display:grid;grid-template-rows:minmax(108px,auto) auto;padding:18px 27px 9px;margin-top:0}.dialogue:after{content:'';position:absolute;inset:7px;border:1px solid #b79c7455;pointer-events:none}.nameplate{position:absolute;left:22px;top:-20px;background:#3c2530;border:1px solid #d4b282;box-shadow:3px 3px #1e152244;display:flex;align-items:center;gap:12px;padding:10px 18px;color:#fff0ce;z-index:1}.nameplate strong{font:23px var(--serif);letter-spacing:.13em}.nameplate small{font-size:9px;color:#d6b98e;border-left:1px solid #bda27666;padding-left:12px}.name-mark{font-size:12px;color:#d8b77e}.dialogue-body{position:relative;display:block;align-self:stretch;text-align:left;width:100%;padding:17px 18px 14px 9px;font:23px/1.65 var(--serif);color:#352a2a!important;word-break:keep-all;overflow-wrap:anywhere}.dialogue-body:disabled{opacity:1;color:#352a2a;cursor:url('assets/ui/cursor.png') 3 2,auto}.next-mark{position:absolute;right:3px;bottom:16px;color:#b25541;font-size:8px;animation:pulse 1.6s infinite}@keyframes pulse{50%{opacity:.25;transform:translateY(3px)}}.dialogue-footer{position:relative;border-top:1px solid #aa89694d;min-height:35px;display:flex;justify-content:space-between;align-items:center;gap:12px;padding-top:6px;font:11px var(--sans);color:#7e6756}.dialogue-status{display:flex;align-items:center;gap:10px;min-width:0;flex-wrap:wrap}#line-progress{font-variant-numeric:tabular-nums;color:#9e4b3a;white-space:nowrap}.dialogue-footer>div{display:flex;gap:17px;align-items:center;flex-wrap:wrap;justify-content:flex-end}.dialogue-footer button{padding:5px 0;white-space:nowrap;font-size:11px}.dialogue-footer button:hover:not(:disabled){color:#a13c2c}.dialogue-footer button[aria-pressed=true]{color:#a64334}#next-dialogue{color:#8d3a30}.bottom-note{position:relative;display:flex;justify-content:space-between;align-items:center;padding-top:9px;min-height:21px;font-size:9px;letter-spacing:.08em;color:#c6b7a58c}.atmosphere{position:absolute;inset:0;overflow:hidden;pointer-events:none;z-index:0}.atmosphere span{position:absolute;color:#e3b57a;font-size:9px;opacity:.3;animation:drift 13s ease-in-out infinite}.atmosphere span:nth-child(1){top:25%;left:51%}.atmosphere span:nth-child(2){top:65%;left:88%;animation-delay:-5s}.atmosphere span:nth-child(3){top:55%;left:10%;font-size:6px;animation-delay:-8s}.atmosphere span:nth-child(4){top:15%;left:82%;font-size:7px;animation-delay:-2s}@keyframes drift{50%{transform:translate(10px,-25px);opacity:.5}}.reader,.log{padding:0;border:1px solid #bb996d;background:#281d27;color:#efdfc3;box-shadow:0 20px 100px #0f091ddd}.reader::backdrop,.log::backdrop{background:#1d1421ed;backdrop-filter:blur(6px)}.reader{width:min(920px,96vw);max-width:96vw;height:96svh;max-height:96svh;overflow:hidden}.reader-header{height:80px;display:flex;align-items:center;gap:20px;padding:15px 23px;border-bottom:1px solid #b99a6e66}.reader-header small{font-size:9px;color:#c1a480;letter-spacing:.14em}.reader-header h2{font:23px var(--serif);margin-top:4px}.reader-header>span{margin-left:auto;font-size:11px;color:#ceb080}.reader-header>button,.log header>button{font-size:12px;padding:8px 12px;border:1px solid #b69b7377}.reader-scroll{height:calc(100% - 80px);overflow:auto;background:white;overscroll-behavior:contain;scrollbar-color:#a38868 #e9e2d8}.reader-scroll>img{width:100%;max-width:800px;display:block;margin:auto;min-height:100px}.reader-end{display:flex;justify-content:center;align-items:center;gap:35px;background:#2a1e29;padding:25px}.reader-end button{padding:10px 22px;border:1px solid #b69b7377}.reader-end>span{font-size:11px}.log{width:min(680px,92vw);max-height:82svh}.log header{padding:20px 24px;display:flex;justify-content:space-between;align-items:center;border-bottom:1px solid #b69b7377}.log h2{font:22px var(--serif)}#log-content{padding:15px 26px 26px;max-height:calc(82svh - 80px);overflow:auto}#log-content p{font:20px/1.7 var(--serif);padding:14px 0;border-bottom:1px solid #ac906655;word-break:keep-all}#log-content small{display:block;font:10px var(--sans);color:#c6a97c;margin-bottom:5px}.sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}.noscript{position:fixed;inset:40%;padding:30px;background:#30202a;color:white;z-index:99}.click-ring{position:fixed;pointer-events:none;z-index:1000;width:18px;height:18px;border:1px solid #e8bd7e;border-radius:50%;transform:translate(-50%,-50%);animation:ring .38s ease-out forwards}@keyframes ring{to{width:44px;height:44px;opacity:0}}
@media(min-width:1600px){.novel{padding-left:7%;padding-right:7%}.dialogue{min-height:195px}.dialogue-body{font-size:26px}.title-panel{top:12%}h1{font-size:clamp(42px,8cqh,65px)}}
@media(max-width:1100px) and (min-width:701px){.novel{padding-left:4%;padding-right:4%}.topbar{gap:17px}.topbar nav{gap:16px}.topbar nav button{font-size:14px}.brand>span{font-size:17px}.sound{gap:5px}.sound>button{font-size:9px;padding:7px}.sound #sfx-toggle{font-size:8px}.scene-panel{width:48%}.cast-panel{width:58%}.name-rail button{padding:6px 9px;font-size:14px}.choices button{font-size:18px}.dialogue-footer>div{gap:12px}}
@media(max-height:800px) and (min-width:701px){.novel{min-height:650px;grid-template-rows:auto minmax(340px,1fr) auto auto;padding-top:24px;padding-bottom:18px}.topbar{padding-bottom:12px}.stage{margin-bottom:17px}.title-panel{top:4%;padding-top:7px}.title-panel .eyebrow{margin-bottom:11px}h1{font-size:clamp(30px,8cqh,44px)}.title-rule{margin:14px 0 15px}.begin{padding:11px 17px;font-size:18px}.choice-panel{top:5%}.choices{gap:9px;margin-top:17px}.choices button{padding:12px 16px}.story-panel{top:9%}.story-panel h2{font-size:clamp(27px,7.8cqh,39px)}.story-divider{margin:15px 0}.story-panel p{font-size:13px}.dialogue{min-height:157px;grid-template-rows:minmax(93px,auto) auto;padding-top:15px}.dialogue-body{font-size:21px;padding-top:17px}.places-panel{top:4%;height:92%}.intro-panel{top:5%}.intro-panel p{font-size:13px;margin:14px 0 17px}.cast-groups button{font-size:17px}.cast-panel{padding-top:9px}.cast-groups{margin-bottom:6px}.name-rail{margin-bottom:9px}.card-tools{margin-top:7px}.intro-panel h2{font-size:clamp(31px,8cqh,43px)}}


@media(pointer:coarse){body,button,.dialogue-body:disabled{cursor:auto}.click-ring{display:none}}@media(prefers-reduced-motion:reduce){*,*:before,*:after{animation:none!important;transition:none!important}.click-ring{display:none}}
/* The standing sprite continues behind the dialogue window rather than ending at its edge. */
.stage,.actor{overflow:visible}
/* Entrance and conversational choice hierarchy. */
.gate{position:relative;isolation:isolate;min-height:650px;height:100svh;display:flex;align-items:center;overflow:hidden;padding:7% 9%;background:#241b22}.gate-background{position:absolute;inset:0;z-index:-3;background:url('assets/backgrounds/shrine.webp') center 50%/cover;transform:scale(1.015)}.gate:before{content:'';position:absolute;inset:0;z-index:-2;background:linear-gradient(90deg,#221922f5,#37212be8 34%,#2b1c2566 68%,#27192145),linear-gradient(0deg,#24182299,transparent 55%)}.gate:after{content:'';position:absolute;width:160px;height:160px;border:1px solid #d4ad6e22;border-radius:50%;right:13%;top:16%;box-shadow:0 0 0 15px #d4ad6e0d;z-index:-1}.gate-frame{position:absolute;inset:22px;border:1px solid #c9a875;box-shadow:inset 0 0 0 7px #2119234d;pointer-events:none}.gate-frame:before,.gate-frame:after{content:'◆';position:absolute;color:#d7b47f;background:#3b242a;font-size:10px;padding:3px;top:-10px}.gate-frame:before{left:20px}.gate-frame:after{right:20px}.gate-copy{max-width:850px;width:75%;position:relative;z-index:1}.gate-emblem{display:flex;align-items:center;gap:12px;color:#d9bc8e;font:20px var(--serif);letter-spacing:.2em;margin-bottom:42px}.gate-emblem img{width:34px;height:34px;filter:sepia(1) saturate(.6) brightness(1.5)}.gate-kicker{font-size:11px;letter-spacing:.2em;color:#d2b58d;margin-bottom:23px}.gate h1{font-size:clamp(35px,4.3vw,65px);line-height:1.38;letter-spacing:-.035em}.gate h1 .title-small{font-size:.48em;letter-spacing:.09em;margin:6px 0}.gate h1>span:last-child{word-break:keep-all}.gate-subtitle{display:flex;align-items:center;gap:15px;max-width:390px;margin:28px 0 36px;color:#d8b584;font:18px var(--serif);letter-spacing:.14em}.gate-subtitle i{height:1px;background:#d4ad7266;flex:1}.gate .begin{min-width:250px;font-size:22px;padding:16px 22px}.gate-sound-note{display:block;margin-top:15px;font-size:10px;color:#bba799}.gate-seal{position:absolute;right:9%;bottom:12%;border:1px solid #d87658;color:#e6a17d;padding:13px 9px;font:19px/1.3 var(--serif);transform:rotate(-5deg);box-shadow:inset 0 0 0 3px #a4493840}.entered{animation:entry-fade .55s ease-out}@keyframes entry-fade{from{opacity:0;filter:blur(3px)}to{opacity:1;filter:none}}.top-actions{display:flex;align-items:center;gap:15px;margin-left:auto}.top-actions button{font:15px var(--serif);padding:7px 4px}.top-actions #gate-return{font-size:14px;color:#d9bb8b}.topbar{gap:23px}.brand{margin-right:0}.stage,.actor{overflow:hidden}.actor{z-index:0}.scene-panel{z-index:2}.actor img{filter:drop-shadow(-4px 5px 12px #160e2540);transform-origin:50% 85%;mask-image:none}.actor #actor-tap{position:absolute;inset:0;padding:0;border:0;pointer-events:none;cursor:auto;background:none;box-shadow:none;transform:none;filter:none;animation:none!important}.actor #actor-tap:disabled{opacity:1}.actor.is-interactive #amayoi{pointer-events:auto;cursor:url('assets/ui/cursor-active.png') 3 2,pointer}.actor #actor-tap:focus-visible{outline:none}.actor #actor-tap:focus-visible img{filter:drop-shadow(0 0 9px #e8b66b)}.actor img.boing{animation:boing .55s ease-out!important}@keyframes boing{0%,100%{transform:translateY(0) scale(1)}25%{transform:translateY(-9px) scale(1.02,.98)}53%{transform:translateY(2px) scale(.99,1.01)}76%{transform:translateY(-3px) scale(1.005,.997)}}.menu-panel{left:2.5%;top:10%;width:47%;height:86%;max-height:86%;display:flex;flex-direction:column;overflow:hidden;padding:6px 9px 5px 0}.menu-panel h2{font-size:clamp(27px,6.7cqh,42px);line-height:1.45;margin-bottom:23px;flex-shrink:0}.menu-panel .eyebrow{flex-shrink:0}.novel[data-view=main] .menu-panel{top:19%;height:76%;max-height:76%}.answer-choices{display:grid;gap:12px;overflow:auto;min-height:0;scrollbar-width:thin;scrollbar-color:#ad8b69 transparent;padding:3px 7px 5px 0}.answer-choices>button{display:flex;justify-content:space-between;align-items:center;gap:15px;text-align:left;font:21px/1.5 var(--serif);padding:13px 18px;border:1px solid #b99a6b99;background:#30212aea;flex-shrink:0}.answer-choices>button:hover{background:#66312eea;transform:translateX(3px)}.answer-choices i{font-style:normal;font-family:var(--sans);color:#d6ad75;flex-shrink:0}.character-choices{grid-template-columns:1fr 1fr;gap:10px}.character-choices .person-choice{font-size:21px;padding:11px 15px}.character-choices.mountain-choices{grid-template-columns:1fr}.menu-panel .cast-groups{flex-shrink:0;margin:0 0 16px;gap:24px}.menu-panel .cast-groups button{font-size:20px}.return-choice{display:block;flex-shrink:0;text-align:left;align-self:flex-start;padding:10px 0;margin-top:17px;color:#dbbd8f;font:18px var(--serif);border-bottom:1px solid #b9976d66;white-space:nowrap}.return-choice:hover{color:#ffe1a5}.detail-panel{top:17%;width:45%;max-height:79%}.detail-panel h2{font-size:clamp(30px,7cqh,43px);line-height:1.45}.detail-panel p{font:15px/1.9 var(--sans);white-space:pre-line;color:#e4d6c2;text-wrap:pretty}.detail-panel .return-choice{margin-top:28px}.cast-panel{grid-template-rows:auto minmax(0,1fr) auto;width:56%;height:100%;max-height:100%;top:0;padding-top:7px}.cast-panel .return-choice{margin:0 0 12px;padding:10px 0;font-size:17px}.places-panel .return-choice{margin-top:10px}.intro-panel .return-choice{margin-top:22px}.dialogue-footer #back-choice{color:#9e4330}.dialogue-status #line-progress{font-size:10px}.novel[data-view=characters] .menu-panel{top:8%;height:88%;max-height:88%}.novel[data-view=characters] .menu-panel h2{margin-bottom:14px}.dialogue-body{display:grid}#dialogue-reserve,#dialogue-text{grid-area:1/1;align-self:center}#dialogue-reserve{visibility:hidden;pointer-events:none}
@media(max-height:800px) and (min-width:701px){.gate{min-height:600px;padding-top:5%;padding-bottom:5%}.gate-emblem{margin-bottom:25px}.gate h1{font-size:clamp(34px,4vw,52px)}.gate-subtitle{margin:19px 0 23px}.gate-kicker{margin-bottom:15px}.gate .begin{padding:12px 20px}.menu-panel{top:7%;height:89%;max-height:89%}.menu-panel h2{font-size:32px;margin-bottom:17px}.novel[data-view=main] .menu-panel{top:12%;height:84%;max-height:84%}.answer-choices{gap:9px}.answer-choices>button{padding:10px 16px;font-size:19px}.return-choice{margin-top:12px;padding:8px 0;font-size:17px}.novel[data-view=characters] .menu-panel{top:5%;height:93%;max-height:93%}.menu-panel .cast-groups{margin-bottom:10px}.menu-panel .cast-groups button{font-size:18px}.character-choices .person-choice{font-size:18px;padding:8px 14px}.detail-panel{top:13%;max-height:83%}.detail-panel h2{font-size:32px}.detail-panel p{font-size:13px}.cast-panel .return-choice{margin-bottom:8px;padding:7px 0}.dialogue-status #line-progress{font-size:9px}}



/* Full-height visual-novel portrait, anchored behind the dialogue. */
.novel>.actor{position:absolute;inset:0;z-index:0;overflow:hidden;pointer-events:none}
.novel>.stage{z-index:1;pointer-events:none}
.novel>.stage .scene-panel{pointer-events:auto}
.actor #amayoi{mask-image:none;animation:none!important;transition:none!important;opacity:1;transform-origin:50% 70%}
.actor #actor-tap{transition:none!important;animation:none!important}
.bottom-note{z-index:11}
/* Recognisable face thumbnails on every character choice. */
.novel[data-view=characters] .menu-panel{top:4%;height:95%;max-height:95%;width:49%}
.character-choices{grid-template-columns:1fr 1fr;gap:10px}
.character-choices.mountain-choices{grid-template-columns:1fr 1fr}
.character-choices .person-choice{display:grid;grid-template-columns:66px minmax(0,1fr) 10px;gap:12px;padding:6px;min-height:80px;font:20px/1.3 var(--serif);background:#2c2029f2}
.person-choice img{width:66px;height:66px;object-fit:cover;display:block;border:1px solid #c6a4748a;background:#30222b}
.person-choice>span{min-width:0;word-break:keep-all}
.person-choice small{display:block;margin-top:5px;font:10px/1.4 var(--sans);color:#c5ab8b}
.person-choice i{padding-right:4px}
.person-choice:hover img{filter:brightness(1.08)}
.character-choices.mountain-choices .person-choice{font-size:18px}
@media(max-height:800px) and (min-width:701px){
 .novel[data-view=characters] .menu-panel{top:2%;height:97%;max-height:97%}
 .novel[data-view=characters] .menu-panel h2{font-size:29px;margin-bottom:8px}
 .novel[data-view=characters] .menu-panel .eyebrow{margin-bottom:7px}
 .character-choices{gap:7px}
 .character-choices .person-choice{grid-template-columns:52px minmax(0,1fr) 8px;min-height:64px;font-size:18px;gap:9px;padding:5px}
 .person-choice img{width:52px;height:52px}
 .person-choice small{font-size:9px;margin-top:3px}
 .character-choices.mountain-choices .person-choice{font-size:16px}
}


/* Hide the source crop beneath an ink-coloured foreground gradient. */
.lower-shade{position:absolute;inset:0;z-index:1;pointer-events:none;background:linear-gradient(to bottom,transparent 38%,#20151f08 48%,#20151f55 65%,#20151fc4 82%,#19121bf5 94%,#19121b 100%)}
.actor #amayoi-previous{mask-image:none;animation:none!important;transition:none!important;pointer-events:none;transform-origin:50% 70%}
.dialogue{background:linear-gradient(115deg,#f7f0e4fc,#f0e3d3fc)}
.novel[data-view=character] .card-wrap{isolation:isolate}
.card-controls{min-height:0;padding-top:3px}
.card-controls .card-tools{min-height:31px;margin:5px 0 9px}
.emotion-label{font-size:10px;color:#dbc29e;margin-left:auto;letter-spacing:.08em}
.expression-picker{display:grid;grid-template-columns:repeat(8,minmax(0,1fr));gap:5px}
.expression-picker button{font:13px/1.2 var(--serif);padding:9px 3px;min-height:35px;border:1px solid #b4936d70;background:#2b1e29f0;white-space:nowrap;color:#dfcdb4}
.expression-picker button[aria-pressed=true]{background:#923f38;border-color:#e0be8b;color:#fff2d5;box-shadow:inset 0 -2px #e2b887}
.expression-picker button:hover{background:#65302d;color:#ffe4b5}
/* A pair of paper doors briefly opens onto the first scene. */
.entrance{position:fixed;inset:0;z-index:100;overflow:hidden;pointer-events:none}
.entry-door{position:absolute;top:0;bottom:0;width:50%;background:repeating-linear-gradient(0deg,transparent,transparent 109px,#bca17a1c 110px,#bca17a1c 112px),repeating-linear-gradient(90deg,#38252e,#38252e 93px,#bca17a1a 94px,#bca17a1a 96px);border:1px solid #b79b6c66;box-shadow:0 0 35px #120d17aa}
.entry-left{left:0;border-right:3px solid #d4b58588}
.entry-right{right:0;border-left:3px solid #d4b58588}
.entry-emblem{position:absolute;left:50%;top:45%;transform:translate(-50%,-50%);display:flex;flex-direction:column;align-items:center;gap:20px;font:22px var(--serif);letter-spacing:.18em;color:#ead5ac}
.entry-emblem img{width:44px;filter:sepia(1) saturate(.5) brightness(1.4)}
/* Hidden omikuji: familiar paper, a suspiciously self-serving blessing. */
.fortune{padding:0;border:0;background:transparent;color:#3b2928;max-height:94svh;width:min(340px,86vw);overflow:auto;scrollbar-width:thin;box-shadow:0 20px 90px #110b16aa}
.fortune::backdrop{background:#1e1521dc;backdrop-filter:blur(4px)}
.fortune-paper{position:relative;padding:32px 28px 25px;background:#f3e7d3;border:1px solid #d0ad7e;text-align:center;box-shadow:inset 0 0 0 7px #e2c59e66}
.fortune-paper:before{content:'';position:absolute;inset:11px;border:1px solid #9d4c3b70;pointer-events:none}
.fortune small{font:11px var(--serif);letter-spacing:.08em;color:#8d634a}
.fortune h2{font:65px var(--serif);color:#9c3e33;letter-spacing:.15em;margin:24px 0 17px;padding-left:.15em}
.fortune-rule{height:1px;background:#b99b6b;margin:0 9px 24px}
.fortune #fortune-verse{font:20px/1.8 var(--serif);white-space:pre-line}
.fortune dl{margin:24px 0 18px;font:14px var(--serif);text-align:left;border-top:1px solid #b89a6b66}
.fortune dl>div{display:flex;gap:13px;border-bottom:1px solid #b89a6b66;padding:12px 2px}
.fortune dt{color:#9c4436;white-space:nowrap}.fortune dd{margin:0}
.fortune-seal{display:inline-block;border:1px solid #ad4939;color:#ad4939;font:15px/1.2 var(--serif);padding:7px;transform:rotate(-7deg);box-shadow:inset 0 0 0 2px #ad49391a}
.fortune .fortune-aside{font-size:10px;line-height:1.7;color:#8b7560;margin:18px 0 20px;word-break:keep-all}
.fortune #fortune-close{position:relative;font:17px var(--serif);border:1px solid #a86b4f;background:#8c3d33;color:#fff0d6;padding:11px 28px;width:100%}
@media(max-width:1100px){.expression-picker{grid-template-columns:repeat(4,minmax(0,1fr))}.expression-picker button{font-size:13px;min-height:34px;padding:8px 3px}.card-controls .card-tools{margin-bottom:7px}}

/* Portrait crops never become scroll containers when the image is focused. */
.novel,.novel>.actor{overflow:clip}

.portrait-spacer{display:none}
.card-image-button{display:block;width:100%;height:100%;min-height:0;padding:0;background:none;cursor:zoom-in}
.card-image-button img{display:block;width:100%;height:100%;object-fit:contain;object-position:left center;filter:drop-shadow(0 8px 14px #1d111b66)}
.card-enlarge{font:12px/1.4 var(--sans);color:#eed9b5;padding:7px 0;margin-left:auto;text-decoration:underline;text-underline-offset:4px}
.card-zoom{border:1px solid #bda076;background:#251b25;color:#f6e7d0;padding:0;width:min(1100px,96vw);height:94svh;max-width:96vw;max-height:94svh;overflow:hidden}
.card-zoom[open]{display:flex;flex-direction:column}
.card-zoom::backdrop{background:#17101aee;backdrop-filter:blur(5px)}
.card-zoom header{display:flex;align-items:center;gap:14px;padding:12px 18px;border-bottom:1px solid #bda07666;flex-shrink:0}
.card-zoom h2{font:19px/1.5 var(--serif);margin-right:auto;word-break:keep-all}
.card-zoom header button{font-size:14px;padding:10px 13px;min-height:44px;border:1px solid #c4a57988;white-space:nowrap}
.zoom-viewport{flex:1;min-height:0;overflow:auto;touch-action:pan-x pan-y;overscroll-behavior:contain;background:#1b141e;scrollbar-color:#d0af7d #29202c}
.zoom-viewport img{display:block;max-width:none;height:auto}
.card-zoom>p{font-size:13px;line-height:1.6;color:#e4ccb0;padding:10px 16px;margin:0;flex-shrink:0}
@media(max-width:760px),(max-height:500px) and (pointer:coarse){
 html{font-size:100%;-webkit-text-size-adjust:100%;text-size-adjust:100%}
 body{overflow-x:clip}
 .novel{display:flex;flex-direction:column;gap:0;height:auto;min-height:100svh;padding:18px 18px calc(24px + env(safe-area-inset-bottom));overflow:clip}
 .frame{inset:7px;border-color:#c6a67188}
 .frame i{width:16px;height:16px}
 .novel>.scenery{background-attachment:scroll;background-position:center top;background-size:auto 100svh;background-repeat:no-repeat;background-color:#241b25;transform:none}
 .scene-shade{background:linear-gradient(180deg,#24192599,#241925f2 650px,#241925 100%)}
 .lower-shade{display:none}
 /* Four roomy utility controls, independent of the title. */
 .topbar{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px 7px;min-height:0;padding:0 0 16px;border-bottom:1px solid #c0a07670}
 .brand{grid-column:1/-1;grid-row:1;gap:10px;min-height:46px;justify-content:flex-start;min-width:0;padding:0;text-align:left}
 .brand img{width:32px;height:32px;flex-shrink:0}
 .brand>span{font-size:1.25rem;letter-spacing:.02em;line-height:1.3;white-space:normal}
 .brand small{font-size:.8125rem;letter-spacing:.04em;margin-top:5px;color:#e5c89c}
 .top-actions,.sound{display:contents}
 .topbar .top-actions button,.topbar .top-actions #gate-return,.topbar .sound>button,.topbar .sound #sfx-toggle{display:flex;justify-content:center;align-items:center;min-height:48px;font: .875rem/1.3 var(--sans);padding:8px 4px;border:1px solid #bda07988;background:#2b1e2af2;color:#f4e3c9;white-space:normal}
 .topbar button:disabled{opacity:1;color:#a895a4;border-color:#675463;background:#281e29}
 .sound-icon{display:none}
 .volume{z-index:40;right:0;top:100%;font-size:.875rem;width:min(260px,100%);background:#322232;padding:18px}
 .volume input{min-height:40px;accent-color:#c56e56}
 /* A distinct portrait area, followed by readable text and choices. */
 .portrait-spacer{display:block;flex:none;height:280px;margin-top:10px}
 .novel>.actor{bottom:auto;overflow:clip}
 .novel>.actor:after{content:'';position:absolute;inset:0;pointer-events:none;background:linear-gradient(180deg,transparent 55%,#241b2522 65%,#241b25bb 86%,#241b25 100%)}
 .actor.is-interactive #amayoi{cursor:auto}
 .novel:is([data-view=characters],[data-view=character],[data-view=place])>.actor,
 .novel:is([data-view=characters],[data-view=character],[data-view=place])>.portrait-spacer{display:none}
 .novel>.stage{position:relative;container-type:normal;isolation:auto;flex:none;width:100%;min-height:0;height:auto;overflow:visible;margin:0;padding:0}
 .novel .stage .scene-panel,.novel:is([data-view=main],[data-view=about],[data-view=characters],[data-view=places]) .stage .menu-panel{position:relative;inset:auto;width:100%;height:auto;min-height:0;max-height:none;padding:24px 0 0;overflow:visible;margin:0}
 .novel .stage .scene-panel h2{font:1.75rem/1.5 var(--serif);letter-spacing:-.025em;word-break:keep-all;white-space:normal;margin:0 0 18px;text-shadow:none}
 .novel .stage .eyebrow{display:block;font: .875rem/1.65 var(--sans);letter-spacing:.03em;color:#e4c79f;margin-bottom:12px}
 .novel .stage p{font:1.0625rem/1.85 var(--serif);color:#f3e3cf;max-width:none;word-break:keep-all;overflow-wrap:anywhere;text-shadow:none}
 .novel .stage .detail-panel,.novel .stage .intro-panel{background:none}
 .story-divider{margin:18px 0;background:#d5ad78}
 .answer-choices,.novel[data-view=about] .answer-choices{display:grid;grid-template-columns:1fr;gap:12px;overflow:visible;max-height:none;padding:0;margin:0}
 .answer-choices>button{font:1.125rem/1.65 var(--serif);min-height:58px;padding:13px 16px;gap:12px;background:#35242dfb;border:1px solid #c4a274b0;color:#fff0d8;text-shadow:none}
 .answer-choices>button:hover{transform:none;background:#59312f}
 .answer-choices i{font-size:1.125rem;color:#e3be86}
 .novel .stage .return-choice{min-height:48px;display:flex;align-items:center;margin:18px 0 0;padding:10px 0;font:1.0625rem/1.5 var(--serif);color:#efd0a3;white-space:normal}
 /* Portraits and names remain visible without opening a detail card. */
 .novel[data-view=characters] .menu-panel .cast-groups{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin:0 0 16px}
 .menu-panel .cast-groups button{font:1rem/1.5 var(--serif);min-height:48px;padding:10px 5px;color:#e4cdb1;border:1px solid #a7886688;background:#30222f}
 .menu-panel .cast-groups button[aria-pressed=true]{color:#fff0cf;border-color:#e1bd84;background:#7b3834}
 .novel .character-choices{grid-template-columns:1fr 1fr;gap:10px}
 .novel .character-choices .person-choice{grid-template-columns:58px minmax(0,1fr);gap:9px;min-height:90px;padding:8px;font:1.125rem/1.45 var(--serif);background:#33242efa}
 .novel .person-choice img{width:58px;height:66px;object-fit:cover}
 .novel .person-choice>span{min-width:0;word-break:keep-all;overflow-wrap:anywhere}
 .novel .person-choice small{font: .875rem/1.45 var(--sans);margin-top:5px;color:#e1c6a6}
 .novel .person-choice i{display:none}
 .novel .character-choices.mountain-choices{grid-template-columns:1fr}
 .novel .character-choices.mountain-choices .person-choice{font-size:1.1875rem;grid-template-columns:68px 1fr;min-height:98px;gap:15px;padding:10px}
 .novel .character-choices.mountain-choices .person-choice img{width:68px;height:76px}
 /* Full original card with direct touch controls beneath it. */
 .novel .stage .cast-panel{display:flex;flex-direction:column;padding-top:16px}
 .novel .stage .cast-panel .return-choice{margin:0 0 16px}
 .card-wrap{flex:none;width:100%;aspect-ratio:4/3;display:block;min-height:0;background:#221923;border:1px solid #c1a07166}
 .card-image-button{width:100%;height:100%;min-height:0;line-height:0}
 .card-image-button img{object-position:center;filter:none}
 #card-status{top:10px;left:10px;right:10px;padding:12px;font-size:.9375rem;line-height:1.5;background:#31212bf7}
 .card-controls{padding:0}
 .card-controls .card-tools{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:10px;margin:14px 0 16px;min-height:48px}
 .outfits{gap:8px;flex-wrap:wrap}
 .outfits button{min-height:48px;padding:10px 13px;font:1rem/1.4 var(--serif);color:#eed6b4;border-color:#b4946b}
 .outfits button[aria-pressed=true]{color:#fff2d6;background:#713932}
 .card-enlarge{font: .9375rem/1.5 var(--sans);min-height:48px;padding:10px 5px;color:#f6d3a3;margin-left:auto}
 .expression-picker{grid-template-columns:repeat(4,minmax(0,1fr));gap:8px}
 .expression-picker button{font: .9375rem/1.35 var(--serif);min-height:50px;padding:10px 2px;white-space:normal;color:#f2ddc3;border-color:#b09370;background:#34242f}
 .expression-picker button[aria-pressed=true]{color:#fff5df;background:#92463b;border-color:#f2ce94;box-shadow:inset 0 -3px #e5ba7c}
 /* The dialogue grows with the text and is never cropped to a viewport. */
 .novel .dialogue{flex:none;display:block;min-height:0;margin:34px 0 8px;padding:25px 18px 16px;color:#302329;background:#f5ecdf;box-shadow:0 8px 28px #130c1766,inset 0 0 0 5px #dfc6a44d;overflow:visible}
 .dialogue:after{inset:6px}
 .nameplate{left:12px;top:-19px;padding:10px 13px;gap:10px;max-width:calc(100% - 24px)}
 .nameplate strong{font-size:1.375rem;letter-spacing:.05em}
 .nameplate small{font-size:.8125rem;line-height:1.4;padding-left:9px;color:#e8cba0}
 .name-mark{font-size:.8125rem}
 .dialogue-body{display:grid;min-height:0;font:1.1875rem/1.85 var(--serif);text-align:left;letter-spacing:0;padding:12px 0 20px;color:#302329!important;word-break:keep-all;overflow-wrap:anywhere}
 .dialogue-body:disabled{opacity:1}
 .next-mark{font-size:10px;right:0;bottom:9px}
 .dialogue-footer{display:block;min-height:0;padding-top:14px;border-top:1px solid #a3896d77}
 .dialogue-status{font: .875rem/1.6 var(--sans);display:flex;flex-wrap:wrap;gap:4px 10px;color:#695040;margin-bottom:12px}
 .dialogue-status #line-progress{font-size:.875rem;color:#883b30;white-space:normal}
 .dialogue-footer>div{display:grid;grid-template-columns:1fr 1fr;gap:8px;align-items:stretch}
 .dialogue-footer button{min-height:48px;padding:10px 5px;font: .9375rem/1.4 var(--sans);white-space:normal;border:1px solid #b99c7a88;background:#ede0cd;color:#573a31}
 .dialogue-footer button:disabled{opacity:1;background:#f0e7da;color:#927c69;border-color:#d8c7b2}
 .dialogue-footer #back-choice{grid-column:1/-1;margin:0;background:#69312f;color:#fff1d8;border-color:#8b4a3b}
 .dialogue-footer #back-choice:disabled{background:#e5d8c6;color:#856e5a;border-color:#cbbba5}
 .dialogue-footer #next-dialogue{background:#873e34;color:#fff1d8;border-color:#9b5945}
 .dialogue-footer #next-dialogue:disabled{background:#e5d8c6;color:#856e5a;border-color:#cbbba5}
 .bottom-note{min-height:0;display:block;padding-top:20px;font: .8125rem/1.7 var(--sans);color:#c5ae98;letter-spacing:0}
 .bottom-note>span:last-child{display:none}
 .places-panel .place-photo{aspect-ratio:4/3;flex:none;min-height:0}
 .place-photo h2{font-size:1.625rem!important;margin:0!important;left:20px;bottom:18px}
 .novel .stage .intro-panel h2{font-size:2rem}
 .intro-panel p{margin:18px 0 22px}
 .begin,.intro-panel .begin{font-size:1.125rem;min-height:54px;padding:14px 18px;width:100%;min-width:0}
 /* Entrance type and supporting text remain readable as well. */
 .gate{height:auto;min-height:100svh;padding:42px 24px 74px;align-items:center}
 .gate-copy{width:100%;max-width:none}
 .gate-frame{inset:9px;box-shadow:inset 0 0 0 4px #2119234d}
 .gate:before{background:linear-gradient(90deg,#241924f5,#32202ad9),linear-gradient(0deg,#211321ba,transparent)}
 .gate-emblem{font-size:1.125rem;gap:10px;margin-bottom:36px;letter-spacing:.08em}
 .gate-emblem img{width:32px;height:32px}
 .gate-kicker{font: .9375rem/1.65 var(--serif);letter-spacing:.02em;color:#e5c9a4;margin-bottom:24px}
 .gate h1{font-size:clamp(1.875rem,7.8vw,2.8rem);line-height:1.5;letter-spacing:-.055em}
 .gate h1 .title-small{font-size:.67em;margin:9px 0}
 .gate h1>span:last-child{max-width:none;word-break:keep-all;overflow-wrap:anywhere}
 .gate-subtitle{font-size:1.125rem;max-width:330px;margin:28px 0 32px;letter-spacing:.08em}
 .gate .begin{min-width:0;font-size:1.25rem;min-height:58px;padding:15px 18px}
 .gate-sound-note{font: .875rem/1.7 var(--sans);color:#e0cbb9;margin-top:16px}
 .gate-seal{font-size:1rem;right:26px;bottom:22px;padding:8px;position:absolute}
 .entry-emblem{font-size:1.125rem;white-space:nowrap}
 /* Reading tools keep their actions comfortably touchable. */
 .reader{width:100%;height:100svh;max-width:100%;max-height:100svh;border:0}
 .reader-header{height:auto;min-height:104px;display:grid;grid-template-columns:1fr auto;padding:14px;gap:8px 12px}
 .reader-header>div{grid-column:1}
 .reader-header h2{font:1.25rem/1.5 var(--serif)}
 .reader-header small{font-size:.8125rem;letter-spacing:.04em}
 .reader-header>span{grid-column:1;font-size:.875rem;margin:0}
 .reader-header>button{grid-column:2;grid-row:1/3;min-height:48px;font-size:1rem;padding:10px 14px}
 .reader-scroll{height:calc(100% - 104px)}
 .reader-end{display:flex;flex-wrap:wrap;gap:12px;padding:20px 14px}
 .reader-end button{min-height:50px;font-size:1rem;padding:12px 16px}
 .reader-end>span{font-size:.875rem}
 .log{width:calc(100vw - 24px);max-height:90svh}
 .log header{padding:15px;gap:10px}
 .log h2{font:1.25rem/1.5 var(--serif)}
 .log header>button{min-height:48px;font-size:.9375rem;padding:10px 12px;white-space:nowrap}
 #log-content{padding:8px 20px 24px;max-height:calc(90svh - 100px)}
 #log-content p{font:1.125rem/1.85 var(--serif);padding:18px 0}
 #log-content small{font-size:.875rem;line-height:1.5;color:#e5c49a}
 .fortune{width:min(360px,calc(100vw - 24px));max-height:94svh}
 .fortune-paper{padding:28px 22px}
 .fortune small{font-size:.9375rem;line-height:1.5}
 .fortune h2{font-size:3.5rem}
 .fortune #fortune-verse{font-size:1.25rem;line-height:1.8}
 .fortune dl{font-size:1rem;line-height:1.55}
 .fortune .fortune-aside{font-size:.9375rem;line-height:1.8}
 .fortune #fortune-close{font-size:1.125rem;min-height:52px}
 .card-zoom{width:100%;max-width:100%;height:100svh;max-height:100svh;border:0}
 .card-zoom header{display:grid;grid-template-columns:1fr 1fr;padding:14px;gap:10px;min-height:0}
 .card-zoom h2{grid-column:1/-1;font:1.125rem/1.6 var(--serif);margin:0}
 .card-zoom header button{font-size:1rem;min-height:48px;padding:12px 8px}
 .card-zoom>p{font-size:.9375rem;line-height:1.7;padding:12px 16px}
}
@media(max-width:370px){
 .novel{padding-left:14px;padding-right:14px}
 .novel .character-choices{grid-template-columns:1fr}
 .novel .character-choices .person-choice{grid-template-columns:64px 1fr;gap:15px;min-height:94px;padding:10px;font-size:1.1875rem}
 .novel .person-choice img{width:64px;height:72px}
 .portrait-spacer{height:260px}
 .novel .dialogue{padding-left:15px;padding-right:15px}
 .expression-picker{gap:6px}
 .expression-picker button{font-size:.875rem}
 .gate{padding-left:22px;padding-right:22px}
}
@media(max-width:760px),(max-height:500px) and (pointer:coarse){
 .novel[data-view=main] #back-choice,.novel[data-view=main] .dialogue-status{display:none}
 .nameplate small{font-size:.875rem}
}
.reader[open]{display:flex;flex-direction:column}
.reader-header{flex-shrink:0}
.reader-scroll{flex:1;min-height:0;height:auto}
.reader-header #reader-zoom{min-height:44px;padding:8px 12px;font-size:13px;border:1px solid #b69b7377;white-space:nowrap}
.reader.is-zoomed #reader-image{width:200%;max-width:none;margin:0}
@media(max-width:760px),(max-height:500px) and (pointer:coarse){
 .reader-header{grid-template-columns:1fr auto auto;min-height:0}
 .reader-header>div{grid-column:1/-1}
 .reader-header>span{grid-column:1;grid-row:2}
 .reader-header #reader-zoom{grid-column:2;grid-row:2;font-size:.9375rem;min-height:48px;padding:10px 12px}
 .reader-header #reader-close{grid-column:3;grid-row:2;font-size:.9375rem;min-height:48px;padding:10px 12px}
 .reader-scroll{height:auto}
}
