/* =========================================================
   稿件预审 · 中文编辑工具风格
   纸感底色 + 深墨色 + 青绿强调
   ========================================================= */

:root {
  --paper: #f7f3ec;
  --paper-2: #fffdf9;
  --paper-3: #efe9dd;
  --paper-4: #e7e0d2;
  --ink: #20262b;
  --ink-2: #4a5259;
  --ink-3: #737b83;
  --line: #ddd4c5;
  --line-strong: #c8bba6;
  --accent: #0e7168;
  --accent-deep: #085c55;
  --accent-soft: #e2f1ee;
  --accent-line: #b8d9d4;
  --danger: #b42318;
  --danger-deep: #8f1b12;
  --danger-soft: #fbeceb;
  --danger-line: #efc7c3;
  --warn: #a85a07;
  --warn-soft: #fdf2e2;
  --warn-line: #ecd3aa;
  --ok: #177a4c;
  --ok-soft: #e6f3ec;
  --ok-line: #bfddcb;
  --muted: #6b7076;
  --muted-soft: #eef0f1;
  --blue: #476b8b;
  --blue-soft: #eaf0f6;
  --blue-line: #c4d5e4;
  --shadow-sm: 0 1px 2px rgba(32, 38, 43, 0.06);
  --shadow-md: 0 1px 2px rgba(32, 38, 43, 0.05), 0 10px 28px rgba(32, 38, 43, 0.07);
  --radius: 10px;
  --radius-lg: 14px;
  --serif: "Songti SC", "STSong", "SimSun", "Noto Serif SC", "Source Han Serif SC", Georgia, serif;
  --sans: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", "Source Han Sans SC", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "Cascadia Mono", "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.65;
  background-color: var(--paper);
  background-image:
    radial-gradient(circle at 16% 8%, rgba(255, 255, 255, 0.6), transparent 42%),
    radial-gradient(circle at 88% 92%, rgba(203, 192, 172, 0.16), transparent 55%),
    repeating-linear-gradient(0deg, rgba(120, 105, 80, 0.022) 0 1px, transparent 1px 4px);
}

[hidden] {
  display: none !important;
}

h1,
h2,
h3,
h4 {
  margin: 0;
  font-family: var(--serif);
  font-weight: 700;
  letter-spacing: 0.01em;
  color: var(--ink);
}

h1 {
  font-size: 30px;
  line-height: 1.28;
}

h2 {
  font-size: 21px;
  line-height: 1.35;
}

h3 {
  font-size: 16px;
  line-height: 1.45;
}

p {
  margin: 0;
}

