:root {
  --bg: #f6f7f4;
  --panel: #ffffff;
  --ink: #1f2a2e;
  --muted: #667277;
  --line: #dfe5df;
  --teal: #147a75;
  --teal-dark: #0d5552;
  --amber: #c17716;
  --red: #b43b32;
  --blue: #2e638f;
  --green: #2d7a45;
  --shadow: 0 10px 30px rgba(29, 45, 51, 0.08);
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--bg);
  font-family:
    "Microsoft YaHei",
    "PingFang SC",
    "Segoe UI",
    Arial,
    sans-serif;
}

button,
input,
select {
  font: inherit;
}

.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 264px;
  padding: 22px 18px;
  background: #183337;
  color: #f7fbfa;
}

.brand {
  display: flex;
  gap: 12px;
  align-items: center;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
}

.brand-mark {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 8px;
  color: #d9f7ef;
  font-weight: 800;
}

.brand strong {
  display: block;
  line-height: 1.25;
}

.brand span {
  display: block;
  margin-top: 4px;
  color: #a9c4c0;
  font-size: 12px;
}

.nav {
  display: grid;
  gap: 5px;
  margin-top: 18px;
}

.nav a,
.nav-section-label {
  display: block;
  padding: 11px 12px;
  border-radius: 6px;
  color: #d9e7e4;
  text-decoration: none;
}

.nav a.active,
.nav a:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
}

.main {
  min-height: 100vh;
  margin-left: 264px;
}

.topbar {
  position: sticky;
  z-index: 5;
  top: 0;
  display: flex;
  min-height: 86px;
  align-items: center;
  justify-content: space-between;
  padding: 18px 30px;
  border-bottom: 1px solid var(--line);
  background: rgba(246, 247, 244, 0.94);
  backdrop-filter: blur(8px);
}

.eyebrow {
  margin: 0 0 5px;
  color: var(--teal-dark);
  font-size: 13px;
  font-weight: 700;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: 27px;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 14px;
  font-size: 20px;
}

h3 {
  margin-bottom: 9px;
  font-size: 16px;
}

.top-actions,
.row-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  align-items: center;
}

button,
.button-link {
  min-height: 36px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #ffffff;
  color: var(--ink);
  cursor: pointer;
  text-decoration: none;
}

button {
  padding: 0 13px;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.button-link {
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
}

.primary-button {
  border-color: var(--teal);
  background: var(--teal);
  color: #ffffff;
  font-weight: 700;
}

.icon-button {
  width: 38px;
  padding: 0;
  font-size: 18px;
}

.content {
  padding: 28px 30px 42px;
}

.section {
  margin-bottom: 26px;
}

.grid {
  display: grid;
  gap: 16px;
}

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

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

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

.ingest-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(280px, 0.75fr);
  gap: 18px;
  align-items: stretch;
}

.ingest-primary-panel .panel-header {
  padding: 22px 24px 0;
}

.ingest-primary-panel .panel-body {
  padding: 22px 24px 24px;
}

.ingest-capability-panel {
  align-self: start;
}

.ingest-capability-panel .panel-body {
  padding-top: 14px;
}

.ingest-workbench {
  display: grid;
  gap: 18px;
}

.ingest-current {
  display: grid;
  gap: 5px;
  padding: 15px 16px;
  border: 1px solid #cfe2dc;
  border-radius: 8px;
  background: #f2fbf7;
}

.ingest-current span,
.ingest-current small {
  color: var(--muted);
  font-size: 12px;
}

.ingest-current strong {
  font-size: 18px;
}

.upload-box {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  min-height: 148px;
  padding: 18px;
  border: 1px dashed #7baaa4;
  border-radius: 8px;
  background: #fbfefd;
}

.upload-box input[type="file"] {
  grid-column: 1 / -1;
  width: 100%;
  min-height: 44px;
  padding: 9px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #ffffff;
}

.upload-box strong {
  display: block;
  margin-bottom: 6px;
  font-size: 17px;
}

.upload-hint,
.compact-note {
  margin: 8px 0 0;
  font-size: 12px;
}

.capability-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.batch-card-list,
.file-card-list {
  display: grid;
  gap: 12px;
}

.ingest-intake-panel .file-card-list {
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  max-height: min(58vh, 620px);
  overflow-y: auto;
  padding-right: 4px;
}

.ingest-intake-panel .file-card {
  grid-template-columns: 1fr;
  align-content: start;
  min-height: 146px;
}

.ingest-intake-panel .file-card .status,
.ingest-intake-panel .file-card .button-link {
  width: fit-content;
}

.ingest-reception-deck .ingest-command-grid-v2 {
  grid-template-columns: minmax(320px, 0.38fr) minmax(420px, 0.44fr) minmax(240px, 0.18fr);
}

.ingest-reception-links {
  min-height: 0;
}

.ingest-reception-links a {
  min-height: 64px;
}

.batch-card,
.file-card {
  display: grid;
  gap: 12px;
  align-items: center;
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfa;
}

.batch-card {
  grid-template-columns: minmax(260px, 1fr) minmax(260px, 0.8fr) auto;
}

.batch-card.active {
  border-color: #9bc6bd;
  background: #f3fbf8;
}

.file-card {
  grid-template-columns: minmax(260px, 1fr) auto auto auto;
}

.card-title-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.card-title-row h3,
.file-card h3 {
  margin-bottom: 2px;
}

.file-card-title {
  color: var(--ink);
  text-decoration: none;
}

.file-card-title:hover {
  color: var(--primary);
}

.batch-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--muted);
  font-size: 13px;
}

.batch-facts span {
  min-height: 30px;
  padding: 5px 9px;
  border-radius: 6px;
  background: #eef3ef;
}

.merge-decision {
  display: flex;
  gap: 18px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  padding: 16px;
  border: 1px solid #cfe2dc;
  border-radius: 8px;
  background: #f2fbf7;
}

.merge-decision h3 {
  margin-bottom: 5px;
  font-size: 18px;
}

.expert-details {
  margin-top: 16px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfa;
}

.expert-details summary {
  cursor: pointer;
  font-weight: 700;
}

.expert-details h3 {
  margin-top: 16px;
}

.ingest-command-center {
  display: grid;
  gap: 18px;
  padding: 18px;
  border: 1px solid #d9e4e1;
  border-radius: 8px;
  background: #f8faf8;
}

.ingest-progress-strip {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  padding: 10px;
  border: 1px solid #e1e8e5;
  border-radius: 8px;
  background: #ffffff;
}

.ingest-progress-step {
  display: flex;
  min-height: 44px;
  align-items: center;
  gap: 9px;
  padding: 8px 10px;
  border-radius: 7px;
  color: var(--muted);
  font-size: 13px;
}

.ingest-progress-step span {
  display: block;
  width: 11px;
  height: 11px;
  flex: 0 0 auto;
  border: 2px solid #b8c8c4;
  border-radius: 999px;
  background: #ffffff;
}

.ingest-progress-step.done {
  background: #edf7f4;
  color: var(--teal-dark);
}

.ingest-progress-step.done span {
  border-color: var(--teal);
  background: var(--teal);
}

.ingest-command-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(320px, 0.72fr);
  gap: 18px;
  align-items: stretch;
}

.ingest-upload-card,
.ingest-side-card {
  display: grid;
  gap: 18px;
  border: 1px solid #dbe5e1;
  border-radius: 8px;
  background: #ffffff;
}

.ingest-upload-card {
  padding: 24px;
}

.ingest-upload-card h2 {
  max-width: 780px;
  margin-bottom: 8px;
  font-size: 24px;
}

.ingest-side-card {
  align-content: start;
  padding: 20px;
}

.ingest-side-card h3 {
  margin-bottom: 8px;
  font-size: 20px;
}

.ingest-current-hero {
  display: flex;
  gap: 14px;
  align-items: center;
  justify-content: space-between;
  padding: 16px;
  border: 1px solid #cce2dd;
  border-radius: 8px;
  background: #f1faf7;
}

.ingest-current-hero div {
  display: grid;
  gap: 4px;
}

.ingest-current-hero span,
.ingest-current-hero small {
  color: var(--muted);
  font-size: 12px;
}

.ingest-current-hero strong {
  color: var(--ink);
  font-size: 18px;
}

.ingest-action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.ingest-action-row button,
.ingest-dropzone button,
.batch-card button {
  min-height: 44px;
}

.ingest-select-label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.ingest-select-label select {
  min-height: 44px;
  font-weight: 600;
}

.ingest-dropzone {
  display: grid;
  gap: 12px;
  justify-items: center;
  min-height: 260px;
  padding: 26px;
  border: 1px dashed #82aaa4;
  border-radius: 8px;
  background: #fbfefd;
  text-align: center;
  transition:
    border-color 180ms ease,
    background 180ms ease;
}

.ingest-dropzone.drag-over {
  border-color: var(--teal);
  background: #edf7f4;
}

.upload-pick-button {
  min-width: 120px;
  border-color: #b8d6d0;
  background: #f4fbf8;
  color: var(--teal-dark);
  font-weight: 800;
}

.ingest-dropzone strong {
  font-size: 20px;
}

.upload-submit {
  min-width: 170px;
}

.selected-file-list {
  display: grid;
  width: min(100%, 620px);
  gap: 6px;
  padding: 12px;
  border-radius: 8px;
  background: #f4f7f5;
  color: var(--muted);
  font-size: 13px;
  text-align: left;
}

.selected-file-list span {
  color: var(--ink);
  font-weight: 800;
}

.selected-file-list small {
  display: block;
  overflow-wrap: anywhere;
}

.ingest-side-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.ingest-side-metrics div {
  display: grid;
  gap: 2px;
  min-height: 82px;
  padding: 12px;
  border: 1px solid #e0e8e4;
  border-radius: 8px;
  background: #fbfcfa;
}

.ingest-side-metrics strong {
  font-size: 24px;
}

.ingest-side-metrics span {
  font-weight: 700;
}

.ingest-side-metrics small {
  color: var(--muted);
  font-size: 12px;
}

.capability-tags.compact {
  margin-top: 2px;
}

.ingest-work-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(360px, 0.85fr);
  gap: 18px;
  align-items: start;
}

.ingest-entry-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.ingest-entry-card {
  display: grid;
  min-height: 150px;
  align-content: start;
  gap: 9px;
  padding: 18px;
  border: 1px solid #dbe5e1;
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  text-decoration: none;
  box-shadow: var(--shadow);
  transition:
    border-color 160ms ease,
    transform 160ms ease,
    box-shadow 160ms ease;
}

.ingest-entry-card:hover {
  border-color: #94beb7;
  box-shadow: 0 14px 32px rgba(29, 45, 51, 0.1);
  transform: translateY(-1px);
}

.ingest-entry-card span {
  width: fit-content;
  padding: 5px 9px;
  border-radius: 999px;
  background: #edf7f4;
  color: var(--teal-dark);
  font-size: 12px;
  font-weight: 800;
}

.ingest-entry-card strong {
  font-size: 18px;
}

.ingest-entry-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.ingest-home-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(340px, 0.85fr);
  gap: 16px;
  align-items: start;
}

.ingest-summary-card,
.ingest-checklist-card {
  box-shadow: none;
}

.ingest-result-metrics,
.file-parse-overview {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.ingest-result-metrics > div,
.file-parse-overview > div {
  display: grid;
  gap: 2px;
  min-height: 82px;
  padding: 12px;
  border: 1px solid #e0e8e4;
  border-radius: 8px;
  background: #fbfcfa;
}

.ingest-result-metrics strong,
.file-parse-overview strong {
  font-size: 23px;
}

.ingest-result-metrics span,
.file-parse-overview span {
  font-weight: 700;
}

.ingest-result-metrics small,
.file-parse-overview small {
  color: var(--muted);
  font-size: 12px;
}

.next-action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.ingest-command-deck {
  display: grid;
  gap: 16px;
  padding: 18px;
  border: 1px solid #d6e1dd;
  border-radius: 8px;
  background: #f8faf8;
}

.ingest-command-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 18px;
}

.ingest-command-head h2 {
  max-width: 760px;
  margin-bottom: 6px;
  font-size: 24px;
}

.ingest-command-head .muted {
  max-width: 780px;
}

.ingest-command-grid-v2 {
  display: grid;
  grid-template-columns: minmax(300px, 0.95fr) minmax(420px, 1.1fr) minmax(230px, 0.55fr);
  gap: 14px;
  align-items: stretch;
}

.ingest-batch-card-v2,
.ingest-upload-card-v2,
.ingest-next-card-v2 {
  min-width: 0;
  border: 1px solid #dbe5e1;
  border-radius: 8px;
  background: #ffffff;
}

.ingest-batch-card-v2 {
  display: grid;
  gap: 12px;
  padding: 14px;
}

.ingest-batch-title-row {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid #e1e8e5;
}

.ingest-batch-title-row div {
  display: grid;
  min-width: 0;
  gap: 4px;
}

.ingest-batch-title-row span,
.ingest-batch-title-row small {
  color: var(--muted);
  font-size: 12px;
}

.ingest-batch-title-row strong {
  overflow-wrap: anywhere;
  font-size: 18px;
}

.ingest-mini-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.ingest-mini-metrics div {
  display: grid;
  gap: 2px;
  min-height: 66px;
  padding: 10px;
  border: 1px solid #e1e8e5;
  border-radius: 8px;
  background: #fbfcfa;
}

.ingest-mini-metrics strong {
  font-size: 20px;
}

.ingest-mini-metrics span {
  font-weight: 800;
}

.ingest-mini-metrics small {
  color: var(--muted);
  font-size: 12px;
}

.ingest-upload-card-v2 {
  display: grid;
  gap: 12px;
  align-content: start;
  padding: 16px;
}

.ingest-upload-card-v2 strong {
  display: block;
  margin-top: 3px;
  font-size: 18px;
}

.ingest-upload-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.ingest-next-card-v2 {
  display: grid;
  gap: 9px;
  align-content: start;
  padding: 14px;
}

.ingest-next-card-v2 a {
  display: grid;
  gap: 4px;
  min-height: 62px;
  padding: 11px;
  border: 1px solid #e1e8e5;
  border-radius: 8px;
  background: #fbfcfa;
  color: var(--ink);
  text-decoration: none;
}

.ingest-next-card-v2 a:hover {
  border-color: #94beb7;
  background: #f1faf7;
}

.ingest-next-card-v2 span {
  color: var(--muted);
  font-size: 12px;
}

.ingest-flow-board {
  display: grid;
  gap: 14px;
  padding: 18px;
  border: 1px solid #d6e1dd;
  border-radius: 8px;
  background: linear-gradient(180deg, #ffffff 0%, #f7faf9 100%);
}

.ingest-flow-board-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(420px, 0.62fr);
  gap: 18px;
  align-items: start;
}

.ingest-flow-board-head h2 {
  margin-bottom: 6px;
  font-size: 24px;
}

.ingest-operation-panel {
  display: grid;
  gap: 16px;
  padding: 18px;
  border: 1px solid #d9e4e1;
  border-radius: 8px;
  background: #f8faf8;
}

.ingest-operation-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 18px;
}

.ingest-operation-head h2 {
  margin-bottom: 6px;
  font-size: 23px;
}

.ingest-operation-grid {
  display: grid;
  grid-template-columns: minmax(320px, 0.92fr) minmax(420px, 1.1fr) minmax(240px, 0.55fr);
  gap: 14px;
  align-items: stretch;
}

.ingest-current-box,
.ingest-operation-links {
  display: grid;
  gap: 12px;
  min-width: 0;
  padding: 14px;
  border: 1px solid #dbe5e1;
  border-radius: 8px;
  background: #ffffff;
}

.compact-upload {
  min-height: 0;
  padding: 18px;
}

.compact-upload strong {
  font-size: 18px;
}

.compact-upload .selected-file-list {
  width: 100%;
}

.ingest-operation-links {
  align-content: start;
}

.ingest-operation-links a {
  display: grid;
  gap: 4px;
  min-height: 66px;
  padding: 12px;
  border: 1px solid #e0e8e4;
  border-radius: 8px;
  background: #fbfcfa;
  color: var(--ink);
  text-decoration: none;
}

.ingest-operation-links a:hover {
  border-color: #94beb7;
  background: #f1faf7;
}

.ingest-operation-links span {
  color: var(--muted);
  font-size: 12px;
}

.ingest-flow-switchbar {
  display: flex;
  min-height: 68px;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid #d9e4e1;
  border-radius: 8px;
  background: #ffffff;
}

.ingest-flow-switchbar label {
  display: grid;
  min-width: min(520px, 100%);
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.ingest-flow-switchbar select {
  min-height: 42px;
  font-weight: 700;
}

.ingest-flow-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(420px, 0.62fr);
  gap: 18px;
  align-items: stretch;
  padding: 20px;
  border: 1px solid #d9e4e1;
  border-radius: 8px;
  background: #f8faf8;
}

.ingest-flow-hero h2 {
  max-width: 820px;
  margin-bottom: 8px;
  font-size: 25px;
}

.ingest-flow-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.ingest-flow-summary > div {
  display: grid;
  gap: 2px;
  min-height: 78px;
  padding: 12px;
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  background: #ffffff;
}

.ingest-flow-summary strong {
  font-size: 24px;
}

.ingest-flow-summary span {
  font-weight: 800;
}

.ingest-flow-summary small {
  color: var(--muted);
  font-size: 12px;
}

.ingest-flow-stagebar {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
  padding: 10px;
  border: 1px solid #e1e8e5;
  border-radius: 8px;
  background: #ffffff;
}

.ingest-flow-stagebar a {
  display: flex;
  min-height: 44px;
  align-items: center;
  gap: 9px;
  padding: 9px 10px;
  border-radius: 7px;
  color: var(--ink);
  text-decoration: none;
  animation: flowNodeEnter 260ms ease both;
  animation-delay: calc(var(--flow-stage-index) * 45ms);
}

.ingest-flow-stagebar a:hover {
  background: #edf7f4;
}

.ingest-flow-stagebar span {
  display: inline-flex;
  width: 22px;
  height: 22px;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  border-radius: 999px;
  background: #dcebe7;
  color: var(--teal-dark);
  font-size: 12px;
  font-weight: 800;
}

.ingest-flow-stagebar strong {
  font-size: 13px;
}

.processing-file-rail {
  display: grid;
  align-content: start;
  gap: 12px;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  padding: 14px;
  overflow: hidden;
  border: 1px solid #dbe7e2;
  border-radius: 8px;
  background: #ffffff;
}

.risk-text {
  color: #a6421a !important;
  font-weight: 800;
}

.ingest-flow-canvas,
.processing-file-scroll {
  min-width: 0;
  max-width: 100%;
  max-height: min(68vh, 760px);
  overflow-x: hidden;
  overflow-y: auto;
  padding: 12px;
  border: 1px solid #dbe7e2;
  border-radius: 8px;
  background: #ffffff;
}

.ingest-flow-canvas .ingest-flow-stagebar {
  position: sticky;
  top: 0;
  z-index: 2;
  margin-bottom: 12px;
  box-shadow: 0 8px 18px rgba(39, 54, 60, 0.06);
}

.ingest-flow-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.26fr);
  gap: 16px;
  align-items: start;
}

.ingest-flow-lane-list {
  display: grid;
  gap: 10px;
}

.ingest-flow-lane {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid #dbe5e1;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 8px 18px rgba(29, 45, 51, 0.06);
  animation: flowLaneEnter 300ms ease both;
  animation-delay: calc(var(--flow-lane-index) * 60ms);
}

.ingest-flow-file {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 6px 12px;
  align-items: center;
}

.ingest-flow-file .status {
  grid-row: span 2;
}

.ingest-flow-file h3 {
  margin: 0;
  overflow-wrap: anywhere;
  font-size: 15px;
}

.ingest-flow-file h3 a {
  color: var(--ink);
  text-decoration: none;
}

.ingest-flow-file h3 a:hover,
.ingest-flow-file h3 a:focus-visible {
  color: var(--teal-dark);
  outline: none;
  text-decoration: underline;
}

.ingest-flow-file p {
  margin: 0;
}

.ingest-flow-track {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 8px;
  overflow: visible;
}

.ingest-flow-node {
  position: relative;
  display: grid;
  gap: 5px;
  min-height: 88px;
  padding: 10px;
  border: 1px solid #dde8e4;
  border-radius: 8px;
  background: #fbfcfa;
  animation: flowNodeEnter 280ms ease both;
  animation-delay: calc(var(--flow-node-index) * 70ms);
}

a.ingest-flow-node {
  color: inherit;
  cursor: pointer;
  text-decoration: none;
  transition:
    border-color 160ms ease,
    box-shadow 160ms ease,
    transform 160ms ease;
}

a.ingest-flow-node:hover,
a.ingest-flow-node:focus-visible {
  border-color: rgba(20, 122, 117, 0.55);
  box-shadow: 0 12px 24px rgba(20, 122, 117, 0.12);
  outline: none;
  transform: translateY(-1px);
}

.ingest-flow-node::after {
  position: absolute;
  top: 50%;
  right: -11px;
  width: 10px;
  height: 2px;
  background: #cbd8d4;
  content: "";
}

.ingest-flow-node:last-child::after {
  display: none;
}

.ingest-flow-node span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.ingest-flow-node strong {
  overflow-wrap: anywhere;
  font-size: 15px;
  line-height: 1.45;
}

.ingest-flow-node small {
  color: var(--muted);
  line-height: 1.5;
}

.ingest-flow-dataset-node {
  gap: 7px;
}

.ingest-flow-dataset-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-width: 0;
  max-width: 100%;
}

.ingest-flow-dataset-list em {
  display: inline-flex;
  max-width: 100%;
  min-height: 26px;
  align-items: center;
  padding: 4px 8px;
  border: 1px solid #cfe2dc;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--teal-dark);
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
  line-height: 1.35;
  overflow-wrap: anywhere;
  white-space: normal;
  word-break: break-word;
}

.ingest-flow-dataset-list small {
  color: var(--muted);
}

.ingest-flow-node.tone-ok {
  border-color: #cce2dd;
  background: #f1faf7;
}

.ingest-flow-node.tone-warn {
  border-color: #f2d5a5;
  background: #fff8ea;
}

.ingest-flow-node.tone-risk {
  border-color: #f1b7af;
  background: #fff3f1;
}

.ingest-flow-node.tone-info {
  border-color: #ceddeb;
  background: #f3f8fc;
}

.file-processing-hero,
.dataset-detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
}

.dataset-center-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 4px 0 0;
}

.dataset-center-tabs a {
  min-height: 38px;
  padding: 9px 13px;
  border: 1px solid #d9e4e1;
  border-radius: 7px;
  background: #ffffff;
  color: var(--ink);
  font-weight: 800;
  text-decoration: none;
}

.dataset-center-tabs a.active,
.dataset-center-tabs a:hover,
.dataset-center-tabs a:focus-visible {
  border-color: rgba(20, 122, 117, 0.58);
  background: #edf7f4;
  color: var(--teal-dark);
  outline: none;
}

.dataset-catalog-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 0.46fr);
  gap: 18px;
  align-items: stretch;
  padding: 26px;
  overflow: hidden;
  border: 1px solid rgba(20, 122, 117, 0.22);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(20, 122, 117, 0.15), rgba(255, 255, 255, 0.9) 48%),
    radial-gradient(circle at 96% 12%, rgba(46, 99, 143, 0.16), transparent 34%),
    #fbfdfb;
  box-shadow: 0 18px 44px rgba(23, 42, 46, 0.08);
}

.dataset-catalog-hero h2 {
  max-width: 900px;
  margin: 4px 0 9px;
  font-size: 30px;
  line-height: 1.2;
}

.dataset-catalog-hero p {
  max-width: 820px;
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.7;
}

.dataset-catalog-hero-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  align-content: stretch;
}

.dataset-catalog-hero-metrics > div {
  min-width: 0;
  padding: 15px;
  border: 1px solid rgba(20, 122, 117, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
}

.dataset-catalog-hero-metrics span,
.dataset-catalog-hero-metrics small {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.dataset-catalog-hero-metrics strong {
  display: block;
  margin: 8px 0 4px;
  color: var(--ink);
  font-size: 26px;
  line-height: 1;
}

.dataset-relation-canvas,
.dataset-topology-shell {
  padding: 20px;
  border: 1px solid #d9e4e1;
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(244, 250, 248, 0.94)),
    #ffffff;
  box-shadow: 0 14px 34px rgba(23, 42, 46, 0.06);
}

.dataset-canvas-head,
.dataset-topology-head {
  display: flex;
  gap: 14px;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 16px;
}

.dataset-canvas-head h3,
.dataset-topology-head h3 {
  margin: 3px 0 0;
  font-size: 22px;
}

.dataset-relation-canvas {
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(250, 253, 252, 0.98), rgba(240, 248, 255, 0.92)),
    #ffffff;
}

.dataset-relation-canvas > .muted {
  margin: -4px 0 18px;
  line-height: 1.7;
}

.dataset-canvas-board {
  position: relative;
  display: grid;
  gap: 18px;
  min-height: 560px;
  padding: 18px;
  border: 1px solid rgba(20, 122, 117, 0.16);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(20, 122, 117, 0.05), rgba(46, 99, 143, 0.04)),
    #fbfdfd;
}

.dataset-canvas-band-title {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  padding: 7px 10px;
  border: 1px solid rgba(20, 122, 117, 0.16);
  border-radius: 999px;
  background: #eef8f5;
  color: var(--teal-dark);
  font-size: 13px;
  font-weight: 900;
}

.dataset-atom-row,
.dataset-composite-row {
  display: grid;
  gap: 14px;
  align-items: stretch;
}

.dataset-atom-row {
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
}

.dataset-composite-row {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.dataset-canvas-card {
  position: relative;
  display: grid;
  min-width: 0;
  gap: 8px;
  min-height: 136px;
  padding: 15px;
  border: 1px solid #dce8e5;
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  text-decoration: none;
  box-shadow: 0 10px 24px rgba(23, 42, 46, 0.05);
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.dataset-canvas-card:hover,
.dataset-canvas-card:focus-visible {
  border-color: rgba(20, 122, 117, 0.52);
  box-shadow:
    0 16px 30px rgba(20, 122, 117, 0.12),
    0 0 0 3px rgba(20, 122, 117, 0.08);
  outline: none;
  transform: translateY(-2px);
}

.dataset-canvas-card.is-atomic::before,
.dataset-canvas-card.is-composite::before {
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  border-radius: 8px 0 0 8px;
  background: var(--teal);
  content: "";
}

.dataset-canvas-card.is-composite::before {
  background: var(--blue);
}

.dataset-canvas-card.is-composite {
  border-color: rgba(46, 99, 143, 0.22);
  background:
    linear-gradient(135deg, rgba(46, 99, 143, 0.06), rgba(255, 255, 255, 0.96)),
    #ffffff;
}

.dataset-canvas-card span,
.dataset-canvas-card em,
.dataset-process-card span {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
}

.dataset-canvas-card strong {
  display: block;
  font-size: 16px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.dataset-canvas-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.dataset-canvas-card > div {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.dataset-canvas-card em {
  padding: 4px 7px;
  border-radius: 999px;
  background: #edf7f4;
  color: var(--teal-dark);
}

.dataset-canvas-card.is-composite em {
  background: #eef5fb;
  color: #285a80;
}

.dataset-process-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  min-height: 220px;
  padding: 8px 4px;
}

.dataset-process-lane {
  position: relative;
  display: grid;
  min-height: 210px;
  place-items: center;
}

.dataset-process-arrow {
  position: relative;
  display: grid;
  width: 62px;
  height: 168px;
  place-items: center;
}

.dataset-arrow-line {
  position: absolute;
  top: 0;
  bottom: 28px;
  left: 50%;
  width: 7px;
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(20, 122, 117, 0.24), rgba(20, 122, 117, 0.95));
  box-shadow: 0 0 18px rgba(20, 122, 117, 0.18);
  transform: translateX(-50%);
  content: "";
}

.dataset-arrow-head {
  position: absolute;
  bottom: 9px;
  left: 50%;
  width: 0;
  height: 0;
  border-top: 28px solid rgba(20, 122, 117, 0.96);
  border-right: 18px solid transparent;
  border-left: 18px solid transparent;
  filter: drop-shadow(0 8px 12px rgba(20, 122, 117, 0.22));
  transform: translateX(-50%);
}

.dataset-arrow-packet {
  position: absolute;
  top: 8px;
  left: 50%;
  width: 13px;
  height: 13px;
  border: 2px solid #ffffff;
  border-radius: 50%;
  background: #2e638f;
  box-shadow:
    0 0 0 5px rgba(46, 99, 143, 0.13),
    0 0 20px rgba(46, 99, 143, 0.35);
  animation: datasetPacketDown 2.9s ease-in-out infinite;
  animation-delay: calc(var(--lane-index, 0) * 180ms);
  transform: translateX(-50%);
}

@keyframes datasetPacketDown {
  0% {
    top: 8px;
    opacity: 0;
    transform: translateX(-50%) scale(0.72);
  }
  12% {
    opacity: 1;
  }
  80% {
    opacity: 1;
  }
  100% {
    top: 126px;
    opacity: 0;
    transform: translateX(-50%) scale(1);
  }
}

.dataset-process-card {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 2;
  width: min(220px, 82%);
  padding: 10px 12px;
  border: 1px solid rgba(46, 99, 143, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 14px 28px rgba(23, 42, 46, 0.08);
  transform: translate(-50%, -50%);
}

.dataset-process-card strong {
  display: block;
  margin: 4px 0;
  font-size: 15px;
}

.dataset-process-card p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.dataset-process-lane::before,
.dataset-process-lane::after {
  position: absolute;
  left: 50%;
  width: 1px;
  height: 26px;
  background: rgba(20, 122, 117, 0.2);
  content: "";
}

.dataset-process-lane::before {
  top: -12px;
}

.dataset-process-lane::after {
  bottom: -12px;
}

.dataset-topology-grid {
  position: relative;
  display: grid;
  grid-template-columns: minmax(260px, 0.95fr) minmax(280px, 0.82fr) minmax(260px, 0.95fr);
  gap: 16px;
  align-items: stretch;
}

.dataset-topology-column {
  display: grid;
  min-width: 0;
  gap: 10px;
  align-content: start;
  padding: 12px;
  border: 1px solid rgba(20, 122, 117, 0.12);
  border-radius: 8px;
  background: rgba(250, 253, 252, 0.78);
}

.dataset-topology-column-title {
  position: sticky;
  top: 94px;
  z-index: 1;
  padding: 8px 10px;
  border: 1px solid rgba(20, 122, 117, 0.14);
  border-radius: 7px;
  background: rgba(238, 248, 245, 0.96);
  color: var(--teal-dark);
  font-size: 13px;
  font-weight: 900;
}

.dataset-process-column {
  background:
    linear-gradient(180deg, rgba(236, 247, 244, 0.7), rgba(255, 255, 255, 0.9));
}

.dataset-process-node {
  position: relative;
  display: grid;
  min-width: 0;
  gap: 8px;
  padding: 13px;
  border: 1px solid #dce8e5;
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  text-decoration: none;
  box-shadow: 0 10px 24px rgba(23, 42, 46, 0.05);
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.dataset-process-node:hover {
  border-color: rgba(20, 122, 117, 0.5);
  box-shadow: 0 16px 30px rgba(20, 122, 117, 0.12);
  outline: none;
  transform: translateY(-2px);
}

.dataset-process-node span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.dataset-process-node strong {
  display: block;
  font-size: 16px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.dataset-process-node p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.dataset-process-node {
  padding: 15px;
  border-color: rgba(46, 99, 143, 0.22);
  background:
    linear-gradient(135deg, rgba(46, 99, 143, 0.08), rgba(255, 255, 255, 0.96)),
    #ffffff;
}

.dataset-process-node a {
  color: var(--teal-dark);
  font-size: 13px;
  font-weight: 900;
  text-decoration: none;
}

.dataset-flow-line {
  height: 3px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(20, 122, 117, 0.16);
}

.dataset-flow-line::after {
  display: block;
  width: 42%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, transparent, rgba(20, 122, 117, 0.9), transparent);
  animation: datasetFlowPulse 2.8s ease-in-out infinite;
  animation-delay: calc(var(--flow-index, 0) * 160ms);
  content: "";
}

@keyframes datasetFlowPulse {
  0% {
    transform: translateX(-120%);
    opacity: 0.2;
  }
  45% {
    opacity: 1;
  }
  100% {
    transform: translateX(260%);
    opacity: 0.2;
  }
}

.dataset-canvas-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: flex-end;
}

.dataset-canvas-tools button {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid rgba(46, 99, 143, 0.22);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  font-weight: 900;
  cursor: pointer;
}

.dataset-canvas-tools button:hover,
.dataset-canvas-tools button:focus-visible {
  border-color: rgba(20, 122, 117, 0.56);
  color: var(--teal-dark);
  outline: none;
}

.dataset-lineage-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 0.28fr);
  gap: 16px;
  align-items: stretch;
}

.dataset-lineage-stage {
  position: relative;
  min-height: 760px;
  overflow: hidden;
  border: 1px solid rgba(20, 122, 117, 0.16);
  border-radius: 10px;
  background:
    linear-gradient(rgba(20, 122, 117, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(20, 122, 117, 0.055) 1px, transparent 1px),
    radial-gradient(circle at 50% 48%, rgba(20, 122, 117, 0.12), transparent 34%),
    #fbfdfd;
  background-size: 36px 36px, 36px 36px, auto, auto;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.82);
}

.dataset-lineage-svg {
  display: block;
  width: 100%;
  height: 760px;
  cursor: grab;
  touch-action: none;
  user-select: none;
}

.dataset-lineage-svg.is-panning,
.dataset-lineage-svg.is-dragging {
  cursor: grabbing;
}

.dataset-lineage-divider {
  stroke: rgba(20, 122, 117, 0.12);
  stroke-width: 1;
  stroke-dasharray: 10 12;
}

.dataset-lineage-link {
  fill: none;
  stroke: rgba(20, 122, 117, 0.34);
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-dasharray: 8 12;
  opacity: 0.58;
  animation: datasetLineageFlow 2.6s linear infinite;
  animation-delay: calc(var(--flow-index, 0) * 90ms);
}

.dataset-lineage-link.active {
  stroke: #147a75;
  stroke-width: 3.2;
  opacity: 1;
  filter: drop-shadow(0 6px 10px rgba(20, 122, 117, 0.2));
}

.dataset-lineage-link.muted {
  opacity: 0.28;
  animation: none;
}

@keyframes datasetLineageFlow {
  to {
    stroke-dashoffset: -44;
  }
}

.dataset-lineage-node {
  cursor: pointer;
  outline: none;
}

.dataset-lineage-card {
  fill: url("#dataset-lineage-atomic");
  stroke: rgba(20, 122, 117, 0.3);
  stroke-width: 1.4;
  filter: url("#dataset-lineage-shadow");
  transition: stroke 160ms ease, stroke-width 160ms ease, opacity 160ms ease;
}

.dataset-lineage-node.composite .dataset-lineage-card {
  fill: url("#dataset-lineage-composite");
  stroke: rgba(46, 99, 143, 0.3);
}

.dataset-lineage-node.active .dataset-lineage-card,
.dataset-lineage-node:focus-visible .dataset-lineage-card {
  stroke: #0f8f87;
  stroke-width: 3.2;
  filter:
    url("#dataset-lineage-shadow")
    drop-shadow(0 0 10px rgba(20, 122, 117, 0.34))
    drop-shadow(0 0 22px rgba(46, 99, 143, 0.16));
}

.dataset-lineage-node.muted {
  opacity: 1;
}

.dataset-lineage-type {
  fill: #678086;
  font-size: 12px;
  font-weight: 800;
}

.dataset-lineage-name {
  fill: var(--ink);
  font-size: 15px;
  font-weight: 900;
}

.dataset-lineage-meta {
  fill: #4b7472;
  font-size: 11px;
  font-weight: 800;
}

.dataset-lineage-node.composite .dataset-lineage-meta {
  fill: #2e638f;
}

.dataset-lineage-tooltip {
  position: absolute;
  z-index: 4;
  display: none;
  max-width: 260px;
  padding: 9px 11px;
  border: 1px solid rgba(20, 122, 117, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 16px 34px rgba(23, 42, 46, 0.14);
  pointer-events: none;
}

.dataset-lineage-tooltip.visible {
  display: grid;
  gap: 4px;
}

.dataset-lineage-tooltip strong {
  font-size: 13px;
}

.dataset-lineage-tooltip span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.dataset-lineage-detail {
  display: grid;
  gap: 14px;
  align-content: start;
  min-width: 0;
  padding: 16px;
  border: 1px solid rgba(20, 122, 117, 0.16);
  border-radius: 10px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(246, 251, 250, 0.92)),
    #ffffff;
}

.dataset-lineage-detail-head span {
  color: var(--teal-dark);
  font-size: 12px;
  font-weight: 900;
}

.dataset-lineage-detail-head h3 {
  margin: 5px 0 8px;
  font-size: 20px;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.dataset-lineage-detail-head p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

.dataset-lineage-detail-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.dataset-lineage-detail-metrics div {
  min-width: 0;
  padding: 10px;
  border: 1px solid rgba(20, 122, 117, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
}

.dataset-lineage-detail-metrics span,
.dataset-lineage-detail-metrics small {
  display: block;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.dataset-lineage-detail-metrics strong {
  display: block;
  margin: 4px 0 2px;
  font-size: 20px;
  line-height: 1;
}

.dataset-lineage-detail-section {
  display: grid;
  gap: 9px;
}

.dataset-lineage-detail-section > strong {
  font-size: 14px;
}

.dataset-lineage-related {
  display: grid;
  gap: 8px;
}

.dataset-lineage-related button {
  display: grid;
  gap: 3px;
  width: 100%;
  min-height: 54px;
  padding: 9px 11px;
  border: 1px solid rgba(20, 122, 117, 0.14);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}

.dataset-lineage-related button:hover,
.dataset-lineage-related button:focus-visible {
  border-color: rgba(20, 122, 117, 0.54);
  outline: none;
}

.dataset-lineage-related span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.dataset-lineage-related em {
  overflow-wrap: anywhere;
  font-style: normal;
  font-weight: 900;
}

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

.dataset-lineage-list > div {
  min-width: 0;
  padding: 14px;
  border: 1px solid rgba(20, 122, 117, 0.12);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.78);
}

.dataset-lineage-list strong {
  display: block;
  margin-bottom: 4px;
}

.dataset-lineage-list p {
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.dataset-lineage-list > div > div {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.dataset-lineage-chip {
  min-height: 34px;
  padding: 0 10px;
  border: 1px solid rgba(20, 122, 117, 0.16);
  border-radius: 999px;
  background: #f8fbfa;
  color: var(--ink);
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.dataset-lineage-chip.active,
.dataset-lineage-chip:hover,
.dataset-lineage-chip:focus-visible {
  border-color: rgba(20, 122, 117, 0.6);
  background: #e8f7f3;
  color: var(--teal-dark);
  outline: none;
}

.dataset-catalog-toolbar {
  align-items: center;
}

.dataset-catalog-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.dataset-catalog-controls button {
  min-height: 38px;
  border-radius: 999px;
  font-weight: 800;
}

.dataset-catalog-controls button.active {
  border-color: var(--teal);
  background: var(--teal);
  color: #ffffff;
}

.dataset-catalog-controls input {
  min-height: 38px;
  width: min(280px, 100%);
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 0 12px;
  background: #ffffff;
}

.dataset-catalog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 12px;
}

.dataset-delivery-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.32fr);
  gap: 16px;
  align-items: end;
  padding: 22px;
  border: 1px solid #d9e4e1;
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(20, 122, 117, 0.1), rgba(255, 255, 255, 0.72) 42%),
    #f8faf8;
}

.dataset-delivery-hero h2 {
  margin: 4px 0 7px;
  font-size: 28px;
}

.dataset-delivery-hero p {
  max-width: 820px;
  line-height: 1.7;
}

.dataset-delivery-hero label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.dataset-delivery-actions,
.dataset-delivery-card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 14px;
}

.button-link.subtle {
  color: var(--muted);
}

.dataset-delivery-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 0.32fr);
  gap: 16px;
  align-items: start;
}

