.spellbook-screen{position:absolute;inset:0;z-index:70;overflow:auto;overscroll-behavior:contain;background:#09131d var(--sb-scene) center/cover;color:#e2d5b7;touch-action:pan-y;font-family:inherit}.spellbook-screen:before{content:'';position:fixed;inset:0;background:#05101bc9;pointer-events:none}.sb-book{position:relative;min-height:100%;max-width:1600px;margin:auto;padding:clamp(16px,2vw,32px);display:flex;flex-direction:column;gap:16px}.sb-header{display:flex;align-items:center;justify-content:space-between;gap:20px;padding:4px 6px 12px}.sb-header small,.sb-page-head>small,.sb-lesson-heading>small{font:10px Georgia,serif;letter-spacing:3px;color:#b6a17a}.sb-header h2{font-weight:400;font-size:clamp(23px,3vw,36px);letter-spacing:3px;margin:8px 0 0;color:#ffe2a7}.sb-tabs{display:flex;gap:12px}.spellbook-screen button{font:inherit;cursor:pointer;background:none;border:0;color:#d9c69c}.spellbook-screen button:focus-visible,.sb-ink:focus-visible{outline:2px solid #ffdfa4;outline-offset:3px}.spellbook-screen button:disabled{opacity:.4;cursor:default}.sb-tabs button{padding:13px 24px;background:var(--sb-button) center/100% 100%;min-height:46px;font-size:15px}.sb-tabs button[aria-selected=true]{color:#fff0c5;filter:brightness(1.35)}.sb-tabs span{font-size:11px;margin-left:6px}.spellbook-screen .sb-close{font:32px Georgia,serif;width:42px;height:42px}.sb-requirements{background:var(--sb-status) center/100% 100%;padding:17px 28px;display:flex;flex-wrap:wrap;gap:8px 22px;align-items:center;font-size:13px}.sb-requirements strong{color:#f2cf84;font-weight:400}.sb-requirements small{flex-basis:100%;font-size:11px;color:#a3b7bc}.sb-spread{display:grid;grid-template-columns:minmax(145px,.52fr) minmax(240px,1fr) minmax(330px,1.23fr);gap:18px;flex:1;min-height:0}.sb-index{display:flex;flex-direction:column;gap:7px;padding:7px 0}.sb-index button{display:flex;align-items:center;gap:10px;text-align:left;padding:7px;min-height:56px;background:#0915238a}.sb-index button.selected{background:var(--sb-status) center/100% 100%;filter:brightness(1.15)}.sb-index img{width:45px;height:45px;object-fit:contain;image-rendering:pixelated;flex-shrink:0}.sb-index strong{display:block;font-size:13px;letter-spacing:1px;font-weight:400;color:#e5d6b0}.sb-index small{display:block;font-size:10px;color:#9caeaf;margin-top:6px}.sb-page,.sb-workspace{border:24px solid transparent;border-image:var(--sb-frame) 60 fill stretch;padding:clamp(20px,2.3vw,36px);min-width:0;display:flex;flex-direction:column}.sb-page{text-align:center;justify-content:center}.sb-page-head h3{font-weight:400;font-size:clamp(24px,2.7vw,37px);color:#f8dfaa;letter-spacing:4px;margin:10px 0 12px}.sb-page-head>p{font-size:12px;line-height:1.7;color:#c6b590;margin:0}.sb-reference{margin:14px auto 4px;width:min(100%,270px);aspect-ratio:1}.sb-reference img{display:block;width:100%;height:100%;object-fit:contain;image-rendering:pixelated}.sb-steps{font-size:12px;color:#f1d29c;line-height:1.9;margin:10px 0}.sb-lore{font-size:12px;color:#9fb1b9;line-height:1.9;margin:7px 0}.sb-footnote{font-size:10px;line-height:1.7;color:#718b9a;margin-top:12px}.sb-lesson-heading h3{font-weight:400;font-size:20px;letter-spacing:2px;color:#ebd7ad;margin:8px 0}.sb-lesson-heading p{font-size:12px;line-height:1.8;color:#a2b6bd;margin:0 0 14px}.sb-ink-wrap{position:relative;flex-shrink:0;aspect-ratio:1;width:min(100%,300px);align-self:center;background:#06111b;border:1px solid #a48a5955;overflow:hidden}.sb-ink{width:100%;height:100%;display:block;touch-action:none;cursor:crosshair}.sb-ink-instruction{position:absolute;left:10px;right:10px;top:47%;font-size:12px;letter-spacing:3px;text-align:center;color:#728e9c;pointer-events:none}.sb-key-cursor{position:absolute;width:30px;height:30px;object-fit:contain;transform:translate(-45%,-65%);pointer-events:none;image-rendering:pixelated}.sb-practice-tools{display:flex;justify-content:space-between;align-items:center;gap:10px;margin:11px 0 0;font-size:11px}.sb-practice-tools button{padding:6px;color:#a9bec5}.sb-progress{color:#dfcb9b}.sb-notice{font-size:12px;line-height:1.8;color:#e9d1a1;min-height:42px;margin:8px 0}.sb-actions{display:flex;justify-content:center;gap:10px;margin-top:auto}.spellbook-screen .sb-primary{background:var(--sb-primary) center/100% 100%;padding:16px 26px;min-height:50px;font-size:14px;color:#f7dfad;letter-spacing:1px}.sb-keyboard-help{font-size:10px;color:#819cab;margin-top:12px;line-height:1.6}.sb-keyboard-help p{margin:8px 0 0}.sb-keyboard-help summary{cursor:pointer}.sb-footer{display:flex;justify-content:space-between;gap:18px;color:#8e9fa4;font-size:10px;line-height:1.7;padding:0 6px}.sb-loadout{display:grid;grid-template-columns:repeat(4,1fr);gap:8px;margin:14px 0 20px}.sb-equipped-slot{text-align:center;display:flex;flex-direction:column;align-items:center;gap:8px;min-height:148px;padding:10px 0;background:#06121c88}.sb-equipped-slot>small{font-size:9px;color:#a59371}.sb-equipped-slot img{width:100%;max-width:76px;aspect-ratio:1;object-fit:contain;image-rendering:pixelated}.sb-equipped-slot strong{font-size:11px;font-weight:400;color:#e4d1aa;white-space:nowrap}.sb-equipped-slot button{font-size:10px;padding:7px;min-height:30px;color:#9bb1bc}.sb-empty-slot{font-size:10px;margin:auto;color:#688392}.sb-equip-selection{padding:16px 0}.sb-equip-selection>strong,.sb-replace>strong{font-size:13px;letter-spacing:1px;color:#e5ce9f;font-weight:400}.sb-equip-selection>p{font-size:12px;line-height:1.8;color:#97aeb7}.sb-equip-selection>button:not(.sb-primary){padding:12px;font-size:13px;color:#e4c48b}.sb-replace{background:#06121dc7;padding:14px}.sb-replace>div{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:12px 0}.sb-replace button{padding:10px;font-size:12px;background:var(--sb-button) center/100% 100%}.sb-replace>button{background:none;padding:5px;color:#92aab5}
@media(min-width:1500px){.sb-ink-wrap{width:340px}.sb-reference{width:310px}.sb-index button{min-height:66px}.sb-index img{width:52px;height:52px}}
@media(max-height:720px) and (min-aspect-ratio:1/1){.sb-book{padding:14px;gap:8px}.sb-header{padding:0 4px 4px}.sb-header h2{font-size:24px}.sb-page,.sb-workspace{padding:22px}.sb-index{gap:3px}.sb-index button{padding:4px;min-height:44px}.sb-index img{width:36px;height:36px}.sb-index small{margin-top:3px}.sb-reference{width:190px;margin-top:8px}.sb-page-head h3{font-size:27px}.sb-ink-wrap{width:min(100%,220px)}.sb-lesson-heading h3{font-size:17px}.sb-lesson-heading p{font-size:11px;margin-bottom:8px}.sb-lore{font-size:11px}.sb-notice{font-size:11px;min-height:36px;margin:5px 0}.spellbook-screen .sb-primary{padding:12px 22px;min-height:42px}.sb-keyboard-help{margin-top:6px}.sb-loadout{margin:5px 0 10px}.sb-equipped-slot{min-height:110px}.sb-equip-selection{padding:8px 0}}
@media(max-width:900px){.sb-spread{grid-template-columns:118px minmax(200px,.9fr) minmax(270px,1.1fr);gap:10px}.sb-index button{gap:4px}.sb-index img{width:33px;height:33px}.sb-index strong{font-size:11px}.sb-index small{font-size:9px}.sb-page,.sb-workspace{padding:23px 18px}.sb-tabs{gap:5px}.sb-tabs button{font-size:12px;padding:12px 14px}.sb-steps{font-size:11px}.sb-requirements{font-size:11px;padding:16px 23px}}
@media(max-aspect-ratio:1/1){.sb-book{padding:16px 12px;gap:12px}.sb-header{flex-wrap:wrap;gap:12px}.sb-header>div:first-child{order:0}.sb-header>.sb-close{order:1}.sb-header>.sb-tabs{order:2;flex-basis:100%;justify-content:center}.sb-header h2{font-size:25px}.sb-tabs button{flex:1;font-size:13px}.sb-spread{display:flex;flex-direction:column;gap:14px}.sb-index{display:grid;grid-template-columns:repeat(4,1fr);gap:5px;padding:0}.sb-index button{flex-direction:column;gap:3px;padding:7px 2px;min-height:81px;text-align:center}.sb-index img{width:38px;height:38px}.sb-index strong{font-size:10px;letter-spacing:0}.sb-index small{font-size:8px;margin-top:3px}.sb-page{display:grid;grid-template-columns:100px 1fr;gap:3px 10px;text-align:left;align-items:center;padding:23px}.sb-page-head{grid-column:2;grid-row:1}.sb-page-head>small{font-size:8px;letter-spacing:1px}.sb-page-head h3{font-size:24px;letter-spacing:2px;margin:8px 0}.sb-page-head>p{font-size:10px}.sb-reference{width:100px;margin:0;grid-column:1;grid-row:1}.sb-steps{grid-column:1/-1;margin:10px 0 0}.sb-lore,.sb-footnote{display:none}.sb-workspace{padding:26px 24px}.sb-ink-wrap{width:min(100%,320px)}.sb-notice{min-height:0;margin:10px 0}.sb-actions{margin-top:6px}.sb-footer{flex-direction:column;gap:6px;text-align:center}.sb-requirements{padding:16px 24px;gap:6px}.sb-requirements span{line-height:1.8}.sb-loadout{gap:5px}.sb-equipped-slot{min-height:130px}.sb-equipped-slot strong{font-size:10px}}

.sb-page,.sb-workspace{border-width:16px;border-image-slice:70 100 70 100;padding:22px}
.sb-requirements{background:none;border:12px solid transparent;border-image:var(--sb-status) 35 90 fill stretch;padding:7px 14px;font-size:14px;line-height:1.8}
.sb-requirements small,.sb-index small,.sb-footnote,.sb-keyboard-help,.sb-footer{font-size:12px;line-height:1.8;color:#acbec4}
.sb-recommended{display:flex;flex-wrap:wrap;gap:8px 18px;flex-basis:100%}.sb-recommended button{font-size:12px;text-decoration:underline;text-underline-offset:4px;padding:4px 0}.sb-recommended button:hover{color:#fff0c5}
.sb-page-head>p,.sb-steps,.sb-lore,.sb-lesson-heading p,.sb-notice,.sb-equip-selection>p{font-size:14px;line-height:1.85}
.sb-index strong,.sb-equip-selection>strong,.sb-replace>strong{font-size:14px;line-height:1.6}
.sb-index button{min-height:64px}.sb-index button.selected{background:#253445;border:1px solid #d9b877;filter:none}
.sb-tabs button,.sb-practice-tools button,.sb-equipped-slot button,.sb-replace button,.sb-keyboard-help summary{min-height:44px}
.sb-practice-tools,.sb-tabs span,.sb-equipped-slot>small,.sb-equipped-slot button,.sb-empty-slot{font-size:12px;line-height:1.7}
.sb-equipped-slot strong{font-size:13px;line-height:1.7;white-space:normal}
.spellbook-screen .sb-primary{color:#172028;text-shadow:none;min-height:48px;font-size:15px}
.sb-keyboard-help summary{display:flex;align-items:center}.sb-footer{font-size:12px}
.sb-book{box-sizing:border-box}
.sb-tactics-lead{font-size:14px;line-height:1.8;color:#c3d0cd;margin:0 6px}
.sb-tactics-grid{display:grid;grid-template-columns:1fr 1fr;gap:16px;min-height:0}
.sb-build{border:12px solid transparent;border-image:var(--sb-frame) 70 100 fill stretch;padding:14px 20px;display:flex;flex-direction:column;gap:10px;min-width:0}
.sb-build-heading{display:flex;justify-content:space-between;align-items:center;gap:14px}.sb-build h3{font-size:23px;font-weight:400;color:#efd299;margin:0}
.sb-build-chain{display:flex;align-items:center;gap:5px;color:#b8a273}.sb-build-chain img{width:47px;height:47px;object-fit:contain;image-rendering:pixelated}
.sb-build p{font-size:14px;line-height:1.8;color:#cbd7d2;margin:0}.sb-build>small{font-size:12px;line-height:1.7;color:#b5a77f}
.sb-build-spells{display:flex;flex-wrap:wrap;gap:8px 14px;font-size:12px;line-height:1.7;color:#bbc8cd}.sb-build-spells .unlearned{color:#e5bd80}
.sb-build .sb-primary{margin-top:auto;align-self:flex-start}.sb-next-lesson{font-size:14px;line-height:1.7;padding:12px;color:#efd299;text-align:left}
@media(min-aspect-ratio:1/1) and (max-height:800px){.sb-tactics-grid{gap:8px}.sb-build{padding:8px 14px;gap:6px}.sb-build h3{font-size:20px}.sb-build-chain img{width:37px;height:37px}.sb-build p{font-size:13px;line-height:1.65}.sb-build .sb-primary{padding:10px 20px;min-height:42px}.sb-tactics-lead{font-size:13px}}
@media(max-width:700px){.sb-tactics-grid{grid-template-columns:1fr}.sb-build{padding:12px}.sb-tabs button{padding-left:8px;padding-right:8px}.sb-build h3{font-size:21px}}
@media(max-width:1000px) and (min-aspect-ratio:1/1){.sb-spread{grid-template-columns:130px minmax(190px,1fr) minmax(250px,1.15fr)}.sb-page,.sb-workspace{padding:16px;border-width:12px}.sb-index img{width:32px;height:32px}.sb-index strong{font-size:12px}.sb-index small{font-size:11px}.sb-loadout{grid-template-columns:repeat(2,1fr)}.sb-equipped-slot{min-height:100px}.sb-equipped-slot img{max-width:60px}}
@media(max-aspect-ratio:1/1){.sb-page,.sb-workspace{border-width:12px;padding:18px}.sb-page{grid-template-columns:90px 1fr}.sb-reference{width:90px}.sb-index strong{font-size:12px;line-height:1.7}.sb-index small{font-size:10px;line-height:1.6}.sb-index button{min-height:88px}.sb-tabs button{font-size:14px;padding:12px 16px}.sb-page-head>p,.sb-steps,.sb-lesson-heading p,.sb-notice,.sb-equip-selection>p{font-size:14px}.sb-footnote{display:block;grid-column:1/-1;font-size:12px;margin-top:8px}.sb-loadout{grid-template-columns:repeat(2,1fr);gap:10px}.sb-equipped-slot{min-height:135px}.sb-equipped-slot strong{font-size:14px}.sb-keyboard-help{display:none}.sb-footer{font-size:12px}}
