:root {
  --canvas: #eceeea;
  --paper: #fffef9;
  --paper-soft: #f7f7f2;
  --ink: #171816;
  --muted: #686b65;
  --line: #d4d7cf;
  --line-strong: #aeb3aa;
  --blue: #245d78;
  --blue-soft: #eaf2f5;
  --green: #17633b;
  --green-soft: #eaf4ed;
  --amber: #8a5b00;
  --amber-soft: #fff5dc;
  --red: #982c2c;
  --red-soft: #faecea;
  --violet: #684d7c;
  --radius: 8px;
  --topbar-height: 72px;
  color: var(--ink);
  font-family: "Segoe UI", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  font-synthesis: none;
  letter-spacing: 0;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { width: 100%; height: 100%; }
html { overflow: hidden; overscroll-behavior: none; }
body { position: fixed; inset: 0; margin: 0; overflow: hidden; overscroll-behavior: none; background: var(--canvas); }
button, input, textarea, select { font: inherit; letter-spacing: 0; }
button, a { -webkit-tap-highlight-color: transparent; }
button { color: inherit; }
button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible,
.viewer:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}

.topbar {
  height: var(--topbar-height);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 20px;
  min-width: 0;
  padding: 10px 20px;
  border-bottom: 1px solid var(--line);
  background: var(--paper);
}
.identity { min-width: 0; overflow: hidden; }
.product { display: block; color: var(--blue); font-size: 12px; font-weight: 700; }
.identity h1 {
  width: 100%;
  margin: 3px 0 0;
  overflow: hidden;
  color: var(--ink);
  font-family: Georgia, "Songti SC", serif;
  font-size: 19px;
  font-weight: 600;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.topbar-actions { display: flex; align-items: center; gap: 18px; }
.report-link {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  padding: 7px 11px;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  color: var(--blue);
  background: var(--paper);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}
.report-link:hover { border-color: var(--blue); background: var(--blue-soft); }
.progress-wrap { width: 164px; flex: 0 0 auto; }
.progress-copy { display: flex; justify-content: space-between; align-items: baseline; color: var(--muted); font-size: 12px; }
.progress-copy strong { color: var(--ink); font-size: 14px; font-variant-numeric: tabular-nums; }
.progress-track { height: 4px; margin-top: 7px; overflow: hidden; border-radius: 2px; background: var(--line); }
.progress-track span { display: block; width: 0; height: 100%; background: var(--green); }

.mobile-pane-switch { display: none; }
.workspace {
  width: 100%;
  max-width: 100vw;
  height: calc(100vh - var(--topbar-height));
  height: calc(100dvh - var(--topbar-height));
  display: grid;
  grid-template-columns: minmax(520px, 1.52fr) minmax(400px, 1fr);
  overflow: hidden;
}
.paper-pane, .review-pane { min-width: 0; min-height: 0; overflow: hidden; }
.paper-pane {
  display: grid;
  grid-template-rows: 52px minmax(0, 1fr);
  border-right: 1px solid var(--line-strong);
  background: #e4e7e3;
}
.viewer-toolbar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(8px, 2vw, 22px);
  min-width: 0;
  padding: 7px 12px;
  overflow-x: auto;
  overflow-y: hidden;
  border-bottom: 1px solid var(--line);
  background: var(--paper-soft);
  scrollbar-width: thin;
}
.tool-group { flex: 0 0 auto; display: flex; align-items: center; gap: 7px; }
.icon-button {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid transparent;
  border-radius: 6px;
  background: transparent;
  cursor: pointer;
  font-size: 18px;
}
.icon-button:hover { border-color: var(--line); background: var(--paper); }
.icon-button:disabled { opacity: .35; cursor: default; }
.page-input { display: flex; align-items: center; gap: 4px; color: var(--muted); font-size: 13px; }
.page-input input {
  width: 50px;
  height: 34px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 5px;
  color: var(--ink);
  background: var(--paper);
  text-align: center;
}
.zoom-controls span { width: 48px; color: var(--muted); font-size: 12px; text-align: center; }
.anchor-status {
  max-width: 230px;
  flex: 0 1 auto;
  overflow: hidden;
  color: var(--amber);
  font-size: 12px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.viewer { min-height: 0; overflow: auto; overscroll-behavior: contain; padding: 24px; outline: none; }
.viewer:focus-visible { outline-offset: -3px; }
.page-stage {
  position: relative;
  width: fit-content;
  min-width: 200px;
  min-height: 260px;
  margin: 0 auto;
  background: white;
  box-shadow: 0 2px 14px rgba(23, 24, 22, .16);
}
.page-stage[aria-busy="true"]::after {
  content: "正在载入页面";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--muted);
  background: rgba(255, 255, 255, .76);
  font-size: 13px;
  pointer-events: none;
}
#pdf-canvas { display: block; }
.text-layer, .anchor-layer { position: absolute; inset: 0; overflow: hidden; }
.text-layer { line-height: 1; }
.text-layer span, .text-layer br {
  position: absolute;
  color: transparent;
  white-space: pre;
  cursor: text;
  transform-origin: 0 0;
}
.text-layer ::selection { background: rgba(36, 93, 120, .28); }
.anchor-layer { pointer-events: none; }
.anchor-marker {
  position: absolute;
  min-height: 4px;
  border-left: 4px solid var(--amber);
  background: rgba(210, 163, 43, .19);
}