a {
  color: var(--accent-deep);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

button,
input,
textarea,
select {
  font: inherit;
  color: inherit;
}

code {
  font-family: var(--mono);
  font-size: 0.88em;
  padding: 0.1em 0.35em;
  border-radius: 4px;
  background: rgba(32, 38, 43, 0.06);
  overflow-wrap: anywhere;
}

pre {
  margin: 0;
  font-family: var(--mono);
  font-size: 12.5px;
  line-height: 1.6;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

::selection {
  background: rgba(14, 113, 104, 0.2);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.skip-link {
  position: absolute;
  left: 12px;
  top: -48px;
  z-index: 100;
  padding: 8px 14px;
  border-radius: 0 0 8px 8px;
  background: var(--ink);
  color: var(--paper-2);
  text-decoration: none;
  transition: top 0.15s ease;
}

.skip-link:focus {
  top: 0;
}

.sr-only {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.muted {
  color: var(--ink-3);
}

.small {
  font-size: 12.5px;
}

.req {
  color: var(--danger);
}

.optional {
  color: var(--ink-3);
  font-weight: 400;
  font-size: 12.5px;
}

/* =========================== 布局 =========================== */

.app {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  min-height: 100vh;
}

.sidebar {
  position: sticky;
  top: 0;
  display: flex;
  flex-direction: column;
  height: 100vh;
  padding: 22px 16px 16px;
  border-right: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(255, 253, 249, 0.92), rgba(244, 239, 230, 0.94)),
    var(--paper);
  box-shadow: inset -1px 0 0 rgba(255, 255, 255, 0.55);
  overflow: hidden;
}

.main {
  min-width: 0;
  padding: 34px 46px 90px;
}

.main:focus {
  outline: none;
}

/* =========================== 品牌 =========================== */

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 2px 6px 18px;
}

.brand-mark {
  display: inline-flex;
  color: var(--accent);
  flex: none;
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.3;
}

.brand-text strong {
  font-family: var(--serif);
  font-size: 19px;
  letter-spacing: 0.08em;
}

.brand-text small {
  margin-top: 2px;
  color: var(--ink-3);
  font-size: 11.5px;
  letter-spacing: 0.12em;
}

/* =========================== 按钮 =========================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 36px;
  padding: 7px 14px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  color: var(--ink);
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.4;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
  user-select: none;
}

.btn:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.btn-primary {
  background: var(--accent);
  border-color: var(--accent-deep);
  color: #f7fffd;
  box-shadow: 0 1px 2px rgba(8, 92, 85, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.14);
}

.btn-primary:hover:not(:disabled) {
  background: var(--accent-deep);
}

.btn-primary:active:not(:disabled) {
  transform: translateY(1px);
}

.btn-ghost {
  border-color: var(--line-strong);
  background: rgba(255, 253, 249, 0.7);
  color: var(--ink-2);
}

.btn-ghost:hover:not(:disabled) {
  background: var(--paper-3);
  color: var(--ink);
}

.btn-danger-ghost {
  border-color: var(--danger-line);
  background: rgba(255, 253, 249, 0.7);
  color: var(--danger);
}

.btn-danger-ghost:hover:not(:disabled) {
  background: var(--danger-soft);
}

.btn-sm {
  min-height: 31px;
  padding: 5px 10px;
  font-size: 12.5px;
}

.btn-lg {
  min-height: 44px;
  padding: 10px 22px;
  font-size: 14.5px;
}

.btn-new {
  width: 100%;
  min-height: 42px;
  margin-bottom: 20px;
  font-size: 14px;
  letter-spacing: 0.04em;
}

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  padding: 0;
  border: 1px solid transparent;
  border-radius: 6px;
  background: transparent;
  color: var(--ink-3);
  cursor: pointer;
}

.icon-btn:hover {
  border-color: var(--line);
  background: var(--paper-3);
  color: var(--ink);
}

/* =========================== 历史 =========================== */

.history {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  margin-top: 2px;
}

.history-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 6px 8px;
  color: var(--ink-3);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.14em;
}

.history-list {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 2px;
  scrollbar-width: thin;
}

.history-item {
  position: relative;
  display: flex;
  align-items: stretch;
  margin-bottom: 4px;
  border: 1px solid transparent;
  border-radius: 8px;
  transition: background 0.14s ease, border-color 0.14s ease;
}

.history-item:hover {
  border-color: var(--line);
  background: rgba(255, 253, 249, 0.8);
}

.history-item.is-current {
  border-color: var(--accent-line);
  background: var(--accent-soft);
}

.history-open {
  flex: 1;
  min-width: 0;
  padding: 8px 34px 8px 10px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.history-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.history-id {
  overflow: hidden;
  font-family: var(--serif);
  font-size: 13.5px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.history-sub,
.history-meta {
  display: block;
  margin-top: 2px;
  overflow: hidden;
  color: var(--ink-3);
  font-size: 11.5px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.history-meta {
  color: var(--ink-2);
}

.history-progress {
  display: block;
  height: 3px;
  margin-top: 5px;
  border-radius: 999px;
  background: var(--paper-4);
  overflow: hidden;
}

.history-progress-fill {
  display: block;
  width: 36%;
  height: 100%;
  border-radius: 999px;
  background: var(--accent);
  animation: history-progress 1.5s ease-in-out infinite;
}

@keyframes history-progress {
  0% {
    transform: translateX(-110%);
  }
  100% {
    transform: translateX(310%);
  }
}

.history-delete {
  position: absolute;
  top: 6px;
  right: 5px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  padding: 0;
  border: 1px solid transparent;
  border-radius: 6px;
  background: transparent;
  color: var(--ink-3);
  font-size: 15px;
  line-height: 1;
  opacity: 0;
  cursor: pointer;
  transition: opacity 0.14s ease, color 0.14s ease, background 0.14s ease;
}

.history-item:hover .history-delete,
.history-item:focus-within .history-delete {
  opacity: 1;
}

@media (hover: none) {
  .history-delete {
    opacity: 1;
  }
}

.history-delete:hover {
  border-color: var(--danger-line);
  background: var(--danger-soft);
  color: var(--danger);
}

.history-empty,
.history-error {
  padding: 10px;
  margin: 0;
  color: var(--ink-3);
  font-size: 12.5px;
  line-height: 1.6;
}

.history-error {
  color: var(--danger);
}

/* 状态胶囊 */
.status-pill {
  display: inline-flex;
  align-items: center;
  flex: none;
  gap: 4px;
  padding: 1px 7px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 600;
  line-height: 1.7;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.pill-done {
  border-color: var(--ok-line);
  background: var(--ok-soft);
  color: var(--ok);
}

.pill-running {
  border-color: var(--accent-line);
  background: var(--accent-soft);
  color: var(--accent-deep);
}

.pill-queued {
  border-color: var(--line-strong);
  background: var(--paper-3);
  color: var(--ink-2);
}

.pill-failed {
  border-color: var(--danger-line);
  background: var(--danger-soft);
  color: var(--danger);
}

.pill-cancelled,
.pill-interrupted {
  border-color: var(--line-strong);
  background: var(--muted-soft);
  color: var(--muted);
}

.pill-unknown {
  border-color: var(--line);
  background: var(--paper-3);
  color: var(--ink-2);
}

.pill-running::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  animation: pulse 1.4s ease-in-out infinite;
}

@keyframes pulse {
  0%,
  100% {
    opacity: 0.35;
    transform: scale(0.9);
  }
  50% {
    opacity: 1;
    transform: scale(1.15);
  }
}

/* =========================== 模型状态 =========================== */

.model-status {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 12px;
  padding: 10px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 253, 249, 0.82);
  text-align: left;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
}

.model-status:hover {
  border-color: var(--line-strong);
  background: var(--paper-2);
}

.model-status > svg {
  flex: none;
  color: var(--ink-3);
}

.dot {
  flex: none;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--muted);
  box-shadow: 0 0 0 3px rgba(107, 112, 118, 0.14);
}

.dot-ok {
  background: var(--ok);
  box-shadow: 0 0 0 3px rgba(23, 122, 76, 0.16);
}

.dot-warn {
  background: var(--warn);
  box-shadow: 0 0 0 3px rgba(168, 90, 7, 0.16);
}

.dot-error {
  background: var(--danger);
  box-shadow: 0 0 0 3px rgba(180, 35, 24, 0.16);
}

.dot-checking {
  background: var(--accent);
  animation: pulse 1.4s ease-in-out infinite;
}

.model-text {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
  line-height: 1.35;
}

.model-text strong {
  overflow: hidden;
  font-size: 12.5px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.model-text small {
  overflow: hidden;
  color: var(--ink-3);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sidebar-foot {
  padding: 10px 4px 0;
  color: var(--ink-3);
  font-size: 10.5px;
  letter-spacing: 0.04em;
  text-align: center;
}

/* =========================== 主区域通用 =========================== */

.view {
  max-width: 1080px;
  margin: 0 auto;
  animation: view-in 0.22s ease both;
}

@keyframes view-in {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.view-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 22px;
}

.eyebrow {
  margin-bottom: 6px;
  color: var(--accent-deep);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.22em;
}

.lede {
  max-width: 70ch;
  margin-top: 9px;
  color: var(--ink-2);
  font-size: 14px;
}

.head-actions {
  display: flex;
  flex: none;
  gap: 8px;
  padding-top: 4px;
}

.card {
  padding: 24px 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--paper-2);
  box-shadow: var(--shadow-sm);
}

.card + .card {
  margin-top: 18px;
}

.card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.card-lede {
  margin-bottom: 18px;
  color: var(--ink-2);
  font-size: 13.5px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper-2);
  color: var(--ink-2);
  font-size: 11px;
  font-weight: 600;
  line-height: 1.65;
  white-space: nowrap;
}

.badge-accent {
  border-color: var(--accent-line);
  background: var(--accent-soft);
  color: var(--accent-deep);
}

.badge-muted {
  border-color: var(--line);
  background: var(--paper-3);
  color: var(--ink-3);
}

.demo-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  max-width: 1080px;
  margin: 0 auto 18px;
  padding: 10px 14px;
  border: 1px dashed var(--warn-line);
  border-radius: var(--radius);
  background: var(--warn-soft);
  color: var(--warn);
  font-size: 12.5px;
}

.demo-banner strong {
  font-family: var(--serif);
  letter-spacing: 0.08em;
}

/* =========================== 提示条 =========================== */

.callout {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-left-width: 4px;
  border-radius: var(--radius);
  background: var(--paper-3);
}

.callout-body {
  min-width: 0;
}

.callout-body > strong {
  display: block;
  margin-bottom: 4px;
  font-family: var(--serif);
  font-size: 14.5px;
}

.callout-body > p {
  color: var(--ink-2);
  font-size: 13px;
}

.callout-body > p + p {
  margin-top: 6px;
}

.callout-actions {
  display: flex;
  flex: none;
  flex-wrap: wrap;
  gap: 6px;
}

.callout-warn {
  border-color: var(--warn-line);
  border-left-color: var(--warn);
  background: var(--warn-soft);
}

.callout-error {
  border-color: var(--danger-line);
  border-left-color: var(--danger);
  background: var(--danger-soft);
}

.callout-error .callout-body > strong {
  color: var(--danger-deep);
}

.config-guide {
  margin: 8px 0 6px;
  padding-left: 20px;
  color: var(--ink-2);
  font-size: 12.5px;
  line-height: 1.8;
}

/* =========================== 步骤条 =========================== */

.wizard-steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  margin: 0 0 20px;
  padding: 0;
  list-style: none;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper-2);
  overflow: hidden;
}

.wizard-steps li {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 16px;
  color: var(--ink-3);
  font-size: 13px;
}

.wizard-steps li + li {
  border-left: 1px solid var(--line);
}

.wizard-steps li.is-current {
  background: var(--accent-soft);
  color: var(--accent-deep);
}

.wizard-steps li.is-complete {
  color: var(--ink-2);
}

.step-index {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 25px;
  height: 25px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: var(--paper-2);
  font-family: var(--serif);
  font-size: 12.5px;
  font-weight: 700;
  flex: none;
}

