@import url('https://fonts.googleapis.com/css2?family=Heebo:wght@400;500;600;700;800&display=swap');
:root {
  font-family: Heebo, Arial, sans-serif;
  color-scheme: light;
  --primary: #3A94E6;
  --tint: #D0F0FF;
  --primary-hover: #6aaff0;
  --on-primary: #071d31;
  --background: #f7fcff;
  --surface: #ffffff;
  --surface-soft: #eef8ff;
  --text: #172f46;
  --muted: #586e83;
  --line: #ccdfef;
  --field-border: #adcbe3;
  --focus: #3A94E6;
  --sidebar: #D0F0FF;
  --sidebar-text: #173b5c;
  --sidebar-selected: #3A94E6;
  --sidebar-hover: #bce5ff;
  --hero: #D0F0FF;
  --hero-end: #ecf8ff;
  --success-bg: #e4f3e9;
  --success-text: #24724e;
  --warning-bg: #fff1dd;
  --warning-text: #80521a;
  --error-bg: #fbe8e8;
  --error-text: #a33135;
  --shadow: #17497112;
  color: var(--text);
  background: var(--background);
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --background: #101820;
  --surface: #192632;
  --surface-soft: #223444;
  --text: #edf5ff;
  --muted: #b4c7da;
  --line: #374c60;
  --field-border: #536d85;
  --sidebar: #152d43;
  --sidebar-text: #D0F0FF;
  --sidebar-selected: #3A94E6;
  --sidebar-hover: #254865;
  --hero: #173a57;
  --hero-end: #1b2e40;
  --success-bg: #193d30;
  --success-text: #99e0b9;
  --warning-bg: #42341f;
  --warning-text: #ffd392;
  --error-bg: #44282d;
  --error-text: #ffb5bc;
  --shadow: #00000030;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--background); color: var(--text); text-align: right; }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; border: 0; border-radius: 10px; padding: 11px 18px; font-weight: 600; color: var(--text); background: var(--surface-soft); transition: background .15s; }
button:disabled { opacity: .5; cursor: wait; }
button:focus-visible, a:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }
[hidden] { display: none !important; }
h1,h2,h3,p { margin: 0; }
h1 { font-size: 32px; letter-spacing: -.7px; }
h2 { font-size: 23px; }
p { line-height: 1.8; color: var(--muted); }
small { color: var(--muted); }
label { display: grid; gap: 7px; font-size: 14px; font-weight: 600; margin-block: 16px; text-align: right; }
input,textarea,select { width: 100%; padding: 12px; border: 1px solid var(--field-border); border-radius: 10px; background: var(--surface); color: var(--text); text-align: right; }
input:focus,textarea:focus,select:focus { outline: 2px solid var(--focus); outline-offset: 1px; border-color: var(--primary); }
textarea { min-height: 105px; resize: vertical; }
select[multiple] { min-height: 100px; }
.primary { background: var(--primary); color: var(--on-primary); }
.primary:hover { background: var(--primary-hover); }
.secondary { background: var(--surface); border: 1px solid var(--line); color: var(--text); }
.secondary:hover { background: var(--surface-soft); }
.login { min-height: 100vh; display: grid; place-items: center; padding: 30px; background: radial-gradient(ellipse at 20% 20%,var(--hero),transparent 65%),var(--background); }
.login-card { width: min(440px,100%); background: var(--surface); padding: 30px 38px 38px; border: 1px solid var(--line); border-radius: 22px; box-shadow: 0 24px 90px var(--shadow); }
.login-card .brand { color: var(--primary); margin-bottom: 28px; }
.login-card .brand span { color: var(--muted); }
.login-card > .primary { width: 100%; margin-top: 12px; }
.login-card small { display: block; text-align: right; margin-top: 22px; }
.auth-tools { display: flex; justify-content: flex-end; margin-bottom: 10px; }
.theme-toggle { display: inline-grid; place-items: center; width: 44px; height: 44px; padding: 10px; flex-shrink: 0; }
.theme-toggle svg,.password-toggle svg { display: block; width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.password-field { position: relative; display: block; }
.password-field input { padding-left: 52px; }
.password-toggle { position: absolute; left: 4px; top: 50%; transform: translateY(-50%); background: transparent; color: var(--muted); display: grid; place-items: center; height: 40px; width: 40px; padding: 8px; }
.password-toggle:hover { background: var(--surface-soft); color: var(--text); }
.brand { font-size: 40px; font-weight: 800; line-height: 1.2; }
.brand span { display: block; font-size: 13px; font-weight: 400; margin-top: 8px; letter-spacing: .3px; }
aside { position: fixed; right: 0; top: 0; bottom: 0; width: 250px; background: var(--sidebar); color: var(--sidebar-text); padding: 34px 22px; display: flex; flex-direction: column; border-left: 1px solid var(--line); }
.eyebrow { font-size: 12px; color: var(--muted); font-weight: 600; letter-spacing: .4px; }
aside > .eyebrow { color: var(--sidebar-text); margin-top: 44px; margin-bottom: 12px; padding-right: 14px; }
nav { display: grid; gap: 6px; }
nav button { background: transparent; color: var(--sidebar-text); text-align: right; display: flex; gap: 12px; align-items: center; font-size: 16px; padding: 14px; }
nav button:hover { background: var(--sidebar-hover); }
nav button.selected { background: var(--sidebar-selected); color: var(--on-primary); }
.aside-bottom { margin-top: auto; border-top: 1px solid var(--line); padding-top: 20px; }
.aside-bottom small { display: block; color: var(--sidebar-text); }
.aside-bottom button { background: transparent; color: var(--sidebar-text); padding: 12px 0; }
main { margin-right: 250px; padding: 36px 44px; max-width: 1700px; }
header { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-bottom: 34px; }
header h1 { margin-top: 5px; }
.header-actions { display: flex; gap: 14px; align-items: center; }
.connected { font-size: 12px; color: var(--text); background: var(--surface-soft); padding: 8px 12px; border-radius: 30px; }
.hero { background: linear-gradient(120deg,var(--hero),var(--hero-end)); border: 1px solid var(--line); border-radius: 20px; padding: 32px; display: flex; justify-content: space-between; align-items: center; gap: 22px; margin-bottom: 24px; }
.hero h2 { font-size: 29px; margin: 8px 0; }
.hero p { max-width: 600px; }
.hero-symbol { font-size: 70px; color: var(--primary); }
.stats { display: grid; grid-template-columns: repeat(4,1fr); gap: 16px; margin-bottom: 28px; }
.stat,.panel { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; }
.stat { padding: 22px; }
.stat strong { display: block; font-size: 36px; line-height: 1.5; }
.stat span { font-size: 13px; color: var(--muted); }
.panel { padding: 24px; margin-bottom: 22px; }
.panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
.panel-heading p { font-size: 14px; }
.grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 18px; }
.content-card { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 24px; display: flex; flex-direction: column; gap: 14px; }
.content-card h3 { font-size: 22px; }
.card-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: auto; }
.badge { display: inline-block; padding: 4px 10px; border-radius: 20px; font-size: 12px; font-weight: 500; background: var(--surface-soft); color: var(--muted); }
.badge.green { background: var(--success-bg); color: var(--success-text); }
.badge.orange { background: var(--warning-bg); color: var(--warning-text); }
.table-wrap { overflow: auto; }
table { width: 100%; border-collapse: collapse; white-space: nowrap; text-align: right; }
th { font-size: 12px; color: var(--muted); background: var(--surface-soft); font-weight: 500; }
td,th { padding: 14px 12px; border-bottom: 1px solid var(--line); }
td { font-size: 14px; }
td button { font-size: 12px; padding: 7px 11px; margin: 2px; }
.empty { text-align: right; padding: 48px 20px; color: var(--muted); }
.empty b { display: block; color: var(--text); font-size: 22px; margin-bottom: 8px; }
.error { color: var(--error-text); margin-top: 12px; font-size: 14px; }
#notice { padding: 14px 20px; border-radius: 12px; background: var(--success-bg); color: var(--success-text); margin-bottom: 20px; }
#notice.error { background: var(--error-bg); color: var(--error-text); }
.search { max-width: 340px; }
.subtle { font-size: 13px; color: var(--muted); }
footer { font-size: 12px; color: var(--muted); margin-top: 40px; }
dialog { border: 1px solid var(--line); border-radius: 20px; max-width: 820px; width: calc(100% - 30px); padding: 28px; background: var(--surface); color: var(--text); box-shadow: 0 30px 100px #0003; max-height: 92vh; text-align: right; }
dialog::backdrop { background: #0e263b99; backdrop-filter: blur(3px); }
.dialog-heading,.dialog-footer { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.dialog-heading > div:first-child { flex: 1; }
.dialog-footer { justify-content: flex-end; border-top: 1px solid var(--line); padding-top: 20px; padding-bottom: 8px; margin-top: 24px; position: sticky; bottom: -28px; background: var(--surface); }
.icon { font-size: 26px; background: var(--surface-soft); padding: 2px 12px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.check { display: flex; align-items: center; gap: 10px; }
.check input { width: auto; }
.question,.vocabulary-row { background: var(--surface-soft); border: 1px solid var(--line); border-radius: 12px; padding: 18px; margin-top: 16px; }
.question-head,.vocabulary-row-heading { display: flex; gap: 10px; align-items: center; justify-content: space-between; }
.question select { max-width: 250px; }
.question button { padding: 5px 10px; }
.vocabulary-editor { border-top: 1px solid var(--line); margin-top: 26px; padding-top: 24px; }
.vocabulary-fields { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 0 16px; }
.vocabulary-empty { padding: 20px; border: 1px dashed var(--field-border); border-radius: 12px; }
.hint { font-size: 12px; font-weight: 400; color: var(--muted); }
.loading { padding: 60px; text-align: right; }
.step-list { display: grid; gap: 18px; counter-reset: step; }
.step { display: flex; gap: 16px; align-items: center; }
.step:before { counter-increment: step; content: counter(step); display: grid; place-items: center; border-radius: 50%; width: 36px; height: 36px; background: var(--surface-soft); color: var(--primary); flex-shrink: 0; }
.progress { height: 7px; background: var(--surface-soft); border-radius: 10px; margin-top: 10px; overflow: hidden; }
.progress > i { display: block; height: 100%; background: var(--primary); }
@media(max-width:1100px) {
  main { padding: 28px 24px; margin-right: 220px; }
  aside { width: 220px; }
  .stats { grid-template-columns: repeat(2,1fr); }
  .header-actions .connected { display: none; }
}
@media(max-width:750px) {
  aside { position: static; width: 100%; padding: 18px; }
  .brand { font-size: 28px; }
  aside > .eyebrow,.aside-bottom { display: none; }
  nav { display: flex; overflow: auto; margin-top: 16px; }
  nav button { white-space: nowrap; padding: 10px; font-size: 13px; }
  main { margin: 0; padding: 22px 16px; }
  h1 { font-size: 26px; }
  .grid,.form-row,.vocabulary-fields { grid-template-columns: 1fr; }
  .hero { padding: 22px; }
  .hero-symbol { display: none; }
  .panel-heading { align-items: flex-start; flex-direction: column; }
  header { align-items: flex-start; }
  .header-actions { gap: 6px; }
  #refresh { padding: 10px; }
  .login-card { padding: 24px; }
  .stat { padding: 16px; }
}

.challenge-editor,.image-editor { border-top: 1px solid var(--line); padding-top: 20px; margin-top: 24px; }
.challenge-editor > p { font-size: 14px; }
.image-editor details { padding: 16px; border: 1px solid var(--line); border-radius: 12px; margin-top: 14px; background: var(--surface-soft); }
.image-editor summary { cursor: pointer; font-weight: 600; }
.image-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-block: 16px; }
.scenario-image { display: block; width: 100%; max-height: 340px; object-fit: contain; border-radius: 12px; margin-top: 16px; background: var(--surface-soft); }
#image-status { margin-top: 12px; font-size: 14px; }

.group-picker{border:1px solid var(--line);border-radius:14px;padding:16px;margin:16px 0;min-width:0}.group-picker legend{padding:0 8px;font-weight:700}.group-picker .check{margin:8px 0}

.answer-row,.sentence-entry{display:flex;gap:12px;align-items:flex-end;margin:12px 0}.answer-row>label,.sentence-entry>label{flex:1;min-width:0;margin:0}.answer-row>button,.sentence-entry>button{flex-shrink:0;margin-bottom:2px}.correct-answer{border-inline-start:4px solid var(--primary);padding-inline-start:12px}.correct-answer label{color:var(--primary);font-weight:700}.pair-row{display:grid;grid-template-columns:minmax(0,1fr) auto minmax(0,1fr) auto;align-items:end;gap:10px;margin:14px 0}.pair-row label{min-width:0;margin:0}.pair-row>span{align-self:center}.pair-row>button{margin-bottom:2px}.solution-editor,.distractor-editor{border-top:1px solid var(--line);margin:18px 0;padding-top:16px}.solution-heading{display:flex;justify-content:space-between;gap:12px;align-items:center;margin-bottom:12px}.word-tiles{display:flex;flex-wrap:wrap;gap:8px;margin:12px 0;direction:rtl}.word-tile{display:inline-flex;flex-direction:column;gap:8px;align-items:center;justify-content:center;padding:10px 14px;background:var(--surface);border:1px solid var(--field-border);border-radius:10px;min-width:44px;unicode-bidi:isolate}.draggable-tile{cursor:grab;user-select:none;border-color:var(--primary)}.draggable-tile:active{cursor:grabbing}.tile-controls{display:flex;gap:4px}.tile-controls button{background:var(--surface-soft);color:var(--text);min-width:28px}.quiz-field-error{color:var(--error-text);font-size:13px;margin:8px 0}.quiz-field-error:empty{display:none}.question-type{margin:0;flex:1;max-width:250px}.sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}@media(max-width:600px){.pair-row{grid-template-columns:minmax(0,1fr) minmax(0,1fr)}.pair-row>span{display:none}.pair-row>button{grid-column:2}.question-head{flex-wrap:wrap}.word-tile{padding:8px}.sentence-entry{align-items:flex-end}}

.draggable-tile{touch-action:none}.draggable-tile.is-dragging{opacity:.5;cursor:grabbing}.draggable-tile.drop-target{outline:2px solid var(--primary);background:var(--hero)}

.scenario-completion-actions{display:flex;align-items:center;gap:8px;margin-inline-end:auto}.scenario-completion-actions[hidden]{display:none}

.user-assignment{border:1px solid var(--line);border-radius:14px;padding:16px;margin:16px 0}.user-assignment legend{padding:0 8px;font-weight:700}#assigned-users-summary{display:flex;flex-wrap:wrap;gap:8px;margin-top:12px}.assigned-user-chip{display:inline-flex;align-items:center;gap:8px;padding:6px 10px;border-radius:12px;background:var(--surface-soft);max-width:100%;overflow-wrap:anywhere}.assigned-user-chip button{padding:2px 8px}.audience-user{display:flex;gap:12px;align-items:center;padding:12px;border-bottom:1px solid var(--line);margin:0}.audience-user input{width:auto}.audience-user span{display:flex;flex-direction:column;gap:4px}.audience-user bdi{font-size:13px;color:var(--muted)}#audience-results{max-height:45vh;overflow:auto;min-height:80px}#audience-picker,#unassigned-warning{max-width:640px}#unassigned-message{margin-top:16px}

.all-organization-access{margin:18px 0;font-weight:700}#editor fieldset:disabled{opacity:.55}#editor fieldset:disabled button{cursor:not-allowed}

#user-statistics-dialog{width:min(1160px,94vw);max-width:1160px;text-align:right}#user-statistics-dialog .panel-heading{align-items:flex-start}#user-statistics-dialog .stats{grid-template-columns:repeat(4,minmax(0,1fr))}.statistics-feedback{min-width:240px;white-space:normal;max-width:440px}.statistics-feedback summary{cursor:pointer;color:var(--primary);font-weight:600}.statistics-feedback dl>div{display:flex;justify-content:space-between;gap:20px;padding:6px 0;border-bottom:1px solid var(--line)}.statistics-feedback dd{margin:0;white-space:nowrap}.statistics-feedback p{white-space:pre-wrap;overflow-wrap:anywhere}tr[hidden]{display:none}@media(max-width:600px){#user-statistics-dialog .stats{grid-template-columns:repeat(2,minmax(0,1fr))}}

.dashboard-heading{display:flex;align-items:center;justify-content:space-between;gap:24px;margin-bottom:22px}.dashboard-heading p{margin:0 0 5px}.dashboard-heading label{min-width:190px;margin:0}.dashboard-stats{grid-template-columns:repeat(3,minmax(0,1fr));gap:18px;margin-bottom:12px}.dashboard-stat{display:flex;flex-direction:column;gap:14px;min-height:164px;text-align:right;white-space:normal;min-width:0;background:var(--surface);color:var(--text);border:1px solid var(--line);font:inherit}.dashboard-stat strong{font-size:clamp(23px,2.1vw,34px);line-height:1.3;letter-spacing:normal}.dashboard-stat-label{display:flex;align-items:center;justify-content:space-between;gap:12px}.dashboard-stat-label i{font-style:normal;color:var(--primary);font-size:20px}.dashboard-stat small{margin-top:auto;color:var(--muted);font-size:13px;font-weight:400}.dashboard-stat[data-dashboard-action]:hover{background:var(--surface-soft);border-color:var(--primary)}.dashboard-data-note{font-size:13px;color:var(--muted);margin:10px 0 24px}.dashboard-trends{margin-top:20px}.chart-tabs{display:flex;gap:5px;flex-wrap:wrap}.chart-tabs button{background:var(--surface-soft);color:var(--text);border:1px solid transparent;padding:9px 13px}.chart-tabs button.selected{background:var(--tint);color:#173b5c;border-color:var(--primary)}.chart-wrapper{min-width:0}.activity-chart{display:block;width:100%;height:auto;overflow:visible;direction:ltr}.activity-chart text{fill:var(--muted);font-size:13px;font-family:Arial,sans-serif}.chart-grid{stroke:var(--line);stroke-width:1}.chart-line{stroke:var(--primary);stroke-width:3;fill:none;stroke-linejoin:round}.chart-fill{fill:var(--primary);opacity:.1}.activity-chart circle{fill:var(--surface);stroke:var(--primary);stroke-width:2;cursor:pointer}.activity-chart circle:hover,.activity-chart circle:focus{fill:var(--primary);stroke-width:4;outline:none}.chart-unit,.chart-point-value{font-size:13px;color:var(--muted);margin:6px 0}.chart-point-value{min-height:22px;color:var(--text)}.dashboard-definitions{font-size:13px;color:var(--muted);margin-top:14px}.dashboard-definitions summary{cursor:pointer}.dashboard-bottom{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:22px;align-items:stretch}.dashboard-bottom>.panel{min-width:0;margin-bottom:0}.dashboard-bottom .panel-heading{gap:12px;flex-wrap:wrap}.dashboard-bottom th,.dashboard-bottom td{white-space:normal;font-size:13px;padding:12px 8px}.dashboard-bottom .text-button{padding:3px 0;text-align:right;white-space:normal;background:transparent;color:var(--primary);font-weight:600}.dashboard-empty{padding:12px 0;margin:0}.dashboard-group-dialog{width:min(800px,94vw);max-width:800px}#inactive-users-filter{width:auto}@media(max-width:1100px){.dashboard-stats{grid-template-columns:repeat(2,minmax(0,1fr))}.dashboard-bottom{grid-template-columns:1fr}.dashboard-trends .panel-heading{align-items:flex-start;flex-direction:column}}@media(max-width:750px){.dashboard-heading{align-items:flex-start;gap:16px}.dashboard-heading label{min-width:150px}.dashboard-stats{gap:12px}.dashboard-stat{min-height:150px}.chart-tabs button{padding:8px;font-size:12px}.dashboard-bottom th,.dashboard-bottom td{padding:9px 6px}.activity-chart text{font-size:13px}}@media(max-width:410px){.dashboard-stats{grid-template-columns:1fr}.dashboard-heading{flex-direction:column;width:100%}.dashboard-heading label{width:100%}}

.message-modes{display:flex;gap:24px;flex-wrap:wrap;margin:12px 0 20px}.message-modes .check{margin:0}#learning-messages-form fieldset{min-width:0;border:0;padding:0}#learning-messages-form legend{font-weight:600}#learning-messages-form textarea{resize:vertical;min-height:120px}#learning-messages-form [hidden]{display:none}

.card-actions button{display:inline-flex;align-items:center;gap:7px}.action-icon{width:16px;height:16px;flex-shrink:0}.vocabulary-editor>summary{cursor:pointer;font-size:18px;font-weight:600}.vocabulary-editor[open]>summary{margin-bottom:16px}

.speech-audio-editor{margin-top:20px;padding-top:16px;border-top:1px solid var(--line)}.speech-audio-editor audio{display:block;width:100%;max-width:460px;margin-top:16px}.speech-audio-editor input[type=file]{max-width:100%}

.platform-form{display:grid;gap:14px;margin:16px 0}.platform-form fieldset{display:grid;gap:10px;border:1px solid var(--line);border-radius:10px;padding:14px}.platform-admin{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px 0;border-bottom:1px solid var(--line)}.platform-admin small,.platform-form small{display:block}.platform-org h3{margin-top:22px}#organization-switch select{max-width:420px;width:100%}

.onboarding-password-settings > summary { cursor: pointer; font-size: 1.1rem; font-weight: 700; }
.onboarding-password-settings[open] > summary { margin-bottom: 16px; }

.danger { background: var(--error-text); color: var(--surface); }
.danger-outline { color: var(--error-text); border: 1px solid var(--error-text); background: var(--surface); }
.delete-dialog { max-width: 560px; }
.delete-dialog p { margin-block: 16px; }

.scenario-order-dialog{width:min(560px,92vw);max-height:85vh;padding:24px;border:1px solid var(--line);border-radius:18px;background:var(--surface);color:var(--text)}
.scenario-order-dialog::backdrop{background:#0008}
.scenario-order-list{max-height:55vh;overflow-y:auto;display:grid;gap:10px;padding:4px;margin:18px 0}
.scenario-order-item{display:flex;align-items:center;gap:12px;padding:16px;border:1px solid var(--line);border-radius:12px;cursor:grab;background:var(--surface);overflow-wrap:anywhere}
.scenario-order-item:focus-visible{outline:2px solid var(--accent,#527f72);outline-offset:1px}
.scenario-order-grip{opacity:.55;font-size:24px;user-select:none}.scenario-order-item.dragging{opacity:.4}.scenario-order-item.drop-target{outline:2px solid var(--accent,#527f72)}

.delete-icon { display: inline-block; vertical-align: middle; flex-shrink: 0; margin-inline-end: 4px; pointer-events: none; }

/* Super-admin AI consumption report. */
.ai-usage-filters{display:flex;align-items:end;flex-wrap:wrap;gap:14px}.ai-usage-filters label{display:grid;gap:6px;min-width:160px}.ai-usage-periods{display:flex;flex-wrap:wrap;gap:8px}.ai-usage-summary{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px}.ai-usage-total{display:flex;flex-direction:column;gap:6px}.ai-usage-total strong{font-size:32px}.ai-usage-total small,.ai-usage-table small{display:block;color:var(--muted);font-weight:400}.ai-usage-table{width:100%;min-width:820px;border-collapse:collapse}.ai-usage-table th,.ai-usage-table td{padding:14px;text-align:right;border-bottom:1px solid var(--line);vertical-align:top}.ai-usage-table tbody tr:nth-child(4n+1){border-top:2px solid var(--line)}.ai-usage-table th[scope=rowgroup]{min-width:160px}.ai-usage-table caption{text-align:right;padding:8px 0}.table-scroll{overflow-x:auto}@media(max-width:800px){.ai-usage-summary{grid-template-columns:repeat(2,minmax(0,1fr))}.ai-usage-filters label{flex:1;min-width:140px}}

/* Answer feedback uses text labels as well as color. */
.quiz-answer-list{padding-inline-start:24px}.quiz-answer-item{padding:12px 0;border-bottom:1px solid var(--line)}
.quiz-answer-correct{color:#137333;font-weight:600}.quiz-answer-incorrect{color:#b3261e;font-weight:600}.quiz-answer-partial{color:#a24b00;font-weight:600}.quiz-answer-unknown{color:var(--muted)}
.quiz-answer-badge{display:inline-block;padding:3px 8px;border-radius:6px;font-size:12px;margin-inline-start:8px}
.quiz-answer-badge.quiz-answer-correct{background:#e6f4ea}.quiz-answer-badge.quiz-answer-incorrect{background:#fce8e6}.quiz-answer-badge.quiz-answer-partial{background:#fff0d6}

.connecting-card { text-align: center; }
.connecting-card .brand { text-align: right; }
.connecting-spinner { display: inline-block; width: 36px; height: 36px; border: 3px solid var(--line); border-top-color: var(--primary); border-radius: 50%; animation: connecting-turn .9s linear infinite; margin: 4px 0 14px; }
@keyframes connecting-turn { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .connecting-spinner { animation: none; } }

.login-card .forgot-password { display: block; margin: 16px auto 0; }
