:root{--ink:#17243b;--muted:#65758b;--bg:#f4f7fb;--line:#e0e7f0;--panel:#fff;--primary:#2258a8;--primary-d:#184480;--red:#b63847;--red-bg:#fff0f2;--green:#13815b;--green-bg:#ecf8f0;--radius:14px;--shadow:0 4px 20px rgba(25,53,98,.045)}
*{box-sizing:border-box}html,body{margin:0;min-height:100%;font-family:-apple-system,BlinkMacSystemFont,"PingFang SC","Microsoft YaHei","Noto Sans SC",sans-serif;color:var(--ink);background:var(--bg);font-size:14px;line-height:1.55}a{color:#1d5ca5;text-decoration:none}a:hover{text-decoration:underline}button,input,select,textarea{font:inherit}button,.button{background:var(--primary);border:1px solid var(--primary);border-radius:9px;color:#fff;min-height:38px;padding:9px 16px;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;font-weight:600;text-decoration:none;white-space:nowrap}button:hover,.button:hover{background:var(--primary-d);color:#fff;text-decoration:none}button.secondary,.button.secondary{background:#fff;color:var(--primary);border-color:#c6d5e9}button.secondary:hover,.button.secondary:hover{background:#eef4fb}button.small,.button.small{font-size:12px;padding:5px 10px;min-height:30px}.text-button{background:transparent;border:0;color:#245da0;padding:0;min-height:auto;font-weight:500}.text-button:hover{background:transparent;color:#123961;text-decoration:underline}input,select,textarea{width:100%;min-height:42px;outline:0;padding:9px 12px;border:1px solid #ced9e7;border-radius:9px;background:white;color:var(--ink)}textarea{min-height:100px;resize:vertical}input:focus,select:focus,textarea:focus{border-color:#478ed6;box-shadow:0 0 0 3px rgba(71,142,214,.13)}input[type=file]{min-height:auto;padding:7px}input[type=checkbox]{min-height:auto;width:auto;accent-color:var(--primary)}label{display:block;color:#32435c;font-weight:600}label input,label select,label textarea{margin-top:6px;font-weight:400}form{margin:0}h1,h2,h3,p{margin-top:0}h1{font-size:24px;line-height:1.3;letter-spacing:-.5px}h2{font-size:17px;line-height:1.4;margin-bottom:8px}small{font-size:12px}p{margin-bottom:14px}b,strong{font-weight:650}.muted,.hint{color:var(--muted)}.hint{font-size:12px}.top{height:70px;background:#fff;border-bottom:1px solid var(--line);display:flex;justify-content:space-between;align-items:center;padding:0 28px;position:sticky;top:0;z-index:4}.brand{display:flex;align-items:center;gap:11px;font-size:16px}.brand small{display:block;color:var(--muted);font-size:11px;letter-spacing:.3px}.brand-icon{display:inline-flex;align-items:center;justify-content:center;background:#1c5da5;border-radius:11px;width:38px;height:38px;color:#fff;font-size:20px;font-weight:700}.brand-icon.large{width:56px;height:56px;margin-bottom:20px;font-size:26px}.top-right{display:flex;align-items:center;gap:18px;color:#465978}.layout{display:grid;grid-template-columns:205px minmax(0,1fr);min-height:calc(100vh - 120px)}.sidebar{background:#fff;border-right:1px solid var(--line);padding:22px 14px}.sidebar a{color:#4d607c;display:block;border-radius:9px;padding:11px 15px;margin:2px 0;font-size:14px;font-weight:550}.sidebar a.selected{background:#eaf2fc;color:#145193;font-weight:700}.sidebar a:hover{background:#f2f6fb;text-decoration:none}.content{padding:30px 34px 55px;min-width:0;max-width:1510px;width:100%;margin:0 auto}.page-title{display:flex;align-items:end;justify-content:space-between;gap:20px;margin-bottom:20px}.page-title h1{margin:2px 0 0}.eyebrow{color:#8a97a9;display:block;font-size:12px;font-weight:700;letter-spacing:.8px}.class-switch{display:flex;align-items:center;gap:8px;max-width:390px;width:100%}.class-switch select{min-width:145px}.term-banner{border:1px solid #d9e6f5;background:#edf5fd;border-radius:10px;padding:12px 16px;margin-bottom:20px;display:flex;align-items:center;justify-content:space-between;gap:16px;color:#2d567d}.term-banner a{white-space:nowrap}.card{padding:23px;border:1px solid var(--line);background:var(--panel);box-shadow:var(--shadow);border-radius:var(--radius);margin-bottom:19px;min-width:0}.card.narrow{max-width:710px}.card h2{margin-bottom:8px}.section-head{display:flex;align-items:center;justify-content:space-between;gap:14px;margin-bottom:16px}.section-head h2{margin-bottom:3px}.section-head p{margin:0;color:var(--muted);font-size:13px}.section-head>a{white-space:nowrap}.stats{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin-bottom:19px}.stat{border-radius:var(--radius);background:#fff;border:1px solid var(--line);padding:21px;box-shadow:var(--shadow)}.card .stats .stat{background:#f9fbfe;box-shadow:none}.stat span{display:block;font-size:13px;color:var(--muted);font-weight:600}.stat b{display:block;font-size:29px;letter-spacing:-1px;margin:6px 0 0;font-variant-numeric:tabular-nums}.stat small{color:#8794a5}.table-wrap{width:100%;overflow:auto}table{border-collapse:collapse;width:100%;min-width:670px;font-size:13px}th{text-align:left;font-size:12px;white-space:nowrap;background:#f7f9fc;color:#67788d;font-weight:700}td,th{border-bottom:1px solid #ecf0f6;padding:12px 13px;vertical-align:middle}tbody tr:hover{background:#fbfdff}tbody tr:last-child td{border-bottom:0}.score{font-size:16px;color:#184784;font-variant-numeric:tabular-nums}.good{color:var(--green)!important}.bad{color:var(--red)!important}.pill{display:inline-block;background:#f0f2f5;color:#5e6a78;border-radius:20px;padding:3px 8px;font-size:11px;font-weight:700}.pill.good-bg{background:var(--green-bg);color:var(--green)}.pill.bad-bg{background:var(--red-bg);color:var(--red)}.actions{white-space:nowrap}.actions a,.actions form{margin-right:12px}.inline-form{display:inline-block}.bottom-link{text-align:right;margin-top:12px}.empty{padding:40px 12px;text-align:center;color:#8290a4;border-radius:9px;background:#f9fbfe}.toolbar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin-bottom:18px}.toolbar input:not([type=file]){flex:1;min-width:180px;max-width:360px}.toolbar select{max-width:245px}.toolbar button,.toolbar .button{white-space:nowrap}.stack{display:flex;flex-direction:column;gap:16px}.stack h2{margin-top:5px;margin-bottom:0}.form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}.button-row{display:flex;gap:10px;align-items:center;flex-wrap:wrap}.alert{border-radius:10px;background:#eef6fd;border:1px solid #cde0f7;padding:13px 17px;color:#2c527b;margin-bottom:18px}.alert.error{background:#fff3f4;border-color:#f3cbd0;color:#9d3240}.tab-row{display:flex;gap:8px;margin-bottom:17px}.tab-row a{padding:10px 17px;border:1px solid var(--line);border-radius:9px;background:white;color:#5f7190;font-weight:650}.tab-row a.active{background:#2258a8;color:#fff;border-color:#2258a8}.record-list{display:flex;flex-direction:column;gap:10px}.record{border:1px solid var(--line);border-radius:10px;padding:15px;background:#fff}.record.void{opacity:.66}.record-main{display:flex;justify-content:space-between;gap:18px;align-items:center}.record-main strong{font-size:15px}.record-main>strong{white-space:nowrap;font-size:18px;font-variant-numeric:tabular-nums}.record-meta{font-size:12px;margin:8px 0;color:#8791a0}.note{margin:9px 0 0;white-space:normal}.void-note{color:#8b6572;margin:9px 0 0;font-size:12px}.void-form{display:flex;gap:9px;align-items:center;margin-top:10px}.void-form input{min-height:34px;max-width:380px}.two-column{display:grid;grid-template-columns:1fr 1fr;gap:19px}.bar-row{margin-top:17px;display:grid;gap:7px}.bar-row>div:first-child{display:flex;justify-content:space-between;gap:14px;font-size:13px}.bar-row small{color:var(--muted)}.bar-track{height:9px;background:#edf2f9;border-radius:20px;overflow:hidden}.bar-fill{background:#2e6db2;height:100%;border-radius:20px}.check-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.check{padding:9px;background:#f8fbfe;border-radius:7px}.check input{margin:0 8px 0 0}fieldset{border:1px solid var(--line);border-radius:9px;padding:14px}legend{padding:0 8px;font-weight:650}.footer{padding:18px;text-align:center;font-size:12px;color:#8b98a8}.login-content{min-height:calc(100vh - 125px);display:flex;align-items:center;justify-content:center;padding:30px 18px}.login-card{width:100%;max-width:435px;padding:38px;background:white;border:1px solid var(--line);border-radius:18px;box-shadow:0 15px 46px rgba(12,43,79,.08)}.login-card h1{margin-bottom:7px}.login-card button{width:100%;margin-top:8px}.install{max-width:820px;margin:35px auto;padding:0 16px 50px}.install h1{margin-bottom:8px}.install .card{margin-top:20px}
@media(max-width:1000px){.content{padding:24px 20px 50px}.sidebar{padding:16px 9px}.layout{grid-template-columns:160px 1fr}.sidebar a{padding:10px}.stats{grid-template-columns:repeat(2,1fr)}.two-column{grid-template-columns:1fr}}
@media(max-width:700px){.top{height:62px;padding:0 14px}.brand{font-size:14px}.brand small{font-size:10px}.top-right{gap:7px;font-size:11px}.brand-icon{height:34px;width:34px}.layout{display:block}.sidebar{display:flex;overflow:auto;padding:9px 12px;border-right:0;border-bottom:1px solid var(--line);gap:5px;position:sticky;top:62px;z-index:3}.sidebar a{white-space:nowrap;flex:0 0 auto;padding:8px 12px;font-size:12px}.content{padding:19px 13px 36px}.page-title{flex-direction:column;align-items:stretch;gap:12px}.page-title h1{font-size:21px}.class-switch{max-width:none}.class-switch select{flex:1}.card{padding:17px 13px;margin-bottom:13px}.section-head{align-items:flex-start;flex-wrap:wrap}.stats{gap:9px;margin-bottom:13px}.stat{padding:14px}.stat b{font-size:24px}.stat span{font-size:11px}.term-banner{align-items:flex-start;font-size:12px}.two-column{gap:0}.form-grid,.check-grid{grid-template-columns:1fr}.toolbar{align-items:stretch}.toolbar input,.toolbar select{max-width:none!important}.toolbar>*{flex:1 1 120px}.void-form{align-items:stretch;flex-direction:column}.record-main strong{font-size:14px}.record-main>strong{font-size:17px}.login-card{padding:26px 23px}.install{margin-top:20px}}

.category-progress{display:block;width:100%;height:10px;accent-color:#2e6db2;border:0;border-radius:20px;overflow:hidden}.category-progress::-webkit-progress-bar{background:#edf2f9;border-radius:20px}.category-progress::-webkit-progress-value{background:#2e6db2;border-radius:20px}.category-progress::-moz-progress-bar{background:#2e6db2;border-radius:20px}
.ai-toolbar{display:flex;gap:12px;align-items:center;flex-wrap:wrap;margin-bottom:18px}.ai-mic{font-size:16px;min-height:50px}.ai-toolbar .hint{flex:1 1 200px}.ai-rows{display:grid;gap:14px;margin:14px 0}.ai-entry{border:1px solid #cdddec;border-radius:12px;padding:17px;background:#fafcff}.ai-entry .section-head{margin-bottom:12px}.ai-entry .form-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.ai-entry label{font-size:13px}@media(max-width:700px){.ai-entry{padding:12px}.ai-entry .form-grid{grid-template-columns:1fr}.ai-toolbar button{flex:1 1 140px}}
/* V1.3 compact app-style responsive design */
:root{--bg:#eef3fa;--radius:18px;--shadow:0 6px 24px rgba(20,62,106,.055)}
html{-webkit-tap-highlight-color:transparent}body{background:linear-gradient(180deg,#e9f2ff 0,#f6f8fc 360px,#f6f8fc 100%)}
.top{box-shadow:0 2px 8px rgba(22,54,98,.04)}.content{max-width:1280px}.brand-icon{border-radius:15px;background:linear-gradient(130deg,#1764c0,#124785)}
.button,button{border-radius:12px;min-height:44px;transition:background-color .12s ease}button:disabled{opacity:.52;cursor:not-allowed}
.card{border-radius:18px}.stat{border-radius:17px}.score-emphasis{display:flex;flex-direction:column;align-items:flex-end}.score-emphasis span{font-size:13px;color:#5b708e}.score-emphasis strong{font-size:42px;color:#2258a8;line-height:1.2}
.personal-hero{display:flex;align-items:center;justify-content:space-between;gap:18px;background:linear-gradient(118deg,#fff,#f3f8ff);border-color:#cadef3}.personal-hero h2{font-size:28px;margin:7px 0 5px}.personal-stats{margin-top:0}.personal-record{display:flex;justify-content:space-between;gap:12px;padding:15px 3px;border-bottom:1px solid #e8eef7;flex-wrap:wrap}.personal-record:last-child{border-bottom:0}.personal-record .record-title{display:flex;align-items:center;gap:10px;flex-wrap:wrap;flex:1}.personal-record .record-title small{color:#8190a3}.personal-record>strong{font-size:18px;white-space:nowrap}.personal-record .record-note{flex-basis:100%;color:#60748d;font-size:13px;padding-left:4px;white-space:pre-wrap;overflow-wrap:anywhere}.report-caution{padding:0 8px;color:#60748d;font-size:12px}.print-heading{display:none}
.student-account-list{display:grid;gap:8px}.student-account-row{border:1px solid #e2e9f5;border-radius:13px;padding:13px 14px;display:flex;align-items:center;justify-content:space-between;gap:10px;background:#fbfcff}.student-account-row>.button-row{flex-wrap:wrap}.student-layout{width:100%;min-height:calc(100vh - 145px)}.student-content{max-width:950px;margin:0 auto}.report-actions{max-width:930px}
.mobile-bottom-nav{display:none}.top-right form{display:inline-flex}
@media(max-width:700px){
  body{background:#f2f6fc}.top{height:59px;padding:0 14px}.top-right>span{max-width:94px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  .layout{display:block}.sidebar{display:none}.content{padding:18px 13px 105px;max-width:600px}.student-content{padding-bottom:110px}
  .mobile-bottom-nav{display:flex;position:fixed;bottom:0;left:0;right:0;background:#fff;border-top:1px solid #dbe5f4;box-shadow:0 -4px 22px rgba(30,54,88,.07);z-index:20;align-items:stretch;justify-content:space-around;padding:8px 4px max(8px,env(safe-area-inset-bottom));gap:1px}
  .mobile-bottom-nav a{flex:1;text-decoration:none;text-align:center;color:#6f829e;font-size:11px;display:flex;flex-direction:column;align-items:center;justify-content:center;min-width:0;padding:5px 2px;font-weight:650}
  .mobile-bottom-nav a strong{display:block;font-size:21px;font-weight:400;line-height:1.25}.mobile-bottom-nav a.selected{color:#1e5fac}.mobile-bottom-nav a.selected strong{font-weight:700}
  .footer{display:none}.page-title{margin-bottom:15px}.page-title h1{font-size:23px}.page-title .eyebrow{font-size:10px}
  .stats{grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}.stat{padding:15px 12px;border-radius:15px}.stat b{font-size:25px}.stat span{font-size:12px}
  .card{padding:18px 14px;border:1px solid #e4eaf5;box-shadow:0 3px 13px rgba(25,53,98,.035);margin-bottom:13px}
  .section-head{gap:9px}.section-head .button-row{flex-wrap:wrap}.student-account-row{align-items:flex-start;flex-direction:column}.student-account-row>.button-row{width:100%}
  .student-account-row>.button-row>*{flex:0 0 auto}.personal-hero{border-radius:18px;padding:22px 16px}.personal-hero h2{font-size:25px}.score-emphasis strong{font-size:37px}
  .personal-record{align-items:flex-start}.personal-record .record-title{gap:5px}.personal-record .record-title b{font-size:14px}.personal-record .record-title small{flex-basis:100%;margin-left:1px}
  .ai-entry{border-radius:13px;padding:14px}.ai-entry input,.ai-entry select{min-height:46px}.login-card{border-radius:20px}
  .button,button{min-height:43px}.toolbar button{flex:1}.report-actions .button-row{display:grid;grid-template-columns:1fr 1fr}.report-actions .button-row>:last-child:nth-child(3){grid-column:1/-1}
}
@media print{
 @page{size:A4;margin:13mm}
 body{background:white!important;color:#000!important;font-size:11pt}.top,.sidebar,.mobile-bottom-nav,.page-title,.report-actions,.footer,.class-switch{display:none!important}
 .layout,.student-layout{display:block!important}.content,.student-content{padding:0!important;max-width:none!important;margin:0!important}
 .personal-report{display:block!important}.print-heading{display:block;font-size:18pt;font-weight:700;text-align:center;margin-bottom:18pt}
 .card,.stat{box-shadow:none!important;border:1px solid #d6d6d6!important;break-inside:avoid}.stats{grid-template-columns:repeat(4,1fr)}
 .personal-record{break-inside:avoid;border-bottom:1px solid #ddd}.record-note{font-size:10pt!important}.report-caution{font-size:9pt}
 .personal-hero{background:none!important}.score-emphasis strong{color:#000!important}.record-list,.personal-record-list{display:block}.alert{display:none!important}
}
.mobile-student-cards{display:none}
@media(max-width:700px){
 .student-summary{display:none}.mobile-student-cards{display:grid;gap:9px}
 .mobile-student-card{background:#fff;border:1px solid #e0e8f4;border-radius:15px;padding:14px 14px 11px}
 .mobile-student-head{display:flex;justify-content:space-between;gap:10px;align-items:center}.mobile-student-head b{font-size:17px}.mobile-student-head small{display:block;font-size:11px;color:#8290a5}
 .mobile-student-head strong{color:#2258a8;font-size:24px;line-height:1;text-align:right}
 .mobile-student-metrics{display:flex;gap:12px;margin:11px 0 10px;font-size:12px;flex-wrap:wrap;color:#60728b}
 .mobile-student-actions{border-top:1px solid #edf1f7;padding-top:9px;display:flex;justify-content:space-between;gap:8px;font-size:13px;font-weight:650}
 .mobile-student-actions a{flex:1;text-align:center}
}
.more-links{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.more-links a{position:relative;border:1px solid #e0e8f3;border-radius:14px;background:#fafcff;padding:15px 36px 15px 16px;color:#273b58;text-decoration:none}.more-links b{display:block;font-size:16px}.more-links small{display:block;color:#74859c;margin-top:3px}.more-links span{position:absolute;right:16px;top:50%;transform:translateY(-50%);color:#7890ac;font-size:25px}.more-links a:hover{background:#edf5ff}
@media(max-width:700px){.more-links{grid-template-columns:1fr;gap:9px}.more-links a{padding:15px 34px 15px 16px}}
/* V1.4 - touch-first responsive UI. This block intentionally overrides earlier mobile styles. */
:root{--app-blue:#2563eb;--app-line:#e6ebf4}
html{scroll-padding-top:76px}body{overflow-x:hidden}a,button,input,select,textarea{touch-action:manipulation}
.button,button{display:inline-flex;align-items:center;justify-content:center;gap:6px;max-width:100%;min-height:44px;line-height:1.25}
input,select,textarea{max-width:100%;min-width:0}
.table-wrap{max-width:100%}.record,.card,.stat,.mobile-student-card{min-width:0}.record-main,.page-title{min-width:0}
.paper-row-list{display:grid;gap:12px}.paper-entry{background:#fff;border:1px solid #dce5f3;border-radius:17px;padding:15px;box-shadow:0 2px 9px rgba(26,54,92,.025)}
.paper-entry-head{display:flex;gap:9px;align-items:center;flex-wrap:wrap;margin-bottom:10px}.paper-entry-head strong{font-size:13px;color:#4f6281;overflow-wrap:anywhere}.paper-toggle{display:flex;align-items:center;gap:8px;font-weight:700;margin-right:auto;color:#223f66;white-space:nowrap}.paper-toggle input{width:20px;height:20px;accent-color:#1d66c2;margin:0}
.paper-grid{display:grid;grid-template-columns:2fr 1fr 1fr 1.4fr;gap:10px}.paper-grid label{min-width:0}.paper-grid label input,.paper-grid label select{width:100%;margin-top:5px}.paper-wide{grid-column:span 2}
.import-summary{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin:12px 0}.import-summary>div{padding:16px 10px;background:#fff;border:1px solid #e0e8f4;border-radius:15px;text-align:center}.import-summary b{display:block;font-size:24px;color:#1f55a4}.import-summary small{font-size:12px;color:#63768e}
.date-fill{display:flex;align-items:end;gap:10px;margin:12px 0;flex-wrap:wrap}.date-fill label{flex:1;min-width:180px}.paper-sticky{position:sticky;bottom:0;display:flex;align-items:center;justify-content:space-between;gap:10px;padding:12px 10px;background:#fff;border:1px solid #dfE8f4;border-radius:14px;z-index:6;box-shadow:0 -4px 18px rgba(19,52,104,.07)}
@media(max-width:700px){
 html,body{width:100%;max-width:100%;overflow-x:hidden;font-size:15px}
 .top{height:64px;padding:0 15px;padding-top:env(safe-area-inset-top);box-sizing:content-box;position:sticky;top:0;z-index:15;background:#fff}
 .brand{gap:9px;min-width:0}.brand b{font-size:15px;line-height:1.2}.brand small{max-width:162px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;display:block;font-size:10px}
 .brand-icon{width:38px;height:38px;flex-shrink:0}.top-right{gap:0}.top-right>span{display:none}.top-right .text-button{font-size:12px;padding:7px 4px;white-space:nowrap}
 .content{width:100%;max-width:100%;padding:15px 12px calc(108px + env(safe-area-inset-bottom))!important}
 .student-content{max-width:100%}.page-title{display:flex;flex-direction:column;gap:8px;margin:0 0 14px}.page-title h1{font-size:22px;line-height:1.3}
 .page-title .class-switch{display:flex;gap:8px;width:100%;align-items:center}.page-title .class-switch select{flex:1;width:1px;min-width:0}.page-title .class-switch button{flex:none}
 .card{padding:16px 13px;border-radius:18px;margin-bottom:12px}.card h2{font-size:18px}.card p{overflow-wrap:anywhere}
 input:not([type=checkbox]):not([type=radio]):not([type=hidden]), select,textarea{font-size:16px;min-height:46px;border-radius:11px}
 textarea{min-height:120px}.form-grid{grid-template-columns:1fr}.button-row{display:flex;gap:8px;flex-wrap:wrap}.button-row>a,.button-row>button{flex:1 1 42%;padding:11px 8px;text-align:center}
 .toolbar{display:flex;flex-direction:column;gap:9px}.toolbar>*{width:100%;flex:none!important}.toolbar .button,.toolbar button{justify-content:center}.toolbar input[type=file]{font-size:13px;max-width:100%}
 .stats{grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}.stat{padding:14px 12px}.stat b{font-size:26px;word-break:break-word}
 .mobile-bottom-nav{min-height:66px;padding:7px 2px calc(8px + env(safe-area-inset-bottom));border-radius:18px 18px 0 0;z-index:30;box-shadow:0 -5px 22px rgba(18,49,101,.12)}
 .mobile-bottom-nav a{font-size:11px;gap:2px;min-height:45px;padding:4px 1px}.mobile-bottom-nav a strong{font-size:24px}.mobile-bottom-nav a.selected{background:#eef5ff;border-radius:12px}
 .record{border-radius:13px;padding:12px}.record-main{gap:8px;align-items:start}.record-meta{font-size:12px;line-height:1.6;overflow-wrap:anywhere}.void-form input{width:100%}.void-form button{width:100%}
 .student-summary{display:none}.mobile-student-cards{display:grid;gap:10px}.mobile-student-head{min-width:0}.mobile-student-head b{overflow-wrap:anywhere}
 /* Every desktop data grid becomes a legible stacked card, no horizontal scrolling. */
 .table-wrap:not(.student-summary){overflow:visible!important;width:100%;max-width:100%}
 .table-wrap:not(.student-summary) table,.table-wrap:not(.student-summary) tbody{display:block!important;width:100%!important;min-width:0!important;table-layout:auto!important}
 .table-wrap:not(.student-summary) thead{display:none!important}
 .table-wrap:not(.student-summary) tbody tr{display:block!important;background:#fff;border:1px solid #e3eaf5;border-radius:13px;margin:0 0 10px;padding:7px 12px;box-shadow:0 2px 8px rgba(20,60,100,.035);overflow:hidden}
 .table-wrap:not(.student-summary) tbody td{display:flex!important;align-items:start;justify-content:space-between;gap:10px;width:100%!important;max-width:100%;padding:9px 0!important;border:0!important;border-bottom:1px solid #eef2f8!important;white-space:normal!important;overflow-wrap:anywhere;text-align:right;min-height:34px}
 .table-wrap:not(.student-summary) tbody td:last-child{border-bottom:0!important}
 .table-wrap:not(.student-summary) tbody td::before{content:attr(data-label);display:block;min-width:70px;max-width:42%;font-size:12px;color:#75849a;text-align:left;flex:none}
 .table-wrap:not(.student-summary) tbody td>a,.table-wrap:not(.student-summary) tbody td>form{max-width:66%}
 .table-wrap:not(.student-summary) tbody td[colspan]{display:block!important;text-align:center}
 .table-wrap:not(.student-summary) tbody td[colspan]::before{display:none}
 .paper-grid{grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:10px}
 .paper-entry{padding:13px 11px;border-radius:15px}.paper-grid .paper-wide{grid-column:1/-1}.paper-grid label{font-size:12px}.paper-grid label input,.paper-grid label select{font-size:15px!important;min-height:43px!important}
 .import-summary{gap:6px}.import-summary>div{padding:11px 6px}.import-summary b{font-size:23px}.import-summary small{font-size:10px}
 .paper-sticky{position:fixed;bottom:calc(75px + env(safe-area-inset-bottom));left:8px;right:8px;padding:9px 10px;z-index:18;border-radius:15px}.paper-sticky button{flex:1;white-space:normal;line-height:1.25}
 #paper-commit{padding-bottom:76px}.date-fill{flex-direction:column;align-items:stretch}.date-fill>button{width:100%}
 .login-content{padding:26px 14px}.login-card{padding:22px 17px}.login-card h1{font-size:23px}
 .footer{display:none}
}
@media(max-width:370px){.brand small{max-width:118px}.content{padding-left:9px!important;padding-right:9px!important}.mobile-bottom-nav a{font-size:10px}.paper-grid{grid-template-columns:1fr}}
@media print{.paper-sticky,.paper-toggle,.date-fill,.paper-entry-head{display:none!important}.paper-entry{break-inside:avoid}}

/* V1.5 - mobile application layout. Cache-busted via ?v=1.5.0 */
.mobile-bottom-nav{display:none}
.filter-field{display:flex;flex-direction:column;gap:5px;min-width:0;flex:1}.filter-field span{font-size:12px;color:#65758c;font-weight:700}
.filter-field input,.filter-field select{margin-top:0}.filter-toolbar{display:flex;flex-wrap:wrap;align-items:end;gap:10px;margin-bottom:8px}.filter-toolbar button{flex:0 0 auto}
.list-tools{display:flex;justify-content:end;padding:3px 0 12px;font-size:13px}
.nav-icon svg{display:block;width:23px;height:23px}.nav-icon{display:grid;place-items:center;height:25px}
@media screen and (max-width:850px){
 html,body{width:100%;max-width:100%;margin:0;overflow-x:clip}
 body{background:#f3f6fb;font-size:15px;padding-bottom:0}
 .top{height:56px;min-height:56px;box-sizing:border-box;position:sticky;top:0;z-index:60;padding:0 13px;background:rgba(255,255,255,.98);border-bottom:1px solid #e8eef6;box-shadow:0 1px 3px rgba(20,40,80,.025)}
 .top .brand{gap:9px;flex:1;min-width:0;overflow:hidden}.top .brand b{font-size:16px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;display:block;max-width:calc(100vw - 135px)}
 .top .brand small{font-size:11px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:calc(100vw - 136px)}
 .brand-icon{width:36px;height:36px;min-width:36px;font-size:19px;border-radius:11px}
 .top-right{gap:2px;flex:none}.top-right>span{display:none!important}.top-right .text-button{font-size:12px;padding:5px 8px;min-height:36px;color:#64748b}
 .layout,.student-layout{display:block!important;width:100%;max-width:100%;min-width:0;min-height:0;overflow:visible}
 .sidebar,.layout>.sidebar{display:none!important}
 main.content,.content,.student-content{display:block;width:100%;max-width:100%;min-width:0;padding:15px 12px calc(112px + env(safe-area-inset-bottom))!important;margin:0 auto}
 .page-title{display:flex;flex-direction:column;align-items:stretch;gap:10px;margin:0 0 14px}
 .page-title .eyebrow{font-size:11px}.page-title h1{font-size:22px;margin:0;line-height:1.25}
 .class-switch,.page-title .class-switch{width:100%;max-width:none;display:flex;gap:8px;align-items:center}
 .class-switch select{flex:1;min-width:0;width:0}.class-switch button{white-space:nowrap;flex:0 0 auto}
 .card{padding:15px 13px;border-radius:17px;margin-bottom:12px;box-shadow:0 2px 10px rgba(39,74,120,.025)}
 .section-head{display:flex;align-items:flex-start;flex-wrap:wrap;gap:10px;margin-bottom:13px}
 .section-head>.button-row{display:flex;flex-wrap:wrap;width:100%;gap:7px}.section-head>.button-row>a{flex:1 1 auto}
 .section-head h2{font-size:18px}.stats{grid-template-columns:repeat(2,minmax(0,1fr));gap:9px;margin-bottom:12px}
 .stat{padding:14px 12px;min-width:0}.stat b{font-size:25px;overflow-wrap:anywhere}.stat span{font-size:12px}
 .term-banner{gap:10px;flex-wrap:wrap;padding:11px 13px;margin-bottom:12px;font-size:12px}
 .filter-toolbar,.toolbar{display:grid!important;grid-template-columns:minmax(0,1fr)!important;gap:10px;width:100%}
 .filter-toolbar>*{min-width:0;max-width:100%;width:100%}
 .filter-toolbar button,.toolbar>button{min-height:46px;width:100%;padding:10px 14px}
 .filter-field{width:100%}.filter-field select,.filter-field input{width:100%}
 .mobile-student-cards{display:grid;grid-template-columns:1fr;gap:9px}.student-summary{display:none!important}
 .mobile-student-card{padding:14px;border-radius:14px;min-width:0}.mobile-student-actions{gap:6px}
 .mobile-student-actions a{background:#eff5ff;border-radius:9px;padding:10px 6px;min-height:42px;display:grid;place-items:center;font-size:13px;color:#2059a9}
 .mobile-bottom-nav{display:flex!important;position:fixed!important;bottom:0;left:0;right:0;width:100%;height:calc(63px + env(safe-area-inset-bottom));min-height:0;max-height:none;padding:5px 6px calc(4px + env(safe-area-inset-bottom));margin:0;border-top:1px solid #e2e8f3;border-radius:0;background:#fff;z-index:1000;box-shadow:0 -2px 15px rgba(16,47,89,.09);align-items:stretch;justify-content:space-around;gap:2px}
 .mobile-bottom-nav a{flex:1;min-width:0;min-height:48px;display:flex;align-items:center;justify-content:center;flex-direction:column;gap:2px;font-size:11px;line-height:1.2;font-weight:650;color:#738199;text-decoration:none;padding:5px 1px;border-radius:12px;white-space:nowrap}
 .mobile-bottom-nav a .nav-icon{height:25px;color:inherit}.mobile-bottom-nav a .nav-label{display:block;font-size:11px}
 .mobile-bottom-nav a.selected{color:#1d61b2;background:#edf4ff}
 .mobile-bottom-nav a:active{background:#eaf0fa}
 .footer{display:none!important}
 .record,.personal-record{min-width:0;overflow-wrap:anywhere}
 .record-main{flex-wrap:wrap;gap:8px}.void-form{flex-wrap:wrap}.void-form input{flex:1 1 100%;width:100%}.void-form button{width:100%}
 input:not([type=hidden]):not([type=checkbox]),select,textarea{min-width:0;max-width:100%;font-size:16px}
 .button-row{display:flex;gap:8px;flex-wrap:wrap}.button-row>*{flex:1 1 auto;white-space:normal;min-height:44px}
 .more-links{grid-template-columns:1fr}
}
@media screen and (min-width:701px) and (max-width:850px){.table-wrap:not(.student-summary) table{min-width:0}.mobile-student-cards{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media screen and (max-width:390px){.content,main.content{padding-left:10px!important;padding-right:10px!important}.top .brand b{font-size:15px}.mobile-bottom-nav a .nav-label{font-size:10px}}

/* V1.6 Compact mobile management - consistent single- and double-line lists */
.compact-filter{background:#f7faff;border:1px solid #e5edf7;border-radius:16px;padding:13px;display:grid;gap:12px;margin:12px 0}
.filter-grid,.filter-grid-students{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.filter-grid-students{grid-template-columns:minmax(0,2fr) minmax(0,1.4fr)}
.filter-field{min-width:0;display:grid;gap:5px}.filter-field span{color:#5a6f89;font-size:12px;font-weight:650}
.filter-field input,.filter-field select{min-width:0;width:100%;margin:0!important;border-radius:11px;background:#fff}
.filter-foot{display:flex;justify-content:space-between;align-items:end;gap:12px}
.filter-foot>.sort-compact{max-width:240px;flex:1}
.filter-action-row{display:flex;gap:8px;align-items:center;justify-content:flex-end}
.filter-action-row>a,.filter-action-row>button{min-width:82px;min-height:41px;padding:8px 15px}
.mobile-records,.student-list-caption{display:none}
.export-panel{border:1px solid #dce8f8;border-radius:15px;margin:14px 0;background:#fff;overflow:hidden}
.export-panel>summary{list-style:none;cursor:pointer;display:flex;gap:4px;align-items:flex-start;flex-direction:column;padding:13px 15px;color:#205a9e;font-weight:700;background:#f5f9ff;position:relative;padding-right:38px}
.export-panel>summary::-webkit-details-marker{display:none}
.export-panel>summary small{font-weight:400;color:#7a8a9d}
.export-panel>summary:after{content:'⌄';font-size:22px;position:absolute;right:15px;top:11px;line-height:1}
.export-panel[open]>summary:after{transform:rotate(180deg)}
.export-form{padding:14px;display:grid;gap:14px}
.export-fields{border:0;padding:0;margin:0;min-width:0}.export-fields legend{font-weight:650;color:#394c64;padding:0 0 8px}
.export-checks{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px}
.export-checks label{border:1px solid #e2eaf5;border-radius:10px;display:flex;align-items:center;gap:7px;padding:9px;font-size:13px;font-weight:500;cursor:pointer;min-width:0}
.export-checks label:has(input:checked){background:#edf5ff;border-color:#bed6f7;color:#215a9e}
.export-checks input{margin:0;width:16px;height:16px;min-height:0;accent-color:#2461ae}
.export-button{justify-self:start}
.ai-main-card{overflow:hidden}.ai-hero{display:flex;align-items:center;gap:14px;margin-bottom:16px}
.ai-hero h2{font-size:22px;margin:1px 0 5px;letter-spacing:-.4px}.ai-hero p{margin:0;font-size:13px;color:#70829b}
.ai-icon{background:linear-gradient(135deg,#215bb1,#478bdb);color:white;flex:none;display:grid;place-items:center;width:56px;height:56px;border-radius:17px;font-size:29px;box-shadow:0 6px 20px rgba(35,99,178,.18)}
.ai-eyebrow{font-size:12px;letter-spacing:.8px;color:#2666b9;font-weight:750}
.ai-steps{display:flex;gap:7px;margin-bottom:20px}.ai-steps span{flex:1;min-width:0;text-align:center;color:#8a98ac;white-space:nowrap;font-size:12px;background:#f6f8fc;border-radius:10px;padding:9px 4px}
.ai-steps span.on{background:#eaf3ff;color:#195ba9;font-weight:700}.ai-steps b{display:inline-grid;place-items:center;background:#e7edf5;border-radius:100%;width:21px;height:21px;margin-right:4px;font-size:11px}.ai-steps span.on b{background:#2565b8;color:white}
.ai-editor-label{font-size:14px;font-weight:700;margin-bottom:7px}.ai-editor-shell{border:1px solid #cbdced;border-radius:14px;overflow:hidden;background:#fff}
.ai-editor-shell:focus-within{border-color:#448add;box-shadow:0 0 0 3px rgba(42,115,203,.12)}
.ai-editor-shell textarea{border:0!important;box-shadow:none!important;border-radius:0!important;min-height:160px;line-height:1.75;padding:14px 16px;resize:vertical;margin:0}
.ai-editor-bottom{display:flex;justify-content:space-between;gap:8px;align-items:center;padding:5px 13px 10px;font-size:11px;color:#8492a3}
.ai-samples{display:flex;flex-wrap:wrap;align-items:center;gap:7px;margin:12px 0 16px}.ai-samples span{color:#728199;font-size:12px}
.ai-example,.ai-example:hover{background:#f3f7fe;color:#32639d;border:1px solid #dfeafa;border-radius:999px;font-size:12px;font-weight:550;padding:6px 12px;min-height:33px}
.ai-main-actions{display:flex;align-items:center;gap:10px}.ai-main-actions #ai-parse{min-height:49px;font-size:15px;flex:1;box-shadow:0 6px 14px rgba(34,88,168,.14)}
.ai-main-actions #ai-clear{min-height:49px;flex:0 0 84px}.ai-privacy{margin:12px 0 0;color:#8694a8;font-size:12px;line-height:1.7}
.ai-preview-title{margin-top:22px;display:flex;flex-direction:column;gap:3px;border-top:1px solid #e5edf7;padding-top:18px}.ai-preview-title b{font-size:17px}.ai-preview-title span{font-size:12px;color:#718399}
.ai-save-bar{display:flex;justify-content:space-between;align-items:center;gap:8px}.ai-save-bar button{min-height:48px}
@media screen and (max-width:850px){
 .student-summary{display:none!important}
 .mobile-student-cards{display:block!important;min-width:0;max-width:100%}
 .student-list-caption,.student-line{display:grid!important;grid-template-columns:minmax(0,1.25fr) minmax(0,.95fr) minmax(0,1.15fr) 48px;gap:5px;align-items:center}
 .student-list-caption{font-size:10px;font-weight:650;color:#8592a5;text-align:center;padding:7px 5px 6px;margin-bottom:3px}
 .student-list-caption span:first-child{text-align:left;padding-left:4px}
 .student-line{min-width:0;background:white;border:0;border-bottom:1px solid #edf1f7;padding:9px 5px;min-height:51px;margin:0;box-shadow:none;line-height:1.2;overflow:hidden}
 .student-line:last-child{border-bottom:0}
 .student-line-name{font-size:14px;font-weight:700;text-overflow:ellipsis;white-space:nowrap;overflow:hidden;min-width:0}
 .student-line-score{font-size:13px;text-align:center;font-variant-numeric:tabular-nums;white-space:nowrap;letter-spacing:-.4px;overflow:hidden;text-overflow:ellipsis}
 .student-line-change{min-width:0;font-size:10px;white-space:nowrap;display:flex;justify-content:space-around;gap:2px;font-variant-numeric:tabular-nums;overflow:hidden}
 .student-line-change b{font-weight:650;overflow:hidden;text-overflow:ellipsis;min-width:0}
 .student-line-detail{color:#2363ae;background:#eff6ff;text-align:center;white-space:nowrap;font-size:11px;font-weight:650;border-radius:8px;min-height:33px;display:grid;place-items:center;padding:3px 0}
 .records-desktop{display:none!important}
 .mobile-records{display:grid!important;gap:0;min-width:0}
 .compact-record{background:#fff;padding:10px 4px;border-bottom:1px solid #ebf1f7;min-width:0;max-width:100%;overflow:hidden}
 .compact-record:last-child{border-bottom:0}
 .compact-record.is-void{opacity:.65}
 .record-line-1{display:grid;grid-template-columns:minmax(48px,auto) minmax(0,1fr) auto;align-items:center;gap:8px;min-height:23px;min-width:0}
 .record-student{font-weight:750;font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:84px;min-width:0}
 .record-reason{font-size:13px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;min-width:0;color:#50627b}
 .record-points{white-space:nowrap;font-size:14px;font-variant-numeric:tabular-nums;letter-spacing:-.3px}
 .record-line-2{display:flex;align-items:center;gap:10px;white-space:nowrap;min-width:0;min-height:23px;font-size:11px;color:#8c9aad;overflow:hidden}
 .record-line-2 time{font-variant-numeric:tabular-nums}
 .record-line-2 a{color:#245fa8;font-weight:700;margin-left:auto;white-space:nowrap}
 .compact-filter{padding:11px;gap:11px;border-radius:13px;margin-bottom:12px}
 .filter-grid,.filter-grid-students{grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}
 .filter-grid-students>.filter-field:first-child{grid-column:1/-1}
 .filter-grid-students>.filter-field:last-child{grid-column:1/-1}
 .filter-foot{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:9px;align-items:end}
 .filter-foot>.sort-compact{max-width:none}
 .filter-action-row{min-width:0}.filter-action-row a,.filter-action-row button{min-height:44px;min-width:0;padding:9px 11px;font-size:13px}
 .student-filter .filter-action-row{justify-content:stretch}.student-filter .filter-action-row>*{flex:1}
 .filter-field input,.filter-field select{min-height:44px!important;font-size:15px!important}
 .export-form{padding:12px;gap:11px}.export-checks{grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}
 .export-checks label{font-size:12px;min-height:39px;padding:7px 8px}
 .export-button{width:100%;justify-self:stretch;min-height:47px}
 .ai-main-card{padding:17px 14px}.ai-icon{width:48px;height:48px;border-radius:15px;font-size:25px}.ai-hero{gap:11px}.ai-hero h2{font-size:20px}.ai-hero p{font-size:12px}
 .ai-steps{gap:4px}.ai-steps span{font-size:11px;padding:8px 2px}.ai-steps b{width:17px;height:17px;margin-right:2px}
 .ai-editor-shell textarea{min-height:150px;font-size:15px!important}
 .ai-main-actions #ai-parse{flex:1;min-width:0}.ai-main-actions #ai-clear{flex:0 0 63px}
 .ai-save-bar{flex-direction:column;align-items:stretch}.ai-save-bar button{width:100%}
}
@media screen and (max-width:360px){
 .student-list-caption,.student-line{grid-template-columns:minmax(0,1.1fr) minmax(0,.86fr) minmax(0,1.12fr) 42px;gap:3px}
 .student-line-name{font-size:13px}.student-line-score{font-size:12px}.student-line-change{font-size:9px}.student-line-detail{font-size:10px}
 .record-student{max-width:61px}.record-line-1{gap:5px}.record-line-2{gap:7px;font-size:10px}
}