.dataset-delivery-main,
.dataset-delivery-side,
.dataset-delivery-advice,
.dataset-delivery-route {
  min-width: 0;
}

.dataset-delivery-section-head {
  display: flex;
  gap: 12px;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 12px;
}

.dataset-delivery-section-head h3 {
  margin: 3px 0 0;
  font-size: 21px;
}

.dataset-delivery-card-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.dataset-delivery-card,
.dataset-delivery-advice,
.dataset-delivery-route {
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 10px 28px rgba(23, 42, 46, 0.05);
}

.dataset-delivery-card {
  display: grid;
  gap: 13px;
  padding: 16px;
  border-top: 4px solid #96c7bd;
}

.dataset-delivery-card.tone-warn {
  border-top-color: #d9a33d;
}

.dataset-delivery-card.tone-risk {
  border-top-color: #d75f4c;
}

.dataset-delivery-card-head {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  justify-content: space-between;
}

.dataset-delivery-card-head span,
.dataset-delivery-card small,
.dataset-delivery-facts span,
.dataset-delivery-matrix-head span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.dataset-delivery-card-head strong {
  display: block;
  margin-top: 5px;
  font-size: 17px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.dataset-delivery-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.dataset-delivery-facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.dataset-delivery-facts div {
  display: grid;
  gap: 4px;
  min-height: 68px;
  padding: 10px;
  border: 1px solid #e2ebe8;
  border-radius: 7px;
  background: #fbfcfa;
}

.dataset-delivery-facts strong {
  font-size: 20px;
  overflow-wrap: anywhere;
}

.dataset-delivery-side {
  display: grid;
  gap: 12px;
}

.dataset-delivery-advice,
.dataset-delivery-route {
  padding: 16px;
}

.dataset-delivery-advice h3,
.dataset-delivery-route h3 {
  margin: 5px 0 8px;
  font-size: 18px;
}

.dataset-delivery-advice p {
  margin: 0 0 12px;
  color: var(--muted);
  line-height: 1.65;
}

.dataset-delivery-advice-list {
  display: grid;
  gap: 8px;
  margin-bottom: 12px;
}

.dataset-delivery-advice-list a,
.dataset-delivery-advice-list div,
.dataset-delivery-route a {
  display: grid;
  gap: 4px;
  padding: 10px;
  border: 1px solid #e1e9e6;
  border-radius: 7px;
  background: #fbfcfa;
  color: var(--ink);
  text-decoration: none;
}

.dataset-delivery-advice-list small,
.dataset-delivery-route span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.dataset-delivery-route div {
  display: grid;
  gap: 8px;
}

.dataset-delivery-route a.active {
  border-color: rgba(20, 122, 117, 0.45);
  background: #edf7f4;
}

.dataset-delivery-matrix {
  display: grid;
  width: 100%;
  min-width: 0;
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  overflow-x: auto;
}

.dataset-delivery-matrix-head,
.dataset-delivery-matrix-row {
  display: grid;
  min-width: 980px;
  grid-template-columns: minmax(220px, 1.4fr) repeat(var(--delivery-dataset-count, 8), minmax(110px, 1fr));
}

.dataset-delivery-matrix-head {
  background: #eef3ef;
}

.dataset-delivery-matrix-head span,
.dataset-delivery-matrix-row strong,
.dataset-delivery-matrix-row span {
  min-width: 0;
  padding: 10px;
  border-right: 1px solid #dfe8e5;
  border-bottom: 1px solid #dfe8e5;
  overflow-wrap: anywhere;
}

.dataset-delivery-matrix-row span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.dataset-delivery-matrix-row span.covered {
  color: var(--teal-dark);
  background: #edf7f4;
}

.file-processing-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: flex-end;
}

.file-step-tabs {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 16px;
}

.file-step-tabs a {
  min-width: 0;
  padding: 11px;
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  background: #fbfcfa;
  color: var(--ink);
  text-decoration: none;
}

.file-step-tabs a.active,
.file-step-tabs a:hover,
.file-step-tabs a:focus-visible {
  border-color: rgba(20, 122, 117, 0.55);
  background: #edf7f4;
  outline: none;
}

.file-step-tabs span {
  display: block;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.file-step-tabs strong {
  display: block;
  margin-top: 4px;
  overflow-wrap: anywhere;
}

.file-stage-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.dataset-detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(300px, 0.55fr);
  gap: 16px;
  align-items: start;
}

.file-stage-main {
  min-width: 0;
}

.file-stage-head {
  margin-bottom: 14px;
}

.file-stage-head h3 {
  margin: 4px 0;
  font-size: 21px;
}

.file-stage-head p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.file-field-lineage {
  display: grid;
  gap: 12px;
  margin: 16px 0;
  padding: 14px;
  border: 1px solid #d6e5e1;
  border-radius: 8px;
  background: #f8fbfa;
}

.file-field-lineage-disclosure {
  display: block;
}

.file-field-lineage-disclosure summary {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  list-style: none;
}

.file-field-lineage-disclosure summary::-webkit-details-marker {
  display: none;
}

.file-field-lineage-disclosure summary::before {
  content: "展开";
  flex: 0 0 auto;
  order: 2;
  min-width: 44px;
  padding: 5px 9px;
  border: 1px solid #cfe2dc;
  border-radius: 999px;
  background: #ffffff;
  color: var(--teal-dark);
  font-size: 12px;
  font-weight: 900;
  text-align: center;
}

.file-field-lineage-disclosure[open] summary::before {
  content: "收起";
}

.file-field-lineage-disclosure summary:focus-visible {
  outline: 2px solid rgba(20, 122, 117, 0.35);
  outline-offset: 3px;
}

.file-field-lineage-disclosure summary strong {
  display: block;
  margin-bottom: 4px;
  font-size: 16px;
}

.file-field-lineage-disclosure summary small {
  display: block;
  color: var(--muted);
  line-height: 1.45;
}

.file-field-lineage-disclosure .file-field-lineage-table-wrap {
  margin-top: 12px;
}

.file-field-lineage-head {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  justify-content: space-between;
}

.file-field-lineage-head h3 {
  margin: 0 0 4px;
  font-size: 17px;
}

.file-field-lineage-head p {
  margin: 0;
  line-height: 1.6;
}

.file-field-lineage-table-wrap {
  overflow-x: auto;
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  background: #ffffff;
}

.file-field-lineage-table {
  width: 100%;
  min-width: 920px;
  border-collapse: collapse;
}

.file-field-lineage-table th,
.file-field-lineage-table td {
  padding: 11px 12px;
  border-bottom: 1px solid #e6eeeb;
  text-align: left;
  vertical-align: top;
}

.file-field-lineage-table th {
  background: #f2f7f5;
  color: #52676a;
  font-size: 12px;
  font-weight: 900;
}

.file-field-lineage-table tr:last-child td {
  border-bottom: 0;
}

.file-field-lineage-table strong {
  display: block;
  overflow-wrap: anywhere;
  color: var(--ink);
  font-size: 13px;
  line-height: 1.45;
}

.file-field-lineage-table small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  line-height: 1.45;
}

.lineage-status {
  display: inline-flex;
  min-height: 24px;
  align-items: center;
  padding: 3px 8px;
  border-radius: 999px;
  background: #edf7f4;
  color: #246b64;
  font-size: 12px;
  font-weight: 900;
}

.file-extract-entries,
.file-diagnosis-entries,
.file-dataset-output-entries,
.file-merge-entries {
  display: grid;
  gap: 12px;
  margin: 16px 0;
  padding: 14px;
  border: 1px solid #d7e1dc;
  border-radius: 8px;
  background: #fbfcfa;
}

.file-diagnosis-entry-list,
.file-dataset-output-list,
.file-merge-entry-list {
  display: grid;
  gap: 8px;
}

.file-diagnosis-group-list {
  display: grid;
  gap: 12px;
}

.file-diagnosis-group {
  display: grid;
  grid-template-columns: minmax(180px, 0.34fr) minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  padding: 12px;
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  background: #ffffff;
}

.file-diagnosis-group h4 {
  margin: 0;
  color: #18312f;
  font-size: 15px;
  line-height: 1.35;
}

.file-diagnosis-group > span {
  justify-self: start;
  padding: 3px 9px;
  border: 1px solid rgba(20, 122, 117, 0.16);
  border-radius: 999px;
  background: #edf7f4;
  color: #246b64;
  font-size: 12px;
  font-weight: 900;
}

.file-diagnosis-group .file-diagnosis-entry-list {
  grid-column: 1 / -1;
}

.file-extract-table-wrap {
  overflow-x: auto;
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  background: #ffffff;
}

.file-extract-table {
  width: 100%;
  min-width: 980px;
  border-collapse: collapse;
}

.file-extract-table th {
  padding: 11px 12px;
  background: #eef5f2;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-align: left;
}

.file-extract-table td {
  padding: 12px;
  border-top: 1px solid #e8efec;
  vertical-align: top;
}

.file-extract-table strong {
  display: block;
  overflow-wrap: anywhere;
  font-size: 13px;
  line-height: 1.5;
}

.file-extract-table small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  line-height: 1.45;
}

.file-diagnosis-entry,
.file-dataset-output-entry,
.file-merge-entry {
  display: grid;
  grid-template-columns: minmax(120px, 0.7fr) minmax(190px, 1.05fr) minmax(220px, 1.25fr) minmax(190px, 1.05fr);
  gap: 10px;
  padding: 12px;
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  background: #ffffff;
}

