:root{--ink:#123045;--dark:#0b344c;--teal:#07877e;--muted:#5d7481;--border:#d9e5ed;--bg:#f3f7fa}*{box-sizing:border-box}html{scroll-behavior:smooth}body{margin:0;background:var(--bg);color:var(--ink);font:15px/1.7 system-ui,'Noto Naskh Arabic',sans-serif}a{color:var(--teal);text-decoration:none}.header{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px max(14px,3%);background:#fff;border-bottom:1px solid var(--border)}.header .brand{display:flex;align-items:center;gap:12px;color:var(--dark);font-size:20px;font-weight:900}.brand img{width:45px;height:45px;border-radius:12px}.brand small{font-size:11px;color:var(--muted);display:block;line-height:1.1}.header nav{display:flex;align-items:center;flex-wrap:wrap;gap:15px;font-weight:750}.primary,button.primary{background:var(--teal);color:#fff;padding:9px 15px;border-radius:10px}.announcement{text-align:center;background:#e0f6ed;color:#165f4e;padding:9px 14px;font-weight:800}.shell{display:grid;grid-template-columns:245px minmax(0,1fr);max-width:1440px;margin:auto;gap:20px;padding:20px}.menu{background:white;border:1px solid var(--border);border-radius:20px;padding:17px;height:max-content;position:sticky;top:10px}.menu h3{margin:4px 8px 14px;color:var(--dark)}.menu button{width:100%;text-align:right;border:0;background:none;border-radius:11px;color:var(--ink);font:inherit;font-weight:700;padding:12px 13px;cursor:pointer}.menu button:hover,.menu button.active{background:#e3f6f1;color:#056f65}.sidebar-foot{border-top:1px solid var(--border);margin-top:16px;padding-top:14px;color:var(--muted);font-size:12px}.menu .muted{background:#f1f4f7;color:#637b89}.content{min-width:0}.content-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:8px 0 20px}.content-head small{color:var(--teal);font-weight:800}.content-head h1{margin:0;font-size:clamp(21px,2.6vw,30px)}.chip{border-radius:99px;background:#e9f7e5;color:#307c2a;font-size:12px;font-weight:800;padding:6px 12px}.chip.offline{background:#fff0d7;color:#8a541c}.grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:13px}.card{background:#fff;border:1px solid var(--border);border-radius:18px;padding:20px;margin-bottom:16px;box-shadow:0 7px 24px #16425906}.stat b{font-size:27px;display:block;color:var(--dark)}.stat small{color:var(--muted);font-weight:800}.card h2,.card h3{margin:0 0 12px}.card p{color:var(--muted);margin:7px 0}.actions{display:flex;gap:10px;flex-wrap:wrap;margin:14px 0}.button,button{font:inherit;cursor:pointer}.button{display:inline-block;background:var(--teal);color:white;border:0;border-radius:10px;padding:9px 14px;font-weight:750}.button.secondary{background:#e9f4f6;color:#135767}.button.warn{background:#b45c19;color:white}button:disabled{opacity:.5;cursor:not-allowed}.field{display:grid;gap:5px;font-size:13px;font-weight:750;min-width:130px}.field input,.field select,.field textarea,input,select{font:inherit;padding:9px 10px;border:1px solid #cadbe2;border-radius:9px;background:#fff;max-width:100%}.form-row{display:flex;align-items:end;gap:12px;flex-wrap:wrap}.table-wrap{overflow-x:auto}table{border-collapse:collapse;width:100%;min-width:560px;text-align:right}th,td{padding:11px 8px;border-bottom:1px solid #e7eff2}th{font-size:13px;color:var(--muted)}.tag{background:#e4f3f1;color:#087b73;border-radius:8px;padding:3px 9px;font-size:12px}.hint{font-size:13px;color:var(--muted)}.danger{color:#ae3d2f}.notice{background:#edf7fc;border:1px solid #c4e2f3;border-radius:12px;padding:13px 18px;margin:10px 0}.row{display:flex;align-items:center;gap:12px;flex-wrap:wrap}.two{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}.qr{background:#fff;padding:12px;display:inline-block;border:1px solid #d4e7e3;border-radius:10px}.qr svg{max-width:100%}.student-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.student-card{background:#fff;border:1px dashed #91b4bf;border-radius:16px;padding:12px;text-align:center}.student-card h4{margin:5px}.student-card small{display:block;color:#678}.student-card .qr{margin:9px}.library-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:9px}.resource{padding:13px;background:#f8fbfc;border:1px solid #dfe9ed;border-radius:10px}.resource b{display:block;font-size:13px}.resource small{color:#6b7d83}.resource a{font-weight:800}.safe{color:#19835d}.small{font-size:12px}.toast{position:fixed;bottom:20px;left:20px;padding:13px 18px;background:#123949;color:white;border-radius:12px;z-index:50;box-shadow:0 8px 24px #1234}.step{border-right:4px solid var(--teal);padding:8px 13px;background:#f4f9fc;margin-bottom:8px}footer{padding:28px;text-align:center;font-size:12px;color:#647985}@media(max-width:1020px){.grid{grid-template-columns:repeat(2,1fr)}.student-grid{grid-template-columns:repeat(2,1fr)}}@media(max-width:790px){.shell{display:block;padding:12px}.menu{position:static;display:flex;gap:6px;overflow-x:auto;white-space:nowrap;padding:8px;margin-bottom:16px;border-radius:13px}.menu h3,.sidebar-foot{display:none}.menu button{min-width:max-content;width:auto;padding:9px 12px}.header{align-items:start}.header nav{font-size:12px;gap:9px}}@media(max-width:540px){.two,.student-grid,.library-grid{grid-template-columns:1fr}.card{padding:15px}.header .brand{font-size:15px}.brand img{width:34px;height:34px}table{min-width:520px}}@media print{.header,.announcement,.menu,.content-head,.actions,footer,.no-print{display:none!important}.shell{display:block;padding:0}.card{box-shadow:none;break-inside:avoid}.student-grid{grid-template-columns:repeat(3,1fr)}}

.demo-login-top{display:none!important}.demo-login-float{position:fixed;right:15px;bottom:17px;z-index:1200;background:#123e56;color:white;padding:13px 20px;font-size:14px;border:2px solid white;box-shadow:0 7px 25px #0004;border-radius:40px;font-weight:900}.demo-login-float:hover,.demo-login-float:focus{background:#006d75;color:white}@media(max-width:790px){.demo-login-top{display:inline-flex!important;font-size:12px;padding:8px 11px;border-radius:9px;background:#123e56;color:#fff;margin-inline-start:auto}.header nav{gap:7px}.header nav a:not(.primary){display:none}.demo-login-float{right:10px;bottom:10px;padding:11px 17px}}
/* V0.19.9 — installed demo PWA has no horizontal document scrolling. */
@media(max-width:790px){
 html,body,.shell,.content,.card,.header{min-width:0;max-width:100%;overflow-x:clip}
 .menu{position:static!important;display:flex;flex-wrap:wrap!important;overflow:visible!important;white-space:normal!important}
 .menu button{min-width:0!important;flex:1 1 125px;width:auto!important;text-align:center}
 .header{flex-wrap:wrap}
 .header nav{flex-wrap:wrap}
 .table-wrap{overflow:visible!important}
 .table-wrap table{min-width:0!important;width:100%;display:block;white-space:normal}
 .table-wrap thead{display:none}
 .table-wrap tbody{display:grid;gap:9px}
 .table-wrap tbody tr{display:block;background:#fff;border:1px solid #dde7ed;border-radius:11px;padding:9px}
 .table-wrap tbody td{display:flex;justify-content:space-between;align-items:start;gap:8px;overflow-wrap:anywhere}
 .table-wrap tbody td:before{content:attr(data-label);font-size:.79rem;font-weight:800;color:#567;flex:0 0 34%}
 .table-wrap tbody td:not([data-label]):before{content:none}
 .step{min-width:0}
}
/* Bilingual layout polish — applies only to the public demo. */
.language-toggle{background:#ecf7f4;color:#07564a;border:1px solid #bcd8d0;border-radius:9px;padding:7px 12px;cursor:pointer;font-weight:800;min-width:65px}
html[lang="en"] .menu button,html[lang="en"] table{text-align:left}
html[lang="ur"] .menu button,html[lang="ur"] table{text-align:right}
html[lang="ur"] .step{border-right:4px solid var(--teal);border-left:0}
html[lang="en"] .step{border-left:4px solid var(--teal);border-right:0}
html[lang="en"] body{font-family:system-ui,-apple-system,'Segoe UI',sans-serif}
html[lang="ur"] body{font-family:'Noto Naskh Arabic','Noto Nastaliq Urdu',system-ui,sans-serif}
@media(max-width:790px){.menu button{text-align:center!important}.header nav{align-items:center}}
