:root{color-scheme:light;--blue:#153d6f;--blue2:#235a96;--ink:#1c2733;--muted:#5d6877;--line:#d7dee8;--bg:#f1f4f8}
*{box-sizing:border-box}
[hidden]{display:none!important}
body{margin:0;background:var(--bg);color:var(--ink);font-family:system-ui,-apple-system,"Segoe UI",sans-serif;line-height:1.55}
.wrap{width:min(1050px,calc(100% - 32px));margin:38px auto}
.header{display:flex;justify-content:space-between;align-items:center;gap:24px;margin-bottom:26px}
.header-tools{display:flex;align-items:center;justify-content:flex-end;gap:20px;flex:0 0 auto}
.theme-toggle{display:inline-flex;align-items:center;justify-content:center;gap:8px;border:1px solid #b9c9da;border-radius:999px;padding:8px 13px;background:#fff;color:#24496d;font:inherit;font-size:.84rem;font-weight:750;white-space:nowrap;cursor:pointer}
.theme-toggle:hover{background:#eaf2fb}
.theme-toggle [data-theme-icon]{font-size:1.12rem;line-height:1}
.logo{width:185px;max-height:78px;object-fit:contain}
h1,h2,h3{color:#142f50;line-height:1.2;margin:0}
h1{font-size:clamp(1.9rem,4vw,2.45rem)}
h2{font-size:1.45rem}
.eyebrow{margin:0 0 7px;color:var(--blue2);font-size:.78rem;font-weight:800;letter-spacing:.1em;text-transform:uppercase}
.subtitle{margin:6px 0 0;color:var(--muted)}
.card{background:#fff;border-radius:12px;padding:clamp(22px,4vw,36px);box-shadow:0 8px 28px #19365316}
.hero{display:grid;grid-template-columns:minmax(0,1.5fr) minmax(245px,.8fr);gap:36px;align-items:center;border-top:5px solid var(--blue);background:linear-gradient(135deg,#fff 0%,#f7faff 68%,#edf4fc 100%)}
.hero h2{margin:13px 0;font-size:clamp(1.75rem,3.7vw,2.5rem)}
.hero p{max-width:620px;margin:0;color:#49596a;font-size:1.06rem}
.pill{display:inline-block;padding:5px 10px;border-radius:20px;background:#e3effb;color:var(--blue);font-size:.8rem;font-weight:800}
.hero-side{padding:22px;border:1px solid #cbd8e7;border-radius:10px;background:#fff}
.hero-side strong{color:#142f50}
.hero-side ol{margin:12px 0 0;padding-left:23px;color:#49596a}
.hero-side li{padding:3px 0}
.form-section{margin-top:20px}
.section-heading{display:flex;align-items:flex-start;gap:16px;margin-bottom:25px}
.section-heading p{margin:6px 0 0;color:var(--muted)}
.step{display:grid;place-items:center;flex:0 0 42px;height:42px;border-radius:50%;background:#e7eff8;color:var(--blue);font-weight:850}
.grid{display:grid;gap:18px}
.grid.three{grid-template-columns:repeat(3,minmax(0,1fr))}
.field{margin-bottom:18px}
.grid .field{margin-bottom:0}
label,legend{font-weight:680}
.field label{display:block;margin-bottom:7px}
input:not([type=radio]):not([type=checkbox]),textarea,select{width:100%;border:1px solid #b9c4d2;border-radius:7px;padding:11px 12px;background:#fff;color:var(--ink);font:inherit}
textarea{resize:vertical;min-height:86px}
input:focus-visible,textarea:focus-visible,select:focus-visible,button:focus-visible,a:focus-visible{outline:3px solid #2b70b951;outline-offset:2px}
.scale{margin:0;padding:17px 0;border:0;border-top:1px solid var(--line)}
.scale:last-child{padding-bottom:0}
.scale-heading{margin:0 0 13px;color:#20364f;font-size:1.06rem}
.lesson-heading{margin-top:23px;padding-top:23px;border-top:2px solid #d7e4f1}
.scale legend{width:100%;padding:0 0 3px;color:#20364f}
.scale-options{display:flex;align-items:center;gap:11px;margin-top:12px}
.scale-options label{position:relative;flex:0 0 46px;height:46px;cursor:pointer}
.scale-options input{position:absolute;inset:0;width:100%;height:100%;margin:0;opacity:0;cursor:pointer}
.scale-options label span{display:grid;place-items:center;width:100%;height:100%;border:1px solid #b9c4d2;border-radius:8px;background:#f7f9fc;color:var(--blue);font-weight:800}
.scale-options input:checked+span{border-color:var(--blue);background:var(--blue);color:#fff;box-shadow:0 0 0 3px #235a9629}
.scale-options input:focus-visible+span{outline:3px solid #2b70b951;outline-offset:2px}
.scale-end{min-width:65px;color:var(--muted);font-size:.83rem}
.scale-end:last-child{text-align:right}
.optional{color:var(--muted);font-size:.84rem;font-weight:400}
.hint{margin:6px 0 0;color:var(--muted);font-size:.88rem}
.grade-panel{margin-bottom:27px;padding:20px;border:1px solid #cbd8e7;border-left:4px solid var(--blue2);border-radius:8px;background:#f7faff}
.grade-panel .field{max-width:560px;margin:0}
.grade-question{margin:0 0 13px;color:#20364f;font-weight:750}
.grade-mode{display:flex;gap:15px;flex-wrap:wrap;margin-bottom:18px}
.grade-mode label{display:flex;align-items:center;gap:7px;font-weight:550}
.grade-mode input{width:18px;height:18px;accent-color:var(--blue)}
.grade-range{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;max-width:560px}
.grade-reason{padding:17px;border:1px solid #cbd8e7;border-radius:8px;background:#f7faff}
.grade-reason .hint{margin:0 0 10px}
.goal-review{margin-bottom:22px;padding:18px;border:1px solid #cbd8e7;border-radius:8px;background:#f7faff}
.goal-review h3{font-size:1.08rem}
.goal-review>.hint{margin:7px 0 17px}
.goal-review .field:last-child{margin-bottom:0}
.choice-group{margin:0;padding:21px 0;border:0;border-top:1px solid var(--line)}
.choice-group legend{width:100%;padding:0 0 2px;color:#20364f;font-size:1.04rem}
.choice-group .hint{margin-bottom:13px}
.choice-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.choice{display:flex;align-items:flex-start;gap:10px;padding:12px 13px;border:1px solid #d6e0ea;border-radius:8px;background:#f8fafc;font-weight:550;line-height:1.35;cursor:pointer}
.choice:has(input:checked){border-color:var(--blue2);background:#eaf3fd;color:#143f6f}
.choice input{flex:0 0 auto;width:18px;height:18px;margin:1px 0 0;accent-color:var(--blue)}
.choice input:disabled{cursor:not-allowed}
.choice:has(input:disabled:not(:checked)){opacity:.58;cursor:not-allowed}
.choice-other{max-width:640px;margin:17px 0 0}
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.submit-row{display:flex;justify-content:space-between;align-items:center;gap:24px;margin:24px 0 0;padding:6px 4px}
.submit-row p{max-width:650px;margin:0;color:var(--muted);font-size:.88rem}
.button{display:inline-block;border:0;border-radius:7px;padding:12px 18px;background:var(--blue);color:#fff;font:inherit;font-weight:750;text-decoration:none;white-space:nowrap;cursor:pointer}
.button:hover{background:#0e315b}
.button.secondary{background:#e8edf3;color:#253649}
.button.secondary:hover{background:#d9e4ef}
.notice{margin:20px 0;padding:15px 18px;border-radius:8px}
.anonymous-notice{background:#eaf2fb;color:#234462}
.anonymous-notice a{color:var(--blue);font-weight:750}
.success{background:#e3f5e9;color:#155b2b}
.error{background:#fae7e7;color:#852020}
.footer{display:flex;justify-content:space-between;gap:16px;margin-top:30px;padding:18px 2px;color:var(--muted);font-size:.9rem}
.footer a,.text-button{color:var(--blue)}
.honeypot{position:absolute!important;left:-10000px!important;width:1px!important;height:1px!important;overflow:hidden!important}
.login-card{width:min(470px,100%);margin:32px auto}
.login-card p{color:var(--muted)}
.admin-toolbar,.results-head,.panel-heading{display:flex;justify-content:space-between;align-items:center;gap:18px}
.admin-toolbar{margin-bottom:18px;color:#40546b}
.admin-toolbar p{margin:0}
.text-button{border:0;padding:5px;background:none;font:inherit;text-decoration:underline;cursor:pointer}
.text-button.danger{color:#a52424}
.admin-panel{margin-bottom:35px}
.panel-heading p,.results-head p{margin:6px 0 0;color:var(--muted)}
.course-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin:22px 0}
.round-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin:22px 0}
.round-item{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:11px 13px;border:1px solid var(--line);border-radius:8px;background:#f8fafc}
.round-item strong,.round-item small{display:block}
.round-item small{margin-top:3px;color:var(--muted)}
.course-item{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:11px 13px;border:1px solid var(--line);border-radius:8px;background:#f8fafc}
.course-item strong{display:block;font-weight:650}
.course-item small{display:block;margin-top:3px;color:var(--muted)}
.course-actions,.course-actions form{display:flex;align-items:center;gap:7px}
.course-actions{flex-wrap:wrap;justify-content:flex-end}
.course-item{align-items:flex-start;flex-direction:column}
.anonymous-list{display:grid;gap:10px;margin-top:20px}
.anonymous-summary{align-items:stretch;flex-direction:column}
.anonymous-summary .hint{margin:0}
.anonymous-results{width:100%}
.anonymous-results .score-grid{margin:8px 0 14px}
.anonymous-results ul{margin:7px 0 0;padding-left:22px}
.course-actions select{width:auto;max-width:135px;padding:6px 8px;font-size:.83rem}
.small-button{border:1px solid #aabed4;border-radius:6px;padding:6px 10px;background:#e7eff8;color:var(--blue);font:inherit;font-size:.83rem;font-weight:750;cursor:pointer}
.small-button.muted-button{background:#fff;color:#526273}
.add-course{display:flex;align-items:end;gap:12px;border-top:1px solid var(--line);padding-top:20px}
.add-course .field{flex:1;margin:0}
.results-head{margin-bottom:18px}
.filter-form{display:flex;align-items:center;gap:10px;margin-bottom:18px}
.filter-form select{max-width:280px}
.filter-form label{white-space:nowrap}
.response-list{display:grid;gap:18px}
.response-card{padding:25px}
.response-top{display:flex;justify-content:space-between;gap:15px}
.response-top h3{margin:8px 0 3px;font-size:1.18rem}
.response-top time{color:var(--muted);font-size:.85rem}
.course-badge{display:inline-block;padding:4px 9px;border-radius:5px;background:#e9f2ff;color:var(--blue);font-size:.78rem;font-weight:800}
.grade-badge{display:inline-block;margin-top:10px;padding:6px 9px;border-radius:6px;background:#edf5e9;color:#315d27;font-size:.84rem;font-weight:800}
.score-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:9px;margin:20px 0}
.score-grid.lesson-scores{grid-template-columns:repeat(3,minmax(0,1fr));margin-top:0}
.score-grid div{padding:12px;border-radius:7px;background:#f2f6fa}
.score-grid span{display:block;min-height:44px;color:#526273;font-size:.8rem;line-height:1.25}
.score-grid strong{display:block;margin-top:7px;color:var(--blue);font-size:1.05rem}
.answer-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;margin:0}
.answer-grid div{min-width:0;border-top:1px solid var(--line);padding-top:12px}
.answer-grid dt{margin-bottom:5px;color:#40546b;font-size:.82rem;font-weight:800}
.answer-grid dd{margin:0;overflow-wrap:anywhere}
.selected-grid{margin-bottom:16px}
.empty{color:var(--muted);text-align:center}
@media(max-width:800px){.hero{grid-template-columns:1fr}.grid.three{grid-template-columns:1fr 1fr}.grid.three .field:last-child{grid-column:1/-1}.submit-row{align-items:stretch;flex-direction:column}.submit-row .button{text-align:center}.score-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.course-item{align-items:flex-start;flex-direction:column}}
@media(max-width:600px){.wrap{margin:22px auto}.header{align-items:flex-start;flex-wrap:wrap}.header>div:first-child{flex:1 1 100%}.header-tools{justify-content:space-between;width:100%}.logo{width:110px}.grid.three,.course-list,.round-list,.answer-grid,.choice-grid{grid-template-columns:1fr}.grid.three .field:last-child{grid-column:auto}.scale-options{gap:5px}.scale-options label{flex:1;min-width:0;height:42px}.scale-end{min-width:42px;font-size:.7rem}.add-course,.results-head,.filter-form{align-items:stretch;flex-direction:column}.filter-form select{max-width:none}.response-card{padding:20px}.score-grid,.score-grid.lesson-scores{grid-template-columns:1fr 1fr}.score-grid span{min-height:0}.response-top{align-items:flex-start}.course-actions{align-items:flex-start;flex-direction:column}.round-item{align-items:flex-start;flex-direction:column}.grade-range{grid-template-columns:1fr}}

:root[data-theme="dark"]{color-scheme:dark;--blue:#a7cdfb;--blue2:#8bbcf6;--ink:#e9f0f7;--muted:#b2c0d0;--line:#3b5066;--bg:#101923}
:root[data-theme="dark"] h1,:root[data-theme="dark"] h2,:root[data-theme="dark"] h3{color:#f2f7fc}
:root[data-theme="dark"] .card{background:#1c2937;box-shadow:0 8px 28px #0005}
:root[data-theme="dark"] .hero{background:linear-gradient(135deg,#1c2937 0%,#1b2d42 68%,#18364f 100%)}
:root[data-theme="dark"] .hero p,:root[data-theme="dark"] .hero-side ol{color:#c5d2df}
:root[data-theme="dark"] .hero-side{border-color:#48617a;background:#203247}
:root[data-theme="dark"] .hero-side strong{color:#f0f6fd}
:root[data-theme="dark"] .pill,:root[data-theme="dark"] .step{background:#29425d;color:#d1e6ff}
:root[data-theme="dark"] .logo{filter:invert(1)}
:root[data-theme="dark"] .theme-toggle{border-color:#56718e;background:#263a50;color:#e2f0ff}
:root[data-theme="dark"] .theme-toggle:hover{background:#34516e}
:root[data-theme="dark"] input:not([type=radio]):not([type=checkbox]),:root[data-theme="dark"] textarea,:root[data-theme="dark"] select{border-color:#59738d;background:#142232;color:#f1f6fc}
:root[data-theme="dark"] input::placeholder,:root[data-theme="dark"] textarea::placeholder{color:#a7b8c9;opacity:1}
:root[data-theme="dark"] input:focus-visible,:root[data-theme="dark"] textarea:focus-visible,:root[data-theme="dark"] select:focus-visible,:root[data-theme="dark"] button:focus-visible,:root[data-theme="dark"] a:focus-visible{outline-color:#8fc6ff}
:root[data-theme="dark"] .scale-heading,:root[data-theme="dark"] .scale legend,:root[data-theme="dark"] .grade-question,:root[data-theme="dark"] .choice-group legend{color:#e8f2fd}
:root[data-theme="dark"] .lesson-heading{border-color:#48617a}
:root[data-theme="dark"] .scale-options label span{border-color:#5a718b;background:#26384a;color:#d6eaff}
:root[data-theme="dark"] .scale-options input:checked+span{border-color:#91c5ff;background:#2f6ea9;color:#fff;box-shadow:0 0 0 3px #8bbcf64d}
:root[data-theme="dark"] .grade-panel,:root[data-theme="dark"] .grade-reason{border-color:#48617a;border-left-color:#8bbcf6;background:#1a3045}
:root[data-theme="dark"] .goal-review{border-color:#48617a;background:#1a3045}
:root[data-theme="dark"] .choice{border-color:#425b73;background:#223447;color:#e4edf7}
:root[data-theme="dark"] .choice:has(input:checked){border-color:#86b9f2;background:#254c70;color:#f0f7ff}
:root[data-theme="dark"] .button{background:#2d6dab;color:#fff}
:root[data-theme="dark"] .button:hover{background:#397cbd}
:root[data-theme="dark"] .button.secondary{background:#30465d;color:#eef6ff}
:root[data-theme="dark"] .button.secondary:hover{background:#3a5673}
:root[data-theme="dark"] .small-button{border-color:#6684a2;background:#2d4966;color:#eaf4ff}
:root[data-theme="dark"] .small-button.muted-button{background:#24374a;color:#d7e4f1}
:root[data-theme="dark"] .notice.success{background:#1c4932;color:#c5f2d3}
:root[data-theme="dark"] .notice.error{background:#542b32;color:#ffd4da}
:root[data-theme="dark"] .anonymous-notice{background:#223e59;color:#e0efff}
:root[data-theme="dark"] .admin-toolbar,:root[data-theme="dark"] .answer-grid dt{color:#c3d0df}
:root[data-theme="dark"] .course-item,:root[data-theme="dark"] .score-grid div{border-color:#3b5066;background:#243548}
:root[data-theme="dark"] .round-item{border-color:#3b5066;background:#243548}
:root[data-theme="dark"] .score-grid span{color:#c3d0df}
:root[data-theme="dark"] .course-badge{background:#284766;color:#d5eaff}
:root[data-theme="dark"] .grade-badge{background:#254532;color:#cff1d7}
:root[data-theme="dark"] .text-button.danger{color:#ffabb2}
