/* (14 Nov 2026, install step 13) the story scroll as ancient parchment: the user's Aged Blank Parchment Sheet (art/story/scroll-parchment.webp)
   as the paper, dark brown old-style writing, a faint drifting dust (dust-1..3.webp). The old per-island scrolls are kept in art/story/old-13nov. */
html body .stpanel::before{
  border-width:0; border-image:none; inset:0; background:url(../art/story/scroll-paper.webp?v=1) 0 0/100% 100% no-repeat}   /* F15: the paper of the user's Antique Weathered Parchment Scroll Banner */
html body .stpanel:not(#_):not(#_){padding:clamp(22px,7vh,34px) clamp(24px,8%,36px) clamp(22px,7vh,34px) !important; color:#2a170a; font-family:Georgia,"Times New Roman",serif;
  filter:drop-shadow(0 6px 10px rgba(0,0,0,.5))}
@media (max-height:400px){ html body .stpanel:not(#_):not(#_){padding-top:20px !important; padding-bottom:18px !important} }
/* dark, readable writing on the paper */
html body .stpanel .stintro:not(#_), html body .stpanel .stnightsay:not(#_), html body .stpanel .note:not(#_){color:#2a170a; text-shadow:none; font-weight:600}
html body .stpanel .stwho b:not(#_){color:#2a170a; font-family:var(--f-display)}
html body .stpanel .stwho small:not(#_){color:#5a3a1c; font-weight:600}
html body .stpanel .sttasks li:not(.got):not(#_){color:#3b2411; font-weight:600}
html body .stpanel .sttasks li.got:not(#_){color:#1f4d1f; font-weight:800}
html body .stpanel .stprize:not(#_){color:#3b2411}
html body .stpanel .stprize b:not(#_){color:#6a3a10}
html body .stpanel .stprize.got b:not(#_){color:#1f5a2a}
html body .stpanel .sttwist:not(#_){color:#2a170a}
html body .stpanel .sttwist b:not(#_){color:#7a3a08}
html body .stpanel .stsoonh:not(#_){color:#2a170a; font-family:var(--f-display); text-shadow:none}
/* a faint dust drifting over the paper; it drifts for a while, then rests (battery) */
html body .stpanel::after{content:""; position:absolute; inset:0; z-index:3; pointer-events:none; opacity:.30; mix-blend-mode:multiply;
  background:url(../art/story/dust-1.webp) no-repeat 8% 18%/16% auto, url(../art/story/dust-2.webp) no-repeat 78% 52%/22% auto, url(../art/story/dust-3.webp) no-repeat 30% 88%/28% auto;
  animation:stdust 26s ease-in-out 3 alternate both}
@keyframes stdust{from{background-position:8% 18%, 78% 52%, 30% 88%} to{background-position:60% 40%, 20% 14%, 74% 60%}}
@media (prefers-reduced-motion:reduce){ html body .stpanel::after{animation:none} }
/* a place just unlocked: its pin pops once */
@keyframes stfresh{0%{transform:scale(.5); opacity:0} 55%{transform:scale(1.25); opacity:1} 100%{transform:scale(1)}}
.stpin.fresh .stpimg{animation:stfresh .9s ease-out 1}
@media (prefers-reduced-motion:reduce){ .stpin.fresh .stpimg{animation:none} }

/* ---------- FIX ROUND 2 F15 (14 Nov 2026): the two rollers of the unrolling story scroll (the user's Scroll Banner pictures, cut to roll-top.webp / roll-bottom.webp) and the dust ---------- */
#storyOv .stbody{position:relative; --h:26px}
.strod{position:absolute; z-index:5; height:var(--h); box-sizing:border-box; pointer-events:none; will-change:transform; border:solid transparent; border-width:0 calc(var(--h)*1.31)}
.strod.t{border-image:url(../art/story/roll-top.webp?v=1) 0 111 0 111 fill / 0 calc(var(--h)*1.31) 0 calc(var(--h)*1.31) stretch; filter:drop-shadow(0 2px 3px rgba(0,0,0,.5))}
.strod.b{height:calc(var(--h)*1.047); border-width:0 calc(var(--h)*1.31); border-image:url(../art/story/roll-bottom.webp?v=1) 0 112 0 112 fill / 0 calc(var(--h)*1.31) 0 calc(var(--h)*1.31) stretch; filter:drop-shadow(0 3px 3px rgba(0,0,0,.5))}
.stpuff{position:absolute; z-index:6; pointer-events:none; opacity:0; will-change:transform,opacity; background:no-repeat center/contain}
/* the title and its line: no box, written in old ink straight on the paper */
html body .stpanel .stname.hasplace:not(.isboss){background:none !important; border:0 !important; box-shadow:none !important; height:auto !important; border-radius:0; overflow:visible; padding:2px 0 4px; margin:0; display:block}
html body .stpanel .stname.hasplace:not(.isboss) .stnamebox{display:grid; justify-items:center; gap:2px; padding:0; mix-blend-mode:multiply}
html body .stpanel .stname.hasplace:not(.isboss) .stnamebox b:not(#_):not(#_){font-family:"IM Fell English","Palatino Linotype",Georgia,serif; font-style:italic; font-weight:700; font-size:clamp(20px,6.4vh,30px); letter-spacing:.03em; color:#34200f; opacity:.88;
  text-shadow:0 0 1.2px rgba(52,32,15,.55), 0 0 5px rgba(120,80,30,.25); filter:blur(.25px)}
html body .stpanel .stname.hasplace:not(.isboss) .stnamebox small:not(#_){font-family:"IM Fell English","Palatino Linotype",Georgia,serif; font-style:italic; font-weight:600; text-transform:none; font-variant:small-caps; font-size:clamp(11px,3.4vh,14px); letter-spacing:.1em; color:#5b3a1c; opacity:.85; text-shadow:0 0 1px rgba(91,58,28,.45); filter:blur(.2px)}
/* (14 Nov 2026, user) the pirate bottle: corked with a scroll inside before a place is open (tap it), empty with the cork beside it while the scroll is open */
.strbtl{position:absolute; z-index:6; padding:0; margin:0; border:0; background:none; cursor:pointer; -webkit-tap-highlight-color:transparent; touch-action:manipulation;
  transition:left .6s cubic-bezier(.3,.7,.3,1), top .6s cubic-bezier(.3,.7,.3,1), width .6s cubic-bezier(.3,.7,.3,1), height .6s cubic-bezier(.3,.7,.3,1); filter:drop-shadow(0 3px 5px rgba(0,0,0,.55))}
.strbtl img{position:absolute; left:0; top:0; width:100%; height:100%; display:block; pointer-events:none; user-select:none; -webkit-user-drag:none}
.strbtl .bt{opacity:0} .strbtl .bk{opacity:0}
.strbtl.closed .bc{opacity:1} .strbtl:not(.closed) .bc{opacity:0} .strbtl:not(.closed) .bt{opacity:1}
.strbtl.popping .bk{opacity:1; left:30%; top:-1%; width:34%; height:auto; transform-origin:50% 90%}
.stbody.corked .strod{visibility:hidden}
.strbtl.closed{animation:strbob 2.8s ease-in-out infinite}
.strbtl.closed::after{content:""; position:absolute; inset:-6% -18%; border-radius:50%; pointer-events:none; background:radial-gradient(closest-side,rgba(255,226,150,.28),rgba(255,226,150,0) 70%); animation:strglow 2.8s ease-in-out infinite}
.strcork{position:absolute; z-index:6; pointer-events:none; transform:rotate(78deg); transition:opacity .4s ease .35s, left .6s, top .6s; filter:drop-shadow(0 2px 3px rgba(0,0,0,.55))}
@keyframes strnope{0%,100%{transform:translateX(0)} 20%{transform:translateX(-4px) rotate(-3deg)} 40%{transform:translateX(4px) rotate(3deg)} 60%{transform:translateX(-3px)} 80%{transform:translateX(3px)}}
.strbtl.closed.nope{animation:strnope .45s ease-in-out}
@keyframes strbob{0%,100%{transform:rotate(-1.5deg) translateY(0)} 50%{transform:rotate(1.5deg) translateY(-3px)}}
@keyframes strglow{0%,100%{opacity:.35} 50%{opacity:1}}
@media (prefers-reduced-motion:reduce){ .strbtl.closed,.strbtl.closed::after{animation:none} .strbtl{transition:none} }

/* ---------- FIX ROUND 3 item 8 (14 Nov 2026): the story scroll is written in an old printed font, IM Fell English (SIL Open Font Licence,
   files in art/fonts/, served from the game itself so it works offline) ---------- */
@font-face{font-family:"IM Fell English"; src:url(../art/fonts/IMFellEnglish-Regular.ttf) format("truetype"); font-weight:400; font-style:normal; font-display:swap}
@font-face{font-family:"IM Fell English"; src:url(../art/fonts/IMFellEnglish-Italic.ttf) format("truetype"); font-weight:400; font-style:italic; font-display:swap}
html body .stpanel:not(#_):not(#_) :is(.stname b, .stname small, .stwho b, .stwho small, .stintro, .stnightsay, .note, .sttasks li, .stprize, .stprize b, .sttwist, .sttwist b){
  font-family:"IM Fell English","Palatino Linotype",Georgia,serif !important; font-weight:400 !important; letter-spacing:.01em}
html body .stpanel .stname:not(.isboss) b:not(#_):not(#_):not(#_){font-style:italic; font-size:clamp(21px,6.4vh,30px) !important; white-space:normal; max-width:100%; line-height:1.05}
html body .stpanel .stname.isboss b:not(#_):not(#_):not(#_){font-style:italic}
html body .stpanel .stname small:not(#_):not(#_):not(#_){font-style:italic; font-variant:small-caps; text-transform:none; font-size:clamp(12px,3.7vh,15px) !important}
html body .stpanel .sttasks li:not(#_):not(#_){font-size:clamp(13px,4vh,16px)}
html body .stpanel .stwho b:not(#_):not(#_){font-size:clamp(13px,4vh,16px)} html body .stpanel .stwho small:not(#_):not(#_){font-size:clamp(11px,3.4vh,13px)}
html body .stpanel .stprize:not(#_):not(#_){font-size:clamp(12px,3.6vh,14px)}

/* (15 Nov 2026, user) the story's subtitles (cutscene captions, speech bubbles, names) are written in the same old printed font as the scroll */
html body :is(.ccap p, .cbubble p, .cname, .stsay, .stcomic .ctap, .svname b, .svname small):not(#_):not(#_){font-family:"IM Fell English","Palatino Linotype",Georgia,serif !important; font-weight:400 !important; letter-spacing:.01em}
html body .ccap p:not(#_):not(#_){font-size:21px; line-height:1.28} html body .cbubble p:not(#_):not(#_){font-size:17px; line-height:1.28} html body .cname:not(#_):not(#_){font-size:22px; font-style:italic}
@media (max-height:430px){ html body .ccap p:not(#_):not(#_){font-size:17px} html body .cbubble p:not(#_):not(#_){font-size:14px} html body .cname:not(#_):not(#_){font-size:18px} }
