/* TeacherShellView.swift: native Teacher consumer, separate from Student shell. */
.teacher-shell{height:100%;min-height:0;display:grid;grid-template-rows:auto minmax(0,1fr) auto;background:white;color:#111827;font-family:-apple-system,BlinkMacSystemFont,sans-serif;font-size:16px}
.teacher-header{display:flex;align-items:center;gap:8px;padding:8px 20px;background:white;min-height:60px}.teacher-header h1{font-size:22px;font-weight:700;margin:0;flex:1;line-height:1.2}.teacher-header button{width:44px;min-height:44px;display:grid;place-items:center;color:#111827;padding:0}.teacher-header button:last-child{border-radius:50%;background:#f1f5f9;border:.7px solid #e2e8f0;color:#64748b}
.teacher-content{overflow:auto;min-height:0;padding:18px;display:flex;flex-direction:column;gap:12px;align-items:stretch;overscroll-behavior:contain}.teacher-content>*{flex-shrink:0}.teacher-content h3{font-size:18px;margin:0}.teacher-card{padding:16px;border:1px solid #e5e7eb;border-radius:14px;background:#fafafc;display:flex;flex-direction:column;gap:6px;position:relative;text-align:left;color:inherit;width:100%}.teacher-card strong{font-weight:600}.teacher-card small,.teacher-secondary{color:#6b7280}.teacher-card-row{display:flex;align-items:center;justify-content:space-between;gap:8px}.teacher-card-row small{font-size:12px}.teacher-link{padding-right:38px}.teacher-link>.native-icon:last-child{position:absolute;right:12px;top:calc(50% - 10px);color:#6b7280}.teacher-count{font-size:28px}.teacher-speaking-tag{font-size:12px;font-weight:700;background:#007aff1f;color:#007aff;border-radius:6px;padding:6px;align-self:flex-start}
.teacher-tabs{display:flex;padding:8px 8px max(8px,env(safe-area-inset-bottom));background:white;border-top:1px solid #e5e7eb}.teacher-tabs button{display:flex;flex:1;flex-direction:column;align-items:center;justify-content:center;gap:5px;color:#6b7280;padding:4px;font-size:12px;min-height:54px}.teacher-tabs button[aria-current=page]{color:#4f46e5}.teacher-chips{display:flex;gap:8px;flex-wrap:wrap}.teacher-chip{padding:8px 12px;border-radius:20px;background:#f1f5f9;color:#334155;font-size:14px;min-height:36px}.teacher-chip[aria-pressed=true]{background:#4f46e5;color:white}.teacher-field{display:flex;flex-direction:column;gap:6px}.teacher-field input,.teacher-field select{padding:14px;border:1px solid #cbd5e1;border-radius:4px;min-height:54px;font:inherit;background:white;color:inherit;width:100%}.teacher-pagination{display:flex;align-items:center;justify-content:space-between;gap:12px}.teacher-pagination button,.teacher-back{min-height:44px;padding:8px 14px;color:#4f46e5}.teacher-student-back{display:flex;gap:8px;align-items:center;min-height:44px;font-size:18px;font-weight:600;padding:0;text-align:left}.teacher-stats{display:grid;grid-template-columns:1fr 1fr;gap:12px}.teacher-stats section{display:flex;flex-direction:column;align-items:center;gap:8px;padding:14px;min-height:76px;border:1px solid #e5e7eb;border-radius:14px;background:#f8fafc}.teacher-stats strong{font-size:21px}.teacher-stats small{font-size:12px;color:#6b7280}.teacher-settings-content{justify-content:safe center}.teacher-lesson-title{font:inherit;font-size:17px;font-weight:500;text-align:left;color:inherit;padding:0;min-height:44px}
/* TeacherWorkDetailView: one continuous page with fixed action dock. */
.teacher-work-sheet{padding:0;border:0;margin:auto;width:min(100%,760px);height:min(100dvh,100%);max-width:100vw;max-height:100dvh;color:#000;background:#fff;border-radius:0;overflow:hidden}.teacher-work-sheet[open]{display:grid;grid-template-rows:auto minmax(0,1fr) auto}.teacher-work-sheet::backdrop{background:#0006}.teacher-work-header{display:flex;align-items:center;gap:12px;padding:10px 12px;border-bottom:1px solid #e5e7eb}.teacher-work-header h1{font-size:20px;flex:1;margin:0}.teacher-work-close{min-height:44px;color:#007aff}.teacher-work-content{min-height:0;overflow:auto;padding:12px;display:flex;flex-direction:column;gap:12px}.teacher-work-content h2{font-size:22px;margin:0}.teacher-work-content h3{font-size:22px;margin:0}.teacher-question-reference{font-size:13px}.teacher-question-reference p{margin:4px 0}.teacher-work-dock{border-top:1px solid #ddd;background:white;padding:12px;display:grid;gap:8px;max-height:45dvh;overflow:auto}.teacher-work-dock audio{width:100%;height:44px}.teacher-review-actions{display:flex;gap:12px}.teacher-review-actions button{flex:1;min-height:44px;border:1px solid #d1d5db;border-radius:8px;padding:8px}.teacher-work-sheet .primary{background:#007aff;color:white;border:0;border-radius:8px;padding:10px 14px;min-height:44px}.teacher-results-scroll{overflow:auto;max-height:46dvh}.teacher-results-table{border-collapse:collapse;table-layout:fixed;font-size:13px;width:max-content;min-width:100%}.teacher-results-table th,.teacher-results-table td{border:1px solid #d1d5db;padding:7px;min-width:84px;max-width:180px;text-align:center;overflow-wrap:anywhere}.teacher-results-table th{background:#fffbdf;position:sticky;left:0;z-index:1}.teacher-results-table td{background:#eef6ff}.teacher-results-table td[data-selected=true]{background:#cce3ff}.teacher-results-table button{font:inherit;font-weight:700;min-height:36px}.teacher-results-table input{width:70px;font:inherit;text-align:center;background:white;border:1px solid #bcd;border-radius:4px;padding:6px}.teacher-transcript{border-radius:12px;padding:12px;background:#f4f6fa}.teacher-transcript--student{background:#f0f7ff}.teacher-transcript--corrected{background:#f0faf2}.teacher-block-heading{display:block;width:100%;text-align:left;font:inherit;font-weight:700;min-height:44px}.teacher-transcript textarea{font:inherit;font-size:17px;line-height:1.45;resize:vertical;width:100%;min-height:140px;padding:10px;background:white;color:#000;border:1px solid #cbd5e1;border-radius:6px}.teacher-edit-actions{display:flex;flex-wrap:wrap;gap:8px;padding-top:8px}.teacher-edit-actions button{min-height:44px;padding:8px;color:#007aff}.teacher-current-mistakes{background:#fff3f3;padding:12px;border-radius:12px}.teacher-current-mistakes summary{font-weight:700;min-height:44px}.teacher-current-mistakes del{color:#c00}.teacher-answer-text,.teacher-corrected-text{white-space:pre-wrap;overflow-wrap:anywhere;font-size:17px}.teacher-corrected-text{color:#21864a}.teacher-test-item{padding:12px;border-bottom:1px solid #ddd}.teacher-tabs button[aria-current=page]{color:#000}
.teacher-settings-card{border:1px solid #e5e7eb;border-radius:14px;background:#fff;padding:16px;color:#111827;text-align:left;flex-shrink:0}.teacher-settings-profile{display:flex;flex-direction:column;gap:9px;background:#fafafc}.teacher-settings-label{display:inline-flex;align-items:center;gap:8px}.teacher-settings-row{display:flex;align-items:center;gap:8px;min-height:60px}.teacher-settings-row>.teacher-settings-label{flex:1}.teacher-settings-password{display:flex;justify-content:center;border:1px solid #cbd5e1;border-radius:999px;min-height:44px;margin-top:2px;color:#4f46e5}.teacher-settings-profile button{color:#4f46e5}.teacher-language-options{display:grid;gap:8px}.teacher-language-options>button{display:flex;justify-content:space-between;align-items:center;min-height:44px;color:#4f46e5}.teacher-privacy-host{min-height:350px}.teacher-shell-wrap{height:100%;min-height:0}
.teacher-work-sheet{width:min(calc(100% - 20px),760px);height:calc(100dvh - 40px);max-height:calc(100dvh - 40px);border-radius:28px}.teacher-work-header{padding:12px 24px;border:0;min-height:60px}.teacher-work-header h1{font-size:24px;font-weight:700}.teacher-work-content{padding-top:12px}.teacher-results-scroll{overflow-x:auto;overflow-y:visible;max-height:none;flex-shrink:0}.teacher-results-table{border-collapse:separate;border-spacing:0;width:100%;font-size:13px}.teacher-results-table th,.teacher-results-table td{height:44px;border:.5px solid #e5e7eb;border-radius:14px;font-size:13px;font-weight:400;padding:8px;min-width:0;max-width:none;overflow-wrap:normal}.teacher-results-table th{width:34%;font-weight:700;background:#fff5c4}.teacher-results-table td{background:#e0f2ff}.teacher-results-table td[data-selected=true]{background:#dbf0ff}.teacher-results-table thead td,.teacher-results-table thead th{height:64px}.teacher-results-table tr:last-child button{font-weight:700}.teacher-results-table input{border-radius:0;border:0;width:100%;background:transparent;min-width:32px}.teacher-results-table tr:has(input) td{border:1px solid #007aff}.teacher-block-header{display:flex;gap:10px;align-items:center;min-height:44px}.teacher-block-header strong{flex:1}.teacher-block-header button{color:#007aff;font-size:14px;min-height:44px;padding:0 3px}.teacher-transcript-text{white-space:pre-wrap;line-height:1.45;overflow-wrap:anywhere;margin:8px 0}.teacher-review-actions button{border:0;border-radius:999px;color:#000;background:#f1f1f3}.teacher-review-actions button.primary{background:#00a2ff;color:#000;font-weight:600}.teacher-work-dock .teacher-review-actions{align-items:center}.teacher-work-dock .teacher-review-actions button:first-child{flex:0 1 auto;min-width:80px;margin:auto}.teacher-review-actions .primary{flex:1;min-height:58px;max-width:60%}.teacher-work-sheet .teacher-work-close{background:none;border:0;padding:0;min-width:44px}.teacher-work-sheet .teacher-work-close .native-icon{color:#1e293b}
.teacher-shell-wrap{display:block;overflow:hidden}.teacher-preview-sheet{margin:auto;padding:0;border:0;border-radius:0;width:min(100vw,760px);height:100dvh;max-width:100vw;max-height:100dvh;overflow:hidden;background:#f7f8fa}.teacher-preview-sheet[open]{display:grid;grid-template-rows:auto minmax(0,1fr)}.teacher-preview-sheet .shell-header{display:flex;align-items:center;justify-content:space-between;gap:10px;min-height:64px;background:#fff}.teacher-preview-sheet .shell-header>div{flex:1;text-align:center}.teacher-preview-sheet h1{font-size:18px;line-height:1.25;margin:0}.teacher-preview-sheet small{display:block;text-align:center}.teacher-preview-sheet .screen-content{min-height:0;padding:0;overflow:hidden}
.teacher-review-actions button.primary{border-radius:999px}.teacher-tabs{padding:15px 8px}.teacher-tabs button{gap:16px;font-size:12px;padding:0;min-height:0;font-weight:600}.teacher-tabs button>span:last-child{white-space:nowrap;font-size:clamp(10px,2.9vw,12px);line-height:1.2}.teacher-results-table td button{font-size:13px}.teacher-results-table td input{font-size:13px}
.teacher-original-audio{padding:12px;border:1px solid #0003;border-radius:12px;background:#0000000a;display:flex;flex-direction:column;gap:12px;margin:0 0 12px;color:#151515}
.teacher-audio-heading{display:flex;justify-content:space-between;align-items:center;gap:8px;font-size:15px}.teacher-audio-clock{font-size:12px;color:#6b7280;white-space:nowrap}
.teacher-original-audio input[type=range]{width:100%;padding:0;accent-color:#2563eb;min-height:20px}
.teacher-audio-controls{display:flex;justify-content:center;align-items:center;flex-wrap:wrap;gap:15px;font-size:15px}
.teacher-audio-controls button{display:flex;align-items:center;justify-content:center;gap:4px;padding:0;min-width:24px;min-height:44px;background:none;color:#2563eb;border:0;border-radius:0;font-size:15px}
.teacher-audio-controls .teacher-audio-play{padding:10px;border-radius:999px;background:#00c7be40}.teacher-audio-controls button:disabled{color:#8e8e93;opacity:.5}
.teacher-comparison{flex-shrink:0;min-width:0}.teacher-comparison>p{margin:0 0 8px}.teacher-results-table th,.teacher-results-table td{border-radius:0}.teacher-results-table th{width:var(--teacher-label-width,34%)}.teacher-results-table thead button{white-space:pre-line;width:100%}.teacher-results-table thead button[aria-pressed=true]{outline:2px solid #007aff;outline-offset:-2px}
.teacher-work-sheet{container-type:inline-size}.teacher-block-header{font-size:16px;line-height:20px}.teacher-block-header button{flex-shrink:0;white-space:nowrap;overflow-wrap:normal}
.teacher-preview-sheet>.shell-header>div{min-width:0}.teacher-preview-sheet>.shell-header h1{white-space:normal;overflow-wrap:anywhere}.teacher-preview-sheet>.screen-content{min-width:0}.teacher-preview-sheet .native-lesson-dock{min-width:0;width:100%;box-sizing:border-box}
.teacher-results-table td{overflow-wrap:anywhere}
.teacher-results-table th,.teacher-results-table td{padding:8px 6px}.teacher-results-table button{padding:0 2px;min-width:0;border:0;background:transparent}.teacher-results-table thead td[data-selected=true]{outline:2px solid #007aff;outline-offset:-2px}.teacher-results-table thead button[aria-pressed=true]{outline:0}
.teacher-original-audio{container-type:inline-size}
@container(max-width:350px){.teacher-block-header{flex-wrap:wrap;column-gap:12px;row-gap:0}.teacher-block-header strong{flex-basis:100%}.teacher-block-header button{flex:none}}
/* Native ViewThatFits fallback: seek/stop/seek above Play/Pause. */
@container(max-width:280px){.teacher-audio-controls{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:8px}.teacher-audio-controls button:nth-child(1){grid-column:1/3;grid-row:1}.teacher-audio-controls button:nth-child(4){grid-column:3/5;grid-row:1}.teacher-audio-controls button:nth-child(5){grid-column:5/7;grid-row:1}.teacher-audio-controls button:nth-child(2){grid-column:1/4;grid-row:2}.teacher-audio-controls button:nth-child(3){grid-column:4/7;grid-row:2}}

.assessment-layout.native-assessment.teacher-question-preview{grid-template-rows:minmax(0,1fr) auto}

/* Keep native comparison header labels readable inside the fixed columns. */
.teacher-results-table thead td{padding:8px 2px}.teacher-results-table thead button{padding:0;overflow-wrap:normal}.teacher-results-table tr>td:last-child:not([data-selected]){background:#fff5c4}

.teacher-results-table th{overflow-wrap:anywhere}