.wizard-steps li.is-current .step-index {
  border-color: var(--accent);
  background: var(--accent);
  color: #f7fffd;
}

.wizard-steps li.is-complete .step-index {
  border-color: var(--accent-line);
  background: var(--accent-soft);
  color: var(--accent-deep);
}

.step-text {
  display: flex;
  flex-direction: column;
  line-height: 1.3;
}

.step-text strong {
  font-size: 13.5px;
}

.step-text small {
  color: inherit;
  opacity: 0.78;
  font-size: 11px;
}

.step-panel {
  animation: view-in 0.18s ease both;
}

/* =========================== 上传 =========================== */

.dropzone {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 34px 20px;
  border: 1.5px dashed var(--line-strong);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at 50% 0%, rgba(14, 113, 104, 0.05), transparent 70%),
    var(--paper-2);
  color: var(--ink-2);
  text-align: center;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.dropzone:hover {
  border-color: var(--accent);
  background: var(--accent-soft);
}

.dropzone.is-dragover {
  border-color: var(--accent);
  background: var(--accent-soft);
  box-shadow: 0 0 0 4px rgba(14, 113, 104, 0.12);
}

.dropzone.is-busy {
  pointer-events: none;
  opacity: 0.65;
}

.dropzone-icon {
  color: var(--accent);
  margin-bottom: 2px;
}

.dropzone strong {
  font-family: var(--serif);
  font-size: 16px;
  color: var(--ink);
}

.dropzone-hint {
  color: var(--ink-3);
  font-size: 12.5px;
}

.dropzone-files {
  margin-top: 6px;
  padding: 3px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink-3);
  font-size: 10.5px;
  letter-spacing: 0.1em;
}

.upload-state {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 14px;
  padding: 12px 14px;
  border: 1px solid var(--accent-line);
  border-radius: var(--radius);
  background: var(--accent-soft);
  color: var(--accent-deep);
  font-size: 13px;
}

.spinner {
  width: 16px;
  height: 16px;
  border: 2px solid rgba(14, 113, 104, 0.25);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  flex: none;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

#upload-error {
  margin-top: 14px;
  margin-bottom: 0;
}

/* 文件卡 */
.file-card {
  margin-top: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--paper-2);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.file-card-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(239, 233, 221, 0.65), rgba(255, 253, 249, 0.4));
}

.file-ext {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--accent-line);
  border-radius: 8px;
  background: var(--accent-soft);
  color: var(--accent-deep);
  font-family: var(--serif);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  flex: none;
}

.file-info {
  flex: 1;
  min-width: 0;
}

.file-name {
  display: block;
  overflow: hidden;
  font-family: var(--serif);
  font-size: 15px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.file-sub {
  display: block;
  margin-top: 2px;
  overflow: hidden;
  color: var(--ink-3);
  font-size: 11.5px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.file-reselect {
  flex: none;
}

.file-facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 0;
  margin: 0;
  border-bottom: 1px solid var(--line);
}

.fact {
  padding: 11px 16px;
  border-right: 1px solid var(--line);
}

.fact:last-child {
  border-right: 0;
}

.fact-label {
  display: block;
  color: var(--ink-3);
  font-size: 10.5px;
  letter-spacing: 0.08em;
}

.fact-value {
  display: block;
  margin-top: 2px;
  font-size: 13px;
  font-weight: 600;
}

.fact-value.is-warn {
  color: var(--warn);
}

.fact-value.is-error {
  color: var(--danger);
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 12px 16px 0;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper-3);
  color: var(--ink-2);
  font-size: 11px;
  line-height: 1.65;
}

.tag-ok {
  border-color: var(--ok-line);
  background: var(--ok-soft);
  color: var(--ok);
}

.tag-warn {
  border-color: var(--warn-line);
  background: var(--warn-soft);
  color: var(--warn);
}

.tag-error {
  border-color: var(--danger-line);
  background: var(--danger-soft);
  color: var(--danger);
}

.file-warnings {
  margin: 12px 16px 0;
  padding: 10px 12px;
  border: 1px solid var(--warn-line);
  border-radius: 8px;
  background: var(--warn-soft);
  color: var(--warn);
  font-size: 12.5px;
}

.file-warnings ul {
  margin: 4px 0 0;
  padding-left: 18px;
}

.file-error {
  margin: 12px 16px 0;
  padding: 10px 12px;
  border: 1px solid var(--danger-line);
  border-radius: 8px;
  background: var(--danger-soft);
  color: var(--danger-deep);
  font-size: 12.5px;
}

.file-redaction {
  margin: 12px 16px 16px;
  padding: 10px 12px;
  border: 1px solid var(--accent-line);
  border-radius: 8px;
  background: var(--accent-soft);
  color: var(--accent-deep);
  font-size: 12.5px;
}

.preview-block {
  margin: 14px 16px 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  overflow: hidden;
}

.preview-block summary {
  padding: 9px 12px;
  color: var(--ink-2);
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  user-select: none;
}

.preview-block summary:hover {
  background: var(--paper-3);
}

.preview-pre {
  max-height: 340px;
  margin: 0;
  padding: 12px 14px;
  border-top: 1px dashed var(--line);
  background: var(--paper-2);
  color: var(--ink-2);
  overflow: auto;
}

/* =========================== 类型选择 =========================== */

.type-notice {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 18px;
  padding: 12px 14px;
  border: 1px solid var(--accent-line);
  border-left: 4px solid var(--accent);
  border-radius: var(--radius);
  background: var(--accent-soft);
  color: var(--accent-deep);
}

.type-notice > svg {
  flex: none;
  margin-top: 2px;
}

.type-notice strong {
  display: block;
  font-family: var(--serif);
  font-size: 14.5px;
}

.type-notice p {
  margin-top: 3px;
  color: var(--ink-2);
  font-size: 12.5px;
}

.type-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
  padding: 0;
  border: 0;
}

.type-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--paper-2);
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.type-card:hover {
  border-color: var(--line-strong);
  box-shadow: var(--shadow-sm);
}

.type-card:focus-within {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.type-card.is-selected {
  border-color: var(--accent);
  background: linear-gradient(180deg, rgba(226, 241, 238, 0.7), rgba(255, 253, 249, 0.95));
  box-shadow: 0 0 0 3px rgba(14, 113, 104, 0.1);
}

.type-card input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.type-card-top {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.type-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--paper-3);
  color: var(--accent-deep);
  flex: none;
}

.type-card.is-selected .type-icon {
  border-color: var(--accent-line);
  background: var(--accent-soft);
}

.type-title {
  display: flex;
  flex-direction: column;
  flex: 1;
  line-height: 1.35;
}

.type-title strong {
  font-family: var(--serif);
  font-size: 16px;
}

.type-title small {
  margin-top: 2px;
  color: var(--ink-3);
  font-size: 11px;
}

.type-check {
  position: relative;
  flex: none;
  width: 19px;
  height: 19px;
  margin-top: 2px;
  border: 1.5px solid var(--line-strong);
  border-radius: 50%;
  background: var(--paper-2);
}

.type-card.is-selected .type-check {
  border-color: var(--accent);
  background: var(--accent);
}

.type-card.is-selected .type-check::after {
  content: "";
  position: absolute;
  left: 5.5px;
  top: 3px;
  width: 5px;
  height: 9px;
  border-right: 2px solid #f7fffd;
  border-bottom: 2px solid #f7fffd;
  transform: rotate(42deg);
}

