:root{font-family:Inter,ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#1e3046;background:#f3f6fa;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased}*{box-sizing:border-box}html{height:100%;-webkit-text-size-adjust:100%}body{margin:0;min-height:100vh;min-height:100dvh}button,input,textarea,select{font:inherit}button{cursor:pointer;-webkit-tap-highlight-color:transparent}button:disabled{opacity:.48;cursor:not-allowed}button:focus-visible,input:focus-visible,textarea:focus-visible,select:focus-visible{outline:3px solid #73a8e6;outline-offset:2px}a{color:#27689f}.hidden{display:none!important}.app-shell{max-width:1340px;margin:auto;padding:0 26px}.topbar{height:82px;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid #dce5f0;gap:15px}.brand{display:flex;gap:12px;align-items:center}.brand-icon{display:grid;place-items:center;background:#204e77;color:#fff;border-radius:12px;width:41px;height:41px;font-size:27px}.brand strong{font-size:19px;letter-spacing:-.5px}.brand strong span{color:#2f79ae}.brand small{display:block;color:#718197;font-size:11px;margin-top:3px;letter-spacing:.025em}.top-actions{display:flex;align-items:center;gap:14px}.network-chip{font-size:12px;color:#1f7d53;border-radius:16px;background:#e2f6eb;padding:7px 11px}.network-chip.offline{background:#fff0e2;color:#a76023}.link-btn{border:0;background:none;color:#315f91;font-size:13px;font-weight:650;padding:8px}.view{padding:30px 0 55px;min-height:calc(100dvh - 148px)}.narrow{max-width:665px;margin:auto}.entry-layout{display:grid;grid-template-columns:minmax(0,1fr) 420px;gap:7%;align-items:center;min-height:calc(100dvh - 190px)}.hero h1{font-size:clamp(33px,4.4vw,62px);line-height:1.12;letter-spacing:-1.6px;margin:22px 0}.hero h1 span{color:#377cad}.hero p{max-width:550px;color:#65758c;font-size:17px;line-height:1.7}.eyebrow{font-size:11px;letter-spacing:.13em;font-weight:800;color:#487fac}.hero-highlights{display:flex;flex-wrap:wrap;gap:12px;margin-top:28px}.hero-highlights span{border:1px solid #d3e0ed;background:#fff;padding:10px 14px;border-radius:13px;font-size:13px;font-weight:600;color:#406181}.hero-note{margin-top:25px;max-width:450px;font-size:13px;color:#708299;line-height:1.7}.card{background:#fff;border:1px solid #e1e9f1;box-shadow:0 8px 35px rgba(27,64,99,.035);border-radius:20px;padding:26px;margin-bottom:18px}.card h2{font-size:20px;letter-spacing:-.4px;margin:0 0 9px}.card h3{font-size:15px;margin:12px 0}.entry-card{padding:33px}.muted{color:#748398;line-height:1.6;font-size:14px}.help{font-size:12px;color:#7a8899;line-height:1.6;margin:16px 0 0}label{display:block;font-size:13px;font-weight:650;color:#435970;margin:15px 0}input:not([type=checkbox]),textarea,select{width:100%;padding:13px 14px;border:1px solid #d2dfec;border-radius:11px;background:#fff;color:#26394e;min-height:46px;outline:0;margin-top:7px}input:focus,textarea:focus,select:focus{border-color:#468fc2}input[type=checkbox]{width:19px;height:19px;accent-color:#2372ad;vertical-align:middle;margin-right:9px}.btn{border:1px solid transparent;border-radius:11px;padding:12px 17px;font-weight:750;font-size:13px;min-height:45px;transition:background .12s,color .12s}.primary{background:#255d89;color:white}.primary:hover:enabled{background:#1d4d75}.outline{background:white;color:#295c87;border-color:#d0dce9}.outline:hover:enabled{background:#edf5fa}.danger{color:#b13d37;border-color:#e9b5af;background:#fff4f3}.full{width:100%}.page-heading{text-align:center;margin:20px 0 26px}.page-heading h1{font-size:29px;margin:9px 0}.switcher,.button-group{display:flex;gap:8px;flex-wrap:wrap;align-items:center}.chip{background:#edf3f8;border:1px solid #d5e3ef;color:#406481;border-radius:30px;padding:9px 16px;font-size:13px;font-weight:700}.chip.selected{background:#285d88;color:#fff}.instruction{font-size:14px;color:#334d66;line-height:1.8;background:#f5f9fc;padding:13px 17px;border-radius:12px;margin-top:15px}.instruction ol{padding-left:19px;margin:0}.tip{background:#edf6fc;border-left:3px solid #4d98ca;padding:13px 15px;border-radius:6px;color:#4e6f8b;font-size:13px;line-height:1.6;margin-top:15px}.checklist{margin:20px 0}.checklist label{margin:15px 0;font-weight:500;display:flex;align-items:center}.section-top,.section-inline,.admin-header{display:flex;align-items:center;justify-content:space-between;gap:16px}.section-top h1{margin:8px 0;font-size:25px}.timer-pill,.time-indicator{border-radius:12px;background:#edf4fa;color:#275d86;padding:10px 14px;font-size:17px;font-weight:750;white-space:nowrap}.exercise-card{text-align:center}.equation{font-size:clamp(48px,10vw,77px);font-weight:750;letter-spacing:-2px;text-align:center;font-variant-numeric:tabular-nums;color:#163f61;padding:20px 0 8px;user-select:none}.feedback{min-height:26px;font-size:14px;color:#56758b;font-weight:600}.feedback.bad{color:#a94b38}.feedback.good{color:#177855}.keypad{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:10px;max-width:470px;margin:16px auto 8px}.digit-btn{height:clamp(62px,9vh,79px);border:1px solid #c8d8e8;background:#f7faff;border-radius:13px;font-size:26px;font-weight:700;color:#285b84;touch-action:manipulation;user-select:none;-webkit-user-select:none}.digit-btn:active{background:#cce5f6;transform:scale(.98)}.compact{padding:18px}.test-view{padding:14px 0 30px}.test-stage{max-width:670px;margin:auto}.test-top{display:flex;align-items:center;justify-content:space-between}.test-top h1{font-size:23px;margin:5px 0 15px}.time-indicator{background:transparent;font-size:14px;color:#7d8c9e;padding:4px}.progress-track{height:5px;border-radius:5px;background:#dce5ed;overflow:hidden}.progress-fill{width:0%;height:100%;background:#4289b6;transition:width 1s linear}.test-card{box-shadow:none;border:0;background:transparent;padding:8px 16px 16px}.test-instruction{text-align:center;color:#697c90;font-size:14px;padding-top:0}.test-card .equation{padding:clamp(13px,6vh,43px) 0 5px;font-size:clamp(52px,12vw,92px)}.answer-placeholder{width:59px;height:56px;display:grid;place-items:center;border:2px solid #bcd3e5;color:#a4bfce;border-radius:12px;background:#fff;font-size:28px;margin:0 auto 22px}.test-card .digit-btn{height:clamp(64px,11vh,90px);background:white;border:1.5px solid #b7d0e1}.test-help{text-align:center;font-size:12px;color:#8190a1;line-height:1.6}.sync-line{display:flex;align-items:center;justify-content:space-between;gap:14px;color:#7c8a9a;font-size:11px;margin:0 10px}.success-card{text-align:center;margin-top:50px;padding:40px 28px}.success-symbol{width:65px;height:65px;display:grid;place-items:center;border-radius:50%;background:#e4f5eb;color:#15804e;font-size:34px;margin:0 auto 20px}.success-card h1{font-size:28px}.success-card p{color:#657b90;line-height:1.7}.success-card button{margin-top:13px}.admin-view{max-width:1260px;margin:auto}.admin-header h1{font-size:28px;margin:6px 0}.admin-nav{display:flex;gap:3px;padding:5px;background:#e7eef5;border-radius:13px;overflow-x:auto;margin:20px 0}.admin-nav button{flex:1;min-width:max-content;border:0;border-radius:9px;background:transparent;color:#57728b;padding:11px 13px;font-size:12px;font-weight:700}.admin-nav button.selected{background:#fff;color:#225d8b;box-shadow:0 2px 8px #d4e2ef}.admin-controls{display:flex;align-items:center;gap:12px;margin-bottom:18px}.admin-controls label{margin:0;flex:1;max-width:450px}.grid-2{display:grid;grid-template-columns:1fr 1fr;gap:18px}.kpi-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:12px;margin-bottom:18px}.kpi{padding:21px;border-radius:16px;background:#fff;border:1px solid #e2eaf2}.kpi strong{display:block;font-size:26px;color:#275d85;margin-top:7px;font-variant-numeric:tabular-nums}.kpi small{color:#7a8c9c;font-size:12px}.table-scroll{overflow-x:auto;max-height:530px;overflow-y:auto}.data-table{border-collapse:collapse;width:100%;font-size:12px}.data-table th,.data-table td{padding:11px 10px;border-bottom:1px solid #eaf0f5;text-align:left;white-space:nowrap}.data-table th{position:sticky;top:0;background:#f5f9fc;color:#566c83;z-index:1}.data-table td{color:#2d4760}.data-table button{border:1px solid #c9dbe8;border-radius:7px;background:#fff;padding:6px;color:#286894;font-size:12px}.pagination{display:flex;justify-content:space-between;align-items:center;padding-top:18px;gap:8px}.pagination span{font-size:12px;color:#789}.analytics-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:15px}.analytics-grid>div{min-width:0;border:1px solid #e4ebf2;border-radius:12px;padding:10px}.chart{min-height:210px}.chart svg{display:block;width:100%;height:auto}.notice{border-radius:11px;background:#e4f2fc;color:#225c86;padding:13px;margin-bottom:15px;white-space:pre-wrap;overflow-wrap:anywhere}.report{padding:32px;background:white}.report h2{font-size:26px}.report-heading{border-bottom:2px solid #2e648d;padding-bottom:17px}.report-table{width:100%;border-collapse:collapse;margin:15px 0;font-size:13px}.report-table td{border-bottom:1px solid #e3e9ef;padding:11px}.report-table td:first-child{color:#65788d;width:42%}.report-kpi{display:grid;grid-template-columns:repeat(4,1fr);gap:8px;margin:20px 0}.report-kpi div{border:1px solid #dce5ed;border-radius:10px;padding:12px}.report-kpi strong{font-size:21px;display:block}.report-kpi small{color:#718299}.toast{position:fixed;bottom:calc(16px + env(safe-area-inset-bottom,0px));left:50%;transform:translateX(-50%);max-width:90%;padding:13px 19px;background:#18354f;color:white;z-index:300;border-radius:13px;box-shadow:0 8px 30px #223a5577;font-size:13px;white-space:pre-wrap}footer{border-top:1px solid #e1e8ef;padding:16px 0 22px;text-align:center;font-size:11px;color:#8998aa}@media(max-width:900px){.entry-layout{grid-template-columns:1fr;max-width:610px;margin:0 auto;gap:24px}.hero{text-align:center}.hero h1{font-size:32px;margin:14px 0}.hero p{font-size:14px;margin:auto}.hero-note{display:none}.hero-highlights{justify-content:center;margin:17px}.entry-card{padding:23px}.grid-2{grid-template-columns:1fr}.kpi-grid{grid-template-columns:repeat(2,1fr)}.analytics-grid{grid-template-columns:1fr}}@media(max-width:600px){.app-shell{padding:0 14px}.topbar{height:67px}.brand strong{font-size:15px}.brand small{font-size:9px}.brand-icon{width:34px;height:34px}.top-actions{gap:5px}.link-btn{font-size:11px}.view{padding-top:17px;min-height:calc(100dvh - 126px)}.hero h1{font-size:30px}.hero-highlights{gap:6px}.hero-highlights span{font-size:11px;padding:8px}.card{padding:20px 16px;border-radius:15px}.entry-layout{gap:17px}.entry-card{padding:22px 19px}.entry-card form label{margin:11px 0}.entry-card form input{min-height:43px;padding:10px 12px}.page-heading h1{font-size:25px}.keypad{gap:8px}.digit-btn{height:clamp(58px,10.5vh,80px)}.test-view{padding:0;min-height:calc(100dvh - 130px)}.test-card{padding:5px 0}.test-card .equation{padding:clamp(11px,5vh,33px) 0 0}.answer-placeholder{margin:2px auto 12px;width:53px;height:47px}.test-card .digit-btn{height:clamp(57px,10.4vh,77px)}.test-help{margin:9px 0}.test-top h1{font-size:19px}.admin-nav{margin:13px 0}.admin-header h1{font-size:24px}.admin-controls{flex-wrap:wrap}.admin-controls label{max-width:none}.report{padding:18px}.report-kpi{grid-template-columns:repeat(2,1fr)}.section-inline{flex-wrap:wrap}}@media(max-height:690px){.test-card .equation{padding:8px 0}.test-card .digit-btn{height:clamp(50px,10vh,67px)}.test-card .answer-placeholder{height:40px}.topbar{height:59px}.test-help{margin:5px}}@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto!important;animation:none!important;transition:none!important}}@media print{body{background:#fff}.topbar,footer,.admin-header,.admin-nav,.admin-controls,.tab-panel,.toast,#report-toolbar{display:none!important}.app-shell{max-width:none;padding:0}.view,.admin-view{display:block!important;padding:0}.report{display:block!important;border:0;box-shadow:none;margin:0;padding:0}#tab-reports{display:block!important}#report-sheet{display:block!important}.report h2{color:#111}.report-table{font-size:10pt}@page{size:A4 portrait;margin:15mm}}

body.testing .topbar,body.testing footer{display:none}body.testing .view{min-height:100dvh}body.testing .test-view{padding-top:max(12px,env(safe-area-inset-top,0px));padding-bottom:max(8px,env(safe-area-inset-bottom,0px))}body.testing .test-card .keypad{touch-action:manipulation}
/* Exam focus layout: keep the keypad within comfortable thumb reach on phones. */
body.testing .test-stage{min-height:calc(100dvh - 20px);display:flex;flex-direction:column}
body.testing .test-card{flex:1;display:flex;flex-direction:column;justify-content:center}
body.testing .test-card .keypad{width:100%}
body.testing .sync-line{padding-bottom:12px}