.review-pane { display: flex; flex-direction: column; background: var(--paper); }
.review-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 16px 20px 12px;
}
.kicker { display: block; color: var(--blue); font-size: 12px; font-weight: 750; }
.review-heading h2 { margin: 3px 0 0; font-family: Georgia, "Songti SC", serif; font-size: 20px; line-height: 1.2; }
.task-nav { display: flex; align-items: center; gap: 4px; white-space: nowrap; }
.task-position {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-width: 112px;
  min-height: 36px;
  color: var(--muted);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.task-position-prefix { flex: 0 0 auto; }
.task-jump-input {
  box-sizing: border-box;
  width: 42px;
  height: 30px;
  padding: 0 4px;
  border: 1px solid var(--line);
  border-radius: 4px;
  color: var(--ink);
  background: white;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  text-align: center;
}
.task-jump-input:focus { border-color: var(--blue); outline: 2px solid rgba(36, 93, 120, .18); outline-offset: 1px; }
.task-jump-input:disabled { color: var(--muted); background: var(--soft); cursor: not-allowed; }
.task-jump-input::-webkit-inner-spin-button,
.task-jump-input::-webkit-outer-spin-button { margin: 0; appearance: none; }
.task-total { flex: 0 0 34px; text-align: left; }
.command-button, .text-button {
  border: 0;
  background: transparent;
  color: var(--blue);
  font-weight: 700;
  cursor: pointer;
}
.command-button { min-height: 36px; padding: 5px 2px; white-space: nowrap; }
.task-actions { display: flex; align-items: center; justify-content: flex-end; gap: 10px; white-space: nowrap; }
.command-button:hover, .text-button:hover { text-decoration: underline; }
.round-tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 0 20px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  overflow: hidden;
}
.round-tab {
  min-width: 0;
  min-height: 50px;
  padding: 7px 8px;
  border: 0;
  border-right: 1px solid var(--line);
  border-top: 3px solid transparent;
  color: var(--muted);
  background: var(--paper-soft);
  cursor: pointer;
  font-size: 12px;
  font-weight: 650;
  line-height: 1.35;
}
.round-tab:last-child { border-right: 0; }
.round-tab:hover { color: var(--ink); background: #f0f2ed; }
.round-tab.is-active,
.round-tab[aria-pressed="true"] {
  border-top-color: var(--blue);
  color: var(--ink);
  background: var(--blue-soft);
  box-shadow: inset 0 -2px 0 var(--blue);
}
.logic-map {
  flex: 0 0 auto;
  margin: 0 20px 10px;
  padding: 12px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f6f8f5;
}
.logic-map-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.logic-map-heading h3 { margin: 2px 0 0; font-family: Georgia, "Songti SC", serif; font-size: 15px; line-height: 1.35; }
.logic-chain {
  display: flex;
  align-items: stretch;
  gap: 7px;
  margin-top: 10px;
  padding: 1px 2px 8px;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: thin;
}
.logic-node {
  width: 176px;
  min-width: 176px;
  min-height: 104px;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 6px;
  padding: 9px 10px;
  border: 1px solid var(--line-strong);
  border-top: 3px solid var(--blue);
  border-radius: 5px;
  color: var(--ink);
  background: var(--paper);
  cursor: pointer;
  text-align: left;
}
.logic-node:hover { border-color: var(--blue); background: var(--blue-soft); }
.logic-node:disabled { cursor: default; opacity: .72; }
.logic-node.strength-strong { border-top-color: var(--line-strong); }
.logic-node.strength-medium { border-top-color: var(--line-strong); }
.logic-node.strength-weak { border-top-color: var(--line-strong); }
.logic-node.strength-none, .logic-node.strength-unresolved { border-top-color: var(--line-strong); }
.logic-node-stage { color: var(--blue); font-size: 11px; font-weight: 750; }
.logic-node-statement { overflow: hidden; font-size: 12px; line-height: 1.45; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; }
.logic-node-strength { color: var(--muted); font-size: 10px; }
.logic-connector { width: 112px; min-width: 112px; align-self: center; display: grid; gap: 2px; color: var(--muted); text-align: center; }
.logic-relation { font-size: 10px; line-height: 1.35; }
.logic-arrow { color: var(--line-strong); font-size: 18px; line-height: 1; }
.logic-dimensions { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 3px; }
.logic-dimension-badge { padding: 3px 6px; border: 1px solid var(--line); border-radius: 4px; color: var(--muted); background: var(--paper); font-size: 10px; }
.logic-gaps { max-height: 72px; margin-top: 7px; overflow: auto; }
.logic-gaps:empty { display: none; }
.logic-gaps p { margin: 3px 0 0; color: var(--muted); font-size: 10px; line-height: 1.4; }

.task-meta-row {
  min-height: 36px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 7px 20px 0;
}
.sort-control { display: inline-flex; align-items: center; gap: 7px; color: var(--muted); font-size: 11px; }
.sort-control select {
  min-height: 30px;
  padding: 3px 26px 3px 8px;
  border: 1px solid var(--line);
  border-radius: 5px;
  color: var(--ink);
  background: var(--paper);
  font: inherit;
  font-size: 12px;
}
.save-status { min-height: 0; padding: 0; color: var(--muted); font-size: 11px; text-align: right; }
.save-status.is-saving, .card-save-status.is-saving { color: var(--amber); }
.save-status.is-error, .card-save-status.is-error { color: var(--red); }
.finding-list { flex: 1 1 0; min-height: 0; overflow: auto; overscroll-behavior: contain; padding: 0 20px 28px; }
.finding-group { margin: 0; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); }
.quote-source { border-bottom: 1px solid var(--line); background: var(--paper-soft); }
.quote-source-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 11px 16px 7px; }
.quote-label { color: var(--blue); font-size: 11px; font-weight: 750; }
.quote-jump {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 5px 14px;
  padding: 4px 16px 14px;
  border: 0;
  color: var(--ink);
  background: transparent;
  text-align: left;
  cursor: pointer;
}
.quote-jump:hover { background: #f0f2ed; }
.quote-jump blockquote { grid-column: 1 / -1; margin: 0; font-family: Georgia, "Songti SC", serif; font-size: 14px; line-height: 1.62; }
.quote-action { grid-column: 2; grid-row: 1; color: var(--blue); font-size: 11px; font-weight: 700; white-space: nowrap; }
.finding-item { padding: 0; }
.bibliography-audit { border-left: 0; background: transparent; }
.bibliography-audit h3, .citation-audit h3 { margin: 0; font-family: Georgia, "Songti SC", serif; font-size: 16px; line-height: 1.35; }
.bibliography-identity { margin: 9px 0 0; font-size: 13px; line-height: 1.5; }
.bibliography-fields { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; margin-top: 12px; }
.bibliography-field { min-width: 0; display: flex; align-items: center; justify-content: space-between; gap: 6px; padding: 7px 8px; border: 1px solid var(--line); border-radius: 4px; background: var(--paper); }
.bibliography-field span { color: var(--muted); font-size: 10px; }
.bibliography-field strong { font-size: 11px; }
.bibliography-field.state-match strong, .support-dimension.state-match strong { color: var(--ink); }
.bibliography-field.state-mismatch strong, .support-dimension.state-mismatch strong { color: var(--ink); }
.bibliography-field.state-unresolved strong, .support-dimension.state-unresolved strong { color: var(--ink); }
.round-a-layout .evidence-entry { border-left-color: var(--line-strong); background: var(--paper); }

.citation-audit { border-left: 0; background: transparent; }
.citation-comparison { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, .65fr); gap: 8px; margin-top: 12px; }
.citation-side { min-width: 0; padding: 10px 11px; border: 1px solid var(--line); border-radius: 5px; background: var(--paper); }
.citation-side > span { color: var(--muted); font-size: 10px; font-weight: 750; }
.citation-side p { margin: 5px 0 0; font-size: 12px; line-height: 1.52; }
.support-dimensions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; margin-top: 10px; }
.support-dimension { display: flex; align-items: center; justify-content: space-between; gap: 6px; padding: 7px 8px; border-bottom: 2px solid var(--line); background: rgba(255, 254, 249, .75); }
.support-dimension span { color: var(--muted); font-size: 10px; }
.support-dimension strong { font-size: 11px; }
.support-dimension.state-match { border-bottom-color: var(--line); }
.support-dimension.state-mismatch { border-bottom-color: var(--line); }
.support-dimension.state-unresolved { border-bottom-color: var(--line); }
.round-b-layout .evidence-entry { border-left-color: var(--line-strong); background: var(--paper); }