.type-guideline {
  display: block;
  padding-top: 2px;
  border-top: 1px dashed var(--line);
  color: var(--ink-3);
  font-size: 11.5px;
}

.type-guideline strong {
  color: var(--accent-deep);
  font-size: 12.5px;
  letter-spacing: 0.02em;
}

.type-guideline span {
  color: var(--ink-3);
}

.type-desc {
  color: var(--ink-2);
  font-size: 12.5px;
  line-height: 1.65;
}

.type-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: auto;
}

.type-tags span {
  padding: 1px 7px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
  color: var(--ink-3);
  font-size: 10.5px;
}

/* =========================== 确认表单 =========================== */

.confirm-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px 18px;
  margin-bottom: 18px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.field-wide {
  grid-column: 1 / -1;
}

.field > label {
  color: var(--ink-2);
  font-size: 13px;
  font-weight: 600;
}

.field input[type="text"],
.field textarea {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: var(--paper-2);
  font-size: 13.5px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.field input[type="text"]:focus,
.field textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(14, 113, 104, 0.12);
  outline: none;
}

.field textarea {
  min-height: 96px;
  resize: vertical;
  line-height: 1.6;
}

.field-hint {
  color: var(--ink-3);
  font-size: 11.5px;
}

.field-counter {
  align-self: flex-end;
}

/* 开关 */
.switch {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  cursor: pointer;
}

.switch input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.switch-track {
  position: relative;
  flex: none;
  width: 40px;
  height: 22px;
  margin-top: 2px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--paper-4);
  transition: background 0.16s ease, border-color 0.16s ease;
}

.switch-thumb {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--paper-2);
  box-shadow: 0 1px 2px rgba(32, 38, 43, 0.25);
  transition: transform 0.16s ease;
}

.switch input:checked + .switch-track {
  border-color: var(--accent);
  background: var(--accent);
}

.switch input:checked + .switch-track .switch-thumb {
  transform: translateX(18px);
}

.switch input:focus-visible + .switch-track {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.switch-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 13px;
}

.switch-text small {
  color: var(--ink-3);
  font-size: 11.5px;
  line-height: 1.55;
}

/* 同意 */
.consent {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid var(--warn-line);
  border-radius: var(--radius);
  background: var(--warn-soft);
  color: var(--ink-2);
  font-size: 12.5px;
  line-height: 1.65;
  cursor: pointer;
}

.consent input {
  flex: none;
  width: 16px;
  height: 16px;
  margin-top: 2px;
  accent-color: var(--accent);
  cursor: pointer;
}

.consent:has(input:checked) {
  border-color: var(--accent-line);
  background: var(--accent-soft);
}

/* 条件提示 */
.hint-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 14px;
}

.hint-item {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  color: var(--warn);
  font-size: 12.5px;
}

.hint-item::before {
  content: "•";
  flex: none;
  font-weight: 700;
}

.hint-ok {
  color: var(--ok);
}

.hint-ok::before {
  content: "✓";
}

/* 底部摘要条 */
.summary-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 16px;
  padding: 15px 18px;
  border: 1px solid var(--accent-line);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, var(--accent-soft), rgba(255, 253, 249, 0.85));
}

.summary-info {
  min-width: 0;
}

.summary-label {
  display: block;
  color: var(--accent-deep);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.16em;
}

.summary-text {
  margin-top: 2px;
  color: var(--ink-2);
  font-size: 13px;
  overflow-wrap: anywhere;
}

.summary-text strong {
  color: var(--ink);
}

.step-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.step-hint {
  color: var(--ink-3);
  font-size: 12px;
}

/* =========================== 进度 =========================== */

.stage-list {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  margin: 0 0 18px;
  padding: 0;
  list-style: none;
}

.stage-list li {
  position: relative;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper-2);
  color: var(--ink-3);
  transition: border-color 0.2s ease, background 0.2s ease;
}

.stage-list li.is-active {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: var(--accent-deep);
  box-shadow: 0 0 0 3px rgba(14, 113, 104, 0.08);
}

.stage-list li.is-done {
  border-color: var(--ok-line);
  background: var(--ok-soft);
  color: var(--ok);
}

.stage-list li.is-error {
  border-color: var(--danger-line);
  background: var(--danger-soft);
  color: var(--danger);
}

.stage-dot {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 25px;
  height: 25px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: var(--paper-2);
  font-family: var(--serif);
  font-size: 12px;
  font-weight: 700;
  flex: none;
}

.stage-list li.is-active .stage-dot {
  border-color: var(--accent);
  background: var(--accent);
  color: #f7fffd;
  animation: pulse 1.6s ease-in-out infinite;
}

.stage-list li.is-done .stage-dot {
  border-color: var(--ok);
  background: var(--ok);
  color: #f7fffd;
}

.stage-body {
  display: flex;
  flex-direction: column;
  min-width: 0;
  line-height: 1.3;
}

.stage-body strong {
  font-size: 12.5px;
  white-space: nowrap;
}

.stage-body small {
  font-size: 10.5px;
  opacity: 0.85;
}

.progress-track {
  height: 8px;
  margin-bottom: 8px;
  border-radius: 999px;
  background: var(--paper-4);
  overflow: hidden;
}

.progress-fill {
  width: 0;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent), #35a396);
  transition: width 0.4s ease;
}

.progress-status {
  min-height: 22px;
  margin-bottom: 18px;
  color: var(--ink-2);
  font-size: 13px;
}

.meta-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 18px;
}

.meta-tile {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper-2);
}

.meta-label {
  color: var(--ink-3);
  font-size: 10.5px;
  letter-spacing: 0.08em;
}

.meta-value {
  font-family: var(--serif);
  font-size: 19px;
  font-weight: 700;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.meta-value-sm {
  font-family: var(--mono);
  font-size: 12.5px;
  font-weight: 500;
}

.log-card {
  padding-bottom: 10px;
}

.log-count {
  color: var(--ink-3);
  font-size: 11.5px;
}

.log-list {
  max-height: 340px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #262b30;
  overflow-y: auto;
  font-family: var(--mono);
  font-size: 11.5px;
  line-height: 1.7;
  scrollbar-width: thin;
}

.log-line {
  display: flex;
  gap: 10px;
  color: #cfd6d3;
  overflow-wrap: anywhere;
}

.log-time {
  flex: none;
  color: #7f8c88;
}

.log-info .log-message {
  color: #d6dcd9;
}

.log-warn .log-message {
  color: #f0c47c;
}

.log-error .log-message {
  color: #f2a09a;
}

.log-debug .log-message {
  color: #9aa8a3;
}

.log-empty {
  color: #8b9793;
}

/* 错误卡片 */
.error-card {
  margin-top: 18px;
  border-color: var(--danger-line);
  background: linear-gradient(180deg, var(--danger-soft), var(--paper-2));
}

.error-head {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 14px;
}

.error-icon {
  flex: none;
  color: var(--danger);
}

.error-head h2 {
  font-size: 19px;
  color: var(--danger-deep);
}

.error-head p {
  margin-top: 3px;
  color: var(--ink-2);
  font-size: 13.5px;
  overflow-wrap: anywhere;
}

.error-details {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 4px 14px;
  margin: 0 0 12px;
  padding: 10px 12px;
  border: 1px solid var(--danger-line);
  border-radius: 8px;
  background: rgba(255, 253, 249, 0.6);
  font-size: 12px;
}

.error-details dt {
  color: var(--ink-3);
}

.error-details dd {
  margin: 0;
  overflow-wrap: anywhere;
}

.tech-details {
  margin-bottom: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  overflow: hidden;
}

.tech-details summary {
  padding: 7px 12px;
  color: var(--ink-2);
  font-size: 12px;
  cursor: pointer;
}

.tech-details pre {
  max-height: 260px;
  padding: 10px 12px;
  border-top: 1px dashed var(--line);
  background: var(--paper-2);
  overflow: auto;
  font-size: 11.5px;
}

.error-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/* =========================== 报告 =========================== */

.report-toolbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 16px;
}

