/* The publication opens as a complete document; panel motion belongs to reader-motion.js. */
#post-dialog{width:min(1040px,calc(100vw - 48px));height:min(820px,90svh);max-height:calc(100svh - 32px);margin:auto;border:1px solid #fff8;border-radius:22px;box-shadow:0 28px 100px #071f4938;transform-origin:50% 58%}
#post-dialog::backdrop{background:#102a486b;backdrop-filter:blur(8px)}
#post-dialog.reader-entering::backdrop{animation:reader-backdrop-in 360ms cubic-bezier(.22,1,.36,1) both}
#post-dialog.reader-closing::backdrop{animation:reader-backdrop-out 190ms ease-out both}
#post-dialog .post-dialog-header{height:68px;padding:12px 20px;gap:18px}
#post-dialog .post-dialog-header>.circle-button{width:44px;height:44px;min-width:44px;font-size:27px}
#post-dialog .post-dialog-body{grid-template-columns:minmax(0,1.3fr) minmax(270px,.8fr)}
#post-dialog .post-viewer{background:#e8f2f8;perspective:none;overflow:auto;overscroll-behavior:contain;scrollbar-width:thin;touch-action:auto}
#post-dialog .slide-stage{position:static;display:grid;gap:24px;padding:20px;inset:auto;perspective:none}
#post-dialog .post-material{margin:0;min-width:0}
#post-dialog .reader-material{position:static;display:block;width:100%;height:auto;max-width:100%;max-height:none;object-fit:contain;border-radius:8px}
#post-dialog .post-material-number{font-size:11px;line-height:1.5;color:#476c8a;text-align:center;margin-top:8px;font-variant-numeric:tabular-nums}
#post-dialog .post-material-source{display:block;width:fit-content;max-width:100%;margin:8px auto 0;padding:10px 4px;font-size:12px;line-height:1.5;text-align:center;text-decoration:underline;text-underline-offset:3px}
#post-dialog .post-story{padding:26px;scrollbar-width:thin;scrollbar-color:#123b6436 transparent}
#post-dialog .post-story h2{font-size:clamp(25px,2.7vw,36px);line-height:1.08;text-wrap:balance}
#post-dialog :focus-visible{outline:2px solid #037fba;outline-offset:3px}
#post-dialog #post-summary{white-space:pre-line;overflow-wrap:anywhere;margin-bottom:24px}
.work-reader-return{min-height:44px;padding:8px 18px;border:1px solid #123b6430;border-radius:24px;font-size:13px;line-height:1.5}
.work-reader-return:focus-visible{outline:2px solid #037fba;outline-offset:3px}
@keyframes reader-backdrop-in{from{background-color:#102a4800}to{background-color:#102a486b}}
@keyframes reader-backdrop-out{from{background-color:#102a486b}to{background-color:#102a4800}}
@media(max-width:700px){
 #post-dialog{width:calc(100vw - 16px);height:calc(100svh - 24px);max-height:calc(100dvh - 16px);margin:auto auto 8px;border-radius:20px;transform-origin:50% 100%}
 #post-dialog .post-dialog-header{height:64px;padding:10px 12px;gap:12px}
 #post-dialog .post-author{font-size:11px;gap:8px}#post-dialog .post-author img{width:30px;height:30px}
 #post-dialog .post-dialog-body{display:flex;flex-direction:column;overflow:auto;overscroll-behavior:contain}
 #post-dialog .post-viewer{flex:none;min-height:0;height:auto;max-height:none;overflow:visible;order:2}
 #post-dialog .slide-stage{padding:14px;gap:20px}
 #post-dialog .post-story{overflow:visible;flex:none;padding:22px 20px;order:1}
 #post-dialog .post-story h2{font-size:27px;margin:12px 0 16px}
 #post-dialog .post-material:last-child{padding-bottom:max(4px,env(safe-area-inset-bottom))}
}
@media(max-height:520px) and (min-width:701px){#post-dialog{height:calc(100svh - 20px);max-height:calc(100svh - 20px)}#post-dialog .post-dialog-header{height:58px;padding-block:7px}#post-dialog .post-story{padding:18px}}
@media(prefers-reduced-motion:reduce){#post-dialog,#post-dialog *,#post-dialog::backdrop{animation:none!important;transition:none!important}}
.reduce-motion #post-dialog,.reduce-motion #post-dialog *,.reduce-motion #post-dialog::backdrop{animation:none!important;transition:none!important}