.logic-diagnosis { background: transparent; }
.logic-diagnosis-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.logic-diagnosis-heading h3 { margin: 0; font-family: Georgia, "Songti SC", serif; font-size: 16px; line-height: 1.35; }
.logic-diagnosis-heading p { margin: 4px 0 0; color: var(--muted); font-size: 11px; }
.logic-strength { flex: 0 0 auto; padding: 4px 7px; border: 1px solid var(--line); border-radius: 4px; background: var(--paper); font-size: 11px; }
.logic-strength.strength-strong { color: var(--ink); border-color: var(--line); }
.logic-strength.strength-medium { color: var(--ink); border-color: var(--line); }
.logic-strength.strength-weak { color: var(--ink); border-color: var(--line); }
.logic-strength.strength-none, .logic-strength.strength-unresolved { color: var(--ink); border-color: var(--line); }
.logic-link-flow { display: grid; grid-template-columns: minmax(0, 1fr) 20px minmax(0, .72fr) 20px minmax(0, 1fr); align-items: stretch; gap: 5px; margin-top: 12px; }
.logic-link-node { min-width: 0; padding: 9px 10px; border: 1px solid var(--line); border-radius: 5px; background: var(--paper); }
.logic-link-node > span { color: var(--blue); font-size: 10px; font-weight: 750; }
.logic-link-node p { margin: 5px 0 0; font-size: 12px; line-height: 1.5; }
.logic-link-arrow { align-self: center; color: var(--line-strong); text-align: center; }
.logic-diagnostics { display: grid; gap: 0; margin-top: 12px; border-top: 1px solid var(--line); }
.logic-diagnostic-row { display: grid; grid-template-columns: 116px minmax(0, 1fr); gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.logic-diagnostic-row strong { color: var(--muted); font-size: 11px; line-height: 1.5; }
.logic-diagnostic-row p { margin: 0; font-size: 12px; line-height: 1.5; }
.logic-diagnostic-row.is-risk p { color: var(--ink); }
.logic-diagnostic-row.is-clear p { color: var(--ink); }

.review-section { padding: 16px; border-top: 1px solid var(--line); }
.section-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.section-heading h3 { margin: 0; font-family: Georgia, "Songti SC", serif; font-size: 16px; line-height: 1.3; }
.section-heading p { margin: 4px 0 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.evidence-section { background: var(--paper); }
.evidence-list { display: grid; gap: 9px; margin-top: 12px; }
.evidence-entry { padding: 11px 12px; border-left: 3px solid var(--line-strong); background: var(--paper); }
.evidence-entry h4 { margin: 0 0 6px; font-size: 13px; line-height: 1.4; }
.evidence-meta { display: flex; flex-wrap: wrap; gap: 4px 14px; color: var(--muted); font-size: 11px; line-height: 1.45; }
.evidence-entry blockquote { margin: 8px 0 0; padding-left: 10px; border-left: 1px solid var(--line-strong); font-family: Georgia, "Songti SC", serif; font-size: 13px; line-height: 1.55; }
.evidence-note { margin: 8px 0 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.evidence-empty { margin: 10px 0 0; color: var(--muted); font-size: 12px; }
.supplemental-evidence { margin-top: 16px; padding-top: 14px; border-top: 1px dashed var(--line); }
.supplemental-evidence-label { display: grid; gap: 7px; color: var(--muted); font-size: 11px; }
.supplemental-evidence-text, .rationale-label textarea {
  width: 100%;
  min-width: 0;
  padding: 8px 9px;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  color: var(--ink);
  background: var(--paper);
  font-size: 13px;
  line-height: 1.45;
}
.supplemental-evidence-text { min-height: 104px; resize: vertical; }
.primary-button, .secondary-button {
  min-height: 38px;
  padding: 7px 12px;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 750;
}
.primary-button { border: 1px solid var(--ink); color: white; background: var(--ink); }
.primary-button:hover { background: #30322f; }
.secondary-button { border: 1px solid var(--line-strong); color: var(--blue); background: var(--paper); }
.secondary-button:hover { border-color: var(--blue); background: var(--blue-soft); }
.machine-block { border-left: 3px solid var(--line-strong); background: var(--paper-soft); }
.machine-verdict { flex: 0 0 auto; padding: 4px 8px; border: 1px solid var(--line); border-radius: 5px; color: var(--ink); background: var(--paper); font-size: 12px; }
.machine-rationale { margin: 12px 0 0; font-size: 13px; line-height: 1.58; }
.suggestion { margin: 9px 0 0; color: var(--ink); font-size: 13px; line-height: 1.5; }
.mentor-block { border-left: 3px solid var(--line-strong); background: var(--paper); }
.machine-summary {
  margin: 14px 0 0;
  padding: 11px 12px;
  border-left: 3px solid var(--line-strong);
  border-radius: 5px;
  background: var(--paper-soft);
}
.machine-summary .machine-verdict {
  display: inline-flex;
  padding: 4px 8px;
  border: 1px solid var(--line);
  border-radius: 5px;
  color: var(--ink);
  background: var(--paper);
  font-size: 12px;
}
.machine-summary .machine-rationale { margin: 9px 0 0; font-size: 13px; line-height: 1.58; }
.machine-summary .suggestion { margin: 9px 0 0; color: var(--ink); font-size: 13px; line-height: 1.5; }
.ai-audit { margin: 10px 0 0; }
.ai-audit summary { cursor: pointer; color: var(--blue); font-size: 12px; font-weight: 700; }
.ai-audit-body { margin-top: 8px; }
.final-verdicts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 7px; margin: 14px 0 0; padding: 0; border: 0; }
.final-verdicts legend { grid-column: 1 / -1; margin-bottom: 7px; color: var(--muted); font-size: 11px; }
.final-verdicts label { position: relative; min-width: 0; }
.final-verdicts input {
  position: absolute;
  top: 0;
  left: 0;
  width: 1px;
  height: 1px;
  margin: 0;
  opacity: 0;
  pointer-events: none;
}
.final-verdicts input:focus-visible + span { outline: 2px solid var(--blue); outline-offset: 2px; }
.final-verdicts span {
  min-height: 38px;
  display: grid;
  place-items: center;
  padding: 6px;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  background: var(--paper);
  cursor: pointer;
  font-size: 12px;
  text-align: center;
}
.final-verdicts input:checked + span { border-color: var(--ink); color: white; background: var(--ink); }
.rationale-label { display: grid; gap: 6px; margin-top: 12px; }
.rationale-title { color: var(--muted); font-size: 11px; }
.rationale-label textarea { min-height: 82px; resize: vertical; background: var(--paper); }
.validation-error { margin: 8px 0 0; padding: 8px 10px; color: var(--red); background: var(--red-soft); font-size: 12px; line-height: 1.45; }
.decision-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 14px; padding-top: 13px; border-top: 1px solid var(--line); }
.card-save-wrap { min-width: 0; display: flex; align-items: center; gap: 7px; }
.card-save-status { color: var(--muted); font-size: 11px; }
.retry-save { min-height: 34px; padding: 4px; color: var(--red); }
.confirm-next { flex: 0 0 auto; }
.empty-state { margin: 28px 20px; color: var(--muted); text-align: center; }
.empty-state strong { display: block; margin-bottom: 10px; color: var(--ink); font-size: 14px; }
.load-error { margin: 24px 0; padding: 12px; color: var(--red); background: var(--red-soft); line-height: 1.5; }

@media (max-width: 980px) and (min-width: 721px) {
  .workspace { grid-template-columns: minmax(430px, 1.15fr) minmax(360px, 1fr); }
  .review-heading { grid-template-columns: minmax(0, 1fr) auto; }
  .review-heading > .task-actions { grid-column: 1 / -1; justify-self: end; }
}

@media (max-width: 720px) {
  :root { --topbar-height: 92px; --mobile-switch-height: 52px; }
  body { overflow: hidden; }
  .topbar { gap: 8px; padding: 9px 12px; }
  .identity h1 {
    display: -webkit-box;
    overflow: hidden;
    white-space: normal;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    font-size: 15px;
    line-height: 1.3;
  }
  .topbar-actions { gap: 8px; }
  .report-link { min-height: 44px; padding: 8px; font-size: 12px; }
  .progress-wrap { width: 74px; }
  .progress-copy span { display: none; }
  .mobile-pane-switch {
    height: var(--mobile-switch-height);
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4px;
    padding: 4px 12px;
    border-bottom: 1px solid var(--line);
    background: var(--paper-soft);
  }
  .pane-switch-button {
    min-width: 0;
    min-height: 44px;
    padding: 7px 12px;
    border: 1px solid transparent;
    border-radius: 6px;
    color: var(--muted);
    background: transparent;
    cursor: pointer;
    font-size: 13px;
    font-weight: 700;
  }
  .pane-switch-button[aria-pressed="true"] { border-color: var(--ink); color: white; background: var(--ink); }
  .workspace {
    height: calc(100vh - var(--topbar-height) - var(--mobile-switch-height));
    height: calc(100dvh - var(--topbar-height) - var(--mobile-switch-height));
    display: block;
    min-height: 0;
  }
  .paper-pane, .review-pane { display: none; width: 100%; height: 100%; min-height: 0; }
  body.mobile-paper .paper-pane { display: grid; grid-template-rows: 56px minmax(0, 1fr); }
  body.mobile-review .review-pane { display: flex; flex-direction: column; }
  .paper-pane { overflow: hidden; border: 0; }
  .viewer-toolbar { width: 100%; max-width: 100vw; justify-content: flex-start; gap: 6px; padding: 6px 8px; }
  .icon-button { width: 44px; height: 44px; }
  .page-input input { width: 48px; height: 44px; }
  .anchor-status { max-width: 180px; }
  .viewer { width: 100%; max-width: 100vw; padding: 14px; }
  .review-heading { grid-template-columns: minmax(0, 1fr) auto; gap: 8px; padding: 13px 14px 9px; }
  .review-heading h2 { font-size: 18px; }
  .review-heading > .task-actions { grid-column: 1 / -1; justify-content: space-between; min-height: 44px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 6px; }
  .task-position { min-width: 108px; }
  .round-tabs { margin: 0 14px 8px; }
  .round-tab { min-height: 52px; padding: 6px 5px; font-size: 11px; }
  .logic-map { margin: 0 14px 8px; padding: 10px; }
  .bibliography-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .citation-comparison, .support-dimensions { grid-template-columns: 1fr; }
  .logic-node { width: 164px; min-width: 164px; min-height: 96px; }
  .logic-link-flow { grid-template-columns: 1fr; }
  .logic-link-arrow { transform: rotate(90deg); }
  .logic-diagnostic-row { grid-template-columns: 1fr; gap: 3px; }
  .save-status { min-height: 30px; padding: 7px 14px 0; }
  .finding-list { padding: 0 14px 24px; }
  .quote-jump { min-height: 44px; padding: 13px 14px; }
  .review-section { padding: 14px; }
  .secondary-button, .primary-button, .text-button { min-height: 44px; }
  .supplemental-evidence-text { min-height: 112px; }
  .final-verdicts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .final-verdicts span { min-height: 44px; }
  .decision-footer { align-items: stretch; flex-direction: column; }
  .card-save-wrap { min-height: 44px; justify-content: space-between; }
  .confirm-next { width: 100%; min-height: 48px; }
}

@media (max-width: 420px) {
  :root { --topbar-height: 96px; }
  .product { font-size: 11px; }
  .identity h1 { font-size: 14px; }
  .report-link { padding-inline: 7px; }
  .progress-wrap { width: 66px; }
  .round-tab { font-size: 10px; }
  .quote-jump { grid-template-columns: 1fr; }
  .quote-action { grid-column: 1; grid-row: auto; }
  .section-heading { align-items: stretch; flex-direction: column; }
  .machine-verdict { align-self: flex-start; }
}


/* Round-specific content uses the same quiet visual language in every round. */
.round-a-layout .evidence-section,
.round-b-layout .evidence-section,
.round-c-layout .evidence-section { border-left: 0; }
/* Keep review cards to: original text → strongest AI evidence → human decision. */
.more-evidence { margin-top: 10px; }
.more-evidence summary { cursor: pointer; color: var(--blue); font-size: 12px; font-weight: 700; }
.more-evidence-list { display: grid; gap: 10px; margin-top: 10px; }
.more-evidence-list .evidence-entry { border-top: 1px solid var(--line); padding-top: 10px; }

/* The source text is directly selectable; no copy control is needed. */
.quote-source blockquote { user-select: text; cursor: text; }
.quote-source-header { justify-content: flex-start; }