.report-toolbar-title {
  min-width: 0;
}

.report-toolbar-title h1 {
  font-size: 27px;
  overflow-wrap: anywhere;
}

.report-subtitle {
  margin-top: 5px;
  color: var(--ink-2);
  font-size: 13px;
  overflow-wrap: anywhere;
}

.report-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
  padding-top: 4px;
}

.anchor-nav {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  gap: 2px;
  margin-bottom: 18px;
  padding: 7px 8px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(247, 243, 236, 0.92);
  backdrop-filter: blur(8px);
  overflow-x: auto;
  scrollbar-width: thin;
}

.anchor-nav a {
  flex: none;
  padding: 4px 9px;
  border-radius: 6px;
  color: var(--ink-2);
  font-size: 12px;
  text-decoration: none;
  white-space: nowrap;
}

.anchor-nav a:hover {
  background: var(--paper-3);
  color: var(--accent-deep);
}

.anchor-nav a.is-active {
  background: var(--accent-soft, #dcefeb);
  color: var(--accent-deep, #0b5f59);
  font-weight: 600;
}

.report-body {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.report-section {
  padding: 22px 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--paper-2);
  box-shadow: var(--shadow-sm);
  scroll-margin-top: 64px;
}

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
  padding-bottom: 9px;
  border-bottom: 1px solid var(--line);
}

.section-head h2 {
  font-size: 19px;
}

.section-note {
  color: var(--ink-3);
  font-size: 11.5px;
  text-align: right;
}

/* 报告头 */
.report-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  overflow: hidden;
}

.meta-pair {
  padding: 10px 14px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.meta-pair:nth-child(3n) {
  border-right: 0;
}

.meta-pair:last-child,
.meta-pair:nth-last-child(2):nth-child(3n + 2),
.meta-pair:nth-last-child(3):nth-child(3n + 1) {
  border-bottom: 0;
}

.meta-pair dt {
  color: var(--ink-3);
  font-size: 10.5px;
  letter-spacing: 0.06em;
}

.meta-pair dd {
  margin: 2px 0 0;
  font-size: 13px;
  font-weight: 500;
  overflow-wrap: anywhere;
}

.meta-pair dd.is-mono {
  font-family: var(--mono);
  font-size: 11.5px;
}

/* 统计卡 */
.stat-grid {
  display: grid;
  gap: 8px;
  margin-bottom: 14px;
}

.stat-grid-verdicts {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.stat-grid-secondary {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.stat-grid-severity {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.stat-card {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}

.stat-label {
  color: var(--ink-3);
  font-size: 10.5px;
  letter-spacing: 0.05em;
  white-space: nowrap;
}

.stat-value {
  font-family: var(--serif);
  font-size: 24px;
  font-weight: 700;
  line-height: 1.2;
}

.stat-card.stat-report {
  border-color: var(--ok-line);
  background: var(--ok-soft);
  color: var(--ok);
}

.stat-card.stat-missing {
  border-color: var(--danger-line);
  background: var(--danger-soft);
  color: var(--danger);
}

.stat-card.stat-insufficient {
  border-color: var(--warn-line);
  background: var(--warn-soft);
  color: var(--warn);
}

.stat-card.stat-na {
  border-color: var(--line-strong);
  background: var(--muted-soft);
  color: var(--muted);
}

.stat-card.stat-unknown {
  border-color: var(--blue-line);
  background: var(--blue-soft);
  color: var(--blue);
}

.stat-card.stat-high {
  border-color: var(--danger-line);
  background: var(--danger-soft);
  color: var(--danger);
}

.stat-card.stat-mid {
  border-color: var(--warn-line);
  background: var(--warn-soft);
  color: var(--warn);
}

.stat-card.stat-low {
  border-color: var(--line-strong);
  background: var(--muted-soft);
  color: var(--muted);
}

.stat-card.stat-blocker {
  border-color: var(--accent-line);
  background: var(--accent-soft);
  color: var(--accent-deep);
}

.stat-card.stat-scope {
  border-color: var(--line);
  background: var(--paper-3);
  color: var(--ink-2);
}

.stat-card .stat-hint {
  color: inherit;
  font-size: 10.5px;
  opacity: 0.75;
}

.substat-label {
  margin: 0 0 6px;
  color: var(--ink-3);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.08em;
}

.auto-summary {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-left: 3px solid var(--accent);
  border-radius: 8px;
  background: var(--paper);
  color: var(--ink-2);
  font-size: 13px;
  line-height: 1.75;
}

.auto-summary strong {
  color: var(--ink);
}

.warn-list {
  margin: 12px 0 0;
  padding: 10px 14px 10px 30px;
  border: 1px solid var(--warn-line);
  border-radius: 8px;
  background: var(--warn-soft);
  color: var(--warn);
  font-size: 12.5px;
}

.warn-list li + li {
  margin-top: 3px;
}

/* 条目表 */
.table-wrap {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow-x: auto;
  background: var(--paper-2);
}

.item-table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
  font-size: 12.5px;
}

.item-table thead th {
  position: sticky;
  top: 0;
  padding: 9px 12px;
  border-bottom: 1px solid var(--line-strong);
  background: var(--paper-3);
  color: var(--ink-2);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-align: left;
  white-space: nowrap;
}

.item-table tbody td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

.item-table tbody tr:last-child td {
  border-bottom: 0;
}

.item-table tbody tr:hover {
  background: rgba(239, 233, 221, 0.4);
}

.cell-no {
  width: 48px;
  color: var(--ink-3);
  font-family: var(--mono);
  font-size: 11.5px;
  white-space: nowrap;
}

.cell-name {
  min-width: 150px;
}

.item-name {
  display: block;
  font-family: var(--serif);
  font-size: 13.5px;
  font-weight: 700;
}

.item-branch {
  display: block;
  margin-top: 2px;
  color: var(--ink-3);
  font-size: 10.5px;
}

.cell-verdict {
  width: 104px;
}

.cell-location {
  width: 140px;
  color: var(--ink-2);
  font-size: 12px;
  overflow-wrap: anywhere;
}

.cell-evidence {
  min-width: 260px;
}

.cell-placeholder {
  color: var(--ink-3);
  font-style: italic;
}

/* 判定徽标 */
.verdict {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 1px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.75;
  white-space: nowrap;
}

.verdict::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: currentColor;
}

.v-report {
  border-color: var(--ok-line);
  background: var(--ok-soft);
  color: var(--ok);
}

.v-missing {
  border-color: var(--danger-line);
  background: var(--danger-soft);
  color: var(--danger);
}

.v-insufficient {
  border-color: var(--warn-line);
  background: var(--warn-soft);
  color: var(--warn);
}

.v-na {
  border-color: var(--line-strong);
  background: var(--muted-soft);
  color: var(--muted);
}

.v-unknown {
  border-color: var(--blue-line);
  background: var(--blue-soft);
  color: var(--blue);
}

.v-invalid {
  border-color: var(--line-strong);
  background: var(--paper-3);
  color: var(--ink-2);
}

.evidence-details {
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--paper);
}

.evidence-details summary {
  padding: 5px 9px;
  color: var(--ink-2);
  font-size: 11.5px;
  font-weight: 600;
  cursor: pointer;
  user-select: none;
}

.evidence-details summary:hover {
  background: var(--paper-3);
}

.evidence-details .evidence-body {
  padding: 8px 10px 10px;
  border-top: 1px dashed var(--line);
}

.evidence-quote {
  padding: 8px 10px;
  border-left: 3px solid var(--line-strong);
  background: var(--paper-2);
  color: var(--ink-2);
  font-size: 12px;
  line-height: 1.7;
  overflow-wrap: anywhere;
}

.evidence-quote.is-empty {
  border-left-color: var(--line);
  color: var(--ink-3);
  font-style: italic;
}

.evidence-note {
  margin-top: 6px;
  color: var(--ink-2);
  font-size: 11.5px;
}

.evidence-note strong {
  color: var(--ink);
}

.muted-inline {
  color: var(--ink-3);
}

/* 发现清单 */
.findings-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.chip {
  padding: 3px 10px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--paper-2);
  color: var(--ink-2);
  font-size: 11.5px;
  cursor: pointer;
  transition: background 0.14s ease, border-color 0.14s ease, color 0.14s ease;
}