.file-diagnosis-entry.is-ok {
  border-color: #83d9ad;
  border-left: 5px solid #12a862;
  background: linear-gradient(90deg, #e8f9ef 0%, #f5fff8 45%, #ffffff 100%);
}

.file-diagnosis-entry.is-warn {
  border-color: #efca6a;
  border-left: 5px solid #d99012;
  background: linear-gradient(90deg, #fff4d8 0%, #fffaf0 45%, #ffffff 100%);
}

.file-diagnosis-entry.is-risk {
  border-color: #ee9d91;
  border-left: 5px solid #d94735;
  background: linear-gradient(90deg, #fff0ee 0%, #fff7f6 45%, #ffffff 100%);
}

.file-diagnosis-entry.clickable-row {
  cursor: pointer;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.file-diagnosis-entry.is-passed strong,
.file-diagnosis-entry.is-ok strong {
  color: #11643d;
}

.file-diagnosis-entry.is-warn strong {
  color: #805106;
}

.file-diagnosis-entry.is-risk strong {
  color: #8f2419;
}

.file-diagnosis-entry.is-ok span,
.file-diagnosis-entry.is-ok small {
  color: #2f7a59;
}

.file-diagnosis-entry.is-warn span,
.file-diagnosis-entry.is-warn small {
  color: #9a690c;
}

.file-diagnosis-entry.is-risk span,
.file-diagnosis-entry.is-risk small {
  color: #a24538;
}

.file-diagnosis-entry.clickable-row:hover,
.file-diagnosis-entry.clickable-row:focus-visible {
  border-color: rgba(20, 122, 117, 0.48);
  box-shadow: 0 12px 26px rgba(50, 91, 116, 0.08);
  outline: none;
  transform: translateY(-1px);
}

.file-diagnosis-entry div,
.file-dataset-output-entry div,
.file-merge-entry div {
  min-width: 0;
}

.file-diagnosis-entry span,
.file-dataset-output-entry span,
.file-merge-entry span {
  display: block;
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.file-diagnosis-entry strong,
.file-dataset-output-entry strong,
.file-merge-entry strong {
  display: block;
  overflow-wrap: anywhere;
  font-size: 13px;
  line-height: 1.5;
}

.file-diagnosis-entry small,
.file-dataset-output-entry small,
.file-merge-entry small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  line-height: 1.45;
}

.lineage-dataset-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.lineage-dataset-links.compact {
  gap: 5px;
}

.lineage-dataset-links a {
  display: inline-flex;
  min-height: 28px;
  align-items: center;
  padding: 4px 8px;
  border: 1px solid #cfe2dc;
  border-radius: 999px;
  background: #edf7f4;
  color: var(--teal-dark);
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
}

.lineage-dataset-links span {
  display: inline-flex;
  min-height: 28px;
  align-items: center;
  padding: 4px 8px;
  border-radius: 999px;
  background: #f3f6f5;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.lineage-dataset-links a:hover,
.lineage-dataset-links a:focus-visible {
  border-color: var(--teal);
  background: #ffffff;
  outline: none;
}

.file-dataset-links {
  display: grid;
  gap: 8px;
}

.file-dataset-links a {
  display: grid;
  gap: 4px;
  padding: 11px;
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  text-decoration: none;
}

.file-dataset-links a:hover,
.file-dataset-links a:focus-visible {
  border-color: rgba(20, 122, 117, 0.55);
  outline: none;
}

.file-dataset-links span,
.field-chip-list span {
  color: var(--muted);
  font-size: 12px;
}

.dataset-source-files {
  display: grid;
  gap: 8px;
}

.dataset-source-files article {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 11px;
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  background: #fbfcfa;
}

.dataset-source-files strong,
.dataset-source-files span,
.dataset-source-files small {
  display: block;
  overflow-wrap: anywhere;
}

.dataset-source-files strong {
  margin-bottom: 4px;
}

.dataset-source-files span,
.dataset-source-files small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.tag-list,
.field-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.field-chip-list span {
  padding: 6px 8px;
  border: 1px solid #dfe8e5;
  border-radius: 999px;
  background: #fbfcfa;
  font-weight: 700;
}

.ingest-flow-foot {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ingest-flow-foot span {
  padding: 6px 9px;
  border: 1px solid #dfe8e5;
  border-radius: 999px;
  background: #fbfcfa;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.ingest-flow-guide {
  position: sticky;
  top: 98px;
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid #dbe5e1;
  border-radius: 8px;
  background: #ffffff;
}

.ingest-flow-guide h3 {
  margin: 0;
}

.flow-guide-actions {
  display: grid;
  gap: 8px;
}

.disabled-link {
  cursor: not-allowed;
  opacity: 0.48;
}

.required-file-list {
  display: grid;
  gap: 10px;
}

.required-file-item {
  display: flex;
  gap: 10px;
  align-items: center;
  min-height: 52px;
  padding: 10px;
  border: 1px solid #e0e8e4;
  border-radius: 8px;
  background: #fbfcfa;
}

.required-file-item > span {
  width: 13px;
  height: 13px;
  flex: 0 0 auto;
  border: 2px solid #bdc9c5;
  border-radius: 999px;
  background: #ffffff;
}

.required-file-item.done {
  border-color: #b9d9d2;
  background: #f1faf7;
}

.required-file-item.done > span {
  border-color: var(--teal);
  background: var(--teal);
}

.required-file-item strong,
.required-file-item small {
  display: block;
}

.required-file-item small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

.file-type-summary {
  grid-column: 1 / -1;
  min-height: auto !important;
}

.merge-conflict-list {
  display: grid;
  gap: 14px;
}

.merge-conflict-card {
  display: grid;
  gap: 14px;
  padding: 16px;
  border: 1px solid #f0c6c0;
  border-radius: 8px;
  background: #fffaf9;
}

.merge-conflict-head {
  display: flex;
  gap: 12px;
  align-items: start;
  justify-content: space-between;
}

.merge-conflict-head h3 {
  margin-bottom: 3px;
  font-size: 18px;
}

.merge-diff-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.merge-diff-item {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid #eedbd8;
  border-radius: 8px;
  background: #ffffff;
}

.merge-diff-item strong {
  color: var(--ink);
}

.merge-diff-item span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.merge-diff-item p {
  margin-bottom: 0;
  overflow-wrap: anywhere;
}

.merge-conflict-actions {
  display: grid;
  grid-template-columns: minmax(180px, 0.45fr) minmax(220px, 1fr) auto;
  gap: 10px;
  align-items: end;
}

.merge-conflict-actions label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.ingest-subpage-head {
  padding: 18px;
  border: 1px solid #d9e4e1;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: var(--shadow);
}

.ingest-subpage-head > div {
  display: grid;
  gap: 10px;
}

.ingest-subpage-head .button-link {
  width: fit-content;
}

.ingest-subpage-head h2 {
  margin-bottom: 0;
  font-size: 24px;
}

.ingest-panel-flat {
  box-shadow: none;
}

.ingest-panel-flat .panel-header {
  padding: 20px 20px 0;
}

.ingest-panel-flat .panel-body {
  padding: 18px 20px 20px;
}

.panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 17px 18px 0;
}

.panel-body {
  padding: 18px;
}

.metric {
  padding: 18px;
}

.metric .label {
  color: var(--muted);
  font-size: 13px;
}

.metric .value {
  margin-top: 8px;
  font-size: 30px;
  font-weight: 800;
}

.metric .hint {
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
}

.table-wrap {
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 760px;
}

th,
td {
  padding: 11px 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
  font-size: 13px;
}

th {
  position: sticky;
  top: 0;
  background: #eef3ef;
  color: #304247;
  font-weight: 800;
}

tr:last-child td {
  border-bottom: 0;
}

.tag,
.status,
.severity {
  display: inline-flex;
  min-height: 24px;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.tag {
  background: #eaf3f1;
  color: var(--teal-dark);
}

.severity.high,
.status.risk {
  background: #fdebe8;
  color: var(--red);
}

.severity.medium {
  background: #fff2dc;
  color: var(--amber);
}

.status.warn {
  background: #fff2dc;
  color: var(--amber);
}

.severity.low,
.status.ok {
  background: #e8f4ed;
  color: var(--green);
}

.status.info {
  background: #e7f0f8;
  color: var(--blue);
}

.steps {
  display: grid;
  gap: 12px;
}

.processing-layout {
  display: grid;
  grid-template-columns: minmax(320px, 0.9fr) minmax(0, 1.5fr);
  gap: 16px;
  align-items: start;
}

.drill-steps {
  position: sticky;
  top: 110px;
}

.step {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 18px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.step-card {
  color: inherit;
  text-decoration: none;
  transition:
    border-color 0.15s ease,
    box-shadow 0.15s ease,
    transform 0.15s ease;
}

.step-card:hover,
.step-card.active {
  border-color: rgba(20, 122, 117, 0.42);
  box-shadow: 0 10px 26px rgba(20, 122, 117, 0.12);
  transform: translateY(-1px);
}

.step-card.active {
  background: #f4fbf9;
}

.step-mini {
  max-height: 118px;
  overflow: hidden;
}

.step-mini .table-wrap {
  border-radius: 6px;
}

.step-mini table {
  min-width: 520px;
}

.step-mini th,
.step-mini td {
  padding: 7px 8px;
  font-size: 12px;
}

.processing-detail {
  min-width: 0;
}

.detail-stack {
  display: grid;
  gap: 20px;
}

.detail-stack section {
  min-width: 0;
}

.detail-stack h3 {
  margin-bottom: 10px;
}

.step-name {
  font-weight: 800;
}

.step-status {
  margin-top: 8px;
}

.processing-overview-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 0.45fr);
  gap: 18px;
  align-items: stretch;
  padding: 22px;
  border: 1px solid #d9e4e1;
  border-radius: 8px;
  background: #f8faf8;
}

.processing-hero-copy {
  display: grid;
  align-content: center;
  gap: 8px;
}

.processing-hero-copy h2 {
  max-width: 820px;
  margin-bottom: 0;
  font-size: 25px;
}

.processing-batch-switch {
  display: grid;
  gap: 12px;
  align-content: center;
  padding: 16px;
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  background: #ffffff;
}

.processing-batch-switch label,
.processing-step-hero label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.processing-file-lanes-panel {
  display: grid;
  gap: 16px;
  padding: 20px;
  border: 1px solid #d4e3df;
  border-radius: 8px;
  background: #ffffff;
}

.processing-file-lanes-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 0.42fr);
  gap: 18px;
  align-items: start;
}

.processing-file-lanes-head h2 {
  margin-bottom: 6px;
  font-size: 22px;
}

.processing-file-lanes-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  min-width: 0;
}

.processing-file-lanes-summary > div {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  grid-template-areas:
    "value label"
    "value hint";
  gap: 1px 7px;
  align-items: baseline;
  min-width: 0;
  padding: 9px 12px;
}

.processing-file-lanes-summary strong {
  grid-area: value;
  color: #13242a;
  font-size: 18px;
  line-height: 1;
  white-space: nowrap;
}

.processing-file-lanes-summary span {
  grid-area: label;
  min-width: 0;
  color: #213942;
  font-size: 12px;
  font-weight: 900;
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.processing-file-lanes-summary small {
  grid-area: hint;
  min-width: 0;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.processing-file-lane-list {
  display: grid;
  gap: 10px;
}

.processing-file-workspace {
  background: linear-gradient(180deg, #ffffff 0%, #f7faf9 100%);
}

.processing-file-workspace-body {
  display: grid;
  grid-template-columns: minmax(260px, 320px) minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  width: 100%;
  max-width: 100%;
  min-height: 0;
  min-width: 0;
}

.processing-file-selector-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: min(68vh, 760px);
  overflow-y: auto;
  padding-right: 4px;
}

.processing-file-selector {
  position: relative;
  display: flex;
  flex-direction: column;
  flex: 0 0 auto;
  gap: 5px;
  width: 100%;
  height: auto;
  min-height: 0;
  padding: 11px 12px 12px;
  overflow: visible;
  box-sizing: border-box;
  border: 1px solid #e1e9e6;
  border-radius: 8px;
  background: #fbfcfa;
  color: var(--ink);
  cursor: pointer;
  text-align: left;
  transition:
    border-color 160ms ease,
    background 160ms ease,
    transform 160ms ease;
}

.processing-file-selector:hover,
.processing-file-selector:focus-visible,
.processing-file-selector.active {
  border-color: #8ab8af;
  background: #f0f8f5;
  outline: none;
}

.processing-file-selector:focus-visible {
  box-shadow: 0 0 0 4px rgba(17, 167, 162, 0.14);
}

.processing-file-selector.active {
  box-shadow: inset 3px 0 0 var(--teal);
}

.processing-file-selector-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  min-width: 0;
  align-items: flex-start;
  gap: 8px;
}

.processing-file-selector strong {
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
  font-size: 13px;
  line-height: 1.35;
}

.processing-file-selector > span:not(.processing-file-selector-head),
.processing-file-selector small {
  display: block;
  min-width: 0;
  max-width: 100%;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
  overflow-wrap: anywhere;
  overflow: visible;
  white-space: normal;
  word-break: break-word;
}

.processing-file-selector small {
  display: block;
}

.processing-file-selector em {
  display: inline-flex;
  flex: 0 0 auto;
  min-width: 0;
  align-items: center;
  justify-self: end;
  padding: 1px 6px;
  border-radius: 999px;
  background: #fff3ed;
  color: #a6421a;
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
}

.processing-file-lane-panel[hidden] {
  display: none;
}

.processing-file-scroll {
  width: 100%;
  max-height: none;
  min-width: 0;
  max-width: 100%;
  overflow: visible;
  overflow-x: hidden;
  padding: 12px;
}

.processing-file-scroll .ingest-flow-lane {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  grid-template-columns: 1fr;
  align-items: start;
  box-shadow: none;
}

.processing-file-scroll .ingest-flow-lane-body {
  display: grid;
  /* legacy contract text: grid-template-columns: minmax(240px, 0.72fr) minmax(260px, 1fr) */
  grid-template-columns: 1fr;
  gap: 14px;
  align-items: stretch;
  min-width: 0;
  max-width: 100%;
}

.processing-file-scroll .ingest-flow-file {
  display: none;
}

.processing-file-scroll .ingest-flow-track {
  position: relative;
  grid-template-columns: 1fr;
  align-content: start;
  gap: 12px;
  min-width: 0;
  max-width: 100%;
  padding-left: 24px;
}

.processing-file-scroll .ingest-flow-track::after {
  position: absolute;
  top: 34px;
  bottom: 12px;
  left: 8px;
  width: 2px;
  border-radius: 999px;
  background: #d7e5e0;
  content: "";
}

.processing-file-scroll .ingest-flow-track::before {
  display: block;
  justify-self: center;
  min-width: 132px;
  margin: -2px 0 2px -24px;
  padding: 4px 14px;
  border-bottom: 2px solid rgba(17, 167, 162, 0.28);
  color: var(--teal-dark);
  font-size: 18px;
  font-weight: 900;
  line-height: 1.15;
  text-align: center;
}

.processing-file-scroll .ingest-flow-track::before {
  content: "治理链路";
}

.processing-file-scroll .ingest-flow-node {
  z-index: 1;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  min-height: 76px;
  padding: 13px 14px;
  overflow: visible;
}

.processing-file-scroll .ingest-flow-node span {
  color: #2b6f70;
  font-size: 14px;
  font-weight: 900;
  line-height: 1.25;
}

.processing-file-scroll .ingest-flow-node strong {
  min-width: 0;
  margin-top: 1px;
  color: #0f252b;
  font-size: 17px;
  line-height: 1.35;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.processing-file-scroll .ingest-flow-node small {
  min-width: 0;
  color: #657a83;
  font-size: 13px;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.processing-file-scroll .ingest-flow-node::before {
  position: absolute;
  top: 50%;
  left: -22px;
  width: 10px;
  height: 10px;
  border: 2px solid #8ab8af;
  border-radius: 999px;
  background: #ffffff;
  content: "";
  transform: translateY(-50%);
}

.processing-file-scroll .ingest-flow-node::after {
  display: none;
}

.processing-lane-ai-summary {
  position: relative;
  display: grid;
  align-content: start;
  gap: 10px;
  min-height: 100%;
  padding: 12px 150px 12px 12px;
  border: 1px solid #c9e3dd;
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(242, 252, 248, 0.98), rgba(255, 255, 255, 0.95)),
    #ffffff;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.72),
    0 14px 26px rgba(50, 91, 116, 0.08);
}

.processing-lane-ai-summary::after {
  position: absolute;
  top: 24px;
  right: 30px;
  width: 96px;
  height: 96px;
  border: 1px solid rgba(17, 167, 162, 0.22);
  border-radius: 50%;
  background:
    radial-gradient(circle at 48% 48%, rgba(255, 255, 255, 0.72), transparent 42%),
    conic-gradient(from 215deg, rgba(50, 209, 190, 0.16), rgba(84, 135, 255, 0.22), rgba(139, 108, 255, 0.13), rgba(50, 209, 190, 0.16));
  box-shadow:
    inset 0 0 24px rgba(255, 255, 255, 0.9),
    0 18px 34px rgba(42, 114, 255, 0.12);
  content: "";
  animation: aiMascotHalo 8s linear infinite;
}

.ai-summary-mascot {
  position: absolute;
  top: 32px;
  right: 22px;
  z-index: 1;
  width: 112px;
  height: 132px;
  pointer-events: none;
  animation: officerFloat 4s ease-in-out infinite;
}

.ai-mascot-head {
  position: absolute;
  top: 18px;
  right: 20px;
  width: 70px;
  height: 54px;
  border: 1px solid rgba(33, 199, 168, 0.28);
  border-radius: 30px;
  background:
    radial-gradient(circle at 50% 75%, rgba(255, 255, 255, 0.72) 0 22%, transparent 23%),
    linear-gradient(180deg, #ffffff, #dff8fb);
  box-shadow:
    inset 0 -12px 20px rgba(42, 114, 255, 0.08),
    0 18px 28px rgba(39, 121, 158, 0.17);
}

.ai-mascot-head::before {
  position: absolute;
  inset: 9px 14px;
  height: auto;
  border-radius: 22px;
  background: #15334e;
  content: "";
}

.ai-mascot-head::after {
  position: absolute;
  top: -12px;
  left: 50%;
  width: 3px;
  height: 12px;
  border-radius: 999px;
  background: #8fd6c4;
  box-shadow:
    0 -6px 0 3px rgba(143, 214, 196, 0.8),
    0 -6px 0 9px rgba(143, 214, 196, 0.18);
  content: "";
  transform: translateX(-50%);
}

.ai-mascot-head i {
  position: absolute;
  top: 24px;
  z-index: 1;
  width: 10px;
  height: 16px;
  border-radius: 12px;
  background: #53f2ff;
  box-shadow: 0 0 14px rgba(53, 241, 255, 0.72);
  animation: aiMascotBlink 4.8s ease-in-out infinite;
}

.ai-mascot-head i:first-child {
  left: 24px;
}

.ai-mascot-head i:last-child {
  right: 24px;
}

.ai-mascot-body {
  position: absolute;
  top: 76px;
  right: 32px;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(33, 199, 168, 0.24);
  border-radius: 24px 24px 30px 30px;
  background: linear-gradient(180deg, #ffffff, #e9fbff);
  box-shadow: 0 18px 30px rgba(42, 114, 255, 0.12);
}

.ai-mascot-body::after {
  position: absolute;
  top: 15px;
  left: 50%;
  width: 16px;
  height: 16px;
  border: 4px solid #92f3df;
  border-radius: 999px;
  background: transparent;
  content: "";
  transform: translateX(-50%);
}

.ai-mascot-arm {
  position: absolute;
  top: 82px;
  right: 18px;
  width: 18px;
  height: 46px;
  border: 1px solid rgba(33, 199, 168, 0.22);
  border-radius: 16px;
  background: linear-gradient(180deg, #ffffff, #dff8fb);
  box-shadow: 0 12px 22px rgba(39, 121, 158, 0.12);
  transform: rotate(-12deg);
  transform-origin: top center;
}

.ai-mascot-arm::after {
  position: absolute;
  top: 0;
  right: 76px;
  width: 18px;
  height: 46px;
  border: 1px solid rgba(33, 199, 168, 0.22);
  border-radius: 16px;
  background: linear-gradient(180deg, #ffffff, #dff8fb);
  box-shadow: 0 12px 22px rgba(39, 121, 158, 0.12);
  content: "";
  transform: rotate(24deg);
}

.ai-summary-title {
  display: block;
  justify-self: center;
  min-width: 132px;
  margin: -2px 0 2px;
  padding: 4px 14px;
  border-bottom: 2px solid rgba(17, 167, 162, 0.28);
  color: var(--teal-dark);
  font-size: 18px;
  font-weight: 900;
  line-height: 1.15;
  text-align: center;
}

.processing-lane-ai-summary p {
  margin: 0;
  color: #4e626b;
  font-size: 13px;
  line-height: 1.7;
}

.ai-summary-copy {
  display: grid;
  gap: 12px;
  padding: 14px 14px 12px;
  padding-right: 96px;
  border-radius: 10px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.86), rgba(239, 251, 247, 0.68)),
    rgba(255, 255, 255, 0.72);
}

.ai-summary-copy > strong {
  color: #2d7480;
  font-size: 16px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.ai-summary-copy p {
  color: #263940;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.85;
}

.ai-summary-copy b {
  color: #0d6f70;
  font-weight: 900;
}

.ai-summary-copy em {
  padding: 2px 6px;
  border-radius: 6px;
  background: #fff2ea;
  color: #ad4c20;
  font-style: normal;
  font-weight: 900;
}

.ai-summary-copy mark {
  padding: 2px 6px;
  border-radius: 6px;
  background: #e8f7f2;
  color: #126f6e;
  font-weight: 900;
}

.ai-summary-action {
  display: grid;
  gap: 6px;
  padding: 12px 14px;
  border-color: #bde6dc;
  border-radius: 10px;
  background:
    linear-gradient(135deg, rgba(236, 251, 246, 0.98), rgba(246, 252, 250, 0.94)),
    #ecfbf6;
}

.ai-summary-action span {
  color: var(--teal-dark);
  font-size: 13px;
  font-weight: 900;
}

.ai-summary-action strong {
  color: #142b31;
  font-size: 14px;
  line-height: 1.55;
}

.document-trace-studio {
  display: grid;
  gap: 14px;
  padding: 16px;
  border: 1px solid #cbded8;
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(251, 252, 250, 0.96), rgba(242, 248, 246, 0.92)),
    #ffffff;
  box-shadow: 0 14px 32px rgba(20, 60, 64, 0.08);
}

.document-trace-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: start;
}

.document-trace-hero h3 {
  margin: 4px 0;
  color: #10282b;
  font-size: 24px;
  line-height: 1.2;
}

.document-trace-hero p {
  margin: 0;
  color: var(--muted);
}

.document-trace-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.document-trace-badges span {
  min-height: 30px;
  padding: 7px 10px;
  border: 1px solid #d7e5e0;
  border-radius: 999px;
  background: #ffffff;
  color: #284347;
  font-size: 12px;
  font-weight: 900;
}

.document-trace-flow {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.document-trace-step {
  position: relative;
  min-height: 62px;
  padding: 10px 12px;
  border: 1px solid #d8e7e2;
  border-radius: 8px;
  background: #ffffff;
}

.document-trace-step::after {
  position: absolute;
  top: 50%;
  right: -9px;
  width: 9px;
  height: 2px;
  background: #b7c9c4;
  content: "";
}

.document-trace-step:last-child::after {
  display: none;
}

.document-trace-step span {
  display: block;
  color: #5f7476;
  font-size: 11px;
  font-weight: 900;
}

.document-trace-step strong {
  display: block;
  margin-top: 6px;
  color: #10282b;
  font-size: 14px;
  line-height: 1.35;
}

.document-trace-step.tone-warn {
  border-color: #edc987;
  background: #fff8e8;
}

.document-trace-grid {
  display: grid;
  grid-template-columns: minmax(280px, 0.86fr) minmax(320px, 1.04fr) minmax(260px, 0.62fr);
  gap: 14px;
  align-items: stretch;
}

.document-paper-preview,
.document-field-board,
.document-outcome-rail {
  min-width: 0;
}

.document-paper-preview {
  display: grid;
  grid-template-rows: auto 1fr;
  border: 1px solid #d7e4df;
  border-radius: 8px;
  background: #f4f7f5;
  overflow: hidden;
}

.document-paper-toolbar {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  padding: 11px 12px;
  border-bottom: 1px solid #d7e4df;
  background: #ffffff;
}

.document-paper-toolbar strong {
  color: #10282b;
}

.document-paper-toolbar span {
  max-width: 55%;
  overflow: hidden;
  color: var(--muted);
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.document-paper {
  display: grid;
  gap: 10px;
  padding: 12px;
  background:
    linear-gradient(90deg, rgba(16, 40, 43, 0.04) 1px, transparent 1px),
    #f7faf8;
  background-size: 18px 18px;
}

.document-page-section {
  padding: 12px;
  border: 1px solid #e0e7e4;
  border-radius: 6px;
  background: #ffffff;
}

.document-page-section span {
  color: #8a5a2b;
  font-size: 11px;
  font-weight: 900;
}

.document-page-section strong {
  display: block;
  margin: 4px 0;
  color: #10282b;
}

.document-page-section p {
  margin: 0;
  color: #40575a;
  font-size: 13px;
  line-height: 1.7;
}

.document-page-section mark {
  padding: 1px 4px;
  border-radius: 4px;
  background: #ffe3a3;
  color: #263b3e;
}

.document-field-board {
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 10px;
}

.document-column-head {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
}

.document-column-head strong {
  color: #10282b;
  font-size: 14px;
}

.document-field-list {
  display: grid;
  gap: 8px;
  align-content: start;
}

.document-field-card {
  display: grid;
  grid-template-columns: minmax(88px, 0.45fr) minmax(0, 1fr);
  gap: 6px 10px;
  padding: 10px 12px;
  border: 1px solid #d9e6e1;
  border-radius: 8px;
  background: #ffffff;
  color: inherit;
  text-decoration: none;
  transition:
    border-color 160ms ease,
    box-shadow 160ms ease,
    transform 160ms ease;
}

.document-field-card:hover,
.document-field-card:focus-visible {
  border-color: rgba(20, 122, 117, 0.55);
  box-shadow: 0 10px 20px rgba(20, 122, 117, 0.12);
  outline: none;
  transform: translateY(-1px);
}

.document-field-card span {
  color: #607477;
  font-size: 12px;
  font-weight: 900;
}

.document-field-card strong {
  min-width: 0;
  overflow-wrap: anywhere;
  color: #10282b;
  font-size: 15px;
}

.document-field-card small {
  color: #8a5a2b;
  font-weight: 800;
}

.document-field-card em {
  color: #5f7476;
  font-size: 12px;
  font-style: normal;
}

.document-outcome-rail {
  display: grid;
  gap: 10px;
  align-content: start;
}

.document-score-card,
.document-risk-card,
.document-dataset-stack {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid #d8e5e1;
  border-radius: 8px;
  background: #ffffff;
}

.document-score-card {
  background: #10282b;
  color: #f7fbfa;
}

.document-score-card span,
.document-risk-card > span,
.document-dataset-stack > span {
  font-size: 12px;
  font-weight: 900;
}

.document-score-card strong {
  font-size: 42px;
  line-height: 1;
}

.document-score-card small {
  color: rgba(247, 251, 250, 0.72);
}

.document-risk-card article {
  padding: 9px;
  border-radius: 6px;
  background: #fff5ed;
}

.document-risk-card strong,
.document-dataset-stack strong {
  display: block;
  color: #10282b;
  line-height: 1.4;
}

.document-risk-card small,
.document-risk-card p,
.document-dataset-stack small {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.document-dataset-stack a {
  padding: 9px;
  border: 1px solid #dce8e4;
  border-radius: 6px;
  color: inherit;
  text-decoration: none;
}

.document-dataset-stack a:hover,
.document-dataset-stack a:focus-visible {
  border-color: rgba(20, 122, 117, 0.55);
  outline: none;
}

.document-trace-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.document-extraction-workbench {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(244, 249, 248, 0.96)),
    #ffffff;
}

.document-extraction-grid {
  display: grid;
  grid-template-columns: minmax(420px, 1.1fr) minmax(360px, 0.9fr);
  gap: 14px;
  align-items: stretch;
  min-height: 620px;
}

.document-extraction-grid .document-paper-preview,
.document-extraction-grid .document-field-board {
  min-width: 0;
}

.document-extraction-grid .document-paper-preview {
  background: #eef4f2;
}

.document-extraction-grid .document-paper {
  max-height: 660px;
  overflow: auto;
  padding: 18px;
}

.document-paper-toolbar > div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.document-paper-toolbar small {
  overflow: hidden;
  color: var(--muted);
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.document-page-section {
  box-shadow: 0 8px 24px rgba(22, 52, 58, 0.06);
}

.document-page-section-head {
  display: flex;
  gap: 10px;
  align-items: baseline;
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid #eef2f0;
}

.document-source-lines {
  display: grid;
  gap: 7px;
}

.document-source-line {
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr);
  gap: 8px;
  margin: 0;
  padding: 6px 8px;
  border: 1px solid transparent;
  border-radius: 6px;
  color: #30484b;
  font-size: 13px;
  line-height: 1.75;
  transition:
    background 160ms ease,
    border-color 160ms ease,
    box-shadow 160ms ease;
}

.document-source-table-row {
  display: grid;
  grid-template-columns: 26px repeat(auto-fit, minmax(78px, 1fr));
  gap: 0;
  overflow: hidden;
  border: 1px solid #d7e3df;
  border-radius: 6px;
  background: #ffffff;
  transition:
    background 160ms ease,
    border-color 160ms ease,
    box-shadow 160ms ease;
}

.document-source-table-row + .document-source-table-row {
  margin-top: -2px;
}

.document-source-table-row > span {
  min-width: 0;
  padding: 8px;
  border-left: 1px solid #e3ebe8;
  color: #31484b;
  font-size: 12px;
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.document-anchor-stack {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  min-height: 22px;
}

.document-anchor-marker {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: 999px;
  background: #147a75;
  color: #ffffff;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
}

.document-source-line.has-anchor,
.document-source-table-row.has-anchor {
  border-color: rgba(20, 122, 117, 0.22);
  background: rgba(236, 248, 246, 0.54);
}

.document-source-line.active,
.document-source-table-row.active {
  border-color: rgba(20, 122, 117, 0.72);
  background: #fff7df;
  box-shadow: 0 0 0 3px rgba(244, 188, 75, 0.2);
}

.document-source-line mark,
.document-source-table-row mark {
  padding: 1px 4px;
  border-radius: 4px;
  background: #ffe08a;
  color: #10282b;
  font-weight: 900;
}

.document-extract-form {
  max-height: none;
  overflow: visible;
  padding-right: 2px;
}

.document-extract-form .document-field-card {
  position: relative;
  grid-template-areas:
    "index label value score"
    "index label source source"
    "index label target target";
  grid-template-columns: 34px minmax(104px, 0.28fr) minmax(0, 1fr) minmax(42px, auto);
  grid-auto-rows: min-content;
  align-items: start;
  gap: 7px 12px;
  width: 100%;
  min-height: auto;
  border-color: #d8e6e2;
  text-align: left;
  cursor: pointer;
  overflow: visible;
  white-space: normal;
}

.document-extract-form .document-field-card.active {
  border-color: rgba(20, 122, 117, 0.72);
  background: linear-gradient(90deg, rgba(236, 248, 246, 0.98), #ffffff);
  box-shadow: 0 12px 26px rgba(20, 122, 117, 0.13);
}

.document-field-index {
  grid-area: index;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  margin-top: 2px;
  border-radius: 999px;
  background: #147a75;
  color: #ffffff !important;
  font-size: 12px !important;
  font-weight: 900;
}

.document-field-label {
  grid-area: label;
  padding-top: 4px;
  color: #53696c !important;
  line-height: 1.45;
}

.document-extract-form .document-field-card strong {
  grid-area: value;
  min-width: 0;
  overflow: visible;
  overflow-wrap: anywhere;
  white-space: normal;
  line-height: 1.45;
}

.document-extract-form .document-field-card small {
  grid-area: source;
  min-width: 0;
  overflow-wrap: anywhere;
  line-height: 1.45;
}

.document-extract-form .document-field-card em {
  grid-area: target;
  min-width: 0;
  overflow-wrap: anywhere;
  line-height: 1.45;
}

.document-extract-form .document-field-card b {
  grid-area: score;
  align-self: start;
  justify-self: end;
  color: #147a75;
  font-size: 12px;
  line-height: 1.45;
}

.document-workbench-foot {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.document-workbench-foot div {
  display: grid;
  gap: 4px;
  padding: 10px;
  border: 1px solid #dce8e4;
  border-radius: 8px;
  background: #ffffff;
}

.document-workbench-foot span {
  color: #687b7e;
  font-size: 11px;
  font-weight: 900;
}

.document-workbench-foot strong {
  color: #10282b;
  font-size: 16px;
}

.document-risk-card.compact {
  max-height: 150px;
  overflow: auto;
}

.processing-batch-strip {
  display: grid;
  grid-template-columns: minmax(260px, 0.3fr) minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 14px 16px;
  border: 1px solid #d8e5e1;
  border-radius: 8px;
  background: #fbfcfa;
}

.processing-batch-strip > div:first-child {
  display: grid;
  gap: 3px;
}

.processing-batch-strip strong {
  font-size: 16px;
}

.processing-batch-strip small {
  color: var(--muted);
  line-height: 1.45;
}

.processing-batch-strip-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.processing-batch-strip-links a {
  display: inline-flex;
  min-height: 32px;
  align-items: center;
  padding: 6px 10px;
  border: 1px solid #d8e5e1;
  border-radius: 999px;
  background: #ffffff;
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
}

.processing-batch-strip-links a:hover,
.processing-batch-strip-links a:focus-visible {
  border-color: #8ab8af;
  background: #f0f8f5;
  outline: none;
}

.processing-step-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  align-items: start;
}

.processing-panel-flat {
  box-shadow: none;
}

.processing-step-hero {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto minmax(300px, 0.35fr);
  gap: 16px;
  align-items: center;
  padding: 18px;
  border: 1px solid #d9e4e1;
  border-radius: 8px;
  background: #f8faf8;
}

.processing-step-title h2 {
  margin-bottom: 6px;
  font-size: 24px;
}

.file-preview-title-trigger {
  display: inline;
  max-width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}

.file-preview-title-trigger:hover,
.file-preview-title-trigger:focus-visible {
  color: var(--teal-dark);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.file-preview-title-trigger:focus-visible {
  outline: 2px solid rgba(20, 122, 117, 0.45);
  outline-offset: 4px;
  border-radius: 4px;
}

.processing-stage-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.processing-stage-nav a {
  min-height: 38px;
  padding: 9px 12px;
  border: 1px solid #dfe8e5;
  border-radius: 7px;
  background: #ffffff;
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
}

.processing-stage-nav a.active {
  border-color: var(--teal);
  background: #edf7f4;
  color: var(--teal-dark);
}

.processing-conclusion {
  display: grid;
  gap: 14px;
}

.processing-conclusion p {
  line-height: 1.7;
}

.processing-conclusion-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.processing-conclusion-grid div {
  display: grid;
  gap: 3px;
  min-height: 82px;
  padding: 12px;
  border: 1px solid #e0e8e4;
  border-radius: 8px;
  background: #fbfcfa;
}

.processing-conclusion-grid strong {
  font-size: 23px;
}

.processing-conclusion-grid span {
  font-weight: 700;
}

.processing-conclusion-grid small {
  color: var(--muted);
}

.processing-transparent-flow {
  display: grid;
  gap: 12px;
}

.processing-flow-main {
  display: grid;
  grid-template-columns: minmax(260px, 0.72fr) minmax(0, 1.85fr);
  gap: 16px;
  align-items: stretch;
}

.processing-output-stage {
  display: grid;
  gap: 14px;
  min-width: 0;
  padding: 16px;
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  background: #fbfcfa;
}

.result-card-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.processing-output-head {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  justify-content: space-between;
}

.processing-output-head h3 {
  margin: 0 0 3px;
  font-size: 17px;
}

.processing-output-head p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.processing-output-head span {
  flex: 0 0 auto;
  color: var(--teal-dark);
  font-size: 12px;
  font-weight: 900;
}

.processing-process-note {
  display: flex;
  gap: 10px;
  align-items: center;
  min-width: 0;
  padding: 9px 12px;
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  background: #f6faf8;
  color: var(--muted);
}

.processing-process-note strong {
  flex: 0 0 auto;
  color: var(--teal-dark);
  font-size: 12px;
}

.processing-process-note span {
  overflow: hidden;
  min-width: 0;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
}

.processing-flow-lane {
  position: relative;
  display: grid;
  gap: 14px;
  min-width: 0;
  padding: 16px;
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  background: #fbfcfa;
}

.processing-flow-lane::after {
  position: absolute;
  top: 34px;
  right: -17px;
  width: 17px;
  height: 2px;
  background: #bfd0cc;
  content: "";
}

.processing-flow-lane:last-child::after {
  display: none;
}

.processing-flow-lane.process {
  background: #f5faf9;
}

.flow-lane-head {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
}

.flow-lane-head > span {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  border: 3px solid #a7c8c2;
  border-radius: 999px;
  background: #fff;
}

.processing-flow-lane.process .flow-lane-head > span {
  border-color: var(--teal);
  background: var(--teal);
  box-shadow: 0 0 0 6px rgba(20, 122, 117, 0.08);
  animation: pulseDot 1500ms ease-in-out infinite;
}

.flow-lane-head h3 {
  margin: 0 0 3px;
  font-size: 16px;
}

.flow-lane-head p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.flow-card-list,
.action-card-list,
.evidence-card-list {
  display: grid;
  gap: 10px;
}

.flow-card,
.action-card,
.evidence-card,
.result-card {
  min-width: 0;
  padding: 13px;
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  background: #ffffff;
  animation: pipelineEnter 320ms ease both;
  animation-delay: calc(var(--trace-index, 0) * 55ms);
}

.flow-card strong,
.action-card strong,
.evidence-card strong,
.result-card strong {
  display: block;
  overflow-wrap: anywhere;
}

.flow-card p,
.action-card p,
.evidence-card p,
.result-card p {
  margin: 6px 0 0;
  color: var(--muted);
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.flow-card small,
.evidence-card small,
.operation-card small {
  display: block;
  margin-top: 7px;
  color: var(--muted);
  line-height: 1.5;
}

.flow-card.tone-ok {
  border-color: #cfe3dc;
  background: #f6fbf8;
}

.flow-card.tone-warn {
  border-color: #ead9b4;
  background: #fffaf0;
}

.flow-card.tone-risk {
  border-color: #efcbc7;
  background: #fff6f4;
}

.result-card {
  display: grid;
  gap: 12px;
  background: #ffffff;
}

.result-card.tone-ok {
  border-color: #cfe3dc;
  background: #fbfefd;
}

.result-card.tone-warn {
  border-color: #ead9b4;
  background: #fffaf0;
}

.result-card.tone-risk {
  border-color: #efcbc7;
  background: #fff6f4;
}

.result-card[data-processing-drill="typical-case-bid-document"] {
  border-color: #b9d8d2;
  background: #f7fbfa;
}

.result-card-main strong {
  font-size: 16px;
}

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

.result-lineage div {
  min-width: 0;
  padding: 8px;
  border: 1px solid #e4ebe8;
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.72);
}

.result-lineage span,
.result-lineage em {
  display: block;
}

.result-lineage span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.result-lineage em {
  margin-top: 4px;
  color: var(--ink);
  font-size: 12px;
  font-style: normal;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.drill-card {
  cursor: pointer;
  transition:
    border-color 160ms ease,
    box-shadow 160ms ease,
    transform 160ms ease;
}

.drill-card:hover,
.drill-card:focus-visible {
  border-color: rgba(20, 122, 117, 0.55);
  box-shadow: 0 12px 24px rgba(20, 122, 117, 0.12);
  outline: none;
  transform: translateY(-1px);
}

.drill-cue {
  display: inline-flex;
  width: fit-content;
  min-height: 26px;
  align-items: center;
  margin-top: 10px;
  padding: 3px 8px;
  border-radius: 999px;
  background: #edf7f4;
  color: var(--teal-dark);
  font-size: 12px;
  font-weight: 800;
}

.operation-card {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 10px;
}

.operation-index {
  display: inline-grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 999px;
  background: var(--teal);
  color: #fff;
  font-size: 13px;
  font-weight: 800;
}

.action-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

.evidence-card small {
  padding-top: 8px;
  border-top: 1px solid #e6eeeb;
}

.review-explain-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.review-explain-grid div {
  min-width: 0;
  padding: 10px;
  border: 1px solid #e0e8e4;
  border-radius: 8px;
  background: #ffffff;
}

.lineage-stage-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 14px 0;
}

.lineage-stage-strip article {
  min-width: 0;
  padding: 11px;
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  background: #ffffff;
}

.lineage-stage-strip article.active {
  border-color: rgba(20, 122, 117, 0.55);
  background: #edf7f4;
}

.lineage-stage-strip span,
.field-lineage-list span {
  display: block;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.lineage-stage-strip strong,
.field-lineage-list strong {
  display: block;
  margin-top: 4px;
  overflow-wrap: anywhere;
}

.lineage-stage-strip p,
.field-lineage-list p {
  margin: 6px 0 0;
  color: var(--muted);
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.field-lineage-list {
  display: grid;
  gap: 12px;
}

.field-lineage-list article {
  display: grid;
  grid-template-columns: 1.25fr 0.75fr 1fr 0.8fr;
  gap: 10px;
  padding: 12px;
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  background: #fbfcfa;
}

.field-lineage-list article > div {
  min-width: 0;
  padding-right: 10px;
  border-right: 1px solid #e4ebe8;
}

.field-lineage-list article > div:last-child {
  padding-right: 0;
  border-right: 0;
}

.review-explain-grid span,
.review-explain-grid strong {
  display: block;
}

.review-explain-grid span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.review-explain-grid strong {
  margin-top: 4px;
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.drawer-open {
  overflow: hidden;
}

.drill-layer[hidden] {
  display: none;
}

.drill-layer {
  position: fixed;
  z-index: 1000;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(420px, 520px);
}

.drill-backdrop {
  width: 100%;
  height: 100%;
  min-height: 0;
  border: 0;
  border-radius: 0;
  background: rgba(16, 35, 38, 0.28);
  cursor: default;
}

.drill-drawer {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  width: 100%;
  height: 100dvh;
  border-left: 1px solid #d4e0dc;
  background: #fbfcfa;
  box-shadow: -18px 0 40px rgba(29, 45, 51, 0.16);
  animation: drawerIn 180ms ease both;
}

.drill-head {
  display: flex;
  gap: 14px;
  align-items: start;
  justify-content: space-between;
  padding: 22px 22px 16px;
  border-bottom: 1px solid #dfe8e5;
  background: #ffffff;
}

.drill-head h2 {
  margin-bottom: 0;
  font-size: 22px;
}

.drill-body {
  display: grid;
  align-content: start;
  gap: 14px;
  min-width: 0;
  overflow: auto;
  padding: 18px 22px 24px;
}

.record-preview-layer[hidden] {
  display: none;
}

.record-preview-layer {
  position: fixed;
  z-index: 1010;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 36px;
}

.record-preview-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  border-radius: 0;
  background: rgba(16, 35, 38, 0.32);
}

.record-preview-dialog {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  width: min(1480px, calc(100vw - 72px));
  max-height: calc(100dvh - 72px);
  border: 1px solid #d4e0dc;
  border-radius: 10px;
  background: #fbfcfa;
  box-shadow: 0 28px 70px rgba(29, 45, 51, 0.22);
  overflow: hidden;
}

.record-preview-head {
  display: flex;
  gap: 14px;
  align-items: start;
  justify-content: space-between;
  padding: 20px 22px 14px;
  border-bottom: 1px solid #dfe8e5;
  background: #ffffff;
}

.record-preview-head h2 {
  margin-bottom: 0;
  font-size: 22px;
}

.record-preview-body {
  display: grid;
  align-content: start;
  gap: 14px;
  min-width: 0;
  overflow: auto;
  padding: 18px 22px 24px;
}

.record-preview-body .table-wrap {
  max-width: 100%;
  overflow: auto;
}

.file-preview-modal-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.file-preview-modal-meta > div {
  display: grid;
  gap: 4px;
  min-width: 0;
  padding: 12px;
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  background: #ffffff;
}

.file-preview-modal-meta strong {
  display: block;
  overflow-wrap: anywhere;
  color: var(--ink);
  font-size: 20px;
  line-height: 1.2;
}

.file-preview-modal-meta span {
  display: block;
  color: var(--ink);
  font-size: 13px;
  font-weight: 900;
  line-height: 1.35;
}

.file-preview-modal-meta small {
  display: block;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.file-diagnosis-drawer-grid {
  display: grid;
  gap: 10px;
}

.file-diagnosis-drawer-grid div {
  display: grid;
  gap: 5px;
  padding: 12px;
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  background: #fbfcfa;
}

.file-diagnosis-drawer-grid span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.file-diagnosis-drawer-grid strong {
  overflow-wrap: anywhere;
  line-height: 1.55;
}

.file-diagnosis-drawer-grid small {
  color: var(--muted);
  line-height: 1.45;
}

.drill-card-list {
  display: grid;
  gap: 12px;
}

.drill-detail-card {
  min-width: 0;
  padding: 14px;
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  background: #ffffff;
}

.drill-detail-card strong {
  display: block;
  overflow-wrap: anywhere;
}

.drill-detail-card p {
  margin: 7px 0 0;
  color: var(--muted);
  line-height: 1.55;
  overflow-wrap: anywhere;
}

@keyframes drawerIn {
  from {
    opacity: 0;
    transform: translateX(18px);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.processing-trace {
  display: grid;
}

.trace-item {
  position: relative;
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr);
  gap: 10px;
  min-height: 66px;
  animation: pipelineEnter 320ms ease both;
  animation-delay: calc(var(--trace-index) * 70ms);
}

.trace-item::before {
  position: absolute;
  top: 21px;
  left: 8px;
  width: 2px;
  height: calc(100% - 18px);
  background: #d8e5e0;
  content: "";
}

.trace-item:last-child::before {
  display: none;
}

.trace-item > span {
  z-index: 1;
  width: 18px;
  height: 18px;
  margin-top: 3px;
  border-radius: 999px;
  background: var(--teal);
  box-shadow: 0 0 0 5px rgba(20, 122, 117, 0.08);
}

.trace-item strong,
.trace-item small {
  display: block;
}

.trace-item small {
  margin-top: 4px;
  color: var(--muted);
}

.business-preview-list,
.todo-list,
.artifact-list,
.review-card-list {
  display: grid;
  gap: 12px;
}

.business-preview-list article,
.todo-list article,
.artifact-list article,
.review-card {
  padding: 14px;
  border: 1px solid #dfe8e5;
  border-radius: 8px;
  background: #fbfcfa;
}

.business-preview-list article p,
.todo-list article p {
  margin: 6px 0 0;
  line-height: 1.6;
}

.todo-list article {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}

.artifact-list article {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
}

.artifact-list span {
  color: var(--muted);
  font-size: 12px;
}

.review-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.55fr);
  gap: 16px;
}

.review-actions {
  display: grid;
  gap: 9px;
}

.processing-risk-board {
  display: grid;
  gap: 14px;
}

.processing-risk-ai,
.processing-risk-list-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
  border: 1px solid #d5e6e2;
  border-radius: 8px;
  background: #ffffff;
}

.processing-risk-ai {
  background:
    linear-gradient(90deg, rgba(236, 248, 255, 0.78), rgba(244, 255, 251, 0.92));
}

.processing-risk-ai h3,
.processing-risk-list-head h3 {
  margin: 0 0 5px;
  font-size: 18px;
  letter-spacing: 0;
}

.processing-risk-ai p,
.processing-risk-list-head p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.processing-risk-table-wrap {
  width: 100%;
  overflow-x: auto;
  border: 1px solid #d4e4e0;
  border-radius: 8px;
  background: #ffffff;
}

.processing-risk-table {
  width: 100%;
  min-width: 1120px;
  border-collapse: separate;
  border-spacing: 0;
  color: var(--ink);
  font-size: 13px;
}

.processing-risk-table th {
  padding: 12px 13px;
  border-bottom: 1px solid #d4e4e0;
  background: #eef8fb;
  color: #31505a;
  font-size: 12px;
  font-weight: 800;
  text-align: left;
  white-space: nowrap;
}

.processing-risk-table td {
  padding: 13px;
  border-bottom: 1px solid #e2ece8;
  line-height: 1.48;
  vertical-align: top;
}

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

.processing-risk-table tbody tr:hover {
  background: #f8fcfb;
}

.processing-risk-table td:nth-child(1),
.processing-risk-table td:nth-child(2),
.processing-risk-table td:nth-child(3),
.processing-risk-table td:nth-child(4),
.processing-risk-table td:nth-child(5) {
  white-space: nowrap;
}

.processing-risk-table td:nth-child(6) {
  min-width: 330px;
}

.processing-risk-table td:nth-child(7) {
  min-width: 230px;
}

.processing-risk-table td:nth-child(8) {
  min-width: 178px;
}

.processing-risk-evidence {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.processing-risk-status {
  display: grid;
  gap: 7px;
  min-width: 170px;
}

.processing-risk-status select,
.processing-risk-status input,
.processing-risk-status button {
  width: 100%;
  min-height: 34px;
  font-size: 13px;
}

.processing-risk-status button {
  border-color: #bcd6d1;
  background: #fbfefd;
  color: var(--teal-dark);
  font-weight: 800;
}

.processing-risk-status small {
  color: var(--muted);
  font-size: 12px;
}

@keyframes pipelineEnter {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes flowLaneEnter {
  from {
    opacity: 0;
    transform: translateY(12px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes flowNodeEnter {
  from {
    opacity: 0;
    transform: translateX(-8px);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes lineagePathGlow {
  0%,
  100% {
    opacity: 0.72;
    filter: drop-shadow(0 0 0 rgba(42, 183, 167, 0));
  }

  50% {
    opacity: 1;
    filter: drop-shadow(0 0 8px rgba(42, 183, 167, 0.28));
  }
}

@keyframes lineageArrowFlow {
  0% {
    background-position: 0 0, 0 0;
  }

  100% {
    background-position: 120px 0, 0 0;
  }
}

@keyframes lineageRibbonDrift {
  0%,
  100% {
    opacity: 0.78;
    transform: translateX(-6px) scaleX(0.985);
  }

  50% {
    opacity: 1;
    transform: translateX(6px) scaleX(1.01);
  }
}

@keyframes lineageCheckPulse {
  0%,
  100% {
    box-shadow: 0 0 0 4px rgba(47, 184, 173, 0.1);
  }

  50% {
    box-shadow: 0 0 0 8px rgba(47, 184, 173, 0.18);
  }
}

@keyframes lineageNodeIn {
  from {
    opacity: 0;
    filter: blur(2px);
  }

  to {
    opacity: 1;
    filter: blur(0);
  }
}

@keyframes pulseDot {
  0%,
  100% {
    box-shadow: 0 0 0 5px rgba(20, 122, 117, 0.08);
  }

  50% {
    box-shadow: 0 0 0 9px rgba(20, 122, 117, 0.15);
  }
}

@media (prefers-reduced-motion: reduce) {
  .flow-card,
  .drill-drawer,
  .processing-flow-lane.process .flow-lane-head > span,
  .ingest-flow-lane,
  .ingest-flow-node,
  .processing-file-scroll .ingest-flow-track::after,
  .processing-file-scroll .ingest-flow-node,
  .processing-file-scroll .ingest-flow-node::after,
  .processing-file-scroll .ingest-flow-node:not(:last-child) > span::after,
  .processing-lane-ai-summary::after,
  .ai-summary-mascot,
  .ai-mascot-head i,
  .ingest-flow-stagebar a,
  .trace-item {
    animation: none;
  }
}

.compact-list {
  display: grid;
  gap: 8px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.compact-list li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px solid var(--line);
}

.compact-list li:last-child {
  border-bottom: 0;
}

.profile-hero {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 18px;
}

.score-ring {
  display: grid;
  width: 132px;
  height: 132px;
  place-items: center;
  border: 12px solid #e8f2ef;
  border-top-color: var(--teal);
  border-right-color: var(--amber);
  border-radius: 999px;
}

.score-ring strong {
  font-size: 34px;
}

.graph-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(340px, 0.65fr);
  gap: 16px;
  align-items: start;
}

.graph-panel-header {
  align-items: center;
  gap: 14px;
}

.graph-panel-header p {
  margin: 4px 0 0;
}

.graph-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.graph-stage {
  position: relative;
  overflow: hidden;
  border: 1px solid #cbdedd;
  border-radius: 8px;
  background:
    radial-gradient(circle at 50% 50%, rgba(27, 140, 132, 0.12), transparent 28%),
    linear-gradient(90deg, rgba(38, 101, 96, 0.06) 1px, transparent 1px),
    linear-gradient(0deg, rgba(38, 101, 96, 0.06) 1px, transparent 1px),
    #fbfdfc;
  background-size: auto, 40px 40px, 40px 40px, auto;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.75);
}

.graph-canvas {
  display: block;
  width: 100%;
  min-height: 620px;
  cursor: grab;
  touch-action: none;
}

.graph-canvas.is-panning,
.graph-canvas.is-dragging {
  cursor: grabbing;
}

.graph-node {
  cursor: pointer;
  outline: none;
}

.graph-node-core {
  stroke: rgba(255, 255, 255, 0.96);
  stroke-width: 2.4;
  filter: url("#graph-node-shadow");
  transition: r 160ms ease, stroke-width 160ms ease;
}

.graph-node.active .graph-node-core {
  stroke: #102a2e;
  stroke-width: 4;
}

.graph-node.risk .graph-node-core {
  stroke: #ffe4dd;
}

.graph-node:focus-visible .graph-node-core {
  stroke: #0f625f;
  stroke-width: 5;
}

.graph-node-mark {
  fill: #fff;
  font-size: 12px;
  font-weight: 800;
  pointer-events: none;
  text-anchor: middle;
}

.graph-node-label,
.graph-edge-label {
  font-size: 12px;
  font-weight: 700;
  paint-order: stroke;
  stroke: #fff;
  stroke-width: 5px;
  stroke-linejoin: round;
  fill: #1b2b30;
  pointer-events: none;
}

.graph-edge-label {
  fill: #617177;
  font-weight: 600;
}

.graph-link {
  fill: none;
  stroke: #aac1bf;
  stroke-width: 1.2;
  stroke-linecap: round;
  opacity: 0.48;
}

.graph-link.active {
  stroke-width: 2.8;
  opacity: 0.96;
}

.graph-link.relation-risk {
  stroke: #d46d61;
}

.graph-link.relation-supply {
  stroke: #56a06b;
}

.graph-link.relation-participate {
  stroke: #4d82b5;
}

.graph-link.relation-include {
  stroke: #99aaa8;
  stroke-dasharray: 5 6;
}

.graph-tooltip {
  position: absolute;
  z-index: 2;
  display: none;
  max-width: 280px;
  padding: 10px 12px;
  border: 1px solid #c7dcda;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 18px 36px rgba(26, 62, 66, 0.16);
  pointer-events: none;
}

.graph-tooltip.visible {
  display: grid;
  gap: 3px;
}

.graph-tooltip strong {
  color: var(--ink);
  font-size: 13px;
}

.graph-tooltip span {
  color: var(--muted);
  font-size: 12px;
}

.graph-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
  color: #53676c;
  font-size: 12px;
}

.graph-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 9px;
  border: 1px solid #d9e8e5;
  border-radius: 999px;
  background: #f7fbfa;
}

.graph-legend i {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: var(--legend-color);
}

.graph-legend .risk-dot {
  background: #c95b4d;
}

@media (max-width: 760px) {
  .graph-panel-header {
    align-items: flex-start;
  }

  .graph-toolbar {
    justify-content: flex-start;
  }

  .graph-canvas {
    min-height: 520px;
  }
}

.risk-path-list {
  display: grid;
  gap: 10px;
}

.risk-path {
  padding: 13px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfa;
}

.risk-path p {
  margin: 7px 0 4px;
  line-height: 1.6;
}

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

.empty,
.loading {
  padding: 22px;
  color: var(--muted);
}

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 14px;
}

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

.form-grid label,
.wide-label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.checkbox-line {
  display: flex !important;
  align-items: center;
  gap: 8px;
  min-height: 36px;
  padding-top: 20px;
}

.result-block {
  margin-top: 14px;
}

.ai-result {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfa;
}

.ai-result p {
  margin-bottom: 0;
  line-height: 1.65;
}

.ai-result-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  color: var(--muted);
  font-size: 12px;
}

.merge-summary {
  margin-bottom: 14px;
}

.merge-tile {
  min-height: 86px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfa;
}

.merge-tile span,
.merge-tile small {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.merge-tile strong {
  display: block;
  margin: 6px 0 4px;
  font-size: 25px;
}

select,
input[type="text"],
textarea {
  min-height: 36px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
}

textarea {
  min-height: 126px;
  padding: 10px;
  resize: vertical;
}

.briefing-callout {
  padding: 18px;
  border-left: 4px solid var(--teal);
  border-radius: 0 8px 8px 0;
  background: #edf7f4;
  line-height: 1.7;
}

@media (max-width: 980px) {
  .sidebar {
    position: static;
    width: auto;
  }

  .processing-risk-ai,
  .processing-risk-list-head {
    align-items: flex-start;
    flex-direction: column;
  }

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

  .main {
    margin-left: 0;
  }

  .topbar,
  .profile-hero,
  .ingest-hero,
  .ingest-command-grid,
  .ingest-command-grid-v2,
  .ingest-work-grid,
  .ingest-home-grid,
  .ingest-operation-grid,
  .ingest-flow-hero,
  .ingest-flow-board-head,
  .ingest-flow-layout,
  .processing-overview-hero,
  .processing-file-lanes-head,
  .processing-file-lanes-summary,
  .processing-file-workspace-body,
  .processing-file-scroll .ingest-flow-lane-body,
  .processing-batch-strip,
  .document-trace-hero,
  .document-trace-grid,
  .document-extraction-grid,
  .processing-flow-main,
  .file-diagnosis-entry,
  .file-dataset-output-entry,
  .file-merge-entry,
  .dataset-source-files article,
  .processing-step-grid,
  .processing-step-hero,
  .file-processing-hero,
  .dataset-detail-hero,
  .file-step-tabs,
  .dataset-detail-grid,
  .review-explain-grid,
  .review-card,
  .step,
  .processing-layout,
  .graph-layout {
    grid-template-columns: 1fr;
  }

  .processing-file-workspace-body {
    grid-template-columns: minmax(240px, 300px) minmax(0, 1fr);
  }

  .processing-flow-lane::after {
    top: auto;
    right: auto;
    bottom: -17px;
    left: 28px;
    width: 2px;
    height: 17px;
  }

  .processing-process-note {
    align-items: flex-start;
  }

  .processing-process-note span {
    overflow: visible;
    text-overflow: clip;
    white-space: normal;
  }

  .result-card-grid,
  .result-lineage,
  .lineage-stage-strip,
  .field-lineage-list article {
    grid-template-columns: 1fr;
  }

  .field-lineage-list article > div {
    padding-right: 0;
    padding-bottom: 10px;
    border-right: 0;
    border-bottom: 1px solid #e4ebe8;
  }

  .field-lineage-list article > div:last-child {
    padding-bottom: 0;
    border-bottom: 0;
  }

  .drill-layer {
    grid-template-columns: 1fr;
  }

  .record-preview-layer {
    padding: 14px;
  }

  .record-preview-dialog {
    width: calc(100vw - 28px);
    max-height: calc(100dvh - 28px);
  }

  .record-preview-head,
  .record-preview-body {
    padding-right: 14px;
    padding-left: 14px;
  }

  .file-preview-modal-meta {
    grid-template-columns: 1fr;
  }

  .drill-backdrop {
    display: none;
  }

  .drill-drawer {
    height: 100dvh;
    border-left: 0;
  }

  .ingest-progress-strip {
    grid-template-columns: 1fr;
  }

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

  .document-trace-flow {
    grid-template-columns: 1fr;
  }

  .document-trace-step::after {
    top: auto;
    right: auto;
    bottom: -9px;
    left: 18px;
    width: 2px;
    height: 9px;
  }

  .document-trace-badges,
  .document-trace-actions {
    justify-content: flex-start;
  }

  .document-extraction-grid {
    min-height: auto;
  }

  .document-extraction-grid .document-paper,
  .document-extract-form {
    max-height: none;
  }

  .document-extract-form .document-field-card,
  .document-workbench-foot {
    grid-template-columns: 1fr;
  }

  .document-extract-form .document-field-card {
    grid-template-areas:
      "index"
      "label"
      "value"
      "score"
      "source"
      "target";
  }

  .document-extract-form .document-field-card small,
  .document-extract-form .document-field-card em {
    grid-column: auto;
  }

  .ingest-flow-canvas,
  .ingest-intake-panel .file-card-list,
  .processing-file-scroll {
    max-height: none;
  }

  .processing-batch-strip-links {
    justify-content: flex-start;
  }

  .ai-summary-mascot {
    display: none;
  }

  .ai-summary-copy {
    padding-right: 14px;
  }

  .ingest-flow-guide {
    position: static;
  }

  .drill-steps {
    position: static;
  }

  .topbar {
    display: grid;
    gap: 16px;
  }

  .grid.cols-4,
  .grid.cols-3,
  .grid.cols-2,
  .ingest-entry-grid,
  .ingest-result-metrics,
  .file-parse-overview,
  .merge-diff-grid,
  .merge-conflict-actions,
  .form-grid {
    grid-template-columns: 1fr;
  }

  .content {
    padding: 20px 16px 30px;
  }

  .batch-card,
  .file-card,
  .upload-box {
    grid-template-columns: 1fr;
  }

  .merge-decision {
    display: grid;
  }

  .ingest-current-hero {
    display: grid;
  }

  .ingest-command-head,
  .ingest-operation-head,
  .todo-list article,
  .artifact-list article {
    display: grid;
  }

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

}

/* Bright workspace redesign layer */
:root {
  --bg: #f7fbff;
  --panel: #ffffff;
  --panel-soft: #f2f8fb;
  --ink: #16212a;
  --muted: #627484;
  --line: #dce8ef;
  --line-strong: #c7dae4;
  --teal: #11a7a2;
  --teal-dark: #087b86;
  --blue: #2678e4;
  --green: #20a66a;
  --amber: #d58a18;
  --red: #df5c50;
  --coral: #ff7a68;
  --mint: #dcf8ec;
  --sky: #e7f3ff;
  --sun: #fff3c9;
  --shadow: 0 18px 42px rgba(50, 91, 116, 0.11);
  --shadow-soft: 0 10px 24px rgba(50, 91, 116, 0.08);
  --radius: 8px;
}

html {
  background: var(--bg);
}

body {
  color: var(--ink);
  background:
    linear-gradient(180deg, #f8fcff 0%, #f3fbf8 42%, #f7fbff 100%);
  font-family:
    "Inter",
    "Microsoft YaHei",
    "PingFang SC",
    "Segoe UI",
    Arial,
    sans-serif;
  letter-spacing: 0;
}

body::before {
  position: fixed;
  z-index: -1;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(17, 167, 162, 0.055) 1px, transparent 1px),
    linear-gradient(180deg, rgba(38, 120, 228, 0.045) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.75), transparent 68%);
  content: "";
}

button,
.button-link,
select,
input[type="text"],
textarea {
  border-radius: var(--radius);
  transition:
    border-color 160ms ease,
    box-shadow 160ms ease,
    background 160ms ease,
    color 160ms ease,
    transform 160ms ease;
}

button,
.button-link {
  min-height: 40px;
  border-color: #cfe0e8;
  background: rgba(255, 255, 255, 0.92);
  color: #16313e;
  font-weight: 750;
}

button:hover,
.button-link:hover,
button:focus-visible,
.button-link:focus-visible {
  border-color: rgba(17, 167, 162, 0.56);
  box-shadow: 0 0 0 4px rgba(17, 167, 162, 0.12);
  outline: none;
  transform: translateY(-1px);
}

.primary-button,
.upload-submit {
  border-color: transparent;
  background: linear-gradient(135deg, #0d9ba4 0%, #16b88c 100%);
  color: #ffffff;
  box-shadow: 0 12px 24px rgba(17, 167, 162, 0.22);
}

.primary-button:hover,
.upload-submit:hover,
.primary-button:focus-visible,
.upload-submit:focus-visible {
  box-shadow:
    0 14px 28px rgba(17, 167, 162, 0.28),
    0 0 0 4px rgba(17, 167, 162, 0.14);
}

.icon-button {
  display: inline-grid;
  width: 42px;
  height: 42px;
  min-height: 42px;
  place-items: center;
  border-radius: 999px;
}

.sidebar {
  width: 278px;
  padding: 22px 18px;
  border-right: 1px solid rgba(199, 218, 228, 0.72);
  background: rgba(255, 255, 255, 0.88);
  color: var(--ink);
  box-shadow: 18px 0 45px rgba(61, 93, 111, 0.08);
  backdrop-filter: blur(18px);
}

.brand {
  min-height: 68px;
  padding: 6px 4px 20px;
  border-bottom-color: rgba(199, 218, 228, 0.8);
}

.brand-mark {
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, #10aaa4, #29c48e);
  color: #ffffff;
  box-shadow: 0 14px 30px rgba(17, 167, 162, 0.22);
  font-size: 15px;
}

.brand strong {
  color: #15242d;
  font-size: 15px;
}

.brand span {
  color: #5f7887;
  font-size: 12px;
}

.nav {
  gap: 7px;
  margin-top: 20px;
}

.nav-group {
  display: grid;
  gap: 6px;
}

.nav a,
.nav-section-label {
  position: relative;
  min-height: 44px;
  padding: 12px 14px 12px 36px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  color: #314a58;
  font-weight: 750;
}

.nav a::before,
.nav-section-label::before {
  position: absolute;
  top: 50%;
  left: 14px;
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: #b8ced9;
  transform: translateY(-50%);
  content: "";
}

.nav a.active,
.nav a:hover,
.nav a:focus-visible {
  border-color: rgba(17, 167, 162, 0.22);
  background: #eaf8f5;
  color: #064d58;
  outline: none;
}

.nav a.active::before,
.nav a:hover::before {
  background: var(--teal);
  box-shadow: 0 0 0 5px rgba(17, 167, 162, 0.13);
}

.nav-submenu {
  display: grid;
  gap: 4px;
  margin-left: 16px;
  padding-left: 12px;
  border-left: 1px solid rgba(17, 167, 162, 0.18);
}

.nav-subitem-disabled {
  position: relative;
  min-height: 36px;
  padding: 9px 12px 9px 30px;
  border: 1px solid rgba(178, 198, 207, 0.25);
  border-radius: 8px;
  color: #8aa0ab;
  font-size: 13px;
  font-weight: 700;
  background: rgba(248, 252, 252, 0.72);
  cursor: not-allowed;
}

.nav-subitem-disabled::before {
  position: absolute;
  top: 50%;
  left: 12px;
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: #d4e1e7;
  transform: translateY(-50%);
  content: "";
}

.nav-submenu a {
  min-height: 34px;
  padding: 8px 10px 8px 28px;
  border-radius: 6px;
  color: #56707c;
  font-size: 12px;
  font-weight: 800;
}

.nav-submenu a::before {
  left: 10px;
  width: 6px;
  height: 6px;
  background: #c3d7df;
}

.nav-submenu a.active {
  border-color: rgba(83, 104, 255, 0.18);
  background: #eef3ff;
  color: #3c49d8;
}

.nav-submenu a.active::before {
  background: #6c63ff;
  box-shadow: 0 0 0 4px rgba(108, 99, 255, 0.12);
}

.main {
  margin-left: 278px;
}

.topbar {
  min-height: 94px;
  padding: 20px 34px;
  border-bottom: 1px solid rgba(199, 218, 228, 0.7);
  background: rgba(247, 251, 255, 0.82);
  backdrop-filter: blur(18px);
}

h1 {
  color: #16212a;
  font-size: 30px;
  font-weight: 850;
}

h2 {
  color: #16212a;
  font-size: 22px;
}

h3 {
  color: #1d2d38;
}

.eyebrow {
  color: var(--teal-dark);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.04em;
}

.content {
  width: 100%;
  max-width: none;
  padding: 30px 34px 48px;
}

.content > .section {
  width: 100%;
}

.section {
  margin-bottom: 22px;
}

.panel,
.ingest-subpage-head,
.processing-overview-hero,
.processing-file-lanes-panel,
.processing-batch-strip,
.processing-step-hero,
.file-field-lineage,
.file-extract-entries,
.file-diagnosis-entries,
.file-dataset-output-entries,
.file-merge-entries {
  border: 1px solid rgba(199, 218, 228, 0.86);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow-soft);
}

.panel-header {
  padding: 18px 20px 0;
}

.panel-body {
  padding: 20px;
}

.muted {
  color: var(--muted);
  line-height: 1.65;
}

.dashboard-hero,
.ingest-command-deck,
.processing-overview-hero {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(141, 206, 209, 0.5);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(232, 249, 246, 0.94) 56%, rgba(236, 246, 255, 0.96) 100%);
  box-shadow: var(--shadow);
}

.content > .section {
  animation: workspaceFadeUp 260ms ease both;
}

.content > .section:nth-child(2) {
  animation-delay: 45ms;
}

.content > .section:nth-child(3) {
  animation-delay: 90ms;
}

.content > .section:nth-child(4) {
  animation-delay: 135ms;
}

.dashboard-hero {
  display: flex;
  gap: 18px;
  align-items: center;
  justify-content: space-between;
  padding: 26px 28px;
}

.dashboard-hero h2,
.ingest-command-head h2,
.processing-hero-copy h2 {
  margin: 4px 0 8px;
  font-size: 28px;
  line-height: 1.25;
}

.dashboard-hero .muted,
.ingest-command-head .muted,
.processing-hero-copy .muted {
  max-width: 780px;
  margin: 0;
  font-size: 15px;
}

.dashboard-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.dashboard-metric-grid {
  gap: 14px;
}

.ai-assistant-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(340px, 0.7fr);
  gap: 22px;
  overflow: hidden;
  padding: 30px;
  border: 1px solid rgba(19, 49, 59, 0.14);
  border-radius: var(--radius);
  background:
    linear-gradient(rgba(255, 255, 255, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.08) 1px, transparent 1px),
    linear-gradient(135deg, #172d36 0%, #0c4f58 52%, #1f6f58 100%);
  background-size: 28px 28px, 28px 28px, auto;
  color: #eefbf8;
  box-shadow: 0 22px 56px rgba(29, 61, 71, 0.2);
}

.ai-assistant-hero::after {
  position: absolute;
  inset: auto 0 0;
  height: 4px;
  background: linear-gradient(90deg, #27c79a, #f0b64f, #e85f4b, #5fb0e8);
  content: "";
}

.ai-hero-copy {
  position: relative;
  z-index: 1;
}

.ai-hero-copy .eyebrow {
  color: #9fe9dc;
}

.ai-hero-copy h2 {
  max-width: 720px;
  margin: 6px 0 12px;
  color: #ffffff;
  font-size: 36px;
  line-height: 1.18;
}

.ai-hero-copy p {
  max-width: 720px;
  margin: 0;
  color: rgba(238, 251, 248, 0.82);
  font-size: 16px;
  line-height: 1.75;
}

.ai-hero-status {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.ai-hero-status span {
  min-height: 38px;
  padding: 9px 12px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.09);
  color: rgba(238, 251, 248, 0.74);
}

.ai-hero-status strong {
  margin-right: 6px;
  color: #ffffff;
}

.ai-command-card {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 220px;
  padding: 22px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.ai-command-topline {
  display: flex;
  gap: 8px;
  align-items: center;
  color: #c9f6ee;
  font-size: 13px;
  font-weight: 850;
}

.ai-signal {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: #2be19d;
  box-shadow: 0 0 0 6px rgba(43, 225, 157, 0.14);
}

.ai-command-card h3 {
  margin: 16px 0 8px;
  color: #ffffff;
  font-size: 24px;
  line-height: 1.28;
}

.ai-command-card p {
  margin: 0 0 18px;
  color: rgba(238, 251, 248, 0.78);
  line-height: 1.7;
}

.assistant-primary-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 10px 16px;
  border-radius: var(--radius);
  text-decoration: none;
}

.ai-assistant-chat {
  position: relative;
  overflow: hidden;
  padding: 24px;
  border: 1px solid rgba(48, 132, 132, 0.22);
  border-radius: 10px;
  background:
    radial-gradient(circle at 9% 0%, rgba(102, 194, 184, 0.15), transparent 30%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(239, 250, 247, 0.94));
  box-shadow: 0 18px 46px rgba(35, 72, 82, 0.12);
}

.ai-assistant-chat::before {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(40, 120, 126, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(40, 120, 126, 0.06) 1px, transparent 1px);
  background-size: 34px 34px;
  content: "";
  mask-image: linear-gradient(90deg, rgba(0, 0, 0, 0.18), transparent 68%);
}

.ai-chat-header,
.ai-chat-body {
  position: relative;
  z-index: 1;
}

.ai-chat-header {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 18px;
}

.ai-chat-identity {
  display: flex;
  min-width: 0;
  gap: 14px;
  align-items: center;
}

.ai-chat-avatar,
.ai-message-avatar {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #ffffff;
  font-weight: 900;
}

.ai-chat-avatar {
  position: relative;
  width: 50px;
  height: 50px;
  background: linear-gradient(135deg, #2f8c8b, #5cc3a7);
  box-shadow: 0 14px 30px rgba(47, 140, 139, 0.24);
  letter-spacing: 0.02em;
}

.ai-chat-avatar::after {
  position: absolute;
  right: 2px;
  bottom: 2px;
  width: 16px;
  height: 16px;
  border: 3px solid rgba(242, 251, 248, 0.96);
  border-radius: 999px;
  background: #6fe0b7;
  content: "";
}

.ai-chat-identity h2 {
  margin: 4px 0 0;
  color: #12242b;
  font-size: 28px;
  line-height: 1.18;
  overflow-wrap: anywhere;
}

.ai-chat-context {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
  max-width: 620px;
}

.ai-chat-context span {
  display: inline-flex;
  min-width: 124px;
  gap: 6px;
  align-items: baseline;
  justify-content: center;
  padding: 9px 12px;
  border: 1px solid rgba(182, 213, 216, 0.8);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
  color: #5f7179;
  font-size: 13px;
  box-shadow: 0 10px 24px rgba(39, 84, 91, 0.06);
}

.ai-batch-switch {
  display: inline-flex;
  min-width: 260px;
  gap: 8px;
  align-items: center;
  padding: 7px 10px;
  border: 1px solid rgba(182, 213, 216, 0.8);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 10px 24px rgba(39, 84, 91, 0.06);
}

.ai-batch-switch span {
  min-width: auto;
  padding: 0;
  border: 0;
  background: transparent;
  color: #6b7b82;
  box-shadow: none;
  white-space: nowrap;
}

.ai-batch-switch select {
  min-width: 0;
  max-width: 360px;
  border: 0;
  background: transparent;
  color: #12242b;
  font: inherit;
  font-size: 15px;
  font-weight: 900;
  outline: none;
  text-overflow: ellipsis;
}

.ai-chat-context strong {
  color: #12242b;
  font-size: 18px;
}

.ai-chat-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 360px);
  gap: 16px;
  align-items: stretch;
}

.ai-chat-message {
  display: block;
  min-width: 0;
}

.ai-message-avatar {
  width: 42px;
  height: 42px;
  margin-top: 4px;
  background: #2f8c8b;
  box-shadow: 0 0 0 8px rgba(47, 140, 139, 0.1);
}

.ai-message-bubble {
  min-width: 0;
  padding: 18px 20px;
  border: 1px solid rgba(173, 215, 213, 0.86);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
}

.ai-message-bubble p {
  margin: 0;
  color: #284046;
  font-size: 16px;
  line-height: 1.82;
}

.ai-message-bubble strong {
  color: #a24d25;
}

.ai-message-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 16px;
}

.ai-message-metrics span {
  min-width: 0;
  padding: 10px 12px;
  border-radius: 8px;
  background: #f1faf7;
  color: #637986;
  font-size: 12px;
  line-height: 1.35;
}

.ai-message-metrics strong {
  display: block;
  margin-bottom: 3px;
  color: #10282b;
  font-size: 17px;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.ai-message-metrics small {
  display: block;
  margin-top: 4px;
  color: #81939c;
  font-size: 11px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.ai-chat-task-card {
  display: flex;
  min-width: 0;
  flex-direction: column;
  justify-content: space-between;
  gap: 18px;
  padding: 18px;
  border: 1px solid rgba(47, 140, 139, 0.22);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(235, 249, 245, 0.96), rgba(255, 255, 255, 0.96));
}

.ai-chat-action-panel,
.ai-chat-risk-panel {
  min-width: 0;
  border: 1px solid rgba(47, 140, 139, 0.22);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(235, 249, 245, 0.96), rgba(255, 255, 255, 0.96));
}

.ai-chat-action-panel {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px;
}

.ai-chat-panel-head {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(191, 219, 218, 0.78);
}

.ai-chat-panel-head span {
  color: #2f7f7c;
  font-size: 13px;
  font-weight: 900;
}

.ai-chat-panel-head strong {
  padding: 3px 8px;
  border-radius: 999px;
  background: #edf8f5;
  color: #255c5d;
  font-size: 12px;
}

.ai-chat-advice-list {
  display: grid;
  gap: 9px;
}

.ai-chat-advice-item {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  min-width: 0;
  padding: 10px 0 10px 10px;
  border-left: 3px solid #7fb5d6;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.62);
  color: #19313a;
  text-decoration: none;
}

.ai-chat-advice-item:hover,
.ai-chat-advice-item:focus-visible {
  background: #ffffff;
  box-shadow: 0 10px 22px rgba(35, 72, 82, 0.08);
  outline: none;
}

.ai-chat-advice-item span {
  color: #5f7179;
  font-size: 12px;
  font-weight: 900;
}

.ai-chat-advice-item strong {
  min-width: 0;
  overflow: hidden;
  color: #13242c;
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ai-chat-advice-item em {
  padding-right: 10px;
  color: #0d6a64;
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
  white-space: nowrap;
}

.ai-chat-risk-panel {
  grid-column: 1 / -1;
  display: flex;
  gap: 18px;
  align-items: center;
  justify-content: space-between;
  padding: 16px 18px;
  border-color: rgba(232, 95, 75, 0.24);
  background:
    linear-gradient(135deg, rgba(255, 246, 241, 0.9), rgba(238, 251, 247, 0.92)),
    #ffffff;
}

.ai-chat-risk-panel h3 {
  margin: 8px 0 6px;
  color: #12242b;
  font-size: 18px;
  line-height: 1.35;
}

.ai-chat-risk-panel p {
  margin: 0;
  color: #5f7179;
  line-height: 1.65;
}

.ai-task-level {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #2f7f7c;
  font-size: 13px;
  font-weight: 900;
}

.ai-task-level::before {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #58c89f;
  box-shadow: 0 0 0 6px rgba(88, 200, 159, 0.14);
  content: "";
}

.ai-chat-task-card h3 {
  margin: 12px 0 8px;
  color: #12242b;
  font-size: 22px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.ai-chat-task-card p {
  margin: 0;
  color: #5f7179;
  line-height: 1.7;
}

.ai-chat-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.ai-chat-composer {
  grid-column: 1 / -1;
  display: flex;
  min-width: 0;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border: 1px solid rgba(196, 216, 222, 0.88);
  border-radius: 8px;
  background: #ffffff;
  color: #73818a;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.ai-chat-composer span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ai-chat-composer a {
  flex: 0 0 auto;
  color: #2f7f7c;
  font-weight: 900;
  text-decoration: none;
}

.ai-status-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
}

.ai-status-card {
  position: relative;
  overflow: hidden;
  min-height: 128px;
  padding: 18px;
  border: 1px solid rgba(199, 218, 228, 0.78);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow-soft);
}

.ai-status-card::before {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: #7fb5d6;
  content: "";
}

.ai-status-success::before,
.ai-status-ok::before {
  background: #24b183;
}

.ai-status-attention::before,
.ai-status-risk::before {
  background: #e85f4b;
}

.ai-status-blue::before {
  background: #4d92c7;
}

.ai-status-card span,
.ai-status-card small {
  display: block;
  color: #607784;
  font-size: 13px;
}

.ai-status-card strong {
  display: block;
  margin: 10px 0 8px;
  color: #13242c;
  font-size: 26px;
  line-height: 1.2;
}

.ai-workflow-panel,
.ai-source-sync-panel,
.ai-recommendation-panel,
.ai-focus-card,
.ai-audit-card,
.ai-dataset-strip {
  border: 1px solid rgba(199, 218, 228, 0.72);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow-soft);
}

.ai-source-sync-body {
  display: grid;
  grid-template-columns: minmax(220px, 0.34fr) minmax(0, 1fr);
  gap: 16px;
  padding: 18px 20px 20px;
}

.ai-source-total {
  display: flex;
  align-self: start;
  min-height: 190px;
  flex-direction: column;
  justify-content: center;
  padding: 22px;
  border: 1px solid rgba(17, 167, 162, 0.2);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(17, 167, 162, 0.12), rgba(95, 176, 232, 0.12)),
    #f8fcfb;
}

.ai-source-total span,
.ai-source-total small {
  display: block;
  color: #607784;
  font-size: 13px;
}

.ai-source-total strong {
  display: block;
  margin: 8px 0 10px;
  color: #102b33;
  font-size: 54px;
  line-height: 1;
}

.ai-source-channels {
  display: grid;
  grid-template-columns: repeat(3, minmax(180px, 1fr));
  gap: 10px;
}

.ai-source-channel {
  position: relative;
  display: flex;
  min-height: 132px;
  flex-direction: column;
  justify-content: space-between;
  padding: 14px;
  border: 1px solid rgba(199, 218, 228, 0.72);
  border-radius: var(--radius);
  background: #fbfdfc;
}

.ai-source-channel::before {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: #f0b64f;
  content: "";
}

.ai-source-channel.is-live::before {
  background: #24b183;
  box-shadow: 0 0 0 5px rgba(36, 177, 131, 0.12);
}

.ai-source-channel span,
.ai-source-channel small {
  display: block;
  color: #607784;
  font-size: 12px;
  line-height: 1.45;
}

.ai-source-channel strong {
  display: block;
  margin: 8px 18px 8px 0;
  color: #142832;
  font-size: 15px;
  line-height: 1.35;
}

.ai-source-channel em {
  color: #0d6a64;
  font-size: 12px;
  font-style: normal;
  font-weight: 850;
}

.ai-source-channel.is-planned em {
  color: #8c681c;
}

.ai-module-map {
  display: grid;
  grid-template-columns: repeat(4, minmax(190px, 1fr));
  gap: 12px;
  padding: 18px 20px 20px;
}

.ai-module-card {
  position: relative;
  display: flex;
  min-height: 172px;
  flex-direction: column;
  justify-content: space-between;
  padding: 18px;
  border: 1px solid rgba(199, 218, 228, 0.72);
  border-radius: var(--radius);
  background: #f9fcfb;
  color: #1a2e37;
  text-decoration: none;
  transition:
    border-color 180ms ease,
    box-shadow 180ms ease,
    transform 180ms ease;
}

.ai-module-card:hover,
.ai-module-card:focus-visible {
  border-color: rgba(17, 167, 162, 0.5);
  box-shadow: 0 18px 34px rgba(49, 82, 96, 0.13);
  outline: none;
  transform: translateY(-2px);
}

.ai-module-card::after {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: #7fb5d6;
  content: "";
}

.ai-module-ok::after {
  background: #24b183;
}

.ai-module-risk::after {
  background: #e85f4b;
}

.ai-module-info::after {
  background: #f0b64f;
}

.ai-module-blue::after {
  background: #4d92c7;
}

.ai-module-label {
  color: #607784;
  font-size: 13px;
  font-weight: 850;
}

.ai-module-card strong {
  display: block;
  margin-top: 12px;
  color: #13242c;
  font-size: 18px;
  line-height: 1.35;
}

.ai-module-card p {
  margin: 10px 0 16px;
  color: #637986;
  line-height: 1.55;
}

.ai-module-card em {
  align-self: flex-start;
  padding: 5px 9px;
  border-radius: 999px;
  background: #edf6f4;
  color: #0d6a64;
  font-size: 12px;
  font-style: normal;
  font-weight: 850;
}

.ai-assistant-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, 0.65fr);
  gap: 16px;
}

.ai-recommendation-list {
  display: grid;
  gap: 10px;
  padding: 18px 20px 20px;
}

.ai-recommendation-item {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  min-height: 84px;
  padding: 14px;
  border: 1px solid rgba(199, 218, 228, 0.72);
  border-left: 4px solid #7fb5d6;
  border-radius: var(--radius);
  background: #fbfdfc;
  color: #172a34;
  text-decoration: none;
}

.ai-recommendation-item:hover,
.ai-recommendation-item:focus-visible {
  border-color: rgba(17, 167, 162, 0.42);
  box-shadow: 0 12px 26px rgba(49, 82, 96, 0.1);
  outline: none;
}

.ai-rec-high {
  border-left-color: #e85f4b;
}

.ai-rec-medium {
  border-left-color: #f0b64f;
}

.ai-rec-low {
  border-left-color: #24b183;
}

.ai-recommendation-item span {
  color: #5c7481;
  font-size: 13px;
  font-weight: 850;
}

.ai-recommendation-item strong {
  display: block;
  color: #13242c;
  font-size: 16px;
}

.ai-recommendation-item p {
  margin: 6px 0 0;
  color: #657a86;
  line-height: 1.55;
}

.ai-recommendation-item em {
  color: #0d6a64;
  font-style: normal;
  font-weight: 850;
  white-space: nowrap;
}

.ai-side-stack {
  display: grid;
  gap: 16px;
}

.ai-dataset-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(180px, 1fr));
  gap: 12px;
  padding: 18px 20px 20px;
}

.ai-dataset-card {
  display: grid;
  gap: 8px;
  min-height: 118px;
  padding: 16px;
  border: 1px solid rgba(199, 218, 228, 0.72);
  border-radius: var(--radius);
  background: #f9fcfb;
  color: #172a34;
  text-decoration: none;
}

.ai-dataset-card span {
  color: #0d6a64;
  font-size: 12px;
  font-weight: 850;
}

.ai-dataset-card strong {
  color: #13242c;
  line-height: 1.35;
}

.ai-dataset-card small {
  color: #607784;
}

.grid.cols-4.dashboard-metric-grid,
.grid.cols-4 {
  grid-template-columns: repeat(4, minmax(220px, 1fr));
}

.grid.cols-3 {
  grid-template-columns: repeat(3, minmax(260px, 1fr));
}

.grid.cols-2 {
  grid-template-columns: repeat(2, minmax(360px, 1fr));
}

.metric {
  position: relative;
  overflow: hidden;
  min-height: 134px;
  padding: 20px;
  border-color: rgba(199, 218, 228, 0.78);
  transition:
    border-color 180ms ease,
    box-shadow 180ms ease,
    transform 180ms ease;
}

.metric:hover {
  border-color: rgba(17, 167, 162, 0.38);
  box-shadow: 0 18px 34px rgba(50, 91, 116, 0.12);
  transform: translateY(-2px);
}

.metric::before {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 42px;
  height: 42px;
  border-radius: var(--radius);
  background: var(--sky);
  content: "";
}

.metric-success::before {
  background: var(--mint);
}

.metric-attention::before {
  background: #ffe9e4;
}

.metric .label {
  color: #587080;
  font-size: 13px;
  font-weight: 850;
}

.metric .value {
  margin-top: 12px;
  color: #12222d;
  font-size: 34px;
  font-weight: 900;
  letter-spacing: 0;
}

.metric .hint {
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
}

.compact-list {
  display: grid;
  gap: 10px;
  padding: 0;
  list-style: none;
}

.compact-list li,
.todo-list article,
.artifact-list article {
  border-color: #dbe9ef;
  border-radius: var(--radius);
  background: #fbfdff;
}

.table-wrap {
  border-color: #d8e6ee;
  border-radius: var(--radius);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75);
}

table {
  background: #ffffff;
}

th {
  background: #edf7fb;
  color: #315163;
  font-size: 12px;
}

td {
  color: #263c49;
}

tr:hover td {
  background: #f7fbff;
}

.tag,
.status,
.severity {
  min-height: 26px;
  border: 1px solid transparent;
  font-weight: 850;
}

.tag {
  border-color: #c8ebe5;
  background: #e9faf6;
  color: #087b73;
}

.status.ok,
.severity.low {
  border-color: #beeeda;
  background: var(--mint);
  color: #147a4d;
}

.status.info {
  border-color: #cde3fb;
  background: var(--sky);
  color: #2464b5;
}

.status.risk,
.severity.high {
  border-color: #ffd2ca;
  background: #fff0ed;
  color: #c7463b;
}

.severity.medium {
  border-color: #f5d99b;
  background: var(--sun);
  color: #9a6510;
}

.ingest-command-deck {
  padding: 24px;
}

.ingest-command-head {
  align-items: flex-start;
  margin-bottom: 18px;
}

.ingest-command-grid-v2 {
  grid-template-columns: minmax(340px, 0.85fr) minmax(480px, 1.05fr) minmax(280px, 0.46fr);
  gap: 14px;
}

@media (min-width: 1760px) {
  .content {
    padding-right: 40px;
    padding-left: 40px;
  }

  .ingest-command-grid-v2 {
    grid-template-columns: minmax(420px, 0.78fr) minmax(620px, 1.12fr) minmax(320px, 0.46fr);
  }

  .processing-overview-hero {
    grid-template-columns: minmax(0, 1fr) minmax(460px, 0.34fr);
  }

  .processing-file-workspace-body {
    grid-template-columns: minmax(280px, 340px) minmax(0, 1fr);
  }
}

.ingest-batch-card-v2,
.ingest-upload-card-v2,
.ingest-next-card-v2,
.ingest-current-box,
.ingest-operation-links,
.ingest-summary-card,
.ingest-checklist-card {
  border: 1px solid #d7e7ed;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: none;
  transition:
    border-color 180ms ease,
    box-shadow 180ms ease,
    transform 180ms ease,
    background 180ms ease;
}

.ingest-batch-card-v2:hover,
.ingest-upload-card-v2:hover,
.ingest-next-card-v2:hover {
  border-color: rgba(17, 167, 162, 0.36);
  box-shadow: 0 16px 30px rgba(50, 91, 116, 0.1);
  transform: translateY(-2px);
}

.ingest-upload-card-v2 {
  background:
    linear-gradient(180deg, #ffffff 0%, #f4fbf8 100%);
}

.ingest-upload-card-v2.drag-over,
.upload-box.drag-over {
  border-color: rgba(17, 167, 162, 0.62);
  background: #ecfbf7;
  box-shadow:
    0 18px 34px rgba(17, 167, 162, 0.16),
    inset 0 0 0 2px rgba(17, 167, 162, 0.18);
  transform: translateY(-2px) scale(1.005);
}

.selected-file-list {
  border: 1px dashed #bcdce3;
  border-radius: var(--radius);
  background: #f5fbfd;
  color: #587080;
}

.ingest-upload-actions {
  gap: 10px;
}

.ingest-next-card-v2 a,
.ingest-operation-links a,
.ingest-entry-card {
  border-color: #d6e6ed;
  background: #fbfdff;
}

.ingest-next-card-v2 a:hover,
.ingest-operation-links a:hover,
.ingest-entry-card:hover {
  border-color: rgba(17, 167, 162, 0.45);
  background: #effbf7;
}

.ingest-mini-metrics,
.ingest-result-metrics,
.file-parse-overview,
.processing-file-lanes-summary {
  gap: 10px;
}

.ingest-mini-metrics div,
.ingest-result-metrics > div,
.file-parse-overview > div,
.processing-file-lanes-summary div,
.merge-tile {
  border: 1px solid #d8e8ef;
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: 0 8px 18px rgba(50, 91, 116, 0.05);
}

.ingest-reception-deck {
  position: relative;
  overflow: hidden;
  border-color: rgba(97, 191, 186, 0.26);
  background:
    radial-gradient(circle at 9% 10%, rgba(124, 213, 206, 0.2), transparent 30%),
    linear-gradient(135deg, #ffffff 0%, #f4fcfb 44%, #eef8ff 100%);
}

.ingest-reception-deck::before {
  content: "";
  position: absolute;
  top: 82px;
  left: -20%;
  z-index: 0;
  width: 42%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(17, 167, 162, 0.46), transparent);
  animation: ingestScanLine 5.6s ease-in-out infinite;
}

.ingest-reception-deck > * {
  position: relative;
  z-index: 1;
}

.ingest-command-grid-v2.ingest-intake-split {
  grid-template-columns: minmax(430px, 0.54fr) minmax(430px, 0.46fr);
  height: clamp(520px, 58vh, 680px);
  min-height: 500px;
  gap: 0;
  align-items: stretch;
  overflow: hidden;
  border: 1px solid rgba(138, 201, 214, 0.36);
  border-radius: var(--radius);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(241, 251, 250, 0.78));
}

.ingest-left-workbench {
  display: grid;
  grid-template-rows: minmax(245px, 0.52fr) minmax(230px, 0.48fr);
  gap: 0;
  min-width: 0;
}

.ingest-intake-split .ingest-upload-card-v2 {
  position: relative;
  min-height: 245px;
  padding: 18px 22px 22px;
  border: 0;
  border-bottom: 1px solid rgba(138, 201, 214, 0.32);
  border-radius: 0;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(239, 253, 249, 0.94)),
    radial-gradient(circle at 84% 16%, rgba(92, 163, 232, 0.14), transparent 34%);
}

.ingest-intake-split .ingest-upload-card-v2::after {
  content: "";
  position: absolute;
  inset: 50px 18px 14px;
  border: 1px dashed rgba(97, 191, 186, 0.3);
  border-radius: calc(var(--radius) - 2px);
  pointer-events: none;
}

.ingest-upload-toolbar {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
}

.ingest-upload-toolbar span {
  margin-right: auto;
  color: #0c8f85;
  font-size: 12px;
  font-weight: 900;
}

.ingest-upload-toolbar button,
.ingest-upload-toolbar .button-link {
  min-height: 32px;
  padding: 6px 10px;
  font-size: 12px;
}

.ingest-upload-head {
  display: flex;
  position: relative;
  z-index: 1;
  gap: 14px;
  align-items: flex-start;
}

.ingest-upload-orb {
  position: relative;
  display: grid;
  flex: 0 0 54px;
  width: 54px;
  height: 54px;
  place-items: center;
  border-radius: 18px;
  background: linear-gradient(145deg, #51d3c6, #5488f8);
  animation: ingestUploadPulse 3.2s ease-in-out infinite;
}

.ingest-upload-orb::before {
  content: "";
  width: 18px;
  height: 22px;
  border: 3px solid #ffffff;
  border-top: 0;
  border-radius: 4px 4px 7px 7px;
}

.ingest-upload-orb::after {
  content: "";
  position: absolute;
  top: 15px;
  left: 50%;
  width: 12px;
  height: 12px;
  border-top: 3px solid #ffffff;
  border-left: 3px solid #ffffff;
  transform: translateX(-50%) rotate(45deg);
}

.ingest-intake-split .ingest-batch-card-v2 {
  min-height: 230px;
  padding: 22px;
  border: 0;
  border-radius: 0;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(247, 253, 250, 0.94));
}

.ingest-batch-files-panel {
  display: grid;
  min-width: 0;
  min-height: 0;
  grid-template-rows: auto minmax(0, 1fr) auto;
  align-content: stretch;
  gap: 14px;
  padding: 22px;
  border: 0;
  border-left: 1px solid rgba(17, 167, 162, 0.35);
  border-radius: 0;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(244, 252, 255, 0.92)),
    radial-gradient(circle at 92% 10%, rgba(88, 139, 248, 0.12), transparent 28%);
  box-shadow: none;
}

.ingest-batch-files-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.ingest-batch-files-head h3 {
  margin: 3px 0 3px;
  font-size: 20px;
}

.ingest-file-preview-list {
  display: grid;
  grid-template-columns: 1fr;
  align-content: start;
  gap: 10px;
  min-height: 0;
  max-height: none;
  overflow-y: auto;
  padding-right: 4px;
}

.ingest-file-preview-card {
  position: relative;
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  gap: 5px 12px;
  min-height: 72px;
  align-items: center;
  padding: 12px 14px;
  border: 1px solid rgba(205, 225, 235, 0.92);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, #ffffff, #f7fcfb);
  color: var(--ink);
  text-decoration: none;
  box-shadow: 0 10px 22px rgba(50, 91, 116, 0.075);
  animation: ingestFileAppear 360ms ease both;
  animation-delay: calc(var(--file-index) * 45ms);
  transition:
    border-color 180ms ease,
    box-shadow 180ms ease,
    transform 180ms ease;
}

.ingest-file-preview-card:hover,
.ingest-file-preview-card:focus-visible {
  border-color: rgba(17, 167, 162, 0.46);
  box-shadow: 0 18px 30px rgba(50, 91, 116, 0.11);
  transform: translateY(-2px);
}

.ingest-file-preview-card strong,
.ingest-file-preview-card small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ingest-file-preview-card strong {
  font-size: 15px;
}

.ingest-file-preview-card small {
  grid-column: 2 / 3;
  color: var(--muted);
  font-size: 12px;
}

.ingest-file-preview-card .status {
  grid-column: 3;
  grid-row: 1 / 3;
  align-self: center;
  justify-self: end;
}

.ingest-file-type {
  display: grid;
  grid-row: 1 / 3;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(145deg, #ebfffb, #eaf2ff);
  color: #257d7b;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  box-shadow: inset 0 0 0 1px rgba(17, 167, 162, 0.18);
}

.ingest-file-preview-empty {
  display: grid;
  min-height: 260px;
  place-items: center;
  align-content: center;
  gap: 10px;
  padding: 24px;
  border: 1px dashed rgba(97, 191, 186, 0.34);
  border-radius: var(--radius);
  background: rgba(247, 253, 251, 0.78);
  color: var(--muted);
  text-align: center;
}

.ingest-file-preview-empty span {
  display: block;
  width: 64px;
  height: 64px;
  border-radius: 22px;
  background:
    linear-gradient(145deg, rgba(81, 211, 198, 0.85), rgba(84, 136, 248, 0.86));
  box-shadow: 0 20px 36px rgba(17, 167, 162, 0.18);
}

.ingest-file-preview-empty strong {
  color: var(--ink);
  font-size: 18px;
}

.ingest-file-preview-empty p {
  max-width: 360px;
}

.ingest-batch-files-panel .ingest-next-card-v2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.ingest-batch-files-panel .ingest-next-card-v2 a {
  min-height: 64px;
  background: rgba(255, 255, 255, 0.72);
}

.ingest-ai-workbench {
  gap: 18px;
  padding: 24px;
  border-color: rgba(99, 178, 193, 0.28);
  background:
    radial-gradient(circle at 84% 12%, rgba(91, 119, 255, 0.08), transparent 26rem),
    radial-gradient(circle at 8% 12%, rgba(18, 198, 169, 0.12), transparent 22rem),
    linear-gradient(180deg, #fbfeff 0%, #f4fbff 100%);
}

.ingest-ai-workbench,
.ingest-ai-workbench * {
  min-width: 0;
  overflow-wrap: anywhere;
}

.ingest-ai-titlebar {
  align-items: center;
  margin-bottom: 0;
}

.ingest-ai-titlebar h2 {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin: 0 0 6px;
  font-size: clamp(28px, 2vw, 36px);
  letter-spacing: 0;
}

.ingest-smart-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 24px;
  padding: 2px 10px;
  border: 1px solid rgba(86, 165, 230, 0.22);
  border-radius: 999px;
  background: linear-gradient(135deg, #eef8ff, #f3fffb);
  color: #3c82b8;
  font-size: 12px;
  font-weight: 850;
}

.ingest-smart-badge::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #62b7ff;
  box-shadow: 0 0 0 4px rgba(98, 183, 255, 0.16);
}

.ingest-ai-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.ingest-ai-actions button {
  min-height: 42px;
  border-radius: 999px;
}

.ingest-ai-process-card,
.ingest-progress-now-card,
.ingest-ai-upload-center,
.ingest-mission-card,
.ingest-asset-flow-panel,
.ingest-distribution-map {
  border: 1px solid rgba(203, 224, 233, 0.92);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 18px 42px rgba(42, 87, 118, 0.07);
}

.ingest-ai-process-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 430px);
  gap: 22px;
  align-items: stretch;
  padding: 22px 24px;
}

