/* 教师批改与答疑共享名单、纸张和操作区。 */
body.teacher-workspace :is(.rv-batch,.rv-help) { position:relative; border:0; }
body.teacher-workspace .rv-batch > summary b { font-weight:600; }
body.teacher-workspace .rv-batch > summary span, body.teacher-workspace .rv-help > summary { color:var(--muted); }
body.teacher-workspace .rv-batch-pop { position:absolute; top:calc(100% + 5px); right:0; z-index:15; width:min(300px,88vw); padding:12px; border:1px solid var(--line); border-radius:9px; background:white; box-shadow:0 7px 22px #10284724; }
body.teacher-workspace .rv-batch-pop p { margin:7px 0; font-size:.8rem; color:var(--muted); line-height:1.6; }
body.teacher-workspace .rv-batch-options { display:grid; gap:2px; }
body.teacher-workspace .rv-batch-options button { display:flex; justify-content:space-between; gap:9px; width:100%; padding:8px; text-align:left; font-size:.875rem; border-radius:5px; }
body.teacher-workspace .rv-batch-options button:hover, body.teacher-workspace .rv-batch-options button[aria-pressed="true"] { color:var(--blue); background:var(--blue-l); }
body.teacher-workspace .rv-batch-options small { font-size:.75rem; }
body.teacher-workspace :is(.rv-grading,.rv-doubts) { display:grid; align-items:start; gap:12px; }
body.teacher-workspace .rv-grading { grid-template-columns:minmax(210px,20fr) minmax(0,48fr) minmax(295px,32fr); }
body.teacher-workspace .rv-doubts { grid-template-columns:minmax(240px,26fr) minmax(0,74fr); }
body.teacher-workspace .rv-card { min-width:0; background:#fff; border:1px solid #e0e6ef; border-radius:12px; box-shadow:0 1px 3px #182c4404; }
body.teacher-workspace .rv-card h2,body.teacher-workspace .rv-field-label { margin:0; font-size:var(--teacher-section-title); font-weight:680; line-height:1.4; color:var(--ink); }
body.teacher-workspace .rv-empty { grid-column:2 / -1; }
body.teacher-workspace .rv-card.rv-queue { padding:12px 10px 8px; }
body.teacher-workspace .rv-queue .queue-fold > summary { font-size:1.03rem; padding:4px 8px 11px; font-weight:650; }
body.teacher-workspace .rv-queue .queue-fold > .task-fold-body { gap:6px; }
body.teacher-workspace .rv-search { width:100%; }
body.teacher-workspace .rv-search .inp { display:block; width:100%; padding-left:31px; padding-right:30px; min-height:37px; }
body.teacher-workspace .rv-search::before, body.teacher-workspace .rv-search::after { content:''; position:absolute; pointer-events:none; color:#6b7a90; }
body.teacher-workspace .rv-search::before { left:11px; top:calc(50% - 7px); width:10px; height:10px; border:1.5px solid; border-radius:50%; }
body.teacher-workspace .rv-search::after { left:21px; top:calc(50% + 4px); width:5px; height:1.5px; background:currentColor; transform:rotate(48deg); }
body.teacher-workspace .rv-tabs { display:flex; border-bottom:1px solid var(--line-2); gap:0; }
body.teacher-workspace .rv-tabs button { flex:1; padding:9px 2px; min-width:0; font-size:.81rem; border-bottom:2px solid transparent; color:var(--muted); }
body.teacher-workspace .rv-tabs button.on { border-color:var(--blue); color:var(--blue); font-weight:650; }
body.teacher-workspace .rv-queue .rv-list { max-height:none; padding:0; }
body.teacher-workspace .rv-queue .rv-row { display:flex; flex-direction:column; align-items:stretch; justify-content:center; text-align:left; width:100%; gap:2px; min-height:58px; padding:9px 10px; line-height:1.5; }
body.teacher-workspace .rv-queue .rv-row.on { background:#eaf1ff; border-radius:6px; box-shadow:inset 3px 0 0 #366acf; }
body.teacher-workspace .rv-row-top { display:flex; align-items:center; justify-content:space-between; gap:6px; }
body.teacher-workspace .rv-row-top b { font-size:1rem; font-weight:650; color:var(--ink); }
body.teacher-workspace .rv-row-top small,body.teacher-workspace .rv-row-line { font-size:.75rem; color:var(--muted); }
body.teacher-workspace .rv-question-line { font-size:.92rem; color:var(--ink-2); overflow:hidden; white-space:nowrap; text-overflow:ellipsis; }
body.teacher-workspace .rv-row-extra { overflow:hidden; white-space:nowrap; text-overflow:ellipsis; font-size:.73rem; color:var(--muted); }
body.teacher-workspace .rv-pager { padding:8px 2px; margin:0; border:0; }
body.teacher-workspace .rv-scope > summary, body.teacher-workspace .rv-snippets > summary { color:var(--muted); font-size:.81rem; font-weight:500; }
body.teacher-workspace .rv-selects { display:grid; gap:6px; }
body.teacher-workspace .rv-selects select { width:100%; }
body.teacher-workspace .rv-empty-list, body.teacher-workspace .rv-no-draft { padding:14px 9px; color:var(--muted); font-size:.85rem; }

body.teacher-workspace .rv-card.rv-paper { padding:16px 12px 9px; }
body.teacher-workspace :is(.rv-paper-head,.rv-score-head,.rv-detail-head) { display:flex; gap:8px 12px; flex-wrap:wrap; align-items:center; }
body.teacher-workspace .rv-paper-head { justify-content:space-between; margin-bottom:12px; padding-inline:4px; }
body.teacher-workspace .rv-paper-head p { font-size:.75rem; color:var(--muted); margin-top:3px; }
body.teacher-workspace :is(.rv-paper-head,.rv-detail-head) .stu-link { font:inherit; color:var(--ink); text-decoration:none; border:0; padding:0; }
body.teacher-workspace :is(.rv-paper-head,.rv-detail-head) .stu-link:hover { color:var(--blue); text-decoration:underline; }
body.teacher-workspace .rv-photo-tools { display:flex; gap:4px; }
body.teacher-workspace .rv-score-shortcut { display:none; }
body.teacher-workspace .rv-photo-tools .btn { font-size:.78rem; }
body.teacher-workspace .rv-photo-tools .btn[aria-pressed="true"] { background:var(--blue-l); color:var(--blue); border-color:#b7ccee; }
body.teacher-workspace .rv-sheet-viewport { padding:0; border:0; border-radius:6px; overflow:auto; height:clamp(470px,57vh,700px); background:#eef0f1; overscroll-behavior:contain; }
body.teacher-workspace .rv-sheet, body.teacher-workspace .rv-draft {
  --rule-height:36px;
  margin:0; width:100%; min-height:100%; padding:22px 20px 28px 33px; border:0; border-radius:4px; box-shadow:none;
  background-color:#f8f6ee;
  background-image:linear-gradient(110deg,#695b4010,transparent 30%,#77683607),repeating-linear-gradient(to bottom,transparent 0,transparent calc(var(--rule-height) - 1px),#a2b4c746 var(--rule-height));
  background-position:0 0,0 23px;
}
body.teacher-workspace :is(.rv-sheet,.rv-draft)::before { left:22px; width:1px; background:#d7958c7a; }
body.teacher-workspace .rv-sheet-top { display:flex; align-items:flex-start; justify-content:space-between; gap:6px; margin-bottom:10px; }
body.teacher-workspace .rv-sheet-top > span { font-size:.75rem; letter-spacing:.02em; color:#6b695e; }
body.teacher-workspace .rv-sheet .red-score-stamp { position:static; flex:none; display:inline-flex; align-items:baseline; gap:3px; border:2px solid #a83736; color:#a83736; background:transparent; border-radius:50%; padding:3px 13px; font:italic 1.65rem/1.15 Georgia,serif; transform:rotate(-8deg); }
body.teacher-workspace .red-score-stamp small { display:inline; font:inherit; font-size:.95rem; }
body.teacher-workspace :is(.rv-sheet-stem,.rv-sheet .hw-hand-line,.rv-draft .hw-hand-line) { font-family:KaiTi,STKaiti,"Kaiti SC","FangSong",Cambria,serif; font-size:clamp(1.05rem,1.34vw,1.28rem); color:#233858; overflow-wrap:anywhere; line-height:var(--rule-height); }
body.teacher-workspace .rv-sheet-stem { font-weight:600; margin:4px 0 20px; }
body.teacher-workspace .rv-sheet .hw-hand-line, body.teacher-workspace .rv-draft .hw-hand-line { margin-bottom:12px; letter-spacing:.015em; }
body.teacher-workspace .rv-red-note { display:block; margin:0 1px 2px auto; color:#9a3d34; font-size:.88em; line-height:1.5; text-align:right; }
body.teacher-workspace .rv-sheet.zoom { width:138%; --rule-height:43px; transform:none; }
body.teacher-workspace .rv-sheet.zoom .hw-hand-line,body.teacher-workspace .rv-sheet.zoom .rv-sheet-stem { font-size:1.48rem; }
body.teacher-workspace .rv-sheet.rot90 { transform-origin:top left; transform:rotate(90deg) translateY(-100%); border:0; }
body.teacher-workspace .rv-photo-caption { font-size:.74rem; line-height:1.5; color:var(--muted); margin:8px 4px 0; }

body.teacher-workspace .rv-card.rv-score { padding:16px; }
body.teacher-workspace .rv-score-head { justify-content:space-between; margin:0 0 12px; }
body.teacher-workspace .rv-score-head > span { font-size:.9rem; color:var(--muted); font-variant-numeric:tabular-nums; }
body.teacher-workspace .rv-score-head strong { font-size:1.65rem; font-weight:700; line-height:1; color:var(--blue); }
body.teacher-workspace .rv-rubrics { display:grid; grid-template-columns:minmax(0,1fr); gap:0; }
body.teacher-workspace .rv-rubrics .rubric-item { display:flex; align-items:center; justify-content:space-between; gap:8px; padding:12px 1px; border:0; border-top:1px solid var(--line-2); border-radius:0; background:white; color:var(--ink); font-size:.9rem; font-weight:600; line-height:1.5; }
body.teacher-workspace .rv-rubrics .rubric-item small { flex:none; padding:3px 7px; margin:0; font-size:.9rem; font-variant-numeric:tabular-nums; font-weight:650; color:#285bac; background:#f3f6fb; border:1px solid #dfe6ef; border-radius:5px; }
body.teacher-workspace .rv-rubrics .rubric-item small span { font-size:.8rem; font-weight:400; color:var(--muted); }
body.teacher-workspace .rv-rubrics .rubric-item.deduct small { color:var(--bad); background:#fff6f5; }
body.teacher-workspace .rv-rubrics .rubric-item:not(:disabled):hover { background:var(--hover); }
body.teacher-workspace .rv-rubrics .rubric-item:disabled { opacity:.9; }
body.teacher-workspace .rv-grade-state { display:flex; align-items:center; justify-content:space-between; gap:6px; padding:5px 0 12px; font-size:.75rem; color:var(--muted); }
body.teacher-workspace .rv-ref { display:flex; justify-content:space-between; align-items:center; width:100%; padding:11px 0; border-block:1px solid var(--line-2); font-size:.88rem; font-weight:650; }
body.teacher-workspace .rv-switch { display:inline-flex; align-items:center; width:31px; height:18px; padding:2px; background:#a4acb7; border-radius:14px; }
body.teacher-workspace .rv-switch::after { content:''; width:14px; height:14px; background:white; border-radius:50%; }
body.teacher-workspace .rv-switch.on { justify-content:flex-end; background:var(--blue); }
body.teacher-workspace .rv-answer { white-space:pre-line; font-size:.85rem; line-height:1.65; }
body.teacher-workspace .rv-score .rv-field-label { display:block; font-size:.94rem; margin:13px 0 6px; }
body.teacher-workspace .rv-comment,body.teacher-workspace .rv-reply-text { width:100%; padding:10px 12px; font-size:1rem; line-height:1.75; background:white; resize:vertical; }
body.teacher-workspace .rv-comment { min-height:112px; }
body.teacher-workspace .rv-submit { width:100%; margin:10px 0 0; min-height:39px; }
body.teacher-workspace .rv-snippets { border:0; }
body.teacher-workspace .rv-snippets .quick-chip { white-space:normal; text-align:left; }
body.teacher-workspace .rv-doubt-detail { padding:18px; }
body.teacher-workspace .rv-detail-head > span, body.teacher-workspace .rv-detail-head > small { color:var(--muted); font-size:.8rem; }
body.teacher-workspace .rv-detail-head > span + span { padding-left:10px; border-left:1px solid var(--line); }
body.teacher-workspace .rv-detail-head .rv-doubt-status { font-size:.75rem; color:#375784; background:#eff4fb; padding:2px 6px; border-radius:5px; }
body.teacher-workspace .rv-quote { position:relative; background:#eaf2ff; border:0; border-radius:9px; margin:17px 0; padding:15px 16px 15px 41px; }
body.teacher-workspace .rv-quote::before { content:'“'; position:absolute; top:4px; left:12px; color:#739bd9; font:700 2.9rem/1.2 Georgia,serif; }
body.teacher-workspace .rv-quote p { margin:0; color:#203955; font-size:clamp(1rem,1.3vw,1.21rem); line-height:1.6; font-weight:600; }
body.teacher-workspace .rv-quote .sr-question { position:absolute; clip-path:inset(50%); width:1px; height:1px; overflow:hidden; }
body.teacher-workspace .rv-doubt-columns { display:grid; grid-template-columns:minmax(0,.95fr) minmax(0,1.05fr); align-items:stretch; gap:14px; }
body.teacher-workspace .rv-context, body.teacher-workspace .rv-reply { min-width:0; background:#fff; border:1px solid var(--line-2); border-radius:9px; padding:13px; }
body.teacher-workspace .rv-context > summary { padding:0; min-height:30px; font-size:1rem; font-weight:650; }
body.teacher-workspace .rv-context > .task-fold-body { padding:8px 0 0; }
body.teacher-workspace .rv-stem-context { padding:9px 11px; margin:0 0 11px; border-radius:6px; background:#f2f5f9; color:var(--ink); font-size:.875rem; line-height:1.6; }
body.teacher-workspace .rv-draft { --rule-height:32px; padding:13px 12px 16px 23px; background-color:#fafaf7; min-height:clamp(210px,30vh,320px); }
body.teacher-workspace .rv-draft::before { left:15px; }
body.teacher-workspace .rv-draft .hw-hand-line { font-size:1.03rem; }
body.teacher-workspace .rv-draft-caption { font-size:.75rem; color:var(--muted); margin:0 0 10px; }
body.teacher-workspace .rv-conversation { margin-top:10px; border-top:1px solid var(--line-2); }
body.teacher-workspace .rv-conversation > summary { font-size:.85rem; }
body.teacher-workspace .rv-conversation ol { list-style:none; padding:0; }
body.teacher-workspace .rv-conversation li { padding:9px 0; border-top:1px solid var(--line-2); }
body.teacher-workspace .rv-conversation li b { color:var(--blue-d); font-size:.78rem; }
body.teacher-workspace .rv-conversation li p { white-space:pre-wrap; overflow-wrap:anywhere; margin:3px 0; font-size:.88rem; }
body.teacher-workspace .rv-reply { display:flex; flex-direction:column; gap:10px; }
body.teacher-workspace .rv-reply .rv-field-label { font-size:1rem; }
body.teacher-workspace .rv-reply-text { flex:1; min-height:clamp(240px,32vh,380px); }
body.teacher-workspace .rv-reply-ops { display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:8px; }
body.teacher-workspace .rv-reply-ops .rv-snippets { width:100%; }
body.teacher-workspace .rv-variant-check { display:flex; align-items:center; gap:5px; min-height:30px; font-size:.8rem; color:var(--ink-2); }
body.teacher-workspace .rv-register { padding:17px; }
body.teacher-workspace .rv-register-filter { padding:0 0 12px; margin:0; border:0; border-bottom:1px solid var(--line-2); border-radius:0; }
body.teacher-workspace .rv-register-summary { margin:10px 0; padding:9px 10px; background:#f4f7fb; border:0; border-radius:7px; }
body.teacher-workspace .rv-register-table .tbl-wrap { max-width:100%; overflow:auto; }
@media (min-width:861px) and (max-width:1100px) {
  body.teacher-workspace .rv-grading { grid-template-columns:minmax(174px,21%) minmax(0,1fr) minmax(265px,.75fr); gap:8px; }
  body.teacher-workspace .rv-card.rv-score { padding:12px; }
  body.teacher-workspace .rv-queue .rv-row { padding-inline:6px; }
  body.teacher-workspace .rv-doubts { grid-template-columns:minmax(200px,25%) minmax(0,1fr); }
}
@media (max-width:860px) {
  body.teacher-workspace .teacher-page-header:has(.rv-batch,.rv-help) { position:relative; }
  body.teacher-workspace :is(.rv-batch,.rv-help) { position:static; }
  body.teacher-workspace .rv-batch-pop { left:0; right:auto; }
  body.teacher-workspace .rv-photo-tools .rv-score-shortcut { display:inline-flex; color:var(--blue); }
  body.teacher-workspace #rv-scoring { scroll-margin-top:16px; }
  body.teacher-workspace .rv-doubt-columns { grid-template-columns:minmax(0,1fr); }
  body.teacher-workspace :is(.rv-grading,.rv-doubts) { grid-template-columns:minmax(0,1fr); gap:10px; }
  body.teacher-workspace .rv-empty { grid-column:1; }
  body.teacher-workspace .rv-card.rv-queue { padding:4px 10px; }
  body.teacher-workspace .rv-queue .queue-fold > summary { padding:6px 2px; min-height:42px; }
  body.teacher-workspace .rv-queue .queue-fold .rv-list { max-height:45vh; }
  body.teacher-workspace .rv-queue .queue-fold > .task-fold-body { padding-bottom:8px; }
  body.teacher-workspace .rv-sheet-viewport { height:clamp(360px,52vh,550px); }
  body.teacher-workspace .rv-doubt-detail { padding:12px; }
}
@media (max-width:600px) {
  body.teacher-workspace .rv-doubt-columns { grid-template-columns:minmax(0,1fr); gap:9px; }
  body.teacher-workspace .rv-detail-head { gap:5px 8px; }
  body.teacher-workspace .rv-quote { margin:13px 0; }
  body.teacher-workspace .rv-reply-text { min-height:160px; }
  body.teacher-workspace .rv-register { padding:12px; }
  body.teacher-workspace .rv-register .fb-left,.rv-register .filter-bar,.rv-register .seg { min-width:0; max-width:100%; flex-wrap:wrap; }
  body.teacher-workspace .rv-register .tbl { min-width:760px; }
  body.teacher-workspace .rv-register-table .pager { gap:8px; }
  body.teacher-workspace .rv-register-table .pager > span { font-size:.75rem; }
}

/* 批改台使用与组卷相同的卡片边界；学生作答保留纸面与圈批。 */
body.teacher-workspace .rv-grading {
  --grade-inset:clamp(13px,1.2vw,20px);
  --grade-rule:#e0e6ef;
  gap:12px;
}
body.teacher-workspace .rv-grading>.rv-card,body.teacher-workspace .rv-card.rv-register {
  border:1px solid #d7e0ed;border-radius:11px;background:white;box-shadow:none
}
body.teacher-workspace .rv-grading>.rv-queue {padding:0}
body.teacher-workspace .rv-grading .queue-fold>summary {
  justify-content:flex-start;min-height:52px;padding:11px var(--grade-inset);border-bottom:1px solid var(--grade-rule);
  font-size:var(--teacher-section-title);font-weight:650;color:#24334c
}
body.teacher-workspace .rv-grading .queue-fold>summary small {margin-inline-start:auto;font-size:13px;color:var(--muted);font-variant-numeric:tabular-nums}
body.teacher-workspace .rv-grading .queue-fold>.task-fold-body {padding:0;gap:0}
body.teacher-workspace .rv-grading .rv-search {width:auto;margin:10px 10px 2px}
body.teacher-workspace .rv-grading .rv-tabs {margin:0 10px}
body.teacher-workspace .rv-grading .rv-list {padding:5px;overscroll-behavior:contain;scrollbar-width:thin}
body.teacher-workspace .rv-grading .rv-row {padding:8px 9px;min-height:53px;gap:2px;border-radius:4px}
body.teacher-workspace .rv-grading .rv-row-top b {font-size:15px;font-weight:600}
body.teacher-workspace .rv-grading .rv-row.on .rv-row-top b {color:#234f9e}
body.teacher-workspace .rv-grading .rv-row-line {line-height:1.5;overflow-wrap:anywhere}
body.teacher-workspace .rv-grading .rv-pager {min-height:40px;margin:0;padding:5px 12px;border-top:1px solid var(--grade-rule);background:#fff}
body.teacher-workspace .rv-grading .rv-scope {border-top:1px solid var(--grade-rule);padding:0 12px}
body.teacher-workspace .rv-grading .rv-scope>summary {min-height:34px}
body.teacher-workspace .rv-grading .rv-selects {padding:0 0 9px}
body.teacher-workspace .rv-grading .teacher-class-picker {width:100%}
/* 名单、图片和判分各有独立空间，提交栏固定在批阅区底部。 */
body.teacher-workspace .rv-grading {
  --review-inset:clamp(12px,1.25vw,20px);
  grid-template-columns:clamp(224px,20%,296px) minmax(0,1fr);
  gap:clamp(16px,1.4vw,24px);align-items:start;
}
body.teacher-workspace .rv-grading .rv-review {padding:0;min-width:0;container-type:inline-size;scroll-margin-top:14px}
body.teacher-workspace .rv-queue-current {color:#4e607b;font-size:14px;font-weight:500}
body.teacher-workspace .queue-fold[open] .rv-queue-current {display:none}
body.teacher-workspace .rv-queue-entry {position:relative;flex:none;min-width:0}
body.teacher-workspace .rv-queue-entry:has(.rv-profile) .rv-row-top {padding-right:30px}
body.teacher-workspace .rv-profile {position:absolute;right:6px;top:6px;display:grid;place-items:center;width:30px;height:30px;border-radius:5px;color:#536aa0}
body.teacher-workspace .rv-profile:hover {background:#dce6ff}
body.teacher-workspace .rv-profile svg {width:15px;height:15px}
body.teacher-workspace .rv-grading .rv-list {padding:4px 8px}
body.teacher-workspace .rv-grading .rv-row {padding:11px 12px;gap:5px;min-height:64px;border:0;border-radius:7px;box-shadow:none}
body.teacher-workspace .rv-queue-entry+.rv-queue-entry {border-top:1px solid #e9edf4}
body.teacher-workspace .rv-grading .rv-row:hover {background:#f7f9fd}
body.teacher-workspace .rv-grading .rv-row.on {background:#edf2ff;box-shadow:inset 3px 0 #4a65d4}
body.teacher-workspace .rv-grading .rv-row-top small {color:#616f86;font-size:12px}
body.teacher-workspace .rv-grading .rv-row-line {font-size:13px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}
body.teacher-workspace .rv-document {margin:0 var(--review-inset)}
body.teacher-workspace .rv-topic {padding:16px 0}
body.teacher-workspace .rv-document-bar,.rv-reading-tools,.rv-submit-actions,.rv-score-foot,.rv-total {
  display:flex;align-items:center;gap:8px;
}
body.teacher-workspace .rv-document-bar {display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:10px 18px}
body.teacher-workspace .rv-review svg,.rv-original svg {width:16px;height:16px;flex:none}
body.teacher-workspace .rv-reading-tools {gap:6px;flex-wrap:wrap}
body.teacher-workspace .rv-reading-tools select {min-width:0;max-width:170px}
body.teacher-workspace .rv-reading-tools button {
  display:inline-flex;align-items:center;justify-content:center;gap:6px;padding:5px 10px;min-height:32px;
  background:white;color:#465875;border:1px solid #d7e0ec;border-radius:6px;font-size:14px;font-weight:550;
}
body.teacher-workspace .rv-reading-tools button:hover {background:#f0f4ff;color:#344e9d;border-color:#b5c5e5}
body.teacher-workspace .rv-review .rv-question-text {margin:0;color:#182a43;font:600 clamp(18px,1.35vw,22px)/1.55 Cambria,"Microsoft YaHei",serif;overflow-wrap:anywhere}
body.teacher-workspace .rv-review-spread {
  display:grid;grid-template-columns:minmax(0,1fr) clamp(268px,33%,400px);gap:12px;align-items:stretch;
}
body.teacher-workspace .rv-review-spread>.hw-viewer,
body.teacher-workspace .rv-steps {
  border:1px solid #d5dee9;border-radius:9px;min-width:0;overflow:hidden;background:#fff
}
body.teacher-workspace .rv-review-spread>.hw-viewer {--hw-viewer-height:230px}
body.teacher-workspace .rv-steps-head {
  display:flex;align-items:center;gap:10px;min-height:45px;padding:7px 14px;border-bottom:1px solid #dee5ed;
}
body.teacher-workspace .rv-steps-head h3 {margin:0;color:#263952;font-size:15px;font-weight:650;line-height:1.5}
body.teacher-workspace .rv-steps-head small {margin-inline-start:auto;color:#60718a;font-size:12px;white-space:nowrap}
body.teacher-workspace .rv-step-list {margin:0;padding:0;list-style:none}
body.teacher-workspace .rv-verdict {padding:14px;background:#fff}
body.teacher-workspace .rv-verdict+.rv-verdict {border-top:1px solid #e4e9ef}
body.teacher-workspace .rv-step-top {display:flex;align-items:flex-start;justify-content:space-between;gap:8px}
body.teacher-workspace .rv-criterion {display:flex;flex-direction:column;align-items:flex-start;gap:3px;min-width:0}
body.teacher-workspace .rv-criterion b {color:#213650;font-size:15px;font-weight:650;line-height:1.5;overflow-wrap:anywhere}
body.teacher-workspace .rv-step-number {color:#536d9c;font-size:16px}
body.teacher-workspace .rv-criterion small {font-size:12px;line-height:1.4;color:#60718a}
body.teacher-workspace .rv-step-reference {margin:9px 0 0;padding:6px 10px;border-left:2px solid #a5baaf;background:#f4f8f5;color:#344d42;font-size:14px;line-height:1.55;white-space:pre-line;overflow-wrap:anywhere}
body.teacher-workspace .rv-step-reference b {font-size:12px;color:#536e5f;font-weight:600;margin-right:3px}
body.teacher-workspace .rv-steps>.rv-step-reference {margin:12px 14px}
body.teacher-workspace .rv-step-result {flex:none;font-size:13px;font-weight:600;color:#266650;padding:4px 8px;border-radius:5px;background:#edf6f1}
body.teacher-workspace [data-verdict="deducted"] .rv-step-result {color:#a34b3b;background:#fbf1ed}
body.teacher-workspace .rv-review .rv-jump {display:none}
body.teacher-workspace .rv-point-scale {display:inline-grid;flex:none;grid-template-columns:repeat(2,1fr);padding:3px;gap:2px;border-radius:9px;background:#edf1f6}
body.teacher-workspace .rv-point-choice {position:relative;cursor:pointer}
body.teacher-workspace .rv-point-choice input {position:absolute;inset:0;width:100%;height:100%;margin:0;opacity:0;cursor:inherit}
body.teacher-workspace .rv-point-choice span {
  display:grid;place-items:center;min-width:40px;min-height:32px;padding:0 9px;
  font-size:15px;font-weight:500;border-radius:6px;color:#526177;
}
body.teacher-workspace .rv-point-choice:hover span {background:#dfe5ef}
body.teacher-workspace .rv-point-choice.earned input:checked+span {background:#26705e;color:#fff;font-weight:700}
body.teacher-workspace .rv-point-choice.deducted input:checked+span {background:#ac493c;color:#fff;font-weight:700}
body.teacher-workspace .rv-point-choice input:focus-visible+span {outline:2px solid #3458ae;outline-offset:2px}
body.teacher-workspace .rv-feedback {margin:14px var(--review-inset);border:1px solid #dce3ed;border-radius:8px;background:#fafbfd}
body.teacher-workspace .rv-feedback summary {list-style:none;display:flex;align-items:center;gap:10px;min-height:48px;padding:10px 14px;cursor:pointer;color:#455a7c}
body.teacher-workspace .rv-feedback summary::-webkit-details-marker {display:none}
body.teacher-workspace .rv-feedback summary b {white-space:nowrap;color:#293a54;font-size:15px;font-weight:650}
body.teacher-workspace .rv-feedback-preview {min-width:0;flex:1;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;color:#56667e;font-size:14px}
body.teacher-workspace .rv-feedback-toggle {margin-left:auto;display:inline-flex;align-items:center;gap:7px;color:#385b9b;font-size:14px}
body.teacher-workspace .rv-feedback-toggle::after {content:'';width:6px;height:6px;border:solid currentColor;border-width:0 1.5px 1.5px 0;transform:rotate(45deg)}
body.teacher-workspace .rv-feedback[open] .rv-feedback-toggle::after {transform:rotate(225deg)}
body.teacher-workspace .rv-feedback[open] :is(.rv-feedback-preview,.rv-feedback-toggle span) {display:none}
body.teacher-workspace .rv-feedback-content {padding:0 14px 14px}
body.teacher-workspace .rv-feedback .rv-comment {display:block;min-height:104px;field-sizing:content;font-size:16px;line-height:1.65;margin:0}
body.teacher-workspace .rv-phrases {display:flex;flex-wrap:wrap;align-items:center;gap:6px;margin-top:10px}
body.teacher-workspace .rv-phrases button {border:1px solid #d9e2ed;border-radius:5px;background:white;color:#405a7e;padding:5px 9px;font-size:14px;line-height:1.45;text-align:left}
body.teacher-workspace .rv-phrases button:hover {border-color:#90a7c7}
body.teacher-workspace .rv-phrases .rv-library {border:0;background:transparent;color:#385b9b}
body.teacher-workspace .rv-comment-readonly {margin:0;color:#344861;font-size:16px;line-height:1.7;white-space:pre-wrap;overflow-wrap:anywhere}
body.teacher-workspace .rv-score-foot {justify-content:space-between;flex-wrap:wrap;gap:10px 16px;padding:13px var(--review-inset);border-top:1px solid var(--grade-rule)}
body.teacher-workspace .rv-total {align-items:baseline;flex-wrap:wrap;gap:4px;color:#5a6981;font-size:14px;font-variant-numeric:tabular-nums}
body.teacher-workspace .rv-total strong {margin-left:3px;font-size:29px;font-weight:700;line-height:1.2;color:#253b69}
body.teacher-workspace .rv-deduction {margin-left:8px;padding-left:12px;border-left:1px solid #dce3ec;font-size:13px;color:#8c503f}
body.teacher-workspace .rv-submit-actions .btn {display:inline-flex;align-items:center;justify-content:center;gap:7px;min-height:40px;padding:7px 16px;border-radius:7px;font-size:14px}
body.teacher-workspace .rv-submit-actions .rv-full {color:#325b4a;background:white;border-color:#c9d8d1}
body.teacher-workspace .rv-submit-actions .btn.primary {min-width:145px}
body.teacher-workspace .modal-dialog:has(.rv-original) {width:min(1080px,100%);max-width:none;max-height:92dvh;padding:0}
body.teacher-workspace .rv-original {padding:16px}
body.teacher-workspace .rv-original>header {display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:12px}
body.teacher-workspace .rv-original h2 {margin:0;font-size:18px}
body.teacher-workspace .rv-original h2 small {font-size:13px;font-weight:500;color:#63718a}
body.teacher-workspace .rv-original .hw-viewer {--hw-viewer-height:min(72dvh,720px);border:1px solid #d5dee9;border-radius:8px}
body.teacher-workspace .modal-dialog:has(.rv-comment-library) {max-width:480px;padding:20px}
body.teacher-workspace .rv-comment-library .card-h {align-items:center;border-bottom:1px solid #dce4ef;margin-bottom:16px;padding-bottom:12px}
body.teacher-workspace .rv-comment-library h2 {font-size:19px;line-height:1.4;color:var(--ink);margin:0}
body.teacher-workspace .rv-comment-library h3,.rv-library-more summary {font-size:13px;line-height:1.5;font-weight:600;color:#495b74}
body.teacher-workspace .rv-library-options {display:grid;gap:6px;margin-top:8px}
body.teacher-workspace .rv-library-option {display:block;width:100%;text-align:start;padding:10px 12px;line-height:1.5;font-size:14px;color:#273e5d;background:#f6f8fc;border:1px solid #dce4ef;border-radius:6px;cursor:pointer}
body.teacher-workspace .rv-library-option:hover,.rv-library-option:focus-visible {background:#eef3ff;border-color:#8ca9d7}
body.teacher-workspace .rv-library-more {margin-top:14px;border-top:1px solid #dce4ef;padding-top:12px}
body.teacher-workspace .rv-library-more summary {cursor:pointer}

body.teacher-workspace .rv-batch-pop:has([data-action="remind-unsubmitted-hw"]) {font-size:14px}
body.teacher-workspace .rv-missing .rv-batch-pop ul {margin:8px 0 12px;padding-left:18px;color:#415572}
body.teacher-workspace .rv-batch-options button small {flex:none;white-space:nowrap}
body.teacher-workspace .rv-grade-receipt {
  display:inline-flex;align-items:center;max-width:100%;gap:8px;
  color:#486052;font-size:13px;line-height:1.5;
}
body.teacher-workspace .rv-grade-receipt [role="status"] {display:flex;align-items:center;gap:5px;min-width:0;overflow-wrap:anywhere}
body.teacher-workspace .rv-grade-receipt svg {flex:none;width:15px;height:15px;color:#377052}
body.teacher-workspace .rv-grade-receipt b {font-weight:600}
body.teacher-workspace .rv-grade-receipt button {
  flex:none;min-height:30px;padding:3px 7px;color:#39589e;background:transparent;
  border-radius:4px;font-size:13px;font-weight:600;
}
body.teacher-workspace .rv-grade-receipt button:hover,
body.teacher-workspace .rv-grade-receipt button:focus-visible {background:#e9eef9;text-decoration:underline}
@media (max-width:860px) {
  body.teacher-workspace .rv-grading .rv-queue:has(>.rv-grade-receipt) {
    display:grid;grid-template-columns:minmax(0,1fr) fit-content(65%);align-items:center
  }
  body.teacher-workspace .rv-queue:has(>.rv-grade-receipt)>.queue-fold {min-width:0;grid-column:1;grid-row:1}
  body.teacher-workspace .rv-queue>.rv-grade-receipt {grid-column:2;grid-row:1;gap:1px;padding-right:7px;font-size:12px}
  body.teacher-workspace .rv-queue>.rv-grade-receipt button {min-height:36px}
  body.teacher-workspace .rv-queue:has(>.rv-grade-receipt) .queue-fold:not([open]) small {display:none}
  body.teacher-workspace .rv-grading .rv-queue:has(>.rv-grade-receipt):has(>.queue-fold[open]) {
    grid-template-columns:minmax(0,1fr);grid-template-rows:auto minmax(0,1fr)
  }
  body.teacher-workspace .rv-queue:has(>.queue-fold[open])>.rv-grade-receipt {
    grid-column:1;justify-content:flex-end;border-bottom:1px solid var(--grade-rule)
  }
  body.teacher-workspace .rv-queue:has(>.rv-grade-receipt)>.queue-fold[open] {grid-row:2;width:100%;min-height:0}
  body.teacher-workspace .rv-queue:has(>.rv-grade-receipt) .rv-queue-current {
    min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap
  }
}
@media (max-width:380px) {
  body.teacher-workspace .rv-grading .rv-queue:has(>.rv-grade-receipt) .queue-fold:not([open])>summary {
    display:grid;grid-template-columns:8px minmax(0,1fr);gap:1px 6px;
    padding:4px 8px;font-size:14px;line-height:1.2;white-space:nowrap
  }
  body.teacher-workspace .rv-queue:has(>.rv-grade-receipt) .queue-fold:not([open])>summary::before {grid-row:1 / span 2}
  body.teacher-workspace .rv-queue:has(>.rv-grade-receipt) .rv-queue-current {grid-column:2;font-size:12px}
}

@media (min-width:861px), (min-height:520px) {
  html:has(.studio-content>.rv-grading) {scrollbar-gutter:auto}
  body.teacher-workspace .app.studio:has(> main > .rv-grading) {height:100dvh;min-height:0;display:grid;grid-template-rows:auto minmax(0,1fr)}
  body.teacher-workspace main.content.studio-content:has(> .rv-grading) {min-height:0;display:grid;grid-template-rows:auto minmax(0,1fr);padding-bottom:var(--teacher-page-top)}
  body.teacher-workspace .rv-grading {min-height:0;grid-template-rows:minmax(0,1fr);align-items:stretch}
  body.teacher-workspace .rv-grading .rv-review {min-height:0;display:grid;grid-template-rows:minmax(0,1fr) auto}
  body.teacher-workspace .rv-review-body {min-height:0;overflow:auto;scrollbar-width:thin;overscroll-behavior:contain;display:flex;flex-direction:column}
  body.teacher-workspace .rv-review-body .rv-document {flex:1 0 auto;display:flex;flex-direction:column}
  body.teacher-workspace .rv-review-spread {flex:1 0 auto}
  body.teacher-workspace .rv-feedback {flex:none}
  body.teacher-workspace .rv-grading .rv-queue {min-height:0;overflow:auto;scrollbar-width:thin}
  body.teacher-workspace .rv-grading .queue-fold[open] {height:100%;display:flex;flex-direction:column;min-height:0}
  body.teacher-workspace .rv-grading .queue-fold[open]::details-content,
  body.teacher-workspace .rv-grading .queue-fold[open]>.task-fold-body {display:flex;min-height:0;flex-direction:column;flex:1}
  body.teacher-workspace .rv-grading .queue-fold>.task-fold-body>:not(.rv-list),body.teacher-workspace .rv-grading .queue-fold>summary {flex:none}
  body.teacher-workspace .rv-grading .rv-queue .rv-list {flex:1 1 0;min-height:0;max-height:none;overflow-y:auto}
}
@media (max-width:860px) {
  body.teacher-workspace .rv-grading {grid-template-columns:minmax(0,1fr);gap:12px;--review-inset:16px}
  body.teacher-workspace .rv-grading .queue-fold:not([open])>summary {border:0}
  body.teacher-workspace .rv-grading .queue-fold>summary {min-height:44px;padding-block:8px}
}
@media (max-width:860px) and (min-height:520px) {
  body.teacher-workspace .rv-grading {grid-template-rows:auto minmax(0,1fr)}
  body.teacher-workspace .rv-grading:has(.queue-fold[open]) {grid-template-rows:minmax(0,1fr)}
  body.teacher-workspace .rv-grading:has(.queue-fold[open])>:not(.rv-queue) {display:none}
}
@media (min-height:520px) {
  @container (min-width:681px) {
    body.teacher-workspace .rv-review-body:not(:has(.rv-feedback[open])) .rv-document {flex:1 1 0;min-height:250px}
    body.teacher-workspace .rv-review-body:not(:has(.rv-feedback[open])) .rv-review-spread {flex:1 1 0;min-height:0}
    body.teacher-workspace .rv-steps {display:flex;flex-direction:column}
    body.teacher-workspace .rv-steps-head {flex:none}
    body.teacher-workspace .rv-step-list {min-height:0;overflow:auto;scrollbar-width:thin;overscroll-behavior:contain}
    body.teacher-workspace .rv-review-body:not(:has(.rv-feedback[open])) .rv-review-spread>.hw-viewer {--hw-viewer-height:0px}
  }
}
@container (max-width:680px) {
  body.teacher-workspace .rv-review-spread {grid-template-columns:minmax(0,1fr)}
  body.teacher-workspace .rv-review-spread>.hw-viewer {--hw-viewer-height:clamp(220px,39dvh,390px)}
  body.teacher-workspace .rv-review .rv-jump {display:inline-flex;align-items:center;justify-content:center;color:#385998;border:1px solid #d7e0ec;border-radius:5px;background:white;font:inherit;font-size:13px;padding:4px 8px;min-height:32px}
}
@container (max-width:660px) {
  body.teacher-workspace .rv-document-bar {grid-template-columns:minmax(0,1fr)}
  body.teacher-workspace .rv-reading-tools select {max-width:100%}
  body.teacher-workspace .rv-score-foot {gap:10px}
  body.teacher-workspace .rv-deduction {margin-left:5px;padding-left:6px}
}
@container (max-width:530px) {
  body.teacher-workspace .rv-verdict {padding:12px}
  body.teacher-workspace .rv-point-choice span {min-width:45px;min-height:44px}
  body.teacher-workspace .rv-feedback-preview {font-size:13px}
  body.teacher-workspace .rv-feedback summary {gap:7px;padding-inline:10px}
  body.teacher-workspace .rv-submit-actions {flex:1 1 100%}
  body.teacher-workspace .rv-submit-actions .primary {flex:1}
}
@container (min-width:350px) and (max-width:530px) {
  body.teacher-workspace .rv-score-foot {padding:9px 12px;flex-wrap:nowrap}
  body.teacher-workspace .rv-total {display:grid;grid-template-columns:auto 1fr;gap:0 3px}
  body.teacher-workspace .rv-total>span:first-child,body.teacher-workspace .rv-total .rv-deduction {grid-column:1/-1;margin:0;padding:0;border:0;font-size:12px}
  body.teacher-workspace .rv-total strong {margin:0;font-size:23px}
  body.teacher-workspace .rv-submit-actions {flex:0 0 auto;gap:5px}
  body.teacher-workspace .rv-submit-actions .btn {min-width:0;padding:6px 9px;font-size:13px}
  body.teacher-workspace .rv-full svg {display:none}
}
@media (forced-colors:active) {
  body.teacher-workspace .rv-point-choice input:checked+span {outline:2px solid Highlight;outline-offset:-2px}
}

/* 纸质登记从班级范围进入批量操作，窄屏将每份记录纵向展开。 */
body.teacher-workspace .rv-card.rv-register {padding:0;overflow:visible}
body.teacher-workspace .rv-register-head {display:flex;align-items:center;justify-content:space-between;gap:8px 16px;flex-wrap:wrap;padding:14px var(--teacher-card-inset);border-bottom:1px solid #e0e6ef}
body.teacher-workspace .rv-register-head h2 {margin:0;color:#24334c;font-size:var(--teacher-section-title)}
body.teacher-workspace .rv-register-head p,body.teacher-workspace .rv-register-head small {margin:3px 0 0;color:var(--muted);font-size:13px}
body.teacher-workspace .rv-register-head>span {color:var(--muted);font-size:13px}
body.teacher-workspace .rv-register .rv-register-filter {display:flex;gap:8px 14px;flex-wrap:wrap;padding:12px var(--teacher-card-inset);border:0;border-bottom:1px solid #e0e6ef;background:#fff}
body.teacher-workspace .rv-register-filter .fb-left {display:flex;align-items:center;flex-wrap:wrap;gap:8px;min-width:0}
body.teacher-workspace .rv-register-filter .seg {margin:0}
body.teacher-workspace .rv-register-filter .fb-meta {font-size:13px;color:var(--muted)}
body.teacher-workspace .rv-register .rv-register-summary {display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px 18px;margin:0;padding:12px var(--teacher-card-inset);border:0;border-radius:0;background:#f4f7fb;color:#32435a}
body.teacher-workspace .rv-register .rv-register-actions {display:flex;align-items:center;gap:7px;flex-wrap:wrap;min-width:0}
body.teacher-workspace .rv-register .rv-register-actions .btn {min-height:33px;border-radius:6px;font-size:13px}
body.teacher-workspace .rv-register .rv-register-table .tbl-wrap {border:0;border-radius:0;overscroll-behavior-x:contain}
body.teacher-workspace .rv-register .tbl {border-collapse:collapse}
body.teacher-workspace .rv-register .tbl thead th {border-block:1px solid #dde5ef;background:#f7f9fc;color:#55667e;font-weight:600;font-size:13px}
body.teacher-workspace .rv-register .tbl td {padding-block:10px;border-bottom:1px solid #e5ebf2}
body.teacher-workspace .rv-register .tbl .att-pills {gap:4px}
body.teacher-workspace .rv-register .tbl .att-pills button {padding:4px 7px;font-size:12px;line-height:1.4}
body.teacher-workspace .rv-register .tbl .att-pills button.on-bad {color:#254b88;border-color:#a8bfe3;background:#eaf1fc}
body.teacher-workspace .rv-register .rv-row-ops {display:flex;align-items:center;gap:8px}
body.teacher-workspace .rv-register .rv-row-ops>span {color:var(--muted);font-size:13px}
body.teacher-workspace .rv-register-table .pager {padding:10px var(--teacher-card-inset)}
@media (max-width:720px) {
  body.teacher-workspace .rv-register .rv-register-filter,body.teacher-workspace .rv-register-head,body.teacher-workspace .rv-register .rv-register-summary {padding:11px 12px}
  body.teacher-workspace .rv-register-filter .fb-left {width:100%;align-items:stretch}
  body.teacher-workspace .rv-register-filter .fb-left .teacher-class-picker {max-width:100%;min-width:0}
  body.teacher-workspace .rv-register-filter .seg {max-width:100%;flex-wrap:wrap}
  body.teacher-workspace .rv-register .tbl {width:100%;min-width:0;display:block}
  body.teacher-workspace .rv-register .rv-register-table :is(tbody,.tbl-wrap) {display:block;overflow:visible}
  body.teacher-workspace .rv-register-table thead {position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
  body.teacher-workspace .rv-register .tbl tr:has(td[colspan]),body.teacher-workspace .rv-register .tbl td[colspan] {display:block}
  body.teacher-workspace .rv-register .tbl tr:has(td[data-label]) {display:grid;grid-template-columns:minmax(0,1.1fr) minmax(0,1fr);padding:12px;gap:9px 12px;border-top:1px solid #dfe6ef}
  body.teacher-workspace .rv-register .tbl tr:has(td[data-label])>td {display:block;min-width:0;padding:0;border:0;white-space:normal;overflow-wrap:anywhere}
  body.teacher-workspace .rv-register .tbl tr:has(td[data-label])>td:nth-child(2) {justify-self:end;text-align:right;font-size:13px;color:#56677e}
  body.teacher-workspace .rv-register .tbl tr:has(td[data-label])>td:nth-child(5),body.teacher-workspace .rv-register .tbl tr:has(td[data-label])>td:nth-child(6) {grid-column:1/-1}
  body.teacher-workspace .rv-register .tbl td[data-label]:nth-child(n+3)::before {content:attr(data-label);display:block;margin-bottom:4px;font-size:12px;font-weight:550;color:#53647b}
  body.teacher-workspace .rv-register .pager,.rv-register .pager-btns {gap:6px;flex-wrap:wrap}
}