.chip:hover {
  border-color: var(--accent);
  color: var(--accent-deep);
}

.chip.is-active {
  border-color: var(--accent);
  background: var(--accent);
  color: #f7fffd;
}

.chip .chip-count {
  margin-left: 4px;
  font-family: var(--mono);
  font-size: 10.5px;
  opacity: 0.85;
}

.toggle-inline {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--ink-2);
  font-size: 12px;
  cursor: pointer;
  user-select: none;
}

.toggle-inline input {
  width: 15px;
  height: 15px;
  accent-color: var(--accent);
  cursor: pointer;
}

.finding-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.finding-card {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-left: 3px solid var(--line-strong);
  border-radius: 8px;
  background: var(--paper);
}

.finding-card.sev-high {
  border-left-color: var(--danger);
}

.finding-card.sev-mid {
  border-left-color: var(--warn);
}

.finding-card.sev-low {
  border-left-color: var(--muted);
}

.finding-head {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 6px;
  flex-wrap: wrap;
}

.sev-badge {
  display: inline-flex;
  align-items: center;
  padding: 0 7px;
  border: 1px solid var(--line);
  border-radius: 5px;
  font-size: 10.5px;
  font-weight: 700;
  line-height: 1.8;
  white-space: nowrap;
}

.sev-high {
  color: var(--danger);
}

.sev-badge.sev-high {
  border-color: var(--danger-line);
  background: var(--danger-soft);
}

.sev-mid {
  color: var(--warn);
}

.sev-badge.sev-mid {
  border-color: var(--warn-line);
  background: var(--warn-soft);
}

.sev-low {
  color: var(--muted);
}

.sev-badge.sev-low {
  border-color: var(--line-strong);
  background: var(--muted-soft);
}

.finding-title {
  font-family: var(--serif);
  font-size: 14px;
  font-weight: 700;
}

.finding-id {
  color: var(--ink-3);
  font-family: var(--mono);
  font-size: 10.5px;
}

.finding-tag {
  padding: 0 6px;
  border: 1px solid var(--line);
  border-radius: 4px;
  color: var(--ink-3);
  font-size: 10px;
  line-height: 1.8;
}

.finding-quote {
  padding: 7px 10px;
  border-left: 3px solid var(--line-strong);
  border-radius: 0 6px 6px 0;
  background: var(--paper-2);
  color: var(--ink-2);
  font-size: 12.5px;
  line-height: 1.7;
  overflow-wrap: anywhere;
}

.finding-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 16px;
  margin-top: 6px;
  color: var(--ink-3);
  font-size: 11.5px;
}

.finding-meta strong {
  color: var(--ink-2);
  font-weight: 600;
}

/* 必办 / 风险 / 复核 */
.blocker-list {
  margin: 0;
  padding-left: 22px;
  color: var(--ink-2);
  font-size: 13px;
  line-height: 1.8;
}

.blocker-list li {
  padding-left: 4px;
}

.blocker-list li + li {
  margin-top: 5px;
}

.risk-list {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.risk-list li {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  color: var(--ink-2);
  font-size: 12.5px;
  line-height: 1.7;
}

.risk-list li::before {
  content: "!";
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  width: 17px;
  height: 17px;
  margin-top: 1px;
  border-radius: 50%;
  background: var(--warn-soft);
  color: var(--warn);
  font-family: var(--serif);
  font-size: 11px;
  font-weight: 700;
}

.review-groups {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.review-group {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}

.review-group h3 {
  margin-bottom: 7px;
  font-size: 14px;
}

.review-group ul {
  margin: 0;
  padding-left: 18px;
  color: var(--ink-2);
  font-size: 12px;
  line-height: 1.7;
}

.review-group.group-high {
  border-color: var(--danger-line);
  background: var(--danger-soft);
}

.review-group.group-high h3 {
  color: var(--danger-deep);
}

.review-group.group-material {
  border-color: var(--warn-line);
  background: var(--warn-soft);
}

.review-group.group-material h3 {
  color: var(--warn);
}

.review-group.group-ai {
  border-color: var(--accent-line);
  background: var(--accent-soft);
}

.review-group.group-ai h3 {
  color: var(--accent-deep);
}

/* 证据表 */
.evidence-table {
  min-width: 680px;
}

.evidence-table .cell-no {
  width: 40px;
}

.evidence-table .cell-loc {
  width: 150px;
}

.evidence-table .cell-item {
  width: 170px;
}

/* 声明 */
.declaration {
  display: flex;
  flex-direction: column;
  gap: 8px;
  color: var(--ink-2);
  font-size: 12.5px;
  line-height: 1.8;
}

.declaration p::before {
  content: "·";
  margin-right: 6px;
  color: var(--accent);
  font-weight: 700;
}

.declaration .warn-list {
  margin: 4px 0 0;
}

.footer-meta {
  margin-top: 14px;
  padding-top: 10px;
  border-top: 1px dashed var(--line);
  color: var(--ink-3);
  font-family: var(--mono);
  font-size: 10.5px;
  line-height: 1.8;
  overflow-wrap: anywhere;
}

.empty-state {
  padding: 22px 16px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  background: var(--paper);
  color: var(--ink-3);
  font-size: 12.5px;
  text-align: center;
}

.empty-inline {
  color: var(--ink-3);
  font-size: 12.5px;
}

/* =========================== 对话框 =========================== */

.dialog {
  width: min(620px, calc(100vw - 32px));
  max-height: min(84vh, 760px);
  padding: 0;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  background: var(--paper-2);
  color: var(--ink);
  box-shadow: 0 24px 60px rgba(32, 38, 43, 0.22);
  overflow: auto;
}

.dialog::backdrop {
  background: rgba(32, 38, 43, 0.36);
  backdrop-filter: blur(2px);
}

.dialog-inner {
  padding: 22px 24px 20px;
}

.dialog-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 6px;
}

.dialog-head h2 {
  font-size: 20px;
}

.dialog-lede {
  margin-bottom: 16px;
  color: var(--ink-3);
  font-size: 12.5px;
}

.settings-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 14px;
  margin: 0 0 16px;
}

