/* Small contextual windows and compact study routes. Deliberately loaded last. */
:root{--law-highlight:#fff0a6;--law-highlight-ink:#302b17;--route-positive:#ecf7f2;--route-line:#bfd8cf}
html[data-study-theme=dark]{--law-highlight:#62501b;--law-highlight-ink:#fff2b5;--route-positive:#16392f;--route-line:#396457}
.capital-route .route-heading{display:flex;align-items:center;justify-content:space-between;gap:16px}.capital-route h1{font-size:28px;line-height:1.2;margin:7px 0 10px}.capital-route .route-intro{font-size:15px;line-height:1.65;max-width:850px;margin:0 0 18px}.route-heading .study-button{font-size:12px;white-space:nowrap}.route-map{display:flex;align-items:center;gap:8px;margin:16px 0 20px;padding:12px;background:var(--study-wash);border:1px solid var(--study-line);border-radius:10px}.route-map a{display:flex;align-items:center;gap:8px;color:var(--study-ink);text-decoration:none;font-size:14px;font-weight:600;flex:1}.route-map a span,.route-step{display:inline-grid;place-items:center;border-radius:50%;width:27px;height:27px;flex-shrink:0;background:var(--study-accent);color:white;font-size:13px}.route-map b{color:var(--study-muted);font-weight:400}.capital-context{display:flex;flex-wrap:wrap;gap:10px 26px;margin:0 0 20px;padding:0 2px}.capital-context>div>span{display:block;font-size:12px;color:var(--study-muted);margin-bottom:6px}.capital-context .route-scope{flex-basis:100%;font-size:11px;line-height:1.6;color:var(--study-muted);margin:0}.capital-context .route-scope .law-ref{padding:2px 5px;font-size:10px}.capital-context .route-scope .law-ref span{display:none}
.route-options{display:flex;flex-wrap:wrap;gap:5px}.route-options button{font:inherit;font-size:12px;line-height:1.3;min-height:34px;padding:7px 10px;border:1px solid var(--study-line);border-radius:7px;background:var(--study-surface);color:var(--study-ink);cursor:pointer}.route-options button:hover{border-color:var(--study-accent)}.route-options button[aria-pressed=true]{background:var(--study-accent);border-color:var(--study-accent);color:white;box-shadow:0 0 0 1px var(--study-accent)}.route-options button:focus-visible,.route-map a:focus-visible{outline:3px solid var(--study-accent);outline-offset:3px}.route-stage{margin:16px 0 24px;scroll-margin-top:140px}.route-stage>h2{font-size:18px!important;display:flex;align-items:center;gap:9px;margin:0 0 12px!important}.route-classifications{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}.route-question{padding:15px;border:1px solid var(--study-line);border-radius:10px;background:var(--study-surface);display:flex;flex-direction:column;gap:10px;min-width:0}.route-question[data-answer=yes]{border-color:var(--study-accent);box-shadow:inset 0 3px var(--study-accent)}.route-question[data-answer=no]{box-shadow:inset 0 3px #9a784e}.route-question>div:first-child{flex:1}.route-question h3{font-size:15px!important;margin:0 0 6px!important;color:var(--study-ink)!important}.route-question p,.route-consolidation p{font-size:13px!important;line-height:1.55;margin:5px 0!important}.route-question .route-hint{color:var(--study-muted);font-size:12px!important}.route-question .law-rail{margin:9px 0 0}.route-question .law-ref,.route-exception .law-ref,.route-result .law-ref,.route-consolidation .law-ref{font-size:11px;padding:4px 6px}.route-question .law-ref>span{font-size:10px}
#capital-value-questions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.route-exception{grid-column:1/-1;display:flex;flex-wrap:wrap;align-items:center;gap:10px;font-size:12px}.route-exception .law-rail{margin:0}.route-result{margin-top:10px;border:1px solid var(--route-line);border-left:4px solid var(--study-accent);border-radius:9px;padding:14px 16px;background:var(--route-positive);color:var(--study-ink)}.route-result>strong{font-size:16px}.route-result p{font-size:13px!important;line-height:1.65;margin:6px 0!important}.route-result .law-rail{display:inline-flex;margin:7px 7px 0 0}.route-consolidation{padding:13px 15px;border:1px solid var(--study-line);border-radius:9px;background:var(--study-surface)}.route-consolidation .route-options{margin-top:10px}.route-consolidation .law-rail{margin:8px 0 0}.route-next-checks{margin-top:10px;padding-top:8px;border-top:1px solid var(--route-line);font-size:12px}.route-reading-links{display:flex;gap:18px;flex-wrap:wrap;font-size:13px}.route-reading-links a{color:var(--study-accent)}.capital-route>.study-note-source{font-size:11px!important;line-height:1.65;margin-top:20px}
.law-popover{position:fixed;inset:auto;margin:0;padding:0;width:430px;border:1px solid var(--study-line);border-radius:9px;background:var(--study-surface);color:var(--study-ink);box-shadow:0 8px 28px #132c2a29;z-index:2000;overflow:hidden;font-family:Arial,system-ui,sans-serif;font-size:14px;line-height:1.65}.law-popover[hidden]{display:none!important}.law-popover:not([hidden]){display:flex;flex-direction:column}.law-popover::backdrop{background:transparent;pointer-events:none}.law-popover:focus{outline:none}.law-popover-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;padding:11px 13px 7px;border-bottom:1px solid var(--study-line);flex:none}.law-popover-head h2{font-size:15px!important;line-height:1.4;margin:0!important;color:var(--study-accent)!important}.law-popover-head p{font-size:11px!important;color:var(--study-muted);margin:2px 0 0!important}.law-popover-head button{font:inherit;font-size:20px;line-height:1;width:30px;height:30px;flex-shrink:0;border:0;background:transparent;color:var(--study-muted);border-radius:4px;cursor:pointer}.law-popover button:hover{background:var(--study-wash);color:var(--study-accent)}.law-popover button:focus-visible{outline:2px solid var(--study-accent);outline-offset:2px}.law-popover-content{overflow:auto;overscroll-behavior:contain;padding:8px 13px 5px;min-height:0}.law-popover .law-mark-legend{font-size:11px!important;line-height:1.5;color:var(--study-muted);margin:0 0 10px!important}.law-popover mark{color:var(--law-highlight-ink);background:var(--law-highlight);box-decoration-break:clone;-webkit-box-decoration-break:clone;border-radius:2px;padding:1px 0}.law-popover .law-quote p{font-size:13px!important;line-height:1.7;margin:0 0 10px!important;overflow-wrap:break-word}.law-popover footer{flex:none;display:flex;align-items:center;flex-wrap:wrap;justify-content:space-between;gap:6px;padding:8px 13px;border-top:1px solid var(--study-line);color:var(--study-muted);font-size:10px}.law-popover footer button{border:0;color:var(--study-accent);background:transparent;font:inherit;font-size:11px;cursor:pointer;min-height:30px;text-decoration:underline;text-underline-offset:3px}.law-inline{cursor:pointer;text-decoration:underline dotted;text-underline-offset:3px}.law-ref[aria-expanded=true],.law-inline[aria-expanded=true]{outline:2px solid var(--study-accent);outline-offset:2px}
.calculator-fab{position:fixed;right:20px;bottom:calc(20px + env(safe-area-inset-bottom,0px));z-index:120;border:1px solid var(--route-line);border-radius:999px;background:var(--study-surface);color:var(--study-accent);padding:11px 15px;display:flex;align-items:center;gap:8px;box-shadow:0 4px 18px #17383124;cursor:pointer;font:600 12px Arial,sans-serif;min-height:46px}.calculator-fab[hidden]{display:none!important}.calculator-float{position:fixed;z-index:125;width:294px;max-width:calc(100vw - 16px);max-height:calc(100dvh - 16px);overflow:auto;inset:auto;margin:0;padding:0;border:1px solid var(--study-line);border-radius:12px;background:var(--study-surface);color:var(--study-ink);box-shadow:0 8px 35px #142c3438;font-family:Arial,system-ui,sans-serif;font-size:13px}.calculator-float[hidden]{display:none!important}.calculator-float:focus{outline:none}.calculator-float-head{display:flex;align-items:center;gap:5px;padding:9px 10px;border-bottom:1px solid var(--study-line);background:var(--study-wash)}.calculator-handle{display:flex;align-items:center;gap:9px;flex:1;cursor:grab;touch-action:none;user-select:none}.calculator-handle:active{cursor:grabbing}.calculator-float-head h2{font-size:14px!important;line-height:1.3;margin:0!important;color:var(--study-ink)!important}.calculator-float-head button{border:0;background:transparent;color:var(--study-muted);font-size:18px;width:30px;height:28px;border-radius:4px;cursor:pointer}.calculator-float-body[hidden]{display:none!important}.calculator-float .calc-display{margin:10px 11px 8px;padding:10px;border:1px solid var(--study-line);border-radius:8px;background:var(--study-wash);text-align:right;overflow-wrap:anywhere}.calculator-float .calc-expression{font-size:11px;min-height:16px;color:var(--study-muted)}.calculator-float .calc-output{font-size:25px;font-variant-numeric:tabular-nums;display:block;min-height:32px;color:var(--study-ink)}.calculator-float .calc-memory{font-size:10px;min-height:12px;color:var(--study-accent)}.calculator-float .calc-keys{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:5px;margin:0;padding:0 11px}.calculator-float .calc-keys button{border:1px solid var(--study-line);border-radius:6px;padding:7px 0;min-height:33px;line-height:1.1;font-size:15px;cursor:pointer;background:var(--study-surface);color:var(--study-ink)}.calculator-float .calc-keys button:hover{background:var(--study-wash);border-color:var(--study-accent)}.calculator-float .calc-keys button[data-calc-key="="]{background:var(--study-accent);border-color:var(--study-accent);color:white}.calculator-float .calc-help{font-size:10px!important;line-height:1.4;margin:8px 12px!important;color:var(--study-muted)}.calculator-float footer{border-top:1px solid var(--study-line);padding:8px 11px;display:flex;justify-content:space-between;align-items:center;gap:6px;font-size:11px}.calculator-float footer button{font:inherit;padding:7px 8px;border:1px solid var(--study-line);border-radius:6px;background:var(--study-wash);color:var(--study-ink);cursor:pointer}.calculator-float button:focus-visible,.calculator-handle:focus-visible,.calculator-fab:focus-visible{outline:2px solid var(--study-accent);outline-offset:2px}.calc-copy-result{min-width:0;overflow-wrap:anywhere}
.chapter-orientation{display:grid;grid-template-columns:1fr 1fr;gap:18px;background:var(--study-wash);border:1px solid var(--study-line);border-radius:9px;padding:16px 18px;margin:15px 0 20px}.chapter-orientation h2{font-size:15px!important;margin:0 0 7px!important;color:var(--study-ink)!important}.chapter-orientation ul{margin:0;padding-left:19px}.chapter-orientation li{font-size:14px;line-height:1.65;margin:4px 0}.chapter-orientation a{color:var(--study-accent);text-decoration:underline dotted;text-underline-offset:3px}.chapter-orientation .study-note-source{grid-column:1/-1;font-size:10px;line-height:1.5;margin:-4px 0 0;color:var(--study-muted)}
.exam-route-tabs{display:flex;gap:6px;flex-wrap:wrap;margin:18px 0}.exam-route-tabs button{font:inherit;font-size:13px;border:1px solid var(--study-line);border-radius:7px;padding:8px 12px;background:var(--study-surface);color:var(--study-ink);cursor:pointer}.exam-route-tabs button[aria-pressed=true]{color:white;background:var(--study-accent);border-color:var(--study-accent)}.exam-route-card{border:1px solid var(--study-line);border-radius:10px;background:var(--study-surface);padding:18px;margin:0 0 14px}.exam-route-card[hidden]{display:none}.exam-route-card h2{font-size:20px!important;margin:5px 0 12px!important}.exam-route-card .exam-example-label{font-size:11px;color:var(--study-accent);text-transform:uppercase;letter-spacing:.04em}.exam-route-card p{font-size:14px;line-height:1.7}.exam-route-card ol{padding-left:22px;font-size:14px;line-height:1.7}.exam-route-card li{padding-left:3px;margin-bottom:7px}.exam-route-card .exam-route-source{font-size:11px;line-height:1.65;color:var(--study-muted)}.exam-route-card .exam-route-check{background:var(--study-wash);padding:10px 13px;border-left:3px solid var(--study-accent);border-radius:4px}.exam-route-scope{font-size:13px!important;line-height:1.65;color:var(--study-muted);padding:12px 15px;border:1px solid var(--study-line);border-radius:8px;background:var(--study-wash)}
@media(max-width:1050px){.route-classifications{grid-template-columns:1fr}.route-question{flex-direction:row;align-items:center}.route-question>.route-options{max-width:200px;flex:0 0 170px}#capital-value-questions .route-question{flex-direction:column;align-items:stretch}#capital-value-questions .route-options{flex:auto;max-width:none}}
@media(max-width:760px){.capital-route h1{font-size:23px}.route-heading{flex-wrap:wrap}.capital-route .route-heading{gap:5px}.route-heading .summary-kicker{font-size:9px}.route-map{padding:9px 7px;gap:4px}.route-map a{font-size:11px;gap:4px}.route-map a span{width:21px;height:21px;font-size:11px}.capital-context{gap:9px}.route-stage{scroll-margin-top:calc(100px + var(--study-return-h));margin:18px 0}.route-question{padding:12px;flex-direction:column;align-items:stretch;gap:8px}.route-question>.route-options{flex:auto;max-width:none}.route-question p{font-size:13px!important}#capital-value-questions{grid-template-columns:1fr}.route-result{padding:12px}.route-reading-links{gap:9px;font-size:12px}.chapter-orientation{grid-template-columns:1fr;gap:12px;padding:13px 15px;margin:13px 0 17px}.chapter-orientation li{font-size:14px}.calculator-fab{right:12px;bottom:calc(72px + env(safe-area-inset-bottom,0px));padding:11px}.calculator-fab span{display:none}.exam-route-card{padding:14px}.exam-route-card h2{font-size:18px!important}}
@media print{.calculator-float,.calculator-fab,.law-popover,.capital-context,.route-options,[data-capital-reset],.exam-route-tabs{display:none!important}.route-stage{break-inside:avoid}.chapter-orientation{break-inside:avoid}.exam-route-card[hidden]{display:block!important}}

/* Only one stage at a time: the mobile route stays short, while every answer updates all outcomes. */
.capital-route .route-heading>div{max-width:none}.capital-route h1{max-width:none!important}
.route-map button{appearance:none;display:flex;align-items:center;gap:9px;flex:1;text-align:left;border:1px solid transparent;border-radius:8px;padding:10px;background:transparent;color:var(--study-ink);font:inherit;font-size:14px;font-weight:650;cursor:pointer;min-width:0}
.route-map button>span{display:grid;place-items:center;width:27px;height:27px;border-radius:50%;border:1px solid var(--study-accent);color:var(--study-accent);flex:none}.route-map button[aria-pressed=true]{background:var(--study-surface);border-color:var(--study-accent)}.route-map button[aria-pressed=true]>span{background:var(--study-accent);color:white}.route-map small{display:block;font-size:10px;font-weight:400;color:var(--study-muted);margin-top:4px;line-height:1.4}.route-stage[hidden],.capital-context[hidden]{display:none!important}.route-step-navigation{display:flex;justify-content:flex-end;gap:8px;margin:20px 0}.route-step-navigation button[hidden]{display:none}.route-classifications{position:relative}.route-classifications:before{content:'';position:absolute;height:14px;width:65%;top:-15px;left:17%;border:1px solid var(--study-line);border-bottom:0;border-radius:8px 8px 0 0}.route-stage>h2{margin-bottom:25px!important}
@media(max-width:760px){.route-map{padding:6px;align-items:stretch}.route-map button{flex-direction:column;gap:5px;padding:7px 3px;font-size:11px;text-align:center;justify-content:flex-start}.route-map small{font-size:9px;max-width:88px}.route-map>b{align-self:center}.route-map button>span{width:22px;height:22px}.route-classifications:before{display:none}.route-stage>h2{margin-bottom:12px!important}.capital-route .route-heading{flex-wrap:nowrap;align-items:start}.capital-route .route-heading>div{min-width:0}.capital-route h1{font-size:22px}.capital-route .route-heading>button{font-size:10px;padding:7px;white-space:nowrap;margin-top:24px}.capital-context .route-scope{font-size:10px}.route-stage{margin-top:16px}.route-intro{font-size:13px!important;line-height:1.6!important}.route-step-navigation{margin:15px 0}.route-reading-links{margin-top:10px!important}.capital-route>.study-note-source{font-size:10px}}
@media print{.route-stage[hidden]{display:block!important}.route-step-navigation{display:none!important}}

:root[data-study-theme="dark"] .route-options button[aria-pressed="true"],:root[data-study-theme="dark"] .route-map button[aria-pressed="true"]>span,:root[data-study-theme="dark"] .route-step,:root[data-study-theme="dark"] .exam-route-tabs button[aria-pressed="true"]{color:#102629}
