.recall{margin:14px 0;border:1px solid #dedede;border-radius:7px;background:#fafafa}.recall summary{color:#444;font-size:14px;letter-spacing:0;padding:13px}.recall p{padding:0 16px 12px;margin:0}.reading-reference{margin-top:28px;padding:15px 20px;border:1px solid #ddd;border-radius:8px;background:#eee}.reading-reference summary{color:#555;font-size:12px;letter-spacing:0}.reading-reference p{font-size:12px}.reading-reference a{color:#444}.formula{overflow-wrap:anywhere;font-size:22px;line-height:1.7}.lesson-diagram{margin:24px 0;background:#f7f7f7;border:1px solid #ddd;border-radius:8px;padding:15px}.lesson-diagram svg{display:block;width:100%;height:auto}.lesson-diagram figcaption{font-size:11px;line-height:1.7;color:#666;margin-top:10px}.truth-table{width:100%;border-collapse:collapse;text-align:center;font-size:13px}.truth-table caption{text-align:left;padding:0 0 14px;color:#555}.truth-table th,.truth-table td{border-bottom:1px solid #ddd;padding:10px}.attempt-list{background:white;border:1px solid #ddd;border-radius:8px;padding:8px 20px}.attempt-list>div{display:flex;justify-content:space-between;gap:20px;padding:12px 0;border-bottom:1px solid #eee;font-size:12px;color:#666}.attempt-list>div:last-child{border:0}.attempt-list b{white-space:nowrap}nav .course-home{margin-bottom:16px;font-size:12px;border:1px solid #555}aside .brand{flex-shrink:0}aside .sidebar-bottom{flex-shrink:0}.paper .recall summary:hover{background:#eee}button:disabled{cursor:default;opacity:.6}@media(max-width:650px){.formula{font-size:18px}.lesson-diagram{padding:7px;margin:18px 0}.attempt-list{padding:8px 12px}}

.question-tools{margin:0;justify-content:flex-end}.question-tools button{padding:8px 12px;font-size:12px}.question-nav{flex-wrap:wrap;align-items:center}.question-nav>.eyebrow{white-space:nowrap}

.deep-section{margin-top:34px;padding-top:6px;border-top:1px solid #eee}.deep-section p{max-width:70ch}.paper p{margin:15px 0}.paper h2{line-height:1.3}.deep-section h2{font-size:25px}

.progress-file-controls{margin:10px 0;border:1px solid #555;border-radius:6px;padding:8px}.progress-file-controls summary{padding:0;font-size:12px;letter-spacing:0;color:#eee}.progress-file-controls p{font-size:11px;line-height:1.5;color:#ddd;margin:8px 0}.progress-file-controls button{display:block;width:100%;margin:5px 0}.progress-file-controls button[hidden]{display:none}.sidebar-bottom{max-height:48vh;overflow-y:auto}

#drawer-close,#drawer-backdrop,.mobile-title{display:none}
@media(max-width:900px){
 body.nav-open{overflow:hidden}
 #sidebar{display:flex;position:fixed;inset:0 auto 0 0;top:0;width:min(320px,86vw);height:100vh;height:100dvh;z-index:40;padding:calc(22px + env(safe-area-inset-top)) 16px calc(16px + env(safe-area-inset-bottom));transform:translateX(-105%);visibility:hidden;transition:transform .2s ease;overscroll-behavior:contain;box-shadow:4px 0 20px #0003}
 body.nav-open #sidebar{transform:translateX(0);visibility:visible}
 #drawer-close{display:block;position:absolute;top:calc(12px + env(safe-area-inset-top));right:10px;width:44px;height:44px;border:0;border-radius:50%;background:transparent;color:white;font-size:30px;line-height:1}
 #drawer-backdrop:not([hidden]){display:block;position:fixed;inset:0;z-index:30;border:0;background:#0007;cursor:pointer}
 main{margin-left:0;width:100%;min-width:0}
 header{position:sticky;top:0;z-index:20;height:calc(64px + env(safe-area-inset-top));padding:env(safe-area-inset-top) 16px 0 8px;justify-content:flex-start;gap:12px;background:#f5f5f5;box-shadow:0 1px 4px #0001}
 #menu{display:flex;align-items:center;justify-content:center;width:48px;height:48px;flex:0 0 48px;border:0;background:transparent;border-radius:50%;font-size:26px;color:#363636;padding:0}
 .desktop-title{display:none}.mobile-title{display:block;font-size:21px;letter-spacing:0;font-weight:600;color:#363636}.local{display:none}
 #content{padding:24px 16px calc(40px + env(safe-area-inset-bottom));overflow-wrap:anywhere}
 #sidebar .brand{padding:4px 42px 24px 10px;font-size:29px}
 #sidebar .path-label{margin-bottom:12px}
 #sidebar .sidebar-bottom{max-height:none;overflow:visible;padding-top:16px}
 #sidebar nav button,#sidebar summary{min-height:44px}
 .paper{padding:22px 18px;width:100%;min-width:0}.grid{grid-template-columns:1fr}.card{min-width:0;padding:20px}.card .foot{gap:12px}
 h1{font-size:30px;line-height:1.2}h2,.deep-section h2{font-size:24px}p,li{font-size:16px;line-height:1.75}
 .stats{gap:12px;flex-wrap:wrap}.stats>span{flex:1 1 120px}.actions{gap:10px}.actions button{min-height:44px;white-space:normal}.primary,.secondary{min-height:44px}
 .tabs{gap:20px}.tabs button{min-height:48px}.option{min-height:52px;padding:16px 12px;line-height:1.6}.option input{width:18px;height:18px;vertical-align:middle}
 .question-nav{align-items:flex-start}.question-nav>.eyebrow{white-space:normal}.question-tools{justify-content:flex-start;width:100%}.question-tools button{font-size:13px;min-height:44px}
 .formula{padding:18px 12px;font-size:20px}.callout{padding:14px 16px}.truth-table{font-size:12px}.truth-table th,.truth-table td{padding:8px 4px}
 .toast{left:16px;right:16px;bottom:calc(16px + env(safe-area-inset-bottom));z-index:50;font-size:14px}
 input[type=range]{min-height:44px}.subject-reading{align-items:flex-start}
}
@media(prefers-reduced-motion:reduce){#sidebar{transition:none}}

.instant-feedback{margin:22px 0;padding:18px;border:1px solid #d5d5d5;border-left:4px solid #4d7a40;border-radius:8px;background:#f5faf3}.instant-feedback.is-incorrect{border-left-color:#ab513f;background:#fff7f4}.instant-feedback h3{margin:0 0 12px;line-height:1.5}.instant-feedback p{margin:10px 0}.answer-correct,.option.answer-correct:has(input:checked){border-color:#5b864c;background:#f2f8ef}.answer-incorrect,.option.answer-incorrect:has(input:checked){border-color:#b96552;background:#fff5f1}.answer-marker{display:block;font-size:12px;font-weight:600;margin-top:6px}.feedback-lesson{margin:16px 0 0;border-top:1px solid #ddd;padding-top:8px}.feedback-lesson summary{color:#444;font-size:14px;letter-spacing:0;line-height:1.5;padding:12px 0}.feedback-lesson p{font-size:14px}.instant-feedback h3:focus{outline:none}

.sync-pill{margin-left:auto;border:1px solid #ccc;border-radius:18px;background:#fff;color:#444;padding:8px 12px;min-height:40px;font-size:12px;max-width:220px;white-space:normal;line-height:1.3}header .local{display:none}#cloud-dialog{width:calc(100% - 32px);max-width:480px;border:1px solid #ccc;border-radius:12px;padding:24px;color:#333;background:#fff}#cloud-dialog::backdrop{background:#0008}#cloud-dialog h2{margin-top:0}#cloud-dialog button[hidden]{display:none}@media(max-width:900px){.sync-pill{font-size:11px;max-width:165px;min-height:44px}}