.settings-item {
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
}

.settings-item dt {
  color: var(--ink-3);
  font-size: 10.5px;
  letter-spacing: 0.06em;
}

.settings-item dd {
  margin: 2px 0 0;
  font-size: 12.5px;
  overflow-wrap: anywhere;
}

.dialog-section {
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.dialog-section h3 {
  margin-bottom: 6px;
  font-size: 14px;
}

.dialog-section p {
  color: var(--ink-2);
  font-size: 12.5px;
  line-height: 1.75;
}

.dialog-section p + p {
  margin-top: 6px;
}

.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 18px;
}

/* =========================== Toast =========================== */

.toast-container {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 200;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
  pointer-events: none;
}

.toast {
  max-width: min(420px, calc(100vw - 40px));
  padding: 10px 14px;
  border: 1px solid var(--line-strong);
  border-left: 3px solid var(--ink-3);
  border-radius: 9px;
  background: var(--paper-2);
  color: var(--ink);
  box-shadow: var(--shadow-md);
  font-size: 12.5px;
  line-height: 1.6;
  pointer-events: auto;
  animation: toast-in 0.2s ease both;
}

.toast-error {
  border-left-color: var(--danger);
  background: var(--danger-soft);
  color: var(--danger-deep);
}

.toast-success {
  border-left-color: var(--ok);
  background: var(--ok-soft);
  color: var(--ok);
}

.toast-info {
  border-left-color: var(--accent);
  background: var(--accent-soft);
  color: var(--accent-deep);
}

