html,body{margin:0;width:100%;height:100%;overflow:hidden;background:#f5f4ef;color:#272a2d}
body.idle{cursor:none}
/* Every scene warms once behind the cover. Only live and next draw during the loop. */
iframe{position:fixed;inset:0;width:100%;height:100%;border:0;visibility:hidden;pointer-events:none}
body.warming iframe{visibility:visible}
iframe.next{visibility:visible;z-index:1}iframe.live{visibility:visible;z-index:2}
#loading{position:fixed;inset:0;z-index:3;background:#f5f4ef;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:24px;font:24px/1.4 system-ui,sans-serif}
#loading strong{font-size:52px}body:not(.warming) #loading{display:none}
#problem,#diag{position:fixed;left:24px;right:24px;z-index:80;margin:0;padding:20px 24px;background:#fff;color:#272a2d;font:17px/1.5 ui-monospace,monospace;white-space:pre-wrap;box-shadow:0 3px 30px #0002}
#problem{top:24px;color:#963d1d}#diag{bottom:24px}[hidden]{display:none!important}

#review{position:fixed;inset:auto 24px 24px;z-index:90;background:#f5f4effa;color:#191f23;border:1px solid #b5bdc2;box-shadow:0 8px 50px #0002;padding:22px;font:16px/1.3 system-ui,sans-serif;cursor:auto}
.review-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:16px}.review-head b{font-size:22px}
#review button{font:inherit;border:1px solid #bec4c7;background:#fff;color:#191f23;cursor:pointer;text-align:left;padding:12px 16px}
#review button:hover,#review button:focus-visible{background:#191f23;color:#fff}
#chapters{display:grid;grid-template-columns:repeat(5,1fr);gap:6px}.review-actions{display:flex;gap:6px;margin-top:14px}#review p{margin:14px 0 0;color:#4d5960}
#review-second{width:75px;font:inherit;padding:10px}
