body[data-screen=grade9] #screen{height:calc(100dvh - var(--hud-height));min-height:0;display:flex;flex-direction:column;padding-top:18px;padding-bottom:18px;max-width:none}
body[data-screen=grade9] .screen-heading{flex-shrink:0;margin-bottom:14px}
body[data-screen=grade9] .screen-heading .back-link{margin-bottom:8px}
body[data-screen=grade9] .screen-heading h1{font-size:clamp(30px,2.8vw,44px);margin-bottom:7px}
body[data-screen=grade9] .chapter-map{
 display:flex;flex:1;min-height:0;width:100%;max-width:1350px;margin:0 auto;padding:15px 4px 22px;
 gap:24px;align-items:center;overflow-x:auto;overflow-y:hidden;scroll-snap-type:x mandatory;scroll-padding-left:4px;
 touch-action:pan-x pinch-zoom;overscroll-behavior-x:contain;-webkit-overflow-scrolling:touch;scrollbar-width:none;
}
body[data-screen=grade9] .chapter-map::-webkit-scrollbar{display:none}
body[data-screen=grade9] .chapter-node{
 flex:0 0 calc((100% - 48px)/3);width:auto;min-width:0;min-height:0;height:min(100%,365px);max-height:100%;
 scroll-snap-align:start;scroll-snap-stop:always;justify-content:center;padding:22px 20px;transform:none;
}
body[data-screen=grade9] .chapter-node:hover{transform:none;border-color:#d2b471}
body[data-screen=grade9] .chapter-node strong{font-size:clamp(20px,1.5vw,26px);line-height:1.5}
body[data-screen=grade9] .chapter-node small,body[data-screen=grade9] .chapter-node i,body[data-screen=grade9] .chapter-node>b{font-size:13px}
body[data-screen=grade9] .chapter-orb{flex-shrink:0;margin-bottom:15px}
body[data-screen=grade9] .chapter-node>b{margin-top:15px;padding-top:0}
body[data-screen=grade9] .chapter-7{grid-column:auto;justify-self:auto}
.chapter-controls{flex-shrink:0;display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:12px;width:100%;max-width:1350px;margin:0 auto}
.chapter-controls>button:disabled{opacity:.35;cursor:default;transform:none}
.chapter-dots{display:flex;justify-content:center;gap:9px}
.chapter-dots button{width:36px;height:36px;border:1px solid #78916b;border-radius:50%;background:#193b35;color:#bdc9a5;font:14px var(--sans);cursor:pointer}
.chapter-dots button.active{background:#d6b56c;color:#20362d;border-color:#edcf8d}
#chapter-position{grid-column:1/-1;text-align:center;color:#98b59e;font-size:13px;margin:0;line-height:1.5}
body[data-screen=grade9] .guide-strip{flex-shrink:0;margin-top:12px;padding:12px 18px}
body[data-screen=grade9] .guide-strip p{font-size:13px}
@media(max-width:1100px){
 body[data-screen=grade9] .chapter-node{flex-basis:calc((100% - 24px)/2)}
}
@media(max-height:760px) and (min-width:601px){
 body[data-screen=grade9] #screen{padding-top:12px;padding-bottom:12px}
 body[data-screen=grade9] .screen-heading .eyebrow{margin-bottom:4px;font-size:12px}
 body[data-screen=grade9] .screen-heading h1{font-size:30px}
 body[data-screen=grade9] .screen-heading p:not(.eyebrow){font-size:14px}
 body[data-screen=grade9] .chapter-node{padding:15px 18px}
 body[data-screen=grade9] .chapter-orb{width:44px;height:44px;font-size:23px;margin-bottom:8px}
 body[data-screen=grade9] .chapter-node strong{font-size:20px;margin:5px 0}
 body[data-screen=grade9] .chapter-node>b{margin-top:8px}
 body[data-screen=grade9] .guide-strip{display:none}
}
@media(max-width:600px){
 body[data-screen=grade9] #screen{height:calc(100dvh - var(--hud-height) - 70px - env(safe-area-inset-bottom));padding:12px 12px 14px}
 body[data-screen=grade9] .screen-heading{gap:8px;margin-bottom:7px;position:relative}
 body[data-screen=grade9] .screen-heading h1{font-size:28px}
 body[data-screen=grade9] .screen-heading .eyebrow{font-size:10px;letter-spacing:.6px;margin-bottom:5px}
 body[data-screen=grade9] .screen-heading .back-link{font-size:12px;margin-bottom:5px}
 body[data-screen=grade9] .screen-heading p:not(.eyebrow){font-size:13px;line-height:1.7}
 body[data-screen=grade9] .screen-heading>[data-index]{font-size:12px;padding:5px 10px;min-height:34px}
 body[data-screen=grade9] .chapter-map{gap:16px;padding:10px 4px 16px;align-items:stretch}
 body[data-screen=grade9] .chapter-node{flex-basis:calc(100% - 24px);height:100%;max-height:none;padding:18px 22px;scroll-snap-align:start}
 body[data-screen=grade9] .chapter-node strong{font-size:23px;margin:12px 0;line-height:1.5}
 body[data-screen=grade9] .chapter-orb{width:54px;height:54px;font-size:27px;margin-bottom:12px}
 body[data-screen=grade9] .chapter-node small,body[data-screen=grade9] .chapter-node i,body[data-screen=grade9] .chapter-node>b{font-size:13px}
 .chapter-controls{gap:7px;grid-template-columns:auto 1fr auto}
 .chapter-controls>.outline-button,.chapter-controls>.gold-button{font-size:12px;padding:7px 10px;min-height:38px}
 .chapter-dots{gap:5px}.chapter-dots button{width:13px;height:13px;padding:0;font-size:0}
 #chapter-position{font-size:12px;line-height:1.6}
 body[data-screen=grade9] .guide-strip{display:none}
}
@media(max-width:600px) and (max-height:740px){
 body[data-screen=grade9] .screen-heading p:not(.eyebrow){display:none}
 body[data-screen=grade9] .chapter-orb{width:42px;height:42px;font-size:22px;margin-bottom:8px}
 body[data-screen=grade9] .chapter-node strong{font-size:21px;margin:8px 0}
 body[data-screen=grade9] .chapter-node{padding:14px 18px}
 body[data-screen=grade9] .chapter-node>b{margin-top:12px}
}
@media print{body[data-screen=grade9] #screen{height:auto}.chapter-controls{display:none}body[data-screen=grade9] .chapter-map{display:block;overflow:visible}body[data-screen=grade9] .chapter-node{height:auto;max-height:none}}