.toast.is-hiding {
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

@keyframes toast-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.noscript {
  padding: 20px;
  color: var(--danger);
  text-align: center;
}

/* =========================== 响应式 =========================== */

@media (max-width: 1120px) {
  .main {
    padding: 28px 30px 72px;
  }

  .report-actions {
    max-width: 46%;
  }
}

@media (max-width: 980px) {
  .app {
    grid-template-columns: minmax(0, 1fr);
  }

  .sidebar {
    position: sticky;
    top: 0;
    z-index: 30;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    grid-template-areas:
      "brand new status"
      "history history history"
      "foot foot foot";
    gap: 10px 12px;
    height: auto;
    padding: 12px 16px 10px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    box-shadow: 0 6px 18px rgba(32, 38, 43, 0.06);
  }

  .brand {
    grid-area: brand;
    padding: 0;
  }

  .brand-text small {
    display: none;
  }

  .btn-new {
    grid-area: new;
    width: auto;
    min-height: 36px;
    margin: 0;
    justify-self: start;
  }

  .history {
    grid-area: history;
    margin: 0;
    min-height: 0;
  }

  .history-list {
    display: flex;
    gap: 6px;
    padding: 2px 0;
    overflow-x: auto;
    overflow-y: hidden;
  }

  .history-item {
    flex: none;
    width: 210px;
    margin: 0;
  }

  .history-head {
    padding: 0 0 4px;
  }

  .history-empty,
  .history-error {
    padding: 4px 2px;
  }

  .model-status {
    grid-area: status;
    margin: 0;
    min-width: 0;
    max-width: 250px;
  }

  .model-status > svg,
  .sidebar-foot {
    display: none;
  }

  .sidebar-foot {
    grid-area: foot;
  }

  .main {
    padding: 24px 20px 64px;
  }

  .view-head,
  .report-toolbar {
    flex-direction: column;
    gap: 10px;
  }

  .head-actions {
    padding-top: 0;
  }

  .report-actions {
    max-width: none;
    justify-content: flex-start;
    padding-top: 0;
  }

  .anchor-nav {
    top: 0;
  }

  .type-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .type-card {
    padding: 14px 16px;
  }

  .stat-grid-verdicts {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .review-groups {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 720px) {
  body {
    font-size: 14px;
  }

  h1 {
    font-size: 24px;
  }

  .main {
    padding: 20px 14px 56px;
  }

  .sidebar {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "brand status"
      "new new"
      "history history";
  }

  .btn-new {
    justify-self: stretch;
  }

  .history-item {
    width: 190px;
  }

  .wizard-steps li {
    padding: 9px 10px;
  }

  .step-text small {
    display: none;
  }

  .card,
  .report-section {
    padding: 18px 16px;
  }

  .dropzone {
    padding: 26px 14px;
  }

  .file-facts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .fact:nth-child(2n) {
    border-right: 0;
  }

  .fact {
    border-bottom: 1px solid var(--line);
  }

  .fact:nth-last-child(-n + 2) {
    border-bottom: 0;
  }

  .confirm-form {
    grid-template-columns: minmax(0, 1fr);
  }

  .summary-bar {
    flex-direction: column;
    align-items: stretch;
  }

  .summary-bar .btn {
    width: 100%;
  }

  .stage-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .stage-list li:last-child {
    grid-column: 1 / -1;
  }

  .meta-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .stat-grid-verdicts {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .stat-grid-secondary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .report-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .meta-pair,
  .meta-pair:nth-child(3n) {
    border-right: 1px solid var(--line);
  }

  .meta-pair:nth-child(2n) {
    border-right: 0;
  }

  .meta-pair:last-child {
    border-bottom: 0;
  }

  .settings-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .report-toolbar h1 {
    font-size: 23px;
  }

  .toast-container {
    right: 12px;
    bottom: 12px;
  }
}

@media (max-width: 460px) {
  .wizard-steps li {
    gap: 7px;
    font-size: 12px;
  }

  .step-text strong {
    font-size: 12px;
  }

  .stat-grid-verdicts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .stat-grid-severity {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .stage-list {
    grid-template-columns: minmax(0, 1fr);
  }

  .stage-list li:last-child {
    grid-column: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

/* =========================== 打印 =========================== */

@media print {
  @page {
    margin: 16mm 14mm;
  }

  body {
    background: #fff;
    color: #111;
    font-size: 10.5pt;
    line-height: 1.55;
  }

  .sidebar,
  .demo-banner,
  .skip-link,
  .report-toolbar .report-actions,
  .anchor-nav,
  .toast-container,
  .dialog,
  .view-head .head-actions,
  .noscript {
    display: none !important;
  }

  .app {
    display: block;
  }

  .main {
    padding: 0;
    max-width: none;
  }

  .view {
    max-width: none;
  }

  #view-new,
  #view-progress {
    display: none !important;
  }

  #view-report {
    display: block !important;
  }

  .report-body {
    gap: 8mm;
  }

  .report-section {
    padding: 0 0 4mm;
    border: 0;
    border-bottom: 1px solid #bbb;
    border-radius: 0;
    background: #fff;
    box-shadow: none;
    break-inside: auto;
    page-break-inside: auto;
  }

  .section-head {
    margin-bottom: 3mm;
    padding-bottom: 1.5mm;
    border-color: #999;
    break-after: avoid;
    page-break-after: avoid;
  }

  .section-head h2 {
    font-size: 13pt;
  }

  .section-note {
    color: #555;
  }

  .report-toolbar {
    margin-bottom: 4mm;
  }

  .report-toolbar h1 {
    font-size: 18pt;
  }

  .report-subtitle {
    color: #444;
  }

  .report-meta {
    border-color: #aaa;
    background: #fff;
    break-inside: avoid;
    page-break-inside: avoid;
  }

  .meta-pair {
    border-color: #ccc;
  }

  .meta-pair dt {
    color: #555;
  }

  .stat-grid {
    break-inside: avoid;
    page-break-inside: avoid;
  }

  .stat-card {
    border-color: #bbb;
    background: #fff !important;
    color: #111 !important;
  }

  .stat-card .stat-label {
    color: #555;
  }

  .auto-summary,
  .warn-list,
  .finding-card,
  .review-group,
  .risk-list li,
  .empty-state {
    background: #fff !important;
    border-color: #bbb;
    break-inside: avoid;
    page-break-inside: avoid;
  }

  .table-wrap {
    overflow: visible;
    border-color: #999;
  }

  .item-table {
    min-width: 0;
    font-size: 8.5pt;
  }

  .item-table thead th {
    position: static;
    background: #eee !important;
    border-color: #999;
  }

  .item-table tbody td {
    border-color: #ccc;
  }

  .item-table tbody tr {
    break-inside: avoid;
    page-break-inside: avoid;
  }

  .verdict,
  .sev-badge,
  .badge {
    border-color: #999;
    background: #fff !important;
    color: #111 !important;
  }

  .evidence-quote,
  .finding-quote {
    border-color: #999;
    background: #f7f7f7 !important;
  }

  details > summary {
    display: none !important;
  }

  details > *:not(summary) {
    display: block !important;
  }

  .evidence-body {
    border-top: 0 !important;
    padding: 0 !important;
  }

  .anchor-nav {
    display: none !important;
  }

  a {
    color: #111;
    text-decoration: none;
  }

  .footer-meta {
    color: #555;
    border-color: #999;
  }

  .review-groups {
    grid-template-columns: 1fr 1fr 1fr;
  }

  .report-section,
  .finding-card,
  .review-group {
    break-inside: avoid-page;
  }
}

/* ===== 注册号官网核验 ===== */
.file-registration {
  margin-top: 12px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface-soft, #fbfaf6);
}
.file-reg-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
  color: var(--ink);
  font-size: 13px;
}
.file-reg-head .btn-xs {
  padding: 3px 8px;
  font-size: 12px;
}
.file-reg-empty,
.file-reg-foot {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}
.file-reg-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 6px;
}
.file-reg-item {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  padding: 6px 8px;
  border-radius: 8px;
  background: var(--surface, #fff);
  border: 1px solid var(--line-soft, #eee7da);
  font-size: 12px;
}
.file-reg-id {
  font-family: var(--mono);
  font-weight: 700;
  color: var(--ink);
}
.file-reg-platform {
  color: var(--muted);
}
.file-reg-title {
  flex: 1 1 220px;
  min-width: 160px;
  color: var(--ink-soft, #39424e);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.file-reg-note {
  flex-basis: 100%;
  color: var(--muted);
  line-height: 1.5;
}
.reg-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.reg-table th,
.reg-table td {
  padding: 8px 10px;
  border-bottom: 1px solid var(--line-soft, #eee7da);
  text-align: left;
  vertical-align: top;
}
.reg-table th {
  color: var(--muted);
  font-weight: 600;
  background: var(--surface-soft, #fbfaf6);
  white-space: nowrap;
}
.reg-table .reg-id {
  font-family: var(--mono);
  font-weight: 700;
  white-space: nowrap;
}
.reg-table .reg-title {
  max-width: 320px;
  line-height: 1.55;
}
.reg-note {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.55;
}
.reg-status {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}
.reg-status.reg-ok {
  color: #067647;
  background: #e7f6ec;
}
.reg-status.reg-missing {
  color: #b42318;
  background: #fdeceb;
}
.reg-status.reg-manual {
  color: #b54708;
  background: #fef3e2;
}
.reg-status.reg-error {
  color: #5b6776;
  background: #eef1f4;
}
.reg-link {
  color: var(--accent, #0f766e);
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
}
.reg-link:hover {
  text-decoration: underline;
}
.reg-disclaimer {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}
@media (max-width: 760px) {
  .reg-table .reg-title,
  .reg-table .reg-id {
    max-width: none;
    white-space: normal;
  }
  .file-reg-title {
    white-space: normal;
  }
}

/* ===== 发现判定与英文审稿意见 ===== */
.finding-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px dashed var(--line-soft, #eee7da);
}
.finding-actions-label {
  color: var(--muted);
  font-size: 12px;
  margin-right: 2px;
}
.triage-btn {
  appearance: none;
  border: 1px solid var(--line);
  background: var(--surface, #fff);
  color: var(--muted);
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.14s ease, color 0.14s ease, border-color 0.14s ease;
}
.triage-btn:hover {
  border-color: var(--accent, #0f766e);
  color: var(--accent, #0f766e);
}
.triage-btn.is-active.triage-agree {
  background: #e7f6ec;
  color: #067647;
  border-color: #a6e0bb;
}
.triage-btn.is-active.triage-disagree {
  background: #fdeceb;
  color: #b42318;
  border-color: #f3b8b3;
}
.triage-btn.is-active.triage-pending {
  background: #eef1f4;
  color: #475467;
  border-color: #cfd6dd;
}
.review-decision-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}
.review-decision-count {
  display: inline-flex;
  align-items: center;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}
.review-agree {
  color: #067647;
  background: #e7f6ec;
}
.review-disagree {
  color: #b42318;
  background: #fdeceb;
}
.review-pending {
  color: #475467;
  background: #eef1f4;
}
.review-hint {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
  margin: 4px 0;
}
.review-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 10px 0;
}
.review-stale {
  margin: 8px 0;
  padding: 8px 10px;
  border-radius: 8px;
  background: #fef3e2;
  color: #b54708;
  font-size: 12px;
  line-height: 1.55;
}
.review-textarea {
  width: 100%;
  min-height: 300px;
  box-sizing: border-box;
  margin-top: 8px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  color: var(--ink);
  font-family: var(--mono);
  font-size: 13px;
  line-height: 1.7;
  resize: vertical;
}
.review-textarea:focus {
  outline: 2px solid var(--accent-soft, #cce9e5);
  outline-offset: 1px;
}
.review-meta {
  margin: 8px 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}
.review-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
@media print {
  .finding-actions,
  .review-actions,
  .review-tools {
    display: none !important;
  }
  .review-textarea {
    border: none;
    min-height: 0;
    height: auto;
    font-family: inherit;
  }
}

.finding-scope-note {
  color: var(--muted);
  font-size: 12px;
  font-style: italic;
}
.review-outscope {
  color: #475467;
  background: #eef1f4;
}

/* ===== 飞书用户信息 ===== */
.user-card {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: auto;
  margin-bottom: 10px;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface, #fff);
}
.user-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  flex: none;
  border-radius: 50%;
  background: var(--accent-soft, #dcefeb);
  color: var(--accent-deep, #0b5f59);
  font-weight: 700;
  font-size: 14px;
}
.user-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1 1 auto;
}
.user-text strong {
  font-size: 12px;
  color: var(--ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.user-text small {
  font-size: 11px;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.user-card .btn-xs {
  padding: 3px 7px;
  font-size: 11px;
  flex: none;
}