.ingest-ai-process-card h3,
.ingest-progress-now-card h3,
.ingest-panel-headline h3,
.ingest-batch-files-head h3,
.ingest-distribution-map h3 {
  margin: 0;
  color: #18263a;
  font-size: 18px;
  font-weight: 900;
}

.ingest-ai-process-flow {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin-top: 22px;
}

.ingest-ai-step {
  position: relative;
  display: grid;
  gap: 6px;
  min-height: 112px;
  padding-left: 42px;
}

.ingest-ai-step::before {
  content: "";
  position: absolute;
  top: 10px;
  bottom: 18px;
  left: 14px;
  width: 2px;
  border-radius: 999px;
  background: linear-gradient(180deg, #1fb7a8, rgba(31, 183, 168, 0.12));
}

.ingest-ai-step:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 39px;
  right: -10px;
  width: 28px;
  height: 18px;
  background: linear-gradient(90deg, #36b7ac, #58a7df);
  clip-path: polygon(0 38%, 68% 38%, 68% 0, 100% 50%, 68% 100%, 68% 62%, 0 62%);
  opacity: 0.78;
}

.ingest-ai-step-icon,
.ingest-capability-chip span,
.ingest-domain-node span {
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(145deg, #e9fffb, #e8f3ff);
  color: #16877d;
  font-size: 13px;
  font-weight: 950;
  box-shadow: inset 0 0 0 1px rgba(23, 173, 162, 0.18), 0 8px 20px rgba(38, 136, 170, 0.08);
}

.ingest-ai-step-icon {
  position: absolute;
  top: 0;
  left: 0;
  width: 30px;
  height: 30px;
  border-radius: 50%;
}

.ingest-ai-step-icon::before,
.ingest-capability-chip span::before,
.ingest-domain-node span::before,
.ingest-upload-orb::before {
  content: attr(data-icon);
  font-size: 11px;
  line-height: 1;
  text-transform: uppercase;
}

.ingest-ai-step-icon[data-icon="upload"]::before,
.ingest-domain-node span[data-icon="input"]::before,
.ingest-upload-orb[data-icon="upload"]::before {
  content: "↑";
  font-size: 18px;
}

.ingest-ai-step-icon[data-icon="ai"]::before,
.ingest-capability-chip span[data-icon="scan"]::before {
  content: "AI";
}

.ingest-ai-step-icon[data-icon="parse"]::before,
.ingest-capability-chip span[data-icon="map"]::before {
  content: "↔";
  font-size: 16px;
}

.ingest-ai-step-icon[data-icon="asset"]::before,
.ingest-capability-chip span[data-icon="archive"]::before {
  content: "DB";
}

.ingest-capability-chip span[data-icon="quality"]::before {
  content: "✓";
  font-size: 16px;
}

.ingest-domain-node span[data-icon="supplier"]::before {
  content: "S";
}

.ingest-domain-node span[data-icon="material"]::before {
  content: "M";
}

.ingest-domain-node span[data-icon="order"]::before {
  content: "O";
}

.ingest-domain-node span[data-icon="contract"]::before {
  content: "C";
}

.ingest-ai-step strong {
  color: #19283d;
  font-size: 16px;
}

.ingest-ai-step small {
  color: #75869b;
  font-weight: 700;
}

.ingest-ai-step b {
  color: #172438;
  font-size: 18px;
}

.ingest-ai-engine-card {
  position: relative;
  display: grid;
  align-content: start;
  gap: 12px;
  overflow: hidden;
  min-height: 168px;
  padding: 24px;
  border-radius: 12px;
  background:
    radial-gradient(circle at 74% 50%, rgba(77, 139, 255, 0.58), transparent 28%),
    radial-gradient(circle at 76% 48%, rgba(111, 240, 255, 0.28), transparent 18%),
    linear-gradient(135deg, #081933 0%, #102d67 100%);
  color: #ffffff;
}

.ingest-ai-engine-card span {
  font-size: 16px;
  font-weight: 900;
}

.ingest-ai-engine-card strong {
  max-width: 230px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 13px;
  line-height: 1.65;
}

.ingest-ai-brain {
  position: absolute;
  right: 42px;
  top: 38px;
  width: 142px;
  height: 112px;
  border: 2px solid rgba(112, 205, 255, 0.38);
  border-radius: 58% 42% 48% 52%;
  box-shadow:
    0 0 24px rgba(88, 154, 255, 0.58),
    inset 0 0 28px rgba(88, 154, 255, 0.24);
  animation: ingestUploadPulse 3.4s ease-in-out infinite;
}

.ingest-ai-brain::before,
.ingest-ai-brain::after,
.ingest-ai-brain i {
  content: "";
  position: absolute;
  border: 1px solid rgba(125, 227, 255, 0.45);
  border-radius: 50%;
}

.ingest-ai-brain::before {
  inset: 18px 30px 18px 20px;
}

.ingest-ai-brain::after {
  inset: 34px 16px 26px 46px;
}

.ingest-ai-brain i:nth-child(1) {
  left: 38px;
  top: 28px;
  width: 10px;
  height: 10px;
  background: #75f7ff;
}

.ingest-ai-brain i:nth-child(2) {
  right: 34px;
  top: 58px;
  width: 8px;
  height: 8px;
  background: #5aa7ff;
}

.ingest-ai-brain i:nth-child(3) {
  left: 66px;
  bottom: 22px;
  width: 6px;
  height: 6px;
  background: #ffffff;
}

.ingest-progress-now-card {
  display: grid;
  gap: 16px;
  padding: 20px 24px;
}

.ingest-progress-file-row {
  display: grid;
  grid-template-columns: repeat(5, minmax(150px, 1fr)) minmax(120px, 0.5fr);
  gap: 12px;
  align-items: stretch;
}

.ingest-progress-file-card,
.ingest-progress-more {
  min-width: 0;
  border: 1px solid #dbe9ef;
  border-radius: 10px;
  background: #ffffff;
  color: var(--ink);
  text-decoration: none;
}

.ingest-progress-file-card {
  position: relative;
  display: grid;
  gap: 8px;
  min-height: 80px;
  padding: 14px 36px 12px 14px;
}

.ingest-progress-file-card strong {
  overflow: hidden;
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ingest-progress-file-card small {
  color: #3a9c91;
  font-weight: 800;
}

.ingest-progress-file-card i {
  display: block;
  height: 3px;
  overflow: hidden;
  border-radius: 999px;
  background: #e5edf3;
}

.ingest-progress-file-card i::before {
  content: "";
  display: block;
  width: var(--progress);
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #20bfae, #4d87ff);
}

.ingest-progress-file-card span {
  position: absolute;
  right: 14px;
  top: 50%;
  display: grid;
  width: 18px;
  height: 18px;
  place-items: center;
  border-radius: 50%;
  transform: translateY(-50%);
}

.ingest-progress-file-card span.done {
  background: #e7f7ef;
  color: #22a06b;
}

.ingest-progress-file-card span.done::before {
  content: "✓";
  font-size: 12px;
  font-weight: 950;
}

.ingest-progress-file-card span.running {
  border: 2px solid #5d8cff;
  border-top-color: transparent;
  animation: aiMascotHalo 1.1s linear infinite;
}

.ingest-progress-more {
  display: grid;
  min-height: 80px;
  place-items: center;
  color: #65758a;
  font-size: 13px;
  font-weight: 850;
  text-align: center;
}

.ingest-progress-empty {
  min-height: 76px;
  padding: 22px;
  border: 1px dashed #cfe2eb;
  border-radius: 10px;
  color: var(--muted);
}

.ingest-ai-main-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(360px, 0.82fr);
  gap: 18px;
  align-items: start;
}

.ingest-ai-left-column {
  display: grid;
  gap: 18px;
  min-width: 0;
}

.ingest-panel-headline {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.ingest-panel-headline p {
  margin-top: 5px;
}

.ingest-ai-upload-center {
  display: grid;
  gap: 16px;
  min-height: 420px;
  padding: 24px;
}

.ingest-ai-upload-center::after {
  display: none;
}

.ingest-ai-dropzone {
  display: grid;
  min-height: 198px;
  place-items: center;
  align-content: center;
  gap: 14px;
  border: 1.5px dashed #c8e0ec;
  border-radius: 12px;
  background:
    radial-gradient(circle at 50% 48%, rgba(81, 142, 255, 0.08), transparent 34%),
    linear-gradient(180deg, #fbfeff, #f7fcff);
  color: #1f334c;
  text-align: center;
  cursor: pointer;
  transition: border-color 180ms ease, box-shadow 180ms ease, transform 180ms ease;
}

.ingest-ai-dropzone:hover,
.ingest-upload-card-v2.drag-over .ingest-ai-dropzone {
  border-color: rgba(17, 167, 162, 0.58);
  box-shadow: 0 18px 34px rgba(17, 167, 162, 0.12);
  transform: translateY(-1px);
}

.ingest-ai-dropzone .ingest-upload-orb {
  width: 72px;
  height: 72px;
  border-radius: 24px;
}

.ingest-ai-dropzone .ingest-upload-orb::before {
  width: auto;
  height: auto;
  border: 0;
  color: #ffffff;
  font-size: 28px;
}

.ingest-ai-dropzone strong {
  display: block;
  font-size: 17px;
}

.ingest-ai-dropzone small {
  color: #76879b;
}

.ingest-upload-orb[data-icon="upload"]::after {
  display: none;
}

.ingest-ai-capabilities {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.ingest-capability-chip {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr);
  gap: 4px 10px;
  min-height: 76px;
  align-content: center;
  padding: 12px;
  border-radius: 10px;
  background: linear-gradient(180deg, #fbfdff, #f4fbff);
}

.ingest-capability-chip span {
  grid-row: span 2;
  width: 34px;
  height: 34px;
}

.ingest-capability-chip strong {
  font-size: 13px;
}

.ingest-capability-chip small {
  color: #7a8799;
  font-size: 11px;
  line-height: 1.35;
}

.ingest-mission-card {
  display: grid;
  gap: 16px;
  padding: 22px;
}

.ingest-mission-progress {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 12px;
  align-items: center;
}

.ingest-mission-progress i {
  position: relative;
  display: block;
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #e4edf1;
}

.ingest-mission-progress i::before {
  content: "";
  display: block;
  width: var(--progress);
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #1db7a6, #65a8ff);
}

.ingest-asset-flow-panel {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  min-height: 640px;
  padding: 24px;
}

.ingest-asset-flow-panel .ingest-file-preview-list {
  gap: 14px;
  max-height: min(72vh, 760px);
}

.ingest-file-preview-card.ingest-asset-card {
  grid-template-columns: 52px minmax(0, 1fr) 76px 72px auto;
  gap: 10px 14px;
  min-height: 116px;
  padding: 16px;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.96), rgba(250, 254, 255, 0.96)),
    radial-gradient(circle at 100% 50%, rgba(92, 140, 255, 0.11), transparent 35%);
}

.ingest-file-preview-card.ingest-asset-card > div {
  display: grid;
  gap: 4px;
}

.ingest-file-preview-card.ingest-asset-card small {
  grid-column: auto;
  white-space: normal;
}

.ingest-file-preview-card.ingest-asset-card .status {
  grid-column: 5;
  grid-row: 1 / 3;
}

.ingest-asset-score {
  display: grid;
  gap: 3px;
  justify-items: center;
  color: #627488;
  font-size: 11px;
}

.ingest-asset-score b {
  color: #1c314a;
  font-size: 18px;
}

.ingest-asset-ring {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border-radius: 50%;
  background:
    radial-gradient(circle at center, #ffffff 0 55%, transparent 56%),
    conic-gradient(#25b8a5 calc(var(--complete) * 1%), #e8eef5 0);
  color: #1c314a;
  font-size: 12px;
  font-weight: 900;
}

.ingest-asset-card.tone-1 .ingest-file-type,
.ingest-asset-card.tone-1 .ingest-asset-ring {
  color: #2c6fd8;
  background:
    radial-gradient(circle at center, #ffffff 0 55%, transparent 56%),
    conic-gradient(#4d8cff calc(var(--complete) * 1%), #e8eef5 0);
}

.ingest-asset-card.tone-2 .ingest-file-type,
.ingest-asset-card.tone-2 .ingest-asset-ring {
  color: #7048db;
  background:
    radial-gradient(circle at center, #ffffff 0 55%, transparent 56%),
    conic-gradient(#7d5cff calc(var(--complete) * 1%), #e8eef5 0);
}

.ingest-asset-card.tone-3 .ingest-file-type,
.ingest-asset-card.tone-3 .ingest-asset-ring {
  color: #b76c18;
  background:
    radial-gradient(circle at center, #ffffff 0 55%, transparent 56%),
    conic-gradient(#f5a941 calc(var(--complete) * 1%), #e8eef5 0);
}

.ingest-asset-card.tone-4 .ingest-file-type,
.ingest-asset-card.tone-4 .ingest-asset-ring {
  color: #1585a2;
  background:
    radial-gradient(circle at center, #ffffff 0 55%, transparent 56%),
    conic-gradient(#42bad4 calc(var(--complete) * 1%), #e8eef5 0);
}

.ingest-distribution-map {
  display: grid;
  gap: 18px;
  padding: 24px;
  overflow: hidden;
  background:
    radial-gradient(circle at 40% 55%, rgba(86, 132, 255, 0.08), transparent 28%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(247, 253, 255, 0.94));
}

.ingest-domain-flow {
  position: relative;
  display: grid;
  grid-template-columns: minmax(210px, 0.74fr) minmax(230px, 0.8fr) minmax(0, 1.6fr);
  gap: 28px;
  align-items: center;
  min-height: 150px;
  padding: 18px;
  border: 1px solid rgba(205, 225, 235, 0.8);
  border-radius: 14px;
  background:
    linear-gradient(90deg, rgba(48, 187, 175, 0.04) 1px, transparent 1px),
    linear-gradient(180deg, rgba(48, 187, 175, 0.04) 1px, transparent 1px),
    rgba(255, 255, 255, 0.72);
  background-size: 28px 28px;
}

.ingest-domain-flow::before,
.ingest-domain-flow::after {
  content: "";
  position: relative;
  position: absolute;
  top: 50%;
  z-index: 0;
  height: 2px;
  border-radius: 999px;
  background:
    linear-gradient(90deg, transparent, rgba(72, 176, 190, 0.42), rgba(88, 135, 255, 0.5), transparent);
  transform: translateY(-50%);
}

.ingest-domain-flow::before {
  left: 210px;
  width: calc(50% - 160px);
}

.ingest-domain-flow::after {
  right: 110px;
  width: calc(50% - 110px);
}

.ingest-domain-source,
.ingest-domain-engine,
.ingest-domain-node {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 6px 14px;
  align-items: center;
  min-height: 86px;
  padding: 16px 18px;
  border: 1px solid #dae9ef;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 12px 26px rgba(50, 91, 116, 0.06);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.ingest-domain-source:hover,
.ingest-domain-node:hover {
  border-color: rgba(17, 167, 162, 0.36);
  box-shadow: 0 18px 34px rgba(50, 91, 116, 0.1);
  transform: translateY(-2px);
}

.ingest-domain-source::after,
.ingest-domain-engine::after {
  content: "";
  position: absolute;
  top: 50%;
  right: -30px;
  z-index: 3;
  width: 30px;
  height: 16px;
  background: linear-gradient(90deg, #36b7ac, #5d8cff);
  clip-path: polygon(0 40%, 65% 40%, 65% 0, 100% 50%, 65% 100%, 65% 60%, 0 60%);
  transform: translateY(-50%);
}

.ingest-domain-source::before,
.ingest-domain-engine::before {
  content: "";
  position: absolute;
  top: 50%;
  right: -54px;
  z-index: 2;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #32c7b5;
  box-shadow: 0 0 0 6px rgba(50, 199, 181, 0.12), 0 0 18px rgba(50, 199, 181, 0.42);
  transform: translateY(-50%);
  animation: ingestDomainPulse 1.8s ease-in-out infinite;
}

.ingest-domain-source span,
.ingest-domain-node span {
  grid-row: span 2;
  width: 48px;
  height: 48px;
  border-radius: 14px;
}

.ingest-domain-engine {
  grid-template-columns: 78px minmax(0, 1fr);
  min-height: 112px;
  border-color: rgba(106, 141, 255, 0.18);
  background:
    radial-gradient(circle at 24% 50%, rgba(72, 126, 255, 0.18), transparent 38%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(243, 249, 255, 0.94));
}

.ingest-domain-engine > span {
  grid-row: span 2;
  display: grid;
  width: 72px;
  height: 72px;
  place-items: center;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 50%, #2449c7 0 24%, rgba(64, 157, 255, 0.9) 25% 44%, rgba(35, 199, 185, 0.2) 45% 100%);
  color: #ffffff;
  font-size: 18px;
  font-weight: 950;
  box-shadow:
    0 0 0 8px rgba(82, 152, 255, 0.08),
    0 14px 30px rgba(54, 108, 219, 0.18);
  animation: ingestDomainEngine 3.6s ease-in-out infinite;
}

.ingest-domain-engine small {
  color: #6a7890;
}

.ingest-domain-targets {
  display: grid;
  grid-template-columns: repeat(5, minmax(128px, 1fr));
  gap: 12px;
}

.ingest-domain-targets .ingest-domain-node {
  grid-template-columns: 44px minmax(0, 1fr);
  min-height: 94px;
  padding: 14px;
  animation: ingestFileAppear 360ms ease both;
  animation-delay: calc(var(--node) * 65ms);
}

.ingest-domain-targets .ingest-domain-node::before {
  content: "";
  position: absolute;
  left: -16px;
  top: 50%;
  width: 16px;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(92, 140, 255, 0.42));
  transform: translateY(-50%);
}

.ingest-domain-targets .ingest-domain-node::after {
  content: "";
  position: absolute;
  right: 12px;
  bottom: 10px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #24bfae;
  box-shadow: 0 0 0 5px rgba(36, 191, 174, 0.12);
}

.ingest-domain-targets .ingest-domain-node span {
  width: 40px;
  height: 40px;
}

.ingest-domain-node strong {
  font-size: 15px;
}

.ingest-domain-source strong,
.ingest-domain-engine strong,
.ingest-domain-node strong {
  color: #1b2b41;
  font-weight: 900;
}

.ingest-domain-node small {
  color: #6f7f92;
}

.ingest-domain-source small,
.ingest-domain-node small {
  display: block;
  margin-top: 4px;
}

.ingest-domain-node span[data-icon="risk"]::before {
  content: "R";
}

@keyframes ingestDomainPulse {
  50% {
    transform: translateY(-50%) scale(0.82);
    opacity: 0.64;
  }
}

@keyframes ingestDomainEngine {
  0%,
  100% {
    transform: scale(1);
    filter: drop-shadow(0 0 0 rgba(84, 144, 255, 0));
  }
  50% {
    transform: scale(1.035);
    filter: drop-shadow(0 0 12px rgba(84, 144, 255, 0.36));
  }
}

@media (max-width: 1440px) {
  .ingest-ai-process-card,
  .ingest-ai-main-grid {
    grid-template-columns: 1fr;
  }

  .ingest-ai-engine-card {
    min-height: 150px;
  }

  .ingest-progress-file-row {
    grid-template-columns: repeat(3, minmax(160px, 1fr));
  }

  .ingest-domain-flow {
    grid-template-columns: 1fr;
  }

  .ingest-domain-flow::before,
  .ingest-domain-flow::after,
  .ingest-domain-source::before,
  .ingest-domain-source::after,
  .ingest-domain-engine::before,
  .ingest-domain-engine::after,
  .ingest-domain-targets .ingest-domain-node::before {
    display: none;
  }

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

@media (max-width: 900px) {
  .ingest-ai-workbench {
    padding: 16px;
  }

  .ingest-ai-titlebar,
  .ingest-panel-headline {
    display: grid;
    grid-template-columns: 1fr;
  }

  .ingest-ai-actions {
    justify-content: flex-start;
  }

  .ingest-ai-process-flow,
  .ingest-ai-capabilities {
    grid-template-columns: 1fr 1fr;
  }

  .ingest-domain-targets {
    grid-template-columns: 1fr;
  }

  .ingest-progress-file-row {
    grid-template-columns: 1fr;
  }

  .ingest-file-preview-card.ingest-asset-card {
    grid-template-columns: 48px minmax(0, 1fr) auto;
  }

  .ingest-file-preview-card.ingest-asset-card .ingest-asset-score,
  .ingest-file-preview-card.ingest-asset-card .ingest-asset-ring {
    display: none;
  }

  .ingest-file-preview-card.ingest-asset-card .status {
    grid-column: 3;
  }
}

@media (max-width: 560px) {
  .ingest-ai-titlebar h2 {
    font-size: 24px;
  }

  .ingest-ai-process-flow,
  .ingest-ai-capabilities,
  .ingest-domain-flow {
    grid-template-columns: 1fr;
  }

  .ingest-ai-process-card,
  .ingest-progress-now-card,
  .ingest-ai-upload-center,
  .ingest-mission-card,
  .ingest-asset-flow-panel,
  .ingest-distribution-map {
    padding: 14px;
  }

  .ingest-ai-step:not(:last-child)::after {
    display: none;
  }

  .ingest-ai-brain {
    opacity: 0.45;
    right: 10px;
  }
}

.ingest-flow-stagebar,
.file-step-tabs {
  gap: 10px;
}

.ingest-flow-stagebar a,
.file-step-tabs a {
  border-color: #d9e9ef;
  background: #ffffff;
}

@keyframes ingestScanLine {
  0% {
    transform: translateX(-18%);
    opacity: 0;
  }
  18%,
  76% {
    opacity: 0.7;
  }
  100% {
    transform: translateX(118%);
    opacity: 0;
  }
}

@keyframes ingestUploadPulse {
  0%,
  100% {
    box-shadow:
      0 12px 28px rgba(49, 145, 199, 0.16),
      inset 0 0 0 1px rgba(255, 255, 255, 0.82);
    transform: translateY(0);
  }
  50% {
    box-shadow:
      0 20px 36px rgba(17, 167, 162, 0.22),
      inset 0 0 0 1px rgba(255, 255, 255, 0.96);
    transform: translateY(-2px);
  }
}

@keyframes ingestFileAppear {
  from {
    transform: translateY(10px);
  }
  to {
    transform: translateY(0);
  }
}

.ingest-flow-stagebar a:hover,
.ingest-flow-stagebar a:focus-visible,
.file-step-tabs a.active,
.file-step-tabs a:hover,
.file-step-tabs a:focus-visible {
  border-color: rgba(17, 167, 162, 0.46);
  background: #eafaf6;
}

.batch-card,
.file-card {
  border-color: #d9e8ef;
  border-radius: var(--radius);
  background: #ffffff;
}

.batch-card.active {
  border-color: rgba(17, 167, 162, 0.55);
  background: #effbf7;
  box-shadow: 0 0 0 4px rgba(17, 167, 162, 0.1);
}

.processing-overview-hero {
  grid-template-columns: minmax(0, 1fr) minmax(380px, 0.36fr);
  padding: 26px 28px;
}

.processing-batch-switch {
  min-width: 0;
  border-color: #d7e8ed;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 10px 22px rgba(50, 91, 116, 0.08);
}

.processing-batch-switch label,
.ingest-select-label {
  min-width: 0;
}

.processing-batch-switch select,
.ingest-select-label select {
  width: 100%;
  min-width: 0;
  max-width: 100%;
}

.processing-batch-strip {
  display: grid;
  grid-template-columns: minmax(230px, 0.28fr) minmax(0, 1fr);
  gap: 18px;
  align-items: center;
  padding: 18px 20px;
  background: #ffffff;
}

.processing-batch-strip strong {
  display: block;
  margin-top: 4px;
  font-size: 20px;
}

.processing-batch-strip small {
  display: block;
  margin-top: 5px;
  color: var(--muted);
}

.processing-batch-strip-links a {
  border-color: #d6e7ed;
  background: #f8fcff;
}

.processing-file-lanes-panel {
  padding: 22px;
  max-width: 100%;
  overflow: hidden;
  background: #ffffff;
}

.processing-file-lanes-head {
  align-items: center;
}

.processing-file-lanes-head h2 {
  font-size: 25px;
}

.processing-file-workspace-body {
  grid-template-columns: minmax(260px, 320px) minmax(0, 1fr);
  gap: 16px;
  min-width: 0;
}

.processing-file-rail {
  position: sticky;
  top: 116px;
}

.processing-file-selector-list {
  width: 100%;
  max-width: 100%;
  padding: 6px 6px 6px 0;
}

.processing-file-selector {
  flex: 0 0 auto;
  height: auto;
  min-height: 0;
  width: 100%;
  max-width: 100%;
  align-content: start;
  align-items: stretch;
  overflow: visible;
  border-color: #d8e7ee;
  border-radius: var(--radius);
  background: #fbfdff;
  transition:
    border-color 160ms ease,
    background 160ms ease,
    box-shadow 160ms ease,
    transform 160ms ease;
}

.processing-file-selector:hover,
.processing-file-selector:focus-visible,
.processing-file-selector.active {
  border-color: rgba(17, 167, 162, 0.5);
  background: #edfbf7;
  transform: translateX(2px);
}

.processing-file-selector-head {
  grid-template-columns: minmax(0, 1fr) auto;
}

.processing-file-selector-head em {
  justify-self: end;
}

.processing-file-selector.active {
  box-shadow:
    inset 4px 0 0 var(--teal),
    0 10px 20px rgba(17, 167, 162, 0.09);
}

.processing-file-scroll {
  padding: 0;
  min-width: 0;
  max-width: 100%;
  overflow-x: auto;
}

.processing-file-scroll .ingest-flow-lane,
.document-trace-studio {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  border: 1px solid #d7e7ed;
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: 0 14px 30px rgba(50, 91, 116, 0.08);
  animation: workspaceFadeUp 320ms ease both;
}

.processing-file-scroll .ingest-flow-track {
  gap: 14px;
  padding-left: 28px;
}

.processing-file-scroll .ingest-flow-track::after {
  left: 10px;
  background: linear-gradient(180deg, #13aaa1, #8fd6c4);
}

.ingest-flow-node {
  border-color: #d9e8ef;
  border-radius: var(--radius);
  background: #ffffff;
}

a.ingest-flow-node:hover,
a.ingest-flow-node:focus-visible {
  border-color: rgba(17, 167, 162, 0.48);
  box-shadow: 0 10px 22px rgba(17, 167, 162, 0.1);
  transform: translateY(-2px);
}

.ingest-flow-node.tone-ok {
  border-color: #cdeee1;
  background: #f0fcf7;
}

.ingest-flow-node.tone-warn {
  border-color: #f6deac;
  background: #fff9e9;
}

.ingest-flow-node.tone-risk {
  border-color: #ffd3ca;
  background: #fff3f1;
}

.ingest-flow-node.tone-info {
  border-color: #cfe5fb;
  background: #f2f8ff;
}

.processing-file-scroll .ingest-flow-track {
  position: relative;
  display: grid;
  --flow-card-w: clamp(188px, 12vw, 230px);
  --flow-gap: clamp(84px, 6.2vw, 118px);
  --flow-line-y: 172px;
  --flow-arrow-l: var(--flow-gap);
  grid-template-columns: repeat(5, var(--flow-card-w));
  justify-content: center;
  column-gap: var(--flow-gap);
  row-gap: 0;
  min-width: calc((var(--flow-card-w) * 5) + (var(--flow-gap) * 4) + 72px);
  min-height: 272px;
  align-items: center;
  padding: 82px 36px 46px;
  overflow: hidden;
  border: 1px solid #d7e7ed;
  border-radius: 14px;
  background:
    radial-gradient(circle at 1px 1px, rgba(41, 96, 116, 0.14) 1px, transparent 1.5px),
    radial-gradient(circle at 18% 28%, rgba(45, 183, 172, 0.1), transparent 22%),
    radial-gradient(circle at 78% 70%, rgba(91, 124, 255, 0.08), transparent 24%),
    linear-gradient(135deg, rgba(248, 252, 255, 0.96), rgba(239, 251, 247, 0.92));
  background-size: 18px 18px, auto;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.9),
    0 18px 34px rgba(50, 91, 116, 0.08);
}

.processing-file-scroll .ingest-flow-track::before {
  position: absolute;
  top: 20px;
  left: 24px;
  z-index: 3;
  display: inline-flex;
  width: auto;
  min-width: 0;
  margin: 0;
  padding: 7px 14px 7px 34px;
  border: 1px solid rgba(17, 167, 162, 0.26);
  border-radius: 999px;
  background:
    radial-gradient(circle at 17px 50%, #35bbb0 0 4px, transparent 5px),
    rgba(255, 255, 255, 0.86);
  box-shadow: 0 10px 20px rgba(50, 91, 116, 0.08);
  color: #126f70;
  content: "治理链路";
  font-size: 15px;
  font-weight: 900;
  line-height: 1.2;
}

.processing-file-scroll .ingest-flow-track::after {
  position: absolute;
  top: var(--flow-line-y);
  right: calc(3% + var(--flow-card-w) - 6px);
  left: calc(3% + var(--flow-card-w) - 8px);
  z-index: 0;
  display: none;
  width: auto;
  height: 5px;
  border: 0;
  border-radius: 999px;
  background:
    linear-gradient(90deg, rgba(54, 189, 178, 0.1), rgba(78, 145, 255, 0.38), rgba(139, 108, 255, 0.14)),
    linear-gradient(90deg, rgba(42, 183, 167, 0.46), rgba(78, 145, 255, 0.56));
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.7),
    0 0 18px rgba(78, 145, 255, 0.16);
  content: "";
  animation: lineagePathGlow 2.8s ease-in-out infinite;
}

.processing-file-scroll .ingest-flow-track > .ingest-flow-node::before,
.processing-file-scroll .ingest-flow-track > .ingest-flow-node::after {
  pointer-events: none;
}

.processing-file-scroll .ingest-flow-node {
  position: relative;
  z-index: 2;
  display: grid;
  min-height: 126px;
  align-content: start;
  gap: 6px;
  padding: 54px 16px 14px;
  border: 1px solid rgba(210, 229, 237, 0.95);
  border-radius: 12px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.74), transparent 42%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(247, 252, 255, 0.9));
  box-shadow:
    0 16px 28px rgba(50, 91, 116, 0.09),
    inset 0 1px 0 rgba(255, 255, 255, 0.95);
  transition:
    border-color 180ms ease,
    box-shadow 180ms ease,
    transform 180ms ease;
  animation: lineageNodeIn 360ms ease both;
  animation-delay: calc(var(--flow-node-index) * 70ms);
}

.processing-file-scroll a.ingest-flow-node:hover,
.processing-file-scroll a.ingest-flow-node:focus-visible {
  border-color: rgba(44, 168, 190, 0.7);
  box-shadow:
    0 20px 36px rgba(27, 129, 177, 0.16),
    0 0 0 4px rgba(17, 167, 162, 0.11);
  outline: none;
}

.processing-file-scroll .ingest-flow-node::before {
  position: absolute;
  top: 14px;
  left: 14px;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(17, 167, 162, 0.24);
  border-radius: 9px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.6), transparent),
    linear-gradient(135deg, #6fd8cb, #4e91ff);
  box-shadow: 0 10px 18px rgba(49, 148, 190, 0.2);
  color: #ffffff;
  content: "SQL";
  font-size: 10px;
  font-weight: 950;
  letter-spacing: 0;
  transform: none;
}

.processing-file-scroll .ingest-flow-node:nth-child(1)::before {
  content: "CSV";
}

.processing-file-scroll .ingest-flow-node:nth-child(2)::before {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.6), transparent),
    linear-gradient(135deg, #55cfb1, #4d8cff);
  content: "AI";
}

.processing-file-scroll .ingest-flow-node:nth-child(3)::before {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.6), transparent),
    linear-gradient(135deg, #4ecdc4, #23a6d5);
  content: "MAP";
}

.processing-file-scroll .ingest-flow-node:nth-child(4)::before {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.62), transparent),
    linear-gradient(135deg, #f7b955, #ff7a72);
  content: "QA";
}

.processing-file-scroll .ingest-flow-node:nth-child(5)::before {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.62), transparent),
    linear-gradient(135deg, #7a6cff, #2ab7a7);
  content: "DB";
}

.processing-file-scroll .ingest-flow-node::after {
  position: absolute;
  top: 50%;
  right: calc(-1 * var(--flow-arrow-l) - 1px);
  z-index: 4;
  display: block;
  width: calc(var(--flow-arrow-l) + 2px);
  height: 18px;
  border: 0;
  border-radius: 0;
  background:
    linear-gradient(90deg, transparent 0 8%, rgba(255, 255, 255, 0.52) 18%, transparent 30%) 0 0 / 120px 100% repeat-x,
    linear-gradient(90deg, rgba(31, 174, 164, 0.94), rgba(72, 128, 255, 1));
  box-shadow:
    0 0 18px rgba(42, 183, 167, 0.18),
    0 0 20px rgba(78, 145, 255, 0.16);
  clip-path: polygon(0 40%, calc(100% - 18px) 40%, calc(100% - 18px) 12%, 100% 50%, calc(100% - 18px) 88%, calc(100% - 18px) 60%, 0 60%);
  content: "";
  transform: translateY(-50%);
  animation: lineageArrowFlow 1.9s linear infinite;
}

.processing-file-scroll .ingest-flow-node:last-child::after {
  display: none;
}

.processing-file-scroll .ingest-flow-node:not(:last-child) > span::after {
  display: none;
  content: none;
}

.processing-file-scroll .ingest-flow-node span {
  position: relative;
  color: #265f72;
  font-size: 13px;
  font-weight: 900;
}

.processing-file-scroll .ingest-flow-node strong {
  color: #0e2838;
  font-size: 16px;
  line-height: 1.34;
}

.processing-file-scroll .ingest-flow-node small,
.processing-file-scroll .ingest-flow-dataset-list small {
  color: #63808f;
  font-size: 12px;
  line-height: 1.48;
}

.processing-file-scroll .ingest-flow-dataset-list {
  gap: 5px;
}

.processing-file-scroll .ingest-flow-dataset-list em {
  max-width: 100%;
  border-color: rgba(17, 167, 162, 0.18);
  background: rgba(235, 250, 247, 0.9);
  color: #12716f;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.processing-file-scroll .ingest-flow-node.tone-ok {
  border-color: rgba(42, 183, 167, 0.34);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(239, 253, 247, 0.92));
}

.processing-file-scroll .ingest-flow-node.tone-warn {
  border-color: rgba(247, 185, 85, 0.46);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(255, 249, 232, 0.94));
}

.processing-file-scroll .ingest-flow-node.tone-risk {
  border-color: rgba(255, 122, 114, 0.42);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(255, 243, 241, 0.94));
}

.processing-file-scroll .ingest-flow-node.tone-info {
  border-color: rgba(77, 140, 255, 0.32);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(240, 248, 255, 0.94));
}

.processing-file-scroll .ingest-flow-track > .ingest-flow-node {
  position: relative;
  width: var(--flow-card-w);
  min-width: 188px;
  max-width: 230px;
  transform: none;
}

.processing-file-scroll .ingest-flow-track > .ingest-flow-node:nth-child(1) {
  grid-column: 1;
  grid-row: 1;
}

.processing-file-scroll .ingest-flow-track > .ingest-flow-node:nth-child(2) {
  grid-column: 2;
  grid-row: 1;
}

.processing-file-scroll .ingest-flow-track > .ingest-flow-node:nth-child(3) {
  grid-column: 3;
  grid-row: 1;
}

.processing-file-scroll .ingest-flow-track > .ingest-flow-node:nth-child(4) {
  grid-column: 4;
  grid-row: 1;
}

.processing-file-scroll .ingest-flow-track > .ingest-flow-node:nth-child(5) {
  grid-column: 5;
  grid-row: 1;
}

.processing-file-scroll .ingest-flow-track > .ingest-flow-node:hover,
.processing-file-scroll .ingest-flow-track > .ingest-flow-node:focus-visible {
  transform: translateY(-6px);
}

.document-trace-hero {
  border-bottom-color: #d8e8ef;
  background:
    linear-gradient(135deg, #f5fbff 0%, #effbf7 100%);
}

.document-paper-preview,
.document-field-board,
.document-outcome-rail,
.document-field-card,
.document-score-card,
.document-risk-card,
.document-dataset-stack {
  border-color: #d8e8ef;
  border-radius: var(--radius);
}

.document-field-card:hover,
.document-field-card:focus-visible,
.document-dataset-stack a:hover,
.document-dataset-stack a:focus-visible {
  border-color: rgba(17, 167, 162, 0.48);
  background: #f0fbf7;
}

.processing-step-hero,
.file-processing-hero,
.dataset-detail-hero {
  background:
    linear-gradient(135deg, #ffffff 0%, #f1fbf8 100%);
}

.processing-flow-main,
.processing-flow-lane,
.result-card,
.drill-card,
.review-card,
.file-diagnosis-entry,
.file-dataset-output-entry,
.file-merge-entry,
.dataset-source-files article,
.file-dataset-links a {
  border-color: #d8e8ef;
  border-radius: var(--radius);
  background: #ffffff;
}

.result-card:hover,
.drill-card:hover,
.drill-card:focus-visible {
  border-color: rgba(17, 167, 162, 0.48);
  box-shadow: 0 12px 24px rgba(17, 167, 162, 0.1);
}

.drill-layer {
  grid-template-columns: minmax(0, 1fr) minmax(460px, 560px);
}

.drill-backdrop {
  background: rgba(26, 46, 56, 0.34);
  backdrop-filter: blur(6px);
}

.drill-drawer {
  border-left: 1px solid #c9dce5;
  background: #f7fbff;
  box-shadow: -24px 0 54px rgba(24, 57, 75, 0.2);
}

.drill-head {
  position: sticky;
  z-index: 2;
  top: 0;
  padding: 24px 24px 18px;
  border-bottom-color: #d8e8ef;
  background:
    linear-gradient(135deg, #ffffff 0%, #effbf7 100%);
}

.drill-head h2 {
  font-size: 24px;
}

.drill-body {
  gap: 14px;
  padding: 20px 24px 28px;
}

.drill-detail-card {
  border-color: #d6e7ed;
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: 0 10px 22px rgba(50, 91, 116, 0.06);
}

.briefing-callout {
  border-left-color: var(--teal);
  background: #eefbf7;
}

.empty,
.loading {
  border: 1px dashed #c7dce6;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.72);
  color: var(--muted);
}

.loading {
  position: relative;
  overflow: hidden;
}

.loading::after {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.72) 48%, transparent 100%);
  animation: shimmerSweep 1200ms ease-in-out infinite;
  content: "";
}

select,
input[type="text"],
textarea {
  border-color: #cfe0e8;
  background: #ffffff;
  color: var(--ink);
}

select:focus,
input[type="text"]:focus,
textarea:focus {
  border-color: rgba(17, 167, 162, 0.62);
  box-shadow: 0 0 0 4px rgba(17, 167, 162, 0.13);
  outline: none;
}

button:active,
.button-link:active,
a.ingest-flow-node:active,
.processing-file-selector:active {
  transform: translateY(0) scale(0.98);
}

@keyframes workspaceFadeUp {
  from {
    opacity: 0.98;
    transform: translateY(6px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes shimmerSweep {
  from {
    transform: translateX(-100%);
  }

  to {
    transform: translateX(100%);
  }
}

@media (prefers-reduced-motion: reduce) {
  button,
  .button-link,
  .nav a,
  .metric,
  .processing-file-selector,
  .ingest-flow-node,
  .content > .section,
  .processing-file-scroll .ingest-flow-lane,
  .document-trace-studio,
  .dataset-lineage-link,
  .loading::after {
    animation: none;
    transition: none;
  }
}

@media (max-width: 1320px) {
  .processing-file-scroll .ingest-flow-lane-body {
    grid-template-columns: 1fr;
  }

  .processing-lane-ai-summary,
  .processing-file-scroll .ingest-flow-track {
    max-width: 100%;
  }
}

@media (max-width: 980px) {
  html,
  body {
    width: 100%;
    max-width: 100vw;
    overflow-x: hidden;
  }

  body::before {
    background-size: 36px 36px;
  }

  .sidebar {
    position: static;
    width: auto;
    max-width: 100%;
    border-right: 0;
    border-bottom: 1px solid rgba(199, 218, 228, 0.72);
    box-shadow: none;
  }

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

  .nav-group {
    min-width: 0;
  }

  .nav a {
    min-width: 0;
    padding-right: 10px;
    padding-left: 30px;
    overflow-wrap: anywhere;
  }

  .nav-section-label {
    min-width: 0;
    padding-right: 10px;
    padding-left: 30px;
    overflow-wrap: anywhere;
  }

  .nav-submenu {
    margin-left: 8px;
  }

  .main {
    width: 100%;
    max-width: 100vw;
    margin-left: 0;
    overflow-x: hidden;
  }

  .topbar {
    min-height: auto;
    padding: 18px 18px;
  }

  .content {
    width: 100%;
    max-width: 100vw;
    padding: 20px 16px 34px;
    overflow-x: hidden;
  }

  .dashboard-hero,
  .ai-chat-header,
  .ai-chat-body,
  .ai-assistant-hero,
  .ai-assistant-grid,
  .ingest-command-head,
  .dataset-catalog-hero,
  .dataset-canvas-head,
  .dataset-lineage-layout,
  .dataset-lineage-list,
  .dataset-topology-grid,
  .dataset-topology-head,
  .dataset-delivery-hero,
  .dataset-delivery-layout,
  .processing-overview-hero,
  .processing-batch-strip,
  .processing-file-lanes-head,
  .processing-file-workspace-body {
    display: grid;
    grid-template-columns: 1fr;
  }

  .processing-file-workspace-body {
    grid-template-columns: minmax(240px, 300px) minmax(0, 1fr);
  }

  .grid.cols-4,
  .grid.cols-3,
  .grid.cols-2,
  .grid.cols-4.dashboard-metric-grid,
  .ai-status-grid,
  .ai-source-sync-body,
  .ai-source-channels,
  .ai-module-map,
  .ai-dataset-list,
  .dataset-catalog-hero-metrics,
  .dataset-catalog-grid,
  .dataset-delivery-card-grid,
  .ingest-command-grid-v2 {
    grid-template-columns: 1fr;
  }

  .ingest-command-grid-v2.ingest-intake-split {
    grid-template-columns: 1fr;
    height: auto;
    min-height: 0;
  }

  .ingest-left-workbench {
    grid-template-rows: auto auto;
  }

  .ingest-batch-files-panel {
    border-top: 1px solid rgba(17, 167, 162, 0.32);
    border-left: 0;
  }

  .processing-overview-hero > *,
  .processing-batch-strip > *,
  .processing-file-workspace-body > *,
  .ingest-command-grid-v2 > *,
  .ai-chat-header > *,
  .ai-chat-body > *,
  .ai-assistant-hero > *,
  .ai-assistant-grid > *,
  .dataset-catalog-hero > *,
  .dataset-canvas-head > *,
  .dataset-topology-grid > *,
  .dataset-delivery-hero > *,
  .dataset-delivery-layout > *,
  .ingest-command-deck > *,
  .ingest-batch-card-v2,
  .ingest-upload-card-v2,
  .ingest-next-card-v2,
  .panel,
  .table-wrap {
    min-width: 0;
  }

  .ingest-command-deck {
    overflow: hidden;
  }

  .ingest-batch-files-panel .ingest-next-card-v2 {
    grid-template-columns: 1fr;
  }

  .ai-chat-header {
    gap: 14px;
  }

  .ai-chat-context {
    justify-content: flex-start;
    max-width: none;
  }

  .ai-chat-context span {
    flex: 1 1 150px;
  }

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

  .ai-chat-advice-item {
    grid-template-columns: 70px minmax(0, 1fr);
  }

  .ai-chat-advice-item em {
    grid-column: 2;
    padding-right: 0;
  }

  .ai-chat-risk-panel {
    display: grid;
    align-items: start;
  }

  .ai-chat-composer {
    align-items: flex-start;
  }

  .ai-chat-composer span {
    white-space: normal;
  }

  .ingest-command-head {
    gap: 14px;
  }

  .ingest-command-head h2,
  .dashboard-hero h2,
  .ai-chat-identity h2,
  .ai-hero-copy h2,
  .processing-hero-copy h2 {
    overflow-wrap: anywhere;
  }

  .dashboard-hero h2,
  .ai-chat-identity h2,
  .ai-hero-copy h2,
  .ingest-command-head h2,
  .processing-hero-copy h2 {
    font-size: 24px;
  }

  .dashboard-hero-actions,
  .top-actions {
    justify-content: flex-start;
  }

  .ingest-command-deck,
  .ai-assistant-chat,
  .ai-assistant-hero,
  .processing-file-lanes-panel {
    padding: 18px;
  }

  .dataset-delivery-hero {
    align-items: stretch;
  }

  .dataset-delivery-hero h2 {
    font-size: 24px;
  }

  .dataset-catalog-hero h2 {
    font-size: 24px;
  }

  .dataset-canvas-board {
    min-height: 0;
    padding: 14px;
  }

  .dataset-lineage-stage {
    min-height: 640px;
  }

  .dataset-lineage-svg {
    height: 640px;
  }

  .dataset-lineage-detail-metrics {
    grid-template-columns: 1fr;
  }

  .dataset-atom-row,
  .dataset-process-row,
  .dataset-composite-row {
    grid-template-columns: 1fr;
  }

  .dataset-process-lane::before,
  .dataset-process-lane::after {
    display: none;
  }

  .dataset-process-card {
    width: min(240px, 90%);
  }

  .dataset-topology-column-title {
    position: static;
  }

  .dataset-delivery-card-grid,
  .dataset-delivery-side {
    gap: 10px;
  }

  .dataset-delivery-matrix {
    overflow-x: auto;
  }

  .ai-module-map,
  .ai-source-sync-body,
  .ai-recommendation-list,
  .ai-dataset-list {
    padding: 16px;
  }

  .ai-recommendation-item {
    grid-template-columns: 1fr;
  }

  .ai-recommendation-item em {
    white-space: normal;
  }

  .processing-file-rail {
    position: static;
  }

  .processing-file-selector-list {
    max-height: min(58vh, 620px);
    overflow-y: auto;
    padding-right: 0;
  }

  .processing-file-selector {
    min-height: 0;
    padding: 12px 14px;
    transform: none;
  }

  .processing-file-selector:hover,
  .processing-file-selector:focus-visible,
  .processing-file-selector.active {
    transform: none;
  }

  .drill-layer {
    grid-template-columns: 1fr;
  }

  .record-preview-layer {
    padding: 14px;
  }

  .record-preview-dialog {
    width: calc(100vw - 28px);
    max-height: calc(100dvh - 28px);
  }

  .file-preview-modal-meta {
    grid-template-columns: 1fr;
  }

  .drill-drawer {
    width: 100%;
  }
}

@media (max-width: 760px) {
  .processing-file-workspace-body,
  .processing-file-scroll .ingest-flow-lane-body {
    grid-template-columns: 1fr;
  }

  .ingest-file-preview-list {
    grid-template-columns: 1fr;
  }

  .dataset-delivery-facts {
    grid-template-columns: 1fr;
  }

  .processing-file-selector-list {
    max-height: none;
    overflow-y: visible;
  }
}

@media (max-width: 520px) {
  .sidebar,
  .topbar,
  .content,
  .section,
  .dashboard-hero,
  .ai-assistant-chat,
  .ai-assistant-hero,
  .dataset-catalog-hero,
  .dataset-relation-canvas,
  .dataset-topology-shell,
  .ingest-command-deck,
  .processing-overview-hero,
  .processing-file-lanes-panel,
  .panel {
    width: 100%;
    max-width: 100vw;
  }

  .sidebar {
    padding: 18px 16px;
  }

  .nav {
    grid-template-columns: 1fr;
  }

  .nav a,
  .nav-section-label {
    width: 100%;
  }

  .topbar {
    padding: 16px;
  }

  .content {
    padding: 18px 14px 32px;
  }

  .ingest-command-deck,
  .dashboard-hero,
  .ai-assistant-chat,
  .ai-assistant-hero,
  .dataset-catalog-hero,
  .dataset-relation-canvas,
  .dataset-topology-shell,
  .processing-overview-hero,
  .processing-file-lanes-panel {
    padding: 16px;
  }

  .row-actions,
  .top-actions,
  .ai-chat-actions,
  .dashboard-hero-actions,
  .ai-hero-status,
  .ingest-upload-actions {
    width: 100%;
  }

  .row-actions > *,
  .top-actions > *,
  .ai-chat-actions > *,
  .dashboard-hero-actions > *,
  .ai-hero-status > *,
  .ingest-upload-actions > * {
    flex: 1 1 auto;
    min-width: 0;
  }

  .ingest-command-head h2,
  .dashboard-hero h2,
  .ai-hero-copy h2,
  .dataset-catalog-hero h2,
  .processing-hero-copy h2 {
    font-size: 22px;
    line-height: 1.3;
  }

  .ai-command-card h3 {
    font-size: 20px;
  }

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

  .processing-file-selector-list {
    max-height: min(54vh, 560px);
    overflow-y: auto;
  }

  .processing-file-selector {
    gap: 7px;
    padding: 12px;
  }

  .processing-file-selector-head {
    align-items: flex-start;
  }

  .processing-file-selector > span:not(.processing-file-selector-head),
  .processing-file-selector small {
    line-height: 1.45;
  }
}

body[data-route="document-ai"] #import-btn,
body[data-subroute="document-ai"] #import-btn,
body[data-subroute="document-recognition"] #import-btn {
  display: none;
}

body[data-route="document-ai"] .content,
body[data-subroute="document-ai"] .content,
body[data-subroute="document-recognition"] .content {
  padding: 18px;
}

.docrec-shell {
  display: grid;
  gap: 0;
}

.docrec-workspace {
  display: grid;
  grid-template-columns: minmax(280px, 340px) minmax(420px, 0.95fr) minmax(390px, 1fr);
  gap: 14px;
  min-width: 0;
  min-height: calc(100vh - 150px);
}

.docrec-control,
.docrec-preview,
.docrec-result {
  min-width: 0;
  border: 1px solid rgba(210, 224, 224, 0.9);
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 14px 34px rgba(29, 45, 51, 0.06);
}

.docrec-control {
  display: grid;
  gap: 14px;
  align-content: start;
  padding: 14px;
}

.docrec-drop {
  display: grid;
  min-height: 172px;
  place-items: center;
  gap: 8px;
  padding: 18px;
  border: 1.5px dashed rgba(20, 122, 117, 0.34);
  border-radius: 10px;
  background: linear-gradient(180deg, #f7fbfa, #ffffff);
  color: #5f6f76;
  cursor: pointer;
  text-align: center;
}

.docrec-drop.dragover {
  border-color: #147a75;
  background: #edf8f5;
  box-shadow: 0 0 0 4px rgba(20, 122, 117, 0.1);
}

.docrec-drop-icon {
  position: relative;
  width: 48px;
  height: 56px;
  border: 2px solid rgba(20, 122, 117, 0.48);
  border-radius: 8px;
  background: #ffffff;
}

.docrec-drop-icon::before {
  position: absolute;
  top: 10px;
  right: 9px;
  left: 9px;
  height: 3px;
  border-radius: 999px;
  background: #77b8b2;
  box-shadow: 0 10px 0 #b4d8d4, 0 20px 0 #dceae8;
  content: "";
}

.docrec-drop strong {
  max-width: 100%;
  overflow: hidden;
  color: #173238;
  font-size: 15px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.docrec-drop small {
  color: #7d8c93;
}

#docrec-file-input {
  display: none;
}

.docrec-control-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.docrec-control label {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.docrec-control label span,
.docrec-switches label {
  color: #65747b;
  font-size: 12px;
  font-weight: 750;
}

.docrec-control input,
.docrec-control select {
  width: 100%;
  min-width: 0;
  min-height: 38px;
  border: 1px solid #d8e4e3;
  border-radius: 7px;
  background: #ffffff;
}

.docrec-switches {
  display: grid;
  gap: 8px;
  padding: 12px;
  border-radius: 8px;
  background: #f5faf8;
}

.docrec-advanced {
  border: 1px solid #e0e9e8;
  border-radius: 8px;
  background: #ffffff;
}

.docrec-advanced summary {
  min-height: 38px;
  padding: 10px 12px;
  color: #147a75;
  cursor: pointer;
  font-size: 13px;
  font-weight: 850;
}

.docrec-switches label {
  display: flex;
  align-items: center;
  gap: 8px;
}

.docrec-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 8px;
}

.docrec-actions button {
  width: 100%;
}

.docrec-result-file {
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  border: 1px solid #e0e9e8;
  border-radius: 8px;
  background: #fbfdfc;
}

.docrec-result-file span {
  color: #75858c;
  font-size: 12px;
}

.docrec-result-file strong {
  min-width: 0;
  overflow: hidden;
  color: #173238;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.docrec-task {
  display: grid;
  gap: 9px;
  padding: 13px;
  border: 1px solid #e0e9e8;
  border-radius: 8px;
}

.docrec-task-head,
.docrec-step {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.docrec-task-head span {
  color: #65747b;
  font-size: 12px;
}

.docrec-task-head strong {
  color: #147a75;
}

.docrec-step {
  justify-content: flex-start;
  color: #8a989e;
  font-size: 13px;
}

.docrec-step i {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #d6e1e0;
}

.docrec-step.active {
  color: #183337;
  font-weight: 800;
}

.docrec-step.active i {
  background: #22a06b;
  box-shadow: 0 0 0 4px rgba(34, 160, 107, 0.12);
}

.docrec-preview {
  display: flex;
  min-height: 0;
  flex-direction: column;
  padding: 16px;
  overflow: hidden;
}

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

.docrec-panel-head h3 {
  margin: 0;
  color: #173238;
}

.docrec-pill {
  flex: none;
  padding: 5px 10px;
  border-radius: 999px;
  background: #eef8f5;
  color: #147a75;
  font-size: 12px;
  font-weight: 800;
}

.docrec-paper {
  min-height: 0;
  flex: 1;
  overflow: auto;
  padding: 28px;
  border: 1px solid #e0e8e7;
  border-radius: 8px;
  background:
    linear-gradient(#ffffff, #ffffff) padding-box,
    linear-gradient(135deg, rgba(20, 122, 117, 0.18), rgba(46, 99, 143, 0.12)) border-box;
  color: #253940;
}

.docrec-empty-preview,
.docrec-office-preview {
  display: grid;
  place-items: center;
  text-align: center;
}

.docrec-empty-preview strong,
.docrec-office-preview strong {
  display: block;
  margin-bottom: 8px;
  color: #173238;
}

.docrec-empty-preview p,
.docrec-office-preview p {
  max-width: 440px;
  margin: 0 auto;
  color: #718087;
  line-height: 1.7;
}

.docrec-office-icon {
  display: grid;
  width: 72px;
  height: 88px;
  place-items: center;
  margin: 0 auto 14px;
  border: 1px solid rgba(20, 122, 117, 0.26);
  border-radius: 12px;
  background: linear-gradient(180deg, #f7fbfa, #ffffff);
  color: #147a75;
  font-weight: 900;
}

.docrec-file-preview {
  padding: 0;
}

.docrec-file-preview object,
.docrec-file-preview img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 560px;
  border: 0;
  object-fit: contain;
}

.docrec-page-label {
  margin-bottom: 24px;
  color: #8a989e;
  font-size: 12px;
}

.docrec-paper h4 {
  margin: 0 0 18px;
  color: #122a31;
  font-size: 24px;
  letter-spacing: 0;
}

.docrec-highlight {
  padding: 12px 14px;
  border-left: 4px solid #147a75;
  border-radius: 0 8px 8px 0;
  background: #edf8f5;
  color: #24454a;
}

.docrec-layout-lines {
  display: grid;
  gap: 10px;
  margin: 22px 0;
}

.docrec-layout-lines span {
  height: 9px;
  border-radius: 999px;
  background: #e8eeee;
}

.docrec-paper table {
  width: 100%;
  min-width: 420px;
  border-collapse: collapse;
  font-size: 13px;
}

.docrec-paper th,
.docrec-paper td {
  padding: 11px 12px;
  border: 1px solid #e5eceb;
  text-align: left;
  vertical-align: top;
}

.docrec-paper th {
  background: #f0f6f5;
  color: #147a75;
}

.docrec-result {
  display: flex;
  min-height: 0;
  flex-direction: column;
  overflow: hidden;
}

.docrec-tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  border-bottom: 1px solid #e0e9e8;
}

.docrec-tabs button {
  min-width: 0;
  min-height: 48px;
  border: 0;
  border-right: 1px solid #edf3f2;
  border-radius: 0;
  background: #ffffff;
  color: #687980;
  box-shadow: none;
  font-size: 13px;
  font-weight: 800;
}

.docrec-tabs button:last-child {
  border-right: 0;
}

.docrec-tabs button.active {
  background: #eef8f5;
  color: #147a75;
}

.docrec-result-panel {
  display: none;
  min-height: 0;
  flex: 1;
  overflow: auto;
  padding: 20px;
}

.docrec-result-panel.active {
  display: block;
}

.docrec-result-panel h3 {
  margin-bottom: 12px;
  color: #173238;
}

.docrec-result-panel p {
  color: #53666e;
  line-height: 1.8;
}

.docrec-kv {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  gap: 10px 14px;
  margin-top: 18px;
  padding: 16px;
  border-radius: 8px;
  background: #f8fbfa;
}

.docrec-kv span {
  color: #708188;
}

.docrec-kv strong {
  min-width: 0;
  color: #183337;
  overflow-wrap: anywhere;
}

.docrec-result-panel pre {
  min-height: 100%;
  margin: 0;
  overflow: auto;
  padding: 16px;
  border-radius: 8px;
  background: #102427;
  color: #d8f4ed;
  font-size: 13px;
  line-height: 1.7;
  white-space: pre-wrap;
}

.docrec-output {
  color: #334155;
  font-size: 14px;
  line-height: 1.85;
}

.docrec-output h2,
.docrec-output h3,
.docrec-output h4 {
  color: #173238;
}

.docrec-output table {
  width: 100%;
  border-collapse: collapse;
}

.docrec-output th,
.docrec-output td {
  padding: 9px 10px;
  border: 1px solid #e0e9e8;
  text-align: left;
  vertical-align: top;
}

.docrec-output th {
  background: #eef8f5;
  color: #147a75;
}

.docrec-empty-output {
  display: grid;
  min-height: 420px;
  place-items: center;
  color: #8a989e;
}

@media (max-width: 1500px) {
  .docrec-workspace {
    grid-template-columns: minmax(260px, 320px) minmax(360px, 1fr);
  }

  .docrec-result {
    grid-column: 1 / -1;
    min-height: 420px;
  }
}

@media (max-width: 920px) {
  .docrec-workspace {
    grid-template-columns: 1fr;
  }

  .docrec-workspace {
    min-height: 0;
  }

  .docrec-preview,
  .docrec-result {
    min-height: 440px;
  }
}

@media (max-width: 620px) {
  body[data-subroute="document-recognition"] .content {
    padding: 12px;
  }

  .docrec-control,
  .docrec-preview {
    padding: 14px;
  }

  .docrec-control-grid,
  .docrec-tabs,
  .docrec-kv {
    grid-template-columns: 1fr;
  }

  .docrec-tabs button {
    border-right: 0;
    border-bottom: 1px solid #edf3f2;
  }
}

.docai-shell {
  display: grid;
  grid-template-columns: minmax(320px, 420px) minmax(0, 1fr);
  min-height: calc(100vh - 130px);
  overflow: hidden;
  border: 1px solid rgba(199, 218, 228, 0.86);
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: var(--shadow-soft);
}

.docai-left-panel {
  display: flex;
  min-height: 0;
  flex-direction: column;
  border-right: 1px solid #dbe5ec;
  background: linear-gradient(180deg, #edf4fb 0%, #e7eef6 100%);
}

.docai-upload {
  display: grid;
  gap: 10px;
  padding: 18px 16px 16px;
  border-bottom: 1px solid #dbe5ec;
}

.docai-drop-zone {
  display: grid;
  min-height: 176px;
  place-items: center;
  padding: 22px;
  border: 1.5px dashed rgba(48, 142, 211, 0.52);
  border-radius: 12px;
  background:
    radial-gradient(circle at 50% 8%, rgba(94, 120, 230, 0.16), transparent 44%),
    linear-gradient(135deg, #ffffff 0%, #f5faff 100%);
  color: #475569;
  cursor: pointer;
  text-align: center;
}

.docai-drop-zone:hover,
.docai-drop-zone:focus-within,
.docai-drop-zone.dragover {
  border-color: #328ad9;
  box-shadow: 0 0 0 4px rgba(50, 138, 217, 0.1);
}

.docai-upload-mark {
  position: relative;
  width: 54px;
  height: 54px;
  border-radius: 999px;
  background: linear-gradient(135deg, #5b6ee6, #50a4e8);
  box-shadow: 0 14px 30px rgba(80, 115, 220, 0.3);
}

.docai-upload-mark::before,
.docai-upload-mark::after {
  position: absolute;
  content: "";
}

.docai-upload-mark::before {
  top: 16px;
  left: 26px;
  width: 2px;
  height: 20px;
  background: #ffffff;
}

.docai-upload-mark::after {
  top: 14px;
  left: 20px;
  width: 12px;
  height: 12px;
  border-top: 2px solid #ffffff;
  border-left: 2px solid #ffffff;
  transform: rotate(45deg);
}

.docai-drop-zone strong {
  margin-top: 10px;
  color: #334155;
  font-size: 14px;
}

.docai-drop-zone small {
  color: #8b9aaa;
}

#docai-file-input {
  display: none;
}

.is-hidden {
  display: none !important;
}

.docai-file-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) 24px;
  gap: 8px;
  align-items: center;
  min-height: 34px;
  padding: 6px 8px;
  border: 1px solid #dfe8f2;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
  font-size: 12px;
}

.docai-file-card span {
  color: #5b6ee6;
  font-weight: 800;
}

.docai-file-card strong {
  overflow: hidden;
  color: #475569;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.docai-file-card button {
  width: 24px;
  min-height: 24px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #9aa7b5;
  box-shadow: none;
}

.docai-add-file {
  min-height: 34px;
  border: 1.5px dashed #bac8ff;
  background: rgba(255, 255, 255, 0.58);
  color: #5b6ee6;
}

.docai-run-button {
  min-height: 42px;
  border: 0;
  border-radius: 8px;
  background: linear-gradient(135deg, #5b5fe8 0%, #7f8cf5 100%);
  color: #ffffff;
  font-weight: 850;
  box-shadow: 0 12px 24px rgba(91, 95, 232, 0.26);
}

.docai-status-head,
.docai-char-row,
.docai-token-row {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  padding: 7px 14px;
  border-bottom: 1px solid #dbe5ec;
  background: rgba(255, 255, 255, 0.62);
  font-size: 12px;
}

.docai-status-head strong {
  color: #64748b;
  letter-spacing: 0.04em;
}

.docai-status-head em {
  margin-left: auto;
  padding: 2px 8px;
  border: 1px solid rgba(50, 138, 217, 0.24);
  border-radius: 6px;
  background: rgba(50, 138, 217, 0.08);
  color: #2271b5;
  font-style: normal;
  font-weight: 800;
}

.docai-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #22c55e;
  box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.12);
}

.docai-status-dot.is-running {
  animation: docaiPulse 1s ease-in-out infinite;
}

@keyframes docaiPulse {
  50% {
    opacity: 0.45;
    transform: scale(0.82);
  }
}

.docai-char-row span,
.docai-token-row span {
  color: #64748b;
}

.docai-char-row strong {
  color: #2271b5;
}

.docai-token-row {
  gap: 10px;
  background: linear-gradient(90deg, rgba(240, 249, 255, 0.9), rgba(245, 250, 255, 0.9));
  overflow-x: auto;
  white-space: nowrap;
}

.docai-token-row strong {
  color: #17a36d;
}

.docai-token-row b {
  color: #2271b5;
}

.docai-log {
  display: grid;
  align-content: start;
  gap: 6px;
  min-height: 0;
  flex: 1;
  overflow-y: auto;
  padding: 10px;
}

.docai-log-entry {
  padding: 8px 10px;
  border: 1px solid #e2e8f0;
  border-left-width: 3px;
  border-radius: 5px 8px 8px 5px;
  background: rgba(255, 255, 255, 0.76);
  color: #64748b;
  font-size: 12px;
  line-height: 1.55;
}

.docai-log-entry.done {
  border-color: rgba(34, 197, 94, 0.26);
  border-left-color: #22c55e;
  background: #eefbf2;
  color: #168143;
  font-weight: 750;
}

.docai-log-entry.processing {
  border-left-color: #328ad9;
  background: #eef7ff;
  color: #2271b5;
  font-weight: 750;
}

.docai-log-entry.error {
  border-color: rgba(239, 68, 68, 0.24);
  border-left-color: #ef4444;
  background: #fff1f2;
  color: #be123c;
  font-weight: 750;
}

.docai-result {
  position: relative;
  display: flex;
  min-width: 0;
  min-height: 0;
  flex-direction: column;
  background: #ffffff;
}

.docai-result-head {
  display: flex;
  gap: 14px;
  align-items: center;
  justify-content: space-between;
  min-height: 56px;
  padding: 12px 24px;
  border-bottom: 1px solid #e8edf4;
  background: linear-gradient(135deg, #fbfdff 0%, #f7faff 100%);
}

.docai-kicker {
  display: block;
  margin-bottom: 4px;
  color: #94a3b8;
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0.06em;
}

.docai-result-head h2 {
  margin: 0;
  color: #1f2a44;
}

.docai-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.docai-export {
  border-color: #f0c46b;
  background: #fff8e8;
  color: #ad6b10;
}

.docai-source-badge {
  position: absolute;
  right: 10px;
  bottom: 8px;
  z-index: 2;
  padding: 2px 6px;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  color: #94a3b8;
  font-size: 10px;
  line-height: 1.3;
  pointer-events: none;
}

.docai-source-badge[data-source="缓存"] {
  color: #4b8a6a;
}

.docai-source-badge[data-source="API"] {
  color: #7a80d9;
}

.docai-tabs {
  display: flex;
  gap: 2px;
  padding: 0 24px;
  border-bottom: 1px solid #e8edf4;
  background: #ffffff;
}

.docai-tab {
  min-height: 44px;
  padding: 0 16px;
  border: 0;
  border-bottom: 2px solid transparent;
  border-radius: 0;
  background: transparent;
  color: #64748b;
  box-shadow: none;
}

.docai-tab:hover,
.docai-tab:focus-visible {
  box-shadow: none;
  transform: none;
}

.docai-tab.active {
  border-bottom-color: #665fe8;
  color: #5b5fe8;
}

.docai-panels {
  position: relative;
  min-height: 0;
  flex: 1;
  overflow: hidden;
}

.docai-empty-state {
  display: grid;
  min-height: 100%;
  place-content: center;
  gap: 56px;
  padding: 80px 32px;
  text-align: center;
}

.docai-empty-copy {
  display: grid;
  gap: 10px;
}

.docai-empty-copy h2 {
  margin: 0;
  background: linear-gradient(90deg, #4e7de8 0%, #28c7ad 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-size: 26px;
  font-weight: 900;
  letter-spacing: 0;
}

.docai-empty-copy p {
  margin: 0;
  color: #6f7f95;
  font-size: 14px;
}

.docai-capability-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(220px, 300px));
  gap: 32px 76px;
  justify-content: center;
  text-align: left;
}

.docai-capability-item {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

.docai-capability-icon {
  display: grid;
  width: 26px;
  height: 26px;
  place-items: center;
  border-radius: 6px;
  background: rgba(80, 115, 220, 0.12);
  color: #4e7de8;
  font-size: 13px;
  font-weight: 900;
}

.docai-capability-item strong {
  display: block;
  margin-bottom: 4px;
  color: #5b6ee6;
  font-weight: 900;
}

.docai-capability-item small {
  color: #7a8aa0;
  font-size: 13px;
  line-height: 1.45;
}

.docai-capability-item.tone-green .docai-capability-icon {
  background: rgba(34, 197, 94, 0.14);
  color: #22a35f;
}

.docai-capability-item.tone-green strong {
  color: #20a461;
}

.docai-capability-item.tone-orange .docai-capability-icon {
  background: rgba(245, 158, 11, 0.14);
  color: #c2770d;
}

.docai-capability-item.tone-orange strong {
  color: #d08318;
}

.docai-capability-item.tone-red .docai-capability-icon {
  background: rgba(239, 68, 68, 0.12);
  color: #cf4c4c;
}

.docai-capability-item.tone-red strong {
  color: #df5b5b;
}

.docai-panel {
  display: none;
  height: 100%;
  overflow-y: auto;
  padding: 24px 28px 36px;
}

.docai-panel.active {
  display: block;
}

.docai-stream-output {
  min-height: 560px;
  padding: 18px;
  overflow-x: hidden;
  overflow-y: auto;
  border: 1px solid #dfe8f2;
  border-radius: 8px;
  background: linear-gradient(180deg, #ffffff, #f8fbff);
  color: #334155;
  font-family:
    "Microsoft YaHei",
    "PingFang SC",
    "Segoe UI",
    Arial,
    sans-serif;
  font-size: 14px;
  line-height: 1.8;
  overflow-wrap: normal;
  word-break: break-word;
  white-space: normal;
}

.docai-empty-hint {
  color: #94a3b8;
}

.docai-stream-output h2,
.docai-stream-output h3,
.docai-stream-output h4,
.docai-stream-output h5,
.docai-stream-output h6 {
  margin: 18px 0 10px;
  color: #26344d;
  font-weight: 900;
  letter-spacing: 0;
}

.docai-stream-output h2 {
  padding-bottom: 10px;
  border-bottom: 1px solid #e8edf4;
  color: #1f2a44;
  font-size: 19px;
}

.docai-stream-output h3 {
  color: #2e8a63;
  font-size: 16px;
}

.docai-stream-output h4,
.docai-stream-output h5,
.docai-stream-output h6 {
  color: #b85f19;
  font-size: 14px;
}

.docai-stream-output p,
.docai-stream-output blockquote {
  margin: 0 0 12px;
}

.docai-stream-output p,
.docai-stream-output li {
  max-width: none;
  white-space: normal;
  word-break: break-word;
  overflow-wrap: normal;
}

.docai-stream-output strong {
  color: #1f2a44;
  font-weight: 900;
}

.docai-stream-output del {
  color: inherit;
  text-decoration: none;
}

.docai-stream-output code {
  padding: 1px 5px;
  border-radius: 5px;
  background: #eef4ff;
  color: #315bb8;
  font-family: Consolas, "Courier New", monospace;
  font-size: 0.92em;
}

.docai-stream-output pre {
  overflow: auto;
  margin: 12px 0 16px;
  padding: 12px;
  border: 1px solid #dfe8f2;
  border-radius: 8px;
  background: #f8fafc;
}

.docai-stream-output pre code {
  padding: 0;
  background: transparent;
  color: #334155;
}

.docai-stream-output blockquote {
  padding: 8px 12px;
  border-left: 3px solid #6d7bf2;
  border-radius: 0 6px 6px 0;
  background: #f6f8ff;
  color: #52627a;
}

.docai-stream-output ul,
.docai-stream-output ol {
  display: grid;
  gap: 6px;
  margin: 0 0 14px;
  padding-left: 24px;
}

.docai-stream-output hr {
  height: 1px;
  margin: 18px 0;
  border: 0;
  background: #e8edf4;
}

.docai-markdown-table-wrap {
  overflow-x: hidden;
  margin: 14px 0 18px;
  border: 1px solid #dfe8f2;
  border-radius: 8px;
}

.docai-markdown-table {
  width: 100%;
  min-width: 0;
  border-collapse: collapse;
  background: #ffffff;
  font-size: 13px;
}

.docai-markdown-table th,
.docai-markdown-table td {
  padding: 10px 12px;
  border-bottom: 1px solid #edf2f7;
  border-right: 1px solid #edf2f7;
  text-align: left;
  vertical-align: top;
}

.docai-markdown-table th:last-child,
.docai-markdown-table td:last-child {
  border-right: 0;
}

.docai-markdown-table th {
  background: #e9edff;
  color: #5960d2;
  font-weight: 900;
}

.docai-markdown-table tr:nth-child(even) td {
  background: #f8fafc;
}

.docai-panel-toolbar {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid #e8edf4;
}

.docai-panel-toolbar strong {
  color: #334155;
}

.docai-panel-toolbar span {
  color: #8a98aa;
  font-size: 12px;
}

.docai-metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.docai-mini-card {
  display: grid;
  gap: 6px;
  padding: 14px;
  border: 1px solid #dfe8f2;
  border-radius: 8px;
  background: linear-gradient(180deg, #ffffff, #f8fbff);
}

.docai-mini-card span,
.docai-mini-card small {
  color: #718096;
}

.docai-mini-card strong {
  color: #1f2a44;
  font-size: 18px;
}

.docai-section-block {
  margin-bottom: 22px;
}

.docai-section-block h3 {
  margin-bottom: 12px;
  color: #2f8064;
}

.docai-section-block p {
  color: #475569;
  line-height: 1.85;
}

.docai-check-list {
  display: grid;
  gap: 9px;
  margin: 0;
  padding-left: 20px;
  color: #475569;
  line-height: 1.75;
}

.docai-table-wrap {
  overflow-x: auto;
  border: 1px solid #dfe8f2;
  border-radius: 8px;
}

.docai-table-wrap table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
  font-size: 13px;
}

.docai-table-wrap th,
.docai-table-wrap td {
  padding: 11px 12px;
  border-bottom: 1px solid #edf2f7;
  text-align: left;
  vertical-align: top;
}

.docai-table-wrap th {
  background: #e9edff;
  color: #5960d2;
  font-weight: 850;
}

.docai-table-wrap tr:nth-child(even) td {
  background: #f8fafc;
}

.docai-requirement {
  display: grid;
  gap: 6px;
  margin-bottom: 12px;
}

.docai-requirement strong {
  color: #b65f18;
}

.docai-log-modal {
  position: fixed;
  z-index: 40;
  inset: 0;
  display: none;
  place-items: center;
  padding: 24px;
  background: rgba(15, 23, 42, 0.38);
}

.docai-log-modal.open {
  display: grid;
}

.docai-log-modal-card {
  width: min(780px, calc(100vw - 40px));
  max-height: min(680px, calc(100vh - 40px));
  overflow: hidden;
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 28px 70px rgba(15, 23, 42, 0.24);
}

.docai-log-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid #e8edf4;
}

.docai-log-modal-card pre {
  max-height: 560px;
  margin: 0;
  overflow: auto;
  padding: 18px;
  background: #f8fafc;
  color: #334155;
  white-space: pre-wrap;
}

@media (max-width: 1120px) {
  .docai-shell {
    grid-template-columns: 1fr;
  }

  .docai-left-panel {
    border-right: 0;
    border-bottom: 1px solid #dbe5ec;
  }

  .docai-log {
    max-height: 220px;
  }

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

@media (max-width: 620px) {
  body[data-route="document-ai"] .content,
  body[data-subroute="document-ai"] .content {
    padding: 12px;
  }

  .docai-result-head,
  .docai-tabs,
  .docai-panel {
    padding-right: 14px;
    padding-left: 14px;
  }

  .docai-result-head,
  .docai-panel-toolbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .docai-actions,
  .docai-actions button {
    width: 100%;
  }

  .docai-metric-grid {
    grid-template-columns: 1fr;
  }

  .docai-tabs {
    overflow-x: auto;
  }

  .docai-empty-state {
    gap: 32px;
    padding: 48px 18px;
  }

  .docai-capability-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
}

@media print {
  .sidebar,
  .topbar,
  .docai-left-panel,
  .docai-actions,
  .docai-tabs {
    display: none !important;
  }

  .main {
    margin-left: 0 !important;
  }

  body[data-route="document-ai"] .content,
  body[data-subroute="document-ai"] .content {
    padding: 0;
  }

  .docai-shell {
    display: block;
    min-height: 0;
    border: 0;
    box-shadow: none;
  }

  .docai-result,
  .docai-panel,
  .docai-panel.active {
    display: block;
    height: auto;
    overflow: visible;
  }

  .docai-panel:not(.active) {
    display: none;
  }
}

/* AI data officer report page */
body[data-route="ai-data-officer"] {
  --officer-ink: #10213f;
  --officer-muted: #60708f;
  --officer-line: rgba(42, 201, 188, 0.18);
  --officer-mint: #21c7a8;
  --officer-cyan: #28b9f2;
  --officer-blue: #2a72ff;
  --officer-violet: #8657ff;
  --officer-amber: #ffb44d;
  --officer-coral: #ff6f79;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 23% 6%, rgba(60, 221, 211, 0.22), transparent 24rem),
    radial-gradient(circle at 84% 12%, rgba(114, 114, 255, 0.16), transparent 25rem),
    linear-gradient(180deg, #f8fdff 0%, #f3fbff 48%, #f7fbff 100%);
}

body[data-route="ai-data-officer"] .sidebar {
  display: flex;
  flex-direction: column;
  border-right: 1px solid rgba(37, 175, 166, 0.18);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(240, 251, 250, 0.95)),
    radial-gradient(circle at 40% 4%, rgba(34, 207, 179, 0.22), transparent 14rem);
  box-shadow: 14px 0 34px rgba(33, 103, 128, 0.08);
  color: #16324f;
}

body[data-route="ai-data-officer"] .sidebar::after {
  content: "建设任务状态        运行中\A\A任务编号：DSJC-2026-0524-001\A开始时间：2026-05-23 09:18\A预计完成：2026-05-28 18:00\A\A整体进度：68%        68%";
  display: block;
  margin-top: auto;
  padding: 15px 14px 38px;
  border: 1px solid rgba(37, 175, 166, 0.16);
  border-radius: 10px;
  background:
    linear-gradient(90deg, #24c2aa 0 68%, #dceff4 68% 100%) left bottom / calc(100% - 28px) 6px no-repeat,
    rgba(248, 253, 255, 0.86);
  color: #5e718d;
  white-space: pre-line;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.65;
  box-shadow: 0 12px 26px rgba(33, 103, 128, 0.07);
}

body[data-route="ai-data-officer"] .brand {
  min-height: 82px;
  border-bottom-color: rgba(35, 181, 166, 0.2);
}

body[data-route="ai-data-officer"] .brand-mark {
  width: 52px;
  height: 52px;
  border: 0;
  background: transparent;
  box-shadow: none;
  color: transparent;
  font-size: 0;
}

body[data-route="ai-data-officer"] .brand-mark::before {
  content: "车";
  display: grid;
  width: 52px;
  height: 52px;
  place-items: center;
  border: 3px solid #df1b1f;
  color: #df1b1f;
  font-family: "Microsoft YaHei", "PingFang SC", sans-serif;
  font-size: 34px;
  font-weight: 950;
  line-height: 1;
}

body[data-route="ai-data-officer"] .brand strong {
  display: block;
  font-size: 0;
}

body[data-route="ai-data-officer"] .brand strong::before {
  content: "中国中车  CRRC";
  color: #10213f;
  font-size: 18px;
  font-weight: 950;
  letter-spacing: 0;
}

body[data-route="ai-data-officer"] .brand span {
  display: block;
  margin-top: 4px;
  font-size: 0;
}

body[data-route="ai-data-officer"] .brand span::before {
  content: "数据资产生产驾驶舱";
  color: #72819d;
  font-size: 12px;
  font-weight: 800;
}

body[data-route="ai-data-officer"] .brand span,
body[data-route="ai-data-officer"] .nav a,
body[data-route="ai-data-officer"] .nav-section-label {
  color: #60708f;
}

body[data-route="ai-data-officer"] .nav a.active,
body[data-route="ai-data-officer"] .nav a:hover {
  background: rgba(32, 201, 170, 0.12);
  color: #0f7f7a;
}

body[data-route="ai"] .main {
  background:
    radial-gradient(circle at 78% 2%, rgba(80, 162, 255, 0.13), transparent 32%),
    linear-gradient(180deg, #f7fbff 0%, #f3f8fd 52%, #f8fbff 100%);
}

body[data-route="ai"] .content {
  max-width: 1680px;
}

.ai-center-workspace {
  display: grid;
  gap: 18px;
  color: #162531;
}

.ai-center-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 20px;
  align-items: center;
  padding: 22px 24px;
  border: 1px solid rgba(207, 221, 235, 0.78);
  border-radius: 12px;
  background:
    radial-gradient(circle at 8% 0%, rgba(70, 158, 255, 0.12), transparent 36%),
    linear-gradient(135deg, #ffffff 0%, #f7fbff 56%, #f1fbff 100%);
  box-shadow: 0 16px 36px rgba(74, 105, 135, 0.09);
}

.ai-center-hero h2,
.ai-center-control h3,
.ai-center-result h3 {
  margin: 0;
  color: #132434;
  letter-spacing: 0;
}

.ai-center-hero h2 {
  margin-top: 4px;
  font-size: clamp(24px, 2.4vw, 34px);
  line-height: 1.14;
}

.ai-center-hero p {
  max-width: 720px;
  margin: 7px 0 0;
  color: #607284;
  font-size: 15px;
  line-height: 1.65;
}

.ai-center-hero-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 180px;
  padding: 11px 13px;
  border: 1px solid rgba(89, 164, 255, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 10px 22px rgba(56, 114, 170, 0.08);
}

.ai-center-live-dot {
  width: 9px;
  height: 9px;
  flex: 0 0 auto;
  border-radius: 999px;
  background: #2fc98d;
  box-shadow: 0 0 0 5px rgba(47, 201, 141, 0.14);
}

.ai-center-hero-meta strong {
  display: block;
  color: #2463e6;
  font-size: 13px;
  line-height: 1.2;
}

.ai-center-hero-meta small {
  display: block;
  max-width: 150px;
  margin-top: 2px;
  overflow: hidden;
  color: #748395;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ai-center-tool-tabs {
  display: inline-grid;
  grid-template-columns: repeat(3, minmax(168px, 1fr));
  gap: 4px;
  width: min(100%, 720px);
  padding: 5px;
  border: 1px solid #dfe8f2;
  border-radius: 999px;
  background: #eef5fb;
}

.ai-center-tool-tabs a {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  padding: 8px 13px;
  border-radius: 999px;
  color: #5f7286;
  text-decoration: none;
  transition: background 160ms ease, color 160ms ease, box-shadow 160ms ease;
}

.ai-center-tool-tabs a i,
.ai-center-panel-mark {
  display: grid;
  width: 28px;
  height: 28px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 10px;
  background: linear-gradient(135deg, #dff1ff, #f0fbff);
  color: #2b70e4;
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
}

.ai-center-tool-tabs a span {
  display: grid;
  gap: 1px;
  min-width: 0;
}

.ai-center-tool-tabs a em {
  color: #8b9aae;
  font-size: 11px;
  font-style: normal;
  font-weight: 700;
}

.ai-center-tool-tabs a strong {
  overflow: hidden;
  font-size: 13px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ai-center-tool-tabs a.active,
.ai-center-tool-tabs a:hover {
  background: #ffffff;
  color: #152b3f;
  box-shadow: 0 8px 18px rgba(60, 102, 145, 0.12);
}

.ai-center-tool-tabs a.active i,
.ai-center-tool-tabs a:hover i {
  background: linear-gradient(135deg, #3785ff, #28c2d1);
  color: #ffffff;
}

.ai-center-grid {
  display: grid;
  grid-template-columns: minmax(330px, 400px) minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.ai-center-control,
.ai-center-result {
  min-width: 0;
  border: 1px solid #e0e9f2;
  border-radius: 14px;
  background: #ffffff;
  box-shadow: 0 14px 32px rgba(72, 100, 130, 0.08);
}

.ai-center-control {
  position: sticky;
  top: 18px;
  display: grid;
  gap: 17px;
  padding: 20px;
}

.ai-center-form {
  display: grid;
  gap: 16px;
}

.ai-center-panel-head p,
.ai-center-result-head p {
  margin: 6px 0 0;
  color: #738294;
  font-size: 13px;
  line-height: 1.6;
}

.ai-center-panel-head {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.ai-center-note-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.ai-center-note-row span {
  min-width: 0;
  padding: 7px 8px;
  border: 1px solid #dbe9f6;
  border-radius: 999px;
  background: #f6fbff;
  color: #3b6f9f;
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}

.ai-center-form-section {
  display: grid;
  gap: 13px;
  padding: 14px;
  border: 1px solid #edf3f8;
  border-radius: 12px;
  background: #fbfdff;
}

.ai-center-form-section > strong {
  color: #263b4f;
  font-size: 13px;
}

.ai-center-form label {
  display: grid;
  gap: 7px;
  min-width: 0;
  color: #40566a;
  font-size: 13px;
  font-weight: 800;
}

.ai-center-form input,
.ai-center-form textarea {
  width: 100%;
  min-height: 42px;
  padding: 10px 12px;
  border: 1px solid #d8e5f0;
  border-radius: 10px;
  background: #ffffff;
  color: #172c38;
  outline: none;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.ai-center-form input:focus,
.ai-center-form textarea:focus {
  border-color: #3b82f6;
  background: #ffffff;
  box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.11);
}

.ai-center-form textarea {
  line-height: 1.65;
  resize: vertical;
}

.ai-center-form small {
  color: #798a91;
  font-size: 12px;
  font-weight: 650;
}

.ai-center-upload-field input {
  min-height: 48px;
  padding: 8px 10px;
  border-style: dashed;
  background: #f7fbff;
}

.ai-center-upload-field input::file-selector-button {
  min-height: 32px;
  margin-right: 10px;
  padding: 0 12px;
  border: 0;
  border-radius: 999px;
  background: #e6f1ff;
  color: #2563eb;
  font-weight: 850;
  cursor: pointer;
}

.ai-center-column-panel {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid #dbeafe;
  border-radius: 12px;
  background: #f8fbff;
}

.ai-center-column-panel[hidden] {
  display: none;
}

.ai-center-column-panel strong {
  color: #234052;
  font-size: 13px;
}

.ai-center-column-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ai-center-column-chips button {
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid #c9dcf5;
  border-radius: 999px;
  background: #ffffff;
  color: #2764c8;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.ai-center-column-chips button:hover {
  border-color: #3478f6;
  background: #edf6ff;
}

.ai-center-column-loading {
  color: #64798a;
  font-size: 12px;
  font-weight: 750;
}

.ai-center-runbar {
  display: grid;
  gap: 9px;
}

.ai-center-runbar .primary-button {
  width: 100%;
  min-height: 46px;
  border-radius: 12px;
  background: linear-gradient(135deg, #3478f6, #25bfd0);
  box-shadow: 0 12px 24px rgba(52, 120, 246, 0.22);
}

.ai-center-runbar span {
  color: #7a8a91;
  font-size: 12px;
  line-height: 1.5;
  text-align: center;
}

.ai-center-result {
  overflow: hidden;
}

.ai-center-result-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 18px 20px 16px;
  border-bottom: 1px solid #eef3f8;
  background: #ffffff;
}

.ai-center-result .ghost-button {
  min-height: 38px;
  padding: 9px 12px;
  border: 1px solid rgba(59, 130, 246, 0.24);
  border-radius: 10px;
  background: #f7fbff;
  color: #2563eb;
  font-weight: 850;
  cursor: pointer;
}

.ai-center-result .ghost-button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.ai-center-result-body {
  display: grid;
  gap: 16px;
  min-height: 450px;
  padding: 18px 20px 20px;
}

.ai-center-stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.ai-center-stat {
  min-width: 0;
  padding: 13px 14px;
  border: 1px solid #e1eaf4;
  border-radius: 12px;
  background: linear-gradient(180deg, #f7fbff, #ffffff);
}

.ai-center-stat span {
  display: block;
  color: #718895;
  font-size: 12px;
  font-weight: 800;
}

.ai-center-stat strong {
  display: block;
  margin-top: 5px;
  overflow: hidden;
  color: #15242d;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ai-center-section-title,
.ai-center-subtitle {
  color: #1c3347;
  font-weight: 900;
}

.ai-center-section-title {
  padding-top: 2px;
  font-size: 16px;
}

.ai-center-subtitle {
  margin: 12px 0 8px;
  font-size: 13px;
}

.ai-center-group {
  border: 1px solid #e0e9f2;
  border-radius: 12px;
  background: #ffffff;
  overflow: hidden;
}

.ai-center-group summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 15px;
  background: #fbfdff;
  cursor: pointer;
}

.ai-center-group summary strong {
  color: #172c35;
}

.ai-center-group summary span {
  color: #647b87;
  font-size: 12px;
}

.ai-center-group-body {
  display: grid;
  gap: 8px;
  padding: 0 15px 15px;
}

.ai-center-table-wrap {
  max-width: 100%;
  overflow-x: auto;
  border: 1px solid #e3ebf4;
  border-radius: 10px;
}

.ai-center-table {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
  font-size: 13px;
}

.ai-center-table th,
.ai-center-table td {
  max-width: 280px;
  padding: 10px 12px;
  border-bottom: 1px solid #eef3f8;
  text-align: left;
  vertical-align: top;
}

.ai-center-table th {
  background: #f0f7ff;
  color: #2563eb;
  font-weight: 900;
}

.ai-center-table td {
  color: #243b48;
  overflow-wrap: anywhere;
}

.ai-center-empty,
.ai-center-error {
  display: grid;
  place-items: center;
  min-height: 260px;
  padding: 30px;
  border: 1px dashed #cbdff5;
  border-radius: 14px;
  background: linear-gradient(180deg, #fbfdff, #f6fbff);
  color: #6f7f91;
  text-align: center;
}

.ai-center-empty span {
  width: 48px;
  height: 48px;
  margin-bottom: 12px;
  border-radius: 16px;
  background:
    linear-gradient(135deg, rgba(52, 120, 246, 0.18), rgba(37, 191, 208, 0.18)),
    #ffffff;
  box-shadow: inset 0 0 0 1px rgba(59, 130, 246, 0.16);
}

.ai-center-empty strong {
  color: #203548;
  font-size: 15px;
}

.ai-center-empty p {
  max-width: 360px;
  margin: 6px 0 0;
  line-height: 1.65;
}

.ai-center-error {
  display: grid;
  gap: 8px;
  min-height: auto;
  border-color: rgba(180, 59, 50, 0.32);
  background: #fff7f6;
  color: #8d2c25;
  text-align: left;
  place-items: stretch;
}

.ai-center-raw {
  border-top: 1px solid #eef3f8;
  padding-top: 12px;
}

.ai-center-raw summary {
  color: #5f7185;
  cursor: pointer;
  font-weight: 850;
}

.ai-center-raw pre {
  max-height: 360px;
  overflow: auto;
  padding: 14px;
  border-radius: 12px;
  background: #102032;
  color: #dcecff;
  font-size: 12px;
  line-height: 1.6;
}

@media (max-width: 1180px) {
  .ai-center-hero,
  .ai-center-grid {
    grid-template-columns: 1fr;
  }

  .ai-center-tool-tabs {
    width: 100%;
  }

  .ai-center-control {
    position: static;
  }

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

@media (max-width: 620px) {
  .ai-center-hero,
  .ai-center-result-head {
    align-items: flex-start;
    display: grid;
    grid-template-columns: 1fr;
  }

  .ai-center-tool-tabs,
  .ai-center-note-row,
  .ai-center-stat-grid {
    grid-template-columns: 1fr;
    border-radius: 14px;
  }

  .ai-center-control,
  .ai-center-hero,
  .ai-center-result-head,
  .ai-center-result-body {
    padding: 16px;
  }
}

body[data-route="ai-data-officer"] .topbar {
  display: none;
}

body[data-route="ai-data-officer"] .main {
  background:
    linear-gradient(90deg, rgba(27, 191, 176, 0.06) 1px, transparent 1px),
    linear-gradient(180deg, rgba(42, 114, 255, 0.04) 1px, transparent 1px);
  background-size: 42px 42px;
}

body[data-route="ai-data-officer"] .content {
  width: 100%;
  max-width: none;
  padding: 0 18px 18px;
}

.officer-page {
  display: grid;
  gap: 14px;
  color: var(--officer-ink);
  font-family:
    "Inter",
    "Microsoft YaHei",
    "PingFang SC",
    "Segoe UI",
    Arial,
    sans-serif;
}

.officer-page,
.officer-page * {
  min-width: 0;
  overflow-wrap: anywhere;
}

.officer-page a {
  color: inherit;
  text-decoration: none;
}

.officer-page svg {
  width: 1em;
  height: 1em;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.officer-report-top {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: 210px minmax(260px, 1fr) minmax(360px, 0.9fr) auto;
  gap: 18px;
  align-items: center;
  min-height: 74px;
  margin: 0 -18px 8px;
  padding: 10px 22px;
  border-bottom: 1px solid rgba(28, 68, 105, 0.11);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 14px 32px rgba(38, 92, 128, 0.08);
  backdrop-filter: blur(18px);
}

.officer-crrc-lockup {
  display: grid;
  grid-template-columns: 50px minmax(0, 1fr);
  align-items: center;
  column-gap: 10px;
  color: #101f34;
}

.officer-crrc-lockup span {
  grid-row: span 2;
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border: 3px solid #df1b1f;
  color: #df1b1f;
  font-size: 32px;
  font-weight: 950;
  line-height: 1;
}

.officer-crrc-lockup strong {
  align-self: end;
  font-size: 17px;
  font-weight: 950;
  line-height: 1;
}

.officer-crrc-lockup em {
  align-self: start;
  color: #111827;
  font-size: 26px;
  font-style: normal;
  font-weight: 950;
  letter-spacing: -0.02em;
  line-height: 1;
}

.officer-report-title h2 {
  margin: 0;
  color: #0f213d;
  font-size: clamp(22px, 1.55vw, 29px);
  font-weight: 950;
  line-height: 1.1;
  white-space: nowrap;
}

.officer-report-title p {
  margin: 5px 0 0;
  color: #667995;
  font-size: 13px;
  font-weight: 750;
}

.officer-report-context {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid rgba(34, 111, 169, 0.14);
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(38, 92, 128, 0.06);
}

.officer-report-context span {
  color: #51647f;
  font-size: 13px;
  font-weight: 900;
  white-space: nowrap;
}

.officer-report-context select {
  min-width: 0;
  border: 0;
  background: transparent;
  color: #10213f;
  font-size: 14px;
  font-weight: 950;
  outline: none;
}

.officer-report-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 14px;
  color: #10213f;
  font-weight: 900;
  white-space: nowrap;
}

.officer-date,
.officer-alert,
.officer-agent-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.officer-date svg,
.officer-alert svg {
  color: #44617f;
  font-size: 18px;
}

.officer-alert {
  width: 36px;
  height: 36px;
  justify-content: center;
  border-radius: 999px;
  background: #f5fbff;
}

.officer-agent-pill {
  min-height: 38px;
  padding: 0 14px 0 10px;
  border: 1px solid rgba(27, 191, 176, 0.22);
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(233, 255, 249, 0.94), rgba(246, 253, 255, 0.94));
  color: #07917d;
  box-shadow: 0 10px 22px rgba(22, 168, 177, 0.14);
}

.officer-agent-pill svg {
  width: 26px;
  height: 26px;
  padding: 4px;
  border-radius: 50%;
  background: #10213f;
  color: #6ff7f4;
  stroke-width: 1.8;
}

.officer-report-ticker {
  grid-column: 1 / -1;
  display: none;
  gap: 10px;
  color: #708098;
  font-size: 12px;
  font-weight: 850;
}

.officer-hero,
.officer-section,
.officer-panel,
.officer-footer {
  max-width: 100%;
  border: 1px solid rgba(54, 199, 190, 0.18);
  border-radius: 14px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.93), rgba(244, 254, 255, 0.88)),
    linear-gradient(180deg, rgba(32, 205, 176, 0.08), transparent);
  box-shadow: 0 18px 48px rgba(42, 114, 255, 0.08);
}

.officer-upper-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(330px, 360px);
  gap: 14px;
  align-items: stretch;
}

.officer-upper-main {
  display: grid;
  gap: 14px;
  min-width: 0;
}

.officer-hero {
  display: grid;
  grid-template-columns: 160px minmax(220px, 0.72fr) minmax(360px, 1.28fr);
  gap: 18px;
  align-items: center;
  min-height: 188px;
  padding: 18px;
  overflow: hidden;
  position: relative;
}

.officer-hero::before {
  content: "";
  position: absolute;
  inset: -35% -10% auto 35%;
  height: 250px;
  background: linear-gradient(100deg, rgba(41, 211, 185, 0.26), rgba(77, 164, 255, 0.1), transparent);
  filter: blur(2px);
  transform: rotate(-5deg);
}

.officer-bot-card,
.officer-hero-copy,
.officer-ask,
.officer-insight-card {
  position: relative;
  z-index: 1;
}

.officer-bot-card {
  display: grid;
  min-height: 188px;
  place-items: center;
}

.officer-bot-halo {
  position: absolute;
  width: 138px;
  height: 138px;
  border-radius: 50%;
  background: conic-gradient(from 210deg, rgba(33, 199, 168, 0.14), rgba(42, 114, 255, 0.24), rgba(134, 87, 255, 0.15), rgba(33, 199, 168, 0.14));
  animation: officerSpin 9s linear infinite;
}

.officer-bot {
  position: relative;
  width: 106px;
  height: 142px;
  animation: officerFloat 4s ease-in-out infinite;
}

.officer-bot::before,
.officer-bot::after {
  content: "";
  position: absolute;
  top: 92px;
  z-index: -1;
  width: 22px;
  height: 54px;
  border: 1px solid rgba(33, 199, 168, 0.22);
  border-radius: 16px;
  background: linear-gradient(180deg, #ffffff, #dff8fb);
  box-shadow: 0 12px 22px rgba(39, 121, 158, 0.12);
}

.officer-bot::before {
  left: 3px;
  transform: rotate(14deg);
}

.officer-bot::after {
  right: 3px;
  transform: rotate(-14deg);
}

.officer-bot-face {
  position: absolute;
  inset: 18px 10px auto;
  display: flex;
  height: 62px;
  align-items: center;
  justify-content: center;
  gap: 16px;
  border: 1px solid rgba(33, 199, 168, 0.28);
  border-radius: 32px;
  background: linear-gradient(180deg, #ffffff, #dff8fb);
  box-shadow: inset 0 -12px 20px rgba(42, 114, 255, 0.08), 0 18px 28px rgba(39, 121, 158, 0.18);
}

.officer-bot-face::before {
  content: "";
  position: absolute;
  inset: 9px 16px;
  border-radius: 22px;
  background: #15334e;
}

.officer-bot-face i {
  position: relative;
  z-index: 1;
  width: 11px;
  height: 16px;
  border-radius: 12px;
  background: #35f1ff;
  box-shadow: 0 0 16px rgba(53, 241, 255, 0.75);
}

.officer-bot-body {
  position: absolute;
  inset: 82px 20px 0;
  border: 1px solid rgba(33, 199, 168, 0.24);
  border-radius: 26px 26px 34px 34px;
  background: linear-gradient(180deg, #ffffff, #e9fbff);
  box-shadow: 0 18px 30px rgba(42, 114, 255, 0.12);
}

.officer-bot-body::after {
  content: "";
  position: absolute;
  inset: 18px auto auto 50%;
  width: 16px;
  height: 16px;
  border: 4px solid #92f3df;
  border-radius: 50%;
  transform: translateX(-50%);
}

.officer-bot-ear {
  position: absolute;
  top: 39px;
  width: 14px;
  height: 26px;
  border-radius: 10px;
  background: #c9f6f4;
}

.officer-bot-ear.left {
  left: 1px;
}

.officer-bot-ear.right {
  right: 1px;
}

.officer-title-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-bottom: 8px;
}

.officer-title-row h2 {
  margin: 0;
  font-size: clamp(30px, 3vw, 48px);
  line-height: 1;
}

.officer-title-row span {
  padding: 5px 12px;
  border: 1px solid rgba(33, 199, 168, 0.3);
  border-radius: 999px;
  background: rgba(33, 199, 168, 0.12);
  color: #0a907f;
  font-size: 13px;
  font-weight: 800;
}

.officer-hero-copy p {
  max-width: 34rem;
  margin: 0 0 16px;
  color: var(--officer-muted);
  font-size: 15px;
  line-height: 1.7;
}

.officer-batch-select {
  display: grid;
  gap: 6px;
  max-width: 360px;
  color: #65728e;
  font-size: 12px;
  font-weight: 800;
}

.officer-batch-select select {
  width: 100%;
  min-height: 38px;
  border: 1px solid rgba(42, 114, 255, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--officer-ink);
}

.officer-ask {
  display: grid;
  gap: 12px;
  padding: 18px;
  border: 1px solid rgba(33, 199, 168, 0.26);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.68);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.65);
}

.officer-ask label {
  color: #65728e;
  font-size: 13px;
  font-weight: 700;
}

.officer-ask-input {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 48px;
  gap: 10px;
}

.officer-ask-input input {
  width: 100%;
  min-width: 0;
  min-height: 48px;
  padding: 0 15px;
  border: 1px solid rgba(42, 114, 255, 0.16);
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.94);
  color: var(--officer-ink);
  outline: none;
}

.officer-ask-input input:focus {
  border-color: rgba(33, 199, 168, 0.72);
  box-shadow: 0 0 0 4px rgba(33, 199, 168, 0.13);
}

.officer-ask-input button {
  display: grid;
  min-width: 48px;
  min-height: 48px;
  place-items: center;
  border: 0;
  border-radius: 10px;
  background: linear-gradient(135deg, #0bb895, #0589e9);
  box-shadow: 0 12px 28px rgba(23, 149, 186, 0.28);
  cursor: pointer;
}

.officer-ask-input button svg {
  color: #ffffff;
  font-size: 24px;
  stroke-width: 2.4;
  transform: translateX(1px);
}

.officer-prompts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.officer-prompts button {
  min-height: 32px;
  padding: 0 12px;
  border: 1px solid rgba(42, 114, 255, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  color: #52617f;
  cursor: pointer;
  font-size: 12px;
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.officer-prompts button:hover,
.officer-ask-input button:hover {
  transform: translateY(-2px);
}

.officer-prompts button:hover {
  border-color: rgba(33, 199, 168, 0.52);
  box-shadow: 0 8px 18px rgba(42, 114, 255, 0.08);
}

.officer-insight-card {
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid rgba(42, 114, 255, 0.14);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.72);
}

.officer-card-head,
.officer-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.officer-card-head h3,
.officer-section-head h3 {
  margin: 0;
  color: var(--officer-ink);
  font-size: 17px;
}

.officer-section-head a,
.officer-card-head a {
  color: #0b9c8f;
  font-size: 13px;
  font-weight: 800;
}

.officer-answer {
  min-height: 86px;
  padding: 12px;
  border-radius: 10px;
  background: linear-gradient(135deg, rgba(33, 199, 168, 0.1), rgba(42, 114, 255, 0.08));
}

.officer-answer strong {
  display: block;
  margin-bottom: 7px;
  font-size: 15px;
}

.officer-answer p {
  margin: 0;
  color: var(--officer-muted);
  font-size: 13px;
  line-height: 1.65;
}

.officer-answer.pulse {
  animation: officerPulse 520ms ease;
}

.officer-insight-list {
  display: grid;
  gap: 8px;
  margin: 0;
}

.officer-insight-list div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.officer-insight-list dt {
  color: #60708f;
  font-size: 12px;
  font-weight: 750;
}

.officer-insight-list dd {
  margin: 0;
  color: var(--officer-ink);
  font-size: 13px;
  font-weight: 850;
  text-align: right;
}

.officer-primary-link {
  display: grid;
  min-height: 40px;
  place-items: center;
  border-radius: 8px;
  background: linear-gradient(135deg, #1ab999, #1186e8);
  color: #ffffff !important;
  font-weight: 850;
  box-shadow: 0 12px 26px rgba(23, 149, 186, 0.24);
}

.officer-section {
  padding: 16px;
}

.officer-section-head {
  margin-bottom: 14px;
}

.officer-section-head h3 strong {
  color: #0aaa94;
}

.officer-section-head span {
  color: #0b9c8f;
  font-size: 13px;
  font-weight: 850;
}

.officer-dataset-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(118px, 1fr));
  gap: 10px;
}

.officer-dataset-card {
  position: relative;
  display: grid;
  min-height: 145px;
  gap: 8px;
  align-content: start;
  overflow: hidden;
  padding: 14px 12px;
  border: 1px solid rgba(42, 114, 255, 0.12);
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 10px 24px rgba(33, 103, 128, 0.07);
  animation: officerRise 520ms ease both;
  animation-delay: calc(var(--card-index) * 55ms);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.officer-dataset-card::after {
  content: "";
  position: absolute;
  inset: 0 auto auto -42%;
  width: 42%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.64), transparent);
  transform: skewX(-18deg);
  transition: transform 520ms ease;
}

.officer-dataset-card:hover,
.officer-panel:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 42px rgba(42, 114, 255, 0.12);
}

.officer-dataset-card:hover::after {
  transform: translateX(330%) skewX(-18deg);
}

.officer-card-icon {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--card-a), var(--card-b));
  box-shadow: 0 10px 18px var(--card-shadow);
  color: #ffffff;
  font-size: 20px;
}

.officer-card-icon svg {
  stroke-width: 2.25;
}

.officer-dataset-card strong {
  min-height: 38px;
  color: #1a2a4b;
  font-size: 15px;
  line-height: 1.35;
}

.officer-dataset-card em,
.officer-dataset-card small {
  color: #54637f;
  font-style: normal;
  font-weight: 750;
}

.officer-dataset-card i {
  display: block;
  width: 100%;
  height: 6px;
  margin-top: auto;
  overflow: hidden;
  border-radius: 999px;
  background: #e7eef6;
}

.officer-dataset-card i::before {
  content: "";
  display: block;
  width: var(--score);
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--card-a), var(--card-b));
  animation: officerBar 900ms ease both;
}

.tone-blue {
  --card-a: #2a72ff;
  --card-b: #3bd9ff;
  --card-shadow: rgba(42, 114, 255, 0.18);
}

.tone-mint {
  --card-a: #1fc69f;
  --card-b: #6df2c4;
  --card-shadow: rgba(31, 198, 159, 0.18);
}

.tone-violet {
  --card-a: #8057ff;
  --card-b: #c084fc;
  --card-shadow: rgba(128, 87, 255, 0.18);
}

.tone-amber {
  --card-a: #ffb23f;
  --card-b: #ffdf80;
  --card-shadow: rgba(255, 178, 63, 0.2);
}

.tone-cyan {
  --card-a: #14b8d6;
  --card-b: #79f2ff;
  --card-shadow: rgba(20, 184, 214, 0.18);
}

.tone-coral {
  --card-a: #ff6f79;
  --card-b: #ffb28c;
  --card-shadow: rgba(255, 111, 121, 0.18);
}

.officer-main-grid {
  display: grid;
  grid-template-columns: 1.35fr 1fr 1.05fr;
  gap: 14px;
}

.officer-panel {
  min-width: 0;
  padding: 16px;
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.officer-pipeline-progress {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #e8f1f6;
}

.officer-pipeline-progress i {
  display: block;
  width: var(--progress);
  height: 100%;
  border-radius: inherit;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.62), transparent 22%, rgba(255, 255, 255, 0.4) 44%, transparent 58%),
    linear-gradient(90deg, #17c9a4, #2a72ff, #8657ff);
  background-size: 180px 100%, 100% 100%;
  animation: officerBar 1000ms ease both;
}

.officer-pipeline {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
  margin-top: 18px;
}

.officer-pipeline-node {
  position: relative;
  display: grid;
  min-height: 174px;
  gap: 8px;
  align-content: start;
  padding: 12px 10px 13px;
  border: 1px solid rgba(42, 114, 255, 0.12);
  border-radius: 12px;
  background:
    radial-gradient(circle at 50% 14%, var(--card-shadow), transparent 46%),
    linear-gradient(180deg, #ffffff, #f4fbff);
  animation: officerRise 520ms ease both;
  animation-delay: calc(var(--step) * 70ms);
}

.officer-pipeline-node::after {
  content: "";
  position: absolute;
  top: 37px;
  right: -11px;
  z-index: 2;
  width: 18px;
  height: 10px;
  background: linear-gradient(90deg, #20c7a8, #2a72ff);
  clip-path: polygon(0 38%, 68% 38%, 68% 0, 100% 50%, 68% 100%, 68% 62%, 0 62%);
}

.officer-pipeline-node:last-child::after {
  display: none;
}

.officer-flow-icon {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border-radius: 15px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.26), transparent 44%),
    linear-gradient(135deg, var(--card-a), var(--card-b));
  color: #ffffff;
  font-size: 30px;
  box-shadow: 0 16px 24px var(--card-shadow), inset 0 0 0 1px rgba(255, 255, 255, 0.36);
}

.officer-pipeline-node.done span::before,
.officer-pipeline-node.active span::before {
  display: none;
}

.officer-pipeline-node.active .officer-flow-icon {
  animation: officerPing 1.6s ease infinite;
}

.officer-flow-icon svg {
  stroke-width: 2.1;
}

.officer-pipeline-node strong {
  margin-top: 2px;
  color: #1b2b4a;
  font-size: 14px;
  line-height: 1.25;
}

.officer-pipeline-node em {
  width: fit-content;
  padding: 4px 7px;
  border-radius: 999px;
  background: rgba(33, 199, 168, 0.11);
  color: #0c927d;
  font-size: 12px;
  font-style: normal;
  font-weight: 850;
}

.officer-pipeline-node small {
  color: #63708b;
  font-size: 12px;
  line-height: 1.45;
}

.officer-knowledge {
  display: grid;
  grid-template-columns: minmax(230px, 1fr) minmax(120px, 0.62fr);
  gap: 12px;
  align-items: center;
}

.officer-orbit {
  position: relative;
  min-height: 306px;
}

.officer-orbit::before {
  content: "";
  position: absolute;
  inset: 28px;
  border: 1px dashed rgba(42, 114, 255, 0.25);
  border-radius: 50%;
  animation: officerSpin 18s linear infinite;
}

.officer-orbit-line {
  position: absolute;
  inset: 62px 36px;
  border: 1px dashed rgba(33, 199, 168, 0.23);
  border-radius: 50%;
}

.officer-orbit-line.two {
  inset: 90px 76px;
}

.officer-orbit-center,
.officer-orbit-node {
  position: absolute;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #ffffff;
  text-align: center;
  box-shadow: 0 16px 28px rgba(42, 114, 255, 0.18);
}

.officer-orbit-center {
  top: 50%;
  left: 50%;
  width: 86px;
  height: 86px;
  background: linear-gradient(135deg, #16b78f, #22d3c5);
  transform: translate(-50%, -50%);
}

.officer-orbit-center strong,
.officer-orbit-node strong {
  font-size: 14px;
}

.officer-orbit-center em,
.officer-orbit-node span {
  font-style: normal;
  font-size: 12px;
  opacity: 0.9;
}

.officer-orbit-node {
  width: 72px;
  height: 72px;
  padding: 8px;
  background: linear-gradient(135deg, var(--card-a), var(--card-b));
  animation: officerRise 560ms ease both;
  animation-delay: calc(var(--node) * 80ms);
}

.officer-orbit-node.node-0 {
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
}

.officer-orbit-node.node-1 {
  top: 94px;
  right: 10px;
}

.officer-orbit-node.node-2 {
  right: 54px;
  bottom: 18px;
}

.officer-orbit-node.node-3 {
  bottom: 28px;
  left: 36px;
}

.officer-orbit-node.node-4 {
  top: 94px;
  left: 2px;
}

.officer-graph-stats {
  display: grid;
  gap: 10px;
}

.officer-graph-stats div {
  display: grid;
  gap: 2px;
  padding: 10px;
  border-radius: 10px;
  background: rgba(244, 251, 255, 0.9);
}

.officer-graph-stats span,
.officer-graph-stats small {
  color: #65728e;
  font-size: 12px;
}

.officer-graph-stats strong {
  color: #13a994;
  font-size: 20px;
}

.officer-health-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.officer-health-card {
  min-width: 0;
  padding: 13px;
  border: 1px solid rgba(42, 114, 255, 0.11);
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.86);
}

.officer-health-card span,
.officer-health-card small {
  display: block;
  color: #64718d;
  font-size: 12px;
  font-weight: 750;
}

.officer-health-card strong {
  display: block;
  margin: 8px 0 2px;
  color: #18304e;
  font-size: 23px;
}

.officer-health-card svg {
  display: block;
  width: 100%;
  height: 44px;
  margin-top: 6px;
}

.officer-health-card path {
  fill: none;
  stroke: var(--card-a);
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 3;
  filter: drop-shadow(0 6px 8px var(--card-shadow));
  stroke-dasharray: 130;
  stroke-dashoffset: 130;
  animation: officerDraw 1000ms ease forwards;
}

.officer-bottom-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(360px, 0.75fr);
  gap: 14px;
}

.officer-asset-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.officer-asset-card {
  position: relative;
  display: grid;
  min-height: 148px;
  gap: 14px;
  overflow: hidden;
  padding: 16px;
  border: 1px solid rgba(42, 114, 255, 0.12);
  border-radius: 12px;
  background:
    radial-gradient(circle at 10% 10%, var(--card-shadow), transparent 42%),
    rgba(255, 255, 255, 0.88);
  box-shadow: 0 10px 24px rgba(33, 103, 128, 0.07);
  animation: officerRise 520ms ease both;
  animation-delay: calc(var(--asset-index) * 55ms);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.officer-asset-card::after {
  content: "";
  position: absolute;
  inset: auto -20% -42% auto;
  width: 104px;
  height: 104px;
  border-radius: 50%;
  background: var(--card-shadow);
}

.officer-asset-card:hover {
  border-color: rgba(33, 199, 168, 0.28);
  box-shadow: 0 18px 42px rgba(42, 114, 255, 0.12);
  transform: translateY(-2px);
}

.officer-asset-top {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

.officer-asset-icon {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 13px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.24), transparent 44%),
    linear-gradient(135deg, var(--card-a), var(--card-b));
  color: #ffffff;
  font-size: 24px;
  box-shadow: 0 14px 22px var(--card-shadow);
}

.officer-asset-icon svg {
  stroke-width: 2.2;
}

.officer-asset-top strong,
.officer-asset-top small {
  display: block;
  min-width: 0;
}

.officer-asset-top strong {
  color: #1b2b4a;
  font-size: 15px;
  line-height: 1.35;
}

.officer-asset-top small {
  display: block;
  max-height: 34px;
  margin-top: 4px;
  overflow: hidden;
  color: #6a7890;
  font-size: 12px;
  line-height: 1.45;
}

.officer-asset-metrics {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.officer-asset-metrics span {
  display: grid;
  gap: 4px;
  color: #687994;
  font-size: 12px;
  font-weight: 750;
}

.officer-asset-metrics b {
  color: #18304e;
  font-size: 15px;
}

.officer-asset-foot {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: auto;
}

.officer-table-wrap {
  overflow-x: auto;
}

.officer-table-wrap table {
  width: 100%;
  min-width: 720px;
  border-collapse: collapse;
}

.officer-table-wrap th,
.officer-table-wrap td {
  padding: 12px 10px;
  border-bottom: 1px solid rgba(42, 114, 255, 0.08);
  text-align: left;
}

.officer-table-wrap th {
  color: #60708f;
  font-size: 12px;
}

.officer-table-wrap td {
  color: #22334f;
  font-size: 13px;
}

.officer-table-wrap td strong,
.officer-table-wrap td small {
  display: block;
}

.officer-table-wrap td small {
  margin-top: 3px;
  color: #78849a;
}

.officer-stars {
  color: #19b99a;
  letter-spacing: 2px;
}

.officer-state {
  display: inline-grid;
  min-width: 48px;
  place-items: center;
  padding: 5px 9px;
  border-radius: 999px;
  font-weight: 850;
}

.officer-state.ok {
  background: rgba(33, 199, 168, 0.12);
  color: #0d967f;
}

.officer-state.info {
  background: rgba(42, 114, 255, 0.1);
  color: #2a72ff;
}

.officer-state.warn {
  background: rgba(255, 180, 77, 0.16);
  color: #b57000;
}

.officer-app-matrix {
  display: grid;
  grid-template-columns: 160px minmax(0, 1fr);
  gap: 16px;
  align-items: center;
}

.officer-donut {
  display: grid;
  width: 150px;
  height: 150px;
  place-items: center;
  border-radius: 50%;
  background:
    radial-gradient(circle, #ffffff 0 48%, transparent 49%),
    conic-gradient(#2a72ff 0 calc(var(--a) * 1%), #21c7a8 0 calc((var(--a) + var(--b)) * 1%), #ffb44d 0 calc((var(--a) + var(--b) + var(--c)) * 1%), #ff6f79 0);
  box-shadow: 0 16px 28px rgba(42, 114, 255, 0.12);
}

.officer-donut strong,
.officer-donut span {
  grid-area: 1 / 1;
}

.officer-donut strong {
  margin-top: -12px;
  font-size: 23px;
}

.officer-donut span {
  margin-top: 36px;
  color: #64718d;
  font-size: 12px;
  font-weight: 800;
}

.officer-app-list {
  display: grid;
  gap: 11px;
}

.officer-app-list div {
  display: grid;
  grid-template-columns: 12px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
}

.officer-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--card-a);
}

.officer-app-list strong {
  min-width: 0;
  color: #243752;
  font-size: 13px;
}

.officer-app-list em {
  color: #61708c;
  font-size: 12px;
  font-style: normal;
}

.officer-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
  padding: 14px 18px;
  color: #60708f;
  font-size: 13px;
}

.officer-footer strong {
  color: #173453;
}

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

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

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

@keyframes aiMascotBlink {
  0%,
  8%,
  100% {
    transform: scaleY(1);
  }

  4% {
    transform: scaleY(0.35);
  }

  52% {
    box-shadow: 0 0 20px rgba(53, 241, 255, 0.86);
  }
}

@keyframes officerBar {
  from {
    transform: scaleX(0);
    transform-origin: left;
  }
  to {
    transform: scaleX(1);
    transform-origin: left;
  }
}

@keyframes officerRise {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes officerDraw {
  to {
    stroke-dashoffset: 0;
  }
}

@keyframes officerPing {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(42, 114, 255, 0.35);
  }
  50% {
    box-shadow: 0 0 0 8px rgba(42, 114, 255, 0);
  }
}

@keyframes officerPulse {
  0% {
    box-shadow: 0 0 0 0 rgba(33, 199, 168, 0.3);
  }
  100% {
    box-shadow: 0 0 0 13px rgba(33, 199, 168, 0);
  }
}

@media (max-width: 1560px) {
  .officer-report-top {
    grid-template-columns: 190px minmax(230px, 1fr) minmax(300px, 0.9fr);
  }

  .officer-report-actions {
    grid-column: 2 / -1;
    justify-content: flex-start;
  }

  .officer-hero {
    grid-template-columns: 138px minmax(200px, 0.8fr) minmax(340px, 1.35fr);
  }

  .officer-insight-card {
    grid-column: 2 / -1;
  }

  .officer-dataset-grid {
    grid-template-columns: repeat(3, minmax(180px, 1fr));
  }

  .officer-main-grid {
    grid-template-columns: 1fr 1fr;
  }

  .officer-health-panel {
    grid-column: 1 / -1;
  }

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

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

@media (max-width: 1120px) {
  body[data-route="ai-data-officer"] .content {
    padding: 14px;
  }

  .officer-report-top {
    position: relative;
    grid-template-columns: 1fr;
    margin: -14px -14px 8px;
  }

  .officer-report-actions {
    grid-column: auto;
    flex-wrap: wrap;
  }

  .officer-report-context {
    grid-template-columns: 1fr;
    padding: 10px 14px;
  }

  .officer-hero,
  .officer-main-grid,
  .officer-bottom-grid {
    grid-template-columns: 1fr;
  }

  .officer-insight-card {
    grid-column: auto;
  }

  .officer-dataset-grid,
  .officer-health-grid,
  .officer-asset-cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .officer-pipeline-node::after {
    display: none;
  }
}

@media (max-width: 720px) {
  body[data-route="ai-data-officer"] .content {
    padding: 10px;
    overflow-x: hidden;
  }

  .officer-report-top {
    margin: -10px -10px 8px;
    padding: 12px;
  }

  .officer-crrc-lockup {
    grid-template-columns: 44px minmax(0, 1fr);
  }

  .officer-crrc-lockup span {
    width: 42px;
    height: 42px;
    font-size: 27px;
  }

  .officer-crrc-lockup em {
    font-size: 22px;
  }

  .officer-date {
    font-size: 12px;
  }

  .officer-report-ticker {
    display: flex;
    flex-wrap: wrap;
  }

  .officer-page {
    overflow: hidden;
  }

  body[data-route="ai-data-officer"] .main {
    margin-left: 0;
    overflow-x: hidden;
  }

  body[data-route="ai-data-officer"] .sidebar {
    display: none;
  }

  .officer-title-row h2 {
    font-size: 34px;
  }

  .officer-hero {
    overflow: hidden;
    padding: 14px;
  }

  .officer-bot-card {
    min-height: 154px;
  }

  .officer-ask-input {
    grid-template-columns: 1fr;
  }

  .officer-ask-input button {
    width: 100%;
  }

  .officer-prompts button {
    flex: 1 1 100%;
  }

  .officer-card-head,
  .officer-section-head {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .officer-card-head a,
  .officer-section-head a {
    display: none;
  }

  .officer-hero-copy p,
  .officer-ask label,
  .officer-answer p {
    white-space: normal;
    word-break: break-all;
  }

  .officer-insight-list div {
    grid-template-columns: 1fr;
  }

  .officer-insight-list dd {
    text-align: left;
  }

  .officer-dataset-grid,
  .officer-health-grid,
  .officer-asset-cards,
  .officer-pipeline,
  .officer-knowledge,
  .officer-app-matrix {
    grid-template-columns: 1fr;
  }

  .officer-orbit {
    min-height: 280px;
  }

  .officer-donut {
    margin: 0 auto;
  }

  .officer-footer {
    display: grid;
  }
}

@media (prefers-reduced-motion: reduce) {
  .officer-bot,
  .officer-bot-halo,
  .officer-orbit::before,
  .officer-pipeline-node,
  .officer-orbit-node,
  .officer-dataset-card,
  .officer-health-card path,
  .officer-answer.pulse {
    animation: none !important;
  }

  .officer-dataset-card,
  .officer-panel,
  .officer-prompts button,
  .officer-ask-input button {
    transition: none !important;
  }
}
