*,:after,:before{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgb(59 130 246/0.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgb(59 130 246/0.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }/*
! tailwindcss v3.4.19 | MIT License | https://tailwindcss.com
*/*,:after,:before{box-sizing:border-box;border:0 solid #e5e7eb}:after,:before{--tw-content:""}:host,html{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}fieldset{margin:0}fieldset,legend{padding:0}menu,ol,ul{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}[role=button],button{cursor:pointer}:disabled{cursor:default}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]:where(:not([hidden=until-found])){display:none}.hidden{display:none}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}:root{--forest:#2D5222;--sage:#5B7C63;--cream:#FDF9F3;--mist:#EDF1EB;--text:#25332E;--muted:#778178;--border:#E7E7E1;--gold:#B1844F;--coral:#C95F5B;--blue:#6F8089}*{box-sizing:border-box}body,html{margin:0;min-height:100%;background:var(--cream);color:var(--text);font-family:Inter,Segoe UI,Tahoma,Arial,sans-serif}button,input,select{font:inherit}button{cursor:pointer}button:disabled{opacity:.54;cursor:not-allowed}button:focus-visible,input:focus-visible,select:focus-visible{outline:3px solid #B1CAB3;outline-offset:2px}h1,h2,h3,p{margin-top:0}h1,h2,h3{line-height:1.25}p{line-height:1.6}a{color:inherit}.spin{animation:rotate 1s linear infinite}@keyframes rotate{to{transform:rotate(1turn)}}.app-layout{display:flex;flex-direction:row-reverse;min-height:100vh;min-height:100dvh}.sidebar{width:256px;flex:0 0 256px;background:linear-gradient(155deg,#183D2B,#1C442E 46%,#325941);color:#EFF5ED;display:flex;flex-direction:column;position:sticky;top:0;height:100vh;height:100dvh;padding:24px 12px 18px;overflow-y:auto;overscroll-behavior:contain;z-index:30;box-shadow:-3px 0 26px #21492B1A}.brand{text-align:center;padding:7px 4px 22px}.brand-emblem{width:56px;height:56px;margin:0 auto 13px;display:grid;place-items:center;border:1px solid #d5e6d15c;border-radius:16px;color:#D5E6D1;background:#FFFFFF0D}.brand h1{font-family:Georgia,serif;font-size:25px;letter-spacing:-.9px;color:white;margin:1px 0 6px}.brand p{margin:0;font-size:12px;line-height:1.5;color:#E0E9DD}.side-navigation{display:flex;flex-direction:column;gap:5px;margin-top:7px}.nav-link{width:100%;min-height:45px;display:flex;align-items:center;gap:11px;padding:10px 12px;border:0;border-radius:11px;background:transparent;color:#F3F7F0;text-align:start;transition:background .2s,color .2s;font-size:13px;font-weight:650}.nav-link svg{flex-shrink:0}.nav-link span{min-width:0;line-height:1.35;overflow-wrap:anywhere}.nav-link small{font-size:11px;font-weight:550}.nav-link:not(.is-active):hover{background:#FFFFFF13}.nav-link.is-active{color:#1F5138;background:linear-gradient(90deg,#FDF8EF,#E8F0E4);box-shadow:0 5px 12px #172E1740}.workspace{display:flex;flex:1;flex-direction:column;min-width:0}.topbar{height:68px;justify-content:space-between;gap:20px;padding:12px 27px;background:#FCF9F5;border-bottom:1px solid #eaeae5}.searchbar,.topbar{display:flex;align-items:center}.searchbar{height:39px;max-width:640px;width:50%;gap:10px;padding:0 15px;background:#F0ECE8;border-radius:24px;color:#606D69}.searchbar input{background:transparent;border:0;outline:0;min-width:0;width:100%;color:var(--text);font-size:12px}.searchbar input::-moz-placeholder{color:#7D8580}.searchbar input::placeholder{color:#7D8580}.top-actions{gap:14px;white-space:nowrap}.language-toggle,.top-actions{display:flex;align-items:center}.language-toggle{padding:3px;border-radius:24px;background:#EBEBE7;gap:3px}.language-toggle button{background:none;border:none;border-radius:22px;padding:5px 10px;font-size:11px;font-weight:750;color:#4A5550}.language-toggle button.selected{background:var(--forest);color:white;box-shadow:0 2px 5px #1C3F2340}.top-divider{height:27px;width:1px;background:#D1D8D0}.icon-button{border:0;background:transparent;color:inherit;display:inline-flex;align-items:center;justify-content:center;width:34px;height:34px;border-radius:10px}.icon-button:hover{background:#F1F2EC}.user-menu{gap:10px;text-align:left;border:0;background:transparent;color:#21382D}.avatar,.user-menu{display:flex;align-items:center}.avatar{justify-content:center;width:39px;height:39px;background:#254F36;color:white;border-radius:50%}.user-details{display:flex;flex-direction:column}.user-details strong{font-size:12px}.mobile-menu{display:none}.main-content{flex:1;width:100%;max-width:1650px;margin:0 auto;padding:20px 24px 28px}.main-content[dir=rtl]{text-align:right}.main-content[dir=rtl] .section-title-left{flex-direction:row}.main-content[dir=rtl] .section-title-left h2 span{display:inline}.welcome-banner{min-height:125px;border:1px solid #e0e6d9;border-radius:14px;display:flex;align-items:center;justify-content:space-between;gap:20px;background:linear-gradient(108deg,#F2F1E9,#E8EBDF);margin-bottom:18px;padding:20px 24px}.welcome-copy{border-inline-start:4px solid var(--sage);padding-inline-start:16px}.eyebrow{color:#6B8B6F;font-size:10px;font-weight:850;letter-spacing:1.4px;display:inline-block;margin-bottom:6px}.welcome-copy h2{font-size:24px;font-family:Georgia,Times New Roman,serif;letter-spacing:-.5px;margin:0 0 5px;color:#2D583F}.welcome-copy>p{font-size:14px;line-height:1.55;margin:0;color:#425C4D}.section-title{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:1px 0 11px}.section-title-left{display:flex;align-items:center;gap:9px;color:#2E6B49}.section-title h2{font-size:15px;font-weight:800;margin:0;color:#202A24}.section-title h2 span{font-size:13px;font-weight:700}.text-action{display:inline-flex;align-items:center;justify-content:center;gap:6px;background:transparent;border:0;color:#2D6845;font-size:11px;font-weight:800}.text-action:hover{text-decoration:underline}.tiny-progress{background:#DFE2DD;border-radius:20px;height:8px;position:relative;overflow:hidden;min-width:30px;flex:1}.tiny-progress span{display:block;height:100%;background:#4E7C55;border-radius:20px;transition:width .25s}.dashboard-grid{display:grid;grid-template-columns:1.25fr .93fr 1.13fr;gap:11px;align-items:stretch}.panel{border:1px solid #e6e5e1;border-radius:15px;background:#FFFEFD;box-shadow:0 2px 12px #3F51420C;padding:15px;min-width:0}.dashboard-grid .panel{min-height:365px;display:flex;flex-direction:column}.soft-tag{font-size:10px;color:#2A6546;background:#E8F1E4;padding:5px 9px;border-radius:7px;font-weight:800;white-space:nowrap}.lecture-name{background:linear-gradient(100deg,#F0F3F0,#F8F9F7);padding:10px 12px;border-radius:10px;margin:7px 0 12px}.lecture-name h3{font-size:17px;margin:0 0 2px;color:#24362A}.lecture-name small{font-size:10px;color:#617068}.chip-row{display:flex;flex-wrap:wrap}.chip,.chip-row{align-items:center;gap:6px}.chip{border-radius:20px;padding:5px 9px;display:inline-flex;font-size:10px;background:#E8F1F2;color:#527481;font-weight:750}.chip-alert{background:#F9EEE9;color:#B56A4E}.parts-row{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:7px;margin-bottom:13px}.part-tile{display:flex;align-items:center;flex-direction:column;text-align:center;gap:3px;background:#FBFBF9;border:1px solid #d8ded7;color:#2F3833;padding:9px 4px;border-radius:10px}.part-tile.selected{background:#ECF4E8;border-color:#3B784E;box-shadow:inset 0 0 0 1px #3B784E40}.part-tile:hover{background:#EFF5EB}.play-circle{border-radius:50%;height:22px;width:22px;background:#74899B;color:white;display:grid;place-items:center}.part-tile.selected .play-circle{background:#346D47}.part-tile strong{font-size:11px}.part-tile small{font-size:9px;font-weight:700}.slide-range{font-size:8.5px;color:#69726B}.primary-button{min-height:39px;border:1px solid #2d6440;background:linear-gradient(180deg,#3A7550,#2D603F);color:white;display:inline-flex;align-items:center;justify-content:center;gap:8px;padding:10px 16px;border-radius:9px;font-weight:800;font-size:12px;transition:filter .15s,transform .15s}.primary-button:hover:not(:disabled){filter:brightness(1.08)}.primary-button:active:not(:disabled){transform:translateY(1px)}.primary-button span{font-weight:550}.full-button{width:100%}.current-lecture>.full-button{margin-top:auto}.key-points-label{background:#EDF3E9;padding:7px 11px;font-size:12px;color:#2B5235;font-weight:800;border-radius:7px;margin:6px 0 12px}.key-points-label span{font-size:11px}.summary-list{display:flex;flex-direction:column}.summary-list.compact{gap:13px}.summary-item{display:flex;gap:9px;align-items:flex-start}.bullet{width:7px;height:7px;min-width:7px;background:#437D4E;border-radius:50%;margin-top:8px}.summary-item p{font-size:11px;line-height:1.42;margin:0 0 4px;color:#25322B}.summary-item .arabic-note{font-size:10px;color:#59655B;line-height:1.55}.summary-item small{font-size:9px;font-weight:800;color:#89918C}.bottom-link{align-self:flex-start;margin-top:auto;padding-top:12px}.quiz-progress{display:flex;align-items:center;gap:10px;margin:10px 0}.quiz-progress>span{display:block;background:#E0E4DF;flex:1;height:8px;border-radius:16px;overflow:hidden}.quiz-progress>span>span{display:block;background:#477A54;height:100%;border-radius:16px}.quiz-progress small{font-size:10px;white-space:nowrap}.preview-question{font-size:12px;line-height:1.45;font-weight:800;border:1px solid #e2e4e0;background:#FAFBF9;padding:10px;border-radius:9px;margin:2px 0 8px}.quiz-preview-options{display:flex;flex-direction:column;gap:7px;flex:1}.choice-preview{border:1px solid #e0e3e0;border-radius:8px;padding:8px 10px;display:flex;gap:10px;align-items:center;color:#394039;font-size:10px}.radio-preview{display:block;min-width:17px;height:17px;border:1.6px solid #9ca8a0;border-radius:50%}.dashboard-quiz .full-button{margin-top:14px}.outline-button{border:1px solid #5d9070;background:#FFFEFD;color:#326845;display:inline-flex;align-items:center;justify-content:center;gap:8px;padding:9px 14px;min-height:37px;font-size:12px;font-weight:800;border-radius:9px}.outline-button:hover:not(:disabled){background:#F0F7ED}.secondary-button{border:1px solid #c9d7c5;background:#EAF3E8;color:#396448;padding:9px 15px;border-radius:9px;font-weight:800;font-size:12px}.analytics-panel{margin-top:12px}.stat-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;margin:4px 0 10px}.stat{border:1px solid #e4e8e1;background:#F5F9F2;padding:9px 5px 8px;border-radius:10px;text-align:center;display:flex;align-items:center;justify-content:center;flex-direction:column;color:#447E50}.stat strong{font-size:21px;line-height:1.35;color:#235A38}.stat small{display:flex;flex-direction:column;font-size:9px;font-weight:700;color:#48564D}.stat small span{font-size:8.5px}.stat.orange{background:#FBF7F1;color:#C17846}.stat.orange strong{color:#92643B}.stat.red{background:#FFF6F2;color:#B76253}.stat.red strong{color:#9D443E}.stat.blue{background:#F2F7F9;color:#748E9B}.stat.blue strong{color:#55707B}.analytics-lower{display:grid;grid-template-columns:1.1fr 1fr;gap:9px}.plan-box,.weak-box{border:1px solid #ece8e4;background:#FCF3F0;padding:8px 10px;border-radius:9px;min-height:70px}.plan-box>strong,.weak-box>strong{font-size:10px}.weak-box ul{margin:5px 0 0;padding-left:17px;font-size:9px}.weak-box li::marker{color:#C56C58}.plan-box p,.weak-box p{font-size:10px;margin:5px 0}.plan-box{background:#F9FAF8}.plan-box .tiny-progress{height:6px;margin:5px 0}.plan-box .text-action{font-size:9px;margin-top:4px;padding:0}.page-heading{display:flex;justify-content:space-between;align-items:center;gap:20px;margin:7px 0 19px}.page-heading h2{font-size:26px;color:#233A2B;margin:2px 0 6px;letter-spacing:-.5px}.page-heading h2 span{font-size:18px;color:#57785E}.page-heading p{font-size:12px;color:#738077;margin:0}.modal input:not([type=file]),.modal select,.plan-form input,.range-form input,.settings-card input,.settings-card select{height:41px;padding:10px 12px;border:1px solid #dce4dc;border-radius:9px;background:#FFFFFF;color:#28362C;min-width:0}.lecture-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.lecture-list-card{padding:19px;border:1px solid #e1e8de;border-radius:12px;background:#FFF;box-shadow:0 3px 11px #2343290E;display:flex;gap:13px;align-items:center;text-align:start;color:#24392B;min-width:0}.lecture-list-card:hover{border-color:#8CAE8F}.lecture-file-icon{width:52px;height:52px;border-radius:12px;background:#EDF3EA;display:grid;place-items:center;color:#4E8055}.lecture-list-details{min-width:0;flex:1;overflow-wrap:anywhere}.lecture-list-card h3{font-size:16px;margin:5px 0}.lecture-list-card p{font-size:11px;color:#7A857D;margin-bottom:11px}.lecture-list-card .tiny-progress{height:6px}.lecture-percent{font-size:13px;font-weight:800;color:#40714B}.info-banner,.warning-banner{display:flex;align-items:flex-start;gap:10px;border:1px solid #e8cdaf;background:#FEF9F1;border-radius:10px;padding:12px 15px;margin:10px 0 17px;color:#876037;font-size:12px}.info-banner svg,.warning-banner svg{flex-shrink:0}.info-banner{border-color:#DDE8DF;background:#F4F8F2;color:#55765C;margin:12px 0 20px}.heading-actions{display:flex;gap:8px;flex-wrap:wrap}.study-steps{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:9px;margin-bottom:15px}.study-step{border-radius:12px;border:1px solid #e0e5df;background:white;padding:13px;display:flex;align-items:center;gap:11px;text-align:left;color:#31463A}.study-step.is-current{border-color:#5A9767;background:#F0F8EE;box-shadow:inset 0 0 0 1px #65A47122}.step-number{border-radius:50%;display:grid;place-items:center;width:34px;height:34px;flex:0 0 34px;background:#E9EEE8;color:#6E8874;font-size:14px;font-weight:800}.study-step.is-current .step-number,.study-step.is-done .step-number{background:#4C845A;color:white}.study-step strong{display:block;font-size:14px}.study-step small{color:#718174;font-size:11px}.study-layout{display:grid;grid-template-columns:minmax(0,1.75fr) minmax(230px,.72fr);gap:13px}.study-side{display:flex;flex-direction:column;gap:13px}.part-topline{display:flex;justify-content:space-between;gap:9px;align-items:flex-start;border-bottom:1px solid #eef0ea;padding-bottom:17px}.part-topline h3{font-size:19px;margin:0 0 6px}.part-topline h3 span{font-size:14px;color:#638069}.part-topline p{font-size:11px;color:#819083;margin:0}.summary-list.expanded{gap:17px;padding:6px 1px}.summary-list.expanded .summary-item{gap:12px}.summary-list.expanded .summary-item p{font-size:13px;line-height:1.65}.summary-list.expanded .summary-item .arabic-note{color:#52735D;font-size:12px}.summary-list.expanded .summary-item .bullet{margin-top:8px}.slide-reference{display:inline-flex;align-items:center;gap:5px;color:#78927D!important}.part-actions{display:flex;justify-content:space-between;gap:10px;flex-wrap:wrap;margin-top:25px;padding-top:20px;border-top:1px solid #ebeeea}.quiz-callout{text-align:center;padding:24px 20px}.callout-icon{width:52px;height:52px;background:#EAF3E7;color:#448258;border-radius:16px;margin:0 auto 14px;display:grid;place-items:center}.quiz-callout h3{font-size:18px;margin-bottom:5px}.quiz-callout>p{font-size:11px;color:#708074}.question-count{margin:19px auto 8px;display:flex;flex-direction:column}.question-count strong{font-size:38px;color:#2C6A46;line-height:1.2}.question-count span{font-size:12px;color:#597261}.range-text{font-size:10px!important;margin-bottom:18px}.support-text{display:block;font-size:10px;color:#A18673;margin-top:11px}.quick-revision h3{font-size:14px;display:flex;align-items:center;gap:9px;color:#315B40}.quick-revision>div{border-top:1px solid #edf0ea;padding:9px 0}.quick-revision p{font-size:11px;margin:0 0 5px;line-height:1.5}.quick-revision small{font-size:10px;color:#7A9380}.final-banner{justify-content:space-between;gap:15px;margin-top:14px;background:#F1F6EE}.final-banner,.final-banner h3{display:flex;align-items:center}.final-banner h3{font-size:15px;gap:9px;margin-bottom:5px}.final-banner p{font-size:11px;color:#718174;margin:0}.exclusion-panel{margin:9px 0 16px}.exclusion-panel>p{font-size:11px;color:#708075}.slide-picker{display:flex;flex-wrap:wrap;gap:7px;margin:15px 0}.slide-number{display:flex;align-items:center;justify-content:center;gap:3px;width:36px;height:34px;border-radius:7px;border:1px solid #d6e2d5;background:#F6FBF4;color:#346C41;font-weight:800;font-size:11px}.slide-number.is-excluded{border-color:#D79B7F;background:#FBEAE2;color:#B25E3D}.slide-number.unreadable:not(.is-excluded){border-style:dashed;border-color:#E2BA77}.range-form{display:flex;gap:7px}.range-form input{flex:1}.quiz-stage{max-width:900px;margin:0 auto;border:1px solid #e0e7df;background:white;box-shadow:0 12px 40px #2F4C3520;border-radius:18px;padding:30px 36px}.quiz-stage-top{display:flex;align-items:center;justify-content:space-between;color:#52715A;font-size:12px;font-weight:800}.quiz-progress.wide{margin:12px 0 27px}.quiz-progress.wide>span{height:10px}.quiz-topic{display:inline-flex;align-items:center;gap:6px;background:#EFF5EC;color:#53815F;padding:7px 11px;border-radius:8px;font-size:11px;font-weight:800;margin-bottom:12px}.quiz-stage h3{font-size:23px;line-height:1.45;margin:7px 0 24px;max-width:760px;text-align:left}.quiz-options{display:flex;flex-direction:column;gap:10px}.answer-choice{width:100%;min-height:62px;display:flex;align-items:center;gap:14px;background:#FCFDFB;border:1px solid #dae5da;border-radius:12px;padding:11px 16px;text-align:left;color:#283A30;font-size:14px}.answer-choice:hover:not(:disabled){background:#F0F8EF;border-color:#83AD86}.answer-choice:disabled{opacity:1;cursor:default}.answer-letter{height:31px;width:31px;flex:0 0 31px;display:grid;place-items:center;font-size:12px;font-weight:850;background:#EDF2EC;border-radius:50%;color:#4C6C51}.answer-choice>span:nth-child(2){flex:1}.choice-circle{width:17px;height:17px;border-radius:50%;border:2px solid #9eb3a2}.answer-choice.is-correct{border-color:#67A773;background:#EDF9ED;color:#255E39}.answer-choice.is-wrong{border-color:#D98E83;background:#FFF0EE;color:#A54D43}.answer-choice.is-correct .answer-letter{background:#468B51;color:#fff}.answer-choice.is-wrong .answer-letter{background:#C96C5F;color:#fff}.hint-button{display:flex;align-items:center;gap:7px;border:0;background:transparent;color:#A47A3B;font-size:12px;font-weight:750;margin:19px 0 7px}.feedback{margin-top:21px;border-radius:11px;padding:17px 20px;border:1px solid #b4d9b5;background:#F0FAF0;color:#2D633D}.feedback.failure{border-color:#EBD1BF;background:#FFF7F1;color:#8F5C38}.feedback-heading{display:flex;align-items:center;gap:9px;font-size:15px;margin-bottom:9px}.feedback p{font-size:12px;line-height:1.7;margin:5px 0}.feedback small{display:block;font-size:10px;color:#708675;margin-top:13px}.quiz-footer{display:flex;align-items:center;justify-content:space-between;gap:14px;border-top:1px solid #e8eee6;padding-top:19px;margin-top:24px;color:#748274;font-size:12px}.result-card{max-width:710px;text-align:center;margin:35px auto;padding:46px 30px}.result-medal{color:#B18A45}.result-card h2{font-size:25px;margin-top:15px}.result-card h2 span{color:#77907D;font-size:17px}.result-number{display:block;font-size:70px;line-height:1.25;color:#37764D}.result-card p{color:#678071}.result-actions{display:flex;justify-content:center;gap:9px;flex-wrap:wrap;margin-top:25px}.wrong-list{display:flex;flex-direction:column;gap:9px}.wrong-card{display:flex;align-items:center;justify-content:space-between;gap:15px}.wrong-card h3{font-size:15px;margin:13px 0 6px}.wrong-card p{font-size:12px;color:#607067;margin:0}.wrong-card>svg{color:#D47A70}.progress-stats{margin-bottom:14px;gap:12px}.progress-stats .stat{min-height:145px}.progress-stats .stat strong{font-size:33px}.progress-stats .stat small{font-size:12px}.two-columns{display:grid;grid-template-columns:1fr 1fr;gap:14px}.progress-row{display:flex;align-items:center;gap:12px;padding:15px 0;border-top:1px solid #eff0ec}.progress-row>div:first-child{width:50%}.progress-row strong{display:block;font-size:13px}.progress-row small{font-size:10px;color:#7D8C80}.progress-row>.tiny-progress{height:9px}.progress-row>b{font-size:12px;color:#477D55}.weak-topic-row{padding:13px 2px;border-top:1px solid #eef1ed;display:flex;justify-content:space-between;gap:10px;font-size:12px}.weak-topic-row span:last-child{font-weight:700;color:#C17B63}.attempt-history{margin-top:14px}.history-row{display:grid;grid-template-columns:2fr 1fr 1fr .5fr;gap:10px;padding:11px 0;border-top:1px solid #e9eee8;font-size:12px}.history-row b{color:#427950}.muted{font-size:12px;color:#849088}.plan-form{display:flex;gap:12px;align-items:end;margin-bottom:14px}.modal form label,.plan-form label,.settings-card label{display:flex;flex-direction:column;gap:7px;font-size:11px;font-weight:800;color:#5E7864}.plan-form label:first-child{flex:1}.plan-form label:nth-child(2){width:190px}.plan-form input{width:100%;min-width:0}.task-panel{padding:10px 17px}.task-row{display:flex;align-items:center;justify-content:space-between;gap:13px;border-bottom:1px solid #e9eee8;padding:13px 6px}.task-row:last-child{border-bottom:0}.task-row label{display:flex;gap:10px;align-items:center;flex:1;font-size:13px}.task-row input{accent-color:#478054;height:18px;width:18px}.task-row small{color:#859286}.crossed{text-decoration:line-through;color:#84958B}.settings-card{padding:23px}.settings-card h3{font-size:18px;margin:0 0 16px}.settings-card label{margin:0 0 18px}.settings-card p{color:#6F7D73;font-size:12px}.settings-card code{color:#265A3D;background:#EBF4EA;padding:2px 5px;border-radius:4px}.settings-actions{display:flex;flex-wrap:wrap;gap:9px;margin:17px 0}.settings-card .info-banner{margin-top:20px}.empty-state{text-align:center;color:#7B8A7F;padding:27px 12px;display:flex;align-items:center;justify-content:center;flex-direction:column;flex:1;min-height:145px}.empty-state svg{color:#87A38C}.empty-state h3{font-size:15px;color:#3A5842;margin:12px 0 5px}.empty-state p{font-size:12px;margin:0 0 11px;max-width:360px}.loading-screen{height:100vh;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:17px;color:#497852}.loading-screen p{font-size:13px;font-weight:750}.modal-layer{position:fixed;inset:0;display:grid;place-items:center;z-index:80;background:#10291ECC;padding:18px;backdrop-filter:blur(4px)}.modal{border-radius:18px;background:white;width:min(550px,100%);padding:26px;max-height:94vh;overflow:auto;box-shadow:0 22px 70px #0004}.modal-title{display:flex;align-items:center;justify-content:space-between;margin-bottom:22px}.modal-title h2{margin:0;font-size:24px}.modal-title h2 span{font-size:15px;color:#5F7A62}.modal form{display:flex;flex-direction:column;gap:16px}.modal form input:not([type=file]),.modal form select{width:100%}.file-drop{border:2px dashed #9ebda1;border-radius:13px;min-height:140px;background:#F7FAF5;display:flex!important;align-items:center;justify-content:center;gap:10px!important;color:#427852!important;position:relative;overflow:hidden;text-align:center}.file-drop input{position:absolute;inset:0;opacity:0;cursor:pointer}.file-drop strong{font-size:14px}.file-drop span{font-weight:550;color:#718574;font-size:11px}.modal-actions{display:flex;justify-content:end;gap:9px}.upload-status small{font-size:11px;color:#5F8068}.toast{position:fixed;z-index:99;right:22px;bottom:20px;max-width:520px;background:#1C4A31;color:white;box-shadow:0 13px 35px #1C3B2A44;border-radius:12px;display:flex;align-items:flex-start;gap:12px;padding:15px;font-size:12px}.toast svg{flex-shrink:0}.toast.error{background:#974C42}.toast button{background:transparent;color:inherit;border:0;margin-left:auto}.mobile-menu,.sidebar-backdrop{display:none}@media(max-width:1320px){.sidebar{width:235px;flex-basis:235px}.main-content{padding:18px}.topbar{padding:10px 18px}.dashboard-grid{grid-template-columns:1.15fr 1fr}.dashboard-quiz{grid-column:1/-1}.dashboard-quiz .quiz-preview-options{display:grid;grid-template-columns:1fr 1fr}.dashboard-quiz .full-button{max-width:290px;align-self:end}}@media(max-width:960px){.sidebar{position:fixed;top:0;right:0;transform:translateX(100%);visibility:hidden;transition:transform .2s,visibility .2s;box-shadow:-6px 0 26px #0003}.sidebar.mobile-open{transform:translateX(0);visibility:visible}.sidebar-backdrop{display:block;position:fixed;inset:0;background:#142A2188;border:0;z-index:29}.mobile-menu{display:grid;place-items:center;flex-shrink:0;width:40px;height:40px;color:#254F36}.workspace{width:100%}.topbar{gap:10px}.searchbar{width:42%}.dashboard-grid{grid-template-columns:1fr 1fr}.dashboard-grid .current-lecture{grid-column:1/-1;min-height:auto}.dashboard-grid .dashboard-quiz{grid-column:auto}.dashboard-quiz .quiz-preview-options{display:flex}.dashboard-quiz .full-button{max-width:none}.study-layout{grid-template-columns:1.5fr 1fr}}@media(max-width:710px){.topbar{height:62px;gap:8px;padding:8px 12px}.top-actions{gap:6px}.top-divider,.user-details,.user-menu>svg{display:none}.avatar{height:34px;width:34px}.searchbar{width:100%;flex:1}.searchbar input{font-size:10px}.main-content{padding:13px}.welcome-banner{align-items:flex-start;flex-direction:column;gap:16px;min-height:auto;padding:17px}.welcome-copy{padding-inline-start:12px}.welcome-copy h2{font-size:20px}.welcome-copy>p{font-size:13px}.dashboard-grid,.lecture-grid,.study-layout,.two-columns{grid-template-columns:1fr}.dashboard-grid .dashboard-quiz{grid-column:1}.page-heading{align-items:flex-start;flex-direction:column;gap:13px}.page-heading h2{font-size:22px}.page-heading h2 span{font-size:15px}.stat-grid,.study-steps{grid-template-columns:repeat(2,1fr)}.plan-form{flex-direction:column;align-items:stretch}.plan-form label:nth-child(2){width:100%}.quiz-stage{padding:20px 16px}.quiz-stage h3{font-size:17px}.quiz-footer{flex-direction:column;align-items:stretch}.modal{padding:18px}.final-banner{align-items:flex-start}.final-banner,.part-actions{flex-direction:column}.part-actions button{width:100%}.lecture-list-card{padding:12px}.heading-actions{width:100%}.heading-actions button{flex:1}.sidebar{width:min(263px,calc(100vw - 36px))}.section-title h2{font-size:14px}.section-title h2 span{font-size:11px}}@media(max-width:400px){.language-toggle button{padding:5px 7px;font-size:9px}.parts-row{gap:4px}.part-tile{padding:7px 1px}.slide-range{font-size:7px}.topbar{padding:8px 11px}}.slide-link{border:0;background:transparent;padding:1px 3px;color:#417D50;display:inline-flex;align-items:center;gap:4px;font-size:10px;font-weight:800}.slide-link:hover{text-decoration:underline}.source-open{margin-left:9px;color:inherit}.pdf-layer{padding:3vh 3vw}.pdf-modal{height:94vh;width:min(1060px,95vw);background:white;border-radius:14px;overflow:hidden;display:flex;flex-direction:column;box-shadow:0 24px 70px #0005}.pdf-modal-head{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:9px 18px;color:#29513A;font-size:13px;border-bottom:1px solid #e6ede4}.pdf-modal iframe{flex:1;width:100%;border:0;background:#E6E6E6}.dashboard-empty .empty-state{min-height:220px}.study-layout.study-layout-wide{grid-template-columns:minmax(0,1fr)}.summary-page .part-topline{flex-wrap:wrap}.summary-list .study-note{min-width:0;flex:1}.summary-list .study-note p{text-align:start;overflow-wrap:anywhere}.summary-list.source-excerpts{margin-top:12px;gap:10px}.source-excerpts .summary-item{padding:13px 15px;border:1px solid #e4e9e0;border-radius:10px;background:#FAFCF8}.source-excerpts .study-note p{margin:0;white-space:pre-line}.excerpt-source{margin-bottom:7px;font-size:12px}.site-credit{align-self:stretch;padding:15px 24px;border-top:1px solid #e1e6dc;text-align:left;color:#32573E;font-family:Georgia,serif;font-size:13px;font-weight:700}@media (max-width:710px){.site-credit{padding-inline:13px}}.lecture-list-card{display:grid;grid-template-columns:minmax(0,1fr);align-content:start;gap:0;padding:0}.lecture-open-button{display:flex;align-items:center;gap:12px;width:100%;min-width:0;padding:16px 16px 12px;border-radius:11px;text-align:start;color:inherit}.lecture-file-icon,.lecture-open-button>svg,.lecture-percent{flex-shrink:0}.lecture-card-metadata,.lecture-card-title,.lecture-open-button .tiny-progress{display:block}.lecture-card-title{margin-block-end:4px;font-size:16px;font-weight:700}.lecture-card-metadata{margin-block-end:9px;color:#5F6F64;font-size:11px}.lecture-delete-button{display:inline-flex;align-items:center;gap:6px;min-height:38px;justify-self:end;margin:0 10px 7px;padding-inline:10px;border-radius:8px;color:var(--danger-text,#973D34);font-size:12px;font-weight:700}.lecture-delete-button:hover{background:var(--danger-bg,#FAECE9)}.lecture-delete-dialog{width:min(440px,calc(100% - 32px));margin:auto;color:var(--text)}.lecture-delete-dialog::backdrop{background:#10291ECC;backdrop-filter:blur(4px)}.lecture-delete-dialog .modal-title{margin-bottom:12px}.delete-lecture-name{margin-bottom:8px;overflow-wrap:anywhere}.lecture-delete-dialog .modal-actions{flex-wrap:wrap;margin-top:22px}.lecture-delete-dialog .lecture-delete-confirm{border-color:#8E3931;background:#9A433A;color:#FFF}@media (max-width:710px){.lecture-open-button{gap:9px;padding-inline:12px}.lecture-open-button .lecture-file-icon{width:40px;height:40px}}.wrong-groups{display:grid;gap:16px}.wrong-group-header{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:14px}.wrong-group-heading{display:flex;align-items:center;min-width:0;gap:10px}.wrong-group-heading>svg{flex:none;color:var(--accent,#2E6B49)}.wrong-group-copy{min-width:0}.wrong-group-copy h3{margin:0;font-size:17px;color:inherit;overflow-wrap:anywhere}.wrong-group-copy p{margin:2px 0 0;color:var(--text-muted,#607067);font-size:12px}.wrong-group .wrong-list{margin:12px 0 0;padding:0;gap:0;list-style:none}.wrong-group .wrong-card{padding-block:12px;border-top:1px solid var(--border,#e2e8dc)}.wrong-group .wrong-card:last-child{padding-bottom:0}.wrong-group .wrong-card>div{min-width:0;overflow-wrap:anywhere}.wrong-group .wrong-card>svg{flex:none}.wrong-group .wrong-card .soft-tag{white-space:normal;display:inline-block}.wrong-group .wrong-card h4{margin:6px 0;font-size:15px;font-weight:700}.part-generation-scope,.question-bank-status{color:var(--text-muted,#596D60);font-size:12px}.question-bank-status{margin:0 0 9px}.part-generation-scope{margin:8px 0 0}.study-step{text-align:start}.study-step .study-step-count{display:block;color:var(--text-muted,#596D60);font-weight:700}.quiz-actions{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:8px}.quiz-draft-progress{margin:0 0 10px;color:var(--text-muted,#607067);font-size:12px}@media (max-width:560px){.quiz-actions>button{flex:1 1 auto}}.theme-toggle{display:flex;align-items:center;gap:10px;width:100%;min-height:46px;margin-top:18px;padding:9px 12px;border:1px solid var(--border);border-radius:9px;background:var(--surface-raised,#F5F8F3);color:var(--text);text-align:start;font-size:13px;font-weight:700}.theme-toggle>svg{color:var(--accent,#3B7450)}.theme-toggle:hover{border-color:var(--accent,#3B7450)}.theme-switch{display:flex;align-items:center;width:38px;height:22px;flex-shrink:0;margin-inline-start:auto;padding:3px;border-radius:20px;background:var(--control-border,#77847C)}.theme-switch:before{content:"";width:16px;height:16px;border-radius:50%;background:white}.theme-toggle[aria-checked=true] .theme-switch{justify-content:flex-end;background:var(--accent,#3B7450)}.theme-toggle[aria-checked=true] .theme-switch:before{background:var(--cream)}html[data-theme=dark]{color-scheme:dark;--cream:#131A17;--surface:#1C2721;--surface-raised:#223029;--surface-green:#283A30;--surface-hover:#304439;--text:#E6EEE8;--text-muted:#ADBFB4;--border:#3B4F44;--control-border:#768D80;--forest:#A5D6B2;--sage:#7AB592;--accent:#A5D6B2;--warning-bg:#382C22;--warning-border:#946E49;--warning-text:#F3C99F;--danger-bg:#432B2A;--danger-border:#9D625E;--danger-text:#FFAFA6;--blue-bg:#273942;--blue-text:#ADD0E2}[data-theme=dark] :is(button,input,select):focus-visible{outline-color:var(--accent)}[data-theme=dark] .sidebar{background:linear-gradient(155deg,#152B21,#1E372A);box-shadow:-3px 0 26px #0003}[data-theme=dark] .nav-link.is-active{background:#365747;color:#F2F9F4}[data-theme=dark] :is(.topbar,.panel,.lecture-list-card,.quiz-stage,.modal,.pdf-modal){background:var(--surface);border-color:var(--border)}[data-theme=dark] :is(.panel,.lecture-list-card,.quiz-stage){box-shadow:0 2px 12px #0002}[data-theme=dark] :is(.searchbar,.language-toggle){background:var(--surface-raised);color:var(--text-muted)}[data-theme=dark] .language-toggle button{color:var(--text-muted)}[data-theme=dark] .language-toggle button.selected{background:var(--accent);color:var(--cream)}[data-theme=dark] :is(.top-divider,.tiny-progress,.quiz-progress>span){background:var(--border)}[data-theme=dark] :is(.primary-button,.avatar){background:var(--accent);border-color:var(--accent);color:var(--cream)}[data-theme=dark] :is(.lecture-list-card,.user-menu,.mobile-menu,.page-heading h2,.section-title h2,.lecture-name h3,.summary-item p){color:var(--text)}[data-theme=dark] :is(.searchbar input,.plan-form input,.modal input,.range-form input,.settings-card input)::-moz-placeholder{color:var(--text-muted)}[data-theme=dark] :is(.searchbar input,.plan-form input,.modal input,.range-form input,.settings-card input)::placeholder{color:var(--text-muted)}[data-theme=dark] :is(.page-heading p,.lecture-card-metadata,.summary-item .arabic-note,.summary-list.expanded .summary-item .arabic-note,.summary-item small,.stat small,.lecture-name small,.slide-range,.part-topline p,.study-step small,.quiz-callout>p,.question-count span,.quick-revision small,.final-banner p,.exclusion-panel>p,.quiz-footer,.feedback small,.result-card p,.wrong-card p,.progress-row small,.muted,.task-row small,.crossed,.settings-card p,.empty-state,.file-drop span,.upload-status small){color:var(--text-muted)}[data-theme=dark] :is(.eyebrow,.welcome-copy h2,.page-heading h2 span,.section-title-left,.lecture-percent,.question-count strong,.quick-revision h3,.text-action,.slide-link,.quiz-stage-top,.result-card h2 span,.result-number,.progress-row>b,.history-row b,.part-topline h3 span,.plan-form label,.modal form label,.settings-card label,.modal-title h2 span,.empty-state svg,.empty-state h3,.loading-screen,.site-credit){color:var(--accent)}[data-theme=dark] .slide-reference{color:var(--accent)!important}[data-theme=dark] .welcome-banner{background:linear-gradient(108deg,#23362B,#283D32);border-color:var(--border)}[data-theme=dark] .welcome-copy>p{color:var(--text)}[data-theme=dark] :is(.soft-tag,.key-points-label,.lecture-file-icon,.quiz-topic,.callout-icon,.settings-card code,.step-number,.info-banner,.stat.green){background:var(--surface-green);border-color:var(--border);color:var(--accent)}[data-theme=dark] :is(.lecture-name,.preview-question,.plan-box,.final-banner,.source-excerpts .summary-item){background:var(--surface-raised);border-color:var(--border)}[data-theme=dark] :is(.part-topline,.part-actions,.quick-revision>div,.quiz-footer,.progress-row,.weak-topic-row,.history-row,.task-row,.site-credit,.pdf-modal-head){border-color:var(--border)}[data-theme=dark] .pdf-modal-head{color:var(--text)}[data-theme=dark] .pdf-modal iframe{background:var(--cream)}[data-theme=dark] :is(.bullet,.tiny-progress span,.quiz-progress>span>span){background:var(--sage)}[data-theme=dark] :is(.part-tile,.study-step,.choice-preview,.answer-choice,.slide-number){background:var(--surface-raised);border-color:var(--border);color:var(--text)}[data-theme=dark] :is(.outline-button,.secondary-button){background:var(--surface);border-color:var(--control-border);color:var(--accent)}[data-theme=dark] :is(.plan-form input,.modal input:not([type=file]),.modal select,.settings-card input,.settings-card select,.range-form input){background:var(--surface-raised);border-color:var(--control-border);color:var(--text)}[data-theme=dark] :is(.icon-button,.part-tile,.study-step):hover,[data-theme=dark] :is(.outline-button,.answer-choice):hover:not(:disabled){background:var(--surface-hover)}[data-theme=dark] :is(.lecture-list-card:hover,.answer-choice:hover:not(:disabled),.part-tile.selected,.study-step.is-current){border-color:var(--sage)}[data-theme=dark] :is(.part-tile.selected,.study-step.is-current){background:var(--surface-hover)}[data-theme=dark] :is(.study-step.is-current,.study-step.is-done) .step-number{background:var(--sage);color:var(--cream)}[data-theme=dark] :is(.choice-circle,.radio-preview){border-color:var(--control-border)}[data-theme=dark] .answer-letter{background:var(--surface-hover);color:var(--accent)}[data-theme=dark] :is(.answer-choice.is-correct,.feedback){background:var(--surface-green);border-color:var(--sage);color:var(--accent)}[data-theme=dark] :is(.answer-choice.is-wrong,.stat.red,.weak-box){background:var(--danger-bg);border-color:var(--danger-border);color:var(--danger-text)}[data-theme=dark] .weak-box li::marker,[data-theme=dark] :is(.stat.red strong,.wrong-card>svg){color:var(--danger-text)}[data-theme=dark] .answer-choice.is-correct .answer-letter{background:var(--accent);color:var(--cream)}[data-theme=dark] .answer-choice.is-wrong .answer-letter{background:var(--danger-text);color:var(--cream)}[data-theme=dark] :is(.warning-banner,.feedback.failure,.stat.orange,.slide-number.is-excluded,.chip-alert){background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-theme=dark] :is(.stat.orange strong,.support-text,.weak-topic-row span:last-child,.result-medal,.hint-button){color:var(--warning-text)}[data-theme=dark] :is(.chip:not(.chip-alert),.stat.blue){background:var(--blue-bg);color:var(--blue-text)}[data-theme=dark] .stat.blue strong{color:var(--blue-text)}[data-theme=dark] .stat.green strong{color:var(--accent)}[data-theme=dark] .file-drop{background:var(--surface-raised);border-color:var(--sage);color:var(--accent)!important}[data-theme=dark] .file-drop:focus-within{outline:3px solid var(--accent);outline-offset:2px}[data-theme=dark] .lecture-card-metadata{color:var(--text-muted)}[data-theme=dark] .lecture-delete-dialog .lecture-delete-confirm{border-color:#FFAFA6;background:#FFAFA6;color:#402120}

/* ==========================================================================
   SpaceStudy Hub – design refinements (r2)
   Appended after the compiled stylesheet. Light-theme rules are scoped with
   html:not([data-theme=dark]) so the existing dark theme is never overridden.
   ========================================================================== */

:root{--font-ui:"IBM Plex Sans Arabic","Inter","Segoe UI",Tahoma,Arial,sans-serif}
html:not([data-theme=dark]){color-scheme:light;--muted:#5A675E}

/* 1 ─ Typography: one family that handles Arabic and Latin, readable sizes */
body,html,button,input,select{font-family:var(--font-ui)}
.main-content[dir=rtl] :is(h1,h2,h3,h4,p,button,label,small,strong,span:not(.eyebrow)){letter-spacing:0}
.main-content[dir=rtl] :is(h2,h3,h4){font-family:var(--font-ui);font-weight:700}
.main-content :is(p,small){unicode-bidi:plaintext}
.main-content :is(.info-banner,.warning-banner) :is(span,div,p){unicode-bidi:plaintext}

.soft-tag,.chip,.lecture-name small,.summary-item small,.slide-link,.stat small,
.quiz-progress small,.progress-row small,.quick-revision small,.feedback small,
.support-text,.part-topline p,.quiz-callout>p,.exclusion-panel>p,.lecture-list-card p,
.lecture-card-metadata,.eyebrow,.plan-box>strong,.weak-box>strong,.plan-box p,
.weak-box p,.weak-box ul,.choice-preview{font-size:12px}
.range-text{font-size:12px!important}
.stat small span,.slide-range,.part-tile small{font-size:11px}
.part-tile strong{font-size:12px}
.summary-item p,.quick-revision p{font-size:12.5px}
.summary-item .arabic-note{font-size:12px}
.searchbar input{font-size:13px}
.language-toggle button{font-size:12px}
@media(max-width:400px){
  .slide-range{font-size:10px}
  .language-toggle button{font-size:11px;padding:5px 8px}
}

@media(min-width:1321px){
  .sidebar{width:272px;flex-basis:272px}
  .nav-link small{font-size:12px}
}

/* 2 ─ Contrast (light theme only; every pair below is ≥ 4.5:1) */
html:not([data-theme=dark]) :is(
  .summary-item small,.part-topline p,.progress-row small,.lecture-list-card p,
  .empty-state p,.quiz-callout>p,.exclusion-panel>p,.quick-revision small,
  .feedback small,.page-heading p,.muted,.study-step small,.lecture-name small,
  .slide-range,.question-count span,.settings-card p,.lecture-card-metadata,
  .part-generation-scope,.question-bank-status,.quiz-draft-progress){color:#5A675E}
html:not([data-theme=dark]) .support-text{color:#7A5C48}
html:not([data-theme=dark]) .hint-button{color:#84601F}
html:not([data-theme=dark]) .eyebrow{color:#4F7156}
html:not([data-theme=dark]) input::placeholder,
html:not([data-theme=dark]) textarea::placeholder{color:#66716B}

/* 3 ─ Keyboard focus that is actually visible on cream/white surfaces */
html:not([data-theme=dark]) :is(button,input,select,a,summary,[tabindex]):focus-visible{
  outline:3px solid #2D6845;outline-offset:2px}

/* 4 ─ Spacing bug: Settings cards were touching each other */
.two-columns{margin-bottom:14px}

/* 5 ─ Empty states: a clear focal point instead of a faint icon */
.empty-state svg{box-sizing:content-box;width:32px;height:32px;padding:14px;border-radius:18px}
html:not([data-theme=dark]) .empty-state svg{background:#EAF3E7;color:#3F7650}
html[data-theme=dark] .empty-state svg{background:var(--surface-green)}

/* 6 ─ Footer credit: centred and quieter */
.site-credit{text-align:center;font-weight:600}
html:not([data-theme=dark]) .site-credit{color:#4A6B55}

/* 7 ─ Mobile top bar: search gets its own full-width row */
@media(max-width:710px){
  .topbar{height:auto;flex-wrap:wrap;row-gap:8px;padding-block:10px}
  .top-actions{flex:1;justify-content:flex-end}
  .searchbar{order:3;flex:1 0 100%;width:100%}
}

/* 8 ─ Respect reduced-motion preferences */
@media(prefers-reduced-motion:reduce){
  *,:before,:after{transition-duration:.01ms!important;scroll-behavior:auto!important}
  .spin{animation-duration:3s}
}
