dialog#story {
  box-sizing:border-box;position:fixed;inset:auto auto calc(clamp(24px,4dvh,36px) + env(safe-area-inset-bottom)) max(2vw,env(safe-area-inset-left));
  transform:none;margin:0;width:92vw;max-width:calc(100vw - 2vw - env(safe-area-inset-left) - env(safe-area-inset-right));max-height:80dvh;
  overflow:visible;padding:22px 24px 13px;border:2px solid #ccb797;border-radius:22px;
  color:#483d32;background:#fff5e2;box-shadow:0 5px 0 #392d2729,0 12px 38px #30292033;
  font:15px/1.5 'Trebuchet MS',sans-serif;color-scheme:light;
}
#story::backdrop{background:#211c202b}
#story .speaker-tab{position:absolute;left:22px;top:-15px;background:#ebbd76;color:#594025;border-radius:12px 12px 10px 5px;padding:3px 15px;display:flex;align-items:center;gap:9px;font-size:17px}
#story .speaker-tab small{font-size:10px}
#story .story-body{display:flex;align-items:center;gap:22px;max-height:54dvh;overflow:auto}
#story-portrait{width:96px;height:84px;flex:none;background:#eddfc4;border-radius:50%;image-rendering:pixelated}
#story .story-text{flex:1;min-width:0}
#story h2{font:clamp(23px,2.2vw,29px)/1.2 Georgia,serif;margin:0 0 5px}
#story #story-copy{font:clamp(17px,1.65vw,21px)/1.5 'Trebuchet MS',sans-serif;margin:0;white-space:pre-line}
#story .story-actions{display:flex;align-items:center;gap:8px;justify-content:flex-end;margin-top:12px}
#story .story-actions small{margin-right:auto;font:11px 'Trebuchet MS',sans-serif;color:#766454}
#story button{width:auto;float:none;min-height:30px;border:1px solid #b19065;border-radius:12px;padding:5px 12px;background:#efd39b;color:#4a392a;cursor:pointer;font:600 13px 'Trebuchet MS',sans-serif}
#story #story-close{background:transparent;border-color:transparent}
#story button:focus-visible{outline:2px solid #ad743a;outline-offset:2px}
#story [hidden]{display:none!important}
@media(max-width:560px){dialog#story{left:max(10px,env(safe-area-inset-left));width:calc(100vw - 20px - env(safe-area-inset-left) - env(safe-area-inset-right));padding:17px 14px 11px}#story .story-body{gap:10px}#story-portrait{width:54px;height:48px}#story .story-actions small{font-size:10px}}
