﻿/* =====================
   全局变量 & 重置
===================== */
:root {
  --primary: #8B1538;
  --primary-dark: #6f102c;
  --success: #27ae60;
  --warning: #f39c12;
  --danger: #e74c3c;
  --info: #3498db;

  --bg: #f6f7f9;
  --card-bg: #ffffff;
  --text-main: #2c2c2c;
  --text-muted: #666;
  --border: #e5e7eb;

  --radius: 12px;
  --shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
}

.journal-demo-banner {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 18px;
  border-bottom: 1px solid rgba(146, 64, 14, .18);
  color: #7c2d12;
  background: #fff7ed;
  font-size: 13px;
  line-height: 1.55;
}

.journal-demo-banner strong {
  flex: 0 0 auto;
  min-height: 26px;
  display: inline-flex;
  align-items: center;
  padding: 0 10px;
  border-radius: 999px;
  color: #fff;
  background: #c2410c;
  font-weight: 800;
}

.journal-demo-banner span {
  font-weight: 600;
}

body.journal-demo-mode #logoutBtn {
  display: none;
}

@media (max-width: 760px) {
  .journal-demo-banner {
    align-items: flex-start;
    flex-direction: column;
    padding: 10px 12px;
  }
}

/* Media promotion workspace */
.media-promotion-page {
  min-height: calc(100vh - 146px);
  padding: 28px 32px 36px;
  background: #f6f7fb;
}

.media-promotion-title-card {
  margin: 0 0 18px;
  padding: 20px 24px;
  border: 1px solid #e7eaf0;
  border-radius: 14px;
  background: #ffffff;
  box-shadow: 0 14px 34px rgba(15, 23, 42, .06);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.media-promotion-title-card span,
.media-promotion-card-head span,
.media-promotion-account-card span,
.media-promotion-preview-head span {
  display: block;
  color: #9f1239;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.4;
}

.media-promotion-title-card h2 {
  margin: 4px 0 6px;
  color: #111827;
  font-size: 24px;
  line-height: 1.32;
  font-weight: 850;
}

.media-promotion-title-card p {
  margin: 0;
  color: #64748b;
  font-size: 14px;
  line-height: 1.65;
}

.media-promotion-shell {
  display: grid;
  grid-template-columns: minmax(280px, 340px) minmax(0, 1fr);
  gap: 22px;
  align-items: start;
}

.media-promotion-sidebar,
.media-promotion-main {
  min-width: 0;
  display: grid;
  gap: 16px;
}

.media-promotion-account-card,
.media-promotion-upload-card,
.media-promotion-preset-card,
.media-promotion-history-card,
.media-promotion-log-card,
.media-promotion-wechat-canvas,
.media-promotion-empty-preview,
.media-promotion-process {
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  background: #ffffff;
  box-shadow: 0 12px 30px rgba(15, 23, 42, .055);
}

.media-promotion-account-card {
  min-height: 84px;
  padding: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.media-promotion-account-card strong,
.media-promotion-card-head strong,
.media-promotion-preview-head strong {
  color: #111827;
  font-size: 16px;
  line-height: 1.42;
  font-weight: 850;
}

.media-promotion-account-card i {
  flex: 0 0 auto;
  padding: 6px 10px;
  border: 1px solid #fecdd3;
  border-radius: 999px;
  background: #fff1f2;
  color: #9f1239;
  font-style: normal;
  font-size: 12px;
  font-weight: 850;
}

.media-promotion-upload-card,
.media-promotion-preset-card,
.media-promotion-history-card,
.media-promotion-log-card {
  padding: 16px;
}

.media-promotion-card-head,
.media-promotion-preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.media-promotion-dropzone {
  min-height: 166px;
  padding: 22px 16px;
  border: 1px dashed #d7a5b4;
  border-radius: 14px;
  background:
    linear-gradient(135deg, rgba(159, 18, 57, .055), rgba(11, 92, 158, .045)),
    #fffafa;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 8px;
  color: #64748b;
  text-align: center;
  cursor: pointer;
  transition: border-color 180ms ease, background 180ms ease, transform 180ms ease;
}

.media-promotion-dropzone:hover,
.media-promotion-dropzone.is-dragover {
  border-color: #9f1239;
  background: #fff1f2;
  transform: translateY(-1px);
}

.media-promotion-dropzone input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.media-promotion-dropzone b {
  color: #111827;
  font-size: 17px;
  line-height: 1.4;
  font-weight: 850;
}

.media-promotion-dropzone span,
.media-promotion-upload-note,
.media-promotion-preset-card p {
  margin: 0;
  color: #64748b;
  font-size: 13px;
  line-height: 1.65;
}

.media-promotion-main-btn {
  border-color: transparent;
  background: linear-gradient(135deg, #9f1239 0%, #be123c 48%, #0b5aa2 100%);
  color: #ffffff;
  box-shadow: 0 14px 28px rgba(159, 18, 57, .22);
}

.media-promotion-main-btn:hover:not(:disabled) {
  border-color: transparent;
  background: linear-gradient(135deg, #881337 0%, #9f1239 50%, #0b4f8f 100%);
  transform: translateY(-1px);
  box-shadow: 0 18px 34px rgba(159, 18, 57, .28);
}

.media-promotion-main-btn:disabled {
  border-color: #d7dce3;
  background: #cbd5e1;
  color: #ffffff;
  box-shadow: none;
  cursor: not-allowed;
}

.media-promotion-wechat-btn {
  border-color: transparent;
  background: linear-gradient(135deg, #047857 0%, #059669 54%, #0f766e 100%);
  color: #ffffff;
  font-weight: 800;
  box-shadow: 0 12px 24px rgba(4, 120, 87, .2);
}

.media-promotion-wechat-btn:hover:not(:disabled) {
  background: linear-gradient(135deg, #065f46 0%, #047857 54%, #115e59 100%);
  transform: translateY(-1px);
  box-shadow: 0 16px 30px rgba(4, 120, 87, .26);
}

.media-promotion-wechat-btn:disabled {
  border-color: #d7dce3;
  background: #94a3b8;
  color: #ffffff;
  box-shadow: none;
  cursor: not-allowed;
}

.media-promotion-upload-card .media-promotion-main-btn {
  width: 100%;
  min-height: 44px;
  margin-top: 12px;
}

.media-promotion-upload-note {
  margin-top: 10px;
}

.media-promotion-preset-banner {
  width: 100%;
  display: block;
  border: 1px solid #dbe7f3;
  border-radius: 10px;
  background: #f8fafc;
}

.media-promotion-qr-grid {
  margin: 12px 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.media-promotion-qr-grid img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: contain;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #ffffff;
}

.media-promotion-history-list,
.media-promotion-log-list {
  display: grid;
  gap: 8px;
}

.media-promotion-history-item {
  width: 100%;
  min-width: 0;
  padding: 11px 12px;
  border: 1px solid #eef2f7;
  border-radius: 10px;
  background: #ffffff;
  text-align: left;
  cursor: pointer;
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.media-promotion-history-item:hover {
  border-color: #d7a5b4;
  background: #fff7f9;
  transform: translateY(-1px);
}

.media-promotion-history-item strong {
  display: block;
  color: #111827;
  font-size: 13px;
  line-height: 1.5;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.media-promotion-history-item span,
.media-promotion-history-empty,
.media-promotion-log-empty {
  color: #94a3b8;
  font-size: 12px;
  line-height: 1.5;
}

.media-promotion-history-empty,
.media-promotion-log-empty {
  padding: 16px;
  border: 1px dashed #d8e1ec;
  border-radius: 10px;
  background: #f8fafc;
  text-align: center;
}

.media-promotion-empty-preview {
  min-height: 560px;
  display: grid;
  place-items: center;
  padding: 40px;
  text-align: center;
}

.media-promotion-empty-preview div {
  max-width: 460px;
}

.media-promotion-empty-preview span {
  color: #9f1239;
  font-size: 13px;
  font-weight: 850;
}

.media-promotion-empty-preview strong {
  display: block;
  margin-top: 8px;
  color: #111827;
  font-size: 26px;
  line-height: 1.35;
  font-weight: 850;
}

.media-promotion-empty-preview p {
  margin: 12px 0 0;
  color: #64748b;
  font-size: 14px;
  line-height: 1.75;
}

.media-promotion-process {
  min-height: 560px;
  padding: 42px;
  display: grid;
  grid-template-columns: minmax(220px, .72fr) minmax(0, 1fr);
  gap: 36px;
  align-items: center;
  overflow: hidden;
}

.media-promotion-process-visual {
  min-height: 360px;
  border: 1px solid #dceaf7;
  border-radius: 18px;
  background:
    linear-gradient(90deg, rgba(11, 90, 162, .07) 0 1px, transparent 1px 32px),
    linear-gradient(180deg, #f8fbff 0%, #fff7f9 100%);
  display: grid;
  place-items: center;
  overflow: hidden;
}

.media-promotion-ai-stage {
  position: relative;
  width: min(320px, 90%);
  height: 260px;
  border-radius: 18px;
  background: rgba(255, 255, 255, .78);
  border: 1px solid rgba(148, 163, 184, .35);
  box-shadow: 0 24px 52px rgba(15, 23, 42, .1);
}

.media-promotion-paper-stack span {
  position: absolute;
  left: 58px;
  top: 46px;
  width: 190px;
  height: 126px;
  border-radius: 12px;
  background: #ffffff;
  border: 1px solid #d9e8f8;
  box-shadow: 0 14px 30px rgba(15, 23, 42, .08);
}

.media-promotion-paper-stack span::before,
.media-promotion-paper-stack span::after {
  content: "";
  position: absolute;
  left: 22px;
  right: 22px;
  height: 8px;
  border-radius: 999px;
  background: #e6eef8;
}

.media-promotion-paper-stack span::before { top: 32px; }
.media-promotion-paper-stack span::after { top: 58px; width: 66%; right: auto; }

.media-promotion-paper-stack span:nth-child(1) {
  transform: translate(-16px, 18px) rotate(-7deg);
  opacity: .52;
}

.media-promotion-paper-stack span:nth-child(2) {
  transform: translate(12px, 10px) rotate(5deg);
  opacity: .68;
}

.media-promotion-paper-stack span:nth-child(3) {
  animation: mediaPromotionPaperFloat 2.6s ease-in-out infinite;
}

.media-promotion-scan-line {
  position: absolute;
  left: 48px;
  top: 56px;
  width: 210px;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, #9f1239, #0b5aa2, transparent);
  box-shadow: 0 0 18px rgba(11, 90, 162, .38);
  animation: mediaPromotionScan 2.2s ease-in-out infinite;
}

.media-promotion-node-field {
  position: absolute;
  left: 54px;
  right: 54px;
  bottom: 38px;
  height: 42px;
}

.media-promotion-node-field i {
  position: absolute;
  bottom: 0;
  width: 10px;
  height: 10px;
  border-radius: 3px;
  background: #0b5aa2;
  box-shadow: 0 0 0 5px rgba(11, 90, 162, .08);
  animation: mediaPromotionNodePulse 1.8s ease-in-out infinite;
}

.media-promotion-node-field i:nth-child(1) { left: 0; animation-delay: 0s; }
.media-promotion-node-field i:nth-child(2) { left: 24%; background: #9f1239; animation-delay: .2s; }
.media-promotion-node-field i:nth-child(3) { left: 48%; animation-delay: .4s; }
.media-promotion-node-field i:nth-child(4) { left: 72%; background: #9f1239; animation-delay: .6s; }
.media-promotion-node-field i:nth-child(5) { right: 0; animation-delay: .8s; }

.media-promotion-image-badge {
  position: absolute;
  right: 22px;
  top: 22px;
  padding: 7px 11px;
  border-radius: 999px;
  background: #fff1f2;
  border: 1px solid #fecdd3;
  color: #9f1239;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .02em;
  animation: mediaPromotionBadgeGlow 2.4s ease-in-out infinite;
}

@keyframes mediaPromotionPaperFloat {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(0, -8px); }
}

@keyframes mediaPromotionScan {
  0%, 100% { transform: translateY(0); opacity: .35; }
  50% { transform: translateY(104px); opacity: 1; }
}

@keyframes mediaPromotionNodePulse {
  0%, 100% { transform: translateY(0) scale(1); opacity: .6; }
  50% { transform: translateY(-18px) scale(1.18); opacity: 1; }
}

@keyframes mediaPromotionBadgeGlow {
  0%, 100% { box-shadow: 0 0 0 rgba(159, 18, 57, 0); }
  50% { box-shadow: 0 10px 22px rgba(159, 18, 57, .18); }
}

.media-promotion-process-main span {
  color: #9f1239;
  font-size: 13px;
  font-weight: 850;
}

.media-promotion-process-main strong {
  display: block;
  margin-top: 8px;
  color: #111827;
  font-size: 30px;
  line-height: 1.3;
  font-weight: 880;
}

.media-promotion-process-main p {
  margin: 12px 0 22px;
  color: #64748b;
  font-size: 14px;
  line-height: 1.75;
}

.media-promotion-progress-track {
  height: 10px;
  overflow: hidden;
  border-radius: 999px;
  background: #e8edf3;
}

.media-promotion-progress-track i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #9f1239, #be123c, #0b5aa2);
  transition: width 280ms ease;
}

.media-promotion-progress-meta {
  margin-top: 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #64748b;
  font-size: 13px;
}

.media-promotion-progress-meta b {
  color: #9f1239;
}

.media-promotion-step-list {
  margin-top: 18px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
}

.media-promotion-step {
  min-width: 0;
  padding: 10px 10px 10px 12px;
  border: 1px solid #e5edf6;
  border-radius: 12px;
  background: #f8fafc;
  display: grid;
  grid-template-columns: 12px minmax(0, 1fr) auto;
  gap: 9px;
  align-items: center;
}

.media-promotion-step i {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: #cbd5e1;
  box-shadow: 0 0 0 4px rgba(148, 163, 184, .14);
}

.media-promotion-step strong,
.media-promotion-step span,
.media-promotion-step em {
  display: block;
  line-height: 1.35;
}

.media-promotion-step strong {
  color: #1e293b;
  font-size: 13px;
  font-weight: 850;
}

.media-promotion-step span {
  margin-top: 2px;
  color: #64748b;
  font-size: 12px;
}

.media-promotion-step em {
  color: #94a3b8;
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
  white-space: nowrap;
}

.media-promotion-step.is-active {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.media-promotion-step.is-active i {
  background: #2563eb;
  box-shadow: 0 0 0 5px rgba(37, 99, 235, .13);
  animation: mediaPromotionStepPulse 1.35s ease-in-out infinite;
}

.media-promotion-step.is-active em {
  color: #1d4ed8;
}

.media-promotion-step.is-done {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.media-promotion-step.is-done i {
  background: #16a34a;
  box-shadow: 0 0 0 4px rgba(22, 163, 74, .12);
}

.media-promotion-step.is-done em {
  color: #15803d;
}

@keyframes mediaPromotionStepPulse {
  0%, 100% { transform: scale(1); opacity: .75; }
  50% { transform: scale(1.25); opacity: 1; }
}

.media-promotion-wechat-canvas {
  overflow: hidden;
}

.media-promotion-preview-head {
  margin: 0;
  padding: 18px 22px;
  border-bottom: 1px solid #eef2f7;
  background: linear-gradient(180deg, #ffffff, #fbfdff);
}

.media-promotion-preview-head strong {
  display: block;
  margin-top: 4px;
  font-size: 18px;
  overflow-wrap: anywhere;
}

.media-promotion-preview-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.media-promotion-account-switch {
  padding: 4px;
  border: 1px solid #d8e1ec;
  border-radius: 14px;
  background: #f8fafc;
  display: flex;
  gap: 4px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .85);
}

.media-promotion-account-switch button {
  min-height: 46px;
  min-width: 168px;
  position: relative;
  padding: 8px 14px 8px 34px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: transparent;
  color: #475569;
  cursor: pointer;
  text-align: left;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease, box-shadow 160ms ease;
}

.media-promotion-account-switch button::before {
  content: "";
  position: absolute;
  left: 13px;
  top: 50%;
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: #94a3b8;
  box-shadow: 0 0 0 4px rgba(148, 163, 184, .16);
  transform: translateY(-50%);
}

.media-promotion-account-switch button:hover {
  background: #ffffff;
  border-color: #cbd5e1;
}

.media-promotion-account-switch button.is-active {
  background: #ffffff;
  border-color: rgba(159, 18, 57, .28);
  color: #0f172a;
  box-shadow: 0 8px 18px rgba(15, 23, 42, .08);
}

.media-promotion-account-switch button.is-active::before {
  background: #9f1239;
  box-shadow: 0 0 0 4px rgba(159, 18, 57, .13);
}

.media-promotion-account-switch strong,
.media-promotion-account-switch span {
  display: block;
  white-space: nowrap;
}

.media-promotion-account-switch strong {
  font-size: 13px;
  line-height: 1.25;
  font-weight: 850;
}

.media-promotion-account-switch span {
  margin-top: 2px;
  font-size: 11px;
  line-height: 1.2;
  opacity: .9;
}

.media-promotion-cover-preview {
  margin: 0;
  padding: 22px 24px 24px;
  border-bottom: 1px solid #eef2f7;
  background:
    linear-gradient(135deg, rgba(185, 28, 28, .075), rgba(11, 90, 162, .07)),
    #fbfdff;
}

.media-promotion-cover-preview div {
  margin-bottom: 12px;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
}

.media-promotion-cover-preview span {
  color: #be123c;
  font-size: 12px;
  font-weight: 850;
  letter-spacing: .08em;
}

.media-promotion-cover-preview strong {
  color: #334155;
  font-size: 13px;
  line-height: 1.45;
  font-weight: 750;
}

.media-promotion-cover-preview img {
  display: block;
  width: min(100%, 820px);
  aspect-ratio: 16 / 9;
  object-fit: cover;
  margin: 0 auto;
  border: 1px solid #cbd5e1;
  border-radius: 14px;
  background: #ffffff;
  box-shadow: 0 18px 38px rgba(15, 23, 42, .14);
}

.media-promotion-meta-row {
  padding: 14px 22px;
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 6px 12px;
  border-bottom: 1px solid #eef2f7;
  background: #fbfdff;
}

.media-promotion-meta-row span {
  color: #9f1239;
  font-size: 12px;
  font-weight: 850;
}

.media-promotion-meta-row p {
  margin: 0;
  color: #475569;
  font-size: 13px;
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.media-promotion-wechat-article {
  max-width: 860px;
  margin: 0 auto;
  padding: 28px 40px 38px;
  background: #ffffff;
  overflow-wrap: anywhere;
}

.media-promotion-wechat-article img {
  max-width: 100%;
  height: auto;
}

.media-promotion-log-card {
  box-shadow: none;
}

.media-promotion-log-item {
  display: grid;
  grid-template-columns: 72px 58px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
  padding: 9px 10px;
  border: 1px solid #eef2f7;
  border-radius: 10px;
  background: #ffffff;
}

.media-promotion-log-item span,
.media-promotion-log-item strong,
.media-promotion-log-item em {
  font-size: 12px;
  line-height: 1.45;
}

.media-promotion-log-item span {
  color: #94a3b8;
}

.media-promotion-log-item strong {
  color: #64748b;
}

.media-promotion-log-item em {
  color: #334155;
  font-style: normal;
  overflow-wrap: anywhere;
}

.media-promotion-log-item small {
  display: block;
  margin-top: 3px;
  color: #64748b;
}

.media-promotion-log-item.is-active strong { color: #0b5aa2; }
.media-promotion-log-item.is-done strong { color: #047857; }
.media-promotion-log-item.is-warn strong { color: #b45309; }
.media-promotion-log-item.is-error strong { color: #b91c1c; }

@media (max-width: 1180px) {
  .media-promotion-shell,
  .media-promotion-process {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 760px) {
  .media-promotion-page {
    padding: 18px 14px 28px;
  }

  .media-promotion-title-card,
  .media-promotion-preview-head {
    align-items: stretch;
    flex-direction: column;
  }

  .media-promotion-sidebar {
    grid-template-columns: 1fr;
  }

  .media-promotion-process,
  .media-promotion-empty-preview {
    min-height: 420px;
    padding: 24px 18px;
  }

  .media-promotion-process-visual {
    min-height: 220px;
  }

  .media-promotion-wechat-article {
    padding: 22px 18px 28px;
  }

  .media-promotion-step-list,
  .media-promotion-account-switch {
    grid-template-columns: 1fr;
  }

  .media-promotion-step-list {
    grid-template-columns: 1fr;
  }

  .media-promotion-account-switch {
    width: 100%;
    display: grid;
  }

  .media-promotion-account-switch button {
    min-width: 0;
  }

  .media-promotion-preview-actions {
    justify-content: stretch;
  }

  .media-promotion-preview-actions > .btn,
  .media-promotion-preview-actions > button {
    width: 100%;
  }

  .media-promotion-log-item {
    grid-template-columns: 1fr;
  }
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  font-family: "Noto Sans SC", "Microsoft YaHei", system-ui, sans-serif;
  background: var(--bg);
  color: var(--text-main);
}

.hidden { display: none !important; }

/* 兼容你之前用过的 tailwind 类（不依赖 tailwind） */
.w-full { width: 100%; }
.justify-center { justify-content: center; }

/* =====================
   登录页
===================== */
.login-page {
  min-height: 100vh;
  background: linear-gradient(135deg, #7b1333, #b01f48);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.login-card {
  width: 420px;
  max-width: 92vw;
  background: #fff;
  border-radius: var(--radius);
  padding: 40px 36px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35);
  margin: auto 0;
}

.login-logo {
  margin-bottom: 26px;
}

.brand-lockup {
  display: flex;
  align-items: center;
}

.brand-mark {
  display: block;
  flex: 0 0 auto;
  object-fit: contain;
}

.brand-lockup-login {
  justify-content: center;
  gap: 12px;
}

.brand-lockup-login .brand-mark {
  width: 42px;
  height: 42px;
}

.login-logo h1 {
  margin: 0;
  text-align: left;
  font-family: "Noto Sans SC", "Microsoft YaHei", system-ui, sans-serif;
  color: var(--primary);
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.35;
  white-space: nowrap;
}

.login-logo p {
  text-align: center;
  color: #777;
  margin: 8px 0 26px;
  font-size: 14px;
}

.login-hint {
  margin-top: 16px;
  background: #fafafa;
  border: 1px dashed var(--border);
  padding: 12px;
  border-radius: 10px;
  font-size: 12px;
  color: #666;
}

.site-footer {
  width: 100%;
  text-align: center;
  font-size: 12px;
  line-height: 1.6;
}

.site-footer a {
  color: var(--text-muted);
  text-decoration: none;
}

.site-footer a:hover {
  text-decoration: underline;
}

.login-footer {
  color: rgba(255, 255, 255, .82);
  padding-top: 18px;
}

.login-footer a {
  color: rgba(255, 255, 255, .9);
}

.main-footer {
  padding: 4px 24px 8px;
}

/* =====================
   表单
===================== */
.form-group { margin-bottom: 18px; }

.form-label {
  display: block;
  margin-bottom: 6px;
  font-weight: 600;
  font-size: 14px;
}

.form-input,
select.form-input,
textarea.form-input {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid var(--border);
  font-size: 14px;
  background: #fff;
  color: var(--text-main);
}

textarea.form-input { resize: vertical; }

.form-input:focus,
select.form-input:focus,
textarea.form-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(139, 21, 56, 0.12);
}

.password-input-wrap {
  position: relative;
  width: 100%;
}

.password-input-wrap .form-input {
  padding-right: 48px;
}

.password-visibility-toggle {
  position: absolute;
  top: 50%;
  right: 8px;
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transform: translateY(-50%);
  padding: 0;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: #64748b;
  cursor: pointer;
}

.password-visibility-toggle:hover,
.password-visibility-toggle:focus-visible {
  background: #f1f5f9;
  color: var(--primary);
}

.password-visibility-toggle:focus-visible {
  outline: 2px solid rgba(139, 21, 56, .35);
  outline-offset: 1px;
}

.password-eye-icon {
  width: 19px;
  height: 19px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.password-eye-hide,
.password-visibility-toggle[aria-pressed="true"] .password-eye-show {
  display: none;
}

.password-visibility-toggle[aria-pressed="true"] .password-eye-hide {
  display: block;
}

/* =====================
   按钮
===================== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 16px;
  border-radius: 10px;
  border: 1px solid transparent;
  font-size: 14px;
  cursor: grab;
  user-select: none;
  text-decoration: none;
  line-height: 1;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
}

.btn-primary:hover { background: var(--primary-dark); }

.btn-secondary {
  background: #f1f1f1;
  color: #333;
  border-color: #e6e6e6;
}

.btn-secondary:hover { background: #e5e5e5; }

.viewer-ai-fill-action {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
}

.viewer-ai-fill-btn {
  padding: 10px 18px !important;
  border-radius: 999px;
  border: 1px solid rgba(37, 99, 235, 0.22);
  background: linear-gradient(135deg, #0f766e 0%, #2563eb 100%);
  color: #fff;
  box-shadow: 0 10px 24px rgba(37, 99, 235, 0.24);
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
}

.viewer-ai-fill-btn:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 14px 30px rgba(37, 99, 235, 0.30);
}

.viewer-ai-fill-btn:disabled {
  cursor: wait;
  opacity: 0.78;
}

.viewer-ai-fill-hint {
  color: #2563eb;
  font-size: 12px;
  font-weight: 700;
}

.btn-danger {
  background: #fdecea;
  color: var(--danger);
  border-color: #f6c3bf;
}

.btn-danger:hover {
  background: #fbd7d3;
}

/* =====================
   顶部导航
===================== */
.top-nav {
  height: 64px;
  background: var(--primary);
  color: #fff;
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 50;
}

.nav-content {
  height: 100%;
  width: 100%;
  max-width: none;      /* ✅ 铺满屏幕 */
  margin: 0;            /* ✅ 不再居中留白 */
  padding: 0 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.nav-brand h1 {
  font-size: 18px;
  margin: 0;
}

.brand-lockup-nav {
  gap: 8px;
  color: #fff;
}

.brand-lockup-nav .brand-mark {
  width: 30px;
  height: 30px;
}

.brand-lockup-nav h1 {
  white-space: nowrap;
}

.nav-brand span {
  font-size: 13px;
  opacity: 0.9;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.nav-user {
  font-size: 14px;
  opacity: 0.95;
  white-space: nowrap;
}

/* 消息按钮 */
.message-btn {
  position: relative;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.22);
  color: #fff;
  padding: 8px 12px;
  border-radius: 999px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.message-btn:hover {
  background: rgba(255, 255, 255, 0.24);
}

.badge {
  position: absolute;
  top: -6px;
  right: -6px;
  background: var(--danger);
  color: #fff;
  font-size: 12px;
  padding: 2px 7px;
  border-radius: 999px;
  min-width: 20px;
  text-align: center;
}

/* 表格中的 badge 需要恢复为普通文档流，避免“待改版”徽标发生偏移 */
.manuscript-table .badge,
.data-table .badge {
  position: static !important;
  top: auto !important;
  right: auto !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  min-width: auto;
  line-height: 1.2;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  vertical-align: middle;
}

/* =====================
   标签页导航
===================== */
.tab-nav {
  background: #fff;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 64px;
  z-index: 40;
  box-shadow: 0 1px 4px rgba(0,0,0,.04);
}

.tab-nav-content {
  width: 100%;
  max-width: none;
  margin: 0;
  display: flex;
  gap: 2px;
  padding: 0 16px;
  overflow-x: auto;
}

.tab-nav-content::-webkit-scrollbar { height: 6px; }
.tab-nav-content::-webkit-scrollbar-track { background: transparent; }
.tab-nav-content::-webkit-scrollbar-thumb { background: #ddd; border-radius: 999px; }

.tab-btn {
  padding: 12px 18px;
  font-size: 13px;
  font-weight: 500;
  border: none;
  background: transparent;
  cursor: pointer;
  color: #6b7280;
  white-space: nowrap;
  position: relative;
  transition: all .2s ease;
  border-radius: 8px 8px 0 0;
  letter-spacing: .3px;
}

.tab-btn:hover {
  color: var(--primary);
  background: rgba(139, 21, 56, .06);
}

.tab-btn.active {
  color: var(--primary);
  font-weight: 700;
  background: rgba(139, 21, 56, .08);
}
.tab-btn.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 12px;
  right: 12px;
  height: 3px;
  background: var(--primary);
  border-radius: 3px 3px 0 0;
}

/* =====================
   主内容区
===================== */
.main-content {
  width: 100%;
  max-width: none;      /* ✅ 铺满屏幕 */
  margin: 14px 0 4px;   /* ✅ 只保留必要上下间距 */
  padding: 0 24px 14px; /* ✅ 减少底部空白 */
}

.inline-loader-spinner {
  width: 18px;
  height: 18px;
  border: 2px solid #e5e7eb;
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: inlineSpin .8s linear infinite;
  flex: 0 0 auto;
}

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

#workspaceGuideLauncher,
#workspaceGuidePageBtn,
#workspaceGuideMask,
#workspaceGuideSpotlight,
#workspaceGuidePanel,
#ratingGuideBtn,
#ratingGuideMask,
#ratingGuideSpotlight,
#ratingGuidePanel {
  display: none !important;
}

/* =====================
   卡片
===================== */
.card {
  background: var(--card-bg);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
  margin-bottom: 18px;
  overflow: hidden;
}

.card-title {
  font-size: 18px;
  margin-bottom: 12px;
  font-weight: 700;
}

/* =====================
   表格（美观 & 显示稳定）
   - 容器横向滚动
   - 默认所有列 1 行省略号
   - 仅【题目】列最多 2 行（不再叠加多个补丁，统一在这里）
===================== */
.table-wrapper {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--border);
  border-radius: 12px;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 1400px;     /* 字段多，保证不挤压 */
  background: #fff;
  table-layout: fixed;   /* 关键：列宽稳定，不会“忽宽忽窄” */
}

thead {
  background: #f3f4f6;
  position: sticky;
  top: 0;
  z-index: 1;
}

th,
td {
  padding: 2px 4px;
  border-bottom: 1px solid var(--border);
  text-align: left;
  font-size: 13px;
  vertical-align: middle;

  /* 默认：所有列 1 行 */
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;

  /* 给一点上限，避免个别列过宽（table-layout:fixed 下主要靠列宽分配） */
  max-width: 360px;
  line-height: 1.3;
}

th {
  font-weight: 700;
  color: #444;
}

tbody tr:hover {
  background: #fafafa;
}

/* 本文编辑工作台表格行高优化 */
.editor-workspace-container .manuscript-table th,
.editor-workspace-container .manuscript-table td {
  line-height: 1.2;
  padding: 5px 8px;
}

.editor-workspace-container .manuscript-table thead th {
  text-align: center !important;
}

.editor-workspace-container .editor-workspace-compact-table-wrapper {
  width: 100%;
  overflow-x: hidden !important;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #fff;
}

.editor-workspace-container .editor-workspace-compact-table {
  width: 100% !important;
  min-width: 0 !important;
  border-collapse: collapse;
  table-layout: fixed !important;
  background: #fff;
}

.editor-workspace-container .editor-workspace-compact-table th,
.editor-workspace-container .editor-workspace-compact-table td {
  white-space: normal !important;
  word-break: break-word !important;
  overflow-wrap: anywhere !important;
  vertical-align: middle;
}

.editor-workspace-container .editor-workspace-compact-table .editor-workspace-seq-cell,
.editor-workspace-container .editor-workspace-compact-table .editor-workspace-status-cell,
.editor-workspace-container .editor-workspace-compact-table .editor-workspace-action-cell {
  text-align: center;
}

.editor-workspace-container .editor-workspace-compact-table .editor-workspace-seq-cell {
  font-weight: 600;
  color: #6b7280;
}

.editor-workspace-container .editor-workspace-compact-table .editor-workspace-action-cell .btn {
  white-space: nowrap !important;
}

.editor-workspace-container .editor-workspace-compact-table .editor-workspace-edit-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 78px;
  padding: 7px 12px;
  cursor: pointer;
}

.editor-workspace-container .editor-workspace-compact-table .editor-workspace-title-cell .title-cell {
  white-space: normal !important;
  word-break: break-word !important;
  overflow-wrap: anywhere !important;
  line-height: 1.45;
}

.editor-workspace-title-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.editor-toolbox-trigger {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 16px;
  border: 1px solid rgba(139, 21, 56, 0.2);
  border-radius: 999px;
  background: linear-gradient(135deg, #8b1538 0%, #a51d45 100%);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(139, 21, 56, 0.2);
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, border-color 0.18s ease;
}

.editor-toolbox-trigger:hover,
.editor-toolbox-trigger:focus-visible {
  transform: translateY(-1px);
  border-color: rgba(139, 21, 56, 0.2);
  background: linear-gradient(135deg, #98183f 0%, #b52450 100%);
  box-shadow: 0 14px 28px rgba(139, 21, 56, 0.26);
  outline: none;
}

.editor-toolbox-trigger:active { transform: translateY(0); }

.editor-toolbox-trigger-icon,
.editor-toolbox-title-icon,
.editor-toolbox-card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
}

.editor-toolbox-trigger-icon .editor-toolbox-emoji {
  display: inline-block;
  font-size: 21px;
  line-height: 1;
  transform: translateY(-.5px);
}

.editor-toolbox-trigger svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.editor-toolbox-modal {
  align-items: center;
}

.editor-toolbox-dialog {
  width: min(840px, 94vw);
  max-height: 88vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.25);
  border: 1px solid rgba(226, 232, 240, 0.9);
}

.editor-toolbox-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 22px 24px 18px;
  background:
    linear-gradient(135deg, rgba(139, 21, 56, 0.08), rgba(8, 145, 178, 0.08)),
    #fff;
  border-bottom: 1px solid #e5e7eb;
}

.editor-toolbox-title-block {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.editor-toolbox-title-icon {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: #fff;
  color: var(--primary);
  border: 1px solid rgba(139, 21, 56, 0.16);
  box-shadow: 0 10px 22px rgba(139, 21, 56, 0.12);
}

.editor-toolbox-title-icon svg {
  width: 22px;
  height: 22px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.editor-toolbox-title-block h3 {
  margin: 0;
  color: #111827;
  font-size: 21px;
  font-weight: 800;
}

.editor-toolbox-title-block p {
  margin: 5px 0 0;
  color: #64748b;
  font-size: 13px;
  line-height: 1.5;
}

.editor-toolbox-close {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.82);
  color: #64748b;
  cursor: pointer;
  transition: all 0.18s ease;
}

.editor-toolbox-close svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.editor-toolbox-close:hover,
.editor-toolbox-close:focus-visible {
  background: #fff1f2;
  color: var(--primary);
  border-color: rgba(139, 21, 56, 0.25);
  outline: none;
}

.editor-toolbox-body {
  padding: 22px 24px 10px;
  overflow-y: auto;
}

.editor-toolbox-section + .editor-toolbox-section {
  margin-top: 22px;
}

.editor-toolbox-section-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.editor-toolbox-section-title span {
  color: #1f2937;
  font-size: 15px;
  font-weight: 800;
}

.editor-toolbox-section-title small {
  color: #94a3b8;
  font-size: 12px;
}

.editor-toolbox-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.editor-toolbox-grid-compact {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.editor-toolbox-card {
  min-height: 132px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  width: 100%;
  padding: 16px;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  background: #fff;
  text-align: left;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}

.editor-toolbox-card:hover,
.editor-toolbox-card:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(139, 21, 56, 0.28);
  box-shadow: 0 16px 34px rgba(15, 23, 42, 0.12);
  outline: none;
}

.editor-toolbox-card.is-disabled {
  cursor: not-allowed;
  opacity: 0.68;
  background: #f8fafc;
  box-shadow: none;
}

.editor-toolbox-card.is-disabled:hover {
  transform: none;
  border-color: #e2e8f0;
}

.editor-toolbox-card-icon {
  width: 42px;
  height: 42px;
  border-radius: 13px;
  background: #fdf2f8;
  color: var(--primary);
  border: 1px solid rgba(139, 21, 56, 0.1);
}

.editor-toolbox-card:nth-child(2) .editor-toolbox-card-icon {
  background: #fff7ed;
  color: #b45309;
}

.editor-toolbox-card-icon svg {
  width: 21px;
  height: 21px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.editor-toolbox-card-main {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.editor-toolbox-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.editor-toolbox-card-top strong {
  color: #111827;
  font-size: 15px;
  font-weight: 800;
  line-height: 1.35;
}

.editor-toolbox-card-top em {
  flex: 0 0 auto;
  padding: 3px 8px;
  border-radius: 999px;
  background: #ecfeff;
  color: #0e7490;
  font-style: normal;
  font-size: 11px;
  font-weight: 800;
}

.editor-toolbox-card-top em.is-muted {
  background: #f1f5f9;
  color: #64748b;
}

.editor-toolbox-card-desc,
.editor-toolbox-card-hint {
  color: #64748b;
  font-size: 13px;
  line-height: 1.55;
}

.editor-toolbox-card-hint {
  margin: 0;
  color: #8b5a6a;
}

.editor-toolbox-footer {
  display: flex;
  justify-content: flex-end;
  padding: 14px 24px 20px;
  border-top: 1px solid #e5e7eb;
  background: #fff;
}

.reference-format-modal {
  align-items: center;
}

.reference-format-modal.is-minimized {
  display: none;
}

.reference-format-header {
  position: relative;
  padding-right: 116px;
}

.reference-format-header .editor-toolbox-close,
.reference-format-minimize {
  position: absolute;
  top: 20px;
}

.reference-format-header .editor-toolbox-close {
  right: 24px;
}

.reference-format-minimize {
  right: 66px;
  border: 0;
  background: transparent;
  color: #526375;
  border-radius: 7px;
  min-width: 70px;
  height: 36px;
  padding: 0 10px;
  font: inherit;
  font-size: 14px;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.reference-format-minimize:hover {
  color: var(--primary);
  background: rgba(255, 255, 255, 0.72);
}

.reference-format-dialog {
  width: min(980px, 94vw);
  max-height: 88vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.25);
  border: 1px solid rgba(226, 232, 240, 0.9);
}

.reference-format-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  position: relative;
  padding: 22px 24px 18px;
  padding-right: 116px;
  background:
    linear-gradient(135deg, rgba(139, 21, 56, 0.08), rgba(14, 116, 144, 0.08)),
    #fff;
  border-bottom: 1px solid #e5e7eb;
}

.reference-format-rules {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 14px 24px;
  background: #f8fafc;
  border-bottom: 1px solid #e5e7eb;
}

.reference-format-rules span {
  padding: 6px 10px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid #e2e8f0;
  color: #475569;
  font-size: 12px;
  font-weight: 700;
}

.reference-format-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 18px;
  padding: 20px 24px;
  overflow-y: auto;
  background: #fff;
}

.reference-format-body-single {
  grid-template-columns: minmax(0, 1fr);
}

.reference-format-panel {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.reference-format-panel-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.reference-format-panel-title label {
  color: #1f2937;
  font-size: 15px;
  font-weight: 800;
}

.reference-format-panel-title button {
  min-height: 34px;
  padding: 6px 12px;
  border: 1px solid #e2e8f0;
  border-radius: 9px;
  background: #f8fafc;
  color: #475569;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.18s ease;
}

.reference-format-panel-title button:hover,
.reference-format-panel-title button:focus-visible {
  background: #fff1f2;
  color: var(--primary);
  border-color: rgba(139, 21, 56, 0.24);
  outline: none;
}

.reference-format-textarea {
  width: 100%;
  min-height: 360px;
  resize: vertical;
  padding: 14px;
  border: 1px solid #dbe3ef;
  border-radius: 14px;
  background: #fff;
  color: #111827;
  font-size: 13px;
  line-height: 1.75;
  font-family: "Noto Sans SC", "Microsoft YaHei", system-ui, sans-serif;
  outline: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.reference-format-input-textarea {
  min-height: 520px;
}

.reference-word-dropzone {
  min-height: 260px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 10px;
  padding: 28px;
  border: 1.5px dashed #cbd5e1;
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(139, 21, 56, 0.035), rgba(14, 116, 144, 0.05)),
    #fff;
  color: #475569;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease, background 0.18s ease;
}

.reference-word-dropzone:hover,
.reference-word-dropzone.is-dragging {
  border-color: rgba(139, 21, 56, 0.45);
  background:
    linear-gradient(135deg, rgba(139, 21, 56, 0.07), rgba(14, 116, 144, 0.07)),
    #fff;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.1);
  transform: translateY(-1px);
}

.reference-word-dropzone.has-file {
  border-style: solid;
  border-color: rgba(14, 116, 144, 0.36);
  background:
    linear-gradient(135deg, rgba(236, 254, 255, 0.85), rgba(255, 241, 242, 0.72)),
    #fff;
}

.reference-word-dropzone-icon {
  width: 54px;
  height: 54px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  background: #fff;
  color: var(--primary);
  border: 1px solid rgba(139, 21, 56, 0.14);
  box-shadow: 0 14px 30px rgba(139, 21, 56, 0.12);
}

.reference-word-dropzone-icon svg {
  width: 27px;
  height: 27px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.reference-word-dropzone strong {
  color: #0f172a;
  font-size: 19px;
  font-weight: 900;
}

.reference-word-dropzone span {
  max-width: 620px;
  color: #64748b;
  font-size: 13px;
  line-height: 1.7;
}

.reference-word-dropzone em {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  max-width: 100%;
  padding: 5px 10px;
  border-radius: 999px;
  background: #f8fafc;
  color: #475569;
  border: 1px solid #e2e8f0;
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
  word-break: break-all;
}

.reference-format-modal.is-checking .reference-format-input-textarea {
  min-height: 300px;
}

.reference-format-modal.is-checking .reference-format-rules,
.reference-format-modal.is-checking .reference-format-footer {
  display: none;
}

.reference-format-modal.is-checking .reference-format-dialog {
  width: min(1180px, 96vw);
  max-height: 92vh;
}

.reference-format-modal.is-reference-completed .reference-format-dialog {
  width: min(980px, 94vw);
  max-height: 78vh;
}

.reference-format-modal.is-reference-completed .reference-format-header {
  padding: 18px 22px 15px;
}

.reference-format-modal.is-reference-completed .editor-toolbox-title-icon {
  width: 48px;
  height: 48px;
}

.reference-format-body-running {
  min-height: min(72vh, 680px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 28px;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(139, 21, 56, 0.045), rgba(14, 116, 144, 0.055)),
    #fff;
}

.reference-format-body-complete {
  min-height: auto;
  display: block;
  padding: 16px 22px 20px;
  overflow: visible;
  background: #fff;
}

.reference-format-body-complete .reference-check-running-stage,
.reference-format-body-complete .reference-check-completed-stage {
  width: 100%;
  min-height: 0;
  display: block;
}

.reference-format-body-complete .reference-format-report {
  min-height: 0;
}

.reference-check-running-stage {
  width: min(1040px, 100%);
  min-height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.reference-check-running-stage .reference-format-report {
  width: 100%;
  flex: 1 1 auto;
  min-width: 0;
}

.reference-format-textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(139, 21, 56, 0.12);
}

.reference-format-output {
  background: #f8fafc;
}

.reference-format-checkbox {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #475569;
  font-size: 13px;
  font-weight: 700;
}

.reference-format-checkbox input {
  width: 16px;
  height: 16px;
  accent-color: var(--primary);
}

.reference-format-report {
  min-height: 44px;
}

.reference-format-report-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #f8fafc;
}

.reference-format-report-summary strong {
  color: #1f2937;
  font-size: 13px;
}

.reference-format-report-summary div {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.reference-format-report-summary span {
  padding: 3px 8px;
  border-radius: 999px;
  background: #ecfeff;
  color: #0e7490;
  font-size: 11px;
  font-weight: 800;
}

.reference-format-warnings {
  margin-top: 8px;
  display: grid;
  gap: 6px;
}

.reference-format-warnings p {
  margin: 0;
  padding: 8px 10px;
  border-radius: 10px;
  background: #fff7ed;
  border: 1px solid #fed7aa;
  color: #9a3412;
  font-size: 12px;
  line-height: 1.45;
}

.reference-format-ok {
  margin-top: 8px;
  padding: 8px 10px;
  border-radius: 10px;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  color: #166534;
  font-size: 12px;
  font-weight: 700;
}

.reference-format-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 24px 20px;
  border-top: 1px solid #e5e7eb;
  background: #fff;
}

.reference-format-footer > div {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.smart-revision-modal {
  align-items: center;
}

.smart-revision-modal.is-minimized {
  display: none;
}

.smart-revision-dialog {
  width: min(860px, 94vw);
  max-height: 82vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid #dfe7f1;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.25);
}

.smart-revision-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 16px 20px;
  border-bottom: 1px solid #e5e7eb;
  background: #fff;
}

.smart-revision-header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.smart-revision-minimize-btn {
  width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  padding: 0;
  border: 1px solid #cbd5e1;
  border-radius: 7px;
  background: #fff;
  color: #475569;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.smart-revision-minimize-btn svg,
.smart-revision-progress-minimize svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
}

.smart-revision-minimize-btn:hover:not(:disabled) {
  border-color: #0e7490;
  color: #0e7490;
  background: #f0fdfa;
}

.smart-revision-minimize-btn:disabled {
  cursor: not-allowed;
  opacity: .45;
}

.smart-revision-rules,
.smart-revision-scope,
.smart-revision-pipeline {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.smart-revision-rules {
  padding: 10px 22px;
  border-bottom: 1px solid #e5e7eb;
  background: #f8fafc;
}

.smart-revision-rules span,
.smart-revision-scope span,
.smart-revision-pipeline span {
  padding: 4px 8px;
  border: 1px solid #dce5ef;
  border-radius: 999px;
  background: #fff;
  color: #475569;
  font-size: 11px;
  font-weight: 700;
}

.smart-revision-body {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  overflow: hidden;
  background: #f8fafc;
}

.smart-revision-upload-panel,
.smart-revision-result-panel {
  min-width: 0;
  overflow-y: auto;
  padding: 18px;
}

.smart-revision-upload-panel {
  display: flex;
  flex-direction: column;
  gap: 12px;
  border-bottom: 1px solid #e5e7eb;
  background: #fff;
}

.smart-revision-upload-title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.smart-revision-upload-title strong {
  display: block;
  color: #172033;
  font-size: 15px;
}

.smart-revision-upload-title span {
  display: block;
  margin-top: 5px;
  color: #64748b;
  font-size: 12px;
  line-height: 1.5;
}

.smart-revision-upload-title button {
  flex: 0 0 auto;
  min-height: 32px;
  padding: 5px 10px;
  border: 1px solid #d8e1ec;
  border-radius: 8px;
  background: #fff;
  color: #475569;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.smart-revision-dropzone {
  min-height: 128px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 9px;
  padding: 18px;
  border: 1.5px dashed #c5d2e0;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(139, 21, 56, 0.035), rgba(14, 116, 144, 0.04)), #fff;
  text-align: center;
  color: #64748b;
  cursor: pointer;
  transition: border-color .18s ease, background .18s ease, box-shadow .18s ease;
}

.smart-revision-file-summary { display: none; }

.smart-revision-dialog.is-result-ready .smart-revision-body {
  display: block;
  overflow-y: auto;
}

.smart-revision-dialog.is-result-ready .smart-revision-upload-panel {
  display: block;
  padding: 12px 20px;
  overflow: visible;
  border-bottom: 1px solid #e5e7eb;
}

.smart-revision-dialog.is-result-ready .smart-revision-upload-title,
.smart-revision-dialog.is-result-ready .smart-revision-dropzone { display: none; }

.smart-revision-dialog.is-result-ready .smart-revision-file-summary {
  display: flex;
  align-items: center;
  gap: 10px;
}

.smart-revision-file-summary > span {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border: 1px solid #f0c6d3;
  border-radius: 6px;
  background: #fff7fa;
  color: var(--primary);
}

.smart-revision-file-summary svg { width: 17px; height: 17px; }

.smart-revision-file-summary > div { min-width: 0; display: grid; gap: 2px; }
.smart-revision-file-summary small { color: #94a3b8; font-size: 11px; }
.smart-revision-file-summary strong { overflow: hidden; color: #334155; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }

.smart-revision-file-summary button {
  margin-left: auto;
  padding: 4px 7px;
  border: 0;
  background: transparent;
  color: #0f766e;
  font-size: 12px;
  cursor: pointer;
}

.smart-revision-file-summary button:hover { text-decoration: underline; }

.smart-revision-dropzone:hover,
.smart-revision-dropzone.is-dragging {
  border-color: rgba(139, 21, 56, .55);
  background: #fff7fa;
  box-shadow: 0 12px 26px rgba(15, 23, 42, .08);
}

.smart-revision-dropzone.has-file {
  border-style: solid;
  border-color: rgba(14, 116, 144, .4);
  background: #f0fdfa;
}

.smart-revision-dropzone-icon {
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(139, 21, 56, .12);
  border-radius: 12px;
  background: #fff;
  color: var(--primary);
}

.smart-revision-dropzone-icon svg {
  width: 23px;
  height: 23px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.9;
}

.smart-revision-dropzone strong {
  color: #172033;
  font-size: 15px;
}

.smart-revision-dropzone span {
  max-width: 340px;
  font-size: 12px;
  line-height: 1.55;
}

.smart-revision-dropzone em {
  max-width: 100%;
  padding: 4px 8px;
  overflow-wrap: anywhere;
  border: 1px solid #dce5ef;
  border-radius: 999px;
  background: #f8fafc;
  color: #475569;
  font-size: 11px;
  font-style: normal;
  font-weight: 700;
}

.smart-revision-ai-option {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  padding: 11px;
  border: 1px solid #dce5ef;
  border-radius: 10px;
  background: #f8fafc;
  cursor: pointer;
}

.smart-revision-ai-option input {
  width: 16px;
  height: 16px;
  margin-top: 2px;
  accent-color: var(--primary);
}

.smart-revision-ai-option strong,
.smart-revision-ai-option em {
  display: block;
}

.smart-revision-ai-option strong {
  color: #334155;
  font-size: 12px;
}

.smart-revision-ai-option em {
  margin-top: 4px;
  color: #64748b;
  font-size: 11px;
  font-style: normal;
  line-height: 1.5;
}

.smart-revision-result-panel {
  background: #f8fafc;
}

.smart-revision-export-ready {
  display: grid;
  gap: 14px;
  min-height: 220px;
  padding: 18px 20px;
  border: 1px solid #d8e5eb;
  border-radius: 8px;
  background: #fff;
  color: #475569;
}

.smart-revision-export-ready > header,
.smart-revision-export-ready > footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.smart-revision-export-ready > header > div {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.smart-revision-export-ready header strong {
  color: #172033;
  font-size: 16px;
}

.smart-revision-export-ready header span {
  overflow: hidden;
  color: #64748b;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.smart-revision-export-ready header small {
  flex: 0 0 auto;
  padding: 4px 8px;
  border: 1px solid #bae6fd;
  border-radius: 6px;
  background: #ecfeff;
  color: #0f5f73;
  font-size: 11px;
  font-weight: 700;
}

.smart-revision-export-stat {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 13px 14px;
  border-left: 3px solid #0e7490;
  background: #f0fdfa;
}

.smart-revision-export-stat strong {
  color: #0f766e;
  font-size: 26px;
}

.smart-revision-export-stat span,
.smart-revision-export-note {
  color: #475569;
  font-size: 12px;
  line-height: 1.6;
}

.smart-revision-export-note { margin: 0; }

.smart-revision-issue-details {
  display: grid;
  gap: 9px;
  max-height: 390px;
  overflow-y: auto;
  padding-right: 4px;
}

.smart-revision-issue-details > header {
  position: sticky;
  top: 0;
  z-index: 1;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  padding: 4px 0 7px;
  border-bottom: 1px solid #e2e8f0;
  background: #fff;
}

.smart-revision-issue-details > header strong { color: #172033; font-size: 13px; }
.smart-revision-issue-details > header span { color: #64748b; font-size: 11px; }

.smart-revision-issue-detail {
  display: grid;
  gap: 8px;
  padding: 11px 12px;
  border: 1px solid #dce5ef;
  border-left: 3px solid #0e7490;
  border-radius: 7px;
  background: #fbfdfe;
}

.smart-revision-issue-detail > header { display: flex; align-items: center; gap: 7px; }
.smart-revision-issue-number {
  width: 20px;
  height: 20px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #e0f2fe;
  color: #0e7490;
  font-size: 10px;
  font-weight: 800;
}
.smart-revision-issue-detail > header strong { color: #334155; font-size: 12px; }
.smart-revision-issue-detail > header em {
  margin-left: auto;
  padding: 3px 6px;
  border-radius: 999px;
  background: #f0fdfa;
  color: #0f766e;
  font-size: 10px;
  font-style: normal;
  font-weight: 700;
}
.smart-revision-issue-anchor small { color: #94a3b8; font-size: 10px; }
.smart-revision-issue-anchor blockquote {
  margin: 3px 0 0;
  padding: 7px 9px;
  border-left: 2px solid #cbd5e1;
  background: #fff;
  color: #172033;
  font-size: 12px;
  line-height: 1.55;
}
.smart-revision-issue-fields { display: grid; gap: 4px; }
.smart-revision-issue-fields p { margin: 0; color: #64748b; font-size: 11px; line-height: 1.55; }
.smart-revision-issue-fields b { color: #475569; }

.smart-revision-export-ready > footer {
  padding-top: 12px;
  border-top: 1px solid #e2e8f0;
}

.smart-revision-export-ready > footer > span {
  color: #64748b;
  font-size: 12px;
}

.smart-revision-empty,
.smart-revision-running,
.smart-revision-error,
.smart-revision-no-issues {
  min-height: 320px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 10px;
  padding: 26px;
  border: 1px dashed #cbd5e1;
  border-radius: 12px;
  background: rgba(255, 255, 255, .76);
  text-align: center;
}

.smart-revision-complete {
  min-height: 148px;
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 8px;
  padding: 22px;
  color: #475569;
  text-align: center;
}

.smart-revision-complete > span {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid #bae6fd;
  border-radius: 50%;
  background: #ecfeff;
  color: #0e7490;
}

.smart-revision-complete strong {
  color: #172033;
  font-size: 15px;
}

.smart-revision-complete p,
.smart-revision-complete small {
  max-width: 540px;
  margin: 0;
  font-size: 12px;
  line-height: 1.55;
}

.smart-revision-reading {
  display: grid;
  gap: 18px;
  padding: 20px;
  border: 1px solid #d8e5eb;
  border-radius: 8px;
  background: #fff;
  color: #475569;
}

.smart-revision-reading-head,
.smart-revision-reading-file,
.smart-revision-reading-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.smart-revision-reading-model,
.smart-revision-reading-file {
  display: flex;
  align-items: center;
  gap: 9px;
}

.smart-revision-reading-model strong,
.smart-revision-reading-focus strong,
.smart-revision-reading-file strong {
  color: #172033;
  font-size: 14px;
}

.smart-revision-reading-model em {
  color: #64748b;
  font-size: 12px;
  font-style: normal;
}

.smart-revision-reading-signal {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #0e7490;
  box-shadow: 0 0 0 5px #e0f2fe;
  animation: smart-revision-pulse 1.5s ease-in-out infinite;
}

@keyframes smart-revision-pulse {
  50% { box-shadow: 0 0 0 9px rgba(224, 242, 254, .25); }
}

.smart-revision-reading-state {
  padding: 4px 8px;
  border: 1px solid #99d7d1;
  border-radius: 999px;
  background: #f0fdfa;
  color: #0f766e;
  font-size: 11px;
  font-weight: 700;
}

.smart-revision-reading-file {
  padding: 13px 14px;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  background: #f8fafc;
}

.smart-revision-reading-file > span {
  width: 30px;
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #f0c6d3;
  border-radius: 6px;
  background: #fff;
  color: var(--primary);
}

.smart-revision-reading-file svg {
  width: 17px;
  height: 17px;
}

.smart-revision-reading-file small {
  margin-left: auto;
  color: #64748b;
  font-size: 11px;
}

.smart-revision-reading-focus p,
.smart-revision-reading-foot span {
  margin: 5px 0 0;
  color: #64748b;
  font-size: 12px;
  line-height: 1.55;
}

.smart-revision-reading-meter {
  height: 5px;
  overflow: hidden;
  border-radius: 999px;
  background: #e8eef3;
}

.smart-revision-reading-meter > i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #0e7490;
  transition: width .35s ease;
}

.smart-revision-reading-percent {
  display: flex;
  align-items: baseline;
  gap: 7px;
  margin-top: -10px;
  color: #64748b;
  font-size: 11px;
}
.smart-revision-reading-percent strong { color: #0e7490; font-size: 17px; }

.smart-revision-reading-meter.is-reading > i {
  width: 38% !important;
  animation: smart-revision-reading-meter 2.2s ease-in-out infinite;
}

@keyframes smart-revision-reading-meter {
  50% { width: 62% !important; }
}

.smart-revision-reading-steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.smart-revision-reading-steps li {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  align-items: center;
  gap: 7px;
  min-width: 0;
  color: #94a3b8;
  font-size: 11px;
  line-height: 1.35;
}

.smart-revision-reading-steps li > span {
  width: 20px;
  height: 20px;
  display: grid;
  place-items: center;
  border: 1px solid #d6dee8;
  border-radius: 50%;
  background: #fff;
  font-size: 10px;
}

.smart-revision-reading-steps li.is-done,
.smart-revision-reading-steps li.is-current { color: #0f5f73; }
.smart-revision-reading-steps li.is-done > span { border-color: #8ed3c5; background: #eafaf5; color: #08765d; }
.smart-revision-reading-steps li.is-current > span { border-color: #7dd3fc; background: #ecfeff; color: #0e7490; }

.smart-revision-reading-foot {
  padding-top: 2px;
}

.smart-revision-reading-foot span { margin: 0; }

.smart-revision-progress-minimize {
  flex: 0 0 auto;
  width: 32px;
  height: 32px;
  display: inline-grid;
  place-items: center;
  padding: 0;
  border: 1px solid #0e7490;
  border-radius: 6px;
  background: #fff;
  color: #0e7490;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.smart-revision-progress-minimize:hover {
  background: #f0fdfa;
}

.smart-revision-empty > span,
.smart-revision-running > span {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #fdf2f8;
  color: var(--primary);
}

.smart-revision-running > span {
  border: 3px solid #dbeafe;
  border-top-color: #0e7490;
  background: transparent;
  animation: smart-revision-spin 1s linear infinite;
}

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

.smart-revision-empty strong,
.smart-revision-running strong {
  color: #1e293b;
  font-size: 15px;
}

.smart-revision-empty p,
.smart-revision-running p {
  max-width: 500px;
  margin: 0;
  color: #64748b;
  font-size: 12px;
  line-height: 1.65;
}

.smart-revision-error {
  min-height: 120px;
  color: #b91c1c;
  border-color: #fecaca;
  background: #fff7f7;
}

.smart-revision-result-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.smart-revision-read-proof {
  margin-top: 0;
  padding: 8px 10px;
  border-left: 3px solid #0e7490;
  background: #f0fdfa;
  color: #475569;
  font-size: 12px;
  line-height: 1.5;
}

.smart-revision-result-summary > div {
  display: flex;
  align-items: baseline;
  gap: 5px;
  padding: 10px;
  border: 1px solid #dce5ef;
  border-radius: 10px;
  background: #fff;
}

.smart-revision-result-summary strong {
  color: var(--primary);
  font-size: 21px;
}

.smart-revision-diagnostics {
  display: grid;
  gap: 7px;
  margin-top: 10px;
  padding: 12px 14px;
  border: 1px solid #dbe5ef;
  border-radius: 10px;
  background: #fff;
  color: #475569;
  font-size: 12px;
  line-height: 1.55;
}

.smart-revision-diagnostics.is-warning {
  border-color: #f3c982;
  background: #fffbeb;
}

.smart-revision-diagnostics-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}

.smart-revision-diagnostics-title strong {
  color: #92400e;
  font-size: 13px;
}

.smart-revision-diagnostics-title span {
  color: #78716c;
  font-size: 11px;
  font-weight: 700;
}

.smart-revision-diagnostics p {
  margin: 0;
}

.smart-revision-diagnostics b {
  color: #78350f;
}

.smart-revision-diagnostics .btn {
  justify-self: start;
  min-height: 30px;
  padding: 5px 10px;
  font-size: 12px;
}

.smart-revision-result-summary span,
.smart-revision-result-summary p,
.smart-revision-facts small {
  color: #64748b;
  font-size: 11px;
  line-height: 1.45;
}

.smart-revision-result-summary p {
  grid-column: 1 / -1;
  margin: 0;
  padding: 7px 9px;
  border-radius: 8px;
  background: #ecfeff;
  color: #0f766e;
}

.smart-revision-facts {
  display: grid;
  gap: 4px;
  margin: 10px 0;
  padding: 10px;
  border-left: 3px solid var(--primary);
  background: #fff;
}

.smart-revision-facts > span {
  overflow: hidden;
  color: #334155;
  font-size: 13px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.smart-revision-pipeline {
  margin-bottom: 10px;
}

.smart-revision-pipeline span.is-completed,
.smart-revision-pipeline span.is-ready {
  border-color: #a7f3d0;
  background: #ecfdf5;
  color: #047857;
}

.smart-revision-pipeline span.is-skipped {
  background: #f1f5f9;
  color: #64748b;
}

.smart-revision-pipeline span.is-degraded {
  border-color: #fed7aa;
  background: #fff7ed;
  color: #c2410c;
}

.smart-revision-issue-list {
  display: grid;
  gap: 8px;
}

.smart-revision-issue {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  padding: 11px;
  border: 1px solid #fed7aa;
  border-radius: 10px;
  background: #fffdf9;
  cursor: pointer;
}

.smart-revision-issue.is-suggested {
  border-color: #bfdbfe;
  background: #f8fbff;
}

.smart-revision-issue > input {
  width: 16px;
  height: 16px;
  margin-top: 2px;
  accent-color: var(--primary);
}

.smart-revision-issue-main {
  min-width: 0;
  display: grid;
  gap: 5px;
}

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

.smart-revision-issue-top strong {
  color: #334155;
  font-size: 12px;
}

.smart-revision-issue-top em {
  flex: 0 0 auto;
  padding: 2px 6px;
  border-radius: 999px;
  background: #fff7ed;
  color: #c2410c;
  font-size: 10px;
  font-style: normal;
  font-weight: 800;
}

.smart-revision-issue.is-suggested .smart-revision-issue-top em {
  background: #eff6ff;
  color: #1d4ed8;
}

.smart-revision-issue-quote {
  color: #172033;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.5;
}

.smart-revision-issue-reason,
.smart-revision-issue-suggestion,
.smart-revision-issue small {
  color: #64748b;
  font-size: 11px;
  line-height: 1.55;
}

.smart-revision-issue-suggestion {
  color: #334155;
}

.smart-revision-download-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid #dce5ef;
  color: #64748b;
  font-size: 12px;
}

.smart-revision-review-workspace {
  display: grid;
  gap: 12px;
}

.smart-revision-review-heading,
.smart-revision-section-title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.smart-revision-review-heading > div {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.smart-revision-review-heading strong {
  color: #172033;
  font-size: 16px;
}

.smart-revision-review-heading span,
.smart-revision-review-heading small,
.smart-revision-section-title span {
  color: #64748b;
  font-size: 11px;
  line-height: 1.5;
}

.smart-revision-review-heading > div > span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.smart-revision-review-heading small {
  flex: 0 0 auto;
  padding: 3px 7px;
  border: 1px solid #bae6fd;
  border-radius: 7px;
  background: #ecfeff;
  color: #0f5f73;
}

.smart-revision-module-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.smart-revision-module {
  min-width: 0;
  display: grid;
  gap: 3px;
  padding: 9px 10px;
  border: 1px solid #dce5ef;
  border-left: 3px solid #94a3b8;
  border-radius: 7px;
  background: #fff;
}

.smart-revision-module.has-issues { border-left-color: #c2410c; }
.smart-revision-module.is-clear { border-left-color: #0f766e; }

.smart-revision-module strong {
  overflow: hidden;
  color: #334155;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.smart-revision-module span {
  color: #64748b;
  font-size: 11px;
}

.smart-revision-auto-edit {
  padding: 10px 11px;
  border: 1px solid #c7dce4;
  border-radius: 7px;
  background: #f0fdfa;
}

.smart-revision-auto-edit label {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  cursor: pointer;
}

.smart-revision-auto-edit input {
  width: 16px;
  height: 16px;
  margin-top: 2px;
  accent-color: #0f766e;
}

.smart-revision-auto-edit input:disabled { cursor: not-allowed; }

.smart-revision-auto-edit span {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.smart-revision-auto-edit strong {
  color: #134e4a;
  font-size: 12px;
}

.smart-revision-auto-edit small {
  color: #4b6470;
  font-size: 11px;
  line-height: 1.5;
}

.smart-revision-issue-section {
  display: grid;
  gap: 8px;
}

.smart-revision-section-title strong {
  color: #172033;
  font-size: 13px;
}

.smart-revision-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 22px 16px;
  border-top: 1px solid #e5e7eb;
  background: #fff;
}

.smart-revision-footer > span {
  color: #64748b;
  font-size: 12px;
}

.smart-revision-footer > div {
  display: flex;
  flex: 0 0 auto;
  gap: 8px;
}

/* Focused workflow: upload first, then reveal the compact review workspace. */
.smart-revision-dialog {
  width: min(980px, 96vw);
  max-height: min(860px, 90dvh);
  border-color: #d8e1eb;
  border-radius: 12px;
  box-shadow: 0 28px 76px rgba(15, 23, 42, .22);
}

.smart-revision-header {
  align-items: center;
  min-height: 92px;
  padding: 18px 28px;
  border-top: 3px solid #8b1538;
  background: #fff;
}

.smart-revision-header .editor-toolbox-title-icon {
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 12px;
  background: #8b1538;
  color: #fff;
  box-shadow: 0 10px 24px rgba(139, 21, 56, .2);
}

.smart-revision-header .editor-toolbox-title-icon svg {
  width: 24px;
  height: 24px;
  stroke-width: 1.8;
}

.smart-revision-header .editor-toolbox-title-block h3 {
  color: #172033;
  font-size: 24px;
  font-weight: 800;
}

.smart-revision-header .editor-toolbox-title-block p {
  color: #52667f;
  font-size: 14px;
}

.smart-revision-minimize-btn,
.smart-revision-progress-minimize {
  width: auto;
  min-width: 64px;
  height: 34px;
  padding: 0 12px;
  border-color: #cbd5e1;
  border-radius: 7px;
  background: #fff;
  color: #334155;
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
}

.smart-revision-minimize-btn:hover:not(:disabled),
.smart-revision-progress-minimize:hover {
  border-color: #0f766e;
  background: #f0fdfa;
  color: #0f766e;
}

.smart-revision-body {
  display: block;
  overflow-y: auto;
  background: #fff;
}

.smart-revision-upload-panel {
  gap: 14px;
  padding: 24px 28px 26px;
  border-bottom: 0;
}

.smart-revision-upload-title strong { font-size: 17px; }
.smart-revision-upload-title span { max-width: 540px; font-size: 13px; }

.smart-revision-upload-title button {
  min-height: 36px;
  padding: 6px 12px;
  border-color: #cbd5e1;
  color: #334155;
}

.smart-revision-dropzone {
  min-height: 238px;
  gap: 12px;
  border-color: #c9d6e4;
  border-radius: 10px;
  background: #fbfdff;
}

.smart-revision-dropzone:hover,
.smart-revision-dropzone.is-dragging {
  border-color: #0f766e;
  background: #f0fdfa;
  box-shadow: inset 0 0 0 1px rgba(15, 118, 110, .08);
}

.smart-revision-dropzone-icon {
  width: 48px;
  height: 48px;
  border-color: #e7d3da;
  border-radius: 10px;
}

.smart-revision-dropzone strong { font-size: 17px; }
.smart-revision-dropzone span { max-width: 430px; font-size: 13px; }

.smart-revision-result-panel.is-collapsed { display: none; }

.smart-revision-body.has-file .smart-revision-upload-panel {
  display: block;
  padding: 12px 28px;
  border-top: 1px solid #e5e7eb;
  border-bottom: 1px solid #e5e7eb;
}

.smart-revision-body.has-file .smart-revision-upload-title,
.smart-revision-body.has-file .smart-revision-dropzone { display: none; }

.smart-revision-body.has-file .smart-revision-file-summary {
  display: flex;
  min-height: 42px;
}

.smart-revision-body.has-file .smart-revision-result-panel {
  min-height: 176px;
  padding: 18px 28px 22px;
  border: 0;
  background: #f8fafc;
}

.smart-revision-ready {
  min-height: 126px;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 20px;
  border: 1px solid #d9e4ef;
  border-radius: 9px;
  background: #fff;
}

.smart-revision-ready-icon {
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border: 1px solid #a7dfd5;
  border-radius: 50%;
  background: #ecfdf5;
  color: #047857;
}

.smart-revision-ready-icon svg { width: 20px; height: 20px; stroke: currentColor; }
.smart-revision-ready strong { display: block; color: #172033; font-size: 15px; }
.smart-revision-ready p { margin: 5px 0 0; color: #64748b; font-size: 12px; line-height: 1.6; }

.smart-revision-reading {
  gap: 16px;
  padding: 22px;
  border-color: #d7e4eb;
  border-radius: 9px;
  box-shadow: 0 8px 22px rgba(15, 23, 42, .04);
}

.smart-revision-reading-head { padding-bottom: 2px; }
.smart-revision-reading-model strong { font-size: 16px; }
.smart-revision-reading-model em { color: #64748b; }
.smart-revision-reading-file { padding: 12px 14px; }
.smart-revision-reading-focus { display: grid; gap: 2px; }
.smart-revision-reading-focus strong { font-size: 17px; }
.smart-revision-reading-focus p { margin: 0; font-size: 12px; }
.smart-revision-reading-meter { height: 7px; }
.smart-revision-reading-percent { margin-top: -6px; }
.smart-revision-reading-percent strong { font-size: 20px; }
.smart-revision-reading-foot { padding-top: 8px; border-top: 1px solid #e6edf3; }

.smart-revision-reading-steps {
  gap: 12px;
  padding: 14px 0;
  border-top: 1px solid #e6edf3;
  border-bottom: 1px solid #e6edf3;
}

.smart-revision-reading-steps li {
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 8px;
  color: #94a3b8;
  font-size: 12px;
}

.smart-revision-reading-steps li > .smart-revision-step-icon {
  width: 30px;
  height: 30px;
  border-color: #d8e2ec;
  border-radius: 8px;
  background: #fff;
  color: #94a3b8;
}

.smart-revision-step-icon svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
}

.smart-revision-reading-steps li.is-done > .smart-revision-step-icon {
  border-color: #9bd9cd;
  background: #ecfdf5;
  color: #047857;
}

.smart-revision-reading-steps li.is-current > .smart-revision-step-icon {
  border-color: #61c8e7;
  background: #ecfeff;
  color: #0e7490;
  box-shadow: 0 0 0 3px rgba(14, 116, 144, .08);
}

.smart-revision-reading-log {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid #dce6ee;
  border-radius: 8px;
  background: #fbfdff;
}

.smart-revision-reading-log > header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.smart-revision-reading-log strong { color: #334155; font-size: 12px; }
.smart-revision-reading-log header span { color: #0f766e; font-size: 11px; font-weight: 700; }
.smart-revision-reading-log ol { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.smart-revision-reading-log li { display: flex; align-items: flex-start; gap: 8px; color: #64748b; font-size: 12px; line-height: 1.5; }
.smart-revision-reading-log li > i { width: 6px; height: 6px; flex: 0 0 auto; margin-top: 6px; border-radius: 50%; background: #9fb2c4; }
.smart-revision-reading-log li.is-current { color: #0f5f73; font-weight: 700; }
.smart-revision-reading-log li.is-current > i { background: #0e7490; box-shadow: 0 0 0 4px rgba(14, 116, 144, .1); }

.smart-revision-footer {
  min-height: 72px;
  padding: 14px 28px;
  border-top-color: #dfe7ef;
  background: #fff;
}

@media (max-width: 850px) {
  .smart-revision-dialog { width: min(96vw, 680px); max-height: 94vh; }
  .smart-revision-body { grid-template-columns: minmax(0, 1fr); overflow-y: auto; }
  .smart-revision-upload-panel { overflow: visible; border-right: 0; border-bottom: 1px solid #e5e7eb; }
  .smart-revision-result-panel { overflow: visible; }
  .smart-revision-footer { align-items: flex-start; flex-direction: column; }
  .smart-revision-module-grid { grid-template-columns: minmax(0, 1fr); }
  .smart-revision-download-row { align-items: flex-start; flex-direction: column; }
  .smart-revision-export-ready > header,
  .smart-revision-export-ready > footer { align-items: flex-start; flex-direction: column; }
  .smart-revision-export-ready header small { white-space: normal; }
  .smart-revision-dialog.is-result-ready .smart-revision-upload-panel { padding: 12px 16px; }
}

@media (max-width: 720px) {
  .smart-revision-dialog { width: 100vw; max-height: 100dvh; border-radius: 0; }
  .smart-revision-header { min-height: 78px; padding: 14px 16px; }
  .smart-revision-header .editor-toolbox-title-block p { display: none; }
  .smart-revision-minimize-btn { min-width: 58px; padding: 0 8px; }
  .smart-revision-upload-panel { padding: 18px 16px 20px; }
  .smart-revision-dropzone { min-height: 210px; padding: 16px; }
  .smart-revision-body.has-file .smart-revision-upload-panel,
  .smart-revision-body.has-file .smart-revision-result-panel { padding-left: 16px; padding-right: 16px; }
  .smart-revision-reading { padding: 16px; }
  .smart-revision-reading-head,
  .smart-revision-reading-file,
  .smart-revision-reading-foot { align-items: flex-start; flex-direction: column; }
  .smart-revision-reading-file small { margin-left: 39px; }
  .smart-revision-reading-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 14px; }
  .smart-revision-footer { align-items: flex-start; padding: 12px 16px; }
}

.reference-check-progress-card {
  position: relative;
  overflow: hidden;
  width: 100%;
  margin: 0;
  min-height: 490px;
  padding: 26px;
  display: grid;
  grid-template-rows: auto minmax(178px, auto) auto auto auto;
  border: 1px solid rgba(219, 226, 239, 0.98);
  border-radius: 20px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.99), rgba(247, 251, 255, 0.96)),
    #ffffff;
  box-shadow: 0 22px 60px rgba(31, 79, 117, 0.11);
}

.reference-check-progress-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(139, 21, 56, 0.055), transparent 34%, rgba(14, 116, 144, 0.065) 72%, transparent),
    linear-gradient(180deg, rgba(255, 255, 255, 0.62), transparent 52%);
  opacity: 0.78;
}

.reference-check-running-head {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}

.reference-check-running-copy {
  min-width: 0;
  max-width: 780px;
}

.reference-check-running-copy > span {
  min-height: 26px;
  display: inline-flex;
  align-items: center;
  padding: 0 10px;
  border-radius: 999px;
  background: #eef9fb;
  color: #0f6d7f;
  font-size: 12px;
  font-weight: 900;
  box-shadow: inset 0 0 0 1px rgba(14, 116, 144, 0.12);
}

.reference-check-running-copy strong {
  display: block;
  margin-top: 11px;
  color: #0f172a;
  font-size: 22px;
  line-height: 1.25;
  font-weight: 900;
}

.reference-check-running-copy p {
  margin: 7px 0 0;
  color: #64748b;
  font-size: 14px;
  line-height: 1.68;
  word-break: break-word;
}

.reference-check-animation-wrap {
  --reference-progress: 0;
  min-height: 190px;
  display: grid;
  place-items: center;
  position: relative;
  z-index: 1;
  margin: 4px 0 22px;
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(244, 249, 255, 0.84)),
    rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(207, 220, 238, 0.92);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.92),
    0 12px 34px rgba(31, 79, 117, 0.08);
}

.reference-check-animation-wrap::before {
  content: "";
  position: absolute;
  inset: 14px;
  border-radius: 14px;
  background:
    linear-gradient(110deg, transparent 0%, rgba(255, 255, 255, 0.72) 46%, transparent 68%);
  transform: translateX(-55%);
  animation: reference-check-panel-scan 2.8s ease-in-out infinite;
}

@keyframes reference-check-panel-scan {
  0% {
    transform: translateX(-58%);
    opacity: 0;
  }
  18%, 72% {
    opacity: 0.72;
  }
  100% {
    transform: translateX(58%);
    opacity: 0;
  }
}

.reference-check-verifier {
  position: relative;
  z-index: 1;
  width: min(560px, 88%);
  min-height: 138px;
  display: grid;
  grid-template-columns: 190px minmax(80px, 1fr) 186px;
  align-items: center;
  gap: 18px;
}

.reference-check-verifier-paper {
  position: relative;
  overflow: hidden;
  height: 124px;
  padding: 20px 18px;
  border-radius: 16px;
  background:
    linear-gradient(180deg, #ffffff, #f8fafc);
  border: 1px solid rgba(207, 220, 238, 0.94);
  box-shadow:
    0 16px 38px rgba(31, 79, 117, 0.10),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.reference-check-verifier-paper::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, transparent, rgba(14, 116, 144, 0.14), rgba(139, 21, 56, 0.10), transparent);
  transform: translateX(-100%);
  animation: reference-check-document-scan 2.25s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

@keyframes reference-check-document-scan {
  0% {
    transform: translateX(-110%);
    opacity: 0;
  }
  16%, 78% {
    opacity: 1;
  }
  100% {
    transform: translateX(110%);
    opacity: 0;
  }
}

.reference-check-verifier-paper span {
  position: relative;
  z-index: 1;
  display: block;
  height: 8px;
  margin-bottom: 12px;
  border-radius: 999px;
  background: #e7edf5;
}

.reference-check-verifier-paper span:nth-child(1) {
  width: 58%;
  background: rgba(139, 21, 56, 0.22);
}

.reference-check-verifier-paper span:nth-child(2) {
  width: 86%;
}

.reference-check-verifier-paper span:nth-child(3) {
  width: 72%;
}

.reference-check-verifier-paper span:nth-child(4) {
  width: 44%;
  background: rgba(14, 116, 144, 0.20);
}

.reference-check-verifier-paper i {
  position: absolute;
  right: 16px;
  bottom: 16px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 2px solid rgba(14, 116, 144, 0.18);
  background: linear-gradient(135deg, rgba(14, 116, 144, 0.09), rgba(139, 21, 56, 0.08));
}

.reference-check-verifier-paper i::before,
.reference-check-verifier-paper i::after {
  content: "";
  position: absolute;
  background: #0e7490;
  border-radius: 999px;
}

.reference-check-verifier-paper i::before {
  width: 15px;
  height: 2px;
  left: 9px;
  top: 17px;
  transform: rotate(-42deg);
}

.reference-check-verifier-paper i::after {
  width: 8px;
  height: 2px;
  left: 7px;
  top: 19px;
  transform: rotate(42deg);
}

.reference-check-verifier-route {
  position: relative;
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(139, 21, 56, 0.18), rgba(14, 116, 144, 0.18));
}

.reference-check-verifier-route span {
  position: absolute;
  top: 50%;
  width: 10px;
  height: 10px;
  margin-top: -5px;
  border-radius: 50%;
  background: #8b1538;
  box-shadow: 0 0 0 7px rgba(139, 21, 56, 0.08);
  animation: reference-check-packet 2.4s ease-in-out infinite;
}

.reference-check-verifier-route span:nth-child(2) {
  animation-delay: 0.42s;
  background: #0e7490;
  box-shadow: 0 0 0 7px rgba(14, 116, 144, 0.08);
}

.reference-check-verifier-route span:nth-child(3) {
  animation-delay: 0.84s;
}

@keyframes reference-check-packet {
  0% {
    left: 0;
    opacity: 0;
    transform: scale(0.72);
  }
  12%, 78% {
    opacity: 1;
  }
  100% {
    left: calc(100% - 10px);
    opacity: 0;
    transform: scale(1);
  }
}

.reference-check-verifier-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.reference-check-verifier-fields span {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  border: 1px solid #dbe3ef;
  background: rgba(255, 255, 255, 0.96);
  color: #42526b;
  font-size: 12px;
  font-weight: 900;
  box-shadow: 0 10px 22px rgba(31, 79, 117, 0.055);
  animation: reference-check-field-glow 2.8s ease-in-out infinite;
}

.reference-check-verifier-fields span:nth-child(2) {
  animation-delay: 0.25s;
}

.reference-check-verifier-fields span:nth-child(3) {
  animation-delay: 0.5s;
}

.reference-check-verifier-fields span:nth-child(4) {
  animation-delay: 0.75s;
}

@keyframes reference-check-field-glow {
  0%, 100% {
    border-color: #dbe3ef;
    color: #42526b;
    transform: translateY(0);
  }
  42% {
    border-color: rgba(139, 21, 56, 0.24);
    color: #8b1538;
    transform: translateY(-1px);
    box-shadow: 0 14px 28px rgba(139, 21, 56, 0.08);
  }
}

.reference-check-orbit {
  position: relative;
  width: 136px;
  height: 136px;
  border-radius: 50%;
  background:
    conic-gradient(from -90deg, #8b1538 0 calc(var(--reference-progress) * 1%), #dbeafe 0 100%);
  box-shadow:
    inset 0 0 0 1px rgba(226, 232, 240, 0.95),
    0 20px 48px rgba(15, 23, 42, 0.14);
}

.reference-check-orbit::before {
  content: "";
  position: absolute;
  z-index: 2;
  inset: 14px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 42%, #fff 0 48%, #f8fafc 49% 100%);
  box-shadow: inset 0 0 0 1px #edf2f7;
}

.reference-check-orbit::after {
  content: "";
  position: absolute;
  z-index: 3;
  inset: -10px;
  border-radius: 50%;
  border-top: 2px solid rgba(14, 116, 144, 0.75);
  border-right: 2px solid rgba(139, 21, 56, 0.65);
  border-bottom: 2px solid transparent;
  border-left: 2px solid transparent;
  filter: drop-shadow(0 8px 14px rgba(14, 116, 144, 0.2));
  animation: reference-check-orbit-sweep 2.4s linear infinite;
}

.reference-check-orbit i,
.reference-check-orbit b {
  display: none;
}

@keyframes reference-check-orbit-sweep {
  to {
    transform: rotate(360deg);
  }
}

.reference-check-animation-copy {
  position: absolute;
  top: 16px;
  right: 16px;
  display: grid;
  justify-items: center;
  gap: 4px;
  z-index: 2;
  min-width: 82px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(207, 220, 238, 0.9);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 12px 26px rgba(31, 79, 117, 0.08);
  backdrop-filter: blur(10px);
}

.reference-check-animation-copy strong {
  color: #18324b;
  font-size: 22px;
  line-height: 1;
  font-weight: 950;
  font-variant-numeric: tabular-nums;
}

.reference-check-animation-copy span {
  color: #64748b;
  font-size: 12px;
  line-height: 1;
  font-weight: 900;
}

.reference-check-progress-top {
  display: flex;
  align-items: center;
  gap: 12px;
}

.reference-check-progress-top strong {
  display: block;
  color: #0f172a;
  font-size: 14px;
  font-weight: 900;
}

.reference-check-progress-top p {
  margin: 4px 0 0;
  color: #64748b;
  font-size: 12px;
  line-height: 1.5;
}

.reference-check-spinner {
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  border-radius: 50%;
  border: 3px solid #e0f2fe;
  border-top-color: var(--primary);
  border-right-color: #0e7490;
  animation: reference-check-spin 0.85s linear infinite;
}

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

.reference-check-progress-meter {
  position: relative;
  z-index: 1;
  height: 10px;
  overflow: hidden;
  margin-top: 12px;
  border-radius: 999px;
  background: #e4ebf5;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.08);
}

.reference-check-progress-meter span {
  position: relative;
  overflow: hidden;
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #8b1538, #0e7490);
  transition: width 0.22s ease;
}

.reference-check-progress-meter span::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.6), transparent);
  transform: translateX(-100%);
  animation: reference-check-meter-sheen 1.8s ease-in-out infinite;
}

@keyframes reference-check-meter-sheen {
  to {
    transform: translateX(100%);
  }
}

.reference-check-progress-meta {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 13px;
}

.reference-check-progress-meta span {
  min-width: 0;
  padding: 9px 10px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid #dde8f4;
  color: #42526b;
  font-size: 11px;
  font-weight: 800;
  text-align: center;
  box-shadow: 0 8px 18px rgba(31, 79, 117, 0.045);
}

.reference-check-progress-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 12px;
}

.reference-check-latest-panel {
  position: relative;
  z-index: 1;
  margin-top: 18px;
  padding: 14px;
  border: 1px solid rgba(221, 232, 244, 0.95);
  border-radius: 16px;
  background: rgba(248, 251, 255, 0.72);
}

.reference-check-latest-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.reference-check-latest-title strong {
  color: #0f172a;
  font-size: 13px;
  font-weight: 900;
}

.reference-check-latest-title span {
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}

.reference-check-latest-empty,
.reference-check-latest-row {
  padding: 12px 14px;
  border: 1px solid #dde8f4;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.92);
}

.reference-check-latest-empty {
  color: #64748b;
  font-size: 13px;
  line-height: 1.6;
  text-align: center;
}

.reference-check-latest-row {
  border-color: rgba(14, 116, 144, 0.16);
  box-shadow: 0 12px 28px rgba(31, 79, 117, 0.06);
}

.reference-check-latest-row.is-changed {
  border-color: rgba(139, 21, 56, 0.20);
  background: linear-gradient(180deg, #ffffff, #fff8fb);
}

.reference-check-latest-row.is-notfound,
.reference-check-latest-row.is-pendingreview {
  border-color: #fed7aa;
  background: #fffaf5;
}

.reference-check-latest-head {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 7px;
}

.reference-check-latest-head strong {
  color: #0f172a;
  font-size: 12px;
  font-weight: 900;
}

.reference-check-latest-head span,
.reference-check-latest-head em {
  min-height: 22px;
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  font-style: normal;
  font-size: 11px;
  font-weight: 900;
}

.reference-check-latest-head span {
  background: #ecfeff;
  color: #0e7490;
}

.reference-check-latest-head em {
  background: #f1f5f9;
  color: #64748b;
}

.reference-check-latest-row.is-notfound .reference-check-latest-head span,
.reference-check-latest-row.is-pendingreview .reference-check-latest-head span {
  background: #fff7ed;
  color: #9a3412;
}

.reference-check-latest-row p {
  margin: 0;
  color: #334155;
  font-size: 13px;
  line-height: 1.65;
  word-break: break-word;
}

.reference-check-progress-list {
  max-height: 220px;
  overflow-y: auto;
  display: grid;
  gap: 8px;
  padding-right: 2px;
}

.reference-check-progress-row {
  display: grid;
  grid-template-columns: auto auto auto minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  min-width: 0;
  padding: 10px 12px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.045);
}

.reference-check-progress-row.is-notfound,
.reference-check-progress-row.is-pendingreview {
  border-color: #fed7aa;
  background: #fffaf5;
}

.reference-check-progress-row.is-changed {
  border-color: #f8c9d5;
}

.reference-check-progress-row strong,
.reference-check-progress-row span,
.reference-check-progress-row em {
  min-height: 22px;
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  line-height: 1;
  font-weight: 900;
  font-style: normal;
  white-space: nowrap;
}

.reference-check-progress-row strong {
  background: #f1f5f9;
  color: #475569;
}

.reference-check-progress-row span {
  background: #ecfeff;
  color: #0e7490;
}

.reference-check-progress-row.is-notfound span,
.reference-check-progress-row.is-pendingreview span {
  background: #fff7ed;
  color: #9a3412;
}

.reference-check-progress-row em {
  background: #f8fafc;
  color: #64748b;
}

.reference-check-progress-row p {
  min-width: 0;
  margin: 0;
  color: #334155;
  font-size: 13px;
  line-height: 1.45;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.reference-check-live-panel {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid #e2e8f0;
}

.reference-check-live-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.reference-check-live-title strong {
  color: #0f172a;
  font-size: 13px;
  font-weight: 900;
}

.reference-check-live-title span {
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}

.reference-check-live-empty {
  padding: 14px;
  border: 1px dashed #cbd5e1;
  border-radius: 12px;
  background: #f8fafc;
  color: #64748b;
  font-size: 12px;
  line-height: 1.6;
  text-align: center;
}

.reference-check-live-list {
  max-height: 360px;
  overflow-y: auto;
  display: grid;
  gap: 10px;
  padding-right: 2px;
}

.reference-check-live-row {
  min-width: 0;
  padding: 11px 12px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.05);
}

.reference-check-live-row.is-notfound,
.reference-check-live-row.is-pendingreview {
  border-color: #fed7aa;
  background: #fffaf5;
}

.reference-check-live-head {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 8px;
}

.reference-check-live-head strong {
  color: #0f172a;
  font-size: 12px;
  font-weight: 900;
}

.reference-check-live-head span,
.reference-check-live-head em {
  min-height: 22px;
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  font-style: normal;
  font-size: 11px;
  font-weight: 900;
}

.reference-check-live-head span {
  background: #ecfeff;
  color: #0e7490;
}

.reference-check-live-row.is-notfound .reference-check-live-head span,
.reference-check-live-row.is-pendingreview .reference-check-live-head span {
  background: #fff7ed;
  color: #9a3412;
}

.reference-check-live-head em {
  background: #f1f5f9;
  color: #64748b;
}

.reference-check-live-columns {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
  gap: 10px;
}

.reference-check-live-columns p {
  min-width: 0;
  margin: 0;
  padding: 9px 10px;
  border-radius: 10px;
  background: #f8fafc;
  color: #334155;
  font-size: 12px;
  line-height: 1.65;
  word-break: break-word;
}

.reference-check-live-columns p + p {
  background: #fff;
  border: 1px solid #e2e8f0;
  color: #0f172a;
}

.reference-check-live-foot {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.reference-check-live-foot a,
.reference-check-live-foot span {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid #dbe3ef;
  background: #f8fafc;
  color: #475569;
  font-size: 11px;
  font-weight: 800;
  text-decoration: none;
}

.reference-check-live-foot a {
  border-color: rgba(139, 21, 56, 0.25);
  background: #fff1f2;
  color: var(--primary);
}

.reference-check-quiet-btn,
.reference-check-result-actions button,
.reference-check-pane-title button {
  min-height: 34px;
  padding: 6px 12px;
  border: 1px solid #dbe3ef;
  border-radius: 9px;
  background: #ffffff;
  color: #475569;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.18s ease;
}

.reference-check-quiet-btn:hover,
.reference-check-quiet-btn:focus-visible,
.reference-check-result-actions button:hover,
.reference-check-result-actions button:focus-visible,
.reference-check-pane-title button:hover,
.reference-check-pane-title button:focus-visible {
  border-color: rgba(139, 21, 56, 0.25);
  background: #fff1f2;
  color: var(--primary);
  outline: none;
}

.reference-check-report-summary span.is-warning {
  background: #fff7ed;
  color: #9a3412;
}

.reference-check-report-summary span.is-success {
  background: #f0fdf4;
  color: #166534;
}

.reference-check-result-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 10px;
}

.reference-check-download-card {
  margin-top: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid rgba(14, 116, 144, 0.18);
  border-radius: 14px;
  background:
    linear-gradient(135deg, rgba(236, 254, 255, 0.78), rgba(248, 250, 252, 0.96)),
    #fff;
}

.reference-format-modal.is-reference-completed .reference-format-report-summary {
  padding: 9px 12px;
}

.reference-format-modal.is-reference-completed .reference-check-download-card {
  margin-top: 10px;
  padding: 12px 14px;
  border-radius: 12px;
}

.reference-format-modal.is-reference-completed .reference-format-ok,
.reference-format-modal.is-reference-completed .reference-format-warnings {
  margin-top: 10px;
}

.reference-check-download-card > div {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.reference-check-download-card strong {
  color: #0f172a;
  font-size: 15px;
  font-weight: 900;
}

.reference-check-download-card span {
  color: #64748b;
  font-size: 12px;
  line-height: 1.5;
}

.reference-check-download-actions {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.reference-check-download-primary {
  min-height: 40px;
  flex: 0 0 auto;
  padding: 0 16px;
  border: 1px solid rgba(139, 21, 56, 0.18);
  border-radius: 10px;
  background: #8b1538;
  color: #fff;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 14px 26px rgba(139, 21, 56, 0.16);
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.reference-check-download-primary:hover,
.reference-check-download-primary:focus-visible {
  background: #6f102d;
  box-shadow: 0 16px 30px rgba(139, 21, 56, 0.22);
  transform: translateY(-1px);
  outline: none;
}

.reference-check-final-primary {
  min-height: 40px;
  flex: 0 0 auto;
  padding: 0 16px;
  border: 1px solid rgba(4, 120, 87, 0.2);
  border-radius: 10px;
  background: linear-gradient(135deg, #059669, #047857);
  color: #fff;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 14px 26px rgba(4, 120, 87, 0.16);
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.reference-check-final-primary:hover,
.reference-check-final-primary:focus-visible {
  background: linear-gradient(135deg, #047857, #065f46);
  box-shadow: 0 16px 30px rgba(4, 120, 87, 0.22);
  transform: translateY(-1px);
  outline: none;
}

.reference-check-result-modal {
  align-items: center;
  padding: 12px;
}

.reference-check-result-dialog {
  width: min(1560px, calc(100vw - 24px));
  height: min(980px, calc(100dvh - 24px));
  max-height: none;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 26px 76px rgba(15, 23, 42, 0.24);
  border: 1px solid rgba(226, 232, 240, 0.96);
}

.reference-check-result-header {
  flex: 0 0 auto;
}

.reference-check-result-stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  padding: 10px 22px;
  border-bottom: 1px solid #e5e7eb;
  background: linear-gradient(180deg, #f8fafc, #fff);
}

.reference-check-result-stats span {
  min-width: 0;
  padding: 7px 10px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #fff;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}

.reference-check-result-stats strong {
  margin-left: 4px;
  color: #0f172a;
  font-size: 15px;
}

.reference-check-result-body {
  min-height: 0;
  flex: 1 1 auto;
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  gap: 16px;
  padding: 18px 24px;
  overflow: hidden;
  background: #fff;
}

.reference-check-review-body {
  min-height: 0;
  flex: 1 1 auto;
  padding: 14px 22px 18px;
  overflow-y: auto;
  background:
    linear-gradient(180deg, #f8fafc 0%, #fff 44%);
  scrollbar-gutter: stable;
}

.reference-check-full-body {
  display: grid;
  gap: 16px;
  padding: 16px 20px 18px;
}

.reference-check-document-audit,
.reference-check-full-list {
  min-width: 0;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.055);
}

.reference-check-document-audit {
  padding: 14px;
}

.reference-check-document-audit.has-issues {
  border-color: #fed7aa;
  background: linear-gradient(180deg, #fff, #fffaf5);
}

.reference-check-document-audit.is-clean {
  border-color: #bbf7d0;
  background: linear-gradient(180deg, #fff, #f7fef9);
}

.reference-check-document-audit-head,
.reference-check-full-list-title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.reference-check-document-audit-head > div {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.reference-check-document-audit-head strong,
.reference-check-full-list-title strong {
  color: #0f172a;
  font-size: 15px;
  font-weight: 900;
}

.reference-check-document-audit-head span,
.reference-check-full-list-title span {
  color: #64748b;
  font-size: 12px;
  line-height: 1.5;
  font-weight: 800;
}

.reference-check-document-audit-head em {
  flex: 0 0 auto;
  max-width: 320px;
  padding: 5px 10px;
  border-radius: 999px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  color: #475569;
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.reference-check-document-stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}

.reference-check-document-stats span {
  min-width: 0;
  padding: 8px 9px;
  border-radius: 10px;
  background: rgba(248, 250, 252, 0.9);
  border: 1px solid #e2e8f0;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}

.reference-check-document-stats b {
  margin-left: 4px;
  color: #0f172a;
  font-size: 15px;
}

.reference-check-document-issues,
.reference-check-author-comments {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.reference-check-document-issues p,
.reference-check-document-ok {
  margin: 0;
  padding: 9px 10px;
  border-radius: 10px;
  font-size: 12px;
  line-height: 1.55;
  font-weight: 800;
}

.reference-check-document-issues p {
  background: #fff7ed;
  border: 1px solid #fed7aa;
  color: #9a3412;
}

.reference-check-document-ok {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  color: #166534;
}

.reference-check-citation-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 12px;
  padding: 10px;
  border-radius: 12px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}

.reference-check-citation-strip span,
.reference-check-citation-strip em {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border-radius: 999px;
  background: #ecfeff;
  color: #0e7490;
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
}

.reference-check-citation-strip span.is-warning {
  background: #fff1f2;
  color: #be123c;
  box-shadow: inset 0 0 0 1px rgba(190, 18, 60, 0.18);
}

.reference-check-author-comments {
  padding-top: 10px;
  border-top: 1px solid #fed7aa;
}

.reference-check-author-comments > strong {
  color: #9a3412;
  font-size: 13px;
  font-weight: 900;
}

.reference-check-author-comments article {
  padding: 10px 11px;
  border-radius: 10px;
  border: 1px solid #fed7aa;
  background: #fffaf5;
}

.reference-check-author-comments b {
  color: #7c2d12;
  font-size: 12px;
}

.reference-check-author-comments p,
.reference-check-author-comments small {
  display: block;
  margin: 5px 0 0;
  color: #9a3412;
  font-size: 12px;
  line-height: 1.55;
}

.reference-check-author-comments small {
  color: #64748b;
}

.reference-check-full-list {
  display: grid;
  gap: 12px;
  padding: 14px;
}

.reference-check-full-row {
  min-width: 0;
  display: grid;
  gap: 10px;
  padding: 13px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.045);
}

.reference-check-full-row.has-change {
  border-color: rgba(139, 21, 56, 0.22);
}

.reference-check-full-row.is-notfound,
.reference-check-full-row.is-pendingreview {
  border-color: #fed7aa;
  background: #fffaf5;
}

.reference-check-full-row-head {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px;
}

.reference-check-full-row-head strong,
.reference-check-full-row-head span,
.reference-check-full-row-head em {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border-radius: 999px;
  font-size: 11px;
  line-height: 1;
  font-style: normal;
  font-weight: 900;
}

.reference-check-full-row-head strong {
  background: #f1f5f9;
  color: #475569;
}

.reference-check-full-row-head span {
  background: #ecfeff;
  color: #0e7490;
}

.reference-check-full-row-head em {
  background: #fff1f2;
  color: var(--primary);
}

.reference-check-full-row-head em.is-soft {
  background: #f8fafc;
  color: #64748b;
}

.reference-check-full-original,
.reference-check-full-verified {
  min-width: 0;
  padding: 11px 12px;
  border-radius: 11px;
  border: 1px solid #e2e8f0;
}

.reference-check-full-original {
  background: #fff;
}

.reference-check-full-verified {
  background: #f8fbff;
  border-color: #cfe8f3;
}

.reference-check-full-original b,
.reference-check-full-verified b {
  display: block;
  margin-bottom: 7px;
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
}

.reference-check-full-original p,
.reference-check-full-verified p {
  margin: 0;
  color: #1f2937;
  font-size: 13px;
  line-height: 1.8;
  white-space: pre-wrap;
  word-break: break-word;
}

.reference-check-full-original mark,
.reference-check-full-verified mark {
  padding: 1px 2px;
  border-radius: 4px;
  background: #fff1f2;
  color: #be123c;
  font-weight: 900;
}

.reference-check-full-verified p {
  color: #0f3f56;
  font-weight: 700;
}

.reference-check-inline-link {
  color: var(--primary);
  font-weight: 900;
  text-decoration: underline;
  text-underline-offset: 3px;
  overflow-wrap: anywhere;
}

.reference-check-review-shell {
  display: grid;
  gap: 12px;
}

.reference-check-review-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 10px 14px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.05);
}

.reference-check-review-top > div:first-child {
  min-width: 0;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.reference-check-review-top span,
.reference-check-review-top strong,
.reference-check-review-top em,
.reference-check-review-top b {
  min-height: 26px;
  display: inline-flex;
  align-items: center;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 12px;
  line-height: 1;
  font-style: normal;
  font-weight: 900;
}

.reference-check-review-top span {
  background: #f1f5f9;
  color: #475569;
}

.reference-check-review-top strong {
  background: #ecfeff;
  color: #0e7490;
}

.reference-check-review-top em {
  background: #fff7ed;
  color: #9a3412;
}

.reference-check-review-top b {
  background: #f0fdf4;
  color: #166534;
}

.reference-check-review-count {
  flex: 0 0 auto;
  color: #64748b;
  font-size: 13px;
  font-weight: 900;
}

.reference-check-review-progress {
  height: 7px;
  overflow: hidden;
  border-radius: 999px;
  background: #e2e8f0;
}

.reference-check-review-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #8b1538, #0e7490);
  transition: width 0.22s ease;
}

.reference-check-review-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
  gap: 12px;
}

.reference-check-review-grid section {
  min-width: 0;
  padding: 13px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.055);
}

.reference-check-review-grid section.is-result {
  border-color: #e2e8f0;
  background: #fff;
}

.reference-check-review-grid section.is-result.has-change {
  border-color: rgba(139, 21, 56, 0.24);
  box-shadow: 0 12px 26px rgba(139, 21, 56, 0.08);
}

.reference-check-review-grid section.is-result.is-notfound,
.reference-check-review-grid section.is-result.is-pendingreview {
  border-color: #fed7aa;
  background: #fffaf5;
}

.reference-check-review-label {
  margin-bottom: 10px;
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
}

.reference-check-review-grid p {
  margin: 0;
  color: #1f2937;
  font-size: 14px;
  line-height: 1.8;
  word-break: break-word;
}

.reference-check-diff-preview {
  min-height: 94px;
  max-height: 150px;
  overflow-y: auto;
  padding: 12px 13px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #f8fafc;
  color: #1f2937;
  font-size: 14px;
  line-height: 1.8;
  word-break: break-word;
  white-space: pre-wrap;
}

.reference-check-diff-preview mark {
  padding: 1px 2px;
  border-radius: 4px;
  background: #fff1f2;
  color: #be123c;
  font-weight: 800;
}

.reference-check-diff-muted {
  color: #94a3b8;
  font-weight: 700;
}

.reference-check-edit-label {
  margin: 10px 0 6px;
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
}

.reference-check-review-textarea {
  min-height: 104px;
  font-size: 13px;
  line-height: 1.7;
}

.reference-check-field-audit {
  margin-top: 10px;
  padding: 9px 11px;
  border-radius: 10px;
  border: 1px solid #dbe3ef;
  background: #f8fafc;
}

.reference-check-field-audit strong {
  display: block;
  margin-bottom: 5px;
  color: #334155;
  font-size: 12px;
  font-weight: 900;
}

.reference-check-field-audit span {
  display: block;
  color: #64748b;
  font-size: 12px;
  line-height: 1.55;
}

.reference-check-field-audit.has-issues {
  border-color: #fed7aa;
  background: #fffaf5;
}

.reference-check-field-audit.has-issues strong {
  color: #9a3412;
}

.reference-check-field-audit ul {
  margin: 6px 0 0;
  padding-left: 18px;
  color: #9a3412;
  font-size: 12px;
  line-height: 1.65;
}

.reference-check-result-dialog .reference-format-header {
  flex: 0 0 auto;
  padding: 16px 22px 14px;
}

.reference-check-result-dialog .reference-format-footer {
  flex: 0 0 auto;
  padding: 10px 22px 12px;
  box-shadow: 0 -10px 28px rgba(15, 23, 42, 0.06);
}

.reference-check-field-audit b {
  color: #7c2d12;
}

.reference-check-review-empty {
  padding: 42px 18px;
  border: 1px dashed #cbd5e1;
  border-radius: 14px;
  background: #f8fafc;
  color: #64748b;
  font-size: 14px;
  text-align: center;
}

.reference-check-review-primary,
.reference-check-review-secondary {
  min-height: 42px;
  padding: 0 16px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 900;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.reference-check-review-primary {
  border: 1px solid #8b1538;
  background: #8b1538;
  color: #fff;
  box-shadow: 0 10px 24px rgba(139, 21, 56, 0.18);
}

.reference-check-review-secondary {
  border: 1px solid #dbe3ef;
  background: #fff;
  color: #475569;
}

.reference-check-review-primary:hover,
.reference-check-review-primary:focus-visible,
.reference-check-review-secondary:hover,
.reference-check-review-secondary:focus-visible {
  transform: translateY(-1px);
  outline: none;
}

.reference-check-review-primary:hover,
.reference-check-review-primary:focus-visible {
  background: #6f102c;
  box-shadow: 0 14px 28px rgba(139, 21, 56, 0.24);
}

.reference-check-review-secondary:hover,
.reference-check-review-secondary:focus-visible {
  border-color: rgba(139, 21, 56, 0.24);
  background: #fff1f2;
  color: #8b1538;
}

.reference-check-review-secondary:disabled {
  cursor: not-allowed;
  opacity: 0.48;
  transform: none;
  background: #f8fafc;
  color: #94a3b8;
}

.reference-check-result-pane {
  min-width: 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  background: #f8fafc;
  overflow: hidden;
}

.reference-check-pane-title {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-bottom: 1px solid #e2e8f0;
  background: #fff;
}

.reference-check-pane-title strong {
  color: #1f2937;
  font-size: 14px;
  font-weight: 900;
}

.reference-check-pane-title span {
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}

.reference-check-list {
  min-height: 0;
  overflow-y: auto;
  display: grid;
  gap: 10px;
  padding: 12px;
}

.reference-check-original-row,
.reference-check-verified-row {
  min-width: 0;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  padding: 10px 12px;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.05);
}

.reference-check-original-row {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  gap: 10px;
}

.reference-check-original-row > span {
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
  line-height: 1.7;
  text-align: right;
}

.reference-check-original-row p,
.reference-check-verified-row p {
  margin: 0;
  color: #1f2937;
  font-size: 13px;
  line-height: 1.7;
  word-break: break-word;
}

.reference-check-editable {
  width: 100%;
  min-height: 68px;
  resize: vertical;
  padding: 10px 11px;
  border: 1px solid #dbe3ef;
  border-radius: 10px;
  background: #fff;
  color: #111827;
  font-family: "Noto Sans SC", "Microsoft YaHei", system-ui, sans-serif;
  font-size: 13px;
  line-height: 1.7;
  word-break: break-word;
  overflow: hidden;
  outline: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.reference-check-editable:focus {
  border-color: var(--primary);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(139, 21, 56, 0.11);
}

.reference-check-review-textarea.reference-check-editable {
  font-size: 13px;
  line-height: 1.7;
}

.reference-check-verified-row.is-changed {
  border-color: #f8c9d5;
  background: #fffafb;
}

.reference-check-verified-row.is-notfound,
.reference-check-verified-row.is-pendingreview {
  border-color: #fed7aa;
  background: #fffaf5;
}

.reference-check-row-head {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 8px;
}

.reference-check-status {
  padding: 3px 8px;
  border-radius: 999px;
  background: #ecfeff;
  color: #0e7490;
  font-size: 11px;
  font-weight: 900;
}

.reference-check-verified-row.is-notfound .reference-check-status,
.reference-check-verified-row.is-pendingreview .reference-check-status {
  background: #fff7ed;
  color: #9a3412;
}

.reference-check-row-head em,
.reference-check-row-head strong {
  font-style: normal;
  color: #64748b;
  font-size: 11px;
  font-weight: 800;
}

.reference-check-row-head strong {
  color: var(--primary);
}

.reference-check-row-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 9px;
}

.reference-check-row-actions a,
.reference-check-row-actions span {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 8px;
  border-radius: 999px;
  border: 1px solid #dbe3ef;
  background: #f8fafc;
  color: #475569;
  font-size: 11px;
  font-weight: 800;
  text-decoration: none;
}

.reference-check-row-actions a {
  border-color: rgba(139, 21, 56, 0.25);
  background: #fff1f2;
  color: var(--primary);
}

.reference-check-row-actions a:hover,
.reference-check-row-actions a:focus-visible {
  background: var(--primary);
  color: #fff;
  outline: none;
}

.reference-check-row-notes {
  display: grid;
  gap: 5px;
  margin-top: 8px;
}

.reference-check-row-notes span {
  padding: 6px 8px;
  border-radius: 8px;
  background: rgba(255, 247, 237, 0.9);
  color: #9a3412;
  font-size: 11px;
  line-height: 1.45;
}

.reference-check-summary-modal {
  align-items: center;
}

.reference-check-summary-dialog {
  width: min(920px, 95vw);
  max-height: 90vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 28px 80px rgba(15, 23, 42, 0.26);
  border: 1px solid rgba(226, 232, 240, 0.96);
}

.reference-check-summary-header {
  flex: 0 0 auto;
}

.reference-check-summary-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  padding: 14px 24px;
  border-bottom: 1px solid #e5e7eb;
  background: #f8fafc;
}

.reference-check-summary-stats span {
  min-width: 0;
  padding: 10px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}

.reference-check-summary-stats span.is-warning {
  border-color: #fed7aa;
  background: #fff7ed;
  color: #9a3412;
}

.reference-check-summary-stats span.is-success {
  border-color: #bbf7d0;
  background: #f0fdf4;
  color: #166534;
}

.reference-check-summary-stats strong {
  margin-left: 4px;
  color: #0f172a;
  font-size: 18px;
}

.reference-check-summary-body {
  min-height: 0;
  overflow-y: auto;
  padding: 18px 24px 20px;
  background: #fff;
}

.reference-check-summary-alert,
.reference-check-summary-ok {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 12px;
  margin-bottom: 12px;
}

.reference-check-summary-alert {
  border: 1px solid #fed7aa;
  background: #fff7ed;
}

.reference-check-summary-ok {
  border: 1px solid #bbf7d0;
  background: #f0fdf4;
}

.reference-check-summary-alert strong,
.reference-check-summary-ok strong {
  color: #0f172a;
  font-size: 14px;
  font-weight: 900;
}

.reference-check-summary-alert span,
.reference-check-summary-ok span {
  color: #64748b;
  font-size: 12px;
  line-height: 1.5;
  font-weight: 700;
}

.reference-check-summary-list {
  display: grid;
  gap: 10px;
}

.reference-check-summary-list article {
  min-width: 0;
  padding: 12px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.05);
}

.reference-check-summary-list article > div {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}

.reference-check-summary-list strong {
  color: #0f172a;
  font-size: 12px;
  font-weight: 900;
}

.reference-check-summary-list article span {
  min-height: 22px;
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  background: #fff7ed;
  color: #9a3412;
  font-size: 11px;
  font-weight: 900;
}

.reference-check-summary-list p {
  margin: 0;
  color: #334155;
  font-size: 13px;
  line-height: 1.7;
  word-break: break-word;
}

.reference-check-summary-list a {
  margin-top: 8px;
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid rgba(139, 21, 56, 0.25);
  background: #fff1f2;
  color: var(--primary);
  font-size: 12px;
  font-weight: 900;
  text-decoration: none;
}

.reference-check-summary-list a:hover,
.reference-check-summary-list a:focus-visible {
  background: var(--primary);
  color: #fff;
  outline: none;
}

@media (prefers-reduced-motion: reduce) {
  .reference-check-spinner,
  .reference-check-orbit i,
  .reference-check-orbit b,
  .reference-check-orbit::after,
  .reference-check-progress-meter span::after,
  .reference-check-animation-wrap::before,
  .reference-check-verifier-paper::before,
  .reference-check-verifier-route span,
  .reference-check-verifier-fields span {
    animation: none;
  }
}

@media (max-width: 760px) {
  .editor-toolbox-grid,
  .editor-toolbox-grid-compact {
    grid-template-columns: 1fr;
  }

  .editor-toolbox-header {
    padding: 18px;
  }

  .editor-toolbox-body {
    padding: 18px;
  }

  .reference-format-body {
    grid-template-columns: 1fr;
    padding: 18px;
  }

  .reference-check-result-modal {
    padding: 6px;
  }

  .reference-check-result-dialog {
    width: calc(100vw - 12px);
    height: calc(100dvh - 12px);
    border-radius: 12px;
  }

  .reference-format-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .reference-format-footer > div,
  .reference-format-footer .btn {
    width: 100%;
  }

  .reference-check-progress-meta,
  .reference-check-progress-row,
  .reference-check-result-stats,
  .reference-check-summary-stats,
  .reference-check-live-columns,
  .reference-check-review-grid,
  .reference-check-result-body {
    grid-template-columns: 1fr;
  }

  .reference-check-progress-row p {
    white-space: normal;
  }

  .reference-check-running-head,
  .reference-check-review-top {
    align-items: stretch;
    flex-direction: column;
  }

  .reference-check-download-card {
    align-items: stretch;
    flex-direction: column;
  }

  .reference-check-download-actions {
    width: 100%;
    justify-content: stretch;
  }

  .reference-check-download-primary,
  .reference-check-final-primary {
    width: 100%;
  }

  .reference-check-progress-card {
    min-height: 520px;
    padding: 20px;
  }

  .reference-check-animation-wrap {
    min-height: 260px;
  }

  .reference-check-verifier {
    width: 100%;
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .reference-check-verifier-paper {
    width: 100%;
    height: 112px;
  }

  .reference-check-verifier-route {
    width: 70%;
    justify-self: center;
  }

  .reference-check-animation-copy {
    top: 14px;
    right: 14px;
  }

  .reference-check-review-body {
    padding: 12px 12px 16px;
  }

  .reference-check-summary-alert,
  .reference-check-summary-ok {
    align-items: flex-start;
    flex-direction: column;
  }

  .reference-check-result-body {
    overflow-y: auto;
  }

  .reference-check-result-pane {
    min-height: 340px;
  }
}

.editor-workspace-container .proofread-transfer-action-btn {
  background: #0891b2;
  color: #fff;
  border: 1px solid #0e7490;
  padding: 5px 10px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.2;
  min-height: 28px;
  white-space: nowrap;
}

.editor-workspace-container .proofread-transfer-action-btn:hover {
  background: #0e7490;
}

.editor-workspace-container .proofread-transfer-action-btn.is-pending,
.editor-workspace-container .proofread-transfer-action-btn:disabled {
  background: #fef3c7;
  color: #92400e;
  border-color: #fcd34d;
  cursor: not-allowed;
  opacity: 1;
}

.proofread-transfer-dialog {
  width: min(520px, 94vw);
  padding: 18px;
}

.proofread-transfer-dialog .modal-body {
  display: grid;
  gap: 14px;
}

.proofread-transfer-summary {
  display: grid;
  gap: 8px;
  padding: 12px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
}

.proofread-transfer-summary div {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 10px;
  align-items: start;
  font-size: 13px;
  color: #475569;
}

.proofread-transfer-summary span {
  color: #64748b;
  white-space: nowrap;
}

.proofread-transfer-summary strong {
  color: #0f172a;
  font-weight: 700;
  line-height: 1.45;
  word-break: break-word;
}

.proofread-transfer-hint,
.proofread-transfer-reason {
  font-size: 13px;
  line-height: 1.5;
  color: #64748b;
}

.proofread-transfer-warning {
  color: #92400e;
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-radius: 6px;
  padding: 8px 10px;
}

.proofread-transfer-question {
  font-size: 15px;
  line-height: 1.6;
  color: #0f172a;
}

/* 题目列：最多 2 行（命中任意一种即可生效） */
td.title-cell,
td[data-field="title"],
td[data-col="title"]{
  white-space: normal;
  display: -webkit-box;
  -webkit-box-orient: vertical;

  -webkit-line-clamp: 2; /* 现有兼容写法 */
  line-clamp: 2;         /* 标准属性：加上用于减少提示/增强兼容 */

  overflow: hidden;
  text-overflow: ellipsis;
  word-break: break-word;
  line-height: 1.45;
  max-height: calc(1.45em * 2);
  min-width: 320px;
  max-width: 520px;
}



.editor-toolbox-title-emoji {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

.editor-toolbox-emoji {
  display: inline-block;
  font-family: "Segoe UI Emoji", "Apple Color Emoji", "Noto Color Emoji", sans-serif;
  font-style: normal;
  line-height: 1;
}

.editor-toolbox-title-emoji .editor-toolbox-emoji { font-size: 36px; }

.editor-toolbox-card-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: inherit;
}

.editor-toolbox-card:nth-child(2) .editor-toolbox-card-icon {
  background: transparent;
  color: inherit;
}

.editor-toolbox-card-icon .editor-toolbox-emoji { font-size: 30px; }

@media (max-width: 720px) {
  .editor-toolbox-title-emoji { width: 42px; height: 42px; }
  .editor-toolbox-title-emoji .editor-toolbox-emoji { font-size: 31px; }
  .editor-toolbox-card-icon .editor-toolbox-emoji { font-size: 27px; }
}

/* Smart revision: compact editorial workspace overrides */
.smart-revision-dialog {
  width: min(940px, 94vw);
  max-height: min(860px, 88dvh);
  border: 1px solid #e1e7ee;
  border-radius: 16px;
  box-shadow: 0 26px 70px rgba(15, 23, 42, .22);
}

.smart-revision-header {
  min-height: 96px;
  padding: 20px 28px;
  border-top: 0;
  background: #fff;
}

.smart-revision-title-emoji {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

.smart-revision-title-emoji .editor-toolbox-emoji { font-size: 38px; }

.smart-revision-header .editor-toolbox-title-block h3 {
  letter-spacing: 0;
  color: #172033;
  font-size: 24px;
  font-weight: 800;
}

.smart-revision-header .editor-toolbox-title-block p {
  color: #60738b;
  font-size: 14px;
}

.smart-revision-body.has-file .smart-revision-upload-panel {
  padding: 12px 28px;
  background: #fbfcfe;
}

.smart-revision-file-summary > span {
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: inherit;
}

.smart-revision-file-summary > span .editor-toolbox-emoji { font-size: 28px; }

.smart-revision-body.has-file .smart-revision-result-panel {
  min-height: 160px;
  padding: 20px 28px 24px;
  background: #f4f7fa;
}

.smart-revision-ready {
  min-height: 120px;
  padding: 22px 24px;
  border-color: #d5e2e9;
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(15, 23, 42, .04);
}

.smart-revision-ready-icon {
  width: 48px;
  height: 48px;
  border: 0;
  background: transparent;
  color: inherit;
}

.smart-revision-ready-icon .editor-toolbox-emoji { font-size: 34px; }

.smart-revision-dropzone-icon {
  width: 52px;
  height: 52px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: inherit;
  box-shadow: none;
}

.smart-revision-dropzone-icon .editor-toolbox-emoji { font-size: 36px; }

.smart-revision-reading-steps li > .smart-revision-step-icon {
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.smart-revision-reading-steps li.is-current > .smart-revision-step-icon {
  color: inherit;
  box-shadow: none;
}

.smart-revision-reading-steps li.is-done > .smart-revision-step-icon {
  color: inherit;
}

.smart-revision-step-icon .editor-toolbox-emoji { font-size: 24px; }
.smart-revision-reading-file > span .editor-toolbox-emoji { font-size: 22px; }

@media (max-width: 720px) {
  .smart-revision-header { padding: 16px 18px; }
  .smart-revision-title-emoji { width: 46px; height: 46px; }
  .smart-revision-title-emoji .editor-toolbox-emoji { font-size: 32px; }
  .smart-revision-header .editor-toolbox-title-block h3 { font-size: 20px; }
  .smart-revision-body.has-file .smart-revision-upload-panel,
  .smart-revision-body.has-file .smart-revision-result-panel { padding-left: 18px; padding-right: 18px; }
}


/* Chief proofread detail: keep manuscript table as the primary workspace */
.chief-proofread-detail-page .chief-proofread-process-links summary::-webkit-details-marker,
.chief-proofread-detail-page #proofreadStatsDetails summary::-webkit-details-marker {
  display: none;
}

.chief-proofread-detail-page .chief-proofread-process-links[open] summary,
.chief-proofread-detail-page #proofreadStatsDetails[open] summary {
  border-color: #bfdbfe;
}

.chief-proofread-detail-page .chief-proofread-compact-summary {
  align-items: center;
}

.chief-proofread-detail-page .chief-proofread-compact-summary > span:first-child {
  flex: 1 1 auto;
}

.chief-proofread-detail-page .chief-proofread-compact-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  min-width: 72px;
  min-height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  background: #eff6ff;
  box-sizing: border-box;
}

.chief-proofread-detail-page .chief-proofread-process-links #collectionProcessLinksPanel {
  margin: 0 !important;
}

.chief-proofread-detail-page .card-header-with-search {
  gap: 12px;
}

@media (max-width: 1280px) {
  .chief-proofread-detail-page {
    height: calc(100vh - 118px) !important;
  }

  .chief-proofread-detail-page .card-header-with-search {
    align-items: flex-start;
    flex-direction: column;
    padding: 10px 16px !important;
  }

  .chief-proofread-detail-page .card-header-with-search .search-box {
    width: 100%;
    overflow-x: auto;
    padding-bottom: 2px;
  }
}
/* 操作列/编辑按钮：始终一行 */
td.actions-cell,
td[data-col="actions"]{
  white-space: nowrap;
}

/* 表格操作按钮区域 */
.table-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.table-actions .btn {
  padding: 6px 10px;
  font-size: 12px;
}

/* =====================
   状态标签
===================== */
.status {
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  display: inline-block;
}

.status-wait { background: #eee; color: #666; }
.status-success { background: #e8f7ef; color: var(--success); }
.status-warning { background: #fff3e0; color: var(--warning); }
.status-danger { background: #fdecea; color: var(--danger); }

.status-proofing { background: #eef6ff; color: var(--info); }
.status-proof-done { background: #e8f7ef; color: var(--success); }

/* =====================
   倒计时 / 超时
===================== */
.countdown-safe { color: var(--success); font-weight: 700; }
.countdown-warn { color: var(--warning); font-weight: 800; }
.countdown-danger,
.overdue {
  color: var(--danger);
  font-weight: 900;
  animation: blink 1.2s infinite;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

/* =====================
   链接
===================== */
a { color: var(--info); text-decoration: none; }
a:hover { color: var(--primary); text-decoration: underline; }

.proof-link {
  font-weight: 800;
  color: var(--info);
  text-decoration: underline;
}

/* =====================
   模态弹窗（修复“显示不全”）
   - max-height + 内部滚动
===================== */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  padding: 18px;
}

.modal-content {
  width: 920px;
  max-width: 96vw;
  max-height: 88vh;     /* 关键：限制高度 */
  overflow: auto;       /* 关键：内容滚动 */
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border);
  padding-bottom: 10px;
  margin-bottom: 14px;
  position: sticky;
  top: 0;
  background: #fff;
  z-index: 1;
}

.modal-title {
  font-size: 18px;
  font-weight: 800;
}

.close-btn {
  background: none;
  border: none;
  font-size: 22px;
  cursor: pointer;
  color: #999;
}

.close-btn:hover { color: var(--danger); }

/* =====================
   Excel 导入弹窗
===================== */
.excel-import-modal {
  padding: 8px;
}

.excel-import-modal.is-minimized {
  display: none;
}

.excel-import-modal .modal-content {
  width: min(1180px, 96vw);
  max-height: calc(100vh - 16px);
  padding: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border-radius: 18px;
  box-shadow: 0 28px 80px rgba(15, 23, 42, 0.22);
}

.excel-import-modal .modal-header {
  margin-bottom: 0;
  padding: 14px 22px;
  border-bottom: 1px solid #e5e7eb;
  background: #fff;
  position: sticky;
  top: 0;
  z-index: 2;
  align-items: flex-start;
}

.excel-import-modal .modal-title-block {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.excel-import-modal .modal-title {
  margin: 0;
  font-size: 18px;
  font-weight: 800;
  color: #0f172a;
}

.excel-import-modal .modal-subtitle {
  font-size: 12px;
  color: #64748b;
}

.excel-import-header-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 2px;
}

.excel-import-header-chip {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  color: #475569;
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
}

.excel-import-close-btn {
  width: 44px;
  height: 44px;
  border: 1px solid #dbe3f0;
  border-radius: 14px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  color: #334155;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
  transition: all 0.18s ease;
  flex-shrink: 0;
}

.excel-import-close-btn:hover {
  background: #fff4f6;
  border-color: #f8c3cd;
  color: #9f1239;
  box-shadow: 0 12px 24px rgba(190, 24, 93, 0.12);
  transform: translateY(-1px) scale(1.02);
}

.excel-import-close-btn svg {
  width: 18px;
  height: 18px;
}

.excel-import-body {
  flex: 1;
  min-height: 0;
  padding: 14px 18px 16px;
  background: linear-gradient(180deg, #fcfcfd 0%, #f8fafc 100%);
  overflow-y: auto;
}

.excel-import-body.is-preview-mode {
  overflow: hidden;
}

.excel-import-shell {
  display: grid;
  gap: 12px;
}

.excel-import-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(280px, 0.75fr);
  gap: 12px;
  align-items: start;
}

.excel-import-upload-card,
.excel-import-aside-card,
.excel-import-fields-card {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 18px;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.05);
}

.excel-import-upload-card,
.excel-import-fields-card {
  padding: 14px 16px;
}

.excel-import-upload-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.excel-import-aside-card {
  padding: 16px;
}

.excel-import-section-title {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 12px;
}

.excel-import-icon-wrap {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: linear-gradient(135deg, #eff6ff, #e0e7ff);
  color: #4f46e5;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.excel-import-icon-wrap svg {
  width: 20px;
  height: 20px;
}

.excel-import-section-title h2,
.excel-import-section-title h3 {
  margin: 0;
  font-size: 18px;
  line-height: 1.2;
  color: #0f172a;
  font-weight: 800;
}

.excel-import-section-title h3 {
  font-size: 16px;
}

.excel-import-section-title p {
  margin: 4px 0 0;
  font-size: 12px;
  line-height: 1.45;
  color: #64748b;
}

.excel-import-action-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.excel-import-dropzone {
  flex: 1;
  min-width: 0;
  min-height: 82px;
  padding: 14px 16px;
  border: 1px solid #dbe3ee;
  border-radius: 14px;
  cursor: pointer;
  background: linear-gradient(135deg, #ffffff 0%, #f8fbff 100%);
  display: flex;
  align-items: center;
  justify-content: flex-start;
  text-align: left;
  gap: 12px;
  transition: all 0.2s ease;
  position: relative;
}

.excel-import-dropzone:hover,
.excel-import-dropzone.is-drag-over {
  border-color: #8b1538;
  background: linear-gradient(135deg, #fff8fb 0%, #f8fbff 100%);
  box-shadow: 0 8px 22px rgba(139, 21, 56, 0.08);
  transform: translateY(-1px);
}

.excel-import-dropzone.is-selected {
  border-color: #4f46e5;
  background: linear-gradient(135deg, #f8fafc 0%, #eef2ff 100%);
}

.excel-import-dropzone.is-selected .excel-import-drop-graphic {
  background: linear-gradient(135deg, #eef2ff, #e0e7ff);
  color: #4f46e5;
  box-shadow: 0 10px 24px rgba(79, 70, 229, 0.14);
}

.excel-import-drop-content {
  min-width: 0;
  max-width: 100%;
  display: grid;
  gap: 4px;
  width: 100%;
}

.excel-import-drop-graphic {
  width: 42px;
  height: 42px;
  margin: 0;
  border-radius: 12px;
  background: linear-gradient(135deg, #fff7ed, #ffedd5);
  color: #ea580c;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 24px rgba(249, 115, 22, 0.14);
}

.excel-import-drop-graphic svg {
  width: 21px;
  height: 21px;
}

.excel-import-drop-title {
  font-size: 13px;
  line-height: 1.4;
  font-weight: 700;
  color: #334155;
  min-width: 0;
  word-break: normal;
}

.excel-import-drop-meta {
  margin-top: 2px;
  font-size: 12px;
  line-height: 1.4;
  color: #64748b;
}

.excel-import-file-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
  padding: 6px 12px;
  border-radius: 999px;
  background: #eef2ff;
  color: #4338ca;
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 0;
  white-space: nowrap;
}

.excel-import-selected-line {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  max-width: 100%;
  min-width: 0;
  white-space: nowrap;
}

.excel-import-selected-name {
  display: inline-block;
  min-width: 0;
  max-width: min(360px, 42vw);
  overflow: hidden;
  text-overflow: ellipsis;
  color: #1e293b;
  font-size: 14px;
  font-weight: 800;
  vertical-align: middle;
}

.excel-import-modal .btn {
  white-space: nowrap;
}

.excel-import-primary-action {
  flex: 0 0 auto;
  min-height: 82px;
  min-width: 188px;
  padding: 0 18px;
  gap: 10px;
  justify-content: center;
  box-shadow: 0 10px 22px rgba(139, 21, 56, 0.18);
}

.excel-import-primary-action svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.excel-import-result {
  margin-top: 0;
}

.excel-import-log-panel {
  display: grid;
  gap: 8px;
  min-height: 126px;
  padding: 12px;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  background: #f8fafc;
}

.excel-import-log-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.excel-import-log-head span {
  color: #0f172a;
  font-size: 13px;
  font-weight: 800;
}

.excel-import-log-head em {
  color: #64748b;
  font-size: 12px;
  font-style: normal;
  line-height: 1.4;
  text-align: right;
}

.excel-import-result:empty {
  min-height: 68px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
}

.excel-import-result:empty::before {
  content: "等待开始导入";
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 68px;
  color: #94a3b8;
  font-size: 13px;
  font-weight: 700;
}

.excel-import-log-panel .excel-import-status {
  background: #ffffff;
  border-color: #dbe3ee;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.04);
}

.excel-import-side-list {
  display: grid;
  gap: 6px;
  margin-top: 10px;
}

.excel-import-side-item {
  padding: 8px 10px;
  border-radius: 14px;
  background: #f8fafc;
  border: 1px solid #e5e7eb;
}

.excel-import-side-item-title {
  font-size: 13px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 2px;
}

.excel-import-side-item-text {
  font-size: 11px;
  line-height: 1.4;
  color: #64748b;
}

.excel-import-note {
  margin-top: 8px;
  padding: 8px 10px;
  border-radius: 12px;
  background: linear-gradient(135deg, #fefce8, #fff7ed);
  border: 1px solid #fde68a;
  font-size: 11px;
  line-height: 1.4;
  color: #92400e;
}

.excel-import-fields-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  margin-top: 10px;
}

.excel-import-field-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  min-height: 46px;
  padding: 8px 10px;
  border-radius: 12px;
  background: #f8fafc;
  border: 1px solid #e5e7eb;
}

.excel-import-field-index {
  min-width: 26px;
  height: 26px;
  border-radius: 8px;
  background: #eef2ff;
  color: #4f46e5;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 800;
  flex-shrink: 0;
}

.excel-import-field-label {
  font-size: 12px;
  line-height: 1.25;
  color: #1e293b;
  font-weight: 700;
}

.excel-import-required {
  display: inline-flex;
  align-items: center;
  margin-left: 8px;
  padding: 2px 8px;
  border-radius: 999px;
  background: #fee2e2;
  color: #dc2626;
  font-size: 11px;
  font-weight: 700;
  vertical-align: middle;
}

.excel-import-required {
  margin-left: 6px;
  padding: 1px 6px;
  font-size: 10px;
}

.excel-import-field-item.is-ai {
  background: #f0f9ff;
  border-color: #bae6fd;
}

.excel-import-field-item.is-added {
  background: #f8fafc;
}

.excel-import-ai-chip,
.excel-import-added-chip {
  display: inline-flex;
  align-items: center;
  height: 18px;
  margin-left: 6px;
  padding: 0 6px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
  white-space: nowrap;
  vertical-align: middle;
}

.excel-import-ai-chip {
  background: #dbeafe;
  color: #1d4ed8;
}

.excel-import-added-chip {
  background: #dcfce7;
  color: #166534;
}

.excel-import-status {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
  color: #334155;
}

.excel-import-status strong {
  display: block;
  margin-bottom: 2px;
  color: #0f172a;
  font-size: 13px;
}

.excel-import-status p {
  margin: 0;
  color: #64748b;
  font-size: 12px;
  line-height: 1.45;
}

.excel-import-status-content {
  flex: 1;
  min-width: 0;
}

.excel-import-status-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 2px;
}

.excel-import-status-head strong {
  margin: 0;
}

.excel-import-status-tools {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.excel-import-status-head span,
.excel-import-status-tools span {
  color: #1d4ed8;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.excel-import-status-tools button {
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  background: #ffffff;
  color: #1d4ed8;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.16s ease;
}

.excel-import-status-tools button:hover {
  border-color: #2563eb;
  background: #dbeafe;
}

.excel-import-status-meter {
  height: 7px;
  margin-top: 10px;
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.12);
  overflow: hidden;
}

.excel-import-status-meter span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #2563eb 0%, #06b6d4 100%);
  transition: width 0.2s ease;
}

.excel-import-status-metrics,
.excel-import-status-steps {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.excel-import-status-metrics span,
.excel-import-status-steps span {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  border: 1px solid #dbeafe;
  background: #fff;
  color: #1e40af;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.excel-import-status-steps span {
  border-color: #e5e7eb;
  color: #64748b;
}

.excel-import-status-steps span.is-done {
  border-color: #bbf7d0;
  background: #f0fdf4;
  color: #15803d;
}

.excel-import-status-steps span.is-active {
  border-color: #bfdbfe;
  background: #eff6ff;
  color: #1d4ed8;
}

.excel-import-status svg {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.excel-import-status.is-loading {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.excel-import-status.is-error {
  border-color: #fecaca;
  background: #fef2f2;
  color: #b91c1c;
}

.excel-import-status.is-error strong,
.excel-import-status.is-error p {
  color: #991b1b;
}

.excel-import-status .loading-spinner,
.excel-import-confirm-btn .loading-spinner {
  width: 20px;
  height: 20px;
  border: 2px solid rgba(59, 130, 246, 0.24);
  border-top-color: #2563eb;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
  animation: excelImportSpin 0.8s linear infinite;
}

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

.excel-import-floating-progress {
  position: fixed;
  right: 18px;
  top: 176px;
  z-index: 13000;
  width: 186px;
  min-height: 88px;
  padding: 12px 14px;
  border: 1px solid #bfdbfe;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.18);
  color: #0f172a;
  cursor: pointer;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "title percent"
    "subtitle percent"
    "meter meter";
  align-items: center;
  justify-items: stretch;
  gap: 5px 12px;
  backdrop-filter: blur(10px);
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease;
}

.excel-import-floating-progress:hover {
  transform: translateX(-2px);
  border-color: #2563eb;
  box-shadow: 0 22px 52px rgba(37, 99, 235, 0.22);
}

.excel-import-floating-progress.is-complete {
  border-color: #86efac;
  background: rgba(240, 253, 244, 0.98);
}

.excel-import-floating-title {
  grid-area: title;
  color: #0f172a;
  font-size: 12px;
  font-weight: 900;
  line-height: 1.25;
  text-align: left;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.excel-import-floating-meter {
  grid-area: meter;
  width: 100%;
  height: 8px;
  border-radius: 999px;
  background: #e2e8f0;
  display: flex;
  align-items: stretch;
  overflow: hidden;
}

.excel-import-floating-meter span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #06b6d4 0%, #2563eb 100%);
  transition: width 0.24s ease;
}

.excel-import-floating-progress.is-complete .excel-import-floating-meter span {
  background: linear-gradient(90deg, #22c55e 0%, #16a34a 100%);
}

.excel-import-floating-percent {
  grid-area: percent;
  color: #1d4ed8;
  font-size: 20px;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  text-align: right;
}

.excel-import-floating-progress.is-complete .excel-import-floating-percent {
  color: #15803d;
}

.excel-import-floating-subtitle {
  grid-area: subtitle;
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.3;
  text-align: left;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.excel-import-floating-notice {
  position: fixed;
  right: 220px;
  top: 190px;
  z-index: 13001;
  max-width: 220px;
  padding: 10px 12px;
  border: 1px solid #86efac;
  border-radius: 12px;
  background: #f0fdf4;
  color: #166534;
  font-size: 13px;
  font-weight: 800;
  box-shadow: 0 16px 38px rgba(22, 163, 74, 0.18);
}

/* =====================
   后台任务侧栏
===================== */
.background-task-dock {
  position: fixed;
  z-index: 13040;
  width: 390px;
  max-width: calc(100vw - 28px);
  pointer-events: auto;
}

.background-task-dock.is-compact {
  width: 304px;
}

.background-task-dock.is-compact .background-task-head {
  align-items: flex-start;
  flex-direction: column;
}

.background-task-dock.is-compact .background-task-head-actions {
  width: 100%;
  justify-content: flex-start;
}

.background-task-dock.is-dragging,
.background-task-dock.is-dragging * {
  cursor: grabbing !important;
  user-select: none;
}

.background-task-panel {
  border: 1px solid rgba(139, 21, 56, 0.22);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 24px 68px rgba(15, 23, 42, 0.22);
  overflow: hidden;
  backdrop-filter: blur(12px);
}

.background-task-head {
  min-height: 72px;
  padding: 14px 16px;
  border-bottom: 1px solid #f0e4e8;
  background: linear-gradient(180deg, #fff 0%, #fff8fa 100%);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  cursor: grab;
}

.background-task-head > div:first-child {
  min-width: 0;
  flex: 1 1 auto;
}

.background-task-kicker {
  color: #8b1538;
  font-size: 12px;
  line-height: 1.2;
  font-weight: 900;
}

.background-task-head h3 {
  margin: 3px 0 0;
  color: #0f172a;
  font-size: 18px;
  line-height: 1.18;
  font-weight: 900;
  letter-spacing: 0;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.background-task-head-actions {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex: 0 0 auto;
}

.background-task-head-actions button,
.background-task-actions button {
  min-height: 34px;
  min-width: 50px;
  border: 1px solid #dbe3ee;
  border-radius: 8px;
  background: #fff;
  color: #475569;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 900;
  line-height: 1;
  white-space: nowrap;
  word-break: keep-all;
  cursor: pointer;
  transition: background 0.16s ease, color 0.16s ease, border-color 0.16s ease, transform 0.16s ease;
}

.background-task-head-actions button:last-child {
  min-width: 40px;
  padding: 0 12px;
}

.background-task-head-actions button:hover,
.background-task-actions button:hover {
  border-color: #e8b9c4;
  background: #fff1f4;
  color: #8b1538;
  transform: translateY(-1px);
}

.background-task-notice {
  margin: 10px 12px 0;
  padding: 9px 10px;
  border: 1px solid #bbf7d0;
  border-radius: 10px;
  background: #f0fdf4;
  color: #047857;
  font-size: 12px;
  font-weight: 900;
  line-height: 1.35;
}

.background-task-notice.is-error {
  border-color: #fecaca;
  background: #fef2f2;
  color: #b91c1c;
}

.background-task-list {
  max-height: min(560px, calc(100vh - 240px));
  overflow: auto;
  padding: 10px 12px 12px;
  display: grid;
  gap: 10px;
  background: #f8fafc;
}

.background-task-card {
  border: 1px solid #e6edf4;
  border-left: 4px solid #2563eb;
  border-radius: 12px;
  background: #fff;
  padding: 11px;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.07);
}

.background-task-card.is-complete {
  border-left-color: #16a34a;
}

.background-task-card.is-error {
  border-left-color: #dc2626;
}

.background-task-card-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 10px;
}

.background-task-card h4 {
  margin: 3px 0 0;
  color: #0f172a;
  font-size: 15px;
  line-height: 1.25;
  font-weight: 900;
  letter-spacing: 0;
  word-break: break-word;
}

.background-task-card-head strong {
  color: #8b1538;
  font-size: 22px;
  line-height: 1;
  font-weight: 950;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.background-task-card p,
.background-task-detail {
  margin: 8px 0 0;
  color: #475569;
  font-size: 12px;
  line-height: 1.45;
  font-weight: 700;
  word-break: break-word;
}

.background-task-detail {
  color: #64748b;
  font-weight: 600;
}

.background-task-meter {
  height: 9px;
  margin-top: 10px;
  border-radius: 999px;
  background: #e2e8f0;
  overflow: hidden;
}

.background-task-meter span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #8b1538 0%, #4f46e5 52%, #06b6d4 100%);
  transition: width 0.24s ease;
}

.background-task-card.is-complete .background-task-meter span {
  background: linear-gradient(90deg, #22c55e 0%, #16a34a 100%);
}

.background-task-card.is-error .background-task-meter span {
  background: linear-gradient(90deg, #ef4444 0%, #b91c1c 100%);
}

.background-task-meter.is-indeterminate span {
  min-width: 58%;
  background-size: 220% 100%;
  animation: aiCollectionLiveGradient 1.8s linear infinite;
}

.background-task-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.background-task-meta span {
  max-width: 100%;
  min-height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  background: #f1f5f9;
  color: #64748b;
  display: inline-flex;
  align-items: center;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.2;
  white-space: nowrap;
}

.background-task-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 10px;
}

.background-task-actions button {
  min-width: 68px;
}

.background-task-actions button:first-child {
  border-color: #8b1538;
  background: #8b1538;
  color: #fff;
}

.background-task-actions button:first-child:hover {
  border-color: #6f102c;
  background: #6f102c;
  color: #fff;
}

.background-task-empty {
  padding: 18px 12px;
  border: 1px dashed #cbd5e1;
  border-radius: 12px;
  background: #fff;
  color: #64748b;
  font-size: 13px;
  text-align: center;
}

.background-task-rail {
  min-width: 138px;
  min-height: 54px;
  border: 1px solid rgba(139, 21, 56, 0.28);
  border-radius: 999px;
  background: #8b1538;
  color: #fff;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "title count"
    "state count";
  gap: 1px 8px;
  align-items: center;
  padding: 8px 10px 8px 14px;
  cursor: pointer;
  box-shadow: 0 18px 44px rgba(139, 21, 56, 0.28);
  text-align: left;
}

.background-task-rail:hover {
  background: #76102f;
  transform: translateY(-1px);
}

.background-task-rail:active {
  cursor: grabbing;
}

.background-task-rail span {
  grid-area: title;
  font-size: 12px;
  font-weight: 900;
  line-height: 1.15;
  white-space: nowrap;
}

.background-task-rail strong {
  grid-area: count;
  width: 30px;
  height: 30px;
  border-radius: 999px;
  background: #fff;
  color: #8b1538;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 950;
  font-variant-numeric: tabular-nums;
}

.background-task-rail em {
  grid-area: state;
  color: rgba(255, 255, 255, 0.78);
  font-size: 11px;
  line-height: 1.15;
  font-style: normal;
  font-weight: 800;
}

/* =====================
   AI 推荐组稿进度
===================== */
.ai-collection-modal {
  padding: 12px;
}

.ai-collection-entry-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 38px;
  border-color: #cbd5e1 !important;
  background: #ffffff !important;
  color: #334155 !important;
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.06);
}

.ai-collection-entry-btn:hover {
  border-color: #8b1538 !important;
  background: #fff7f9 !important;
  color: #8b1538 !important;
  transform: translateY(-1px);
}

.ai-collection-entry-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 22px;
  border-radius: 7px;
  background: #8b1538;
  color: #ffffff;
  font-size: 11px;
  font-weight: 950;
  letter-spacing: 0;
  line-height: 1;
}

.ai-collection-entry-btn:hover .ai-collection-entry-mark {
  background: #6f102d;
}

.ai-history-entry-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 38px;
  border-color: #e6d9df !important;
  background: #ffffff !important;
  color: #334155 !important;
}

.ai-history-entry-btn:hover {
  border-color: #8b1538 !important;
  background: #fff7f9 !important;
  color: #8b1538 !important;
  transform: translateY(-1px);
}

.chief-collection-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.chief-collection-action-btn {
  width: 120px;
  min-height: 40px;
  padding: 0 12px;
  border-radius: 6px;
  border: 1px solid transparent;
  font-size: 14px;
  line-height: 1;
  font-weight: 800;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  white-space: nowrap;
  transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease, transform 0.16s ease;
}

.chief-collection-ai-btn {
  border: 1px solid #e8c9d2;
  background: #fff7fa;
  color: #8b1538;
  box-shadow: 0 4px 10px rgba(139, 21, 56, 0.08);
}

.chief-collection-ai-btn:hover {
  border-color: #c46b82;
  background: #fff0f4;
  color: #76102f;
  transform: translateY(-1px);
}

.chief-collection-view-btn {
  border-color: #8b1538;
  background: #8b1538;
  color: #ffffff;
  box-shadow: 0 4px 10px rgba(139, 21, 56, 0.12);
}

.chief-collection-view-btn:hover {
  border-color: #6f102d;
  background: #6f102d;
  color: #ffffff;
  transform: translateY(-1px);
}

.chief-collection-action-btn .ai-collection-entry-mark {
  width: 24px;
  height: 20px;
  border-radius: 6px;
}

.chief-editor-issue-grid {
  display: grid;
  grid-template-columns: repeat(3, 368px);
  gap: 16px;
  justify-content: start;
}

@media (max-width: 1210px) {
  .chief-editor-issue-grid {
    grid-template-columns: repeat(2, 368px);
  }
}

@media (max-width: 820px) {
  .chief-editor-issue-grid {
    grid-template-columns: minmax(0, 368px);
  }
}

@media (max-width: 560px) {
  .chief-editor-issue-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

.chief-editor-issue-grid .issue-card {
  width: 368px !important;
  max-width: 368px !important;
  height: auto !important;
  min-height: 0;
  padding: 20px;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
}

.chief-editor-issue-grid .issue-card-head {
  gap: 12px;
  margin-bottom: 12px;
  flex: 0 0 auto;
}

.chief-editor-issue-grid .issue-card-icon {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  font-size: 24px;
}

.chief-editor-issue-grid .issue-card-title-block h4 {
  font-size: 18px;
  font-weight: 600;
}

.chief-editor-issue-grid .issue-card-title-block p {
  margin-top: 4px;
  font-size: 13px;
}

.chief-editor-issue-grid .issue-card-meta-panel {
  padding: 12px;
  margin-bottom: 12px;
  flex: 0 0 auto;
}

.chief-editor-issue-grid .issue-card-meta-row {
  min-height: auto;
}

.chief-editor-issue-grid .issue-card-meta-row + .issue-card-meta-row {
  margin-top: 6px;
}

.chief-editor-issue-grid .issue-card-meta-label {
  font-size: 13px;
}

.chief-editor-issue-grid .issue-card-meta-value {
  font-size: 16px;
  font-weight: 600;
}

.chief-editor-issue-grid .issue-card-status {
  font-size: 14px;
  font-weight: 600;
}

.chief-editor-issue-grid .issue-card-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: nowrap;
  gap: 10px;
  margin-top: auto;
}

.chief-editor-issue-grid .issue-card-action {
  width: 146px;
  flex: 0 0 146px;
  min-height: 40px;
  border-radius: 8px;
  padding: 0 10px;
  font-size: 14px;
  font-weight: 600;
  box-shadow: none;
}

.chief-editor-issue-grid .issue-card-action-finalize {
  grid-column: auto;
  min-height: 40px;
  box-shadow: none;
}

@media (max-width: 680px) {
  .chief-editor-issue-grid .issue-card-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .chief-editor-issue-grid .issue-card-action {
    width: 100%;
    flex-basis: auto;
  }

  .chief-editor-issue-grid .issue-card {
    width: 100% !important;
    max-width: none !important;
    height: auto;
    padding: 20px;
  }
}

.issue-card {
  position: relative;
  padding: 20px;
  border-radius: 12px;
  border: 2px solid #e5e7eb;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  cursor: pointer;
  overflow: hidden;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.issue-card::before {
  content: none;
}

.issue-card:hover {
  transform: translateY(-4px);
  border-color: #dbe4ff;
  box-shadow: 0 8px 12px rgba(0, 0, 0, 0.15);
}

.issue-card-head,
.issue-card-meta-panel,
.issue-card-actions {
  position: relative;
  z-index: 1;
}

.issue-card-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
}

.issue-card-icon {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  background: rgba(255, 255, 255, 0.2);
  font-size: 24px;
}

.issue-card-title-block {
  flex: 1;
  min-width: 0;
}

.issue-card-title-block h4 {
  margin: 0;
  color: #ffffff;
  font-size: 19px;
  line-height: 1.25;
  font-weight: 800;
  letter-spacing: 0;
  text-shadow: 0 1px 2px rgba(15, 23, 42, 0.16);
}

.issue-card-title-block p {
  margin: 5px 0 0;
  color: rgba(255, 255, 255, 0.8);
  font-size: 13px;
  line-height: 1.35;
}

.issue-card-meta-panel {
  padding: 12px 14px;
  margin-bottom: 14px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.15);
  border: 0;
  box-shadow: none;
  backdrop-filter: blur(10px);
}

.issue-card-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 27px;
}

.issue-card-meta-row + .issue-card-meta-row {
  margin-top: 6px;
}

.issue-card-meta-label {
  color: rgba(255, 255, 255, 0.82);
  font-size: 13px;
  font-weight: 700;
}

.issue-card-meta-value,
.issue-card-status {
  color: #ffffff;
  font-size: 18px;
  font-weight: 850;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.issue-card-status {
  font-size: 15px;
}

.issue-card-status.is-in_progress {
  color: #fbbf24;
}

.issue-card-status.is-completed {
  color: #bbf7d0;
}

.issue-card-status.is-finalized {
  color: #fecaca;
}

.issue-card-status.is-new {
  color: rgba(255, 255, 255, 0.78);
}

.issue-card-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 12px;
  margin-top: 2px;
}

.issue-card-action {
  min-height: 46px;
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.56);
  border-radius: 12px;
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.13);
  transition: transform 0.16s ease, background 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease, color 0.16s ease;
}

.issue-card-action:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 26px rgba(15, 23, 42, 0.18);
}

.issue-card-action-primary,
.issue-card-action-view {
  background: linear-gradient(180deg, #ffffff 0%, #f7f8ff 100%);
  color: #4750c8;
}

.issue-card-action-ai {
  background: linear-gradient(180deg, #ffffff 0%, #fbf8ff 100%);
  color: #6d3fd4;
}

.issue-card-action-finalize {
  grid-column: 1 / -1;
  background: linear-gradient(135deg, #ffffff 0%, #f4edff 100%);
  color: #5b21b6;
  border-color: rgba(255, 255, 255, 0.66);
  box-shadow: 0 12px 24px rgba(67, 56, 202, 0.22);
}

.issue-card-action .ai-collection-entry-mark {
  min-width: 28px;
  height: 20px;
  border-radius: 7px;
  background: linear-gradient(135deg, #7c3aed 0%, #5b21b6 100%);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  letter-spacing: 0;
}

.finalization-modal {
  z-index: 10020;
  align-items: center;
  justify-content: center;
  background: rgba(15, 23, 42, 0.52);
  backdrop-filter: blur(3px);
}

.finalization-modal-shell {
  width: min(1760px, 97vw);
  height: min(980px, 97vh);
  max-height: 97vh;
  padding: 0;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 30px 90px rgba(15, 23, 42, 0.26);
}

.finalization-modal-loading {
  width: min(420px, 92vw);
  padding: 28px;
  border-radius: 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  color: #334155;
}

.finalization-modal-header {
  padding: 11px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid #e2e8f0;
  background: linear-gradient(135deg, #fff7f9 0%, #ffffff 48%, #f8fafc 100%);
  flex-shrink: 0;
}

.finalization-kicker {
  color: #8b1538;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0;
  margin-bottom: 5px;
}

.finalization-modal-header h3 {
  margin: 0;
  color: #111827;
  font-size: 19px;
  line-height: 1.25;
}

.finalization-header-actions {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.finalization-close-btn {
  width: 38px;
  height: 38px;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
  background: #ffffff;
  color: #475569;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease;
}

.finalization-close-btn:hover {
  background: #fff1f2;
  border-color: #fecdd3;
  color: #be123c;
}

.finalization-modal-body {
  flex: 1;
  overflow: hidden;
  padding: 10px 18px 12px;
  background: #f8fafc;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.finalization-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 6px;
  flex-shrink: 0;
}

.finalization-summary-card {
  min-height: 42px;
  border-radius: 9px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  padding: 7px 12px;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.06);
}

.finalization-summary-card span {
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
}

.finalization-summary-card strong {
  color: #0f172a;
  font-size: 18px;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.finalization-summary-card.is-success {
  border-color: #86efac;
  background: #f0fdf4;
}

.finalization-summary-card.is-warning {
  border-color: #facc15;
  background: #fffbeb;
}

.finalization-summary-card.is-danger {
  border-color: #fca5a5;
  background: #fff1f2;
}

.finalization-page-notice {
  border-radius: 9px;
  padding: 6px 10px;
  font-size: 12.5px;
  font-weight: 700;
  margin-bottom: 8px;
  border: 1px solid #e2e8f0;
  background: #ffffff;
  color: #475569;
  flex-shrink: 0;
}

.finalization-page-notice.is-success {
  background: #ecfdf5;
  border-color: #bbf7d0;
  color: #047857;
}

.finalization-page-notice.is-warning {
  background: #fffbeb;
  border-color: #fde68a;
  color: #92400e;
}

.finalization-page-notice.is-danger {
  background: #fff1f2;
  border-color: #fecdd3;
  color: #be123c;
}

.finalization-insert-panel {
  background: #ffffff;
  border: 1px solid #facc15;
  border-radius: 10px;
  padding: 10px 12px;
  margin-bottom: 8px;
  box-shadow: 0 10px 24px rgba(202, 138, 4, 0.08);
  flex-shrink: 0;
}

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

.finalization-insert-head strong {
  display: block;
  color: #92400e;
  font-size: 15px;
  margin-bottom: 4px;
}

.finalization-insert-head span {
  color: #64748b;
  font-size: 13px;
}

.finalization-insert-rule {
  flex-shrink: 0;
  padding: 5px 10px;
  border-radius: 999px;
  background: #fef3c7;
  color: #92400e !important;
  font-weight: 800;
}

.finalization-insert-options {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
}

.finalization-insert-option {
  min-height: 30px;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  background: #f8fafc;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  cursor: pointer;
  color: #334155;
  font-size: 13px;
  font-weight: 700;
}

.finalization-insert-option input {
  width: 15px;
  height: 15px;
  accent-color: #8b1538;
}

.finalization-custom-insert {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto;
  gap: 10px;
}

.finalization-table-wrap {
  overflow: auto;
  border: 1px solid #dbe3ef;
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 16px 34px rgba(15, 23, 42, 0.08);
  flex: 1;
  min-height: 0;
}

.finalization-table {
  width: 100%;
  min-width: 1280px;
  border-collapse: separate;
  border-spacing: 0;
  table-layout: fixed;
  font-size: 12px;
}

.finalization-col-code {
  width: 8%;
}

.finalization-col-author {
  width: 5.5%;
}

.finalization-col-title {
  width: 39.5%;
}

.finalization-col-pages {
  width: 4.5%;
}

.finalization-col-transfer {
  width: 7%;
}

.finalization-col-revision,
.finalization-col-delete {
  width: 6.5%;
}

.finalization-col-link {
  width: 22.5%;
}

.finalization-table th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #8b1538;
  color: #ffffff;
  padding: 4px 7px;
  text-align: center;
  font-weight: 800;
  white-space: nowrap;
  border-right: 1px solid rgba(255, 255, 255, 0.18);
}

.finalization-table td {
  height: 22px;
  padding: 3px 7px;
  border-right: 1px solid #e5edf5;
  border-bottom: 1px solid #e5edf5;
  color: #1f2937;
  vertical-align: middle;
  line-height: 1.2;
  background: #ffffff;
}

.finalization-table tbody tr:nth-child(even) td {
  background: #fbfdff;
}

.finalization-table td:nth-child(1) {
  width: 8%;
  font-weight: 700;
  white-space: nowrap;
}

.finalization-table td:nth-child(2) {
  width: 5.5%;
  white-space: nowrap;
}

.finalization-table td:nth-child(3) {
  width: 39.5%;
}

.finalization-table td:nth-child(4) {
  width: 4.5%;
  text-align: center;
  font-weight: 800;
}

.finalization-table td:nth-child(5) {
  width: 7%;
}

.finalization-table td:nth-child(6),
.finalization-table td:nth-child(7) {
  width: 6.5%;
}

.finalization-table td:nth-child(8) {
  width: 22.5%;
}

.finalization-title-cell {
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
  word-break: break-word;
  overflow-wrap: anywhere;
  line-height: 1.35;
  color: #111827;
}

.finalization-column-row td {
  background: #fff7e8 !important;
  color: #111827;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.05;
  height: 21px;
  padding: 1px 6px;
}

.finalization-column-row td:first-child {
  font-size: 12.5px;
  white-space: normal;
  word-break: break-word;
}

.finalization-page-input {
  width: 54px;
  height: 20px;
  min-height: 20px;
  border-radius: 6px;
  border: 1px solid #dbe3ef;
  background: #ffffff;
  color: #111827;
  padding: 1px 5px;
  font-size: 11.5px;
  line-height: 1;
  font-weight: 800;
  text-align: center;
  font-variant-numeric: tabular-nums;
  box-sizing: border-box;
}

.finalization-page-input:focus {
  outline: none;
  border-color: #8b1538;
  box-shadow: 0 0 0 2px rgba(139, 21, 56, 0.12);
}

.finalization-note-input {
  width: 100%;
  height: 20px;
  min-height: 20px;
  border-radius: 6px;
  border: 1px solid #dbe3ef;
  background: #ffffff;
  color: #111827;
  padding: 1px 5px;
  font-size: 11.5px;
  line-height: 1.05;
  box-sizing: border-box;
}

.finalization-note-input:focus {
  outline: none;
  border-color: #8b1538;
  box-shadow: 0 0 0 3px rgba(139, 21, 56, 0.12);
}

.finalization-cross-tip {
  margin-top: 5px;
  color: #b45309;
  font-size: 12px;
  font-weight: 800;
}

.finalization-link {
  color: #1d4ed8;
  text-decoration: underline;
  text-underline-offset: 2px;
  word-break: break-all;
}

.finalization-muted {
  color: #94a3b8;
  font-weight: 700;
}

.finalization-modal-footer {
  padding: 9px 18px;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  border-top: 1px solid #e2e8f0;
  background: #ffffff;
  flex-shrink: 0;
}

.finalization-start-btn {
  min-width: 128px;
  background: #8b1538 !important;
  border-color: #8b1538 !important;
}

@media (max-width: 900px) {
  .finalization-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .finalization-modal-header,
  .finalization-insert-head,
  .finalization-modal-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .finalization-header-actions,
  .finalization-custom-insert {
    width: 100%;
    grid-template-columns: 1fr;
  }
}

.ai-collection-modal.is-minimized {
  display: none;
}

.ai-collection-loading-shell {
  width: min(760px, 96vw);
  max-height: calc(100vh - 24px);
  padding: 0;
  overflow: hidden;
  border-radius: 18px;
  box-shadow: 0 28px 80px rgba(15, 23, 42, 0.24);
}

.ai-collection-loading-header {
  margin: 0;
  padding: 18px 22px;
  align-items: center;
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
}

.ai-collection-loading-header h3 {
  margin: 2px 0 0;
  color: #0f172a;
  font-size: 20px;
  line-height: 1.2;
}

.ai-collection-kicker {
  color: #8b1538;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
}

.ai-collection-loading-body {
  padding: 18px 20px 20px;
  background: linear-gradient(180deg, #fcfcfd 0%, #f8fafc 100%);
}

.ai-collection-progress-card {
  gap: 18px;
  padding: 18px;
  border-color: #dbeafe;
  background:
    radial-gradient(circle at 88% 8%, rgba(139, 21, 56, 0.08), transparent 28%),
    linear-gradient(180deg, #ffffff 0%, #eff6ff 100%);
  box-shadow: 0 14px 36px rgba(15, 23, 42, 0.08);
}

.ai-collection-orbit {
  position: relative;
  flex: 0 0 116px;
  width: 116px;
  height: 116px;
}

.ai-collection-orbit-core,
.ai-collection-orbit-ring,
.ai-collection-orbit-dot {
  position: absolute;
  inset: 0;
  margin: auto;
}

.ai-collection-orbit-core {
  width: 62px;
  height: 62px;
  border-radius: 18px;
  background: linear-gradient(135deg, #8b1538 0%, #4f46e5 100%);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  font-weight: 900;
  box-shadow: 0 16px 34px rgba(79, 70, 229, 0.26);
  animation: aiCollectionCorePulse 1.8s ease-in-out infinite;
}

.ai-collection-orbit-ring {
  border-radius: 999px;
  border: 1px solid rgba(37, 99, 235, 0.18);
}

.ai-collection-orbit-ring.ring-one {
  width: 92px;
  height: 92px;
  animation: aiCollectionOrbit 4.2s linear infinite;
}

.ai-collection-orbit-ring.ring-two {
  width: 116px;
  height: 116px;
  border-style: dashed;
  border-color: rgba(139, 21, 56, 0.18);
  animation: aiCollectionOrbit 6.4s linear infinite reverse;
}

.ai-collection-orbit-dot {
  width: 12px;
  height: 12px;
  border-radius: 999px;
  background: #06b6d4;
  box-shadow: 0 0 0 7px rgba(6, 182, 212, 0.12);
}

.ai-collection-orbit-dot.dot-one {
  transform: translate(50px, 14px);
  animation: aiCollectionDotOne 2.8s ease-in-out infinite;
}

.ai-collection-orbit-dot.dot-two {
  width: 10px;
  height: 10px;
  background: #8b1538;
  box-shadow: 0 0 0 7px rgba(139, 21, 56, 0.12);
  transform: translate(12px, 76px);
  animation: aiCollectionDotTwo 3.2s ease-in-out infinite;
}

.ai-collection-progress-meter {
  position: relative;
  height: 10px;
  margin-top: 12px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(37, 99, 235, 0.12);
}

.ai-collection-progress-meter span {
  position: relative;
  display: block;
  height: 100%;
  border-radius: inherit;
  overflow: hidden;
  background: linear-gradient(90deg, #8b1538 0%, #4f46e5 54%, #06b6d4 100%);
  transition: width 0.28s ease;
}

.ai-collection-progress-meter.is-indeterminate span {
  min-width: 68%;
  background-size: 220% 100%;
  animation: aiCollectionLiveGradient 1.8s linear infinite;
}

.ai-collection-progress-meter span::after {
  content: "";
  position: absolute;
  inset: 0;
  width: 42%;
  background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.55) 45%, transparent 100%);
  transform: translateX(-120%);
  animation: aiCollectionProgressShine 1.6s ease-in-out infinite;
}

.ai-collection-metric-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 12px;
}

.ai-collection-metric-grid div {
  min-width: 0;
  padding: 9px 10px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.82);
}

.ai-collection-metric-grid span {
  display: block;
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.25;
  white-space: nowrap;
}

.ai-collection-metric-grid strong {
  display: block;
  margin-top: 4px;
  color: #0f172a;
  font-size: 12px;
  font-weight: 900;
  line-height: 1.25;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ai-collection-detail-tags span {
  border-color: #e0e7ff;
  background: #ffffff;
  color: #4338ca;
}

.ai-collection-steps span.is-done {
  border-color: #fecdd3;
  background: #fff1f2;
  color: #9f1239;
}

.ai-collection-steps span.is-active {
  border-color: #c7d2fe;
  background: #eef2ff;
  color: #3730a3;
}

.ai-collection-waiting-note {
  margin-top: 10px;
  padding: 9px 10px;
  border: 1px solid #fde68a;
  border-radius: 12px;
  background: #fffbeb;
  color: #92400e;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.45;
}

.ai-collection-floating-progress {
  top: 282px;
  width: 220px;
  border-color: #c7d2fe;
}

.ai-collection-floating-progress:hover {
  border-color: #8b1538;
  box-shadow: 0 22px 52px rgba(139, 21, 56, 0.18);
}

.ai-collection-floating-progress .excel-import-floating-meter span {
  background: linear-gradient(90deg, #8b1538 0%, #4f46e5 58%, #06b6d4 100%);
}

.ai-collection-floating-progress .excel-import-floating-percent {
  color: #8b1538;
}

.ai-collection-floating-progress.is-live .excel-import-floating-percent {
  font-size: 20px;
  line-height: 1.05;
  white-space: nowrap;
}

.ai-collection-floating-progress.is-indeterminate .excel-import-floating-meter span {
  min-width: 68%;
  background-size: 220% 100%;
  animation: aiCollectionLiveGradient 1.8s linear infinite;
}

.ai-collection-floating-progress.is-complete {
  border-color: #86efac;
  background: rgba(240, 253, 244, 0.98);
}

.ai-collection-floating-progress.is-error {
  border-color: #fecaca;
  background: rgba(254, 242, 242, 0.98);
}

.ai-collection-floating-progress.is-error .excel-import-floating-meter span {
  background: linear-gradient(90deg, #ef4444 0%, #b91c1c 100%);
}

.ai-collection-floating-progress.is-error .excel-import-floating-percent {
  color: #b91c1c;
}

.ai-collection-floating-notice {
  top: 296px;
}

.ai-collection-floating-notice.is-error {
  border-color: #fecaca;
  background: #fef2f2;
  color: #991b1b;
  box-shadow: 0 16px 38px rgba(185, 28, 28, 0.16);
}

/* =====================
   AI 推荐组稿结果
===================== */
.ai-collection-result-shell {
  width: min(1880px, 98vw);
  height: min(calc(100vh - 20px), 1040px);
  max-height: calc(100vh - 20px);
  padding: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: 16px;
  box-shadow: 0 30px 90px rgba(15, 23, 42, 0.26);
}

.ai-result-header {
  flex: 0 0 auto;
  margin: 0;
  padding: 9px 22px;
  align-items: center;
  border-bottom: 1px solid #e5e7eb;
  background: linear-gradient(180deg, #ffffff 0%, #fbfcfe 100%);
}

.ai-result-header h3 {
  margin: 1px 0 0;
  color: #0f172a;
  font-size: 18px;
  line-height: 1.2;
}

.ai-result-header .ai-collection-kicker {
  font-size: 11px;
  line-height: 1.2;
}

.ai-result-close-btn {
  border-radius: 999px;
  background: #ffffff;
  color: #475569;
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.08);
}

.ai-result-close-btn:hover {
  background: #fff1f2;
  border-color: #fecdd3;
  color: #9f1239;
}

.ai-result-close-icon {
  position: relative;
  width: 16px;
  height: 16px;
  display: inline-block;
}

.ai-result-close-icon::before,
.ai-result-close-icon::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 16px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  transform-origin: center;
}

.ai-result-close-icon::before {
  transform: translate(-50%, -50%) rotate(45deg);
}

.ai-result-close-icon::after {
  transform: translate(-50%, -50%) rotate(-45deg);
}

.ai-history-shell {
  width: min(1280px, 96vw);
  height: min(820px, calc(100vh - 28px));
  padding: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: 16px;
  box-shadow: 0 30px 90px rgba(15, 23, 42, 0.26);
}

.ai-history-header {
  flex: 0 0 auto;
  margin: 0;
  padding: 12px 18px;
  border-bottom: 1px solid #e5e7eb;
  background: #ffffff;
}

.ai-history-header h3 {
  margin: 2px 0 0;
  color: #0f172a;
  font-size: 18px;
  line-height: 1.2;
}

.ai-history-body {
  flex: 1;
  min-height: 0;
  padding: 12px;
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 12px;
  background: #f8fafc;
}

.ai-history-list,
.ai-history-detail {
  min-height: 0;
  overflow: auto;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #ffffff;
}

.ai-history-list {
  padding: 8px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ai-history-list-item {
  width: 100%;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: #fff;
  padding: 10px;
  cursor: pointer;
  display: grid;
  gap: 8px;
  text-align: left;
  transition: border-color 0.16s ease, background 0.16s ease, box-shadow 0.16s ease;
}

.ai-history-list-item:hover,
.ai-history-list-item.is-active {
  border-color: #c46b82;
  background: #fff7f9;
  box-shadow: 0 8px 18px rgba(139, 21, 56, 0.08);
}

.ai-history-list-main strong,
.ai-history-list-main em {
  display: block;
}

.ai-history-list-main strong {
  color: #0f172a;
  font-size: 14px;
  line-height: 1.25;
}

.ai-history-list-main em {
  margin-top: 4px;
  color: #64748b;
  font-size: 12px;
  font-style: normal;
}

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

.ai-history-list-meta i,
.ai-history-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 24px;
  padding: 0 9px;
  border-radius: 999px;
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
}

.ai-history-list-meta i.is-complete,
.ai-history-status.is-complete {
  background: #dcfce7;
  color: #15803d;
}

.ai-history-list-meta i.is-failed,
.ai-history-status.is-failed {
  background: #fee2e2;
  color: #b91c1c;
}

.ai-history-list-meta b {
  color: #8b1538;
  font-size: 13px;
}

.ai-history-detail {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ai-history-detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.ai-history-detail-head h3 {
  margin: 2px 0 0;
  color: #0f172a;
  font-size: 18px;
  line-height: 1.35;
}

.ai-history-stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.ai-history-stat-grid div {
  min-width: 0;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #f8fafc;
  padding: 9px 10px;
}

.ai-history-stat-grid span,
.ai-history-stat-grid strong {
  display: block;
}

.ai-history-stat-grid span {
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}

.ai-history-stat-grid strong {
  margin-top: 4px;
  color: #0f172a;
  font-size: 14px;
  line-height: 1.25;
  word-break: break-word;
}

.ai-history-table-wrap {
  flex: 1;
  min-height: 0;
  overflow: auto;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
}

.ai-history-table {
  min-width: 980px;
}

.ai-history-empty,
.ai-history-error {
  border: 1px dashed #cbd5e1;
  border-radius: 12px;
  background: #ffffff;
  padding: 26px;
  color: #64748b;
  font-size: 14px;
  font-weight: 800;
  text-align: center;
}

.ai-history-error {
  border-color: #fecaca;
  background: #fef2f2;
  color: #b91c1c;
  text-align: left;
}

.ai-history-empty-cell {
  padding: 28px !important;
  color: #64748b;
  text-align: center;
  font-weight: 800;
}

.ai-result-body {
  flex: 1;
  min-height: 0;
  padding: 8px 22px 10px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: #f8fafc;
}

.ai-result-topbar {
  display: grid;
  grid-template-columns: minmax(360px, 1fr) minmax(620px, 1.35fr) auto;
  gap: 10px;
  align-items: stretch;
}

.ai-result-summary-card {
  min-width: 0;
  padding: 9px 12px;
  border: 1px solid #e2e8f0;
  border-left: 4px solid #8b1538;
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.04);
}

.ai-result-summary-title {
  color: #0f172a;
  font-size: 13px;
  font-weight: 900;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  overflow: hidden;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.ai-result-summary-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 5px;
}

.ai-result-summary-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  padding: 0 7px;
  border-radius: 999px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
}

.ai-result-score-strip {
  min-width: 0;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 7px;
}

.ai-result-score-card {
  min-width: 0;
  padding: 7px 9px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.035);
}

.ai-result-score-card span {
  display: block;
  color: #64748b;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ai-result-score-card strong {
  display: flex;
  align-items: baseline;
  gap: 5px;
  margin-top: 5px;
  color: #0f172a;
  font-size: 17px;
  font-weight: 950;
  line-height: 1.05;
  white-space: nowrap;
}

.ai-result-score-card em {
  color: #94a3b8;
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
}

.ai-result-score-card.is-ok {
  border-color: #bbf7d0;
  background: linear-gradient(180deg, #ffffff 0%, #f0fdf4 100%);
}

.ai-result-score-card.is-ok strong,
.ai-result-score-card.is-ok em {
  color: #166534;
}

.ai-result-score-card.is-watch {
  border-color: #fed7aa;
  background: linear-gradient(180deg, #ffffff 0%, #fff7ed 100%);
}

.ai-result-score-card.is-watch strong,
.ai-result-score-card.is-watch em {
  color: #c2410c;
}

.ai-result-rerun-btn {
  min-height: 38px;
  padding: 0 14px;
  white-space: nowrap;
  align-self: flex-start;
}

.ai-result-warning-panel {
  padding: 12px 14px;
  border: 1px solid #fed7aa;
  border-radius: 14px;
  background: #fff7ed;
  color: #9a3412;
}

.ai-result-warning-title {
  margin-bottom: 8px;
  color: #9a3412;
  font-size: 13px;
  font-weight: 900;
}

.ai-result-warning-list {
  display: grid;
  gap: 6px;
}

.ai-result-warning-list p {
  position: relative;
  margin: 0;
  padding-left: 14px;
  font-size: 13px;
  line-height: 1.55;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.ai-result-warning-list p::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.72em;
  width: 5px;
  height: 5px;
  border-radius: 999px;
  background: #ea580c;
}

.ai-result-column-plan {
  display: flex;
  flex-wrap: nowrap;
  gap: 6px;
  min-height: 30px;
  max-height: 32px;
  overflow-x: auto;
  overflow-y: hidden;
  padding-bottom: 2px;
  scrollbar-width: thin;
}

.ai-result-column-plan span {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  min-height: 26px;
  max-width: 100%;
  padding: 0 10px;
  border: 1px solid #c7d2fe;
  border-radius: 999px;
  background: #eef2ff;
  color: #3730a3;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.35;
  white-space: nowrap;
}

.ai-result-table-wrap {
  flex: 1;
  min-height: 0;
  overflow: auto;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #ffffff;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.055);
}

.ai-result-table {
  width: 100%;
  min-width: 1280px;
  border-collapse: separate;
  border-spacing: 0;
  table-layout: fixed;
  color: #334155;
  font-size: 13px;
}

.ai-result-table thead th {
  position: sticky;
  top: 0;
  z-index: 3;
  padding: 8px 10px;
  border-bottom: 1px solid #dbe3ee;
  background: #f1f5f9;
  color: #334155;
  font-size: 12px;
  font-weight: 900;
  line-height: 1.35;
  text-align: left;
  white-space: normal;
}

.ai-result-table td {
  padding: 8px 10px;
  border-bottom: 1px solid #eef2f7;
  vertical-align: top;
  line-height: 1.48;
  white-space: normal !important;
  word-break: break-word;
  overflow-wrap: anywhere;
}

.ai-result-table tbody tr:nth-child(even) {
  background: #fcfcfd;
}

.ai-result-table tbody tr:hover {
  background: #fff8fb;
}

.ai-result-check-cell,
.ai-result-index-cell,
.ai-result-priority-cell {
  text-align: center !important;
}

.ai-result-check-cell input,
.ai-rec-checkbox {
  width: 18px;
  height: 18px;
  cursor: pointer;
}

.ai-result-index-cell {
  color: #64748b;
  font-weight: 800;
}

.ai-result-priority {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  min-height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
}

.ai-result-priority.is-high {
  background: #fee2e2;
  color: #b91c1c;
}

.ai-result-priority.is-medium {
  background: #fef3c7;
  color: #92400e;
}

.ai-result-priority.is-low {
  background: #e0f2fe;
  color: #075985;
}

.ai-result-column-input {
  width: 100%;
  min-height: 40px;
  padding: 6px 8px;
  border: 1px solid #dbe3ee;
  border-radius: 10px;
  background: #ffffff;
  color: #1e293b;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.45;
  resize: vertical;
  overflow: auto;
  white-space: normal;
}

.ai-result-column-input:focus {
  outline: none;
  border-color: #8b1538;
  box-shadow: 0 0 0 3px rgba(139, 21, 56, 0.1);
}

.ai-result-title-text {
  color: #0f172a;
  font-size: 13px;
  font-weight: 900;
  line-height: 1.45;
  white-space: normal;
  word-break: break-word;
  overflow-wrap: anywhere;
}

.ai-result-meta-line {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 5px;
}

.ai-result-meta-line span {
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  padding: 0 7px;
  border-radius: 999px;
  background: #f1f5f9;
  color: #64748b;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.3;
}

.ai-result-meta-line span.ai-result-positive-tag {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  color: #166534;
}

.ai-result-meta-line span.ai-result-overdue-tag {
  background: #fff7ed;
  border: 1px solid #fed7aa;
  color: #c2410c;
}

.ai-result-text-cell {
  color: #475569;
  font-size: 12px;
}

.ai-result-discipline-cell strong,
.ai-result-discipline-cell span,
.ai-result-discipline-cell em {
  display: block;
  white-space: normal;
  word-break: break-word;
  overflow-wrap: anywhere;
}

.ai-result-discipline-cell strong {
  color: #334155;
  font-weight: 900;
}

.ai-result-discipline-cell span {
  margin-top: 3px;
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
}

.ai-result-discipline-cell em {
  margin-top: 3px;
  color: #94a3b8;
  font-size: 11px;
  font-style: normal;
}

.ai-result-empty-cell {
  padding: 34px !important;
  text-align: center;
  color: #64748b;
  font-weight: 800;
}

.ai-result-footer {
  flex: 0 0 auto;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin: 0;
  padding: 9px 22px;
  border-top: 1px solid #e5e7eb;
  background: #ffffff;
}

.ai-review-warning-shell {
  width: min(760px, 94vw);
  max-height: min(82vh, 680px);
  padding: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border-radius: 18px;
  box-shadow: 0 28px 80px rgba(15, 23, 42, 0.24);
}

.ai-review-warning-head {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 22px;
  border-bottom: 1px solid #e5e7eb;
  background: #ffffff;
}

.ai-review-warning-head h3 {
  margin: 2px 0 0;
  color: #0f172a;
  font-size: 20px;
  line-height: 1.25;
}

.ai-review-warning-body {
  flex: 1;
  min-height: 0;
  overflow: auto;
  display: grid;
  gap: 10px;
  padding: 16px 22px;
  background: linear-gradient(180deg, #fff7ed 0%, #ffffff 100%);
}

.ai-review-warning-item {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 12px 14px;
  border: 1px solid #fed7aa;
  border-radius: 12px;
  background: #ffffff;
}

.ai-review-warning-item span {
  width: 26px;
  height: 26px;
  border-radius: 999px;
  background: #ffedd5;
  color: #c2410c;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 900;
}

.ai-review-warning-item p {
  margin: 0;
  color: #9a3412;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.58;
  overflow-wrap: anywhere;
}

.ai-review-warning-footer {
  flex: 0 0 auto;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 14px 22px;
  border-top: 1px solid #e5e7eb;
  background: #ffffff;
}

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

@keyframes aiCollectionCorePulse {
  0%, 100% { transform: scale(1); box-shadow: 0 16px 34px rgba(79, 70, 229, 0.26); }
  50% { transform: scale(1.04); box-shadow: 0 20px 40px rgba(139, 21, 56, 0.2); }
}

@keyframes aiCollectionDotOne {
  0%, 100% { transform: translate(50px, 14px) scale(1); }
  50% { transform: translate(58px, 24px) scale(1.16); }
}

@keyframes aiCollectionDotTwo {
  0%, 100% { transform: translate(12px, 76px) scale(1); }
  50% { transform: translate(22px, 82px) scale(1.12); }
}

@keyframes aiCollectionProgressShine {
  to { transform: translateX(260%); }
}

@keyframes aiCollectionLiveGradient {
  0% { background-position: 0% 50%; }
  100% { background-position: 220% 50%; }
}

.excel-import-preview {
  display: flex;
  flex-direction: column;
  gap: 12px;
  height: 100%;
  min-height: 0;
}

.excel-import-preview-scroll {
  flex: 1;
  min-height: 0;
  overflow: auto;
  display: grid;
  gap: 12px;
  padding-right: 4px;
}

.excel-import-preview-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 16px;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.05);
}

.excel-import-preview-kicker {
  margin-bottom: 4px;
  color: #2563eb;
  font-size: 12px;
  font-weight: 800;
}

.excel-import-preview-head h2 {
  margin: 0;
  color: #0f172a;
  font-size: 18px;
  line-height: 1.25;
}

.excel-import-preview-head p {
  margin: 6px 0 0;
  color: #64748b;
  font-size: 12px;
  line-height: 1.5;
}

.excel-import-preview-badges {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  flex-shrink: 0;
}

.excel-import-preview-badges span {
  display: inline-flex;
  align-items: center;
  height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: #eef2ff;
  color: #4338ca;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.excel-import-preview-badges span.is-success {
  background: #ecfdf5;
  color: #047857;
}

.excel-import-preview-badges span.is-warning {
  background: #fff7ed;
  color: #c2410c;
}

.excel-import-preview-warning {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid #fde68a;
  background: #fffbeb;
  color: #92400e;
  font-size: 12px;
  line-height: 1.45;
}

.excel-import-preview-warning svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.excel-import-preview-stage {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 12px;
  align-items: start;
}

.excel-import-preview-record,
.excel-import-preview-side-card,
.excel-import-preview-section.is-side {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.06);
}

.excel-import-preview-record {
  padding: 14px 16px;
}

.excel-import-preview-record-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid #edf2f7;
}

.excel-import-preview-record-meta {
  min-width: 0;
}

.excel-import-preview-record-step {
  color: #2563eb;
  font-size: 12px;
  font-weight: 800;
}

.excel-import-preview-record-meta h3 {
  margin: 4px 0 0;
  color: #0f172a;
  font-size: 20px;
  line-height: 1.2;
  word-break: break-word;
}

.excel-import-preview-record-titleline {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.excel-import-preview-record-titleline h3 {
  margin-top: 4px;
}

.excel-import-detail-btn {
  min-height: 28px;
  padding: 0 12px;
  border: 1px solid #fdba74;
  border-radius: 999px;
  background: #fff7ed;
  color: #c2410c;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.16s ease;
  box-shadow: 0 6px 14px rgba(234, 88, 12, 0.14);
}

.excel-import-detail-btn:hover {
  border-color: #f97316;
  background: #ffedd5;
  color: #9a3412;
  transform: translateY(-1px);
  box-shadow: 0 10px 20px rgba(234, 88, 12, 0.20);
}

.excel-import-duplicate-badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 9px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.excel-import-duplicate-badge.is-clear {
  border-color: #a7f3d0;
  background: #ecfdf5;
  color: #047857;
}

.excel-import-duplicate-badge.is-duplicate {
  border-color: #fecaca;
  background: #fef2f2;
  color: #b91c1c;
}

.excel-import-duplicate-badge.is-file-duplicate {
  border-color: #fed7aa;
  background: #fff7ed;
  color: #c2410c;
}

.excel-import-duplicate-badge.is-unknown {
  border-color: #dbeafe;
  background: #eff6ff;
  color: #1d4ed8;
}

.excel-import-duplicate-detail {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  max-width: 100%;
  margin-top: 7px;
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid #fed7aa;
  background: #fff7ed;
  color: #9a3412;
  font-size: 12px;
  line-height: 1.45;
}

.excel-import-duplicate-detail svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.excel-import-ai-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.excel-import-ai-summary span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 26px;
  padding: 0 9px;
  border-radius: 999px;
  border: 1px solid #dbeafe;
  background: #eff6ff;
  color: #1e40af;
  font-size: 11px;
  font-weight: 700;
  max-width: 100%;
}

.excel-import-ai-summary b {
  color: #475569;
  font-weight: 800;
}

.excel-import-preview-record-meta p {
  margin: 6px 0 0;
  color: #64748b;
  font-size: 13px;
  line-height: 1.5;
  word-break: break-word;
}

.excel-import-preview-record-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
  flex-shrink: 0;
}

.excel-import-preview-record-status.is-confirmed {
  background: #ecfdf5;
  border-color: #a7f3d0;
  color: #047857;
}

.excel-import-preview-record-status.is-pending {
  background: #fff7ed;
  border-color: #fed7aa;
  color: #c2410c;
}

.excel-import-preview-record-body,
.excel-import-preview-side {
  display: grid;
  gap: 10px;
}

.excel-import-preview-record-body {
  margin-top: 12px;
}

.excel-import-preview-section {
  padding: 10px 12px;
  border: 1px solid #e7edf5;
  border-radius: 14px;
  background: linear-gradient(180deg, #ffffff 0%, #fbfdff 100%);
}

.excel-import-preview-section.is-side {
  padding: 12px;
  background: #fff;
}

.excel-import-preview-section-title,
.excel-import-preview-side-title {
  margin-bottom: 8px;
  color: #0f172a;
  font-size: 13px;
  font-weight: 800;
}

.excel-import-preview-section-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 12px;
}

.excel-import-preview-section.is-side .excel-import-preview-section-grid {
  grid-template-columns: 1fr;
}

.excel-import-preview-field {
  min-width: 0;
}

.excel-import-preview-field.is-wide {
  grid-column: 1 / -1;
}

.excel-import-preview-field-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 5px;
}

.excel-import-preview-field-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  color: #334155;
  font-size: 12px;
  font-weight: 700;
}

.excel-import-preview-field-tag {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  background: #e0f2fe;
  color: #0369a1;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.excel-import-add-option-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 22px;
  padding: 0 7px;
  border: 1px solid #bfdbfe;
  border-radius: 7px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
  cursor: pointer;
  white-space: nowrap;
}

.excel-import-add-option-btn:hover {
  background: #dbeafe;
  border-color: #93c5fd;
}

.excel-import-preview-input,
.excel-import-preview-select,
.excel-import-preview-textarea {
  width: 100%;
  min-height: 34px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #fff;
  color: #0f172a;
  font-size: 12px;
  line-height: 1.4;
  outline: none;
  box-sizing: border-box;
}

.excel-import-preview-input,
.excel-import-preview-select {
  padding: 0 10px;
}

.excel-import-preview-textarea {
  min-height: 52px;
  max-height: 112px;
  padding: 8px 10px;
  resize: vertical;
}

.excel-import-preview-input:focus,
.excel-import-preview-select:focus,
.excel-import-preview-textarea:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.excel-import-preview-ai-field {
  border-color: #7dd3fc;
  background: #f8fdff;
}

.excel-import-region-hint {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
  color: #64748b;
  font-size: 11px;
  line-height: 1.4;
}

.excel-import-region-hint span {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 7px;
  border-radius: 999px;
  background: #f1f5f9;
  color: #334155;
  font-weight: 800;
}

.excel-import-region-hint.is-ai span {
  background: #eef2ff;
  color: #4338ca;
}

.excel-import-region-hint em {
  font-style: normal;
  color: #64748b;
}

.excel-import-region-hint button {
  min-height: 24px;
  padding: 0 8px;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
}

.excel-import-region-hint button:hover {
  border-color: #2563eb;
  background: #dbeafe;
}

.excel-import-preview-side-card {
  padding: 12px;
}

.excel-import-preview-progress {
  display: grid;
  gap: 10px;
}

.excel-import-preview-progress-bar {
  height: 8px;
  border-radius: 999px;
  background: #e2e8f0;
  overflow: hidden;
}

.excel-import-preview-progress-bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #2563eb 0%, #0ea5e9 100%);
  transition: width 0.2s ease;
}

.excel-import-preview-progress-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.excel-import-preview-progress-summary div {
  padding: 10px 8px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #f8fafc;
  text-align: center;
}

.excel-import-preview-progress-summary strong {
  display: block;
  color: #0f172a;
  font-size: 18px;
  line-height: 1;
}

.excel-import-preview-progress-summary span {
  display: block;
  margin-top: 4px;
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
}

.excel-import-preview-side-note {
  color: #475569;
  font-size: 12px;
  line-height: 1.5;
}

.excel-import-preview-side-list {
  display: grid;
  gap: 8px;
}

.excel-import-preview-side-item {
  padding: 10px 11px;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  background: #f8fafc;
  color: #475569;
  font-size: 12px;
  line-height: 1.5;
}

.excel-import-preview-readonly {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 9px;
  border-radius: 8px;
  background: #f1f5f9;
  color: #475569;
  font-size: 12px;
}

.excel-import-confirm-bar {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 0;
  padding: 10px 0 2px;
  border-top: 1px solid #e2e8f0;
  background: #f8fafc;
}

.excel-import-confirm-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.excel-import-confirm-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 150px;
  min-height: 40px;
  padding: 0 16px;
  justify-content: center;
  transition: background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.excel-import-confirm-btn svg {
  width: 16px;
  height: 16px;
}

.excel-import-confirm-btn.is-confirmed {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  border-color: #059669;
}

.excel-import-confirm-btn.is-confirming {
  color: #fff;
  box-shadow: 0 10px 22px rgba(5, 150, 105, 0.24);
  animation: excelImportConfirmButton 0.28s ease-out;
}

.excel-import-final-btn {
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  border-color: #1d4ed8;
  color: #fff;
}

.excel-import-final-btn:disabled {
  background: #cbd5e1;
  border-color: #cbd5e1;
  color: #fff;
}

.excel-import-confirm-btn:disabled {
  opacity: 0.72;
  cursor: not-allowed;
}

.excel-import-complete {
  max-width: 760px;
  margin: 18px auto;
  padding: 30px 28px;
  border: 1px solid #bbf7d0;
  border-radius: 16px;
  background: linear-gradient(180deg, #f0fdf4 0%, #ffffff 100%);
  text-align: center;
  box-shadow: 0 14px 36px rgba(22, 163, 74, 0.10);
}

.excel-import-complete-icon {
  width: 54px;
  height: 54px;
  margin: 0 auto 14px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #16a34a;
  color: #fff;
}

.excel-import-complete-icon svg {
  width: 28px;
  height: 28px;
}

.excel-import-complete h2 {
  margin: 0;
  color: #14532d;
  font-size: 22px;
}

.excel-import-complete p {
  margin: 8px 0 0;
  color: #475569;
  font-size: 13px;
}

.excel-import-complete-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
  gap: 10px;
  margin: 22px 0;
}

.excel-import-complete-stats div {
  padding: 16px 12px;
  border-radius: 12px;
  background: #fff;
  border: 1px solid #dcfce7;
}

.excel-import-complete-stats strong {
  display: block;
  color: #166534;
  font-size: 28px;
  line-height: 1;
}

.excel-import-complete-stats span {
  display: block;
  margin-top: 8px;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
}

.excel-import-complete-actions {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 20px;
}

.excel-import-modal .modal-content {
  width: min(1220px, 98vw);
  max-height: calc(100dvh - 16px);
}

.excel-import-body.is-preview-mode {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding: 12px 16px;
}

.excel-import-body.is-preview-mode > .excel-import-preview {
  flex: 1;
  min-height: 0;
}

.excel-import-preview-scroll {
  gap: 10px;
  padding-right: 3px;
}

.excel-import-preview-head {
  align-items: center;
  padding: 10px 12px;
  border-color: #dbe3ee;
  border-radius: 14px;
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.04);
}

.excel-import-preview-head-main {
  min-width: 0;
}

.excel-import-preview-head h2 {
  font-size: 17px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.excel-import-preview-head p {
  max-width: 640px;
}

.excel-import-preview-badges span {
  max-width: 240px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.excel-import-preview-stage {
  display: block;
}

.excel-import-preview-main-card {
  background: #fff;
  border: 1px solid #dbe3ee;
  border-radius: 14px;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06);
  padding: 12px;
  position: relative;
  overflow: hidden;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.excel-import-preview-main-card.is-confirming {
  border-color: #34d399;
  box-shadow: 0 14px 34px rgba(16, 185, 129, 0.18);
  animation: excelImportConfirmCard 0.28s ease-out;
}

.excel-import-preview-main-card.is-confirming::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(90deg, transparent, rgba(16, 185, 129, 0.14), transparent);
  transform: translateX(-100%);
  animation: excelImportConfirmSweep 0.28s ease-out;
}

.excel-import-preview-record-head {
  align-items: center;
  padding: 0 0 10px;
}

.excel-import-preview-record-meta h3 {
  font-size: 18px;
}

.excel-import-preview-panel-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 318px);
  gap: 10px;
  margin-top: 10px;
  align-items: start;
}

.excel-import-preview-section-main {
  align-self: start;
  padding: 10px;
  border-color: #cfe3ff;
  background: linear-gradient(180deg, #fbfdff 0%, #ffffff 100%);
}

.excel-import-preview-section-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 9px;
}

.excel-import-preview-section-title-row > div:first-child {
  min-width: 0;
  flex: 1 1 auto;
}

.excel-import-preview-section-note {
  flex: 0 0 auto;
  color: #64748b;
  font-size: 12px;
  line-height: 1.2;
  text-align: right;
  white-space: nowrap;
}

.excel-import-preview-section-main .excel-import-preview-section-grid {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 8px;
}

.excel-import-preview-section-main .excel-import-preview-field:nth-child(5) {
  grid-column: span 2;
}

.excel-import-preview-side {
  display: grid;
  gap: 10px;
}

.excel-import-preview-side-card {
  padding: 10px;
  border-radius: 12px;
  box-shadow: none;
}

.excel-import-preview-context-list {
  display: grid;
  gap: 7px;
}

.excel-import-preview-context-item {
  padding: 7px 9px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: #f8fafc;
}

.excel-import-preview-context-label {
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 4px;
}

.excel-import-preview-context-value {
  color: #0f172a;
  font-size: 12px;
  line-height: 1.5;
  word-break: break-word;
  white-space: pre-wrap;
}

.excel-import-confirm-bar {
  position: relative;
  bottom: 0;
  z-index: 2;
  flex-shrink: 0;
  margin-top: 10px;
  padding: 10px 12px;
  border: 1px solid #dbe3ee;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 -8px 24px rgba(15, 23, 42, 0.07);
  backdrop-filter: blur(10px);
}

.excel-import-preview-progress {
  gap: 8px;
}

.excel-import-preview-progress-bar {
  height: 7px;
}

.excel-import-preview-progress-summary {
  gap: 6px;
}

.excel-import-preview-progress-summary div {
  padding: 7px 6px;
  border-radius: 10px;
}

.excel-import-preview-progress-summary strong {
  font-size: 16px;
}

.excel-import-preview-progress-summary span {
  margin-top: 3px;
}

.excel-import-preview-side-note {
  display: none;
}

.excel-import-preview-section-title-row .excel-import-ai-summary {
  margin-top: 5px;
}

.excel-import-preview-section-title-row .excel-import-ai-summary span {
  min-height: 22px;
  padding: 0 7px;
  background: #eef6ff;
  color: #1d4ed8;
  font-size: 10px;
}

.excel-import-preview-field {
  padding: 8px;
  border: 1px solid #dbeafe;
  border-radius: 11px;
  background: #ffffff;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.04);
}

.excel-import-preview-field.is-ai {
  background: #f8fdff;
}

.excel-import-preview-input,
.excel-import-preview-select,
.excel-import-preview-textarea {
  min-height: 36px;
  border-color: #bac7d8;
  font-size: 13px;
}

.excel-import-preview-textarea {
  min-height: 58px;
}

.excel-import-confirm-actions {
  align-items: center;
  gap: 8px;
}

.excel-import-confirm-bar .btn {
  min-height: 38px;
  border-radius: 10px;
}

.excel-import-confirm-btn {
  min-height: 38px;
}

.excel-import-final-btn {
  box-shadow: 0 8px 18px rgba(29, 78, 216, 0.18);
}

@keyframes excelImportConfirmCard {
  0% {
    transform: translateY(0) scale(1);
  }
  48% {
    transform: translateY(-2px) scale(1.006);
  }
  100% {
    transform: translateY(0) scale(1);
  }
}

@keyframes excelImportConfirmSweep {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(100%);
  }
}

@keyframes excelImportConfirmButton {
  0% {
    transform: scale(1);
  }
  46% {
    transform: scale(1.035);
  }
  100% {
    transform: scale(1);
  }
}

@media (prefers-reduced-motion: reduce) {
  .excel-import-preview-main-card,
  .excel-import-preview-main-card.is-confirming,
  .excel-import-preview-main-card.is-confirming::after,
  .excel-import-confirm-btn,
  .excel-import-confirm-btn.is-confirming,
  .ai-collection-orbit-core,
  .ai-collection-orbit-ring,
  .ai-collection-orbit-dot,
  .ai-collection-progress-meter span::after,
  .ai-collection-progress-meter.is-indeterminate span,
  .ai-collection-floating-progress.is-indeterminate .excel-import-floating-meter span,
  .ai-collection-floating-progress,
  .background-task-meter span,
  .background-task-meter.is-indeterminate span,
  .background-task-head-actions button,
  .background-task-actions button {
    animation: none;
    transition: none;
  }
}

.excel-import-detail-modal {
  position: fixed;
  inset: 0;
  z-index: 12000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(15, 23, 42, 0.42);
}

.excel-import-detail-panel {
  width: min(1080px, 96vw);
  max-height: min(86vh, 820px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid #dbe3ee;
  border-radius: 16px;
  background: #ffffff;
  box-shadow: 0 28px 80px rgba(15, 23, 42, 0.24);
}

.excel-import-detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 16px 18px;
  border-bottom: 1px solid #e5e7eb;
  background: #ffffff;
}

.excel-import-detail-head h3 {
  margin: 2px 0 0;
  color: #0f172a;
  font-size: 20px;
  line-height: 1.2;
}

.excel-import-detail-head p {
  margin: 6px 0 0;
  color: #64748b;
  font-size: 12px;
}

.excel-import-detail-close {
  width: 38px;
  height: 38px;
  border: 1px solid #dbe3ee;
  border-radius: 12px;
  background: #fff;
  color: #334155;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.16s ease;
  flex-shrink: 0;
}

.excel-import-detail-close:hover {
  border-color: #fecaca;
  background: #fef2f2;
  color: #b91c1c;
}

.excel-import-detail-close svg {
  width: 18px;
  height: 18px;
}

.excel-import-detail-grid {
  flex: 1;
  min-height: 0;
  overflow: auto;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  padding: 14px 18px;
  background: #f8fafc;
}

.excel-import-detail-field {
  min-width: 0;
  padding: 10px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #ffffff;
}

.excel-import-detail-field.is-ai {
  border-color: #bae6fd;
  background: #f8fdff;
}

.excel-import-detail-field.is-wide {
  grid-column: span 2;
}

.excel-import-detail-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 12px 18px;
  border-top: 1px solid #e5e7eb;
  background: #ffffff;
}

@media (max-width: 1024px) {
  .excel-import-hero {
    grid-template-columns: 1fr;
  }

  .excel-import-fields-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .excel-import-dropzone {
    min-height: 78px;
  }

  .excel-import-preview-stage {
    display: block;
  }

  .excel-import-preview-panel-grid {
    grid-template-columns: 1fr;
  }

  .excel-import-preview-section-main .excel-import-preview-section-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .excel-import-preview-side {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  .excel-import-modal .modal-header {
    padding: 16px 18px;
  }

  .excel-import-header-meta {
    gap: 6px;
  }

  .excel-import-header-chip {
    min-height: 26px;
    padding: 0 10px;
    font-size: 11px;
  }

  .excel-import-body {
    padding: 18px;
  }

  .excel-import-upload-card,
  .excel-import-fields-card,
  .excel-import-aside-card {
    padding: 16px;
  }

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

  .excel-import-dropzone {
    min-height: 74px;
    padding: 12px;
  }

  .excel-import-action-row {
    flex-direction: column;
    align-items: stretch;
  }

  .excel-import-primary-action {
    width: 100%;
    min-height: 46px;
  }

  .excel-import-log-head {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }

  .excel-import-log-head em {
    text-align: left;
  }

  .excel-import-status-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .excel-import-status-tools {
    width: 100%;
    justify-content: space-between;
  }

  .excel-import-floating-progress {
    right: 10px;
    top: auto;
    bottom: 18px;
    width: min(186px, calc(100vw - 20px));
    min-height: 84px;
  }

  .excel-import-floating-notice {
    right: 10px;
    top: auto;
    bottom: 112px;
  }

  .ai-collection-loading-shell {
    width: min(96vw, 640px);
  }

  .ai-collection-progress-card {
    flex-direction: column;
    align-items: center;
    padding: 16px;
  }

  .ai-collection-orbit {
    flex-basis: 96px;
    width: 96px;
    height: 96px;
  }

  .ai-collection-orbit-core {
    width: 56px;
    height: 56px;
    border-radius: 16px;
  }

  .ai-collection-orbit-ring.ring-one {
    width: 78px;
    height: 78px;
  }

  .ai-collection-orbit-ring.ring-two {
    width: 96px;
    height: 96px;
  }

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

  .ai-collection-floating-progress {
    right: 10px;
    top: auto;
    bottom: 122px;
    width: min(186px, calc(100vw - 20px));
  }

  .ai-collection-floating-notice {
    right: 10px;
    top: auto;
    bottom: 216px;
  }

  .background-task-dock {
    width: min(340px, calc(100vw - 20px));
  }

  .background-task-dock.is-compact {
    width: min(260px, calc(100vw - 20px));
  }

  .background-task-list {
    max-height: min(460px, calc(100vh - 180px));
  }

  .background-task-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .background-task-head-actions {
    width: 100%;
    justify-content: flex-end;
  }

  .ai-collection-result-shell {
    width: calc(100vw - 16px);
    height: calc(100vh - 16px);
    max-height: calc(100vh - 16px);
  }

  .ai-result-header,
  .ai-result-body,
  .ai-result-footer {
    padding-left: 16px;
    padding-right: 16px;
  }

  .ai-result-topbar {
    grid-template-columns: 1fr;
  }

  .ai-result-score-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ai-result-rerun-btn {
    width: 100%;
  }

  .ai-result-table {
    min-width: 1280px;
  }

  .ai-result-footer {
    flex-direction: column-reverse;
  }

  .ai-result-footer .btn {
    width: 100%;
  }

  .ai-review-warning-shell {
    width: calc(100vw - 16px);
    max-height: calc(100vh - 16px);
  }

  .ai-review-warning-head,
  .ai-review-warning-body,
  .ai-review-warning-footer {
    padding-left: 16px;
    padding-right: 16px;
  }

  .ai-review-warning-footer {
    flex-direction: column-reverse;
  }

  .ai-review-warning-footer .btn {
    width: 100%;
  }

  .excel-import-preview-head {
    flex-direction: column;
    gap: 10px;
  }

  .excel-import-preview-badges {
    justify-content: flex-start;
  }

  .excel-import-preview-record {
    padding: 14px;
  }

  .excel-import-preview-record-head {
    flex-direction: column;
  }

  .excel-import-preview-record-status {
    align-self: flex-start;
  }

  .excel-import-preview-panel-grid,
  .excel-import-preview-side,
  .excel-import-preview-section-title-row {
    grid-template-columns: 1fr;
    flex-direction: column;
    align-items: stretch;
  }

  .excel-import-preview-section-grid,
  .excel-import-preview-section-main .excel-import-preview-section-grid,
  .excel-import-preview-side {
    grid-template-columns: 1fr;
  }

  .excel-import-preview-section-main .excel-import-preview-field:nth-child(5) {
    grid-column: auto;
  }

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

  .excel-import-detail-field.is-wide {
    grid-column: 1 / -1;
  }

  .excel-import-preview-section-note {
    text-align: left;
  }

  .excel-import-confirm-bar,
  .excel-import-complete-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .excel-import-confirm-actions {
    width: 100%;
  }

  .excel-import-confirm-bar .btn,
  .excel-import-confirm-actions .btn,
  .excel-import-complete-actions .btn {
    width: 100%;
  }

  .excel-import-complete-stats {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .excel-import-fields-grid {
    grid-template-columns: 1fr;
  }

  .ai-collection-metric-grid {
    grid-template-columns: 1fr;
  }

  .excel-import-preview-head,
  .excel-import-preview-record,
  .excel-import-preview-side-card,
  .excel-import-preview-section,
  .excel-import-preview-section.is-side {
    border-radius: 14px;
  }

  .excel-import-preview-progress-summary {
    grid-template-columns: 1fr;
  }

  .excel-import-section-title h2 {
    font-size: 20px;
  }

  .excel-import-drop-title {
    font-size: 13px;
  }

  .excel-import-actions {
    justify-content: stretch;
  }

  .excel-import-primary-action {
    width: 100%;
    min-width: 0;
  }

  .excel-import-detail-modal {
    padding: 10px;
  }

  .excel-import-detail-grid {
    grid-template-columns: 1fr;
  }

  .excel-import-detail-actions {
    flex-direction: column;
  }

  .excel-import-detail-actions .btn {
    width: 100%;
  }
}

/* =====================
   消息中心
===================== */
.messages-container {
  max-width: 1200px;
  margin: 0 auto;
}

.message-list {
  margin-top: 24px;
}

.message-item {
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 16px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  position: relative;
  overflow: hidden;
}

.message-item::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: transparent;
  transition: background 0.3s;
}

.message-item:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1), 0 0 0 1px var(--primary);
  transform: translateY(-2px);
  border-color: var(--primary);
}

.message-item:hover::before {
  background: var(--primary);
}

.message-item.unread {
  background: linear-gradient(135deg, #fef3f2 0%, #ffffff 100%);
  border-left: 4px solid var(--primary);
  box-shadow: 0 2px 8px rgba(220, 38, 38, 0.08);
}

.message-item.unread::before {
  background: var(--primary);
}

.message-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}

.message-type {
  display: inline-block;
  padding: 5px 14px;
  border-radius: 16px;
  font-size: 12px;
  font-weight: 600;
  background: linear-gradient(135deg, #e0f2fe 0%, #bae6fd 100%);
  color: #0369a1;
  box-shadow: 0 1px 3px rgba(3, 105, 161, 0.1);
  letter-spacing: 0.3px;
}

.message-type.rating_request {
  background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
  color: #92400e;
  box-shadow: 0 1px 3px rgba(146, 64, 14, 0.1);
}

.message-type.assignment {
  background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
  color: #1e40af;
  box-shadow: 0 1px 3px rgba(30, 64, 175, 0.1);
}

.message-type.revision {
  background: linear-gradient(135deg, #fce7f3 0%, #fbcfe8 100%);
  color: #9f1239;
  box-shadow: 0 1px 3px rgba(159, 18, 57, 0.1);
}

.message-type.proofread {
  background: linear-gradient(135deg, #f3e8ff 0%, #e9d5ff 100%);
  color: #6b21a8;
  box-shadow: 0 1px 3px rgba(107, 33, 168, 0.1);
}

.message-type.reform {
  background: linear-gradient(135deg, #ffedd5 0%, #fed7aa 100%);
  color: #9a3412;
  box-shadow: 0 1px 3px rgba(154, 52, 18, 0.1);
}

.message-type.deadline {
  background: linear-gradient(135deg, #fee2e2 0%, #fecaca 100%);
  color: #991b1b;
  box-shadow: 0 1px 3px rgba(153, 27, 27, 0.1);
}

.unread-indicator {
  color: var(--danger);
  font-size: 18px;
  line-height: 1;
  margin-left: auto;
}

.message-title {
  font-weight: 600;
  font-size: 16px;
  color: #111827;
  margin-bottom: 8px;
  line-height: 1.4;
}

.message-content {
  font-size: 14px;
  color: #4b5563;
  line-height: 1.7;
  margin-bottom: 12px;
}

.message-manuscript {
  margin-top: 10px;
  padding: 10px 14px;
  background: linear-gradient(135deg, #f9fafb 0%, #f3f4f6 100%);
  border-radius: 8px;
  font-size: 13px;
  color: #6b7280;
  border: 1px solid #e5e7eb;
}

.message-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid #e5e7eb;
}

.message-time {
  font-size: 12px;
  color: #9ca3af;
  display: flex;
  align-items: center;
  gap: 4px;
}

.message-time::before {
  content: '🕐';
  font-size: 14px;
}

.message-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.message-actions .btn {
  padding: 7px 16px;
  font-size: 13px;
  border-radius: 8px;
  transition: all 0.3s;
  font-weight: 500;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.message-actions .btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.message-actions .btn-primary {
  background: linear-gradient(135deg, var(--primary) 0%, #b91c1c 100%);
}

.message-actions .btn-outline {
  border-width: 1.5px;
}

.message-filters {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin: 24px 0;
  padding: 16px;
  background: linear-gradient(135deg, #f9fafb 0%, #ffffff 100%);
  border-radius: 12px;
  border: 1px solid #e5e7eb;
}

.message-stats-detail {
  margin-top: 30px;
  padding: 24px;
  background: linear-gradient(135deg, #ffffff 0%, #f9fafb 100%);
  border-radius: 12px;
  border: 1px solid #e5e7eb;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.message-stats-detail h3 {
  font-size: 17px;
  margin-bottom: 18px;
  color: #111827;
  font-weight: 600;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--primary);
}

/* =====================
   小工具条（排序/筛选条常用容器）
===================== */
.toolbar {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: 10px;
}

.toolbar .form-input {
  width: auto;
  min-width: 180px;
}

/* =====================
   响应式
===================== */
@media (max-width: 768px) {
  .nav-content,
  .main-content {
    padding-left: 12px;
    padding-right: 12px;
  }

  .login-card {
    width: 92vw;
    padding: 30px 22px;
  }

  .brand-lockup-login {
    align-items: center;
    gap: 10px;
  }

  .brand-lockup-login .brand-mark {
    width: 36px;
    height: 36px;
  }

  .login-logo h1 {
    font-size: 18px;
  }

  th, td { max-width: 220px; }
  table { min-width: 1100px; }
  .modal-content { width: 96vw; }
}
/* =====================================================
   PATCH：表格所有列强制一行 + 不省略 + 横向滚动查看（最终版）
   目标：
   - 所有 th/td 一律不换行
   - 不出现省略号
   - 内容完整展示（通过横向滚动查看）
===================================================== */

/* 1) 表格容器：开启横向滚动 */
.table-wrapper{
  overflow-x: auto !important;
  -webkit-overflow-scrolling: touch;
}

/* 2) 表格：宽度按内容撑开（关键），不要被父容器压扁 */
.table-wrapper table{
  width: max-content !important;   /* 让表格按内容自然扩展 */
  min-width: 100% !important;      /* 同时保证不比容器窄（避免很少列时难看） */
  table-layout: auto !important;   /* 不要 fixed，否则容易挤压 */
}

/* 3) 所有表头/单元格：一行展示 + 不省略 + 不断词 */
.table-wrapper th,
.table-wrapper td{
  white-space: nowrap !important;  /* 一行 */
  overflow: visible !important;    /* 不裁剪 */
  text-overflow: clip !important;  /* 不省略号 */
  max-width: none !important;      /* 取消你之前的 max-width */
  word-break: keep-all !important; /* 不拆字 */
  overflow-wrap: normal !important;/* 不强制断行 */
}

/* 3b) 文题列允许换行（覆盖上面的 nowrap） */
.table-wrapper td .title-cell,
.table-wrapper td.title-cell{
  white-space: normal !important;
  word-break: break-all !important;
  overflow-wrap: break-word !important;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
}

/* 4) 额外：防止某些元素（按钮/标签）把单元格撑出奇怪高度 */
.table-wrapper td .btn,
.table-wrapper td .status,
.table-wrapper td a{
  white-space: nowrap !important;
}

/* Editor workspace proofread-link table layout */
.editor-workspace-container .proofread-link-table {
  table-layout: fixed !important;
}

.editor-workspace-container .proofread-link-table th,
.editor-workspace-container .proofread-link-table td {
  padding: 10px 12px;
  vertical-align: middle;
  white-space: normal !important;
  word-break: normal !important;
  overflow-wrap: anywhere !important;
  overflow: visible !important;
  text-overflow: clip !important;
}

.editor-workspace-container .proofread-link-table th {
  background: #f8fafc;
  color: #334155;
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap !important;
  word-break: keep-all !important;
  overflow-wrap: normal !important;
}

.editor-workspace-container .proofread-reserve-cell,
.editor-workspace-container .proofread-seq-cell,
.editor-workspace-container .proofread-issue-cell,
.editor-workspace-container .proofread-pages-cell,
.editor-workspace-container .proofread-link-status-cell {
  text-align: center;
}

.editor-workspace-container .proofread-seq-cell {
  color: #64748b;
  font-weight: 700;
}

.editor-workspace-container .proofread-no-cell {
  color: #2563eb;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
  white-space: nowrap !important;
  word-break: keep-all !important;
  overflow-wrap: normal !important;
}

.editor-workspace-container .proofread-author-cell,
.editor-workspace-container .proofread-person-cell {
  line-height: 1.35;
  color: #334155;
  font-weight: 500;
}

.editor-workspace-container .proofread-title-cell {
  display: block !important;
  max-width: none !important;
  line-height: 1.45 !important;
  color: #334155;
  white-space: normal !important;
  word-break: break-word !important;
  overflow-wrap: anywhere !important;
  -webkit-line-clamp: unset !important;
  line-clamp: unset !important;
}

.editor-workspace-container .proofread-reserve-badge {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  line-height: 1.2;
}

.editor-workspace-container .proofread-reserve-main {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  max-width: 100%;
  min-height: 24px;
  padding: 3px 9px;
  border-radius: 999px;
  border: 1px solid #d1d5db;
  background: #f8fafc;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap !important;
}

.editor-workspace-container .proofread-reserve-mark {
  width: 14px;
  height: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-size: 11px;
  line-height: 1;
  background: #94a3b8;
  color: #fff;
}

.editor-workspace-container .proofread-reserve-issue {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  padding: 3px 7px;
  border-radius: 6px;
  background: #f1f5f9;
  color: #475569;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.25;
  white-space: normal !important;
  word-break: normal !important;
  overflow-wrap: anywhere !important;
}

.editor-workspace-container .proofread-reserve-badge.is-grouped .proofread-reserve-main {
  border-color: #bbf7d0;
  background: #ecfdf5;
  color: #047857;
}

.editor-workspace-container .proofread-reserve-badge.is-grouped .proofread-reserve-mark {
  background: #047857;
}

.editor-workspace-container .proofread-reserve-badge.is-grouped .proofread-reserve-issue {
  background: #10b981;
  color: #fff;
}

.editor-workspace-container .proofread-reserve-badge.is-finalized .proofread-reserve-main {
  border-color: #fecdd3;
  background: #fff1f2;
  color: #be123c;
}

.editor-workspace-container .proofread-reserve-badge.is-finalized .proofread-reserve-mark {
  background: #be123c;
}

.editor-workspace-container .proofread-reserve-badge.is-finalized .proofread-reserve-issue {
  background: #e11d48;
  color: #fff;
}

.editor-workspace-container .proofread-reserve-badge.is-pending .proofread-reserve-main {
  border-color: #fde68a;
  background: #fffbeb;
  color: #b45309;
}

.editor-workspace-container .proofread-reserve-badge.is-pending .proofread-reserve-mark {
  background: #b45309;
}

.editor-workspace-container .proofread-reserve-badge.is-pending .proofread-reserve-issue {
  background: #f59e0b;
  color: #fff;
}

.editor-workspace-container .proofread-reserve-badge.is-free .proofread-reserve-main {
  border-color: #e2e8f0;
  background: #f8fafc;
  color: #64748b;
}

.editor-workspace-container .proofread-status-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  min-height: 30px;
  padding: 5px 10px;
  border-radius: 8px;
  background: var(--proofread-status-bg, #f3f4f6);
  color: var(--proofread-status-color, #374151);
  font-weight: 800;
  font-size: 12px;
  line-height: 1.28;
  text-align: center;
  white-space: normal !important;
  word-break: normal !important;
  overflow-wrap: anywhere !important;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.55);
}

.editor-workspace-container .proofread-issue-cell,
.editor-workspace-container .proofread-issue-label {
  white-space: nowrap !important;
  word-break: keep-all !important;
  overflow-wrap: normal !important;
}

.editor-workspace-container .proofread-link-actions-cell {
  min-width: 214px;
  overflow: visible !important;
  box-shadow: -6px 0 12px rgba(15, 23, 42, 0.06);
}

.editor-workspace-container .proofread-link-actions {
  align-items: center;
  justify-content: center;
  flex-wrap: nowrap !important;
}

/* Editor workspace pending proofread table: keep all columns inside viewport */
.editor-workspace-container .editor-proofread-task-table-container {
  width: 100%;
  overflow-x: hidden !important;
}

.editor-workspace-container .editor-proofread-task-table-container > .table-scroll-bar {
  display: none !important;
}

.editor-workspace-container .editor-proofread-task-table-wrapper {
  width: 100%;
  overflow-x: hidden !important;
  overflow-y: visible !important;
}

body .editor-workspace-container .editor-proofread-task-table-wrapper > table.editor-proofread-task-table {
  width: 100% !important;
  min-width: 0 !important;
  max-width: 100% !important;
  table-layout: fixed !important;
}

.editor-workspace-container .editor-proofread-task-table th,
.editor-workspace-container .editor-proofread-task-table td {
  white-space: normal !important;
  overflow: visible !important;
  text-overflow: clip !important;
  max-width: none !important;
  word-break: normal !important;
  overflow-wrap: anywhere !important;
  padding: 7px 8px;
  vertical-align: middle;
}

.editor-workspace-container .editor-proofread-task-table th {
  white-space: nowrap !important;
  word-break: keep-all !important;
  overflow-wrap: normal !important;
}

.editor-workspace-container .editor-proofread-task-table .proofread-type-cell,
.editor-workspace-container .editor-proofread-task-table .proofread-no-cell,
.editor-workspace-container .editor-proofread-task-table .proofread-author-cell,
.editor-workspace-container .editor-proofread-task-table .proofread-issue-cell-compact,
.editor-workspace-container .editor-proofread-task-table .proofread-editor-cell,
.editor-workspace-container .editor-proofread-task-table .proofread-pages-cell,
.editor-workspace-container .editor-proofread-task-table .proofread-date-cell {
  white-space: nowrap !important;
  word-break: keep-all !important;
  overflow-wrap: normal !important;
}

.editor-workspace-container .editor-proofread-task-table .proofread-title-cell-compact .title-cell {
  max-width: none !important;
  white-space: normal !important;
  word-break: break-word !important;
  overflow-wrap: anywhere !important;
  line-height: 1.38 !important;
}

.editor-workspace-container .editor-proofread-task-table .proofread-column-cell {
  white-space: normal !important;
  word-break: break-word !important;
  overflow-wrap: anywhere !important;
  line-height: 1.35 !important;
}

.editor-workspace-container .editor-proofread-task-table .proofread-editor-cell {
  text-align: center !important;
}

.editor-workspace-container .editor-proofread-task-table .proofread-status-cell {
  font-size: 12px;
  line-height: 1.35;
}

.editor-workspace-container .editor-proofread-task-table .proofread-actions-cell {
  overflow: visible !important;
  padding-left: 6px;
  padding-right: 6px;
}

.editor-workspace-container .editor-proofread-task-table .proofread-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px !important;
  flex-wrap: wrap !important;
}

.editor-workspace-container .editor-proofread-task-table .proofread-actions .btn {
  padding: 5px 9px !important;
  min-height: 28px;
  border-radius: 4px;
  font-size: 12px !important;
  line-height: 1.2;
  white-space: nowrap !important;
}

.editor-workspace-container .editor-proofread-task-table .proofread-actions button[title="删除此校对任务"] {
  width: 30px;
  min-width: 30px;
  padding-left: 0 !important;
  padding-right: 0 !important;
}

.editor-workspace-container .proofread-link-action-btn {
  display: inline-flex;
  align-items: center;
  min-width: 82px;
  height: 32px;
  justify-content: center;
  white-space: nowrap !important;
  padding: 6px 12px;
  border-radius: 4px;
  font-size: 13px;
  font-weight: 500;
}

.editor-workspace-container .proofread-link-edit-btn {
  min-width: 100px;
}

/* PDF upload/link tables must stay within the workspace. Long titles and actions grow vertically instead of forcing a horizontal scrollbar. */
.editor-workspace-container .proofread-link-table-wrapper {
  width: 100%;
  overflow-x: hidden !important;
  overflow-y: visible;
}

.editor-workspace-container .proofread-link-table {
  width: 100% !important;
  min-width: 0 !important;
  max-width: 100% !important;
  table-layout: fixed !important;
}

.editor-workspace-container .proofread-link-table th,
.editor-workspace-container .proofread-link-table td {
  min-width: 0 !important;
  max-width: none !important;
  padding: 6px 5px;
  vertical-align: middle;
  white-space: normal !important;
  word-break: break-word !important;
  overflow-wrap: anywhere !important;
}

.editor-workspace-container .proofread-link-table th {
  font-size: 12px;
  line-height: 1.25;
  text-align: center;
}

.editor-workspace-container .proofread-link-table .proofread-reserve-cell { width: 8%; }
.editor-workspace-container .proofread-link-table .proofread-seq-cell { width: 3%; text-align: center; }
.editor-workspace-container .proofread-link-table .proofread-no-cell { width: 9%; }
.editor-workspace-container .proofread-link-table .proofread-author-cell { width: 7%; }
.editor-workspace-container .proofread-link-table .proofread-title-header,
.editor-workspace-container .proofread-link-table .proofread-title-column,
.editor-workspace-container .proofread-link-table .proofread-title-cell { width: 26%; }
.editor-workspace-container .proofread-link-table th:nth-child(5),
.editor-workspace-container .proofread-link-table td:nth-child(5) { width: 26%; }
.editor-workspace-container .proofread-link-table .proofread-issue-cell { width: 9%; }
.editor-workspace-container .proofread-link-table .proofread-pages-cell { width: 3%; text-align: center; }
.editor-workspace-container .proofread-link-table .proofread-link-status-col,
.editor-workspace-container .proofread-link-table .proofread-link-status-cell { width: 6%; }
.editor-workspace-container .proofread-link-table .proofread-person-cell { width: 6%; }
.editor-workspace-container .proofread-link-table .proofread-link-actions-cell { width: 10%; min-width: 0; overflow: visible !important; box-shadow: none; }
.editor-workspace-container .proofread-link-table.is-pending-link .proofread-title-header,
.editor-workspace-container .proofread-link-table.is-pending-link .proofread-title-column,
.editor-workspace-container .proofread-link-table.is-pending-link .proofread-title-cell { width: 31%; }
.editor-workspace-container .proofread-link-table.is-pending-link th:nth-child(5),
.editor-workspace-container .proofread-link-table.is-pending-link td:nth-child(5) { width: 31%; }
.editor-workspace-container .proofread-link-table.is-pending-link .proofread-link-actions-cell { width: 10%; }

/* The title is the primary scanning field on this page. Do not inherit the
   global two-line title clamp used by other data tables. */
.editor-workspace-container .proofread-link-table td.proofread-title-column > .proofread-title-cell {
  display: block !important;
  width: 100% !important;
  min-width: 0 !important;
  max-width: 100% !important;
  white-space: nowrap !important;
  word-break: normal !important;
  overflow-wrap: normal !important;
  overflow: visible !important;
  text-overflow: clip !important;
}

@media (max-width: 1280px) {
  .editor-workspace-container .proofread-link-table td.proofread-title-column > .proofread-title-cell {
    white-space: normal !important;
    overflow-wrap: anywhere !important;
  }
}

.editor-workspace-container .proofread-link-table .proofread-link-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 7px;
  flex-wrap: nowrap !important;
}

.editor-workspace-container .proofread-link-table .proofread-link-action-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  width: 100%;
  gap: 5px;
}

.editor-workspace-container .proofread-link-table .proofread-link-action-btn,
.editor-workspace-container .proofread-link-table .proofread-link-edit-btn {
  min-width: 0;
  min-height: 29px;
  height: auto;
  padding: 5px 7px;
  font-size: 12px;
  line-height: 1.2;
  white-space: normal !important;
}

.editor-workspace-container .proofread-link-table .proofread-link-action-row .proofread-link-action-btn {
  width: 100%;
}

.editor-workspace-container .proofread-link-table .proofread-pdf-upload-btn {
  width: 100%;
  min-height: 30px;
  border-color: #9b173f;
  background: #9b173f;
  color: #fff;
  font-weight: 700;
}

.editor-workspace-container .proofread-link-table .proofread-pdf-upload-btn:hover,
.editor-workspace-container .proofread-link-table .proofread-pdf-upload-btn:focus-visible {
  border-color: #7d0f31;
  background: #7d0f31;
  color: #fff;
}

/* Adapted from Galaxy UI Forms/Cksunandh: visible affordance, hidden native file control. */
.pdf-proofread-file-field { margin-top: 18px; }
.pdf-proofread-file-field .form-label { display: block; margin-bottom: 8px; font-weight: 700; color: #334155; }
.pdf-proofread-dropzone {
  border: 1.5px dashed #b7c5d6;
  border-radius: 10px;
  background: #f8fafc;
  transition: border-color .18s ease, background .18s ease, box-shadow .18s ease;
}
.pdf-proofread-dropzone:hover,
.pdf-proofread-dropzone.is-dragover,
.pdf-proofread-dropzone.has-file {
  border-color: #9b173f;
  background: #fff7f9;
  box-shadow: 0 0 0 3px rgba(155, 23, 63, .09);
}
.pdf-proofread-dropzone-label {
  display: flex;
  min-height: 112px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 6px;
  padding: 16px;
  color: #41526a;
  cursor: pointer;
  text-align: center;
}
.pdf-proofread-dropzone-icon {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid #d5a0b2;
  border-radius: 50%;
  color: #9b173f;
  background: #fff;
  font-size: 23px;
  line-height: 1;
}
.pdf-proofread-dropzone-label strong { font-size: 14px; }
.pdf-proofread-file-name { max-width: 100%; overflow: hidden; color: #718096; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.pdf-proofread-dropzone.has-file .pdf-proofread-file-name { color: #8e1138; font-weight: 700; }
.pdf-proofread-file-hint { margin: 8px 0 0; color: #64748b; font-size: 12px; }

/* Editor workspace reform table: keep proofread-link actions readable */
.editor-workspace-container .editor-reform-table {
  width: 100% !important;
  min-width: 1410px !important;
  table-layout: fixed !important;
}

.editor-workspace-container .table-wrapper > table.editor-reform-table {
  width: 100% !important;
}

.editor-workspace-container .editor-reform-table th,
.editor-workspace-container .editor-reform-table td {
  padding: 8px 8px;
  vertical-align: middle;
  white-space: normal !important;
  word-break: normal !important;
  overflow-wrap: anywhere !important;
}

.editor-workspace-container .editor-reform-table th {
  background: #f3f4f6;
  color: #374151;
  font-weight: 700;
  white-space: nowrap !important;
  word-break: keep-all !important;
  overflow-wrap: normal !important;
}

.editor-workspace-container .editor-reform-seq-cell {
  width: 52px;
  text-align: center;
  color: #6b7280;
  font-weight: 700;
}

.editor-workspace-container .editor-reform-no-cell {
  width: 124px;
  white-space: nowrap !important;
}

.editor-workspace-container .editor-reform-author-cell {
  width: 96px;
}

.editor-workspace-container .editor-reform-title-cell {
  width: 360px;
}

.editor-workspace-container .editor-reform-title-cell .title-cell {
  max-width: none !important;
  display: block !important;
  white-space: normal !important;
  word-break: break-word !important;
  overflow-wrap: anywhere !important;
  line-height: 1.45 !important;
  -webkit-line-clamp: unset !important;
  line-clamp: unset !important;
}

.editor-workspace-container .editor-reform-issue-cell {
  width: 106px;
  text-align: center;
  white-space: nowrap !important;
  word-break: keep-all !important;
  overflow-wrap: normal !important;
}

.editor-workspace-container .editor-reform-editor-cell {
  width: 84px;
  text-align: center;
}

.editor-workspace-container .editor-reform-link-cell {
  width: 156px;
  text-align: center;
  white-space: normal !important;
}

.editor-workspace-container .editor-reform-link-btn {
  width: 124px;
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  background: #eff6ff;
  color: #1d4ed8;
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap !important;
  transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease, box-shadow 0.16s ease;
}

.editor-workspace-container .editor-reform-link-btn:hover,
.editor-workspace-container .editor-reform-link-btn:focus-visible {
  background: #dbeafe;
  border-color: #60a5fa;
  color: #1e40af;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
  outline: none;
}

.editor-workspace-container .editor-reform-link-btn.is-reform {
  border-color: #a7f3d0;
  background: #ecfdf5;
  color: #047857;
}

.editor-workspace-container .editor-reform-link-btn.is-reform:hover,
.editor-workspace-container .editor-reform-link-btn.is-reform:focus-visible {
  border-color: #34d399;
  background: #d1fae5;
  color: #065f46;
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.14);
}

.editor-workspace-container .editor-reform-missing-link-btn {
  width: 128px;
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #fda4af;
  border-radius: 8px;
  background: #fff1f2;
  color: #be123c;
  cursor: pointer;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.18;
  white-space: normal !important;
  text-align: center;
  box-shadow: 0 0 0 3px rgba(244, 63, 94, 0.07);
  transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease, box-shadow 0.16s ease;
}

.editor-workspace-container .editor-reform-missing-link-btn:hover,
.editor-workspace-container .editor-reform-missing-link-btn:focus-visible {
  border-color: #fb7185;
  background: #ffe4e6;
  color: #9f1239;
  outline: none;
  box-shadow: 0 0 0 3px rgba(244, 63, 94, 0.14);
}

.editor-workspace-container .editor-reform-proofreader-cell {
  width: 108px;
  text-align: center;
  line-height: 1.35;
}

.editor-workspace-container .editor-reform-status-cell {
  width: 128px;
  text-align: center;
}

.editor-workspace-container .editor-reform-state-badge {
  min-height: 26px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.2;
  white-space: normal !important;
  word-break: keep-all !important;
  overflow-wrap: normal !important;
  text-align: center;
}

.editor-workspace-container .editor-reform-state-badge.is-pending {
  background: #fef3c7;
  color: #b45309;
}

.editor-workspace-container .editor-reform-state-badge.is-link-missing {
  min-width: 116px;
  border: 1px solid #fda4af;
  background: #ffe4e6;
  color: #be123c;
  box-shadow: 0 0 0 3px rgba(244, 63, 94, 0.08);
}

.editor-workspace-container .editor-reform-state-badge.is-done {
  background: #dcfce7;
  color: #047857;
}

.editor-workspace-container .editor-reform-actions-cell {
  width: 178px;
  min-width: 178px;
  text-align: center;
  vertical-align: middle !important;
  padding-left: 6px !important;
  padding-right: 6px !important;
  position: static;
  right: auto;
  z-index: auto;
  background: #fff;
  box-shadow: none;
}

.editor-workspace-container th.editor-reform-actions-cell {
  background: #f3f4f6;
  z-index: auto;
}

.editor-workspace-container .editor-reform-sticky-status {
  position: static;
  right: auto;
  z-index: auto;
  background: #fff;
}

.editor-workspace-container th.editor-reform-sticky-status {
  background: #f3f4f6;
  z-index: auto;
}

.editor-workspace-container .editor-reform-sticky-third {
  position: static;
  right: auto;
  z-index: auto;
  background: #fff;
}

.editor-workspace-container th.editor-reform-sticky-third {
  background: #f3f4f6;
  z-index: auto;
}

.editor-workspace-container .editor-reform-sticky-second {
  position: static;
  right: auto;
  z-index: auto;
  background: #fff;
}

.editor-workspace-container th.editor-reform-sticky-second {
  background: #f3f4f6;
  z-index: auto;
}

.editor-workspace-container .editor-reform-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: 100%;
  min-height: 32px;
  flex-wrap: wrap;
}

.editor-workspace-container .editor-reform-actions .btn {
  min-height: 28px;
  padding: 5px 9px !important;
  border-radius: 4px;
  font-size: 12px !important;
  line-height: 1.2;
  font-weight: 700;
  white-space: nowrap !important;
}

.editor-workspace-container .editor-reform-actions .editor-reform-upload-link-btn {
  background: #be123c !important;
  border-color: #be123c !important;
  color: #fff !important;
  box-shadow: 0 8px 18px rgba(190, 18, 60, 0.18);
}

.editor-workspace-container .editor-reform-actions .editor-reform-upload-link-btn:hover {
  background: #9f1239 !important;
  border-color: #9f1239 !important;
}

.editor-workspace-container .editor-reform-actions .editor-reform-link-btn {
  width: auto;
  min-width: 112px;
  min-height: 30px;
  padding: 5px 10px;
  border-radius: 6px;
  font-size: 12px;
}

.editor-workspace-container .editor-reform-opinion-btn {
  min-width: 78px;
  padding: 5px 9px !important;
  margin: 0;
  background: #8b5cf6 !important;
  border-color: #8b5cf6 !important;
  color: #fff !important;
  box-shadow: 0 8px 18px rgba(139, 92, 246, 0.18);
}

.editor-workspace-container .editor-reform-opinion-btn:hover,
.editor-workspace-container .editor-reform-opinion-btn:focus-visible {
  background: #7c3aed !important;
  border-color: #7c3aed !important;
  color: #fff !important;
}

.editor-workspace-container .editor-reform-table-action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent !important;
  box-sizing: border-box;
  cursor: pointer;
  letter-spacing: 0;
}

.editor-workspace-container .editor-reform-confirm-table-btn {
  min-width: 78px;
  background: #f97316 !important;
  border-color: #f97316 !important;
  color: #fff !important;
  box-shadow: 0 8px 18px rgba(249, 115, 22, 0.2);
}

.editor-workspace-container .editor-reform-confirm-table-btn:hover,
.editor-workspace-container .editor-reform-confirm-table-btn:focus-visible {
  background: #ea580c !important;
  border-color: #ea580c !important;
  color: #fff !important;
}

.editor-workspace-container .editor-reform-upload-link-table-btn {
  min-width: 78px;
  background: #0891b2 !important;
  border-color: #0891b2 !important;
  color: #fff !important;
  box-shadow: 0 8px 18px rgba(8, 145, 178, 0.2);
}

.editor-workspace-container .editor-reform-upload-link-table-btn:hover,
.editor-workspace-container .editor-reform-upload-link-table-btn:focus-visible {
  background: #0e7490 !important;
  border-color: #0e7490 !important;
  color: #fff !important;
}

.editor-workspace-container .editor-reform-edit-link-table-btn {
  min-width: 78px;
  background: #0f766e !important;
  border-color: #0f766e !important;
  color: #fff !important;
  box-shadow: 0 8px 18px rgba(15, 118, 110, 0.2);
}

.editor-workspace-container .editor-reform-edit-link-table-btn:hover,
.editor-workspace-container .editor-reform-edit-link-table-btn:focus-visible {
  background: #115e59 !important;
  border-color: #115e59 !important;
  color: #fff !important;
}

.editor-reform-confirm-btn {
  min-height: 36px;
  padding: 8px 16px !important;
  border: 1px solid #f97316 !important;
  border-radius: 8px;
  background: linear-gradient(135deg, #f97316 0%, #ea580c 100%) !important;
  color: #fff !important;
  font-weight: 800;
  box-shadow: 0 10px 22px rgba(234, 88, 12, 0.24);
}

.editor-reform-confirm-btn:hover,
.editor-reform-confirm-btn:focus-visible {
  border-color: #c2410c !important;
  background: linear-gradient(135deg, #ea580c 0%, #c2410c 100%) !important;
  color: #fff !important;
  box-shadow: 0 12px 26px rgba(194, 65, 12, 0.28);
  outline: none;
}

.editor-reform-opinion-links {
  display: grid;
  gap: 8px;
}

.editor-reform-opinion-link-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid #dbeafe;
  border-radius: 8px;
  background: #eff6ff;
}

.editor-reform-opinion-link-row.is-empty {
  grid-template-columns: 96px 1fr;
  border-color: #e5e7eb;
  background: #f8fafc;
}

.editor-reform-opinion-link-row span {
  display: block;
  margin-bottom: 4px;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
}

.editor-reform-opinion-link-row strong {
  display: block;
  color: #1e40af;
  font-size: 13px;
  line-height: 1.4;
  word-break: break-all;
  overflow-wrap: anywhere;
}

.editor-reform-opinion-link-row.is-empty strong {
  color: #94a3b8;
}

.editor-reform-link-view-list {
  display: grid;
  gap: 12px;
}

.editor-reform-link-view {
  border: 1px solid #bbf7d0;
  border-radius: 10px;
  background: #f0fdf4;
  padding: 14px;
}

.editor-reform-link-view.is-empty {
  border-color: #e5e7eb;
  background: #f8fafc;
}

.editor-reform-link-view-title {
  margin-bottom: 10px;
  color: #14532d;
  font-size: 15px;
  font-weight: 800;
}

.editor-reform-link-view.is-empty .editor-reform-link-view-title {
  color: #475569;
}

.editor-reform-link-empty {
  color: #94a3b8;
  font-weight: 700;
}

.editor-reform-link-view-body {
  display: grid;
  gap: 10px;
}

.editor-reform-link-field {
  padding: 10px 12px;
  border: 1px solid #d1fae5;
  border-radius: 8px;
  background: #fff;
}

.editor-reform-link-field span {
  display: block;
  margin-bottom: 6px;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}

.editor-reform-link-field pre {
  margin: 0;
  color: #1f2937;
  font-family: inherit;
  font-size: 13px;
  line-height: 1.55;
  white-space: pre-wrap;
  word-break: break-all;
  overflow-wrap: anywhere;
}

.editor-reform-link-field.is-raw-only {
  color: #1f2937;
  font-size: 14px;
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-word;
  overflow-wrap: anywhere;
}

.editor-reform-inline-link {
  color: #2563eb;
  font-weight: 800;
  text-decoration: none;
  word-break: break-all;
}

.editor-reform-inline-link:hover,
.editor-reform-inline-link:focus-visible {
  color: #1d4ed8;
  text-decoration: underline;
  outline: none;
}

.editor-reform-link-field strong {
  display: block;
  color: #2563eb;
  font-size: 14px;
  line-height: 1.45;
  word-break: break-all;
  overflow-wrap: anywhere;
}

.editor-reform-link-actions-inline {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.editor-reform-opinion-modal .modal-content {
  max-height: calc(100vh - 64px);
  display: flex;
  flex-direction: column;
}

.editor-reform-opinion-modal .modal-body {
  overflow-y: auto;
}

.editor-reform-opinion-modal .modal-footer {
  flex-shrink: 0;
  position: sticky;
  bottom: 0;
  background: #fff;
  border-top: 1px solid #e5e7eb;
  padding-top: 12px;
}
/* =====================================================
   Safari 兼容性补丁（修复 DevTools 提示）
   1) user-select -> -webkit-user-select
   2) backdrop-filter -> -webkit-backdrop-filter + 降级
===================================================== */

/* 1) 按钮禁止选中文本：Safari 需要 -webkit-user-select */
.btn{
  -webkit-user-select: none;   /* Safari */
  user-select: none;           /* Standard */
  -webkit-touch-callout: none; /* iOS Safari 长按不弹出菜单（可选但推荐） */
}

/* 2) 你截图提示的 backdrop-filter：Safari 需要 -webkit-backdrop-filter
   如果你是在 #stickyHScrollBar .hscroll-outer 里用的，就在 CSS 里补这一段。
   （你截图显示它在 index.html 里写了 backdrop-filter，所以这段放 CSS 里能彻底消掉提示） */
#stickyHScrollBar .hscroll-outer{
  /* 建议给半透明背景，不然 blur 可能看起来没效果 */
  background: rgba(255, 255, 255, 0.65);

  -webkit-backdrop-filter: blur(6px); /* Safari */
  backdrop-filter: blur(6px);         /* Standard */
}

/* 2.1) 降级：如果浏览器不支持 backdrop-filter，就用更实一点的背景 */
@supports not ((-webkit-backdrop-filter: blur(0)) or (backdrop-filter: blur(0))) {
  #stickyHScrollBar .hscroll-outer{
    background: rgba(255, 255, 255, 0.92);
  }
}

/* =====================================================
   FINAL SIMPLE PATCH
   表格顶部增加一个原生横向滚动条
===================================================== */

/* 顶部横向滚动条容器 */
.table-wrapper::before{
  content: "";
  display: block;
  height: 14px;
  overflow-x: auto;
  overflow-y: hidden;
}

/* 让顶部滚动条可滚 */
.table-wrapper::before{
  scrollbar-color: #cbd5e1 #f3f4f6;
}

/* WebKit 滚动条高度 */
.table-wrapper::before::-webkit-scrollbar{
  height: 14px;
}

/* =====================================================
   FINAL PATCH - 表格顶部横向滚动条（真实 DOM 版）
===================================================== */

.table-scroll-outer{
  width: 100%;
}

.table-scroll-top{
  height: 14px;
  overflow-x: auto;
  overflow-y: hidden;
}

.table-scroll-top > div{
  height: 1px;
}

/* =====================================================
   终极样式补丁 v3.0
   - 双滚动条样式
   - 统一表格样式
   - 图标按钮优化
===================================================== */

/* 双滚动条容器 */
.table-scroll-container {
  width: 100%;
  overflow: hidden;
  margin-bottom: 0;
}

.table-scroll-bar {
  width: 100%;
  height: 20px;
  overflow-x: auto;
  overflow-y: hidden;
  border: 1px solid var(--border, #ddd);
  border-radius: 8px;
  background: linear-gradient(to bottom, #f8f8f8, #f0f0f0);
  margin-bottom: 12px;
  box-shadow: inset 0 1px 3px rgba(0,0,0,0.05);
}

.table-scroll-bar::-webkit-scrollbar {
  height: 14px;
}

.table-scroll-bar::-webkit-scrollbar-track {
  background: #f0f0f0;
  border-radius: 8px;
}

.table-scroll-bar::-webkit-scrollbar-thumb {
  background: linear-gradient(to bottom, #c0c0c0, #a0a0a0);
  border-radius: 8px;
  border: 2px solid #f0f0f0;
}

.table-scroll-bar::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(to bottom, #a0a0a0, #808080);
}

.scroll-bar-inner {
  height: 1px;
  pointer-events: none;
}

/* 表格容器 */
.table-wrapper {
  width: 100%;
  overflow-x: auto;
  overflow-y: visible;
  border: 1px solid var(--border, #ddd);
  border-radius: 8px;
  background: white;
}

.table-wrapper::-webkit-scrollbar {
  height: 14px;
}

.table-wrapper::-webkit-scrollbar-track {
  background: #f0f0f0;
  border-radius: 8px;
}

.table-wrapper::-webkit-scrollbar-thumb {
  background: linear-gradient(to bottom, #c0c0c0, #a0a0a0);
  border-radius: 8px;
  border: 2px solid #f0f0f0;
}

.table-wrapper::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(to bottom, #a0a0a0, #808080);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  background: white;
  font-size: 13px;
}

.data-table thead {
  background: linear-gradient(to bottom, #f8f9fa, #e9ecef);
  position: sticky;
  top: 0;
  z-index: 10;
}

.data-table th {
  padding: 2px 4px;
  text-align: left;
  font-weight: 600;
  color: #2c3e50;
  border-bottom: 2px solid #dee2e6;
  white-space: nowrap;
  font-size: 13px;
}

.data-table td {
  padding: 2px 4px;
  border-bottom: 1px solid #f0f0f0;
  vertical-align: middle;
  font-size: 13px;
}

.data-table tbody tr:hover {
  background: #f8f9fa;
}

.data-table tbody tr.dragging {
  opacity: 0.4;
  background: #e3f2fd;
}

/* 图标按钮（✏️编辑按钮） */
.icon-btn {
  background: none;
  border: none;
  font-size: 18px;
  cursor: pointer;
  padding: 4px 8px;
  transition: transform 0.2s, opacity 0.2s;
  opacity: 0.7;
}

.icon-btn:hover {
  transform: scale(1.2);
  opacity: 1;
}

.icon-btn:active {
  transform: scale(0.95);
}

/* 操作列 */
.action-cell {
  text-align: center;
  padding: 8px !important;
}

/* 拖动手柄 */
.drag-handle {
  cursor: move;
  text-align: center;
  color: #999;
  font-size: 16px;
  user-select: none;
}

.drag-handle:hover {
  color: #333;
}

/* 卡片头部带检索 */
.card-header-with-search {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 2px solid #e9ecef;
}

.card-header-with-search .card-title {
  font-size: 20px;
  font-weight: 700;
  color: #2c3e50;
  margin: 0;
}

/* 检索框 */
.search-box {
  display: flex;
  gap: 8px;
  align-items: center;
}

.search-input {
  width: 280px;
  padding: 8px 12px;
  border: 1px solid #ced4da;
  border-radius: 6px;
  font-size: 14px;
}

.search-input:focus {
  border-color: #4CAF50;
outline: none;
box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.1);
}

.collection-select-header {
  padding: 20px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  gap: 12px;
}

.collection-select-title-row {
  min-width: 0;
}

.collection-select-title {
  white-space: nowrap;
  overflow: visible;
  line-height: 1.25;
}

.collection-select-search-row {
  width: 100%;
}

.collection-select-search-field {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
}

.collection-select-search-input {
  width: 100%;
  height: 42px;
  padding: 9px 14px 9px 44px;
  border: 1.5px solid #dbe3ee;
  border-radius: 9px;
  background: #ffffff;
  color: #1e293b;
  font-size: 14px;
  font-weight: 600;
  outline: none;
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
}

.collection-select-search-input:focus {
  border-color: #8b1538;
  box-shadow: 0 0 0 3px rgba(139, 21, 56, 0.1);
}

.collection-select-action-row {
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.search-btn {
padding: 8px 16px;
background: #4CAF50;
color: white;
border: none;
border-radius: 6px;
font-size: 14px;
font-weight: 600;
cursor: pointer;
transition: all 0.2s;
white-space: nowrap;
}

.search-btn:hover {
background: #45a049;
transform: translateY(-1px);
box-shadow: 0 2px 8px rgba(76, 175, 80, 0.3);
}

.search-btn:active {
transform: translateY(0);
}

.reserve-toolbar-header {
  gap: 16px;
  align-items: flex-start;
}

.reserve-header-summary {
  min-width: 220px;
}

.reserve-header-note {
  margin-top: 4px;
  color: #94a3b8;
  font-size: 12px;
  line-height: 1.5;
}

.reserve-sub-tab-bar {
  display: flex;
  align-items: stretch;
  gap: 18px;
  border-bottom: 2px solid #e5e7eb;
  padding: 0 20px;
  flex-shrink: 0;
}

.reserve-sub-tabs {
  flex: 0 0 auto;
  display: flex;
  align-items: stretch;
  gap: 0;
}

.reserve-sub-tab-btn {
  min-height: 56px;
  padding: 0 24px;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  background: none;
  color: #6b7280;
  cursor: pointer;
  font-size: 15px;
  font-weight: 500;
  transition: color .18s ease, background .18s ease, border-color .18s ease;
}

.reserve-sub-tab-btn:hover {
  background: #f8fafc;
  color: #8b1538;
}

.reserve-sub-tab-btn.active {
  border-bottom-color: #667eea;
  color: #667eea;
  font-weight: 700;
}

.reserve-toolbar-actions,
.reserve-simple-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  flex-wrap: wrap;
}

.reserve-global-search {
  flex: 1 1 460px;
  align-self: center;
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: none;
  min-height: 46px;
  margin: 7px 0 8px auto;
  padding: 6px 8px 6px 14px;
  background: #fff;
  border: 1px solid #dbe3ec;
  border-radius: 18px;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
}

.reserve-global-search-icon {
  flex-shrink: 0;
  font-size: 18px;
  line-height: 1;
}

.reserve-global-search-input {
  flex: 1 1 auto;
  width: auto;
  min-width: 260px;
  border: none;
  outline: none;
  background: transparent;
  color: #0f172a;
  font-size: 14px;
  line-height: 1.4;
}

.reserve-global-search-input::placeholder {
  color: #94a3b8;
}

.reserve-global-search-submit {
  min-height: 34px;
  padding: 0 16px;
  border-radius: 10px;
  white-space: nowrap;
}

.reserve-single-add-btn {
  gap: 8px;
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  color: #fff;
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.22);
}

.reserve-single-add-btn:hover {
  background: linear-gradient(135deg, #1d4ed8 0%, #1e40af 100%);
  box-shadow: 0 10px 22px rgba(29, 78, 216, 0.28);
}

.reserve-single-add-icon {
  width: 18px;
  height: 18px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: rgba(255, 255, 255, 0.22);
  color: #fff;
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
}

.reserve-main-table th,
.reserve-main-table td {
  vertical-align: middle;
}

.table-wrapper .reserve-main-table td.reserve-research-direction-cell,
.reserve-main-table td.reserve-research-direction-cell {
  white-space: normal !important;
  word-break: break-word !important;
  overflow-wrap: anywhere !important;
  overflow: visible !important;
  text-overflow: clip !important;
  line-height: 1.45 !important;
}

.reserve-main-table .btn-sm {
  min-width: 64px;
  justify-content: center;
}

.reserve-view-btn {
  border-color: #bfdbfe;
  background: #eff6ff;
  color: #1d4ed8;
  font-weight: 700;
}

.reserve-view-btn:hover {
  border-color: #93c5fd;
  background: #dbeafe;
  color: #1e40af;
}

.reserve-excel-import-btn {
  min-height: 44px;
  padding: 0 18px;
  border: none;
  border-radius: 12px;
  background: linear-gradient(135deg, #0f766e 0%, #14b8a6 100%);
  color: #fff;
  box-shadow: 0 10px 22px rgba(20, 184, 166, 0.22);
  white-space: nowrap;
}

.reserve-excel-import-btn:hover {
  background: linear-gradient(135deg, #0b5f5a 0%, #0ea5a1 100%);
  transform: translateY(-1px);
  box-shadow: 0 14px 26px rgba(15, 118, 110, 0.26);
}

.reserve-excel-import-btn--compact {
  min-height: 40px;
  padding: 0 16px;
}

/* 工具栏 */
.toolbar {
display: flex;
gap: 10px;
margin-bottom: 16px;
flex-wrap: wrap;
}

/* 期数分组 */
.issue-section {
margin-bottom: 32px;
}

.issue-header {
font-size: 16px;
font-weight: 700;
padding: 12px 16px;
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
color: white;
border-radius: 8px;
margin-bottom: 12px;
box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

/* 快捷面板 */
.quick-panels {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 16px;
margin-bottom: 24px;
}

.quick-panel {
background: #f8f9fa;
border: 1px solid #dee2e6;
border-radius: 12px;
padding: 16px;
box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.panel-title {
font-size: 15px;
font-weight: 700;
margin-bottom: 12px;
color: #2c3e50;
padding-bottom: 8px;
border-bottom: 2px solid #e9ecef;
}

.panel-content {
display: flex;
flex-direction: column;
gap: 8px;
}

.panel-row {
display: flex;
justify-content: space-between;
align-items: center;
padding: 8px 12px;
background: white;
border: 1px solid #e9ecef;
border-radius: 6px;
transition: all 0.2s;
}

.panel-row:hover {
background: #f1f3f5;
border-color: #4CAF50;
transform: translateX(2px);
}

.panel-label {
font-weight: 600;
color: #495057;
}

.panel-empty {
text-align: center;
color: #adb5bd;
padding: 20px;
font-size: 13px;
}

/* 按钮尺寸 */
.btn-sm {
padding: 6px 12px;
font-size: 13px;
border-radius: 5px;
}

/* 状态徽章 */
.status-badge {
display: inline-block;
padding: 4px 10px;
border-radius: 12px;
font-size: 12px;
font-weight: 600;
white-space: nowrap;
}

.status-success {
background: #d4edda;
color: #155724;
}

.status-warning {
background: #fff3cd;
color: #856404;
}

.status-danger {
background: #f8d7da;
color: #721c24;
}

.status-info {
background: #d1ecf1;
color: #0c5460;
}

.status-default {
background: #e9ecef;
color: #495057;
}

/* 链接按钮 */
.link-btn {
color: #007bff;
text-decoration: none;
font-weight: 600;
transition: all 0.2s;
}

.link-btn:hover {
color: #0056b3;
text-decoration: underline;
}

/* 表单控件 */
.form-select {
padding: 6px 10px;
border: 1px solid #ced4da;
border-radius: 5px;
font-size: 13px;
background: white;
cursor: pointer;
transition: border-color 0.2s;
}

.form-select:hover {
border-color: #4CAF50;
}

.form-select:focus {
border-color: #4CAF50;
outline: none;
box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.1);
}

.form-select.compact {
min-width: 120px;
max-width: 180px;
}

/* 空状态 */
.empty-state, .empty-cell {
text-align: center;
padding: 40px 20px;
color: #adb5bd;
font-size: 14px;
}

/* 响应式调整 */
@media (max-width: 1200px) {
.quick-panels {
grid-template-columns: 1fr;
}

.search-input {
width: 200px;
}

.reserve-global-search-input {
min-width: 220px;
}
}

@media (max-width: 768px) {
.card-header-with-search {
flex-direction: column;
align-items: flex-start;
gap: 12px;
}

.search-box {
width: 100%;
}

.search-input {
flex: 1;
}

.reserve-toolbar-actions,
.reserve-simple-actions {
width: 100%;
justify-content: flex-start;
}

.reserve-sub-tab-bar {
width: 100%;
flex-direction: column;
gap: 10px;
padding: 0 12px 12px;
}

.reserve-sub-tabs {
width: 100%;
overflow-x: auto;
}

.reserve-sub-tab-btn {
min-width: max-content;
padding: 0 16px;
}

.reserve-global-search {
width: 100%;
margin: 0;
}

.reserve-global-search-input {
flex: 1 1 auto;
width: auto;
min-width: 0;
}
}

/* 动画效果 */
@keyframes fadeIn {
from {
opacity: 0;
transform: translateY(-10px);
}
to {
opacity: 1;
transform: translateY(0);
}
}

.issue-section {
animation: fadeIn 0.3s ease;
}

/* 确保所有页面样式一致 */
#tabContent .card {
background: white;
border-radius: 12px;
padding: 24px;
box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

/* 打印样式优化 */
@media print {
.search-box,
.toolbar,
.icon-btn,
.drag-handle,
.quick-panels {
display: none !important;
}

.table-scroll-bar {
display: none !important;
}

.table-wrapper {
overflow: visible !important;
border: none !important;
}
}


/* 本文编辑工作台补充样式 */

/* 截止日期徽章 */
.deadline-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 600;
  background: #ff6b6b;
  color: white;
  margin-left: 8px;
}

.deadline-overdue {
  color: #d32f2f;
  font-weight: 700;
  animation: pulse 1.5s ease-in-out infinite;
}

.deadline-urgent {
  color: #f57c00;
  font-weight: 700;
}

.deadline-normal {
  color: #388e3c;
  font-weight: 600;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

/* 紧急面板行 */
.panel-urgent {
  border-left: 3px solid #f44336;
  background: #ffebee;
}

.panel-urgent:hover {
  background: #ffcdd2;
}

/* 高亮行（待处理） */
.row-highlight {
  background: #fff9e6 !important;
  border-left: 3px solid #ffa726;
}

.row-highlight:hover {
  background: #fff3d1 !important;
}

/* 快捷面板（如果之前没有） */
.quick-panels {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

.quick-panel {
  background: #f8f9fa;
  border: 1px solid #dee2e6;
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.panel-title {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 12px;
  color: #2c3e50;
  padding-bottom: 8px;
  border-bottom: 2px solid #e9ecef;
}

.panel-content {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.panel-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  background: white;
  border: 1px solid #e9ecef;
  border-radius: 6px;
  transition: all 0.2s;
}

.panel-row:hover {
  background: #f1f3f5;
  border-color: #4CAF50;
  transform: translateX(2px);
}

.panel-label {
  font-weight: 600;
  color: #495057;
}

.panel-empty {
  text-align: center;
  color: #adb5bd;
  padding: 20px;
  font-size: 13px;
}

/* 响应式调整 */
@media (max-width: 1400px) {
  .quick-panels {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .quick-panels {
    grid-template-columns: 1fr;
  }
}

/* =====================================================
   聚类功能完整样式 v4.0
===================================================== */

/* 筛选容器 */
.filter-bar-container {
  background: white;
  border: 1px solid #dee2e6;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 20px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.filter-section {
  margin-bottom: 20px;
}

.filter-section:last-child {
  margin-bottom: 0;
}

.section-title {
  font-size: 15px;
  font-weight: 700;
  color: #2c3e50;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 2px solid #e9ecef;
}

/* 排序行 */
.filter-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* 筛选网格 */
.filter-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 12px;
}

.filter-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.filter-label {
  font-size: 13px;
  font-weight: 600;
  color: #495057;
}

.form-select.compact {
  padding: 6px 10px;
  font-size: 13px;
}

/* 筛选操作按钮 */
.filter-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  padding-top: 12px;
  border-top: 1px solid #e9ecef;
}

.filter-count {
  margin-left: auto;
  font-size: 13px;
  color: #6c757d;
  font-weight: 600;
}

/* 响应式调整 */
@media (max-width: 1400px) {
  .filter-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  
  .advanced-filters-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 992px) {
  .filter-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .advanced-filters-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .filter-grid {
    grid-template-columns: 1fr;
  }
  
  .filter-row {
    flex-direction: column;
  }
}

/* 按钮样式优化 */
.btn-info {
  background: #17a2b8;
  color: white;
  border: none;
}

.btn-info:hover {
  background: #138496;
}

.btn-sm {
  padding: 6px 12px;
  font-size: 13px;
}

/* 滚动条美化 */
.advanced-filters-grid::-webkit-scrollbar {
  width: 8px;
}

.advanced-filters-grid::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 4px;
}

.advanced-filters-grid::-webkit-scrollbar-thumb {
  background: #888;
  border-radius: 4px;
}

.advanced-filters-grid::-webkit-scrollbar-thumb:hover {
  background: #555;
}

/* =====================================================
   补丁 v5.4 - 样式修复
   1. 隐藏下方滚动条
   2. 编辑弹窗垂直布局
===================================================== */

/* 隐藏表格容器的底部滚动条 */
.table-wrapper {
  width: 100%;
  overflow-x: hidden !important; /* 强制隐藏底部滚动条 */
  overflow-y: visible;
  border: 1px solid var(--border, #ddd);
  border-radius: 8px;
  background: white;
}

/* 保持顶部滚动条样式 */
.table-scroll-bar {
  width: 100%;
  height: 20px;
  overflow-x: auto;
  overflow-y: hidden;
  border: 1px solid var(--border, #ddd);
  border-radius: 8px;
  background: linear-gradient(to bottom, #f8f8f8, #f0f0f0);
  margin-bottom: 12px;
  box-shadow: inset 0 1px 3px rgba(0,0,0,0.05);
}

.table-scroll-bar::-webkit-scrollbar {
  height: 14px;
}

.table-scroll-bar::-webkit-scrollbar-track {
  background: #f0f0f0;
  border-radius: 8px;
}

.table-scroll-bar::-webkit-scrollbar-thumb {
  background: linear-gradient(to bottom, #c0c0c0, #a0a0a0);
  border-radius: 8px;
  border: 2px solid #f0f0f0;
}

.table-scroll-bar::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(to bottom, #a0a0a0, #808080);
}

.scroll-bar-inner {
  height: 1px;
  pointer-events: none;
}

/* 编辑弹窗垂直布局 */
.modal-vertical-layout {
  max-width: 700px;
  width: 95%;
}

.modal-body-vertical {
  max-height: 70vh;
  overflow-y: auto;
  padding: 24px;
}

.modal-body-vertical .form-group {
  margin-bottom: 16px;
}

.modal-body-vertical .form-label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: #495057;
  margin-bottom: 6px;
}

.modal-body-vertical .form-label .required {
  color: #dc3545;
}

.modal-body-vertical .form-input,
.modal-body-vertical .form-select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #ced4da;
  border-radius: 6px;
  font-size: 14px;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.modal-body-vertical .form-input:focus,
.modal-body-vertical .form-select:focus {
  border-color: #667eea;
  outline: none;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.modal-body-vertical textarea.form-input {
  resize: vertical;
  min-height: 80px;
}

/* 优化滚动条样式 */
.modal-body-vertical::-webkit-scrollbar {
  width: 10px;
}

.modal-body-vertical::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 5px;
}

.modal-body-vertical::-webkit-scrollbar-thumb {
  background: #888;
  border-radius: 5px;
}

.modal-body-vertical::-webkit-scrollbar-thumb:hover {
  background: #555;
}

/* 响应式调整 */
@media (max-width: 768px) {
  .modal-vertical-layout {
    width: 98%;
    max-width: none;
  }

  .modal-body-vertical {
    max-height: 65vh;
    padding: 16px;
  }
}

/* =====================================================
   期数管理UI样式 (从 issue_management.css 合并)
   版本: V3.0
   日期: 2025-12-26
   ===================================================== */

/* 页面容器 */
.issue-management-container {
  padding: 20px;
  max-width: 1400px;
  margin: 0 auto;
}

/* 页面标题区 */
.page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
  padding-bottom: 20px;
  border-bottom: 2px solid #e0e0e0;
}

.page-title {
  margin: 0;
  font-size: 28px;
  font-weight: 600;
  color: #2c3e50;
}

.page-subtitle {
  margin: 5px 0 0 0;
  font-size: 14px;
  color: #7f8c8d;
}

/* 表格容器 */
.table-container {
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  overflow: hidden;
}

/* 空状态 */
.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: #95a5a6;
}

.empty-state p:first-child {
  font-size: 48px;
  margin: 0 0 10px 0;
}

.text-muted {
  color: #95a5a6;
  font-size: 14px;
}

/* 进度条 */
.progress-bar-container {
  position: relative;
  width: 100%;
  height: 24px;
  background-color: #ecf0f1;
  border-radius: 12px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  background: linear-gradient(90deg, #3498db, #2ecc71);
  transition: width 0.3s ease;
  border-radius: 12px;
}

.progress-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 11px;
  font-weight: 600;
  color: #2c3e50;
  text-shadow: 0 0 3px rgba(255, 255, 255, 0.8);
}

/* 描述单元格 */
.description-cell {
  max-width: 200px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* 按钮组 */
.btn-group {
  display: flex;
  gap: 8px;
  justify-content: center;
}

.icon-btn.danger:hover {
  border-color: #e74c3c;
  background: #fee;
}

/* 徽章 */
.badge-info {
  background-color: #d6eaf8;
  color: #2471a3;
}

.badge-warning {
  background-color: #fef5e7;
  color: #d68910;
}

.badge-primary {
  background-color: #e8daef;
  color: #7d3c98;
}

.badge-success {
  background-color: #d5f4e6;
  color: #1e8449;
}

.badge-secondary {
  background-color: #e5e7e9;
  color: #5d6d7e;
}

/* 模态框 */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.modal-dialog {
  background: white;
  border-radius: 12px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
  width: 90%;
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto;
  animation: slideUp 0.3s ease;
}

@keyframes slideUp {
  from {
    transform: translateY(50px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.modal-header h3 {
  margin: 0;
  font-size: 20px;
  font-weight: 600;
  color: #2c3e50;
}

.form-label.required::after {
  content: ' *';
  color: #e74c3c;
}

.form-textarea {
  resize: vertical;
  min-height: 80px;
}

.form-hint {
  display: block;
  margin-top: 6px;
  font-size: 12px;
  color: #95a5a6;
}

.form-static {
  padding: 10px 0;
  font-size: 16px;
  font-weight: 600;
  color: #2c3e50;
}

/* 加载状态 */
.loading {
  text-align: center;
  padding: 60px 20px;
  font-size: 16px;
  color: #7f8c8d;
}

/* 响应式 */
@media (max-width: 768px) {
  .page-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
  }

  .modal-dialog {
    width: 95%;
    max-height: 95vh;
  }

  .btn-group {
    flex-wrap: wrap;
  }
}

/* =====================================================
   数据总览页面样式 - 统计卡片和任务卡片
   ===================================================== */

/* 总览容器 */
.overview-container {
  padding: 10px 0;
}

/* 统计卡片网格 */
.stats-grid {
  display: grid;
  gap: 20px;
  margin-bottom: 30px;
}

/* 统计卡片 */
.stat-card {
  border-radius: 16px;
  padding: 28px 24px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s, box-shadow 0.3s;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.stat-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.stat-icon {
  font-size: 42px;
  margin-bottom: 14px;
  line-height: 1;
}

.stat-label {
  font-size: 14px;
  opacity: 0.95;
  margin-bottom: 10px;
  font-weight: 500;
  letter-spacing: 0.3px;
}

.stat-number {
  font-size: 36px;
  font-weight: 800;
  line-height: 1;
}

/* 任务卡片 */
.task-card {
  display: flex;
  align-items: center;
  padding: 20px;
  background: white;
  border-radius: 14px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
  transition: all 0.3s;
  cursor: pointer;
}

.task-card:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
  transform: translateX(4px);
}

.task-icon {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  margin-right: 18px;
  flex-shrink: 0;
}

.task-info {
  flex: 1;
}

.task-label {
  font-size: 14px;
  color: #666;
  margin-bottom: 6px;
  font-weight: 500;
}

.task-count {
  font-size: 32px;
  font-weight: 800;
  color: var(--primary);
  line-height: 1;
}

/* 区域标题 */
.section-title {
  font-size: 20px;
  font-weight: 700;
  color: #2c3e50;
  margin: 28px 0 18px 0;
  padding-bottom: 10px;
  border-bottom: 2px solid #e9ecef;
}

/* 响应式调整 */
@media (max-width: 1200px) {
  .stats-grid[style*="repeat(4"] {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

@media (max-width: 768px) {
  .stats-grid[style*="repeat(4"],
  .stats-grid[style*="repeat(2"] {
    grid-template-columns: 1fr !important;
  }

  .stat-card {
    padding: 22px 18px;
  }

  .stat-icon {
    font-size: 36px;
  }

  .stat-number {
    font-size: 30px;
  }

  .task-card {
    padding: 16px;
  }

  .task-icon {
    width: 44px;
    height: 44px;
    font-size: 22px;
  }

  .task-count {
    font-size: 26px;
  }
}

/* =====================================================
   通校工作台 · 组稿目次详情页美化
   ===================================================== */

/* 栏目标题区域 */
.column-section {
  margin-bottom: 24px !important;
}

.column-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 16px !important;
  font-weight: 700 !important;
  color: #1e3a5f !important;
  padding: 10px 16px !important;
  margin-bottom: 0 !important;
  background: linear-gradient(90deg, #f0f7ff, #ffffff);
  border-left: 4px solid #3b82f6;
  border-bottom: none !important;
  border-radius: 8px 8px 0 0;
}

/* 栏目表格包裹 */
.column-section > .data-table {
  border-radius: 0 0 8px 8px;
  border: 1px solid #e2e8f0;
  overflow: hidden;
}

/* 表格在工作台中的优化 */
.collection-detail-page .data-table th {
  padding: 2px 4px;
  font-size: 13px;
  background: linear-gradient(to bottom, #f1f5f9, #e2e8f0);
  color: #334155;
  font-weight: 700;
  border-bottom: 1px solid #cbd5e1;
  letter-spacing: 0.3px;
}

.collection-detail-page .data-table td {
  padding: 2px 4px;
  font-size: 13px;
  border-bottom: 1px solid #eef2f6;
  color: #475569;
}

/* 交替行背景色 */
.collection-detail-page .data-table tbody tr:nth-child(even) {
  background: #fafbfc;
}

.collection-detail-page .data-table tbody tr:nth-child(even):hover {
  background: #f1f5f9;
}

/* hover 效果 */
.collection-detail-page .data-table tbody tr:hover {
  background: #f0f7ff;
  transition: background 0.15s ease;
}

/* 序号列居中 */
.collection-detail-page .data-table td:nth-child(2),
.collection-detail-page .data-table th:nth-child(2) {
  text-align: center;
  color: #94a3b8;
  font-weight: 600;
  font-size: 12px;
}

/* 页数列突出 */
.collection-detail-page .data-table td:nth-child(13),
.collection-detail-page .data-table th:nth-child(13) {
  text-align: center;
  font-weight: 700;
  color: #1e40af;
}

/* 下拉选择框美化 */
.collection-detail-page .data-table select {
  padding: 4px 8px;
  font-size: 12px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  background: #fff;
  color: #334155;
  cursor: pointer;
  outline: none;
  transition: all 0.15s;
  min-width: 90px;
}

.collection-detail-page .data-table select:hover {
  border-color: #3b82f6;
}

.collection-detail-page .data-table select:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 2px rgba(59,130,246,0.15);
}

/* 日期输入框美化 */
.collection-detail-page .data-table input[type="date"] {
  padding: 3px 6px;
  font-size: 11.5px;
  border: 1px solid #cbd5e1;
  border-radius: 5px;
  color: #475569;
}

/* 确认按钮美化 */
.collection-detail-page .data-table .btn {
  padding: 4px 12px;
  font-size: 12px;
  border-radius: 6px;
  font-weight: 600;
}

/* 复选框列 */
.collection-detail-page .data-table td:first-child,
.collection-detail-page .data-table th:first-child {
  text-align: center;
  width: 36px;
}

/* 操作列 */
.collection-detail-page .data-table td:last-child,
.collection-detail-page .data-table th:last-child {
  text-align: center;
}

/* 已分配状态标签（二校/三校人员已选时行左侧绿色竖条） */
.collection-detail-page .data-table tbody tr.assigned-row td:first-child {
  border-left: 3px solid #22c55e;
}

/* 栏目标题前的序号标识 */
.column-title::before {
  content: '';
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #3b82f6;
  flex-shrink: 0;
}

/* 本文编辑名字高亮 */
.collection-detail-page .data-table td:nth-child(8) {
  color: #7c3aed;
  font-weight: 600;
}

/* 栏目标题右对齐的篇数统计 */
.column-title .column-count {
  margin-left: auto;
  font-size: 12px;
  font-weight: 500;
  color: #64748b;
  background: #f1f5f9;
  padding: 2px 10px;
  border-radius: 12px;
}

/* 响应式：小屏幕下表格允许横向滚动 */
.collection-detail-page .card-body {
  overflow-x: auto;
  padding: 0;
}

.collection-detail-page .data-table {
  min-width: 1200px;
}

/* 工作台顶部标题栏 */
.collection-detail-page .card-header-with-search {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* 栏目区块间距 */
.collection-detail-page .column-section {
  margin-bottom: 20px !important;
}

/* 栏目标题 */
.collection-detail-page .column-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 15px !important;
  font-weight: 700 !important;
  color: #1e3a5f !important;
  padding: 10px 16px !important;
  margin-bottom: 0 !important;
  background: linear-gradient(90deg, #f0f7ff, #ffffff);
  border-left: 4px solid #3b82f6;
  border-bottom: none !important;
  border-radius: 8px 8px 0 0;
}

.collection-detail-page .column-title .column-count {
  margin-left: auto;
  font-size: 12px;
  font-weight: 500;
  color: #64748b;
  background: #f1f5f9;
  padding: 2px 10px;
  border-radius: 12px;
}

/* 栏目表格 */
.collection-detail-page .column-section > .data-table {
  border-radius: 0 0 8px 8px;
  border: 1px solid #e2e8f0;
  overflow: hidden;
  background: #fff;
}

/* 表格表头 */
.collection-detail-page .data-table th {
  padding: 2px 4px;
  font-size: 13px;
  background: linear-gradient(to bottom, #f1f5f9, #e2e8f0);
  color: #334155;
  font-weight: 700;
  border-bottom: 1px solid #cbd5e1;
  letter-spacing: 0.3px;
  white-space: nowrap;
}

/* 表格单元格 */
.collection-detail-page .data-table td {
  padding: 2px 4px;
  font-size: 13px;
  border-bottom: 1px solid #eef2f6;
  color: #475569;
  vertical-align: middle;
}

/* 交替行背景 */
.collection-detail-page .data-table tbody tr:nth-child(even) {
  background: #fafbfc;
}

/* hover 效果 */
.collection-detail-page .data-table tbody tr:hover {
  background: #f0f7ff;
  transition: background 0.15s ease;
}

.collection-detail-page .data-table tbody tr:nth-child(even):hover {
  background: #e8f0fe;
}

/* 序号列 */
.collection-detail-page .data-table td:nth-child(2),
.collection-detail-page .data-table th:nth-child(2) {
  text-align: center;
  color: #94a3b8;
  font-weight: 600;
  font-size: 12px;
}

/* 页数列 */
.collection-detail-page .data-table td:nth-child(12),
.collection-detail-page .data-table th:nth-child(12) {
  text-align: center;
  font-weight: 700;
  color: #1e40af;
}

/* 文题列：允许换行 */
.collection-detail-page .data-table td:nth-child(5) {
  max-width: 280px;
  line-height: 1.5;
  word-break: break-all;
}

/* 本文编辑列 */
.collection-detail-page .data-table td:nth-child(8) {
  color: #7c3aed;
  font-weight: 600;
}

/* 下拉选择框 */
.collection-detail-page .data-table select {
  padding: 4px 8px;
  font-size: 12px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  background: #fff;
  color: #334155;
  cursor: pointer;
  outline: none;
  transition: all 0.15s;
  min-width: 90px;
  max-width: 120px;
}

.collection-detail-page .data-table select:hover {
  border-color: #3b82f6;
}

.collection-detail-page .data-table select:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 2px rgba(59,130,246,0.15);
}

/* 日期输入框 */
.collection-detail-page .data-table input[type="date"] {
  padding: 3px 6px;
  font-size: 11.5px;
  border: 1px solid #cbd5e1;
  border-radius: 5px;
  color: #475569;
  max-width: 110px;
}

/* 确认按钮 */
.collection-detail-page .data-table .btn {
  padding: 4px 12px;
  font-size: 12px;
  border-radius: 6px;
  font-weight: 600;
}

/* 复选框列 */
.collection-detail-page .data-table td:first-child,
.collection-detail-page .data-table th:first-child {
  text-align: center;
  width: 36px;
}

/* 操作列 */
.collection-detail-page .data-table td:last-child,
.collection-detail-page .data-table th:last-child {
  text-align: center;
}

/* 栏目标题前的圆点 */
.collection-detail-page .column-title::before {
  content: '';
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #3b82f6;
  flex-shrink: 0;
}

.no-password-manager-mask {
  -webkit-text-security: disc;
  text-security: disc;
}

/* 责任校对工作台：桌面端整表可见，长文题增加行数而不是横向滚动。 */
.chief-proofread-detail-page .chief-proofread-table-wrap {
  width: 100%;
  overflow: visible;
  overflow-y: visible;
  border: 1px solid #e2e8f0;
  border-radius: 0 0 8px 8px;
  background: #fff;
}

.chief-proofread-detail-page .column-section > .chief-proofread-table-wrap {
  border-top: 0;
}

.chief-proofread-detail-page .chief-proofread-manuscript-table {
  width: 100% !important;
  min-width: 0 !important;
  max-width: 100% !important;
  table-layout: fixed !important;
}

.chief-proofread-detail-page .chief-proofread-manuscript-table th,
.chief-proofread-detail-page .chief-proofread-manuscript-table td {
  font-family: "Noto Sans SC", "Microsoft YaHei", system-ui, sans-serif;
  min-width: 0 !important;
  max-width: none !important;
  overflow: hidden;
  text-overflow: clip;
  vertical-align: middle;
  padding: 5px 8px;
  font-size: 13px;
  line-height: 1.2;
}

.chief-proofread-detail-page .chief-proofread-manuscript-table thead th {
  text-align: center !important;
  white-space: nowrap;
}

.chief-proofread-detail-page .chief-proofread-manuscript-table th:nth-child(1),
.chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(1) { width: 2%; }
.chief-proofread-detail-page .chief-proofread-manuscript-table th:nth-child(2),
.chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(2) { width: 2.5%; }
.chief-proofread-detail-page .chief-proofread-manuscript-table th:nth-child(3),
.chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(3) { width: 6.5%; }
.chief-proofread-detail-page .chief-proofread-manuscript-table th:nth-child(4),
.chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(4) { width: 5%; }
.chief-proofread-detail-page .chief-proofread-manuscript-table .chief-proofread-title-column,
.chief-proofread-detail-page .chief-proofread-manuscript-table .chief-proofread-title-cell {
  width: 23% !important;
}
.chief-proofread-detail-page .chief-proofread-manuscript-table th:nth-child(6),
.chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(6) { width: 5%; }
.chief-proofread-detail-page .chief-proofread-manuscript-table th:nth-child(7),
.chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(7) { width: 3.5%; }
.chief-proofread-detail-page .chief-proofread-manuscript-table th:nth-child(8),
.chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(8) { width: 5%; }
.chief-proofread-detail-page .chief-proofread-manuscript-table th:nth-child(9),
.chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(9),
.chief-proofread-detail-page .chief-proofread-manuscript-table th:nth-child(11),
.chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(11) { width: 9%; }
.chief-proofread-detail-page .chief-proofread-manuscript-table th:nth-child(10),
.chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(10),
.chief-proofread-detail-page .chief-proofread-manuscript-table th:nth-child(12),
.chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(12) { width: 9%; }
.chief-proofread-detail-page .chief-proofread-manuscript-table th:nth-child(13),
.chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(13) { width: 3%; }
.chief-proofread-detail-page .chief-proofread-manuscript-table th:nth-child(14),
.chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(14) { width: 9%; }

.chief-proofread-detail-page .chief-proofread-title-cell {
  white-space: normal !important;
  word-break: normal !important;
  overflow-wrap: break-word !important;
  line-height: 1.45;
}

.chief-proofread-detail-page .chief-proofread-manuscript-table select,
.chief-proofread-detail-page .chief-proofread-manuscript-table input[type="date"] {
  width: 100% !important;
  min-width: 0 !important;
  max-width: 100% !important;
  box-sizing: border-box;
}

.chief-proofread-detail-page .chief-proofread-manuscript-table td:last-child > div > div {
  gap: 3px !important;
}

.chief-proofread-detail-page .chief-proofread-manuscript-table td:last-child .btn {
  min-width: 0 !important;
  padding: 4px 3px !important;
  font-size: 11px !important;
  white-space: nowrap;
}

/* Mac Edge/Safari 的原生控件和字体占宽较大，匹配用户手动调到 90% 时的布局密度。 */
@media (min-width: 761px) and (hover: hover) and (pointer: fine) {
  html.is-macos .chief-proofread-detail-page {
    width: 111.111%;
    transform: scale(0.9);
    transform-origin: top left;
  }

  html.is-macos .chief-proofread-detail-page .chief-proofread-manuscript-table th,
  html.is-macos .chief-proofread-detail-page .chief-proofread-manuscript-table td {
    font-size: 14px;
  }

  html.is-macos .chief-proofread-detail-page .chief-proofread-manuscript-table td:last-child .btn {
    padding: 5px 6px !important;
    font-size: 12px !important;
  }
}

/*
 * 不用宽度单独判断，避免 Mac 浏览器缩放后被误判为手机。
 * 仅无鼠标悬停能力的触摸设备采用卡片布局。
 */
@media (max-width: 760px) and (hover: none) and (pointer: coarse) {
  .chief-proofread-detail-page .card-body {
    overflow-x: visible !important;
  }

  .chief-proofread-detail-page .chief-proofread-table-wrap,
  .chief-proofread-detail-page .chief-proofread-manuscript-table,
  .chief-proofread-detail-page .chief-proofread-manuscript-table tbody {
    display: block;
    width: 100% !important;
    max-width: 100% !important;
  }

  .chief-proofread-detail-page .chief-proofread-manuscript-table thead {
    display: none;
  }

  .chief-proofread-detail-page .chief-proofread-manuscript-table tbody > tr:not(.manuscript-status-row) {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0;
    margin-top: 10px;
    border: 1px solid #dbe3ef;
    border-radius: 8px 8px 0 0;
    overflow: hidden;
  }

  .chief-proofread-detail-page .chief-proofread-manuscript-table tbody > tr:not(.manuscript-status-row) > td {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    padding: 8px 10px;
    border: 0;
    border-right: 1px solid #edf1f6;
    border-bottom: 1px solid #edf1f6;
    overflow: visible;
    text-align: left !important;
  }

  .chief-proofread-detail-page .chief-proofread-manuscript-table tbody > tr:not(.manuscript-status-row) > td::before {
    margin-bottom: 3px;
    color: #64748b;
    font-size: 11px;
    font-weight: 700;
  }

  .chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(1)::before { content: "选择"; }
  .chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(2)::before { content: "序号"; }
  .chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(3)::before { content: "稿号"; }
  .chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(4)::before { content: "第一作者"; }
  .chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(5)::before { content: "文题"; }
  .chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(6)::before { content: "基金情况"; }
  .chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(7)::before { content: "地域"; }
  .chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(8)::before { content: "本文编辑"; }
  .chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(9)::before { content: "二校人员"; }
  .chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(10)::before { content: "二校截止"; }
  .chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(11)::before { content: "三校人员"; }
  .chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(12)::before { content: "三校截止"; }
  .chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(13)::before { content: "页数"; }
  .chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(14)::before { content: "操作"; }

  .chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(5),
  .chief-proofread-detail-page .chief-proofread-manuscript-table td:nth-child(14) {
    grid-column: 1 / -1;
  }

  .chief-proofread-detail-page .chief-proofread-manuscript-table .manuscript-status-row {
    display: block;
    margin: 0 0 10px;
    border: 1px solid #dbe3ef;
    border-top: 0;
    border-radius: 0 0 8px 8px;
  }

  .chief-proofread-detail-page .chief-proofread-manuscript-table .manuscript-status-row td {
    display: block;
    width: auto !important;
    padding: 8px !important;
    border: 0 !important;
  }

  .chief-proofread-detail-page .chief-proofread-manuscript-table .manuscript-status-row td::before {
    content: none;
  }
}

/* =====================================================
   个人待办侧栏
===================================================== */
.todo-sidebar-root {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1600;
}

.todo-sidebar-root button,
.todo-sidebar-root input,
.todo-sidebar-root textarea,
.todo-sidebar-root select {
  font-family: inherit;
}

.todo-sidebar-root svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.todo-sidebar-bubble {
  position: fixed;
  width: 54px;
  height: 54px;
  border: 1px solid rgba(139, 21, 56, 0.18);
  border-radius: 50%;
  background: #ffffff;
  color: var(--primary);
  box-shadow: 0 16px 36px rgba(15, 23, 42, 0.18);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: grab;
  pointer-events: auto;
  touch-action: none;
  transition: width 0.18s ease, height 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.todo-sidebar-bubble:hover {
  border-color: rgba(139, 21, 56, 0.42);
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.24);
  transform: translateY(-1px);
}

.todo-sidebar-bubble:focus-visible,
.todo-icon-btn:focus-visible,
.todo-primary-btn:focus-visible,
.todo-header-add-btn:focus-visible,
.todo-secondary-btn:focus-visible,
.todo-mini-btn:focus-visible,
.todo-task-action:focus-visible,
.todo-sidebar-tab:focus-visible,
.todo-calendar-cell:focus-visible {
  outline: 3px solid rgba(139, 21, 56, 0.24);
  outline-offset: 2px;
}

.todo-sidebar-bubble.is-dragging {
  cursor: grabbing;
  transform: scale(1.03);
}

.todo-sidebar-bubble-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.todo-sidebar-bubble-label {
  display: none;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
}

.todo-sidebar-bubble.is-top-docked {
  width: 132px;
  height: 34px;
  border-radius: 0 0 10px 10px;
  border-color: rgba(139, 21, 56, 0.92);
  background: #8b1538;
  color: #ffffff;
  gap: 7px;
  box-shadow: 0 10px 24px rgba(139, 21, 56, 0.28);
  transform: translateY(-2px);
}

.todo-sidebar-bubble.is-top-docked:hover {
  border-color: rgba(139, 21, 56, 1);
  background: #9d1741;
  box-shadow: 0 14px 30px rgba(139, 21, 56, 0.34);
  transform: translateY(0);
}

.todo-sidebar-bubble.is-top-docked .todo-sidebar-bubble-label {
  display: inline-flex;
}

.todo-sidebar-bubble.is-top-docked .todo-sidebar-bubble-badge {
  position: static;
  min-width: 22px;
  height: 20px;
  padding: 0 6px;
  border-color: rgba(255, 255, 255, 0.95);
  background: #ffffff;
  color: #8b1538;
  line-height: 16px;
}

.todo-sidebar-bubble-badge {
  position: absolute;
  top: -7px;
  right: -7px;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: 999px;
  background: #dc2626;
  color: #fff;
  border: 2px solid #fff;
  font-size: 11px;
  line-height: 18px;
  font-weight: 800;
  text-align: center;
}

.todo-sidebar-panel {
  position: fixed;
  top: 88px;
  bottom: 18px;
  width: min(488px, calc(100vw - 24px));
  max-width: calc(100vw - 24px);
  max-height: calc(100vh - 24px);
  pointer-events: auto;
  background: #fff;
  border: 1px solid #eadfe4;
  border-radius: 8px;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.24);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: translateX(0);
  animation: todoPanelIn 0.2s ease-out;
}

.todo-sidebar-panel.is-form-mode .todo-sidebar-header,
.todo-sidebar-panel.is-form-mode .todo-sidebar-summary,
.todo-sidebar-panel.is-form-mode .todo-sidebar-tabs {
  display: none;
}

.todo-sidebar-panel.is-form-mode .todo-sidebar-content {
  padding: 10px;
  background: #fff;
}

.todo-sidebar-panel.is-right {
  right: 16px;
}

.todo-sidebar-panel.is-left {
  left: 16px;
}

.todo-sidebar-panel.is-top {
  width: min(456px, calc(100vw - 24px));
  right: auto;
}

.todo-sidebar-panel.is-resizing {
  user-select: none;
}

body.todo-sidebar-is-resizing {
  user-select: none;
}

.todo-sidebar-resize-handle {
  position: absolute;
  right: 0;
  bottom: 0;
  z-index: 4;
  width: 26px;
  height: 26px;
  padding: 0;
  border: 0;
  border-radius: 8px 0 8px 0;
  background: linear-gradient(135deg, transparent 0 44%, rgba(15, 118, 110, 0.08) 45% 100%);
  color: #64748b;
  cursor: nwse-resize;
  touch-action: none;
}

.todo-sidebar-resize-handle::before,
.todo-sidebar-resize-handle::after {
  content: "";
  position: absolute;
  right: 6px;
  bottom: 6px;
  width: 9px;
  height: 9px;
  border-right: 2px solid #94a3b8;
  border-bottom: 2px solid #94a3b8;
  border-radius: 1px;
}

.todo-sidebar-resize-handle::after {
  right: 11px;
  bottom: 11px;
  width: 4px;
  height: 4px;
  opacity: 0.75;
}

.todo-sidebar-resize-handle:hover {
  background: linear-gradient(135deg, transparent 0 40%, rgba(15, 118, 110, 0.16) 41% 100%);
}

.todo-sidebar-panel.is-right .todo-sidebar-resize-handle {
  left: 0;
  right: auto;
  border-radius: 0 8px 0 8px;
  cursor: nesw-resize;
  transform: scaleX(-1);
}

@keyframes todoPanelIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.todo-sidebar-header {
  min-height: 76px;
  padding: 16px 16px 12px;
  border-bottom: 1px solid #f0e4e8;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  background: linear-gradient(180deg, #fff 0%, #fff8fa 100%);
}

.todo-sidebar-header-main {
  min-width: 0;
  flex: 1;
}

.todo-sidebar-heading-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}

.todo-sidebar-kicker {
  font-size: 12px;
  color: #8b1538;
  font-weight: 700;
}

.todo-form-header .todo-sidebar-kicker,
.todo-agenda-header .todo-sidebar-kicker {
  margin-bottom: 4px;
}

.todo-sidebar-header h2,
.todo-form-header h3,
.todo-agenda-header h3 {
  margin: 0;
  color: #111827;
  font-size: 18px;
  line-height: 1.25;
  font-weight: 800;
  letter-spacing: 0;
}

.todo-sidebar-header-actions,
.todo-task-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.todo-header-add-btn {
  min-height: 34px;
  border: 1px solid rgba(139, 21, 56, 0.16);
  border-radius: 8px;
  background: #8b1538;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 900;
  line-height: 1;
  cursor: pointer;
  white-space: nowrap;
  box-shadow: 0 8px 18px rgba(139, 21, 56, 0.18);
  transition: background 0.18s ease, border-color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.todo-header-add-btn:hover {
  background: #6f102c;
  border-color: rgba(111, 16, 44, 0.9);
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(139, 21, 56, 0.24);
}

.todo-header-add-btn svg {
  width: 15px;
  height: 15px;
}

.todo-icon-btn,
.todo-mini-btn,
.todo-task-action {
  min-width: 44px;
  min-height: 44px;
  border: 1px solid #eadfe4;
  border-radius: 8px;
  background: #fff;
  color: #475569;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.todo-icon-btn:hover,
.todo-mini-btn:hover,
.todo-task-action:hover {
  background: #fff1f4;
  border-color: #e8b9c4;
  color: var(--primary);
}

.todo-mini-btn {
  min-width: 38px;
  min-height: 38px;
}

.todo-mini-btn.danger:hover {
  background: #fef2f2;
  border-color: #fecaca;
  color: #dc2626;
}

.todo-sidebar-summary {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  padding: 12px 14px;
  border-bottom: 1px solid #f0e4e8;
  background: #fff;
}

.todo-summary-item {
  min-height: 58px;
  border: 1px solid #f1e4e8;
  border-radius: 8px;
  background: #fffafa;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 4px;
}

.todo-summary-item span {
  color: #8b1538;
  font-size: 22px;
  line-height: 1;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.todo-summary-item label {
  color: #64748b;
  font-size: 12px;
  line-height: 1.2;
}

.todo-sidebar-tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  padding: 10px 14px 0;
  background: #fff;
}

.todo-sidebar-tab {
  min-height: 40px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #f8fafc;
  color: #475569;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}

.todo-sidebar-tab:hover {
  border-color: #e8b9c4;
  color: #8b1538;
}

.todo-sidebar-tab.is-active {
  background: #8b1538;
  border-color: #8b1538;
  color: #fff;
}

.todo-sidebar-content {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 14px 14px 16px;
  background: #f8fafc;
  scrollbar-gutter: stable;
}

.todo-sidebar-content::-webkit-scrollbar {
  width: 9px;
}

.todo-sidebar-content::-webkit-scrollbar-track {
  background: #eef2f7;
}

.todo-sidebar-content::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 999px;
}

.todo-sidebar-toolbar,
.todo-form-actions,
.todo-agenda-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.todo-sidebar-toolbar {
  margin-bottom: 14px;
}

.todo-sidebar-status-row {
  min-height: 0;
  justify-content: flex-end;
  margin-bottom: 8px;
}

.todo-primary-btn,
.todo-secondary-btn {
  min-height: 44px;
  border-radius: 8px;
  border: 1px solid transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 14px;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.todo-primary-btn {
  background: #8b1538;
  color: #fff;
  border-color: #8b1538;
}

.todo-primary-btn:hover {
  background: #6f102c;
  border-color: #6f102c;
}

.todo-secondary-btn {
  background: #fff;
  color: #475569;
  border-color: #dbe3ee;
}

.todo-secondary-btn:hover {
  background: #f8fafc;
  color: #0f172a;
}

.todo-sidebar-status {
  min-width: 0;
  color: #64748b;
  font-size: 12px;
  line-height: 1.3;
  text-align: right;
}

.todo-sidebar-status:empty {
  display: none;
}

.todo-sidebar-section {
  margin-bottom: 16px;
}

.todo-section-title {
  margin: 0 0 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: #334155;
  font-size: 13px;
  font-weight: 900;
}

.todo-section-title span {
  min-width: 24px;
  height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  background: #e9f5f2;
  color: #047857;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}

.todo-auto-card-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.todo-auto-card {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  min-height: 168px;
  border: 1px solid #e6edf4;
  border-top: 4px solid #0f766e;
  border-radius: 8px;
  background: #fff;
  color: #0f172a;
  padding: 12px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: space-between;
  gap: 8px;
  text-align: left;
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.05);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}

.todo-auto-card:hover {
  transform: translateY(-2px);
  border-color: #e8b9c4;
  background: #fffafa;
  box-shadow: 0 14px 28px rgba(15, 23, 42, 0.1);
}

.todo-auto-card:focus-visible {
  outline: 3px solid rgba(139, 21, 56, 0.24);
  outline-offset: 2px;
}

.todo-auto-card.priority-low {
  border-top-color: #94a3b8;
}

.todo-auto-card.priority-normal {
  border-top-color: #0f766e;
}

.todo-auto-card.priority-high {
  border-top-color: #b45309;
}

.todo-auto-card.priority-urgent {
  border-top-color: #dc2626;
}

.todo-auto-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}

.todo-auto-card-head strong {
  min-width: 0;
  color: #0f172a;
  font-size: 14px;
  line-height: 1.3;
  font-weight: 900;
  word-break: break-word;
}

.todo-auto-card-head em {
  flex: 0 0 auto;
  min-height: 24px;
  padding: 0 7px;
  border-radius: 999px;
  background: #f1f5f9;
  color: #64748b;
  font-size: 11px;
  line-height: 24px;
  font-style: normal;
  font-weight: 800;
}

.todo-auto-card-count {
  color: #8b1538;
  font-size: 34px;
  line-height: 0.9;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.todo-auto-card-meta {
  display: grid;
  gap: 4px;
}

.todo-auto-card-meta span {
  min-width: 0;
  color: #475569;
  font-size: 12px;
  line-height: 1.25;
  font-weight: 700;
}

.todo-auto-card-samples {
  display: grid;
  gap: 3px;
}

.todo-auto-card-samples span {
  min-width: 0;
  color: #64748b;
  font-size: 11px;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.todo-auto-detail {
  display: grid;
  gap: 12px;
}

.todo-auto-detail-head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  padding: 2px 0 4px;
}

.todo-auto-detail-head h3 {
  margin: 2px 0 0;
  color: #0f172a;
  font-size: 18px;
  line-height: 1.25;
  font-weight: 900;
  letter-spacing: 0;
}

.todo-back-btn {
  min-height: 38px;
  padding: 0 10px;
  gap: 4px;
}

.todo-back-btn svg {
  width: 16px;
  height: 16px;
}

.todo-auto-detail-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.todo-auto-detail-summary span {
  min-width: 0;
  min-height: 54px;
  padding: 9px 8px;
  border: 1px solid #e6edf4;
  border-radius: 8px;
  background: #fff;
  color: #475569;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 12px;
  line-height: 1.3;
  font-weight: 800;
  word-break: break-word;
}

.todo-auto-detail-summary strong {
  color: #8b1538;
  font-size: 20px;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.todo-task-list {
  display: grid;
  gap: 8px;
}

.todo-task-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 11px 10px;
  border: 1px solid #e6edf4;
  border-left: 4px solid #94a3b8;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.05);
}

.todo-task-item.priority-low {
  border-left-color: #94a3b8;
}

.todo-task-item.priority-normal {
  border-left-color: #0f766e;
}

.todo-task-item.priority-high {
  border-left-color: #b45309;
}

.todo-task-item.priority-urgent {
  border-left-color: #dc2626;
}

.todo-task-item.is-completed {
  opacity: 0.72;
}

.todo-task-item.is-completed h3 {
  text-decoration: line-through;
}

.todo-task-main {
  min-width: 0;
}

.todo-task-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-bottom: 6px;
}

.todo-task-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 7px;
  border-radius: 999px;
  background: #f1f5f9;
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
}

.todo-task-item h3 {
  margin: 0;
  color: #0f172a;
  font-size: 14px;
  line-height: 1.35;
  font-weight: 800;
  letter-spacing: 0;
  word-break: break-word;
}

.todo-task-item p {
  margin: 6px 0 0;
  color: #64748b;
  font-size: 12px;
  line-height: 1.5;
  word-break: break-word;
}

.todo-task-action svg {
  width: 17px;
  height: 17px;
}

.todo-task-action {
  gap: 4px;
  padding: 0 10px;
  color: #8b1538;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.todo-task-action span {
  line-height: 1;
}

.todo-sidebar-empty,
.todo-sidebar-loading {
  padding: 18px;
  border: 1px dashed #cbd5e1;
  border-radius: 8px;
  background: #fff;
  color: #64748b;
  font-size: 13px;
  line-height: 1.6;
  text-align: center;
}

.todo-sidebar-empty strong {
  display: block;
  margin-bottom: 6px;
  color: #0f172a;
  font-size: 14px;
}

.todo-sidebar-empty p {
  margin: 0 0 12px;
}

.todo-sidebar-empty.is-compact {
  padding: 12px;
  text-align: left;
}

.todo-form {
  display: grid;
  align-content: start;
  gap: 10px;
  border: 1px solid #e6edf4;
  border-radius: 8px;
  background: #fff;
  padding: 12px;
}

.todo-sidebar-panel.is-form-mode .todo-form {
  min-height: 100%;
  border-color: #edf2f7;
  padding: 16px;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.05);
}

.todo-form-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid #edf2f7;
}

.todo-form-close-btn {
  width: 44px;
  height: 44px;
  flex: 0 0 auto;
  border: 1px solid #eadfe4;
  border-radius: 8px;
  background: #fff;
  color: #475569;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.todo-form-close-btn:hover {
  background: #fff1f4;
  border-color: #e8b9c4;
  color: #8b1538;
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(139, 21, 56, 0.12);
}

.todo-form-close-btn svg {
  width: 20px;
  height: 20px;
}

.todo-field {
  display: grid;
  gap: 6px;
}

.todo-field span,
.todo-check-field span {
  color: #334155;
  font-size: 13px;
  font-weight: 800;
}

.todo-field input,
.todo-field textarea,
.todo-field select {
  width: 100%;
  min-height: 44px;
  border: 1px solid #dbe3ee;
  border-radius: 8px;
  background: #fff;
  color: #0f172a;
  padding: 10px 12px;
  font-size: 14px;
  line-height: 1.4;
}

.todo-field textarea {
  min-height: 68px;
  resize: vertical;
}

.todo-field input:focus,
.todo-field textarea:focus,
.todo-field select:focus {
  outline: none;
  border-color: #8b1538;
  box-shadow: 0 0 0 3px rgba(139, 21, 56, 0.12);
}

.todo-category-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}

.todo-category-input-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.todo-category-save-btn {
  min-height: 44px;
  padding: 0 12px;
  white-space: nowrap;
}

.todo-category-chip {
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid #e6edf4;
  border-radius: 999px;
  background: #f8fafc;
  color: #475569;
  font-size: 12px;
  line-height: 1;
  font-weight: 800;
  cursor: pointer;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.todo-category-chip:hover,
.todo-category-chip:focus-visible {
  border-color: #e8b9c4;
  background: #fff1f4;
  color: #8b1538;
  transform: translateY(-1px);
}

.todo-form-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.todo-schedule-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 10px;
  border: 1px solid #e6edf4;
  border-radius: 8px;
  background: #f8fafc;
}

.todo-schedule-grid .todo-field {
  min-width: 0;
}

.todo-schedule-grid .todo-field span {
  color: #475569;
  font-size: 12px;
  line-height: 1.2;
}

.todo-schedule-grid .todo-field input,
.todo-schedule-grid .todo-field select {
  min-height: 48px;
  background: #fff;
  box-shadow: 0 1px 0 rgba(15, 23, 42, 0.02);
}

.todo-schedule-grid .todo-date-field input[type="date"] {
  font-size: 13px;
  font-variant-numeric: tabular-nums;
  padding-left: 10px;
  padding-right: 8px;
}

.todo-schedule-grid .todo-priority-field {
  grid-column: 1 / -1;
  width: min(220px, 100%);
}

.todo-schedule-grid .todo-priority-field select {
  font-weight: 700;
}

.todo-check-field {
  min-height: 44px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid #e6edf4;
  border-radius: 8px;
  background: #f8fafc;
}

.todo-check-field input {
  width: 18px;
  height: 18px;
  accent-color: #8b1538;
}

.todo-form-note {
  color: #64748b;
  font-size: 12px;
  line-height: 1.5;
  padding: 8px 10px;
  border-radius: 8px;
  background: #fff7ed;
  border: 1px solid #fed7aa;
}

.todo-notes-view {
  display: grid;
  gap: 12px;
}

.todo-notes-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border: 1px solid #e6edf4;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.05);
}

.todo-notes-head h3 {
  margin: 2px 0 0;
  color: #0f172a;
  font-size: 18px;
  line-height: 1.2;
  font-weight: 900;
  letter-spacing: 0;
}

.todo-notes-head p {
  margin: 5px 0 0;
  color: #64748b;
  font-size: 12px;
  line-height: 1.35;
}

.todo-note-save-status {
  min-height: 34px;
  padding: 8px 10px;
  border: 1px solid #bbf7d0;
  border-radius: 8px;
  background: #f0fdf4;
  color: #047857;
  font-size: 13px;
  line-height: 1.25;
  font-weight: 900;
}

.todo-note-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.todo-note-card,
.todo-note-detail,
.todo-floating-note,
.todo-note-color-choice {
  --note-accent: #be123c;
  --note-bg: #fff7f9;
  --note-soft: #ffe4ea;
}

.todo-note-card.color-mint,
.todo-note-detail.color-mint,
.todo-floating-note.color-mint,
.todo-note-color-choice.color-mint {
  --note-accent: #047857;
  --note-bg: #f0fdfa;
  --note-soft: #ccfbf1;
}

.todo-note-card.color-amber,
.todo-note-detail.color-amber,
.todo-floating-note.color-amber,
.todo-note-color-choice.color-amber {
  --note-accent: #b45309;
  --note-bg: #fffbeb;
  --note-soft: #fef3c7;
}

.todo-note-card.color-sky,
.todo-note-detail.color-sky,
.todo-floating-note.color-sky,
.todo-note-color-choice.color-sky {
  --note-accent: #2563eb;
  --note-bg: #eff6ff;
  --note-soft: #dbeafe;
}

.todo-note-card {
  min-width: 0;
  border: 1px solid #e6edf4;
  border-top: 4px solid var(--note-accent);
  border-radius: 8px;
  background: var(--note-bg);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.06);
  overflow: hidden;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.todo-note-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 28px rgba(15, 23, 42, 0.11);
}

.todo-note-open {
  width: 100%;
  min-height: 132px;
  padding: 11px 11px 8px;
  border: 0;
  background: transparent;
  color: inherit;
  display: grid;
  gap: 8px;
  text-align: left;
  cursor: pointer;
}

.todo-note-card-top,
.todo-note-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.todo-note-card-icon {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: var(--note-soft);
  color: var(--note-accent);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.todo-note-card-icon svg {
  width: 17px;
  height: 17px;
}

.todo-note-card em {
  min-height: 22px;
  padding: 0 7px;
  border-radius: 999px;
  background: #fff;
  color: var(--note-accent);
  font-size: 11px;
  line-height: 22px;
  font-style: normal;
  font-weight: 900;
}

.todo-note-card strong {
  min-width: 0;
  color: #0f172a;
  font-size: 14px;
  line-height: 1.3;
  font-weight: 900;
  word-break: break-word;
}

.todo-note-preview {
  min-height: 38px;
  color: #475569;
  font-size: 12px;
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  word-break: break-word;
}

.todo-note-card-foot {
  color: #64748b;
  font-size: 11px;
  font-weight: 800;
}

.todo-note-card-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  padding: 0 9px 9px;
}

.todo-note-detail {
  display: grid;
  gap: 12px;
  border: 1px solid #e6edf4;
  border-top: 4px solid var(--note-accent);
  border-radius: 8px;
  background: #fff;
  padding: 12px;
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.06);
}

.todo-note-detail-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.todo-note-detail-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.todo-note-float-btn.is-active {
  border-color: var(--note-accent);
  background: var(--note-bg);
  color: var(--note-accent);
}

.todo-note-delete-btn:hover {
  border-color: #fecaca;
  background: #fef2f2;
  color: #dc2626;
}

.todo-note-detail textarea {
  min-height: 180px;
}

.todo-note-color-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.todo-note-color-choice {
  position: relative;
  min-height: 38px;
  border: 1px solid #e6edf4;
  border-radius: 8px;
  background: var(--note-bg);
  color: #334155;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.todo-note-color-choice::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--note-accent);
}

.todo-note-color-choice input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.todo-note-color-choice.is-selected,
.todo-note-color-choice:has(input:checked) {
  border-color: var(--note-accent);
  box-shadow: 0 0 0 3px rgba(139, 21, 56, 0.12);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--note-accent) 14%, transparent);
}

.todo-floating-notes {
  position: fixed;
  inset: 0;
  width: auto;
  pointer-events: none;
  z-index: 1602;
}

.todo-floating-notes.hidden {
  display: none;
}

.todo-floating-note {
  position: fixed;
  width: min(320px, calc(100vw - 44px));
  pointer-events: auto;
  border: 1px solid #e6edf4;
  border: 1px solid color-mix(in srgb, var(--note-accent) 28%, #e6edf4);
  border-left: 5px solid var(--note-accent);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 18px 44px rgba(15, 23, 42, 0.18);
  overflow: hidden;
  cursor: grab;
  touch-action: none;
  user-select: none;
}

.todo-floating-note.is-dragging {
  cursor: grabbing;
  opacity: 0.96;
  box-shadow: 0 24px 56px rgba(15, 23, 42, 0.24);
  transition: none;
}

.todo-floating-note-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 36px;
  align-items: center;
  gap: 6px;
  padding: 8px 8px 0 10px;
}

.todo-floating-note-title,
.todo-floating-note-body,
.todo-floating-note-close {
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font: inherit;
}

.todo-floating-note-title {
  min-width: 0;
  color: #0f172a;
  font-size: 13px;
  line-height: 1.25;
  font-weight: 900;
  text-align: left;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  cursor: inherit;
}

.todo-floating-note-close {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  color: #64748b;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.todo-floating-note-close:hover {
  background: #f1f5f9;
  color: #8b1538;
}

.todo-floating-note-body {
  width: 100%;
  padding: 6px 10px 10px;
  color: #475569;
  font-size: 12px;
  line-height: 1.45;
  text-align: left;
  word-break: break-word;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  cursor: inherit;
}

.todo-calendar-now-card {
  min-height: 96px;
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px;
  margin-bottom: 10px;
  border: 1px solid #e6edf4;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.05);
}

.todo-calendar-clock {
  color: #172033;
  font-size: 34px;
  line-height: 1;
  font-weight: 900;
  letter-spacing: 0;
  font-variant-numeric: tabular-nums;
}

.todo-calendar-today-line {
  margin-top: 8px;
  color: #475569;
  font-size: 13px;
  line-height: 1.35;
  font-weight: 700;
}

.todo-calendar-weather-mark {
  flex: 0 0 auto;
  min-width: 58px;
  display: grid;
  justify-items: center;
  gap: 5px;
  color: #f59e0b;
}

.todo-calendar-weather-mark svg {
  width: 36px;
  height: 36px;
  stroke-width: 2.4;
}

.todo-calendar-weather-mark span {
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
}

.todo-calendar-head {
  min-height: 42px;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto 38px;
  align-items: center;
  gap: 6px;
  padding: 0 2px 4px;
  margin-bottom: 8px;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.todo-calendar-head strong {
  min-width: 0;
  color: #0f172a;
  font-size: 18px;
  font-weight: 900;
  text-align: center;
}

.todo-today-btn {
  min-height: 32px;
  padding: 0 10px;
  font-size: 12px;
}

.todo-calendar-focus {
  display: flex;
  flex-wrap: nowrap;
  gap: 6px;
  min-width: 0;
  min-height: 26px;
  margin-bottom: 8px;
  padding: 1px 2px 3px;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
}

.todo-calendar-focus::-webkit-scrollbar {
  display: none;
}

.todo-event-chip {
  flex: 0 0 auto;
  max-width: 118px;
  min-width: 0;
  min-height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 9px;
  border-radius: 999px;
  background: #e0f2fe;
  color: #0369a1;
  font-size: 11px;
  line-height: 1.2;
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  box-sizing: border-box;
}

.todo-event-chip.health,
.todo-event-chip.medical {
  background: #e9f5f2;
  color: #047857;
}

.todo-calendar-weekdays,
.todo-calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 3px 6px;
}

.todo-calendar-weekdays {
  margin-bottom: 4px;
}

.todo-calendar-weekdays span {
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}

.todo-calendar-grid {
  margin-bottom: 12px;
  overflow: visible;
  align-items: stretch;
}

.todo-calendar-cell {
  position: relative;
  min-height: 58px;
  height: 58px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #334155;
  display: grid;
  grid-template-rows: 27px 15px 12px;
  align-content: center;
  gap: 1px;
  padding: 3px 3px 2px;
  min-width: 0;
  overflow: visible;
  cursor: pointer;
  font-weight: 800;
  transition: background 0.18s ease, color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.todo-calendar-cell.is-muted {
  background: transparent;
  pointer-events: none;
}

.todo-calendar-cell:hover {
  color: #0f766e;
  background: #f1f5f9;
}

.todo-calendar-cell.is-today {
  width: 58px;
  max-width: 100%;
  justify-self: center;
  background: #eef2f7;
  box-shadow: none;
}

.todo-calendar-cell.is-selected {
  width: 58px;
  max-width: 100%;
  justify-self: center;
  background: #3b82f6;
  color: #fff;
  box-shadow: 0 10px 20px rgba(59, 130, 246, 0.22);
}

.todo-calendar-cell.is-rest .todo-calendar-day,
.todo-calendar-cell.has-statutory .todo-calendar-day,
.todo-calendar-cell.is-weekend:not(.is-workday) .todo-calendar-day {
  color: #ef4444;
}

.todo-calendar-cell.is-workday .todo-calendar-day {
  color: #475569;
}

.todo-calendar-cell.is-selected .todo-calendar-day,
.todo-calendar-cell.is-selected .todo-calendar-lunar,
.todo-calendar-cell.is-selected .todo-calendar-lunar[class*="event-"] {
  color: #fff;
}

.todo-calendar-day-row {
  min-height: 27px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 0;
  min-width: 0;
}

.todo-calendar-day {
  width: auto;
  height: 27px;
  border-radius: 50%;
  color: #0f172a;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  line-height: 1;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.todo-calendar-cell.is-selected .todo-calendar-day {
  background: transparent;
  color: #fff;
}

.todo-calendar-rest-badge,
.todo-calendar-work-badge {
  position: absolute;
  top: 2px;
  right: 4px;
  z-index: 1;
  min-width: 16px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 9px;
  line-height: 1;
  font-weight: 900;
  pointer-events: none;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.12);
}

.todo-calendar-rest-badge {
  background: #dbeafe;
  color: #2563eb;
}

.todo-calendar-work-badge {
  background: #fef3c7;
  color: #b45309;
}

.todo-calendar-lunar {
  min-width: 0;
  width: 100%;
  box-sizing: border-box;
  min-height: 16px;
  height: 16px;
  padding: 0 1px;
  color: #475569;
  font-size: 10px;
  line-height: 16px;
  font-weight: 800;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  word-break: keep-all;
  display: block;
  align-self: center;
  justify-self: center;
  letter-spacing: 0;
}

.todo-calendar-lunar[class*="event-"] {
  border-radius: 0;
  background: transparent;
  color: #334155;
}

.todo-calendar-lunar.event-statutory,
.todo-calendar-lunar.event-traditional {
  background: transparent;
  color: #1d4ed8;
}

.todo-calendar-lunar.event-health,
.todo-calendar-lunar.event-medical {
  background: transparent;
  color: #047857;
}

.todo-calendar-lunar.event-solar-term {
  background: transparent;
  color: #0f766e;
}

.todo-calendar-cell.is-selected .todo-calendar-lunar[class*="event-"] {
  background: transparent;
}

.todo-calendar-mark-row {
  min-height: 12px;
  height: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  overflow: hidden;
}

.todo-calendar-count {
  min-width: 16px;
  height: 12px;
  padding: 0 5px;
  border-radius: 999px;
  border: 1px solid rgba(37, 99, 235, 0.16);
  background: #eef6ff;
  color: #2563eb;
  font-size: 9px;
  line-height: 10px;
  font-weight: 950;
  font-variant-numeric: tabular-nums;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
}

.todo-calendar-cell.is-selected .todo-calendar-count {
  border-color: rgba(255, 255, 255, 0.48);
  background: rgba(255, 255, 255, 0.9);
  color: #2563eb;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.14);
}

.todo-calendar-event-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #94a3b8;
}

.todo-calendar-cell.has-health .todo-calendar-event-dot,
.todo-calendar-cell.has-medical .todo-calendar-event-dot {
  background: #14b8a6;
}

.todo-calendar-cell.has-statutory .todo-calendar-event-dot,
.todo-calendar-cell.has-traditional .todo-calendar-event-dot {
  background: #3b82f6;
}

.todo-calendar-agenda {
  display: grid;
  gap: 10px;
}

.todo-agenda-header {
  padding: 12px;
  border: 1px solid #e6edf4;
  border-radius: 8px;
  background: #fff;
}

.todo-agenda-lunar {
  margin-top: 4px;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
}

.todo-calendar-agenda-block {
  display: grid;
  gap: 8px;
}

.todo-calendar-agenda-title {
  color: #334155;
  font-size: 13px;
  font-weight: 900;
}

.todo-calendar-event-list {
  display: grid;
  gap: 6px;
}

.todo-calendar-event-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  padding: 9px 10px;
  border: 1px solid #e6edf4;
  border-radius: 8px;
  background: #fff;
}

.todo-calendar-event-item span {
  min-width: 42px;
  height: 24px;
  padding: 0 7px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #f1f5f9;
  color: #64748b;
  font-size: 11px;
  font-weight: 900;
}

.todo-calendar-event-item strong {
  min-width: 0;
  color: #0f172a;
  font-size: 13px;
  line-height: 1.35;
  font-weight: 800;
  word-break: break-word;
}

.todo-calendar-event-item.statutory span,
.todo-calendar-event-item.traditional span {
  background: #dbeafe;
  color: #2563eb;
}

.todo-calendar-event-item.health span,
.todo-calendar-event-item.medical span {
  background: #e9f5f2;
  color: #047857;
}

.todo-calendar-event-item.solar-term span {
  background: #ccfbf1;
  color: #0f766e;
}

.todo-calendar-event-item.work span {
  background: #fef3c7;
  color: #b45309;
}

@media (max-width: 720px) {
  .todo-sidebar-panel {
    top: 74px;
    bottom: 10px;
  }

  .todo-sidebar-panel.is-left,
  .todo-sidebar-panel.is-right {
    left: 12px;
    right: 12px;
  }

  .todo-form-grid {
    grid-template-columns: 1fr;
  }

  .todo-category-input-row,
  .todo-note-grid,
  .todo-note-detail-head {
    grid-template-columns: 1fr;
  }

  .todo-note-detail-head {
    display: grid;
    align-items: stretch;
  }

  .todo-note-detail-actions {
    justify-content: space-between;
  }

  .todo-note-color-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .todo-floating-notes {
    inset: 0;
    width: auto;
  }

  .todo-floating-note {
    width: min(300px, calc(100vw - 24px));
  }

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

  .todo-sidebar-heading-row {
    flex-wrap: wrap;
  }

  .todo-auto-card {
    min-height: 158px;
  }

  .todo-task-actions {
    justify-content: flex-end;
  }

  .todo-calendar-weekdays,
  .todo-calendar-grid {
    gap: 3px 5px;
  }

  .todo-calendar-cell {
    min-height: 54px;
    height: 54px;
    grid-template-rows: 25px 15px 7px;
    gap: 1px;
    padding: 3px 3px 2px;
  }

  .todo-calendar-cell.is-today,
  .todo-calendar-cell.is-selected {
    width: 54px;
  }

  .todo-calendar-day {
    width: auto;
    height: 25px;
    font-size: 17px;
  }

  .todo-calendar-lunar {
    height: 15px;
    min-height: 15px;
    padding: 0 1px;
    font-size: 9px;
    line-height: 15px;
  }

  .todo-calendar-mark-row {
    min-height: 7px;
    height: 7px;
  }

  .todo-calendar-count {
    min-width: 13px;
    height: 13px;
    padding: 0 3px;
    font-size: 8px;
    line-height: 13px;
  }

  .todo-calendar-rest-badge,
  .todo-calendar-work-badge {
    top: 1px;
    right: 3px;
    width: 15px;
    min-width: 15px;
    height: 15px;
    font-size: 8px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .todo-sidebar-panel,
  .todo-sidebar-bubble,
  .todo-icon-btn,
  .todo-mini-btn,
  .todo-task-action,
  .todo-primary-btn,
  .todo-header-add-btn,
  .todo-secondary-btn,
  .todo-sidebar-tab,
  .todo-auto-card,
  .todo-note-card,
  .todo-form-close-btn,
  .todo-calendar-cell {
    transition: none;
    animation: none;
  }
}

/* 加急刊出申请 */
.btn-urgent-publication,
.urgent-publication-approve-btn {
  background: linear-gradient(135deg, #b45309 0%, #d97706 100%);
  color: #fff;
  border: 1px solid #b45309;
  box-shadow: 0 8px 18px rgba(180, 83, 9, 0.18);
}

.btn-urgent-publication:hover,
.urgent-publication-approve-btn:hover:not(:disabled) {
  background: linear-gradient(135deg, #92400e 0%, #b45309 100%);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(180, 83, 9, 0.24);
}

.btn-urgent-publication:disabled,
.urgent-publication-approve-btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.urgent-publication-modal,
.urgent-publication-confirm-modal,
.urgent-publication-list-modal {
  width: min(720px, calc(100vw - 32px));
  max-width: 720px;
  overflow: hidden;
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.32);
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.22);
}

.urgent-publication-confirm-modal {
  max-width: 580px;
}

.urgent-publication-list-modal {
  width: min(1060px, calc(100vw - 40px));
  max-width: 1060px;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
}

.urgent-publication-header {
  align-items: flex-start;
  gap: 16px;
  padding: 18px 22px 16px;
  background: linear-gradient(135deg, #fff7ed 0%, #ffffff 54%, #fffaf5 100%);
  border-bottom: 1px solid #fdba74;
}

.urgent-publication-header h3 {
  margin: 0;
  color: #1f2937;
  font-size: 20px;
  font-weight: 800;
}

.urgent-publication-header p {
  margin: 6px 0 0;
  color: #64748b;
  font-size: 13px;
  line-height: 1.55;
}

.urgent-publication-close {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: #fff;
  border: 1px solid #e5e7eb;
  color: #64748b;
}

.urgent-publication-body {
  padding: 22px 24px 8px;
}

.urgent-publication-list-body {
  padding: 14px 18px 18px;
  overflow-y: auto;
}

.urgent-publication-modal-summary {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 10px;
  padding: 9px 12px;
  border-radius: 10px;
  background: linear-gradient(135deg, #fff7ed 0%, #ffffff 100%);
  border: 1px solid #fdba74;
  color: #7c2d12;
  font-size: 13px;
  font-weight: 800;
}

.urgent-publication-modal-summary strong {
  color: #b45309;
  font-size: 20px;
  line-height: 1;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.urgent-publication-loading,
.urgent-publication-error {
  min-height: 150px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  color: #475569;
  text-align: left;
}

.urgent-publication-loading p,
.urgent-publication-error p {
  margin: 4px 0 0;
  color: #64748b;
  font-size: 13px;
}

.urgent-publication-spinner {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 3px solid #fed7aa;
  border-top-color: #d97706;
  animation: urgentPublicationSpin 0.8s linear infinite;
}

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

.urgent-publication-summary {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 0.85fr);
  gap: 12px;
  margin-bottom: 20px;
}

.urgent-publication-summary > div {
  padding: 12px 14px;
  border-radius: 10px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}

.urgent-publication-summary .urgent-publication-title {
  grid-column: 1 / -1;
}

.urgent-publication-summary span,
.urgent-publication-meta b {
  display: block;
  margin-bottom: 4px;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
}

.urgent-publication-summary strong {
  display: block;
  color: #111827;
  font-size: 14px;
  line-height: 1.55;
  white-space: normal;
  word-break: break-word;
}

.urgent-publication-select,
.urgent-publication-textarea {
  width: 100%;
}

.urgent-publication-helper {
  margin-top: 7px;
  color: #64748b;
  font-size: 12px;
  line-height: 1.5;
}

.urgent-publication-issue-meta {
  margin-top: 10px;
}

.urgent-publication-issue-card {
  min-height: 46px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid #fed7aa;
  border-radius: 10px;
  background: linear-gradient(135deg, #fff7ed 0%, #ffffff 100%);
}

.urgent-publication-issue-card span {
  display: block;
  color: #9a3412;
  font-size: 12px;
  font-weight: 800;
}

.urgent-publication-issue-card strong {
  display: block;
  margin-top: 2px;
  color: #1f2937;
  font-size: 18px;
  line-height: 1;
  font-weight: 900;
}

.urgent-publication-issue-card em,
.urgent-publication-issue-empty {
  color: #94a3b8;
  font-size: 13px;
  font-style: normal;
}

.urgent-publication-toc-link {
  flex: 0 0 auto;
  height: 34px;
  padding: 0 12px;
  border: 1px solid #fdba74;
  border-radius: 8px;
  background: #ffffff;
  color: #b45309;
  font-size: 13px;
  font-weight: 850;
  cursor: pointer;
}

.urgent-publication-toc-link:hover {
  border-color: #d97706;
  background: #fff7ed;
}

.urgent-publication-toc-preview {
  width: min(860px, calc(100vw - 40px));
  max-width: 860px;
  max-height: 86vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.urgent-publication-toc-body {
  padding: 16px 20px 20px;
  overflow: auto;
}

.urgent-publication-toc-summary {
  margin-bottom: 12px;
  padding: 10px 12px;
  border: 1px solid #fed7aa;
  border-radius: 10px;
  background: #fff7ed;
  color: #9a3412;
  font-size: 13px;
  font-weight: 850;
}

.urgent-publication-toc-list {
  display: grid;
  gap: 10px;
}

.urgent-publication-toc-item {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 10px;
  padding: 12px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #ffffff;
}

.urgent-publication-toc-item b {
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 7px;
  background: #f1f5f9;
  color: #64748b;
  font-size: 12px;
}

.urgent-publication-toc-item strong {
  display: block;
  color: #111827;
  font-size: 14px;
  line-height: 1.55;
  word-break: break-word;
}

.urgent-publication-toc-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 7px;
}

.urgent-publication-toc-tags span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  max-width: 100%;
  padding: 3px 8px;
  border: 1px solid #dbeafe;
  border-radius: 999px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 12px;
  line-height: 1.35;
  word-break: break-word;
}

.urgent-publication-toc-tags em {
  flex: 0 0 auto;
  font-style: normal;
  font-weight: 800;
  color: #475569;
}

.urgent-publication-toc-item p {
  margin: 5px 0 0;
  color: #64748b;
  font-size: 12px;
  line-height: 1.5;
  word-break: break-word;
}

.urgent-publication-inline-entry {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin: 0;
  padding: 12px 24px;
  background: linear-gradient(90deg, #fff7ed 0%, #ffffff 100%);
  border-bottom: 1px solid #fed7aa;
}

.urgent-publication-inline-entry strong {
  display: block;
  color: #9a3412;
  font-size: 14px;
  font-weight: 800;
}

.urgent-publication-inline-entry span {
  display: block;
  margin-top: 2px;
  color: #64748b;
  font-size: 12px;
}

.urgent-publication-inline-entry .btn {
  flex: 0 0 auto;
  min-height: 36px;
  padding: 8px 14px;
  font-size: 13px;
  white-space: nowrap;
}

.urgent-publication-footer {
  padding: 16px 24px 22px;
  border-top: none;
  gap: 10px;
}

.urgent-publication-panel {
  margin: 0 20px 14px;
  padding: 16px;
  flex-shrink: 0;
  border: 1px solid #fed7aa;
  border-radius: 12px;
  background: linear-gradient(180deg, #fff7ed 0%, #ffffff 100%);
  box-shadow: 0 12px 30px rgba(180, 83, 9, 0.08);
}

.urgent-publication-compact-panel {
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin: 0 20px 10px;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid #fb923c;
  background: linear-gradient(135deg, #fff3e7 0%, #ffffff 56%, #fff7ed 100%);
  box-shadow: 0 12px 28px rgba(234, 88, 12, 0.15);
  position: relative;
  overflow: hidden;
}

.urgent-publication-compact-panel::before {
  content: '';
  position: absolute;
  inset: 0 auto 0 0;
  width: 5px;
  background: linear-gradient(180deg, #f97316 0%, #dc2626 100%);
}

.urgent-publication-compact-main {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.urgent-publication-compact-panel .urgent-publication-kicker {
  flex: 0 0 auto;
  margin: 0;
  background: #ea580c;
  color: #fff;
  box-shadow: 0 8px 18px rgba(234, 88, 12, 0.24);
}

.urgent-publication-compact-copy {
  min-width: 0;
}

.urgent-publication-compact-copy h3 {
  margin: 0;
  color: #7c2d12;
  font-size: 15px;
  line-height: 1.25;
  font-weight: 900;
}

.urgent-publication-compact-copy p {
  max-width: min(960px, 58vw);
  margin: 3px 0 0;
  overflow: hidden;
  color: #475569;
  font-size: 12px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.urgent-publication-compact-actions {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 8px;
}

.urgent-publication-open-btn {
  min-height: 34px;
  padding: 7px 15px;
  border: 1px solid #c2410c;
  border-radius: 9px;
  background: linear-gradient(135deg, #ea580c 0%, #c2410c 100%);
  color: #ffffff;
  font-size: 13px;
  font-weight: 850;
  box-shadow: 0 8px 18px rgba(234, 88, 12, 0.24);
}

.urgent-publication-open-btn:hover {
  background: linear-gradient(135deg, #c2410c 0%, #9a3412 100%);
  color: #ffffff;
  transform: translateY(-1px);
}

.urgent-publication-panel-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 14px;
}

.urgent-publication-kicker {
  width: fit-content;
  margin-bottom: 6px;
  padding: 3px 9px;
  border-radius: 999px;
  background: #ffedd5;
  color: #9a3412;
  font-size: 12px;
  font-weight: 800;
}

.urgent-publication-panel h3 {
  margin: 0;
  color: #1f2937;
  font-size: 18px;
  font-weight: 800;
}

.urgent-publication-panel p {
  margin: 5px 0 0;
  color: #64748b;
  font-size: 13px;
  line-height: 1.5;
}

.urgent-publication-count {
  flex: 0 0 auto;
  padding: 5px 12px;
  border-radius: 999px;
  background: #ffedd5;
  border: 1px solid #fb923c;
  color: #c2410c;
  font-size: 13px;
  font-weight: 800;
}

.urgent-publication-card-list {
  display: grid;
  gap: 12px;
}

.urgent-publication-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  padding: 14px;
  border-radius: 10px;
  background: #fff;
  border: 1px solid #e5e7eb;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
}

.urgent-publication-card-top {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 8px;
}

.urgent-publication-card-top span {
  padding: 3px 8px;
  border-radius: 999px;
  background: #f1f5f9;
  color: #475569;
  font-size: 12px;
  font-weight: 700;
}

.urgent-publication-card-top .urgent-publication-no {
  background: #eef2ff;
  color: #334155;
  border: 1px solid #c7d2fe;
  font-weight: 850;
}

.urgent-publication-status.is-current {
  background: #dcfce7;
  color: #166534;
}

.urgent-publication-status.is-locked {
  background: #fee2e2;
  color: #991b1b;
}

.urgent-publication-card h4 {
  margin: 0 0 10px;
  color: #111827;
  font-size: 15px;
  line-height: 1.55;
  font-weight: 800;
  white-space: normal;
  word-break: break-word;
}

.urgent-publication-meta {
  display: grid;
  grid-template-columns: repeat(5, minmax(120px, 1fr));
  gap: 8px;
}

.urgent-publication-meta span {
  min-width: 0;
  padding: 8px 10px;
  border-radius: 8px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  color: #334155;
  font-size: 12px;
  line-height: 1.45;
  white-space: normal;
  word-break: break-word;
}

.urgent-publication-reason {
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: 8px;
  background: #fff7ed;
  border: 1px dashed #fdba74;
}

.urgent-publication-reason b {
  color: #9a3412;
  font-size: 12px;
}

.urgent-publication-reason p {
  margin: 5px 0 0;
  color: #431407;
  white-space: pre-wrap;
  word-break: break-word;
}

.urgent-publication-card-actions {
  display: flex;
  flex-direction: column;
  gap: 7px;
  min-width: 144px;
  align-self: stretch;
  justify-content: center;
}

.urgent-publication-card-actions .btn {
  width: 100%;
  justify-content: center;
  min-height: 36px;
  padding: 7px 12px;
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}

.urgent-publication-list-modal .urgent-publication-card {
  gap: 12px;
  padding: 12px;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.045);
}

.urgent-publication-list-modal .urgent-publication-meta {
  grid-template-columns: repeat(5, minmax(96px, 1fr));
}

.urgent-publication-list-modal .urgent-publication-reason {
  margin-top: 8px;
  padding: 9px 10px;
}

.urgent-publication-list-modal .urgent-publication-card-actions .btn {
  min-height: 34px;
  border-radius: 9px;
}

.urgent-publication-view-btn {
  background: #eff6ff;
  color: #1d4ed8;
  border: 1px solid #93c5fd;
}

.urgent-publication-reject-btn {
  background: #fff1f2;
  color: #be123c;
  border: 1px solid #fda4af;
  box-shadow: 0 6px 14px rgba(190, 18, 60, 0.08);
}

.urgent-publication-reject-btn:hover {
  background: #ffe4e6;
  color: #9f1239;
  border-color: #fb7185;
  box-shadow: 0 8px 18px rgba(190, 18, 60, 0.12);
}

.urgent-publication-later-btn {
  background: #f8fafc;
  color: #64748b;
  border: 1px dashed #cbd5e1;
}

.urgent-publication-later-btn:hover {
  background: #f1f5f9;
  color: #334155;
  border-color: #94a3b8;
}

@media (max-width: 920px) {
  .urgent-publication-compact-panel {
    align-items: stretch;
    flex-direction: column;
  }

  .urgent-publication-compact-copy p {
    max-width: 100%;
  }

  .urgent-publication-compact-actions {
    justify-content: flex-end;
  }

  .urgent-publication-card,
  .urgent-publication-meta,
  .urgent-publication-summary {
    grid-template-columns: 1fr;
  }

  .urgent-publication-card-actions {
    flex-direction: row;
    flex-wrap: wrap;
  }

  .urgent-publication-card-actions .btn {
    width: auto;
    flex: 1 1 140px;
  }

  .urgent-publication-inline-entry {
    align-items: stretch;
    flex-direction: column;
  }

  .urgent-publication-inline-entry .btn {
    width: 100%;
    justify-content: center;
  }
}

/* 本文编辑在原 WPS 链接窗口内查看独立的 PDF 校对测试状态。 */
.editor-proofread-pdf-panel {
  margin-top: 18px;
  padding: 14px;
  border: 1px solid #bfdbfe;
  border-radius: 6px;
  background: #f8fbff;
}

.editor-proofread-pdf-panel-title {
  color: #1e3a5f;
  font-size: 15px;
  font-weight: 700;
}

.editor-proofread-pdf-panel-status,
.editor-proofread-pdf-panel-empty,
.editor-proofread-pdf-meta,
.editor-proofread-pdf-panel-error {
  margin-top: 7px;
  color: #64748b;
  font-size: 13px;
  line-height: 1.55;
}

.editor-proofread-pdf-panel-error {
  color: #b91c1c;
}

.editor-proofread-pdf-file-name {
  margin-top: 8px;
  color: #0f3d6e;
  font-size: 14px;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.editor-proofread-pdf-panel-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}



