@font-face{font-family:"Vazir";src:url("Vazir.ttf") format("truetype");font-style:normal;font-weight:100 900;font-display:swap}

:root{--ink:#172b3a;--muted:#657786;--primary:#146c5b;--primary-dark:#0d5145;--mint:#e3f5ee;--paper:#fff;--bg:#f5f8f7;--line:#e2eae7;--gold:#eab85a;--danger:#a62f42;--shadow:0 18px 50px rgba(26,58,48,.08)}*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--ink);font-family:'Vazir',Tahoma,Arial,sans-serif;line-height:1.85}.topbar{height:76px;display:flex;align-items:center;justify-content:space-between;padding:0 max(calc((100% - 1120px)/2),24px);background:rgba(255,255,255,.92);border-bottom:1px solid var(--line)}.brand{display:flex;align-items:center;gap:10px;text-decoration:none;color:var(--ink);font-weight:800;font-size:1.2rem}.brand-icon{display:grid;place-items:center;width:38px;height:38px;border-radius:13px;background:var(--primary);color:white}nav{display:flex;gap:24px}nav a,.back-link{color:var(--muted);text-decoration:none;font-size:.92rem}nav a:hover,.back-link:hover{color:var(--primary)}.container{max-width:1120px;margin:0 auto;padding:38px 24px 60px}.hero{display:grid;grid-template-columns:1.1fr .9fr;gap:32px;align-items:center;min-height:410px;background:linear-gradient(120deg,#e8f6ef,#f9fcfa);border:1px solid #dcefe5;border-radius:28px;padding:48px 56px;overflow:hidden}.eyebrow{font-size:.82rem;font-weight:700;color:var(--primary);letter-spacing:.02em}.hero h1{font-size:clamp(2rem,4vw,3.2rem);line-height:1.35;margin:14px 0}.hero h1 span{color:var(--primary)}.hero p,.page-heading p,.feature p,.create-panel p{color:var(--muted);max-width:610px}.button{display:inline-flex;justify-content:center;align-items:center;gap:10px;border:0;border-radius:12px;padding:12px 20px;font:inherit;font-weight:700;text-decoration:none;cursor:pointer;transition:.18s}.button:hover{transform:translateY(-1px)}.button:disabled{opacity:.45;cursor:not-allowed;transform:none}.primary{background:var(--primary);color:#fff}.primary:hover{background:var(--primary-dark)}.secondary{background:var(--mint);color:var(--primary)}.hero-art{height:300px;position:relative;display:grid;place-items:center}.orbit{position:absolute;border:1px solid #b9ddce;border-radius:50%;width:270px;height:270px}.orbit-two{width:220px;height:220px;border-style:dashed}.paper{z-index:1;position:relative;width:180px;height:235px;background:white;border-radius:16px;padding:25px 20px;box-shadow:0 20px 45px #174f3b24;transform:rotate(-5deg)}.paper-line{height:7px;width:78%;background:#dce9e4;border-radius:8px;margin-bottom:12px}.paper-line.wide{width:100%;background:#9ac9b6}.paper-choice{display:flex;gap:10px;align-items:center;margin:15px 0}.paper-choice b{width:18px;height:18px;border:1px solid #c9d9d2;border-radius:50%}.paper-choice:first-of-type b{background:var(--primary);border-color:var(--primary)}.paper-choice i{height:6px;width:75px;background:#e5ece9;border-radius:5px}.paper-stamp{position:absolute;bottom:-12px;left:-22px;background:#f6d88d;color:#644b19;padding:5px 18px;border-radius:9px;font-weight:800;transform:rotate(-9deg)}.stats{display:grid;grid-template-columns:repeat(3,1fr);gap:16px;margin:24px 0}.stat-card,.panel{background:var(--paper);border:1px solid var(--line);border-radius:20px;padding:24px;box-shadow:var(--shadow)}.stat-card span,.stat-card small{display:block;color:var(--muted)}.stat-card strong{display:block;font-size:1.6rem;margin:5px 0}.stat-card small{font-size:.8rem}.feature{display:flex;align-items:center;justify-content:space-between;gap:24px;padding:28px 6px}.feature h2,.panel h2{margin:5px 0 10px}.page-heading{margin:8px 0 26px}.page-heading h1{font-size:2rem;margin:5px 0}.bank-layout{display:grid;grid-template-columns:1fr 1fr;gap:20px}.panel h2{font-size:1.15rem}.filter-form,.create-form{display:grid;gap:16px}.filter-form label,.create-form label{display:grid;gap:6px;font-size:.9rem;font-weight:600}select,input[type=number]{width:100%;font:inherit;background:#fbfdfc;border:1px solid #d8e4df;border-radius:10px;padding:11px 12px;color:var(--ink);outline:none}select:focus,input:focus{border-color:var(--primary);box-shadow:0 0 0 3px #146c5b18}.full{width:100%;margin-top:6px}.match-count{margin-top:20px;padding:12px;border-radius:12px;background:#f1f8f4;color:var(--muted);display:flex;justify-content:space-between}.match-count strong{color:var(--primary)}.hint{font-size:.83rem;color:var(--muted)}.quiz-top{display:flex;justify-content:space-between;align-items:center;margin-bottom:14px;color:var(--muted)}.progress{height:7px;background:#e1eae5;border-radius:20px;overflow:hidden;margin-bottom:22px}.progress span{display:block;height:100%;background:var(--primary);border-radius:20px}.question-panel{max-width:820px;margin:0 auto;padding:clamp(22px,5vw,44px)}.tags{display:flex;flex-wrap:wrap;gap:8px;margin-bottom:22px}.tags span{background:var(--mint);color:var(--primary);border-radius:30px;padding:3px 12px;font-size:.78rem}.question-text{font-size:1.35rem;line-height:2;margin:0 0 25px}.answer-form{display:grid;gap:12px}.answer-option{display:flex;align-items:center;gap:12px;border:1px solid var(--line);padding:12px 14px;border-radius:13px;cursor:pointer}.answer-option:hover{border-color:#9ccdb9;background:#f8fcfa}.answer-option input{accent-color:var(--primary)}.option-number{display:grid;place-items:center;width:32px;height:32px;border-radius:10px;background:#eef4f1;font-weight:700}.feedback{padding:18px;border-radius:14px;margin-top:20px}.feedback p{margin:7px 0}.success{background:#e7f7ee;color:#145a3a}.error{background:#fff0f1;color:#8e2635}.result-hero{text-align:center;padding:35px 10px 45px}.result-hero h1{font-size:1.9rem}.score-ring{width:170px;height:170px;margin:24px auto;display:flex;flex-direction:column;align-items:center;justify-content:center;border:10px solid #d6eee2;border-right-color:var(--primary);border-radius:50%}.score-ring strong{font-size:2rem;color:var(--primary)}.score-ring span{font-size:.78rem;color:var(--muted)}.weak-list{display:grid;gap:10px}.weak-list div{display:flex;justify-content:space-between;gap:12px;padding:12px 14px;border-radius:12px;background:#f6f9f7}.weak-list b{font-size:.85rem;color:var(--danger)}.review{margin-top:35px}.review-item{margin:14px 0}.review-item h3{font-size:1rem;line-height:2}.success-text{color:#167447}.error-text{color:var(--danger)}.explanation{padding:12px 15px;border-right:3px solid #9ac9b6;background:#f5faf7;border-radius:8px}.messages{margin-bottom:18px}.message{padding:12px 16px;border-radius:10px;background:#fff0f1;color:#8e2635}footer{text-align:center;padding:25px;color:#84938c;font-size:.82rem;border-top:1px solid var(--line)}@media(max-width:760px){.topbar{padding:0 18px;height:68px}nav{gap:12px}nav a{font-size:.8rem}.container{padding:22px 16px 40px}.hero{grid-template-columns:1fr;padding:30px 24px}.hero-art{height:230px}.orbit{width:220px;height:220px}.orbit-two{width:180px;height:180px}.paper{transform:scale(.85) rotate(-5deg)}.stats{gap:8px}.stat-card{padding:14px}.stat-card strong{font-size:1.15rem}.stat-card span,.stat-card small{font-size:.75rem}.bank-layout{grid-template-columns:1fr}.feature{align-items:flex-start;flex-direction:column}.page-heading h1{font-size:1.6rem}.question-text{font-size:1.12rem}.quiz-top{font-size:.82rem}}

/* Safe HTML fragments from the question editor */
.question-text,.review-question{white-space:pre-line;overflow-wrap:anywhere}.question-text img,.review-question img,.explanation img,.feedback img{max-width:100%;height:auto;border-radius:10px;display:block;margin:14px auto}.question-text table,.review-question table{border-collapse:collapse;max-width:100%}.question-text td,.question-text th,.review-question td,.review-question th{border:1px solid var(--line);padding:6px 10px}.practice-form{display:flex;align-items:end;gap:12px;flex-wrap:wrap;margin:20px 0 8px}.practice-form label{display:grid;gap:6px;font-weight:700}.practice-form select{min-width:150px}.section-title-row{display:flex;align-items:start;justify-content:space-between}.review-question{line-height:2}.error-page{max-width:620px;margin:40px auto;text-align:center;padding:42px}.error-page h1{font-size:1.8rem}.error-code{display:inline-block;font-size:2.5rem;font-weight:900;color:var(--primary);background:var(--mint);padding:4px 20px;border-radius:14px}.message.info{background:#eff6ff;color:#1d4ed8}.message.warning{background:#fff7ed;color:#9a3412}.message.success{background:#ecfdf5;color:#047857}


/* Committee logo, local LaTeX rendering and question feedback */
.brand{gap:9px}.brand-logo{width:46px;height:46px;object-fit:contain;border-radius:9px;background:#fff}.hero-logo{display:block;width:min(100%,350px);height:auto;max-height:350px;object-fit:contain;border-radius:22px;filter:drop-shadow(0 12px 24px rgba(12,55,105,.08))}.hero-art{min-width:0}.quiz-privacy-note{margin:14px 0 0}.option-copy{min-width:0;overflow-wrap:anywhere}.answer-option:has(input:checked){border-color:var(--primary);background:#f1faf5}.question-feedback{margin-top:28px;padding:18px;border:1px solid var(--line);border-radius:16px;background:#fbfdfc}.feedback-title{display:flex;flex-direction:column;gap:2px}.feedback-buttons{display:flex;gap:10px;flex-wrap:wrap;margin-top:13px}.reaction-button{display:inline-flex;gap:8px;align-items:center;justify-content:center;border:1px solid var(--line);background:#fff;color:var(--ink);padding:9px 14px;border-radius:12px;font:inherit;font-size:.9rem;cursor:pointer}.reaction-button b{min-width:1.4em;color:var(--muted)}.reaction-button:hover,.reaction-button.is-active{border-color:var(--primary);background:var(--mint);color:var(--primary)}.reaction-button:disabled{opacity:.6;cursor:wait}.feedback-status{min-height:1.6em;margin:8px 0 0;color:var(--primary);font-size:.85rem}.feedback-dialog{width:min(520px,calc(100% - 24px));max-height:min(82vh,650px);overflow:auto;border:1px solid var(--line);border-radius:18px;padding:24px;color:var(--ink);box-shadow:0 24px 80px #0f172a44}.feedback-dialog::backdrop{background:rgba(15,23,42,.45)}.feedback-dialog h3{margin:0 0 16px;font-size:1.1rem}.feedback-dialog-form>label:not(.feedback-details-label){display:flex;align-items:center;gap:10px;padding:9px 5px;border-bottom:1px solid #edf2ef}.feedback-dialog input[type=radio]{accent-color:var(--primary);width:18px;height:18px;flex:none}.feedback-details-label{display:none;gap:8px;margin-top:13px;font-weight:700}.feedback-details-label.is-visible{display:grid}.feedback-details-label textarea{width:100%;resize:vertical;min-height:82px;border:1px solid #d8e4df;border-radius:10px;padding:10px;font:inherit}.feedback-dialog-actions{display:flex;gap:9px;justify-content:flex-end;flex-wrap:wrap;margin-top:20px}.mjx-container{max-width:100%}.mjx-container[display="true"]{max-width:100%;overflow-x:auto;overflow-y:hidden;padding:2px 0}.question-text,.review-question{overflow-wrap:anywhere}.question-text table,.review-question table{display:block;overflow-x:auto}
@media(max-width:520px){.topbar{height:auto;min-height:66px;flex-wrap:wrap;gap:6px;padding:8px 12px}.brand{font-size:1rem}.brand-logo{width:42px;height:42px}nav{width:100%;justify-content:space-around;gap:8px;padding-bottom:3px}nav a{font-size:.82rem}.container{padding:18px 12px 30px}.hero{padding:24px 17px;gap:14px;border-radius:20px}.hero-art{height:auto;min-height:180px}.hero-logo{width:min(100%,250px);max-height:250px;margin:0 auto}.stats{grid-template-columns:1fr;gap:10px}.stat-card{padding:15px 18px}.stat-card strong{font-size:1.35rem}.question-panel{padding:18px 14px}.question-text{font-size:1.08rem}.answer-option{align-items:flex-start;padding:11px 10px;gap:8px}.option-number{width:30px;height:30px;flex:none}.feedback-buttons{display:grid;grid-template-columns:1fr 1fr}.reaction-button{padding:9px 7px;font-size:.82rem}.feedback-dialog{padding:18px}.feedback-dialog-actions .button{flex:1}.quiz-top{gap:8px;flex-wrap:wrap}.page-heading h1{font-size:1.45rem}}

/* Hard limits for the committee logo, even if other image styles exist */
.topbar .brand-logo{width:44px!important;height:44px!important;max-width:44px!important;max-height:44px!important;object-fit:contain!important;flex:0 0 44px!important}
.hero-art{width:100%;min-width:0;max-width:100%;overflow:hidden}
.hero-art .hero-logo{display:block!important;width:100%!important;max-width:280px!important;height:auto!important;max-height:280px!important;object-fit:contain!important;margin:0 auto!important}
@media(max-width:760px){.hero-art .hero-logo{max-width:210px!important;max-height:210px!important}}
html,body{max-width:100%;overflow-x:hidden}

/* Accounts, timed quizzes, feedback and leaderboard */
.auth-panel{max-width:560px;margin:0 auto}.auth-tabs{display:flex;gap:10px;margin-bottom:20px}.auth-tabs .button{flex:1}.auth-panel .create-form input{font:inherit;padding:11px 12px;border:1px solid var(--line);border-radius:10px;background:#fbfdfc}.auth-panel .create-form label{display:grid;gap:6px}.timer-box{background:#fff4e5;color:#9a4d00;padding:6px 12px;border-radius:10px;white-space:nowrap}.timer-box span{font-variant-numeric:tabular-nums}.timer-box .timer-danger,.timer-danger{color:#b42318!important;animation:timer-pulse .8s infinite alternate}.quiz-total-time{margin:-8px 0 12px;color:var(--muted);font-size:.86rem}.quiz-actions{display:flex;justify-content:space-between;gap:12px;margin-top:8px}.quiz-actions button{flex:1}.table-wrap{width:100%;overflow-x:auto}table{width:100%;border-collapse:collapse}th,td{text-align:right;padding:12px 14px;border-bottom:1px solid var(--line)}th{background:#f5faf7;color:var(--primary)}.highlight-row{background:#e8f7ef;font-weight:700}.my-rank{display:flex;justify-content:space-between;gap:12px;flex-wrap:wrap;margin-bottom:18px;background:var(--mint)}.earned-points{font-size:1rem;color:var(--primary);font-weight:700}.earned-points strong{font-size:1.25rem}@keyframes timer-pulse{from{opacity:1}to{opacity:.55}}@media(max-width:520px){.quiz-actions{flex-direction:column-reverse}.quiz-top{align-items:flex-start}.timer-box{font-size:.85rem}.my-rank{flex-direction:column}}

/* Refined account sign-in and registration experience */
.auth-panel{position:relative;overflow:hidden;max-width:650px;margin:0 auto 42px;border-radius:24px;border:1px solid #dbe8ed;box-shadow:0 20px 55px rgba(20,50,75,.10);padding:clamp(22px,4vw,38px);background:radial-gradient(circle at 100% 0,rgba(20,184,166,.09),transparent 30%),#fff}
.auth-panel:before{content:"حساب کاربری شما، مسیر پیشرفت شما";display:block;margin:-38px calc(clamp(22px,4vw,38px) * -1) 25px;padding:26px clamp(22px,4vw,38px);background:linear-gradient(120deg,#0f766e,#155e75 60%,#344e78);color:#fff;font-weight:900;font-size:clamp(18px,2.5vw,25px);line-height:1.8}
.auth-tabs{display:flex;gap:10px;margin-bottom:22px}.auth-tabs .button{flex:1;text-align:center;border-radius:12px;padding:11px}
.create-form{display:grid;gap:17px}.create-form label{display:grid;gap:8px;font-weight:800;color:#28465a}.create-form input{box-sizing:border-box;width:100%;padding:13px 14px;border:1px solid #d7e4eb;border-radius:12px;background:#f9fcfd;font:inherit;transition:border-color .18s,box-shadow .18s}.create-form input:focus{outline:none;border-color:#159a8c;box-shadow:0 0 0 4px rgba(21,154,140,.12)}.create-form .button{border-radius:12px;padding:13px;font-weight:900}.auth-panel .hint{margin-top:18px;padding:12px 14px;background:#f1f8f7;border-radius:12px;line-height:1.9}

/* Examyar — premium macOS-inspired visual system */
:root{--ink:#172033;--muted:#697386;--primary:#356df3;--primary-dark:#2457d6;--mint:#eaf0ff;--paper:rgba(255,255,255,.88);--bg:#f3f5fa;--line:rgba(121,136,163,.19);--gold:#f3c96b;--danger:#c43e57;--shadow:0 14px 42px rgba(32,48,82,.075)}
body{background:radial-gradient(ellipse at 8% 0%,rgba(93,130,255,.10),transparent 35%),radial-gradient(ellipse at 94% 12%,rgba(159,115,255,.08),transparent 32%),#f4f6fb;color:var(--ink);letter-spacing:-.012em}
.topbar{height:78px;position:sticky;top:0;z-index:20;background:rgba(250,251,255,.78);backdrop-filter:blur(24px) saturate(170%);-webkit-backdrop-filter:blur(24px) saturate(170%);border-bottom:1px solid rgba(143,155,180,.2);box-shadow:0 4px 24px rgba(27,39,70,.025)}
.brand{font-size:1.18rem;gap:12px}.brand-icon{width:42px;height:42px;border-radius:14px;background:linear-gradient(145deg,#4d83ff,#3159db);box-shadow:0 7px 18px #356df32e}.brand-logo{width:44px;height:44px;border-radius:13px;box-shadow:0 4px 14px #1b2d5010}
nav{gap:8px;align-items:center}nav a{padding:9px 13px;border-radius:11px;transition:background .18s,color .18s}nav a:hover{background:#eaf0ff;color:#2457d6}
.container{max-width:1220px;padding-top:42px}.hero{position:relative;background:linear-gradient(125deg,rgba(255,255,255,.96),rgba(237,242,255,.94));border:1px solid rgba(255,255,255,.95);border-radius:32px;padding:clamp(32px,5vw,64px);box-shadow:0 24px 80px rgba(42,64,115,.09),inset 0 1px rgba(255,255,255,.95)}.hero:after{content:"";position:absolute;inset:0;border-radius:inherit;pointer-events:none;background:linear-gradient(110deg,transparent 45%,rgba(255,255,255,.5));opacity:.5}.hero-copy,.hero-art{z-index:1}.eyebrow{display:inline-flex;align-items:center;gap:8px;padding:6px 11px;border-radius:30px;background:#eaf0ff;color:#315ed5;font-size:.78rem}.hero h1{letter-spacing:-.045em;font-size:clamp(2.25rem,4.3vw,3.65rem);line-height:1.42}.hero h1 span{color:#356df3}.hero p,.page-heading p,.feature p,.create-panel p{line-height:2.05;color:#6b7488}
.button{border-radius:13px;padding:12px 20px;transition:transform .2s,box-shadow .2s,background .2s;border:1px solid transparent}.button:hover{transform:translateY(-2px);box-shadow:0 9px 22px rgba(40,68,130,.13)}.primary{background:linear-gradient(135deg,#477fff,#315fe4);color:white;box-shadow:0 7px 16px rgba(53,109,243,.18)}.primary:hover{background:linear-gradient(135deg,#356ff1,#244fc9)}.secondary{background:#edf2ff;color:#315ed5;border-color:#e2e9ff}.secondary:hover{background:#e3eaff}
.stats{gap:18px;margin:28px 0}.stat-card,.panel{background:rgba(255,255,255,.86);backdrop-filter:blur(16px);-webkit-backdrop-filter:blur(16px);border:1px solid rgba(255,255,255,.96);border-radius:22px;padding:25px;box-shadow:0 12px 34px rgba(39,54,89,.055),0 1px 3px rgba(35,50,80,.035)}.stat-card strong{font-size:1.85rem;letter-spacing:-.04em;color:#243a69}.stat-card span{font-weight:600}.feature{padding:34px 8px}.feature h2,.panel h2{letter-spacing:-.025em}.page-heading{margin-bottom:30px}.page-heading h1{letter-spacing:-.04em;font-size:2.25rem}.bank-layout{gap:22px}.filter-form,.create-form{gap:18px}.filter-form label,.create-form label{gap:8px;color:#3e4960}select,input[type=number],input:not([type=checkbox]):not([type=radio]):not([type=submit]),textarea{border:1px solid #dfe5f0;background:rgba(249,250,254,.92);border-radius:12px;padding:12px 14px;transition:border-color .18s,box-shadow .18s,background .18s}select:focus,input:focus,textarea:focus{border-color:#7ca0ff;box-shadow:0 0 0 4px rgba(67,113,241,.12);background:#fff;outline:none}.match-count{background:#f0f4ff;color:#697386;border:1px solid #e5ebff}.match-count strong{color:#315ed5}.question-panel{border-radius:26px}.progress{height:8px;background:#e5eaf4}.progress span{background:linear-gradient(90deg,#7097ff,#356df3)}.tags span{background:#edf2ff;color:#315ed5}.answer-option{border:1px solid #e1e6f0;border-radius:15px;padding:14px 16px;background:rgba(255,255,255,.7);transition:border-color .18s,background .18s,transform .18s}.answer-option:hover{border-color:#a6bbff;background:#f6f8ff;transform:translateY(-1px)}.answer-option:has(input:checked){border-color:#6e94ff;background:#edf2ff;box-shadow:0 0 0 3px #356df30c}.option-number{background:#edf1f8;color:#53617c;border-radius:10px}.answer-option:has(input:checked) .option-number{background:#356df3;color:#fff}.question-feedback{background:#f8faff;border-color:#e2e9f8}.reaction-button{border-radius:12px}.score-ring{border-color:#dce7ff;border-right-color:#356df3}.score-ring strong{color:#315ed5}.explanation{background:#f6f8ff;border-right-color:#7195ff}footer{background:rgba(255,255,255,.35);border-color:rgba(121,136,163,.16);margin-top:20px}
.auth-panel{max-width:560px;margin:44px auto;padding:clamp(24px,4vw,42px);border-radius:28px;background:rgba(255,255,255,.9);border:1px solid rgba(255,255,255,.98);box-shadow:0 24px 80px rgba(35,54,98,.1)}.auth-tabs{display:flex;gap:8px;padding:5px;background:#f0f3fa;border-radius:14px}.auth-tabs a,.auth-tabs button{flex:1;border-radius:10px}.login-subtitle{color:var(--muted)}
@media(max-width:760px){.topbar{height:auto;min-height:68px;padding:10px 16px;gap:12px}.container{padding:24px 16px 40px}.hero{border-radius:24px;padding:28px 22px}.stats{gap:10px}.stat-card{padding:15px}.panel{padding:20px}.page-heading h1{font-size:1.8rem}nav{flex-wrap:wrap;justify-content:flex-end}}

/* -------------------------------------------------------------------------
   Examyar visual refinement — presentation-only overrides
   Keep all application markup and behavior unchanged.
   ------------------------------------------------------------------------- */
:root{
  --ink:#17233b;
  --muted:#68758d;
  --primary:#4268e8;
  --primary-dark:#294fca;
  --mint:#edf2ff;
  --paper:#ffffff;
  --bg:#f5f7fc;
  --line:#e3e8f2;
  --gold:#f1c76d;
  --danger:#bd3c55;
  --shadow:0 16px 42px rgba(33,49,89,.065);
  --shadow-hover:0 22px 54px rgba(33,49,89,.105);
  --radius-card:22px;
}
html{scroll-behavior:smooth;scroll-padding-top:100px}
body{
  min-height:100vh;
  background:
    radial-gradient(ellipse at 3% 0%,rgba(95,132,255,.105),transparent 32rem),
    radial-gradient(ellipse at 98% 15%,rgba(169,126,255,.075),transparent 30rem),
    linear-gradient(180deg,#f8f9fd 0%,#f3f6fc 60%,#f7f8fc 100%);
  color:var(--ink);
  font-feature-settings:"kern";
  -webkit-font-smoothing:antialiased;
  text-rendering:optimizeLegibility;
}
::selection{background:rgba(74,111,235,.18);color:#15284c}
a{transition:color .18s ease}
a:focus-visible,button:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible,summary:focus-visible{
  outline:3px solid rgba(66,104,232,.32);outline-offset:3px
}
.topbar{
  min-height:78px;height:auto;gap:22px;
  padding:12px max(calc((100% - 1220px)/2),clamp(16px,3vw,42px));
  background:rgba(250,251,255,.82);
  border-bottom:1px solid rgba(155,168,194,.24);
  box-shadow:0 5px 26px rgba(32,47,82,.035);
  backdrop-filter:blur(24px) saturate(165%);
  -webkit-backdrop-filter:blur(24px) saturate(165%);
}
.brand{flex-shrink:0;gap:12px;font-size:1.13rem;letter-spacing:-.025em}
.brand-logo{width:46px;height:46px;max-width:46px;max-height:46px;flex:0 0 46px;object-fit:contain;border-radius:14px;background:#fff;border:1px solid rgba(226,232,243,.9);box-shadow:0 5px 16px rgba(31,49,91,.08)}
nav{gap:5px;align-items:center}
nav a,.back-link{display:inline-flex;align-items:center;justify-content:center;min-height:40px;padding:8px 12px;border-radius:12px;color:#61708a;text-decoration:none;white-space:nowrap;font-size:.88rem;transition:background .18s ease,color .18s ease,transform .18s ease}
nav a:hover,.back-link:hover{background:#edf1ff;color:#2d55d1;transform:translateY(-1px)}
.container{max-width:1220px;padding:clamp(24px,4vw,48px) clamp(16px,3vw,30px) 64px}
.hero{
  isolation:isolate;position:relative;grid-template-columns:minmax(0,1.08fr) minmax(260px,.92fr);
  gap:clamp(24px,4vw,56px);min-height:390px;
  padding:clamp(30px,5vw,66px);
  border:1px solid rgba(255,255,255,.95);border-radius:32px;
  background:linear-gradient(126deg,rgba(255,255,255,.98) 5%,rgba(241,245,255,.97) 61%,rgba(246,242,255,.96) 100%);
  box-shadow:0 25px 75px rgba(37,54,101,.085),inset 0 1px rgba(255,255,255,.98);
}
.hero:before{content:"";position:absolute;z-index:-1;inset:auto auto -100px -90px;width:280px;height:280px;border-radius:50%;background:radial-gradient(circle,rgba(95,129,247,.12),transparent 70%);pointer-events:none}
.hero:after{content:"";position:absolute;inset:0;border-radius:inherit;pointer-events:none;z-index:0;background:linear-gradient(115deg,transparent 36%,rgba(255,255,255,.38) 72%,transparent 100%)}
.hero-copy,.hero-art{position:relative;z-index:1;min-width:0}
.eyebrow{display:inline-flex;align-items:center;gap:8px;padding:6px 12px;border:1px solid rgba(92,121,224,.12);border-radius:999px;background:linear-gradient(135deg,#edf2ff,#f4f0ff);color:#355bd0;font-size:.79rem;font-weight:800;letter-spacing:0}
.hero h1{margin:17px 0;font-size:clamp(2.15rem,4.2vw,3.55rem);line-height:1.42;letter-spacing:-.045em;color:#1b2945}
.hero h1 span{color:#4268e8;background:linear-gradient(110deg,#477bfa,#6958db);-webkit-background-clip:text;background-clip:text;-webkit-text-fill-color:transparent}
.hero p,.page-heading p,.feature p,.create-panel p{max-width:630px;color:#68758d;line-height:2.05}
.hero .button{margin-top:8px}
.hero-art{min-width:0;display:grid;place-items:center}
.hero-logo{filter:drop-shadow(0 18px 26px rgba(28,47,94,.13));transition:transform .3s ease,filter .3s ease}
.hero-logo:hover{transform:translateY(-3px);filter:drop-shadow(0 22px 30px rgba(28,47,94,.17))}
.button{min-height:44px;display:inline-flex;align-items:center;justify-content:center;gap:9px;padding:11px 19px;border:1px solid transparent;border-radius:13px;font:inherit;font-size:.91rem;font-weight:800;line-height:1.5;text-decoration:none;cursor:pointer;transition:transform .18s ease,box-shadow .18s ease,background .18s ease,border-color .18s ease,color .18s ease}
.button:hover{transform:translateY(-2px);box-shadow:0 9px 22px rgba(40,62,126,.12)}
.button:active{transform:translateY(0)}
.button:disabled{opacity:.48;box-shadow:none;transform:none;cursor:not-allowed}
.button.primary,.primary{background:linear-gradient(135deg,#527eff 0%,#365fe0 100%);color:#fff;box-shadow:0 7px 18px rgba(61,99,226,.2)}
.button.primary:hover,.primary:hover{background:linear-gradient(135deg,#416ff1,#294fc9);box-shadow:0 10px 24px rgba(61,99,226,.24)}
.button.secondary,.secondary{background:linear-gradient(135deg,#f2f5ff,#edf1ff);color:#3458cb;border:1px solid #e1e8ff}
.button.secondary:hover,.secondary:hover{background:#e8eeff;border-color:#d5dfff}
.button.danger-button,.danger-button{background:#fff1f3;color:#b8324b;border:1px solid #f9d9df}
.button.danger-button:hover,.danger-button:hover{background:#ffe7ec;border-color:#f4c3ce}
.stats{gap:17px;margin:25px 0 30px}
.stat-card,.panel{
  min-width:0;background:rgba(255,255,255,.91);backdrop-filter:blur(14px);-webkit-backdrop-filter:blur(14px);
  border:1px solid rgba(222,228,241,.92);border-radius:var(--radius-card);padding:clamp(19px,2.2vw,27px);
  box-shadow:0 10px 30px rgba(39,54,89,.045),0 1px 3px rgba(35,50,80,.025);
  transition:box-shadow .2s ease,border-color .2s ease,transform .2s ease;
}
.stat-card:hover{transform:translateY(-2px);border-color:#dbe3fa;box-shadow:0 16px 34px rgba(39,54,89,.075)}
.stat-card span,.stat-card small{color:var(--muted);line-height:1.8}
.stat-card span{font-size:.9rem;font-weight:700}
.stat-card strong{font-size:clamp(1.35rem,2.2vw,1.9rem);line-height:1.55;letter-spacing:-.04em;color:#263a70;overflow-wrap:anywhere}
.stat-card a{color:#365fe0;text-decoration:none;font-weight:700}
.stat-card a:hover{text-decoration:underline;text-underline-offset:3px}
.feature{position:relative;gap:24px;margin:28px 0;padding:29px clamp(8px,2vw,24px);border-block:1px solid rgba(219,226,241,.7)}
.feature h2,.panel h2{color:#202f4b;letter-spacing:-.028em;line-height:1.6}
.feature p{margin:5px 0;max-width:720px}
.page-heading{margin:6px 0 29px}
.page-heading h1{margin:10px 0;font-size:clamp(1.65rem,3vw,2.3rem);line-height:1.55;letter-spacing:-.04em;color:#1c2b49}
.page-heading p{margin:4px 0}
.bank-layout{grid-template-columns:repeat(2,minmax(0,1fr));gap:22px;align-items:start}
.panel h2{font-size:1.13rem;margin:0 0 15px}
.filter-form,.create-form{gap:17px}
.filter-form label,.create-form label{gap:8px;color:#3d4962;font-weight:750}
select,input[type=number],input:not([type=checkbox]):not([type=radio]):not([type=submit]):not([type=hidden]),textarea{
  max-width:100%;width:100%;min-height:45px;padding:11px 14px;border:1px solid #dfe5f1;border-radius:12px;
  background:rgba(249,250,254,.96);color:#1b2945;font:inherit;line-height:1.6;box-shadow:inset 0 1px 1px rgba(25,42,75,.015);
  transition:border-color .18s ease,box-shadow .18s ease,background .18s ease;
}
textarea{min-height:100px;resize:vertical}
select:focus,input:focus,textarea:focus{outline:none;border-color:#8ba5ff;box-shadow:0 0 0 4px rgba(67,104,232,.12);background:#fff}
input[type=checkbox],input[type=radio]{accent-color:#4268e8}
.match-count{margin-top:20px;padding:13px 15px;border:1px solid #e2e9ff;border-radius:13px;background:linear-gradient(120deg,#f3f6ff,#f6f4ff);color:#6a7690}
.match-count strong{color:#365bd2}
.hint{color:#778198;font-size:.84rem;line-height:1.95}
.quiz-top{gap:14px;flex-wrap:wrap;padding:0 2px;color:#6a7690;font-size:.9rem}
.quiz-top>*{min-width:0}
.timer-box,.quiz-total-time{padding:7px 12px;border:1px solid #e2e8fa;border-radius:12px;background:rgba(255,255,255,.78);color:#4159a1;font-weight:800}
.progress{height:8px;margin:12px 0 23px;background:#e7ebf5;border-radius:999px;box-shadow:inset 0 1px 2px rgba(27,44,76,.045)}
.progress span{background:linear-gradient(90deg,#82a3ff,#4469e8 65%,#6958dc);box-shadow:0 0 10px rgba(66,104,232,.18)}
.question-panel{max-width:860px;padding:clamp(22px,4vw,44px);border-radius:27px}
.tags{gap:8px;margin-bottom:20px}
.tags span{padding:5px 11px;border:1px solid #e1e8ff;background:linear-gradient(135deg,#eef2ff,#f5f1ff);color:#3d5dc9;border-radius:999px;font-size:.78rem;font-weight:700}
.question-text,.review-question{font-size:clamp(1.06rem,1.9vw,1.3rem);line-height:2.05;overflow-wrap:anywhere}
.answer-form{gap:12px}
.answer-option{min-width:0;gap:13px;padding:13px 15px;border:1px solid #e1e6f1;border-radius:15px;background:rgba(255,255,255,.86);transition:border-color .18s ease,background .18s ease,transform .18s ease,box-shadow .18s ease}
.answer-option:hover{border-color:#b7c7ff;background:#f7f9ff;transform:translateY(-1px)}
.answer-option:has(input:checked){border-color:#7895f8;background:linear-gradient(120deg,#eef3ff,#f7f5ff);box-shadow:0 0 0 3px rgba(66,104,232,.065)}
.option-number{flex:0 0 32px;background:#eef1f8;color:#53617c;border:1px solid #e5e9f2;border-radius:10px}
.answer-option:has(input:checked) .option-number{background:#4268e8;border-color:#4268e8;color:#fff}
.option-copy{min-width:0;overflow-wrap:anywhere}
.quiz-actions{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin-top:20px}
.quiz-privacy-note{padding:10px 13px;border-radius:12px;background:#f7f8fc}
.feedback{border:1px solid transparent;line-height:1.9}
.feedback p{overflow-wrap:anywhere}
.success{background:#edf9f2;color:#176342;border-color:#d8f0e1}
.error{background:#fff0f2;color:#9f2b41;border-color:#f8dce2}
.messages{display:grid;gap:10px;margin:0 0 20px}
.message{padding:13px 16px;border:1px solid #f1dce2;border-radius:13px;background:#fff2f4;color:#a42d46;line-height:1.9}
.message.info{background:#eff5ff;color:#2856af;border-color:#dce8ff}
.message.warning{background:#fff7e9;color:#925c10;border-color:#f8e5bc}
.message.success{background:#edfaf2;color:#176b43;border-color:#d9f2e3}
.result-hero{padding:30px 12px 42px}
.result-hero h1{font-size:clamp(1.6rem,3vw,2.15rem);letter-spacing:-.035em;color:#1b2b49}
.score-ring{width:174px;height:174px;border:11px solid #e4eaff;border-top-color:#8daaff;border-right-color:#4268e8;background:rgba(255,255,255,.62);box-shadow:0 12px 30px rgba(57,85,169,.07)}
.score-ring strong{color:#345bd3;font-size:2.2rem;line-height:1.5}
.earned-points{display:inline-flex;align-items:center;justify-content:center;margin:8px auto;padding:9px 15px;border-radius:999px;background:#edf9f2;border:1px solid #d9f0e3;color:#176b43;font-weight:800}
.weak-panel{margin:20px 0}
.weak-list{gap:10px}
.weak-list div{gap:12px;padding:13px 15px;border:1px solid #e8ebf3;border-radius:13px;background:#fafbfe}
.weak-list b{color:#b7354d}
.review{margin-top:38px}
.review-item{margin:15px 0;padding:clamp(17px,2.5vw,24px);border:1px solid #e5e9f2;border-radius:18px;background:rgba(255,255,255,.88);box-shadow:0 7px 24px rgba(34,50,88,.035)}
.review-item h3{font-size:1.02rem;line-height:2;color:#253553}
.success-text{color:#18734b}
.error-text{color:#b7354d}
.explanation{padding:14px 16px;border:1px solid #e3e9ff;border-right:4px solid #7895f8;border-radius:12px;background:#f6f8ff;line-height:2;overflow-wrap:anywhere}
.explanation img,.feedback img,.question-text img,.review-question img{max-width:100%;height:auto}
.question-feedback{margin-top:24px;padding:19px;border:1px solid #e4e9f6;border-radius:18px;background:linear-gradient(145deg,#fafbff,#f5f7ff)}
.feedback-title{gap:3px}
.feedback-buttons{gap:8px}
.reaction-button{min-height:40px;border:1px solid #dfe5f1;border-radius:12px;background:#fff;transition:background .18s,border-color .18s,color .18s,transform .18s}
.reaction-button:hover,.reaction-button.is-active{background:#edf2ff;border-color:#b9c9ff;color:#2f56cf}
.reaction-button:hover{transform:translateY(-1px)}
.feedback-status{color:#3b5fd3}
.feedback-dialog{border:1px solid #e0e6f3;border-radius:22px;background:rgba(255,255,255,.98);box-shadow:0 30px 100px rgba(18,31,61,.25)}
.feedback-dialog::backdrop{background:rgba(20,31,57,.42);backdrop-filter:blur(5px)}
.auth-panel{max-width:570px;margin:32px auto;padding:clamp(23px,4vw,42px);border:1px solid rgba(224,230,243,.95);border-radius:26px;background:rgba(255,255,255,.94);box-shadow:0 20px 64px rgba(35,54,98,.085)}
.auth-tabs{gap:8px;margin-bottom:23px;padding:5px;border:1px solid #e6eaf4;border-radius:15px;background:#f3f5fb}
.auth-tabs a,.auth-tabs button{min-height:42px}
.table-wrap{width:100%;overflow:auto;border:1px solid #e1e6f0;border-radius:17px;background:rgba(255,255,255,.94);box-shadow:0 10px 30px rgba(37,52,88,.04)}
table{width:100%;border-collapse:collapse}
th,td{text-align:right;vertical-align:top;padding:13px 15px;border-bottom:1px solid #edf0f6;line-height:1.9}
th{background:#f3f5fc;color:#3f5078;font-size:.86rem;font-weight:800;white-space:nowrap}
tbody tr:last-child td{border-bottom:0}
tbody tr:hover td{background:#f9faff}
.highlight-row td{background:#f0f4ff!important;color:#294fbe;font-weight:700}
.my-rank{margin:0 0 18px;padding:15px 18px;border:1px solid #dfe7ff;border-radius:15px;background:linear-gradient(120deg,#edf3ff,#f7f4ff);color:#334e9d}
.my-rank strong,.my-rank b{color:#315bd6}
.practice-form{gap:10px;padding:15px;border:1px solid #e5e9f3;border-radius:16px;background:#fafbfe}
.practice-form label{gap:7px;color:#43506b}
.practice-form select{min-width:170px}
.error-page{border:1px solid #e2e7f2;border-radius:24px;background:rgba(255,255,255,.9);box-shadow:var(--shadow)}
.error-code{background:#edf2ff;color:#365fe0}
footer{margin-top:24px;padding:28px 18px;border-top:1px solid rgba(146,158,184,.2);background:rgba(255,255,255,.42);color:#7a859a}
footer a{color:#526ed0;text-decoration:none}
footer a:hover{text-decoration:underline;text-underline-offset:3px}
@media(max-width:980px){
  .topbar{padding-inline:20px;gap:12px}
  nav{gap:2px}
  nav a{padding-inline:9px;font-size:.83rem}
  .hero{gap:28px;padding:clamp(28px,4vw,44px)}
  .bank-layout{gap:16px}
}
@media(max-width:760px){
  .topbar{position:sticky;top:0;z-index:30;display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:8px;padding:9px 15px 8px}
  .brand{font-size:1rem;gap:9px}
  .brand-logo{width:40px;height:40px;max-width:40px;max-height:40px;flex-basis:40px}
  nav{width:100%;max-width:100%;display:flex;flex-wrap:nowrap;justify-content:flex-start;gap:5px;overflow-x:auto;overscroll-behavior-inline:contain;padding:2px 0 4px;scrollbar-width:none}
  nav::-webkit-scrollbar{display:none}
  nav a{flex:0 0 auto;min-height:36px;padding:6px 10px;background:rgba(240,243,252,.6);font-size:.79rem}
  .container{padding:23px 15px 42px}
  .hero{grid-template-columns:minmax(0,1fr);gap:18px;padding:29px 22px;border-radius:25px;min-height:0}
  .hero-copy{order:1}.hero-art{order:0;max-height:210px}
  .hero-art .hero-logo{max-width:190px!important;max-height:190px!important}
  .hero h1{font-size:clamp(2rem,7vw,2.8rem);line-height:1.4;margin:12px 0}
  .hero p{font-size:.94rem;margin:8px 0 12px}
  .stats{grid-template-columns:repeat(3,minmax(0,1fr));gap:9px;margin:18px 0 24px}
  .stat-card{padding:12px 10px;border-radius:16px}
  .stat-card span{font-size:.75rem}.stat-card strong{font-size:1.12rem}.stat-card small{font-size:.7rem}
  .feature{align-items:flex-start;flex-direction:column;gap:12px;margin:22px 0;padding:23px 3px}
  .feature .button{align-self:stretch}
  .page-heading{margin-bottom:22px}.page-heading h1{font-size:1.75rem}
  .bank-layout{grid-template-columns:minmax(0,1fr);gap:15px}
  .panel{padding:19px;border-radius:18px}
  .question-panel{padding:21px 17px;border-radius:20px}
  .question-text,.review-question{font-size:1.04rem;line-height:2}
  .answer-option{align-items:flex-start;padding:12px;gap:10px}
  .quiz-top{align-items:flex-start;font-size:.8rem}
  .quiz-actions .button{flex:1 1 auto}
  .result-hero{padding:22px 3px 30px}
  .score-ring{width:150px;height:150px;border-width:9px}
  .review-item{padding:16px;border-radius:15px}
  .auth-panel{margin:20px auto;padding:23px 18px;border-radius:21px}
  .table-wrap{border-radius:14px}
  th,td{padding:11px 12px;font-size:.86rem}
  .practice-form{align-items:stretch}
  .practice-form label,.practice-form select{width:100%;min-width:0}
  footer{margin-top:12px;padding:22px 12px}
}
@media(max-width:420px){
  .stats{grid-template-columns:1fr;gap:9px}
  .stat-card{display:grid;grid-template-columns:1fr auto;align-items:center;column-gap:10px;padding:12px 14px}
  .stat-card strong{grid-column:2;grid-row:1 / span 2;font-size:1.3rem}
  .stat-card small{grid-column:1}
  .button{padding:10px 14px;font-size:.87rem}
  .hero .button{width:100%}
  .quiz-actions{display:grid;grid-template-columns:1fr}
}
@media(prefers-reduced-motion:reduce){
  *,*::before,*::after{scroll-behavior:auto!important;animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important}
}

/* Adaptive learning and challenge areas */
.hero-actions,.challenge-hero-actions{display:flex;flex-wrap:wrap;gap:12px;align-items:center;margin-top:20px}
.learning-feature{position:relative;border:1px solid rgba(105,125,223,.18);background:linear-gradient(120deg,rgba(237,242,255,.94),rgba(247,240,255,.92));border-radius:24px;padding:25px 28px;gap:22px}
.learning-feature h2{margin:7px 0 10px}.learning-feature p{max-width:790px;color:var(--muted,#68738a);line-height:2;margin:0}
.challenge-feature{border:1px solid rgba(239,169,74,.25);background:linear-gradient(120deg,rgba(255,248,233,.95),rgba(255,241,227,.9));border-radius:24px;padding:25px 28px;gap:22px}
.learning-strip{display:flex;align-items:center;justify-content:space-between;gap:20px;margin:0 0 20px;padding:18px 22px;border:1px solid rgba(103,126,218,.18);border-radius:18px;background:linear-gradient(100deg,#eef3ff,#f7f1ff)}
.learning-strip div{display:grid;gap:4px}.learning-strip b{color:#344b9e}.learning-strip span{color:#69758d;font-size:.92rem}.learning-strip a{white-space:nowrap;color:#415bc0;text-decoration:none;font-weight:800}
.learning-hero,.challenge-hero{position:relative;display:grid;grid-template-columns:minmax(0,1.4fr) minmax(210px,.6fr);align-items:center;gap:30px;overflow:hidden;padding:clamp(28px,5vw,52px);margin-bottom:26px;border-radius:30px;color:#fff;background:linear-gradient(125deg,#243b7b 0%,#415dc1 54%,#7654b7 100%);box-shadow:0 24px 58px rgba(44,60,134,.19)}
.learning-hero:after,.challenge-hero:after{content:"";position:absolute;width:390px;height:390px;border:1px solid rgba(255,255,255,.13);border-radius:50%;left:-150px;top:-220px;box-shadow:0 0 0 35px rgba(255,255,255,.035),0 0 0 75px rgba(255,255,255,.025)}
.learning-hero .eyebrow,.challenge-hero .eyebrow{color:#dbe4ff}.learning-hero h1,.challenge-hero h1{font-size:clamp(2rem,4vw,3.2rem);line-height:1.38;margin:10px 0 14px;color:#fff}.learning-hero h1 span{color:#d4e0ff}.learning-hero p,.challenge-hero p{max-width:760px;line-height:2;color:rgba(255,255,255,.84)}
.learning-hero .button.secondary,.challenge-hero .button.secondary{background:rgba(255,255,255,.12);border-color:rgba(255,255,255,.24);color:#fff}.learning-orbit,.challenge-orbit{position:relative;z-index:1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;min-height:200px;border:1px solid rgba(255,255,255,.22);border-radius:50%;background:radial-gradient(circle,rgba(255,255,255,.2),rgba(255,255,255,.055) 68%);text-align:center;box-shadow:inset 0 0 42px rgba(255,255,255,.08)}
.learning-orbit strong,.challenge-orbit span{font-size:3.5rem;line-height:1;font-weight:900;color:#fff}.learning-orbit span,.learning-orbit small,.challenge-orbit small,.challenge-orbit b{color:rgba(255,255,255,.84);font-size:.85rem}.challenge-hero{background:linear-gradient(125deg,#432b76 0%,#6542a5 52%,#b06a70 100%)}.challenge-orbit span{font-size:4.2rem}.challenge-orbit b{margin-top:6px}
.challenge-grid{display:grid;grid-template-columns:minmax(0,.9fr) minmax(0,1.1fr);gap:20px;align-items:start}.challenge-card{height:100%;padding:26px}.challenge-card h2{margin:8px 0}.challenge-card>p{color:var(--muted,#68738a);line-height:2}.challenge-start-form{display:flex;align-items:end;gap:14px;margin-top:24px}.challenge-start-form label{flex:1}.challenge-start-form .button{flex:1}.challenge-note{margin-top:20px;padding:14px 16px;border-radius:15px;background:#f5f6fb;color:#717b91;font-size:.86rem;line-height:1.9}.challenge-note b{color:#44559b}.challenge-suggest-form{margin-top:20px}.challenge-suggest-form small,.challenge-admin-editor small{display:block;margin-top:6px;color:#7c879a;font-weight:400;line-height:1.8}.empty-state{display:grid;gap:8px;padding:22px;border:1px dashed #cbd3e5;border-radius:17px;background:#f8f9fd;color:#727e95}.empty-state strong{color:#35436f}.empty-state .button{justify-self:start;margin-top:8px}
.adaptive-panel{border:1px solid rgba(89,113,215,.2);background:linear-gradient(145deg,rgba(255,255,255,.97),rgba(245,247,255,.96));box-shadow:0 14px 40px rgba(57,77,143,.07)}.adaptive-panel .section-title-row{align-items:flex-start}.diagnosis-list{display:grid;gap:11px;margin:20px 0}.diagnosis-item{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:16px 18px;border:1px solid #e5eaf5;border-radius:16px;background:#fff}.diagnosis-item>div:first-child{display:grid;gap:5px}.diagnosis-item strong{color:#344576}.diagnosis-item small{color:#7a859a}.diagnosis-metrics{display:flex;flex-wrap:wrap;gap:8px}.diagnosis-metrics span{padding:6px 10px;border-radius:99px;background:#f0f3fb;color:#53648f;font-size:.8rem;font-weight:800;white-space:nowrap}.feature-list{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;margin:18px 0}.feature-list>div{padding:17px;border:1px solid #e8ecf5;border-radius:16px;background:#fafbfe}.feature-list b{color:#3e508f}.feature-list p{margin:7px 0 0;color:#778198;line-height:1.9;font-size:.9rem}.challenge-tag{background:#fff1dc!important;color:#8c541b!important}.challenge-result-card{margin:22px 0;border:1px solid rgba(207,145,67,.24);background:linear-gradient(120deg,#fffaf1,#fff5e9)}.challenge-result-card h2{margin:8px 0 20px;color:#704b27}.challenge-result-stats{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.challenge-result-stats div{display:grid;gap:4px;padding:16px;border-radius:15px;background:rgba(255,255,255,.8);text-align:center}.challenge-result-stats strong{font-size:1.55rem;color:#7d5426}.challenge-result-stats span{font-size:.85rem;color:#8d806e}.inline-reject-form{display:flex;align-items:end;gap:12px;margin-top:16px;padding-top:16px;border-top:1px solid #eceef4}.inline-reject-form label{flex:1}.inline-reject-form .button{flex:0 0 auto}
@media(max-width:850px){.challenge-grid{grid-template-columns:1fr}.learning-hero,.challenge-hero{grid-template-columns:1fr}.learning-orbit,.challenge-orbit{width:180px;min-height:180px;justify-self:center}.feature-list{grid-template-columns:1fr}.challenge-start-form{align-items:stretch;flex-direction:column}.learning-strip{align-items:flex-start;flex-direction:column}}
@media(max-width:600px){.learning-hero,.challenge-hero{padding:25px 20px;border-radius:23px}.learning-hero h1,.challenge-hero h1{font-size:1.9rem}.learning-orbit,.challenge-orbit{width:155px;min-height:155px}.diagnosis-item{align-items:flex-start;flex-direction:column}.diagnosis-metrics{width:100%}.challenge-result-stats{grid-template-columns:1fr}.inline-reject-form{align-items:stretch;flex-direction:column}.hero-actions,.challenge-hero-actions{display:grid;grid-template-columns:1fr}.hero-actions .button,.challenge-hero-actions .button{width:100%}}

/* Adaptive practice, database-backed question images and clearer navigation */
.question-image{margin:18px auto;text-align:center}.question-image img{max-width:100%;height:auto;max-height:520px;object-fit:contain;border-radius:14px;border:1px solid var(--border,#ddd)}
.auto-practice-prompt{margin:18px 0;padding:16px;border:1px solid var(--border,#ddd);border-radius:16px;background:var(--surface,#fff)}.auto-practice-prompt>p{display:flex;gap:10px;justify-content:space-between;flex-wrap:wrap}.auto-practice-prompt #practice-countdown{display:inline-flex;min-width:25px;justify-content:center;font-variant-numeric:tabular-nums}.focus-select{display:flex;gap:7px;align-items:center;font-size:.85em;margin-bottom:7px}.weak-list small{display:block;margin-top:7px;line-height:1.8;color:var(--muted,#666)}.topbar nav{display:flex;align-items:center;gap:clamp(8px,1.5vw,20px);flex-wrap:wrap}.topbar nav a{white-space:nowrap}.home-analysis{margin:24px 0}

/* Beginner-friendly navigation and contextual page tips */
.page-tip{position:relative;display:flex;align-items:center;gap:12px;margin:0 0 20px;padding:12px 46px 12px 15px;border:1px solid #e1e7f3;border-radius:14px;background:#fff;color:#4c5870;box-shadow:0 5px 18px rgba(35,50,80,.035)}
.page-tip[hidden]{display:none}.page-tip-label{flex:0 0 auto;color:#345bd0;font-size:.8rem;font-weight:800}.page-tip p{margin:0;font-size:.88rem;line-height:1.9}.page-tip-close{position:absolute;right:12px;top:50%;transform:translateY(-50%);width:28px;height:28px;border:0;border-radius:8px;background:#f0f3fa;color:#596781;font-size:1.2rem;cursor:pointer}
.home-guide{margin:32px 0;padding:clamp(20px,3vw,32px);border:1px solid #e3e8f2;border-radius:22px;background:#fff;box-shadow:0 10px 30px rgba(39,54,89,.04)}
.home-guide-heading h2,.home-navigation h2{margin:8px 0;color:#202f4b;font-size:1.35rem}.home-guide-heading p{margin:0;color:#707b90;line-height:1.9}
.home-guide-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;margin-top:20px}.home-guide-step{display:flex;flex-direction:column;align-items:flex-start;gap:9px;min-width:0;padding:18px;border:1px solid #e6eaf2;border-radius:16px;background:#fafbfe;color:inherit;text-decoration:none}.home-guide-step:hover{border-color:#bdcaf0;background:#f7f8ff}.home-step-number{display:grid;place-items:center;width:32px;height:32px;border-radius:10px;background:#edf2ff;color:#345bd0;font-weight:900}.home-guide-step>b{color:#273653}.home-guide-step p{margin:0;color:#707b90;font-size:.88rem;line-height:1.95}.home-guide-link{margin-top:auto;color:#345bd0;font-size:.82rem;font-weight:800;line-height:1.8}.home-navigation{margin:32px 0}.home-navigation-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin-top:14px}.home-navigation-grid a{display:flex;flex-direction:column;gap:5px;padding:16px;border:1px solid #e4e9f2;border-radius:14px;background:rgba(255,255,255,.8);text-decoration:none}.home-navigation-grid a:hover{border-color:#b9c8f3;background:#fff}.home-navigation-grid b{color:#30436c}.home-navigation-grid span{color:#788399;font-size:.82rem;line-height:1.8}
.result-score-row{display:flex;align-items:center;justify-content:center;gap:18px;flex-wrap:wrap;margin:18px auto 22px}.result-score-row .score-ring{margin:0}.result-countdown{display:grid;gap:5px;min-width:145px;padding:15px 18px;border:1px solid #e0e7f7;border-radius:16px;background:#f8faff;text-align:center}.result-countdown span{font-size:.82rem;color:#68758d}.result-countdown strong{font-size:1.25rem;color:#345bd0}.result-countdown b{font-variant-numeric:tabular-nums}
@media(max-width:760px){.home-guide-grid,.home-navigation-grid{grid-template-columns:1fr}.page-tip{align-items:flex-start;flex-direction:column;gap:3px;padding:12px 42px 12px 12px}.result-score-row{gap:10px}.result-score-row .score-ring{width:145px;height:145px}.result-countdown{min-width:125px;padding:12px}}
/* Inline SVG diagrams inside question text */
.question-text svg,.review-question svg,.explanation svg,.option-copy svg,.math-preview svg{display:inline-block;max-width:100%;height:auto;vertical-align:middle;overflow:visible}
.question-text>svg,.review-question>svg,.explanation>svg,.math-preview>svg{display:block;margin:14px auto;max-height:560px}
.question-text svg text,.review-question svg text,.explanation svg text,.option-copy svg text,.math-preview svg text{font-family:Tahoma,Arial,sans-serif}
.question-text,.review-question,.option-copy,.explanation,.math-preview{min-width:0;overflow-wrap:anywhere}

/* Final visual system: restrained green, light surfaces, consistent controls */
:root{
  --ink:#202c27;--muted:#68766f;--primary:#16734f;--primary-dark:#10583c;
  --mint:#e8f5ed;--paper:#fff;--bg:#f7f9f7;--line:#e1e8e3;
  --danger:#a62f42;--shadow:0 8px 26px rgba(24,55,39,.055);
}
body{background:var(--bg);color:var(--ink)}
.topbar{background:rgba(255,255,255,.97);border-color:var(--line)}
.brand,.feature h2,.panel h2,.page-heading h1,.result-hero h1{color:var(--ink)}
.brand-icon{background:var(--primary)}
nav a:hover,.back-link:hover,.stat-card a,footer a{color:var(--primary)}
.hero{background:linear-gradient(120deg,#edf7f0,#fbfdfb);border-color:#dcebe0}
.hero h1 span,.eyebrow,.admin-kicker{color:var(--primary)}
.button{border-radius:10px;box-shadow:none}
.button:hover{transform:translateY(-1px);box-shadow:0 5px 14px rgba(24,85,55,.09)}
.button.primary,.primary{background:var(--primary);color:#fff;border-color:var(--primary);box-shadow:none}
.button.primary:hover,.primary:hover{background:var(--primary-dark);border-color:var(--primary-dark);box-shadow:0 5px 14px rgba(22,115,79,.15)}
.button.secondary,.secondary{background:#f3f7f4;color:var(--primary);border:1px solid #dce8df;box-shadow:none}
.button.secondary:hover,.secondary:hover{background:#e9f3ec;border-color:#c9ddcf}
.stat-card,.panel{background:#fff;border-color:var(--line);box-shadow:var(--shadow);backdrop-filter:none;-webkit-backdrop-filter:none;border-radius:16px}
.stat-card:hover{transform:translateY(-1px);border-color:#cfe1d4;box-shadow:0 10px 25px rgba(24,55,39,.07)}
.stat-card strong{color:var(--ink)}
.feature{border-color:var(--line)}
select,input[type=number],input:not([type=checkbox]):not([type=radio]):not([type=submit]):not([type=hidden]),textarea{
  border-color:#d8e2db;background:#fbfcfb;color:var(--ink);border-radius:10px;box-shadow:none
}
select:focus,input:focus,textarea:focus{border-color:#5caa80;box-shadow:0 0 0 3px rgba(22,115,79,.12);background:#fff}
input[type=checkbox],input[type=radio]{accent-color:var(--primary)}
.match-count{border:1px solid #e0ece3;background:#f3f8f4;color:var(--muted)}
.match-count strong,.score-ring strong,.success-text{color:var(--primary)}
.progress{background:#e7eee9;box-shadow:none}
.progress span{background:var(--primary);box-shadow:none}
.timer-box,.quiz-total-time{border-color:var(--line);background:#fff;color:var(--primary)}
.tags span{border-color:#dcebe0;background:var(--mint);color:var(--primary)}
.answer-option{border-color:var(--line);background:#fff;box-shadow:none}
.answer-option:hover{border-color:#a9cfb7;background:#f8fcf9;transform:none}
.answer-option:has(input:checked){border-color:#73b38c;background:#f0f8f2;box-shadow:0 0 0 2px rgba(22,115,79,.06)}
.answer-option:has(input:checked) .option-number{background:var(--primary);border-color:var(--primary);color:#fff}
.option-number{background:#f0f4f1;color:#56665c;border-color:#e2e9e4}
.success{background:#edf8f0;color:#176342;border-color:#d8ecdd}
.error{background:#fff0f2;color:#9f2b41;border-color:#f8dce2}
.message.info{background:#f0f6ff;color:#2856af;border-color:#dce8ff}
.message.warning{background:#fff7e9;color:#925c10;border-color:#f8e5bc}
.message.success{background:#edf8f0;color:#176b43;border-color:#d9ecdf}
.score-ring{border-color:#dcebe0;border-top-color:#8dc6a2;border-right-color:var(--primary);box-shadow:none}
.earned-points{background:#edf8f0;border-color:#d8ecdd;color:#176342}
.weak-list div{border-color:var(--line);background:#f8faf8}
.review-item{border-color:var(--line);background:#fff;box-shadow:none}
.explanation{border-color:#e0ebe3;border-right-color:#73b38c;background:#f7faf7}
.question-feedback{border-color:var(--line);background:#fbfcfb}
.reaction-button{border-color:var(--line)}
.reaction-button:hover,.reaction-button.is-active{background:var(--mint);border-color:#b9d8c2;color:var(--primary)}
.feedback-status{color:var(--primary)}
.feedback-dialog{border-color:var(--line);border-radius:18px;box-shadow:0 22px 65px rgba(20,40,28,.2)}
.auth-panel{max-width:520px;border-color:var(--line);border-radius:18px;background:#fff;box-shadow:0 12px 34px rgba(24,55,39,.07)}
.auth-tabs{border-color:var(--line);border-radius:12px;background:#f5f8f5}
.auth-tabs .button{flex:1}
.create-form{gap:15px}
.create-form label{gap:7px;color:#34443a}
.auth-panel .hint{margin:16px 0 0;line-height:1.9}
.table-wrap{border-color:var(--line);background:#fff;box-shadow:none}
th,td{border-bottom-color:#e9eee9}
th{background:#f2f7f3;color:#405448}
tbody tr:hover td{background:#f8fbf8}
.highlight-row td{background:#edf7ef!important;color:#185b3d}
.my-rank{border-color:#dcebe0;background:#f2f8f3;color:#315b40}
.my-rank strong,.my-rank b{color:var(--primary)}
.practice-form{border-color:var(--line);background:#f8faf8}
.error-page{border-color:var(--line);background:#fff;box-shadow:var(--shadow)}
.error-code{background:var(--mint);color:var(--primary)}
.learning-feature,.learning-strip{border-color:#dcebe0;background:#f1f8f2}
.learning-strip b,.learning-strip a{color:var(--primary)}
.learning-hero{background:linear-gradient(125deg,#185b40 0%,#21764f 58%,#3c9165 100%);box-shadow:0 16px 38px rgba(24,91,64,.12)}
.learning-hero h1 span{color:#d7f0df}
.learning-hero .eyebrow{color:#d7f0df}
.adaptive-panel{border-color:#dcebe0;background:#fff;box-shadow:var(--shadow)}
.empty-state{border-color:#cbdacf;background:#f8faf8;color:var(--muted)}
.empty-state strong{color:var(--ink)}
footer{border-top-color:var(--line);background:#fff;color:#7a887f}
footer a:hover{text-underline-offset:3px}
:focus-visible{outline:3px solid rgba(22,115,79,.35);outline-offset:2px}
@media(max-width:760px){.auth-panel{margin:18px auto;padding:22px 18px}.auth-tabs .button{padding-inline:12px}}


/* Examyar visual refinement: stronger green, cleaner auth/account, usable quiz timers */
:root{--primary:#087443;--primary-dark:#055b34;--mint:#e4f5e9;--line:#dce8df;--bg:#f7faf7;--shadow:0 10px 28px rgba(8,74,43,.055)}
.button.primary,.primary{background:#087443!important;border-color:#087443!important;color:#fff!important}
.button.primary:hover,.primary:hover{background:#055b34!important;border-color:#055b34!important}
.hero{background:linear-gradient(120deg,#e7f6eb,#fbfdfb);border-color:#cfe8d6}
.hero h1 span{background:none;-webkit-text-fill-color:initial;color:#087443!important}
.hero-credit{margin-top:-8px!important;color:#52705d!important;font-size:.86rem;font-weight:700}
.home-save-feature{margin:18px 0 24px;padding:22px 25px;border:1px solid #b9dfc5;border-radius:18px;background:#edf8f0;box-shadow:0 8px 24px rgba(8,116,67,.08)}
.home-save-feature h2{color:#075c35}.home-save-feature .button{background:#087443!important;color:white!important}
.home-bank-stat{grid-template-columns:minmax(220px,360px);margin-top:20px}
.auth-panel{max-width:560px;margin:20px auto 34px;padding:clamp(25px,4vw,42px);border:1px solid #d5e8da;border-radius:22px;box-shadow:0 16px 42px rgba(7,91,49,.09)}
.auth-panel:before{content:"";display:block;height:5px;margin:-42px -42px 28px;border-radius:22px 22px 0 0;background:linear-gradient(90deg,#055b34,#0c8a4c)}
.auth-tabs{display:flex;gap:8px;padding:6px;margin-bottom:24px;background:#edf6ef;border:1px solid #d9eadc;border-radius:13px}
.auth-tabs .button{flex:1;border-radius:9px}.create-form{gap:18px}.create-form label{font-weight:700;color:#263c2e}.create-form input[type=text],.create-form input[type=email],.create-form input[type=password],.create-form input:not([type]){width:100%;font:inherit;padding:13px 14px;border:1px solid #cfdfd3;border-radius:11px;background:#fbfdfb;color:var(--ink);outline:none;transition:border-color .18s,box-shadow .18s}.create-form input:focus{border-color:#087443;box-shadow:0 0 0 4px rgba(8,116,67,.12);background:white}.auth-panel .full{min-height:48px;margin-top:8px}.auth-panel .hint{padding:11px 13px;border-radius:10px;background:#f5faf6;color:#617267}
.quiz-top{display:grid;grid-template-columns:1fr auto auto auto;align-items:center;gap:12px;margin-bottom:20px;direction:ltr}.quiz-top>*{direction:rtl}
.quiz-top .back-link{grid-column:1;justify-self:start}.quiz-top .quiz-question-count{grid-column:2;color:#52665a;white-space:nowrap}.quiz-top .question-timer-box{grid-column:4;justify-self:end}.quiz-top .total-timer-box{grid-column:3;justify-self:center;background:#e5f5e9;border-color:#b9dfc5;color:#075c35}
.timer-box{border-color:#b9dfc5;background:#fff;color:#075c35;border-radius:11px;padding:9px 13px;white-space:nowrap}.timer-danger{color:#b42332!important;border-color:#efb6bd!important;background:#fff1f2!important}
.account-password-panel{border:1px solid #d8e9dc;background:#fff}.account-password-panel .auth-form{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}.account-password-panel .auth-form input[type=password]{width:100%;font:inherit;padding:12px 13px;border:1px solid #cfdfd3;border-radius:11px;background:#fbfdfb;color:var(--ink);outline:none}.account-password-panel .auth-form input[type=password]:focus{border-color:#087443;box-shadow:0 0 0 4px rgba(8,116,67,.12);background:#fff}.account-password-panel .auth-form label{display:grid;gap:7px;font-weight:700}.account-password-panel .auth-form label:nth-child(4){grid-column:1/-1}.account-password-panel .auth-form button{grid-column:1/-1;justify-self:start;min-width:190px}
.page-tip{border-color:#cfe4d4;background:#f8fcf8;color:#43594a}.page-tip-label{color:#087443}.page-tip-close{right:12px;background:#e3f2e7;color:#075b34;font-weight:800}.page-tip-close:hover{background:#cce8d3;color:#034b2b}
@media(max-width:650px){.auth-panel:before{margin:-22px -18px 22px}.quiz-top{grid-template-columns:1fr 1fr;gap:9px}.quiz-top .back-link{grid-column:1;grid-row:1;justify-self:start}.quiz-top .quiz-question-count{grid-column:2;grid-row:1;justify-self:end}.quiz-top .total-timer-box{grid-column:1;grid-row:2;justify-self:stretch;text-align:center}.quiz-top .question-timer-box{grid-column:2;grid-row:2;justify-self:stretch;text-align:center}.account-password-panel .auth-form{grid-template-columns:1fr}.account-password-panel .auth-form label:nth-child(4),.account-password-panel .auth-form button{grid-column:1}}

/* Final layout refinements */
.challenge-hero .eyebrow{color:#ffffff;background:rgba(5,45,28,.28);border:1px solid rgba(255,255,255,.34);border-radius:999px;padding:5px 12px;display:inline-flex;align-items:center;font-weight:800}
.quiz-top{display:grid;grid-template-columns:minmax(0,1fr) auto minmax(0,1fr);align-items:center;gap:12px;margin-bottom:20px;direction:ltr}
.quiz-top>*{direction:rtl}
.quiz-top .total-timer-box{grid-column:1;justify-self:start;background:#d8f3e1;border:1px solid #8ed0a6;color:#075c35}
.quiz-top .quiz-question-count{grid-column:2;justify-self:center;text-align:center;font-weight:800;color:var(--ink);white-space:nowrap}
.quiz-top .question-timer-box{grid-column:3;justify-self:end}
.quiz-exit-bottom{display:flex;justify-content:flex-end;margin-top:22px;padding-top:16px;border-top:1px solid var(--line)}
@media(max-width:650px){.quiz-top{grid-template-columns:1fr 1fr;gap:9px}.quiz-top .total-timer-box{grid-column:1;grid-row:1;justify-self:stretch;text-align:center}.quiz-top .quiz-question-count{grid-column:1 / -1;grid-row:2;justify-self:center}.quiz-top .question-timer-box{grid-column:2;grid-row:1;justify-self:stretch;text-align:center}.quiz-exit-bottom{justify-content:stretch}.quiz-exit-bottom .button{width:100%}}

/* Exam workspace */
:root {
  --ink: #192e35;
  --muted: #52696c;
  --primary: #096c59;
  --primary-dark: #075243;
  --mint: #e6f4ee;
  --line: #dce8e3;
  --bg: #f4f8f5;
  --shadow: 0 12px 32px rgba(26, 57, 48, .07);
}
[hidden] { display: none !important; }
body { background: var(--bg); }
.topbar { background: #fff; }
.topbar nav { flex-wrap: wrap; }
.topbar nav a { color: #375057; }
.topbar nav a[aria-current="page"] {
  color: var(--primary-dark);
  background: var(--mint);
}
.topbar nav a:focus-visible, .home-tile:focus-visible, .question-map button:focus-visible {
  outline: 3px solid #13886f;
  outline-offset: 3px;
}
.home-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  align-items: center;
  gap: clamp(24px, 6vw, 88px);
  min-height: 375px;
  padding: clamp(26px, 5.6vw, 75px);
  color: #fff;
  background: radial-gradient(ellipse at 5% 100%, #185b54 0, transparent 57%), #15363e;
  border-radius: 28px;
  box-shadow: 0 18px 42px rgba(16, 55, 47, .15);
}
.home-hero h1 { color: #fff; margin: 0 0 12px; font-size: clamp(3rem, 7vw, 5.8rem); line-height: 1.16; }
.home-hero p { color: #deede9; font-size: clamp(1rem, 2vw, 1.19rem); margin: 0 0 24px; line-height: 1.95; max-width: 390px; }
.home-hero .hero-actions { margin: 0; gap: 10px; }
.home-hero .button.primary { color: #15363e; background: #dcf4b9; border-color: #dcf4b9; }
.home-hero .button.primary:hover { background: #f0ffdd; }
.home-hero .button.secondary { color: #fff; background: #254951; border-color: #577780; }
.home-hero .button.secondary:hover { background: #345b64; }
.home-hero-art {
  min-height: 265px;
  position: relative;
  display: grid;
  place-items: center;
  direction: ltr;
  background-image: radial-gradient(#76a7a682 1px, transparent 1px);
  background-size: 18px 18px;
  border-radius: 22px;
}
.hero-notebook {
  width: min(68%, 245px);
  padding: 16px 18px 21px;
  border-radius: 16px;
  border: 1px solid #c2e2d6;
  background: #f8fbef;
  box-shadow: 9px 10px 0 #64aa96, 20px 25px 40px #112b34a6;
  transform: rotate(-10deg);
}
.notebook-top { display: flex; gap: 6px; border-bottom: 1px solid #c9dbd2; padding-bottom: 13px; }
.notebook-top span { width: 7px; height: 7px; background: #8cb9aa; border-radius: 50%; }
.notebook-geometry { position: relative; width: 118px; height: 116px; margin: 10px auto 6px; color: #245d53; }
.notebook-geometry i { position: absolute; height: 2px; background: #168068; transform-origin: left; }
.notebook-geometry i:nth-child(1) { top: 91px; left: 8px; width: 100px; }
.notebook-geometry i:nth-child(2) { top: 91px; left: 8px; width: 92px; transform: rotate(-57deg); }
.notebook-geometry i:nth-child(3) { top: 14px; left: 58px; width: 92px; transform: rotate(57deg); }
.notebook-geometry b { position: absolute; font: 700 12px/1 sans-serif; }
.notebook-geometry b:nth-of-type(1) { top: 0; left: 53px; }
.notebook-geometry b:nth-of-type(2) { bottom: 7px; left: 4px; }
.notebook-geometry b:nth-of-type(3) { bottom: 7px; right: 4px; }
.notebook-rule { height: 4px; border-radius: 9px; background: #c7dfd4; margin: 8px 0 0; }
.notebook-rule.short { width: 58%; }
.hero-check, .hero-formula { position: absolute; display: grid; place-items: center; border-radius: 11px; box-shadow: 0 6px 18px #132e3680; }
.hero-check { right: 9%; top: 19%; width: 51px; height: 51px; color: #173f36; background: #dcf4b9; font-size: 1.7rem; transform: rotate(12deg); }
.hero-formula { left: 4%; bottom: 12%; padding: 9px 13px; background: #ffe0a1; color: #223b38; font: 700 1.12rem/1.25 Georgia, serif; transform: rotate(8deg); }
.home-links { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin: 22px 0; }
.home-tile { min-width: 0; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 14px; border: 1px solid var(--line); border-radius: 17px; background: white; padding: clamp(15px, 2.8vw, 25px); color: var(--ink); text-decoration: none; }
.home-tile:hover { border-color: #87baab; box-shadow: var(--shadow); }
.home-tile h2, .home-account h2 { margin: 0; font-size: 1.08rem; color: var(--ink); }
.home-tile p, .home-account p { margin: 4px 0 0; color: var(--muted); font-size: .9rem; }
.home-tile > b { color: var(--primary); }
.tile-mark { display: grid; width: 42px; height: 42px; place-items: center; border-radius: 12px; background: var(--mint); color: var(--primary-dark); font-size: 1.4rem; }
.home-tile:nth-child(2n) .tile-mark { background: #fff2d7; color: #715118; }
.home-account { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; padding: 20px 4px; }
.exam-heading { padding: clamp(20px, 4vw, 40px); margin-bottom: 20px; border: 1px solid #d6e7de; border-radius: 21px; background: linear-gradient(105deg, #f9fcf8 0%, #e7f3ec 100%); }
.exam-heading h1 { margin: 0 0 7px; line-height: 1.45; font-size: clamp(1.7rem, 4vw, 2.7rem); color: var(--ink); }
.exam-heading p { margin: 0 0 15px; color: var(--muted); }
.exam-heading > :last-child { margin-bottom: 0; }
.bank-switch { display: inline-flex; padding: 4px; gap: 4px; border: 1px solid #cadfd4; background: #fafffa; border-radius: 12px; }
.bank-switch a { text-decoration: none; color: var(--primary-dark); min-width: 85px; padding: 8px 14px; text-align: center; border-radius: 9px; }
.bank-switch a[aria-current="page"] { color: #fff; background: var(--primary); }
.exam-builder { align-items: stretch; grid-template-columns: minmax(0, 1.2fr) minmax(0, .85fr); }
.exam-builder > .panel { display: flex; flex-direction: column; }
.exam-builder > .panel h2 { margin: 0 0 17px; font-size: 1.23rem; }
.exam-builder .match-count { margin-top: auto; }
.exam-builder .filter-form { padding-bottom: 18px; }
.exam-builder .create-form { gap: 12px; }
.time-choice { display: flex; align-items: center; gap: 12px; padding: 11px 12px; border: 1px solid #cce4d8; border-radius: 12px; background: #eef8f3; cursor: pointer; }
.time-choice input { width: 19px; height: 19px; flex: 0 0 auto; }
.time-choice span { display: grid; gap: 2px; }
.time-choice small { font-weight: normal; color: #3b5c54; }
.exam-builder .hint { margin: 0; }
.quiz-top.exam-quiz-top { margin-bottom: 12px; }
.timer-box span { display: inline-block; min-width: 48px; font-variant-numeric: tabular-nums; }
.question-map { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; padding-top: 16px; border-top: 1px solid var(--line); }
.question-map button { width: 38px; height: 38px; border: 1px solid #d6e3df; border-radius: 10px; background: #fff; font: inherit; color: #2c4a4d; cursor: pointer; }
.question-map button.is-answered { border-color: #92c1ae; background: #e8f6ee; color: #075243; }
.question-map button[aria-current="step"] { border-color: #136b5b; color: #fff; background: #136b5b; }
.answer-clear { width: max-content; min-height: 36px; padding: 5px 10px; color: var(--primary-dark); background: #f5f8f5; }
.written-answer { display: grid; gap: 8px; }
.written-answer textarea { width: 100%; resize: vertical; }
.quiz-exit-bottom { gap: 10px; flex-wrap: wrap; }
.result-hero { background: #fff; border: 1px solid var(--line); }
.result-countdown { display: flex; align-items: center; justify-content: space-between; gap: 13px; min-width: 0; background: #fff5df; border-color: #efd6a2; color: #5b4419; text-align: start; }
.result-countdown > div { display: grid; gap: 4px; }
.result-countdown strong { color: #5b4419; }
.result-countdown .button { background: #fff; color: #584021; border-color: #d8bd8d; flex-shrink: 0; }
.descriptive-review h2, .descriptive-review h3 { color: var(--ink); }
.descriptive-review h2 { margin: 0 0 12px; font-size: 1.18rem; }
.descriptive-review h3 { margin: 0 0 8px; font-size: 1rem; }
.written-review { margin-top: 18px; padding: 13px 15px; background: #f3f8f5; border-radius: 12px; }
.written-review p { margin: 0; }
.written-copy { overflow-wrap: anywhere; }
.diagram { display: grid; place-items: center; margin: 12px 0; }
.diagram > svg { display: block; max-width: 100%; height: auto; max-height: 440px; }
@media (max-width: 760px) {
  .topbar { justify-content: center; gap: 6px; }
  .topbar nav { justify-content: center; }
  .topbar nav a { padding: 7px 9px; }
  .home-hero { min-height: unset; grid-template-columns: 1fr; gap: 16px; }
  .home-hero-art { min-height: 206px; }
  .hero-notebook { padding: 10px 14px; width: 175px; }
  .notebook-geometry { margin: 2px auto; }
  .exam-builder { grid-template-columns: 1fr; }
}
@media (max-width: 510px) {
  .home-links { grid-template-columns: 1fr; }
  .result-score-row { display: grid; justify-items: center; }
  .result-countdown { padding: 8px 10px; }
  .result-countdown .button { padding-inline: 12px; }
}
.home-hero .button.primary:not(:hover) { color: #173a32; background: #dcf4b9 !important; border-color: #dcf4b9 !important; }
.create-form label.time-choice, .challenge-start-form label.time-choice { display: flex; gap: 12px; }
.create-form .time-choice input { flex: 0 0 19px; width: 19px; margin: 0; }
.tile-chart { display: flex; justify-content: center; align-items: center; gap: 3px; }
.tile-chart i { align-self: end; width: 4px; margin-bottom: 12px; height: 7px; border-radius: 2px; background: currentColor; }
.tile-chart i:nth-child(2) { height: 13px; }
.tile-chart i:nth-child(3) { height: 18px; }
.result-hero { padding-inline: clamp(16px, 3vw, 32px); border-radius: 21px; }
.result-hero .hint a { color: var(--primary-dark); }
@media (max-width: 510px) {
  .result-score-row { margin: 14px auto 18px; }
  .result-score-row .score-ring { width: 124px; height: 124px; }
  .result-score-row .result-countdown { grid-row: 1; }
  .adaptive-panel .section-title-row { flex-direction: column; align-items: flex-start; }
}
.result-score-row .score-ring {
  position: relative;
  isolation: isolate;
  border: 0;
  background: conic-gradient(var(--primary) 0 var(--score), #deebe5 var(--score) 100%);
}
.result-score-row .score-ring::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 7px;
  border-radius: 50%;
  background: #fff;
}

/* MathJax CHTML: keep formulas responsive and let Persian text runs use browser RTL shaping. */
mjx-container[jax="CHTML"]{max-width:100%;max-inline-size:100%}
mjx-container[jax="CHTML"][display="true"]{display:block;max-width:100%;overflow-x:auto;overflow-y:hidden;padding:2px 0}
mjx-mtext[data-examyar-rtl-text="1"]{direction:rtl;unicode-bidi:isolate;text-align:right;font-family:'Vazir',Tahoma,Arial,sans-serif;white-space:pre}
