/* ==========================================================================
   智审合同 · EVIDENCE EDITION
   A quiet, editorial contract-review workspace.
   Warm color photography, paper, thin rules, and evidence-first hierarchy.
   ========================================================================== */

:root {
  --paper: #f3ede2;
  --paper-deep: #e9e1d2;
  --surface: #fbf7ee;
  --surface-2: #f6f0e4;
  --ink: #202a23;
  --ink-soft: #334036;
  --muted: #676d61;
  --muted-light: #8b8f80;
  --line: #d9d1c2;
  --line-strong: #b8ac99;
  --line-dark: rgba(244, 239, 229, 0.18);
  --white: #fffdf7;
  --accent: #a34e34;
  --accent-deep: #803925;
  --accent-soft: #f1ded5;
  --accent-light: #e3a17f;
  --sage: #5f715d;
  --sage-deep: #3f5945;
  --sage-soft: #e5ebe1;
  --sage-light: #b9c8b2;
  --ochre: #9b6d34;
  --ochre-deep: #79501f;
  --ochre-soft: #f3e6d1;
  --ochre-light: #d6b47d;
  --slate: #526978;
  --slate-deep: #3f5664;
  --slate-soft: #e4eaed;
  --slate-light: #9fb6c5;
  --forest: #203127;
  --forest-deep: #152219;
  --serif: "Noto Serif SC", "Source Han Serif SC", "Songti SC", "STSong", "SimSun", serif;
  --sans: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", "Helvetica Neue", sans-serif;
  --mono: "SFMono-Regular", "Cascadia Mono", "JetBrains Mono", "Consolas", monospace;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --container: 1440px;
  --gutter: 56px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

#app {
  flex: 1;
}

body.nav-open {
  overflow: hidden;
}

:focus-visible {
  outline: 1px solid currentColor;
  outline-offset: 3px;
}

body::selection,
::selection {
  background: var(--accent);
  color: var(--white);
}

[hidden] {
  display: none !important;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea,
select {
  font: inherit;
  color: inherit;
}

button {
  -webkit-tap-highlight-color: transparent;
}

h1,
h2,
h3,
h4,
p,
blockquote,
ol,
ul {
  margin-top: 0;
}

em {
  font-style: normal;
}

.icon {
  width: 16px;
  height: 16px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.55;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.svg-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.mono {
  font-family: var(--mono);
  font-size: 0.94em;
  letter-spacing: 0;
}

.muted {
  color: var(--muted);
}

.truncate {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.grain {
  position: fixed;
  inset: 0;
  z-index: 90;
  pointer-events: none;
  opacity: 0.032;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.82' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.7'/%3E%3C/svg%3E");
}

/* --------------------------------------------------------------------------
   Global header
   -------------------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(244, 239, 229, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
}

.header-inner {
  width: 100%;
  max-width: 1560px;
  height: 76px;
  margin: 0 auto;
  padding: 0 42px;
  display: flex;
  align-items: center;
  gap: 40px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex: none;
}

.brand-mark {
  width: 40px;
  height: 40px;
  border: 1px solid var(--accent);
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--accent-deep);
}

.brand-mark .icon {
  width: 23px;
  height: 23px;
  stroke-width: 1.15;
}

.brand-copy {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.brand-copy strong {
  font-size: 19px;
  font-weight: 600;
  letter-spacing: 0.06em;
  line-height: 1.3;
}

.brand-copy small {
  font-family: var(--mono);
  font-size: 12.5px;
  letter-spacing: 0.12em;
  color: var(--muted);
  line-height: 1.3;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 34px;
  margin-left: 14px;
  margin-right: auto;
  align-self: stretch;
}

.main-nav a {
  position: relative;
  display: flex;
  align-items: center;
  height: 100%;
  color: #4b564c;
  font-size: 17px;
  font-weight: 500;
  letter-spacing: 0.04em;
  transition: color 0.3s var(--ease);
}

.main-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.45s var(--ease);
}

.main-nav a:hover,
.main-nav a[aria-current="page"] {
  color: var(--accent-deep);
}

.main-nav a:hover::after,
.main-nav a[aria-current="page"]::after {
  transform: scaleX(1);
}

.header-tools {
  display: flex;
  align-items: center;
  gap: 17px;
  flex: none;
}

.icon-button {
  width: 32px;
  height: 32px;
  display: inline-grid;
  place-items: center;
  border: 0;
  background: transparent;
  cursor: pointer;
  color: var(--ink);
  transition: background 0.3s var(--ease), border-color 0.3s var(--ease);
}

.icon-button:hover {
  background: var(--paper-deep);
}

.icon-button.bordered {
  border: 1px solid var(--line);
}

.icon-button.small {
  width: 28px;
  height: 28px;
  border: 1px solid var(--line);
}

.queue-indicator {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-family: var(--mono);
  font-size: 15px;
  letter-spacing: 0.04em;
  color: var(--muted);
  white-space: nowrap;
}

.queue-indicator i {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--sage);
}

.mode-chip {
  border: 1px solid var(--ochre);
  background: var(--ochre-soft);
  color: var(--ochre-deep);
  padding: 7px 11px 6px;
  font-family: var(--mono);
  font-size: 14.5px;
  letter-spacing: 0.06em;
  line-height: 1;
  white-space: nowrap;
}

.nav-toggle {
  display: none;
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  background: transparent;
  place-items: center;
  cursor: pointer;
}

.nav-toggle .icon {
  width: 18px;
  height: 18px;
}


/* --------------------------------------------------------------------------
   Buttons, links, badges
   -------------------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  min-height: 48px;
  padding: 0 25px;
  border: 1px solid transparent;
  border-radius: 0;
  background: transparent;
  font-family: var(--sans);
  font-size: 16px;
  letter-spacing: 0.08em;
  line-height: 1;
  cursor: pointer;
  transition: background 0.35s var(--ease), color 0.35s var(--ease), border-color 0.35s var(--ease), opacity 0.35s var(--ease);
}

.btn .icon {
  width: 15px;
  height: 15px;
  transition: transform 0.4s var(--ease);
}

.btn:hover .icon {
  transform: translateX(3px);
}

.btn-invert {
  background: var(--accent);
  color: var(--white);
  border-color: var(--accent);
}

.btn-invert:hover {
  background: var(--accent-deep);
  border-color: var(--accent-deep);
}

.btn-dark {
  background: var(--forest);
  color: var(--paper);
  border-color: var(--forest);
}

.btn-dark:hover {
  background: var(--sage-deep);
  border-color: var(--sage-deep);
}

.btn-outline {
  border-color: var(--line-strong);
  color: var(--ink);
}

.btn-outline:hover {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: var(--accent-deep);
}

.btn-ghost-light {
  color: var(--paper);
  border-color: rgba(244, 239, 229, 0.38);
}

.btn-ghost-light:hover {
  background: rgba(244, 239, 229, 0.1);
  border-color: rgba(244, 239, 229, 0.72);
}

.btn-small {
  min-height: 38px;
  padding: 0 15px;
  font-size: 14.5px;
}

.btn.full,
.full {
  width: 100%;
}

.btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.btn:disabled:hover .icon {
  transform: none;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 14.5px;
  letter-spacing: 0.08em;
  white-space: nowrap;
  border-bottom: 1px solid transparent;
  padding-bottom: 2px;
  transition: border-color 0.3s var(--ease);
}

.text-link .icon {
  width: 13px;
  height: 13px;
}

.text-link:hover {
  border-color: currentColor;
}

.text-button {
  padding: 0;
  border: 0;
  background: transparent;
  font-size: 14.5px;
  letter-spacing: 0.05em;
  color: var(--ink);
  border-bottom: 1px solid var(--line-strong);
  cursor: pointer;
  white-space: nowrap;
}

.text-button:hover {
  border-color: var(--accent);
  color: var(--accent-deep);
}

.muted-text {
  color: var(--muted);
  border-color: var(--line);
}

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 20px;
  padding: 4px 8px 3px;
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 13.5px;
  font-weight: 400;
  letter-spacing: 0.08em;
  line-height: 1.2;
  white-space: nowrap;
}

.badge.outline {
  border-color: var(--line-strong);
  color: var(--muted);
}

.badge.inverse {
  background: var(--forest);
  border-color: var(--forest);
  color: var(--paper);
}

.badge.risk {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--white);
}

.badge.missing {
  border-style: dashed;
  border-color: var(--ochre);
  background: var(--ochre-soft);
  color: var(--ochre-deep);
}

.badge.uncertain {
  background:
    repeating-linear-gradient(135deg, rgba(82, 105, 120, 0.16) 0, rgba(82, 105, 120, 0.16) 1px, transparent 1px, transparent 4px),
    var(--slate-soft);
  border-color: var(--slate);
  color: var(--slate-deep);
}

.badge.noissue,
.badge.answered {
  border-color: rgba(95, 113, 93, 0.55);
  background: var(--sage-soft);
  color: var(--sage-deep);
}

.badge.failed {
  background:
    repeating-linear-gradient(135deg, rgba(163, 78, 52, 0.12) 0, rgba(163, 78, 52, 0.12) 1px, transparent 1px, transparent 4px),
    var(--accent-soft);
  border-color: var(--accent);
  color: var(--accent-deep);
}

.badge.insufficient {
  border-style: dashed;
  border-color: var(--ochre);
  background: var(--ochre-soft);
  color: var(--ochre-deep);
}

.legend-mark {
  display: inline-block;
  width: 9px;
  height: 9px;
  border: 1px solid var(--muted-light);
  flex: none;
}

.legend-mark.risk {
  background: var(--accent);
  border-color: var(--accent);
}

.legend-mark.noissue {
  background: var(--sage);
  border-color: var(--sage);
}

.legend-mark.missing {
  border-style: dashed;
  border-color: var(--ochre);
}

.legend-mark.uncertain {
  background: repeating-linear-gradient(135deg, var(--slate) 0, var(--slate) 1px, transparent 1px, transparent 3px);
  border-color: var(--slate);
}

.check-mark {
  color: var(--sage-deep);
  display: inline-flex;
}

.check-mark .icon {
  width: 13px;
  height: 13px;
}

.lock-mark {
  color: var(--muted);
  display: inline-flex;
}

.lock-mark .icon {
  width: 13px;
  height: 13px;
}

/* --------------------------------------------------------------------------
   Typography helpers
   -------------------------------------------------------------------------- */

.kicker {
  display: flex;
  align-items: center;
  gap: 13px;
  margin: 0;
  font-family: var(--mono);
  font-size: 14.5px;
  font-weight: 400;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent-deep);
}

.kicker::before {
  content: "";
  width: 26px;
  height: 1px;
  background: currentColor;
  flex: none;
}

.kicker.light {
  color: var(--accent-light);
}

.eyebrow {
  margin: 0;
  font-family: var(--mono);
  font-size: 14.5px;
  letter-spacing: 0.26em;
  text-transform: uppercase;
}

.eyebrow.light {
  color: var(--accent-light);
}

.serif-heading {
  font-family: var(--serif);
  font-size: clamp(34px, 3.2vw, 48px);
  font-weight: 500;
  line-height: 1.22;
  letter-spacing: 0.02em;
  margin: 17px 0 0;
}

/* --------------------------------------------------------------------------
   Home / hero
   -------------------------------------------------------------------------- */

.view:not([hidden]) {
  animation: viewIn 0.55s var(--ease);
}

@keyframes viewIn {
  from {
    opacity: 0;
    transform: translateY(7px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.hero {
  position: relative;
  display: grid;
  align-items: center;
  min-height: clamp(380px, 49vw, 550px);
  overflow: hidden;
  background: #1a2a20;
  color: var(--paper);
}

.hero-media {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 42%;
  filter: saturate(0.82) contrast(1.04) brightness(0.8);
  transform: scale(1.01);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(70% 90% at 84% 16%, rgba(163, 78, 52, 0.24) 0%, rgba(163, 78, 52, 0) 62%),
    linear-gradient(90deg, rgba(19, 32, 24, 0.86) 0%, rgba(19, 32, 24, 0.44) 52%, rgba(19, 32, 24, 0.12) 100%),
    linear-gradient(0deg, rgba(14, 24, 18, 0.82) 0%, rgba(14, 24, 18, 0) 55%);
}

.hero-copy {
  position: relative;
  width: min(100%, var(--container));
  margin-inline: auto;
  padding: 64px var(--gutter);
  z-index: 2;
}

.hero h1 {
  margin: 0 0 16px;
  font-family: var(--serif);
  font-size: clamp(33px, 5.2vw, 72px);
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: 0.015em;
  color: var(--paper);
}

.hero h1 span {
  color: var(--accent-light);
}

.hero-lede {
  max-width: 560px;
  margin: 0;
  font-size: 17px;
  line-height: 1.95;
  letter-spacing: 0.025em;
  color: rgba(244, 239, 229, 0.82);
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 32px;
}

.hero-specimen {
  position: absolute;
  right: max(var(--gutter), calc((100vw - var(--container)) / 2 + var(--gutter)));
  bottom: 108px;
  z-index: 2;
  width: 292px;
  padding: 23px 22px 17px;
  background: rgba(251, 247, 238, 0.94);
  color: var(--ink);
  border: 1px solid rgba(251, 247, 238, 0.72);
  box-shadow: inset 0 2px 0 var(--accent);
  backdrop-filter: blur(8px);
}

.specimen-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.14em;
  color: var(--muted);
}

.specimen-title {
  margin: 0 0 12px;
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 500;
  line-height: 1.45;
  letter-spacing: 0.02em;
}

.specimen-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.specimen-list li {
  display: grid;
  grid-template-columns: 23px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  padding: 9px 0;
  border-top: 1px solid rgba(32, 42, 35, 0.13);
  font-size: 15.5px;
  letter-spacing: 0.04em;
}

.specimen-list .icon {
  color: var(--accent-deep);
}

.specimen-num {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--muted);
}

.specimen-foot {
  margin: 11px 0 0;
  padding-top: 10px;
  border-top: 1px solid rgba(32, 42, 35, 0.13);
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.15em;
  color: var(--muted);
}

.hero-foot {
  position: absolute;
  left: max(var(--gutter), calc((100vw - var(--container)) / 2 + var(--gutter)));
  right: max(var(--gutter), calc((100vw - var(--container)) / 2 + var(--gutter)));
  bottom: 22px;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding-top: 14px;
  border-top: 1px solid rgba(244, 239, 229, 0.26);
  color: rgba(244, 239, 229, 0.66);
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

/* --------------------------------------------------------------------------
   Home / editorial
   -------------------------------------------------------------------------- */

.editorial {
  padding-block: 46px 62px;
}

.editorial > h2 {
  margin: 0;
  padding-bottom: 13px;
  border-bottom: 1px solid var(--line-strong);
  font-family: var(--serif);
  font-size: clamp(26px, 3vw, 36px);
  font-weight: 500;
  line-height: 1.3;
}

.section-head {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) 380px;
  align-items: end;
  gap: 80px;
  padding-bottom: 34px;
  border-bottom: 1px solid var(--line);
}

.section-head h2 {
  margin: 20px 0 0;
  font-family: var(--serif);
  font-size: clamp(38px, 4vw, 60px);
  font-weight: 500;
  line-height: 1.18;
  letter-spacing: 0.02em;
}

.section-copy {
  max-width: 380px;
  margin: 0 0 4px;
  color: var(--muted);
  font-size: 16.5px;
  line-height: 1.95;
  letter-spacing: 0.015em;
}

.workflow-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 30px;
  margin-top: 24px;
}

.workflow-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.card-media {
  position: relative;
  aspect-ratio: 8 / 5;
  overflow: hidden;
  background: #25372b;
}

.card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.9) contrast(1.03) brightness(0.9);
  transition: transform 1.15s var(--ease), filter 1.15s var(--ease);
}

.card-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(14, 24, 18, 0.68) 0%, rgba(14, 24, 18, 0) 50%);
}

.workflow-card:hover .card-media img {
  transform: scale(1.035);
  filter: saturate(1) contrast(1.05) brightness(1);
}

.card-index {
  position: absolute;
  top: 17px;
  left: 17px;
  z-index: 2;
  padding: 5px 8px;
  border: 1px solid rgba(244, 239, 229, 0.45);
  background: rgba(14, 24, 18, 0.5);
  color: var(--paper);
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.08em;
  backdrop-filter: blur(4px);
}

.workflow-card:nth-child(1) .card-index {
  border-color: rgba(227, 161, 127, 0.72);
  color: #f2c5ae;
}

.workflow-card:nth-child(2) .card-index {
  border-color: rgba(159, 182, 197, 0.72);
  color: #c4d4dd;
}

.workflow-card:nth-child(3) .card-index {
  border-color: rgba(214, 180, 125, 0.72);
  color: #e1c89b;
}

.card-label {
  position: absolute;
  left: 19px;
  bottom: 17px;
  z-index: 2;
  color: rgba(244, 239, 229, 0.82);
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.22em;
}

.card-body {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  padding: 20px 0 15px;
  border-bottom: 1px solid var(--line);
}

.card-body h3 {
  margin: 0 0 6px;
  font-family: var(--serif);
  font-size: 25px;
  font-weight: 500;
  letter-spacing: 0.03em;
  line-height: 1.3;
}

.card-body p {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  letter-spacing: 0.06em;
}

.round-arrow {
  width: 37px;
  height: 37px;
  flex: none;
  display: grid;
  place-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  transition: background 0.4s var(--ease), color 0.4s var(--ease), border-color 0.4s var(--ease);
}

.round-arrow .icon {
  width: 14px;
  height: 14px;
}

.workflow-card:hover .round-arrow {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--white);
}

.workflow-card:hover .card-body h3 {
  color: var(--accent-deep);
}

.card-foot {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 11px 0 0;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 13.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

/* --------------------------------------------------------------------------
   Home / manifesto
   -------------------------------------------------------------------------- */

.manifesto {
  position: relative;
  overflow: hidden;
  padding: 106px 0 110px;
  background:
    radial-gradient(58% 80% at 88% 10%, rgba(163, 78, 52, 0.22) 0%, rgba(163, 78, 52, 0) 68%),
    linear-gradient(135deg, #16231a 0%, #1d3024 100%);
  color: var(--paper);
}

.manifesto::before {
  content: "";
  position: absolute;
  top: -20%;
  right: -10%;
  width: 60vw;
  height: 60vw;
  border: 1px solid rgba(244, 239, 229, 0.08);
  border-radius: 50%;
  pointer-events: none;
}

.manifesto-grid {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.14fr) minmax(0, 0.86fr);
  gap: 92px;
  align-items: start;
}

.manifesto blockquote {
  margin: 28px 0 0;
  font-family: var(--serif);
  font-size: clamp(38px, 4.6vw, 68px);
  font-weight: 500;
  line-height: 1.34;
  letter-spacing: 0.025em;
  color: rgba(244, 239, 229, 0.94);
}

.manifesto blockquote em {
  color: var(--accent-light);
  font-style: normal;
}

.principles {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 42px;
  padding-top: 8px;
}

.principle {
  display: grid;
  grid-template-columns: 26px 1fr;
  gap: 13px;
  padding: 24px 0 25px;
  border-top: 1px solid rgba(244, 239, 229, 0.2);
}

.principle > span {
  padding-top: 2px;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--accent-light);
}

.principle h3 {
  margin: 0 0 9px;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.12em;
}

.principle p {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.86;
  color: rgba(244, 239, 229, 0.68);
}

/* --------------------------------------------------------------------------
   Home / recent + closing
   -------------------------------------------------------------------------- */

.recent {
  padding-top: 96px;
  padding-bottom: 20px;
}

.section-head.compact {
  grid-template-columns: 1fr auto;
  gap: 30px;
  padding-bottom: 28px;
  border-bottom: 0;
}

.section-head.compact h2 {
  font-size: clamp(32px, 3.2vw, 46px);
}

.recent-list {
  border-top: 1px solid var(--line-strong);
}

.recent-row {
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr) 142px 80px 28px;
  align-items: center;
  gap: 20px;
  padding: 23px 12px;
  border-bottom: 1px solid var(--line);
  transition: background 0.35s var(--ease), padding 0.35s var(--ease);
}

.recent-row:hover {
  background: rgba(255, 253, 247, 0.4);
  padding-left: 18px;
}

.recent-id {
  font-size: 14px;
  color: var(--muted);
}

.recent-main {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 0;
}

.recent-main strong {
  font-family: var(--serif);
  font-size: 19px;
  font-weight: 500;
  letter-spacing: 0.02em;
  line-height: 1.4;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.recent-main small {
  font-size: 15px;
  color: var(--muted);
  letter-spacing: 0.03em;
}

.recent-time {
  font-family: var(--mono);
  font-size: 14px;
  color: var(--muted);
}

.recent-arrow {
  display: grid;
  place-items: center;
  color: var(--muted);
  transition: transform 0.35s var(--ease), color 0.35s var(--ease);
}

.recent-arrow .icon {
  width: 14px;
  height: 14px;
}

.recent-row:hover .recent-arrow {
  transform: translateX(3px);
  color: var(--ink);
}

.closing {
  padding-top: 100px;
  padding-bottom: 122px;
}

.closing-line {
  height: 1px;
  background: var(--line-strong);
}

.closing-grid {
  display: grid;
  grid-template-columns: 200px minmax(0, 1fr) auto;
  gap: 56px;
  align-items: center;
  padding-top: 34px;
}

.closing-copy {
  max-width: 660px;
  margin: 0;
  font-family: var(--serif);
  font-size: 19px;
  line-height: 1.95;
  letter-spacing: 0.02em;
}

/* --------------------------------------------------------------------------
   Subpage shell
   -------------------------------------------------------------------------- */

.page {
  max-width: 1280px;
  padding-top: 34px;
  padding-bottom: 64px;
}

.page-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 400px;
  align-items: center;
  gap: 74px;
  padding-bottom: 46px;
  border-bottom: 1px solid var(--line);
}

.page-head h1 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(43px, 4.5vw, 68px);
  font-weight: 500;
  line-height: 1.14;
  letter-spacing: 0.02em;
}

.lede {
  max-width: 600px;
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.95;
  letter-spacing: 0.02em;
}

.page-visual {
  min-width: 0;
}

.page-visual img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  filter: saturate(0.92) contrast(1.02) brightness(0.95);
}

.page-visual p {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  margin: 9px 0 0;
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--muted);
}

.compact-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 20px 24px;
  border: 1px solid var(--line);
  border-inline-start: 3px solid var(--accent);
  background: linear-gradient(105deg, var(--surface), var(--surface-2));
}

.compact-head h1 {
  font-size: clamp(28px, 3.5vw, 43px);
}

.import-heading .page-visual {
  width: min(32%, 250px);
}

.import-heading .page-visual img {
  display: block;
  aspect-ratio: 3 / 1;
  object-position: center 50%;
}

.page-head-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.page-head-actions .btn {
  margin-top: 2px;
}

/* --------------------------------------------------------------------------
   P01 / import
   -------------------------------------------------------------------------- */

.step-rail {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  margin: 22px 0 0;
  padding: 0;
}

.step-rail li {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 17px 18px 17px 0;
  border-top: 1px solid var(--line);
  color: var(--muted);
}

.step-rail li.is-active {
  border-top-color: var(--accent);
  color: var(--ink);
}

.step-rail li.is-complete {
  color: var(--sage-deep);
}

.step-num {
  width: 31px;
  height: 31px;
  flex: none;
  display: grid;
  place-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  font-family: var(--mono);
  font-size: 13px;
}

.step-rail li.is-active .step-num {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--white);
}

.step-rail li.is-complete .step-num {
  background: var(--sage-soft);
  border-color: var(--sage);
}

.step-rail strong {
  display: block;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.06em;
  line-height: 1.5;
}

.step-rail small {
  display: block;
  margin-top: 2px;
  font-size: 13.5px;
  color: var(--muted);
  letter-spacing: 0.03em;
}

.workspace-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 336px;
  align-items: start;
  gap: 28px;
  margin-top: 28px;
}

.workspace-main {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.workspace-main > .panel {
  scroll-margin-top: 112px;
}

.workspace-side {
  min-width: 0;
}

.side-sticky {
  position: sticky;
  top: 116px;
  display: flex;
  flex-direction: column;
  gap: 17px;
}

.panel {
  position: relative;
  min-width: 0;
  padding: 26px;
  border: 1px solid var(--line);
  background: rgba(251, 247, 238, 0.62);
}

.panel.dark {
  background:
    radial-gradient(120% 90% at 100% 0%, rgba(163, 78, 52, 0.18) 0%, rgba(163, 78, 52, 0) 60%),
    #1b2a20;
  border-color: #1b2a20;
  color: var(--paper);
}

.panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 21px;
}

.panel-kicker {
  margin: 0;
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.17em;
  text-transform: uppercase;
  color: var(--accent-deep);
}

.panel-kicker.light {
  color: var(--accent-light);
}

.panel-head h2,
.panel > h2 {
  margin: 6px 0 0;
  font-family: var(--serif);
  font-size: 25px;
  font-weight: 500;
  line-height: 1.35;
  letter-spacing: 0.025em;
}

.panel.dark .panel-kicker,
.panel.dark .panel-head h2 {
  color: var(--paper);
}

.panel.dark .panel-kicker {
  color: var(--accent-light);
}

.panel.dark .badge.inverse {
  background: var(--paper);
  border-color: var(--paper);
  color: var(--ink);
}

.panel-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 13px;
  font-family: var(--mono);
  font-size: 13.5px;
  color: var(--muted);
}

.warn-text {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.segmented {
  display: inline-flex;
  border: 1px solid var(--line);
  margin-bottom: 19px;
}

.segmented-item {
  min-height: 31px;
  padding: 0 15px;
  border: 0;
  border-right: 1px solid var(--line);
  background: transparent;
  font-size: 14.5px;
  letter-spacing: 0.05em;
  color: var(--muted);
  cursor: pointer;
  transition: background 0.3s var(--ease), color 0.3s var(--ease);
}

.segmented-item:last-child {
  border-right: 0;
}

.segmented-item.is-active {
  background: var(--accent);
  color: var(--white);
}

.import-top {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 17px;
}

.dropzone {
  min-height: 180px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  border: 1px dashed var(--line-strong);
  background: rgba(244, 239, 229, 0.5);
  transition: border-color 0.3s var(--ease), background 0.3s var(--ease);
}

.dropzone.is-dragging {
  border-color: var(--accent);
  background: var(--accent-soft);
}

.drop-icon {
  width: 27px;
  height: 27px;
  stroke-width: 1.1;
  margin-bottom: 12px;
}

.dropzone strong {
  font-size: 15.5px;
  font-weight: 500;
  letter-spacing: 0.04em;
}

.dropzone p {
  max-width: 255px;
  margin: 7px 0 0;
  font-size: 14px;
  line-height: 1.75;
  color: var(--muted);
}

.dropzone .btn {
  margin-top: 14px;
}

.file-card {
  min-height: 232px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  background: var(--forest);
  color: var(--paper);
}

.file-card-top {
  display: flex;
  align-items: flex-start;
  gap: 11px;
}

.file-icon {
  width: 35px;
  height: 35px;
  flex: none;
  display: grid;
  place-items: center;
  border: 1px solid rgba(244, 239, 229, 0.28);
}

.file-icon .icon {
  width: 17px;
  height: 17px;
  stroke-width: 1.2;
}

.file-card-top > div {
  min-width: 0;
  flex: 1;
}

.file-card-top strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 15.5px;
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: 0.02em;
}

.file-card-top small {
  display: block;
  margin-top: 3px;
  font-family: var(--mono);
  font-size: 13px;
  color: rgba(244, 239, 229, 0.44);
}

.file-card .badge.inverse {
  background: var(--paper);
  border-color: var(--paper);
  color: var(--ink);
  font-size: 13px;
  padding: 3px 6px;
}

.file-facts {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-top: auto;
  padding: 15px 0;
  border-top: 1px solid rgba(244, 239, 229, 0.15);
  border-bottom: 1px solid rgba(244, 239, 229, 0.15);
}

.file-facts span {
  font-family: var(--mono);
  font-size: 12.5px;
  letter-spacing: 0.04em;
  color: rgba(244, 239, 229, 0.66);
}

.file-facts strong {
  display: block;
  margin-bottom: 3px;
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 500;
  color: var(--paper);
}

.file-note {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  margin: 12px 0 0;
  font-size: 13px;
  line-height: 1.65;
  color: rgba(244, 239, 229, 0.68);
}

.file-note .icon {
  width: 12px;
  height: 12px;
  margin-top: 1px;
}

.check-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-top: 17px;
  padding-top: 15px;
  border-top: 1px solid var(--line);
}

.check-strip > div {
  display: grid;
  grid-template-columns: 14px 1fr;
  column-gap: 6px;
  align-items: center;
  font-size: 13.5px;
  color: var(--muted);
}

.check-strip .icon {
  width: 12px;
  height: 12px;
  grid-row: span 2;
  align-self: start;
  margin-top: 2px;
}

.check-strip small {
  grid-column: 2;
  display: block;
  margin-top: 2px;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--muted-light);
}

.field-label {
  display: block;
  margin-bottom: 8px;
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.textarea {
  width: 100%;
  padding: 15px 16px;
  border: 1px solid var(--line);
  border-radius: 0;
  background: var(--white);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.9;
  resize: vertical;
  outline: none;
  transition: border-color 0.3s var(--ease);
}

.textarea:focus {
  border-color: var(--accent);
}

.textarea.small {
  font-size: 15px;
  min-height: 84px;
}

.textarea-foot {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 8px;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--muted);
}

.warning-note {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 17px;
  padding: 11px 13px;
  border: 1px solid var(--ochre-light);
  background:
    repeating-linear-gradient(135deg, rgba(155, 109, 52, 0.06) 0, rgba(155, 109, 52, 0.06) 1px, transparent 1px, transparent 8px),
    var(--ochre-soft);
}

.warning-note > .icon {
  width: 15px;
  height: 15px;
  margin-top: 1px;
  stroke-width: 1.3;
  color: var(--ochre-deep);
}

.warning-note strong {
  color: var(--ochre-deep);
}

.warning-note > div {
  flex: 1;
  min-width: 0;
}

.warning-note strong {
  display: block;
  font-size: 14.5px;
  font-weight: 500;
  letter-spacing: 0.03em;
}

.warning-note span {
  display: block;
  margin-top: 3px;
  font-size: 13.5px;
  line-height: 1.7;
  color: #6b4c22;
}

.preview-layout {
  display: grid;
  grid-template-columns: 292px minmax(0, 1fr);
  min-height: 442px;
  border: 1px solid var(--line);
  background: #f8f3e9;
}

.block-list {
  max-height: 500px;
  overflow-y: auto;
  border-right: 1px solid var(--line);
  scrollbar-width: thin;
}

.block-item {
  width: 100%;
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr);
  gap: 7px;
  padding: 13px 11px;
  border: 0;
  border-bottom: 1px solid rgba(217, 209, 194, 0.7);
  border-left: 2px solid transparent;
  background: transparent;
  text-align: left;
  color: var(--ink);
  cursor: pointer;
  transition: background 0.3s var(--ease), color 0.3s var(--ease);
}

.block-item:hover {
  background: rgba(255, 253, 247, 0.62);
}

.block-item.is-selected {
  background: var(--forest);
  color: var(--paper);
  border-left-color: var(--accent-light);
}

.block-id {
  padding-top: 1px;
  font-family: var(--mono);
  font-size: 12.5px;
  color: var(--muted);
}

.block-item > span:last-child {
  min-width: 0;
}

.block-item strong {
  display: block;
  font-size: 14.5px;
  font-weight: 500;
  letter-spacing: 0.02em;
  line-height: 1.55;
}

.block-item small {
  display: block;
  margin-top: 3px;
  overflow: hidden;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.block-item em {
  display: block;
  margin-top: 4px;
  font-family: var(--mono);
  font-size: 12.5px;
  color: var(--muted-light);
}

.block-item.is-selected .block-id,
.block-item.is-selected small,
.block-item.is-selected em {
  color: rgba(244, 239, 229, 0.66);
}

.doc-sheet {
  max-height: 500px;
  overflow-y: auto;
  margin: 16px;
  padding: 31px 34px 22px;
  background: #fffdf7;
  box-shadow: 0 1px 0 rgba(32, 42, 35, 0.08), 0 18px 40px rgba(32, 42, 35, 0.045);
  color: #2b372e;
  font-family: var(--serif);
  font-size: 15.5px;
  line-height: 2.08;
  scrollbar-width: thin;
}

.doc-sheet-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 10px;
  margin-bottom: 17px;
  border-bottom: 1px solid #dedbd3;
  font-family: var(--sans);
  font-size: 13px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #8b8a7a;
}

.doc-stamp {
  rotate: -5deg;
  padding: 2px 5px;
  border: 1px solid #8d9188;
  font-size: 12.5px;
  letter-spacing: 0.12em;
  color: #8d9188;
}

.doc-block {
  position: relative;
  margin: 0 0 9px;
  padding: 8px 10px 8px 42px;
  border-left: 2px solid transparent;
  transition: background 0.3s var(--ease), border-color 0.3s var(--ease);
}

.doc-block.is-selected {
  background: var(--accent-soft);
  border-left-color: var(--accent);
}

.doc-block-id {
  position: absolute;
  left: 8px;
  top: 10px;
  font-family: var(--mono);
  font-size: 12.5px;
  color: #9a9787;
  letter-spacing: 0;
}

.doc-block strong {
  font-weight: 600;
}

.doc-footnote {
  margin: 24px 0 0;
  padding-top: 10px;
  border-top: 1px dashed #dedbd3;
  font-family: var(--sans);
  font-size: 13px;
  line-height: 1.7;
  color: #a0a39a;
}

.check-row {
  display: grid;
  grid-template-columns: 19px minmax(0, 1fr) auto;
  align-items: center;
  gap: 13px;
  padding: 14px 15px;
  border: 1px solid var(--line);
  background: rgba(255, 253, 247, 0.25);
  cursor: pointer;
  transition: border-color 0.3s var(--ease), background 0.3s var(--ease);
}

.check-row:hover {
  border-color: var(--line-strong);
}

.check-row.is-checked {
  border-color: var(--sage);
  background: var(--sage-soft);
}

.check-row input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.check-box {
  width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line-strong);
  background: var(--surface);
  transition: background 0.25s var(--ease), border-color 0.25s var(--ease), color 0.25s var(--ease);
}

.check-box .icon {
  width: 11px;
  height: 11px;
  opacity: 0;
  stroke-width: 2;
  transition: opacity 0.2s var(--ease);
}

.check-row input:checked + .check-box {
  background: var(--sage-deep);
  border-color: var(--sage-deep);
  color: var(--white);
}

.check-row input:checked + .check-box .icon {
  opacity: 1;
}

.check-copy {
  min-width: 0;
}

.check-copy strong {
  display: block;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.04em;
}

.check-copy small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.65;
}

.check-state {
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.06em;
  color: var(--muted);
  white-space: nowrap;
}

.check-row.is-checked .check-state {
  color: var(--ink);
}

.check-row.is-disabled {
  opacity: 0.42;
  cursor: not-allowed;
}

.party-block {
  margin-top: 23px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

.party-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 26px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.field > span {
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.field input {
  width: 100%;
  padding: 4px 0 9px;
  border: 0;
  border-bottom: 1px solid var(--line-strong);
  border-radius: 0;
  background: transparent;
  font-family: var(--serif);
  font-size: 18px;
  letter-spacing: 0.02em;
  outline: none;
  transition: border-color 0.3s var(--ease);
}

.field input:focus {
  border-color: var(--accent);
}

.field small {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.role-group {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding-top: 1px;
}

.role-group button {
  padding: 7px 10px;
  border: 1px solid var(--line);
  background: transparent;
  font-size: 14px;
  letter-spacing: 0.03em;
  cursor: pointer;
  transition: background 0.3s var(--ease), color 0.3s var(--ease), border-color 0.3s var(--ease);
}

.role-group button:hover {
  border-color: var(--line-strong);
}

.role-group button.is-active {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--white);
}

.validation-line {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 14px;
  font-size: 13.5px;
  color: var(--muted);
}

.validation-line .icon {
  width: 12px;
  height: 12px;
}

.validation-line .mono {
  margin-left: auto;
  font-size: 13px;
  color: var(--muted-light);
}

.compact-row {
  margin-top: 15px;
}

/* P01 side */

.snapshot-panel {
  padding: 24px;
}

.snapshot-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.snapshot-panel > h2 {
  margin: 21px 0 22px;
  font-family: var(--serif);
  font-size: 24px;
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: 0.03em;
}

.snapshot-list > div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 13px;
  padding: 9px 0;
  border-top: 1px solid rgba(244, 239, 229, 0.13);
}

.snapshot-list span {
  flex: none;
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.05em;
  color: rgba(244, 239, 229, 0.66);
}

.snapshot-list strong {
  font-size: 14.5px;
  font-weight: 400;
  line-height: 1.6;
  text-align: right;
  color: rgba(244, 239, 229, 0.88);
}

.snapshot-list em {
  display: inline-block;
  margin-left: 4px;
  padding: 1px 4px;
  border: 1px solid rgba(244, 239, 229, 0.25);
  font-family: var(--sans);
  font-size: 12.5px;
  color: rgba(244, 239, 229, 0.62);
}

.snapshot-note {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  margin: 11px 0 17px;
  padding: 9px 10px;
  border: 1px solid rgba(244, 239, 229, 0.14);
  color: rgba(244, 239, 229, 0.5);
}

.snapshot-note .icon {
  width: 12px;
  height: 12px;
  margin-top: 1px;
}

.snapshot-note p {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.72;
}

.model-select {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 7px;
  margin: 0 0 14px;
  padding: 9px 10px 10px;
  border: 1px solid rgba(244, 239, 229, 0.18);
}

.model-select > span {
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.05em;
  color: rgba(244, 239, 229, 0.66);
}

.model-select select {
  width: 100%;
  min-width: 0;
  padding: 6px 8px;
  border: 1px solid rgba(244, 239, 229, 0.22);
  border-radius: 0;
  background: rgba(244, 239, 229, 0.08);
  color: rgba(244, 239, 229, 0.92);
  font-size: 14.5px;
}

.model-select select option {
  background: #1b2a20;
  color: #f3ede2;
}

/* 问答页（浅色 scope 面板）内的模型选择：浅色变体 */
.scope-panel .model-select {
  margin: 14px 0 0;
  border-color: var(--line);
}

.scope-panel .model-select > span {
  color: var(--muted);
}

.scope-panel .model-select select {
  border-color: var(--line);
  background: #faf6ed;
  color: var(--ink);
}

.scope-panel .model-select select option {
  background: #fff;
  color: var(--ink);
}

.side-hint {
  margin: 9px 0 0;
  color: rgba(244, 239, 229, 0.62);
  font-size: 13px;
  text-align: center;
  letter-spacing: 0.03em;
}

.side-meta {
  padding: 18px 20px 14px;
}

.side-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}

.side-meta-row span {
  color: var(--muted);
}

.side-meta-row strong {
  font-weight: 500;
  font-size: 14.5px;
}

.side-meta-note {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.side-meta-note .icon {
  width: 12px;
  height: 12px;
  margin-top: 1px;
  flex: none;
}

/* --------------------------------------------------------------------------
   P02 / review
   -------------------------------------------------------------------------- */

.run-strip {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  margin-top: 26px;
  border: 1px solid var(--line);
  background: rgba(251, 247, 238, 0.56);
}

.run-strip > div {
  min-width: 0;
  padding: 12px 15px;
  border-right: 1px solid var(--line);
}

.run-strip > div:last-child {
  border-right: 0;
}

.run-strip span {
  display: block;
  margin-bottom: 4px;
  font-family: var(--mono);
  font-size: 12.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

.run-strip strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 14.5px;
  font-weight: 400;
  letter-spacing: 0.01em;
}

.run-strip em {
  margin-left: 4px;
  padding: 1px 4px;
  border: 1px solid var(--line);
  font-family: var(--sans);
  font-size: 12.5px;
  color: var(--muted);
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 20px;
  border: 1px solid var(--line);
  background: transparent;
}

.metric {
  padding: 22px 24px 20px;
  border-right: 1px solid var(--line);
}

.metric:last-child {
  border-right: 0;
}

.metric > strong {
  display: block;
  margin-bottom: 7px;
  font-family: var(--serif);
  font-size: 34px;
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: 0.02em;
}

.metric > span {
  display: block;
  font-size: 14.5px;
  letter-spacing: 0.05em;
}

.metric > small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
  letter-spacing: 0.02em;
}

.review-layout {
  display: grid;
  grid-template-columns: minmax(210px, 27%) minmax(0, 1fr);
  margin-top: 24px;
  border: 1px solid var(--line);
  background: rgba(251, 247, 238, 0.6);
}

.findings-panel {
  border: 0;
  border-right: 1px solid var(--line);
  padding: 24px 22px 18px;
  background: transparent;
}

.finding-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 11px;
  color: var(--muted);
  font-size: 13px;
}

.finding-legend span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.finding-legend .legend-mark {
  width: 7px;
  height: 7px;
}

.finding-list {
  border-top: 1px solid var(--line);
}

.finding-row {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 15px 8px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  text-align: left;
  color: var(--ink);
  cursor: pointer;
  transition: background 0.3s var(--ease), color 0.3s var(--ease);
}

.finding-row:hover {
  background: #f3ede2;
}

.finding-row.is-active {
  background: var(--forest);
  color: var(--paper);
  box-shadow: inset 3px 0 0 var(--accent-light);
}

.finding-seq {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--muted);
}

.finding-main {
  min-width: 0;
}

.finding-main strong {
  display: block;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.04em;
}

.finding-main small {
  display: block;
  margin-top: 3px;
  overflow: hidden;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.55;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.finding-row.is-active .finding-seq,
.finding-row.is-active .finding-main small {
  color: rgba(244, 239, 229, 0.64);
}

.finding-row.is-active .badge {
  background: var(--paper);
  border-color: var(--paper);
  color: var(--ink);
}

.findings-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 13px;
  color: var(--muted);
  font-size: 13px;
  letter-spacing: 0.04em;
}

.findings-foot span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.findings-foot .icon {
  width: 12px;
  height: 12px;
}

.detail-panel {
  padding: 32px 34px;
  border: 0;
  background: rgba(255, 253, 247, 0.18);
}

.detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.detail-head h2 {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin: 6px 0 0;
  font-family: var(--serif);
  font-size: 29px;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: 0.025em;
}

.detail-rule {
  padding-top: 6px;
  font-family: var(--mono);
  font-size: 12.5px;
  color: var(--muted-light);
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.detail-explanation {
  max-width: 760px;
  margin: 21px 0 22px;
  font-family: var(--serif);
  font-size: 18px;
  line-height: 1.95;
  letter-spacing: 0.02em;
}

.evidence-card {
  margin: 0 0 22px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-left: 3px solid var(--forest);
  background: #f1ece1;
}

.evidence-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.05em;
}

.evidence-card blockquote {
  margin: 11px 0 10px;
  font-family: var(--serif);
  font-size: 17.5px;
  line-height: 1.9;
  color: #2b372e;
}

.evidence-foot {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
}

.evidence-foot .dot-ok {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--sage);
}

.empty-evidence {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 0 0 22px;
  padding: 15px 16px;
  border: 1px dashed var(--ochre);
  background: rgba(243, 230, 209, 0.4);
}

.empty-evidence .icon {
  width: 16px;
  height: 16px;
  margin-top: 1px;
  color: var(--ochre-deep);
}

.empty-evidence strong {
  display: block;
  color: var(--ochre-deep);
  font-size: 14.5px;
  font-weight: 500;
  letter-spacing: 0.03em;
}

.empty-evidence p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.7;
}

.detail-section {
  margin-top: 20px;
}

.detail-section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.reference-empty {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin-top: 10px;
  padding: 12px 13px;
  border: 1px dashed var(--line-strong);
  color: var(--muted);
  font-size: 14px;
  line-height: 1.72;
}

.reference-empty .icon {
  width: 13px;
  height: 13px;
  margin-top: 1px;
  flex: none;
}

.reference-list {
  margin-top: 10px;
  border: 1px solid var(--line);
}

.reference-item {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  gap: 10px;
  padding: 11px 13px;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}

.reference-item:last-child {
  border-bottom: 0;
}

.reference-index {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--muted);
}

.reference-item strong {
  display: block;
  font-weight: 500;
  font-size: 14.5px;
}

.reference-item p {
  margin: 3px 0 0;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.65;
}

.revision-preview {
  margin-top: 10px;
  border: 1px solid var(--line);
  background: #fbf7ee;
}

.revision-preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 12px;
  border-bottom: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 12.5px;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.revision-preview p {
  margin: 0;
  padding: 12px 14px;
  font-family: var(--serif);
  font-size: 16px;
  line-height: 1.85;
}

.revision-preview-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 12px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: var(--muted);
}

.detail-footnote {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  margin-top: 22px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.detail-footnote .icon {
  width: 12px;
  height: 12px;
  margin-top: 1px;
}

.bottom-grid {
  display: grid;
  grid-template-columns: 1.08fr 0.94fr 0.82fr;
  gap: 22px;
  margin-top: 22px;
}

.validation-list > div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto 16px;
  align-items: center;
  gap: 11px;
  padding: 10px 0;
  border-top: 1px solid var(--line);
  font-size: 14.5px;
}

.validation-list > div:last-child {
  border-bottom: 1px solid var(--line);
}

.validation-list span {
  color: var(--muted);
}

.validation-list strong {
  font-weight: 400;
  font-size: 14px;
  white-space: nowrap;
}

.coverage-panel .panel-head {
  align-items: flex-end;
}

.big-number {
  font-family: var(--serif);
  font-size: 42px;
  font-weight: 500;
  line-height: 0.9;
  letter-spacing: 0.01em;
}

.big-number span {
  font-size: 16px;
  margin-left: 2px;
  color: var(--muted);
}

.progress {
  height: 4px;
  margin: 20px 0 13px;
  background: var(--paper-deep);
  overflow: hidden;
}

.progress span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--sage) 0%, var(--sage-deep) 100%);
}

.coverage-copy {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.8;
}

.coverage-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 14px;
  font-size: 13px;
  color: var(--muted);
}

.coverage-foot span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.coverage-foot .legend-mark {
  width: 7px;
  height: 7px;
}

.next-panel {
  display: flex;
  flex-direction: column;
}

.next-panel > h2 {
  margin: 8px 0 10px;
  font-family: var(--serif);
  font-size: 26px;
  font-weight: 500;
  line-height: 1.45;
  letter-spacing: 0.02em;
}

.next-panel > p:not(.panel-kicker) {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.8;
}

.next-panel .btn {
  margin-top: auto;
}

.next-panel .text-link {
  margin-top: 12px;
  align-self: flex-start;
  font-size: 13.5px;
}

/* --------------------------------------------------------------------------
   P03 / decision
   -------------------------------------------------------------------------- */

.decision-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 348px;
  align-items: start;
  gap: 28px;
  margin-top: 28px;
}

.candidate-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
}

.candidate {
  padding: 20px 22px 17px;
  border: 1px solid var(--line);
  background: rgba(251, 247, 238, 0.66);
  transition: border-color 0.35s var(--ease), opacity 0.35s var(--ease), box-shadow 0.35s var(--ease);
}

.candidate.is-accepted {
  border-color: var(--sage);
  background: rgba(229, 235, 225, 0.42);
  box-shadow: inset 3px 0 0 var(--sage-deep);
}

.candidate.is-rejected {
  opacity: 0.64;
  border-style: dashed;
  border-color: var(--slate);
}

.candidate-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.candidate-head > div {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 9px;
}

.candidate-head .mono {
  font-size: 13px;
  color: var(--muted);
}

.candidate.is-accepted .status-tag {
  background: var(--sage-deep);
  border-color: var(--sage-deep);
  color: var(--white);
}

.candidate.is-rejected .status-tag {
  border-style: dashed;
  border-color: var(--slate);
  color: var(--slate-deep);
  background: repeating-linear-gradient(135deg, rgba(82, 105, 120, 0.14) 0, rgba(82, 105, 120, 0.14) 1px, transparent 1px, transparent 4px),
    var(--slate-soft);
}

.candidate-anchor {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-top: 11px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.02em;
}

.candidate-anchor .icon {
  width: 12px;
  height: 12px;
}

.candidate-reason {
  margin: 10px 0 0;
  color: var(--muted);
}

.diff {
  border: 1px solid var(--line);
}

.diff-row {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
}

.diff-row + .diff-row {
  border-top: 1px solid var(--line);
}

.diff-row > span {
  padding: 11px 10px;
  border-right: 1px solid var(--line);
  background: #f1ebdf;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 12.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.diff-row p {
  margin: 0;
  padding: 10px 13px;
  font-size: 14.5px;
  line-height: 1.75;
  color: #373a35;
}

.diff-remove {
  background: rgba(241, 222, 213, 0.34);
}

.diff-remove > span {
  background: var(--accent-soft);
  color: var(--accent-deep);
}

.diff-remove p {
  color: #7f5c50;
  text-decoration: line-through;
  text-decoration-color: rgba(163, 78, 52, 0.55);
  text-decoration-thickness: 1px;
}

.diff-add {
  background: rgba(229, 235, 225, 0.46);
}

.diff-add > span {
  background: var(--sage-soft);
  color: var(--sage-deep);
}

.diff-add p {
  color: var(--sage-deep);
}

.diff-add em {
  color: var(--muted);
  font-size: 14px;
}

.diff-context p {
  color: var(--muted);
}

.candidate-foot {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 16px;
  margin-top: 13px;
}

.candidate-hint {
  color: var(--muted);
  font-size: 13px;
  letter-spacing: 0.02em;
}

.decision-buttons {
  display: flex;
  gap: 6px;
  flex: none;
}

.decision-buttons button {
  min-width: 61px;
  padding: 7px 12px;
  border: 1px solid var(--line);
  background: transparent;
  font-size: 14px;
  letter-spacing: 0.06em;
  cursor: pointer;
  transition: background 0.3s var(--ease), color 0.3s var(--ease), border-color 0.3s var(--ease);
}

.decision-buttons button:hover {
  border-color: var(--accent);
  color: var(--accent-deep);
}

.decision-buttons button:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.candidate.is-accepted [data-decision="accept"] {
  background: var(--sage-deep);
  border-color: var(--sage-deep);
  color: var(--white);
}

.candidate.is-rejected [data-decision="reject"] {
  background: var(--slate-deep);
  border-color: var(--slate-deep);
  color: var(--white);
}

.decision-side {
  padding: 22px;
}

.decision-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  padding: 15px 0 14px;
  margin-bottom: 10px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.decision-stats > div {
  text-align: center;
  border-right: 1px solid var(--line);
}

.decision-stats > div:last-child {
  border-right: 0;
}

.decision-stats strong {
  display: block;
  font-family: var(--serif);
  font-size: 31px;
  font-weight: 500;
  line-height: 1.15;
}

.decision-stats span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 13px;
  letter-spacing: 0.05em;
}

.validation-mini > div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto 13px;
  align-items: center;
  gap: 8px;
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}

.validation-mini span {
  color: var(--muted);
}

.validation-mini strong {
  font-weight: 400;
  font-size: 13px;
  white-space: nowrap;
}

.validation-mini .icon {
  width: 12px;
  height: 12px;
}

.decision-side .btn {
  margin-top: 17px;
}

.decision-side .side-hint {
  color: var(--muted);
}

.decision-side .text-button {
  display: block;
  margin: 12px auto 0;
  font-size: 13px;
}

.applied-panel {
  padding: 24px;
  border-color: var(--sage);
  background: var(--sage-soft);
}

.applied-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  margin-bottom: 12px;
  border-radius: 50%;
  background: var(--sage-deep);
  color: var(--white);
}

.applied-mark .icon {
  width: 16px;
  height: 16px;
  stroke-width: 1.8;
}

.applied-panel h2 {
  margin: 7px 0 15px;
  font-family: var(--serif);
  font-size: 25px;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.applied-meta > div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 0;
  border-top: 1px solid var(--line);
  font-size: 13.5px;
}

.applied-meta span {
  color: var(--muted);
}

.applied-meta strong {
  min-width: 0;
  font-weight: 400;
  font-size: 13.5px;
  text-align: right;
}

.applied-panel .btn {
  margin-top: 16px;
}

.export-result {
  margin-top: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  background: rgba(255, 253, 247, 0.42);
}

.export-result > div {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
}

.export-result .icon {
  width: 12px;
  height: 12px;
  color: var(--sage-deep);
}

.export-result p {
  margin: 6px 0 3px;
  font-size: 13px;
  color: var(--muted);
}

.export-result small {
  display: block;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

/* --------------------------------------------------------------------------
   P04 / ask
   -------------------------------------------------------------------------- */

.qa-layout {
  display: grid;
  grid-template-columns: 324px minmax(0, 1fr);
  align-items: start;
  gap: 28px;
  margin-top: 28px;
}

.scope-panel {
  position: sticky;
  top: 116px;
  padding: 22px;
}

.scope-list {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin-top: 15px;
}

.scope-card {
  display: grid;
  grid-template-columns: 17px minmax(0, 1fr) auto;
  align-items: center;
  gap: 9px;
  padding: 11px 10px;
  border: 1px solid var(--line);
  background: rgba(255, 253, 247, 0.22);
  cursor: pointer;
  transition: border-color 0.3s var(--ease), background 0.3s var(--ease);
}

.scope-card:hover {
  border-color: var(--line-strong);
}

.scope-card.is-selected {
  border-color: var(--sage);
  background: var(--sage-soft);
}

.scope-card input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.scope-check {
  width: 16px;
  height: 16px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line-strong);
  background: var(--surface);
  transition: background 0.25s var(--ease), color 0.25s var(--ease), border-color 0.25s var(--ease);
}

.scope-check .icon {
  width: 10px;
  height: 10px;
  opacity: 0;
  stroke-width: 2;
}

.scope-card input:checked + .scope-check {
  background: var(--sage-deep);
  border-color: var(--sage-deep);
  color: var(--white);
}

.scope-card input:checked + .scope-check .icon {
  opacity: 1;
}

.scope-card > span:nth-of-type(2) {
  min-width: 0;
}

.scope-card strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 14.5px;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.scope-card small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 13px;
}

.scope-card em {
  padding: 1px 4px;
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 12.5px;
  white-space: nowrap;
}

.scope-note.is-warning {
  color: var(--ochre-deep);
}

.scope-note.is-warning .icon {
  color: var(--ochre);
}

.scope-note {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  margin: 13px 0 0;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.scope-note .icon {
  width: 12px;
  height: 12px;
  margin-top: 1px;
  flex: none;
}

.scope-meta {
  margin-top: 13px;
  padding-top: 3px;
  border-top: 1px solid var(--line);
}

.scope-meta > div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  padding: 7px 0;
  border-bottom: 1px solid rgba(217, 209, 194, 0.65);
  font-size: 13px;
}

.scope-meta span {
  color: var(--muted);
}

.scope-meta strong {
  font-weight: 400;
  font-size: 13px;
  text-align: right;
}

.scope-meta em {
  margin-left: 3px;
  padding: 1px 3px;
  border: 1px solid var(--line);
  font-size: 12.5px;
  color: var(--muted);
}

.qa-main {
  min-width: 0;
  max-width: 810px;
  margin-top: 24px;
  display: flex;
  flex-direction: column;
  gap: 19px;
}

.question-panel {
  padding: 22px;
}

.question-box {
  padding: 15px 16px 13px;
  border: 1px solid var(--line);
  background: #fbf7ee;
}

.question-box textarea {
  width: 100%;
  min-height: 53px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  font-family: var(--serif);
  font-size: 19px;
  line-height: 1.7;
  letter-spacing: 0.02em;
  resize: vertical;
  outline: none;
}

.question-tools {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin-top: 9px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.suggestions {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.suggestions button {
  padding: 4px 8px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  font-size: 13px;
  cursor: pointer;
  transition: border-color 0.3s var(--ease), color 0.3s var(--ease);
}

.suggestions button:hover {
  border-color: var(--accent);
  color: var(--accent-deep);
}

.question-submit {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: none;
}

.question-submit .mono {
  font-size: 13px;
  color: var(--muted);
}

.answer-card {
  padding: 26px 28px 20px;
  border: 1px solid var(--line);
  border-top: 2px solid var(--accent);
  background: #fbf7ee;
}

.answer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.answer-head > div {
  display: flex;
  align-items: center;
  gap: 10px;
}

.answer-meta {
  color: var(--muted);
  font-size: 13px;
  letter-spacing: 0.03em;
}

.answer-head > .mono {
  font-size: 13px;
  color: var(--muted);
}

.answer-body {
  margin: 20px 0 18px;
}

.answer-text {
  margin: 0;
  font-family: var(--serif);
  font-size: 19px;
  line-height: 2;
  letter-spacing: 0.02em;
}

.answer-text strong {
  font-weight: 600;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
  text-decoration-color: var(--accent);
}

.answer-note {
  margin: 14px 0 0;
  padding-left: 13px;
  border-left: 1px solid var(--slate-light);
  color: var(--slate);
  font-size: 14px;
  line-height: 1.8;
}

.citation-list {
  border-top: 1px solid var(--line);
}

.citation-item {
  display: grid;
  grid-template-columns: 27px minmax(0, 1fr) 28px;
  gap: 9px;
  align-items: start;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
}

.citation-index {
  padding-top: 1px;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--muted);
}

.citation-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  font-family: var(--mono);
  font-size: 12.5px;
  letter-spacing: 0.04em;
  color: var(--muted);
}

.citation-item blockquote {
  margin: 6px 0 0;
  font-family: var(--serif);
  font-size: 16px;
  line-height: 1.85;
  color: #31342f;
}

.answer-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 16px;
  padding-top: 13px;
  color: var(--muted);
  font-size: 13px;
}

.answer-foot span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.answer-foot .icon {
  width: 11px;
  height: 11px;
}

.supplement-panel {
  padding: 22px;
}

.supplement-list {
  border-top: 1px solid var(--line);
}

.supplement-row {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}

.supplement-num {
  font-family: var(--mono);
  font-size: 12.5px;
  color: var(--muted);
}

.supplement-row strong {
  display: block;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.03em;
}

.supplement-row small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

.supplement-row.done {
  opacity: 0.82;
}

.supplement-note {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.supplement-note .icon {
  width: 12px;
  height: 12px;
  margin-top: 1px;
  flex: none;
}

.qa-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
  padding-top: 3px;
}

.qa-actions .btn {
  min-height: 38px;
  padding: 0 15px;
  font-size: 14px;
}

.qa-actions .text-link {
  margin-left: auto;
  font-size: 13.5px;
}

/* --------------------------------------------------------------------------
   P05 / knowledge
   -------------------------------------------------------------------------- */

.kb-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.76fr) auto;
  gap: 34px;
  align-items: center;
  margin-top: 26px;
  padding: 29px 32px;
  background:
    radial-gradient(100% 130% at 96% 0%, rgba(163, 78, 52, 0.24) 0%, rgba(163, 78, 52, 0) 62%),
    #1b2a20;
  color: var(--paper);
}

.kb-hero-main h2 {
  margin: 12px 0 8px;
  font-family: var(--serif);
  font-size: 34px;
  font-weight: 500;
  letter-spacing: 0.01em;
  line-height: 1.3;
}

.kb-hero-main > p:not(.kicker) {
  max-width: 550px;
  margin: 0;
  color: rgba(244, 239, 229, 0.7);
  font-size: 14px;
  line-height: 1.8;
}

.kb-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 15px;
}

.kb-tags span {
  padding: 3px 6px;
  border: 1px solid rgba(244, 239, 229, 0.26);
  font-family: var(--mono);
  font-size: 12.5px;
  letter-spacing: 0.02em;
  color: rgba(244, 239, 229, 0.68);
}

.kb-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-left: 1px solid rgba(244, 239, 229, 0.16);
}

.kb-stats > div {
  padding: 3px 16px;
  border-right: 1px solid rgba(244, 239, 229, 0.16);
}

.kb-stats > div:last-child {
  border-right: 0;
}

.kb-stats strong {
  display: block;
  font-family: var(--serif);
  font-size: 29px;
  font-weight: 500;
  line-height: 1.2;
}

.kb-stats span {
  display: block;
  margin-top: 4px;
  color: rgba(244, 239, 229, 0.68);
  font-size: 13px;
  line-height: 1.5;
}

.kb-side {
  min-width: 94px;
  text-align: right;
}

.kb-side .badge.inverse {
  background: var(--paper);
  border-color: var(--paper);
  color: var(--ink);
  font-size: 12.5px;
}

.kb-side p {
  margin: 13px 0 0;
  color: rgba(244, 239, 229, 0.64);
  font-size: 13px;
  line-height: 1.7;
}

.kb-side strong {
  color: rgba(244, 239, 229, 0.8);
  font-weight: 400;
  font-size: 13px;
}

.notice {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin-top: 17px;
  padding: 10px 13px;
  border: 1px solid var(--ochre-light);
  background:
    repeating-linear-gradient(135deg, rgba(155, 109, 52, 0.06) 0, rgba(155, 109, 52, 0.06) 1px, transparent 1px, transparent 8px),
    var(--ochre-soft);
  color: var(--ochre-deep);
  font-size: 13.5px;
  line-height: 1.7;
}

.notice .icon {
  width: 14px;
  height: 14px;
  margin-top: 1px;
  flex: none;
}

.notice p {
  margin: 0;
}

.notice .icon {
  color: var(--ochre);
}

.notice strong {
  color: var(--ochre-deep);
  font-weight: 500;
}

.knowledge-tabs {
  display: flex;
  gap: 25px;
  margin-top: 23px;
  border-bottom: 1px solid var(--line);
  overflow-x: auto;
  scrollbar-width: none;
}

.knowledge-tabs::-webkit-scrollbar {
  display: none;
}

.knowledge-tab {
  position: relative;
  flex: none;
  padding: 10px 0 11px;
  margin-bottom: -1px;
  border: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: var(--muted);
  font-size: 14px;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: color 0.3s var(--ease), border-color 0.3s var(--ease);
}

.knowledge-tab span {
  font-family: var(--mono);
  font-size: 12.5px;
  color: var(--muted-light);
  margin-left: 2px;
}

.knowledge-tab:hover,
.knowledge-tab.is-active {
  color: var(--accent-deep);
}

.knowledge-tab.is-active {
  border-bottom-color: var(--accent);
}

.knowledge-layout {
  display: grid;
  grid-template-columns: 382px minmax(0, 1fr);
  align-items: start;
  gap: 22px;
  margin-top: 22px;
}

.knowledge-list-panel {
  padding: 20px;
}

.knowledge-list {
  border-top: 1px solid var(--line);
}

.knowledge-item {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 7px 12px;
  padding: 12px 8px;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-left: 2px solid transparent;
  background: transparent;
  text-align: left;
  cursor: pointer;
  color: var(--ink);
  transition: background 0.3s var(--ease), color 0.3s var(--ease);
}

.knowledge-item:hover {
  background: #f3ede2;
}

.knowledge-item.is-active {
  background: var(--forest);
  color: var(--paper);
  border-left-color: var(--accent-light);
}

.knowledge-item h3 {
  margin: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--serif);
  font-size: 16px;
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: 0.015em;
}

.knowledge-item .ki-meta {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
}

.knowledge-item .ki-meta span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.knowledge-item .badge {
  font-size: 12.5px;
  min-height: 18px;
  padding: 3px 5px;
}

.knowledge-item.is-active .badge {
  background: var(--paper);
  border-color: var(--paper);
  color: var(--ink);
}

.knowledge-item.is-active .ki-meta {
  color: rgba(244, 239, 229, 0.64);
}

.knowledge-empty {
  padding: 25px 10px;
  color: var(--muted);
  font-size: 14px;
  text-align: center;
}

/* 知识页动态列表行（快照） */
.knowledge-row {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 7px 12px;
  padding: 12px 8px;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-left: 2px solid transparent;
  background: transparent;
  text-align: left;
  cursor: pointer;
  color: var(--ink);
  transition: background 0.3s var(--ease), color 0.3s var(--ease);
}

.knowledge-row:hover {
  background: #f3ede2;
}

.knowledge-row.is-selected {
  background: var(--forest);
  color: var(--paper);
  border-left-color: var(--accent-light);
}

.knowledge-row-main {
  min-width: 0;
}

.knowledge-row-main strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--serif);
  font-size: 16px;
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: 0.015em;
}

.knowledge-row-main small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  margin-top: 2px;
  color: var(--muted);
  font-size: 13px;
}

.knowledge-row.is-selected .knowledge-row-main small {
  color: rgba(244, 239, 229, 0.64);
}

.knowledge-row .badge {
  font-size: 12.5px;
  min-height: 18px;
  padding: 3px 5px;
}

.knowledge-row.is-selected .badge {
  background: var(--paper);
  border-color: var(--paper);
  color: var(--ink);
}

/* 知识页操作表单 */
.kb-head-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.kb-form-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  padding-top: 14px;
}

.kb-form-grid .field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.kb-form-grid .field > span {
  color: var(--muted);
  font-size: 13px;
}

.kb-form-grid input,
.kb-form-grid select,
.kb-form-grid textarea {
  width: 100%;
  min-width: 0;
  padding: 9px 11px;
  border: 1px solid var(--line);
  border-radius: 0;
  background: #faf6ed;
  color: var(--ink);
  font-size: 15px;
}

.kb-form-grid textarea {
  resize: vertical;
}

.kb-form-grid .kb-form-wide {
  grid-column: 1 / -1;
}

.kb-form-actions {
  display: flex;
  align-items: flex-end;
}

.kb-form-hint {
  grid-column: 1 / -1;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

/* 快照详情：chunk 与动作 */
.kb-chunk {
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-left: 3px solid var(--accent-light);
  background: #faf6ed;
}

.kb-chunk + .kb-chunk {
  margin-top: 8px;
}

.kb-chunk .mono {
  color: var(--muted);
  font-size: 12.5px;
  letter-spacing: 0.05em;
}

.kb-chunk p {
  margin: 6px 0 0;
  font-size: 14.5px;
  line-height: 1.7;
}

.kb-snap-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.kb-action-hint {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

/* 版本列表与索引切换 */
.kb-version-list {
  display: flex;
  flex-direction: column;
  margin-top: 16px;
  border-top: 1px solid var(--line);
}

.kb-version-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 2px;
  border-bottom: 1px solid var(--line);
}

.kb-version-main {
  flex: 1;
  min-width: 0;
}

.kb-version-main strong {
  display: block;
  font-size: 15px;
  font-weight: 500;
}

.kb-version-main small {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 13px;
}

.kb-version-actions {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* 检索验证 */
.kb-retrieve {
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.kb-retrieve-row {
  display: flex;
  align-items: stretch;
  gap: 10px;
}

.kb-retrieve-row input {
  flex: 1;
  min-width: 0;
  padding: 9px 11px;
  border: 1px solid var(--line);
  border-radius: 0;
  background: #faf6ed;
  color: var(--ink);
  font-size: 15px;
}

.kb-retrieve-result {
  margin-top: 12px;
  border: 1px solid var(--line);
  background: #faf6ed;
}

.kb-retrieve-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 12px;
  border-bottom: 1px solid var(--line);
  font-size: 13.5px;
}

.kb-retrieve-head span {
  color: var(--muted);
  font-size: 12.5px;
}

.kb-hit {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 12px;
}

.kb-hit + .kb-hit {
  border-top: 1px solid var(--line);
}

.kb-hit .citation-index {
  flex: none;
  margin-top: 1px;
  font-family: var(--mono);
  font-size: 12.5px;
}

.kb-hit .mono {
  display: block;
  color: var(--muted);
  font-size: 12.5px;
}

.kb-hit blockquote {
  margin: 5px 0 0;
  font-size: 14.5px;
  line-height: 1.7;
}

.knowledge-detail {
  padding: 28px;
  min-height: 500px;
}

.kd-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding-bottom: 17px;
  border-bottom: 1px solid var(--line);
}

.kd-head h2 {
  margin: 7px 0 7px;
  font-family: var(--serif);
  font-size: 25px;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: 0.015em;
}

.kd-source {
  color: var(--muted);
  font-size: 13.5px;
}

.kd-source span {
  display: inline-block;
  margin-right: 7px;
  padding: 2px 5px;
  border: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 12.5px;
  letter-spacing: 0.04em;
}

.kd-statuses {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 16px 0;
}

.status-block {
  padding: 12px 13px;
  border: 1px solid var(--line);
  background: #faf6ed;
}

.status-block span {
  display: block;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 12.5px;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.status-block strong {
  display: block;
  margin-top: 5px;
  font-size: 14.5px;
  font-weight: 500;
  letter-spacing: 0.04em;
}

.status-block small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.kd-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 24px;
  margin-bottom: 16px;
}

.kd-meta > div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  padding: 7px 0;
  border-top: 1px solid var(--line);
  font-size: 13px;
}

.kd-meta span {
  color: var(--muted);
}

.kd-meta strong {
  font-weight: 400;
  font-size: 13px;
  text-align: right;
}

.kd-content {
  max-height: 210px;
  overflow-y: auto;
  padding: 18px 20px;
  border: 1px solid var(--line);
  background: #fffdf8;
  font-family: var(--serif);
  font-size: 15.5px;
  line-height: 1.9;
  color: #373a35;
  scrollbar-width: thin;
}

.kd-content p {
  margin: 0 0 8px;
}

.kd-content p:last-child {
  margin-bottom: 0;
}

.kd-content-note {
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.kd-issues {
  margin-top: 14px;
  padding: 10px 12px;
  border: 1px dashed var(--line-strong);
  font-size: 13px;
  line-height: 1.7;
}

.kd-issues strong {
  font-weight: 500;
  font-size: 13px;
}

.kd-issues ul {
  margin: 4px 0 0;
  padding-left: 14px;
  color: var(--muted);
}

.kd-issues li + li {
  margin-top: 2px;
}

.kd-timeline {
  display: flex;
  flex-wrap: wrap;
  gap: 7px 18px;
  margin-top: 14px;
  color: var(--muted);
  font-size: 13px;
}

.kd-timeline span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.kd-timeline i {
  width: 4px;
  height: 4px;
  border: 1px solid currentColor;
  border-radius: 50%;
}

.kd-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-top: 18px;
  padding-top: 15px;
  border-top: 1px solid var(--line);
}

.kd-actions .btn {
  min-height: 36px;
  padding: 0 13px;
  font-size: 13.5px;
}

.kd-actions .note {
  margin-left: auto;
  color: var(--muted);
  font-size: 13px;
}

.index-panel {
  margin-top: 22px;
}

.index-flow {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--line);
}

.index-step {
  display: grid;
  grid-template-columns: 25px 1fr;
  gap: 8px;
  padding: 15px 14px;
  border-right: 1px solid var(--line);
  background: transparent;
}

.index-step:last-child {
  border-right: 0;
}

.index-step > span {
  font-family: var(--mono);
  font-size: 12.5px;
  color: var(--muted);
}

.index-step strong {
  display: block;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.04em;
}

.index-step small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 13px;
}

.index-step.done {
  background: rgba(255, 253, 247, 0.3);
}

.index-step.done strong::after {
  content: " ✓";
  font-size: 13px;
}

.index-step.current {
  background: var(--forest);
  color: var(--paper);
  box-shadow: inset 2px 0 0 var(--accent-light);
}

.index-step.current > span,
.index-step.current small {
  color: rgba(244, 239, 229, 0.64);
}

.index-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding-top: 16px;
}

.index-foot p {
  max-width: 700px;
  margin: 0;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.7;
}

/* --------------------------------------------------------------------------
   P06 / audit
   -------------------------------------------------------------------------- */

.audit-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 26px;
  border: 1px solid var(--line);
}

.audit-stats > div {
  padding: 19px 21px 17px;
  border-right: 1px solid var(--line);
}

.audit-stats > div:last-child {
  border-right: 0;
}

.audit-stats strong {
  display: block;
  font-family: var(--serif);
  font-size: 31px;
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: 0.02em;
}

.audit-stats span {
  display: block;
  margin-top: 4px;
  font-size: 14px;
  letter-spacing: 0.04em;
}

.audit-stats small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 13px;
}

.audit-toolbar {
  display: flex;
  align-items: stretch;
  gap: 0;
  margin-top: 19px;
  padding: 5px 6px;
  border: 1px solid var(--line);
  background: rgba(251, 247, 238, 0.62);
}

.search-field {
  flex: 1;
  min-width: 150px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 11px;
}

.search-field .icon {
  width: 14px;
  height: 14px;
  color: var(--muted);
}

.search-field input {
  width: 100%;
  border: 0;
  background: transparent;
  font-size: 14.5px;
  outline: none;
}

.search-field input::placeholder {
  color: var(--muted-light);
}

.audit-toolbar select {
  padding: 0 13px;
  border: 0;
  border-left: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  font-size: 13.5px;
  outline: none;
  cursor: pointer;
}

.audit-tabs {
  display: flex;
  gap: 26px;
  margin-top: 19px;
  border-bottom: 1px solid var(--line);
}

.audit-tab {
  padding: 9px 0 11px;
  margin-bottom: -1px;
  border: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: var(--muted);
  font-size: 14.5px;
  letter-spacing: 0.05em;
  cursor: pointer;
  transition: color 0.3s var(--ease), border-color 0.3s var(--ease);
}

.audit-tab span {
  margin-left: 2px;
  color: var(--muted-light);
  font-family: var(--mono);
  font-size: 12.5px;
}

.audit-tab:hover,
.audit-tab.is-active {
  color: var(--accent-deep);
}

.audit-tab.is-active {
  border-bottom-color: var(--accent);
}

.audit-pane {
  margin-top: 22px;
}

.audit-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 346px;
  align-items: start;
  gap: 22px;
}

.audit-list-panel {
  padding: 0;
  overflow: hidden;
}

.data-table-wrap {
  width: 100%;
  overflow-x: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: auto;
  font-size: 14px;
}

.data-table th {
  padding: 10px 12px;
  border-bottom: 1px solid var(--line-strong);
  color: var(--muted);
  font-family: var(--mono);
  font-size: 12.5px;
  font-weight: 400;
  letter-spacing: 0.08em;
  text-align: left;
  text-transform: uppercase;
  white-space: nowrap;
}

.data-table td {
  padding: 12px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
  white-space: nowrap;
}

.data-table tbody tr {
  cursor: pointer;
  transition: background 0.25s var(--ease);
}

.data-table tbody tr:hover {
  background: #f3ede2;
}

.data-table tbody tr.is-selected {
  background: var(--sage-soft);
  box-shadow: inset 2px 0 0 var(--sage-deep);
}

.data-table tbody tr:last-child td {
  border-bottom: 0;
}

.data-table td strong {
  display: block;
  font-size: 14.5px;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.data-table td small {
  display: block;
  max-width: 160px;
  margin-top: 3px;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--muted);
  font-size: 13px;
}

.data-table .badge {
  font-size: 12.5px;
  min-height: 17px;
  padding: 2px 5px;
}

.audit-detail {
  padding: 22px;
}

.ad-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 15px;
  border-bottom: 1px solid var(--line);
}

.ad-head h2 {
  margin: 5px 0 3px;
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.ad-head p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.ad-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 18px;
  padding: 10px 0 6px;
}

.ad-meta > div {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding: 6px 0;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}

.ad-meta span {
  color: var(--muted);
}

.ad-meta strong {
  font-weight: 400;
  font-size: 13px;
  text-align: right;
}

.timeline {
  margin-top: 15px;
}

.timeline-title {
  margin-bottom: 11px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 12.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.timeline-item {
  position: relative;
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 10px;
  padding-bottom: 15px;
}

.timeline-item::before {
  content: "";
  position: absolute;
  top: 8px;
  bottom: -1px;
  left: 4px;
  width: 1px;
  background: var(--line);
}

.timeline-item:last-child {
  padding-bottom: 0;
}

.timeline-item:last-child::before {
  display: none;
}

.timeline-dot {
  position: relative;
  z-index: 1;
  width: 9px;
  height: 9px;
  margin-top: 3px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: var(--surface);
}

.timeline-item.done .timeline-dot {
  background: var(--sage-deep);
  border-color: var(--sage-deep);
}

.timeline-item.current .timeline-dot {
  background: var(--accent);
  border-color: var(--accent);
  box-shadow: inset 0 0 0 2px var(--paper);
}

.timeline-body time {
  display: block;
  color: var(--muted-light);
  font-family: var(--mono);
  font-size: 12.5px;
  letter-spacing: 0.02em;
}

.timeline-body strong {
  display: block;
  margin-top: 2px;
  font-size: 13.5px;
  font-weight: 500;
}

.timeline-body p {
  margin: 2px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

.ad-actions {
  display: flex;
  gap: 7px;
  margin-top: 16px;
  padding-top: 13px;
  border-top: 1px solid var(--line);
}

.ad-actions .btn {
  flex: 1;
  min-height: 34px;
  padding: 0 10px;
  font-size: 13px;
}

.calls-table td {
  font-size: 13.5px;
}

.table-note {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  margin: 0;
  padding: 12px 15px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.table-note .icon {
  width: 12px;
  height: 12px;
  margin-top: 1px;
  flex: none;
}

.manual-review {
  padding: 22px;
  border-color: var(--ochre-light);
  background: rgba(243, 230, 209, 0.4);
}

.manual-review h2 {
  margin: 7px 0 13px;
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.manual-meta > div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 7px 0;
  border-top: 1px solid var(--line);
  font-size: 13px;
}

.manual-meta span {
  color: var(--muted);
}

.manual-meta strong {
  font-weight: 400;
  font-size: 13px;
  text-align: right;
}

.manual-review .field {
  margin-top: 13px;
}

.manual-conclusions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  margin-top: 13px;
}

.manual-conclusions > span {
  width: 100%;
  margin-bottom: 1px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 12.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.manual-conclusions button {
  flex: 1;
  min-width: 75px;
  padding: 7px 6px;
  border: 1px solid var(--line);
  background: transparent;
  font-size: 13px;
  cursor: pointer;
  transition: border-color 0.3s var(--ease), background 0.3s var(--ease);
}

.manual-conclusions button:hover {
  border-color: var(--ochre);
  background: var(--ochre-soft);
}

.chain-panel {
  padding: 30px 34px;
}

.version-chain {
  margin-top: 18px;
}

.chain-item {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  gap: 16px;
}

.chain-node {
  position: relative;
  width: 9px;
  height: 9px;
  margin-top: 5px;
  margin-left: 5px;
  border: 1px solid var(--accent);
  border-radius: 50%;
  background: var(--paper);
}

.chain-item:not(:last-child) .chain-node::after {
  content: "";
  position: absolute;
  top: 10px;
  left: 3px;
  width: 1px;
  height: calc(100% + 94px);
  background: var(--line);
}

.chain-card {
  padding: 0 0 27px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 24px;
}

.chain-item:last-child .chain-card {
  border-bottom: 0;
  margin-bottom: 0;
  padding-bottom: 0;
}

.chain-card header {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.chain-card header > .mono:first-child {
  font-family: var(--serif);
  font-size: 27px;
  font-weight: 500;
  line-height: 1;
}

.chain-card header > .mono:last-child {
  margin-left: auto;
  font-size: 13px;
  color: var(--muted);
}

.chain-card h3 {
  margin: 10px 0 5px;
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.chain-card > p {
  margin: 0;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.7;
}

.chain-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 24px;
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
}

.chain-meta strong {
  font-weight: 400;
  color: var(--ink);
}

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */

.site-footer {
  padding: 16px 0;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
}

.flow-meta,
.flow-note {
  color: var(--muted);
  font-size: 14px;
  overflow-wrap: anywhere;
}

p.flow-meta {
  margin: 5px 0 0;
}

.flow-note {
  margin: 10px 0 0;
}

.flow-message {
  max-width: 810px;
  margin-top: 20px;
}

.flow-message p {
  margin: 0 0 6px;
}

.compact-details > summary {
  width: fit-content;
  cursor: pointer;
  color: var(--forest);
  font-weight: 500;
}

.compact-details > p {
  margin: 8px 0;
  overflow-wrap: anywhere;
}

.review-legal {
  margin-top: 20px;
  border-top: 2px solid var(--sage);
}

.review-legal h2 {
  display: flex;
  align-items: center;
  gap: 10px;
}

.review-legal h2 .icon {
  color: var(--sage-deep);
}

.clause-legal {
  padding: 10px 8px;
  border-top: 1px solid var(--line);
  overflow-wrap: anywhere;
}

.clause-legal[open] {
  background: var(--surface-2);
}

.clause-legal > summary {
  width: auto;
}

.clause-legal > summary > .badge {
  margin-inline-start: 6px;
  vertical-align: middle;
}

.clause-legal > .evidence-card {
  margin-top: 10px;
}

.clause-legal blockquote {
  white-space: pre-wrap;
}

.import-workspace:has(> .workspace-side[hidden]) {
  grid-template-columns: minmax(0, 740px);
}

.import-confirm.side-sticky {
  position: sticky;
  top: 96px;
  display: flex;
  gap: 12px;
}

.import-confirm .panel-head,
.import-confirm .flow-note,
.import-confirm .side-hint {
  margin: 0;
}

.import-confirm .check-row {
  grid-template-columns: 19px minmax(0, 1fr);
}

.check-row input:focus-visible + .check-box {
  outline: 2px solid var(--forest);
  outline-offset: 3px;
}

.import-overview {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}

.import-overview .flow-note {
  min-width: 0;
  margin: 0;
}

#importControls[hidden] + .import-overview {
  margin-top: 0;
}

.field select,
#knowledgeFilter {
  min-width: 0;
  min-height: 40px;
  padding: 7px 10px;
  border: 1px solid var(--line-strong);
  background: var(--surface);
  color: var(--ink);
  font: inherit;
}

.import-preview .doc-sheet {
  margin: 0;
  padding: 16px;
  box-shadow: none;
  border: 1px solid var(--line);
  overflow-wrap: anywhere;
}

.import-preview .doc-block {
  padding-inline-start: 52px;
}

.import-preview .compact-details {
  margin-bottom: 12px;
  font-size: 14px;
}

.question-toolbar,
.index-actions {
  display: flex;
  align-items: end;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}

.question-toolbar .field {
  flex: 1 1 200px;
  max-width: 290px;
}

.answer-head h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 500;
}

.knowledge-layout:has(> .knowledge-detail[hidden]),
.audit-layout:has(> aside[hidden]) {
  grid-template-columns: minmax(0, 1fr);
}

#kbForms {
  margin-top: 16px;
}

.table-run-label {
  padding: 4px 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.table-run-label:hover {
  text-decoration: underline;
}

#taskTable td,
.calls-table td,
.ad-meta strong,
.citation-meta span {
  white-space: normal;
  overflow-wrap: anywhere;
}

.search-field:focus-within {
  outline: 2px solid var(--forest);
  outline-offset: 2px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 245px minmax(0, 1fr) 300px;
  gap: 54px;
  align-items: start;
  padding-bottom: 38px;
  border-bottom: 1px solid rgba(244, 239, 229, 0.16);
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 11px;
}

.inverse-mark {
  border-color: rgba(244, 239, 229, 0.55);
  color: var(--paper);
}

.footer-brand > div {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.footer-brand strong {
  font-size: 16.5px;
  font-weight: 500;
  letter-spacing: 0.08em;
}

.footer-brand small {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  white-space: nowrap;
  color: rgba(244, 239, 229, 0.62);
}

.footer-copy {
  margin: 0;
  color: rgba(244, 239, 229, 0.64);
  font-size: 14px;
  line-height: 1.9;
}

.footer-links {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px 26px;
}

.footer-links a {
  color: rgba(244, 239, 229, 0.62);
  font-size: 14px;
  letter-spacing: 0.03em;
  transition: color 0.3s var(--ease);
}

.footer-links a:hover {
  color: var(--paper);
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding-top: 17px;
  color: rgba(244, 239, 229, 0.55);
  font-family: var(--mono);
  font-size: 12.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* --------------------------------------------------------------------------
   Toast
   -------------------------------------------------------------------------- */

.toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  z-index: 200;
  max-width: min(90vw, 480px);
  padding: 11px 17px;
  border: 1px solid rgba(244, 239, 229, 0.16);
  background: var(--forest);
  color: var(--paper);
  font-size: 14.5px;
  line-height: 1.6;
  letter-spacing: 0.03em;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 15px);
  transition: opacity 0.35s var(--ease), transform 0.35s var(--ease);
}

.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (max-width: 1280px) {
  :root {
    --gutter: 40px;
  }

  .header-inner {
    padding: 0 30px;
    gap: 28px;
  }

  .main-nav {
    gap: 26px;
  }

  .hero-specimen {
    width: 272px;
  }

  .workspace-grid {
    grid-template-columns: minmax(0, 1fr) 312px;
  }

  .detail-panel {
    padding: 28px;
  }

  .decision-layout {
    grid-template-columns: minmax(0, 1fr) 320px;
  }

  .qa-layout {
    grid-template-columns: 300px minmax(0, 1fr);
  }

  .knowledge-layout {
    grid-template-columns: 350px minmax(0, 1fr);
  }

  .audit-layout {
    grid-template-columns: minmax(0, 1fr) 320px;
  }
}

@media (max-width: 1120px) {
  .header-tools .queue-indicator {
    display: none;
  }

  .hero-specimen {
    width: 246px;
    padding: 18px 17px 14px;
  }

  .specimen-title {
    font-size: 18px;
  }

  .section-head {
    grid-template-columns: minmax(0, 1.2fr) 330px;
    gap: 50px;
  }

  .manifesto-grid {
    gap: 60px;
  }

  .page-head {
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 50px;
  }

  .bottom-grid {
    grid-template-columns: 1fr 1fr;
  }

  .next-panel {
    grid-column: 1 / -1;
  }

  .next-panel .btn {
    max-width: 260px;
  }

  .kb-hero {
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
    gap: 26px;
  }

  .kb-side {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    text-align: left;
    padding-top: 12px;
    border-top: 1px solid rgba(244, 239, 229, 0.13);
  }

  .kb-side p {
    margin: 0;
  }
}

@media (max-width: 980px) {
  /* 避免 backdrop-filter 为固定定位的移动导航创建错误的包含块 */
  .site-header {
    z-index: 85;
    background: var(--paper);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }

  .nav-toggle[aria-expanded="true"] {
    border-color: var(--forest);
    background: var(--forest);
    color: var(--paper);
  }

  .nav-toggle {
    position: relative;
    z-index: 95;
    display: grid;
    margin-left: auto;
  }

  .brand {
    position: relative;
    z-index: 95;
  }

  .main-nav {
    position: fixed;
    inset: 0;
    z-index: 80;
    display: none;
    width: 100%;
    margin: 0;
    padding: 105px 34px 34px;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--paper);
    overflow-y: auto;
  }

  .main-nav.is-open {
    display: flex;
    animation: navIn 0.42s var(--ease);
  }

  @keyframes navIn {
    from {
      transform: translateX(100%);
    }
    to {
      transform: translateX(0);
    }
  }

  .main-nav a {
    height: auto;
    padding: 17px 0;
    border-bottom: 1px solid var(--line);
    font-family: var(--serif);
    font-size: 19px;
    letter-spacing: 0.04em;
  }

  .main-nav a::after {
    display: none;
  }

  .main-nav a[aria-current="page"] {
    padding-left: 12px;
    border-left: 2px solid var(--accent);
  }

  .header-tools {
    margin-left: 0;
  }

  .hero-specimen {
    display: none;
  }

  .workflow-grid {
    gap: 20px;
  }

  .card-media {
    aspect-ratio: 1 / 1;
  }

  .section-head {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .section-copy {
    max-width: 560px;
  }

  .manifesto-grid {
    grid-template-columns: 1fr;
    gap: 50px;
  }

  .principles {
    padding-top: 0;
  }

  .closing-grid {
    grid-template-columns: 1fr auto;
    gap: 20px 40px;
  }

  .closing-grid .kicker {
    grid-column: 1 / -1;
  }

  .closing-copy {
    max-width: none;
  }

  .page-head {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .page-visual {
    max-width: 600px;
  }

  .compact-head {
    grid-template-columns: 1fr;
  }

  .page-head-actions {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
  }

  .workspace-grid {
    grid-template-columns: 1fr;
  }

  .side-sticky {
    position: static;
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }

  .import-confirm.side-sticky {
    position: static;
  }

  .side-sticky > .snapshot-panel {
    grid-row: span 2;
  }

  .import-top {
    grid-template-columns: 1fr;
  }

  .dropzone,
  .file-card {
    min-height: 210px;
  }

  .preview-layout {
    grid-template-columns: 1fr;
  }

  .block-list {
    display: flex;
    max-height: none;
    overflow-x: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    scrollbar-width: thin;
  }

  .block-item {
    flex: 0 0 205px;
    border-bottom: 0;
    border-right: 1px solid var(--line);
    border-left: 0;
    border-top: 2px solid transparent;
  }

  .block-item.is-selected {
    border-left-color: transparent;
    border-top-color: var(--ink);
  }

  .doc-sheet {
    max-height: 430px;
  }

  .run-strip {
    grid-template-columns: repeat(3, 1fr);
  }

  .run-strip > div:nth-child(3n) {
    border-right: 0;
  }

  .run-strip > div:nth-child(-n + 3) {
    border-bottom: 1px solid var(--line);
  }

  .review-layout {
    grid-template-columns: 1fr;
  }

  .findings-panel {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .finding-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .finding-row:nth-child(odd) {
    border-right: 1px solid var(--line);
  }

  .finding-row:last-child {
    border-bottom: 0;
  }

  .detail-panel {
    min-height: 0;
  }

  .decision-layout {
    grid-template-columns: 1fr;
  }

  .decision-side {
    position: static;
  }

  .qa-layout {
    grid-template-columns: 1fr;
  }

  .scope-panel {
    position: static;
  }

  .scope-list {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
  }

  .scope-card {
    grid-template-columns: 17px minmax(0, 1fr);
  }

  .scope-card em {
    display: none;
  }

  .scope-meta {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0 18px;
  }

  .knowledge-layout {
    grid-template-columns: 1fr;
  }

  .knowledge-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .knowledge-item:nth-child(odd) {
    border-right: 1px solid var(--line);
  }

  .index-flow {
    grid-template-columns: repeat(2, 1fr);
  }

  .index-step:nth-child(2) {
    border-right: 0;
  }

  .index-step:nth-child(-n + 2) {
    border-bottom: 1px solid var(--line);
  }

  .audit-layout {
    grid-template-columns: 1fr;
  }

  .audit-detail,
  .manual-review {
    max-width: none;
  }

  .footer-grid {
    grid-template-columns: 220px 1fr;
  }

  .footer-links {
    grid-column: 1 / -1;
    grid-template-columns: repeat(4, auto);
    justify-content: start;
    gap: 20px;
    padding-top: 4px;
  }
}

@media (max-width: 760px) {
  :root {
    --gutter: 22px;
  }

  .header-inner {
    position: relative;
    z-index: 90;
    height: 62px;
    padding: 0 20px;
    gap: 16px;
  }

  .brand-mark {
    width: 32px;
    height: 32px;
  }

  .brand-copy strong {
    font-size: 17px;
  }

  .brand-copy small {
    font-size: 8.5px;
    letter-spacing: 0.06em;
  }

  .header-tools .icon-button {
    display: none;
  }

  .mode-chip {
    font-size: 11px;
    padding: 5px 7px 4px;
  }

  .hero-media {
    object-position: 58% 50%;
  }

  .hero-copy {
    padding-block: 48px;
  }

  .hero h1 {
    font-size: clamp(32px, 7.5vw, 48px);
    line-height: 1.16;
  }

  .hero-lede {
    font-size: 16.5px;
    line-height: 1.85;
  }

  .hero-actions {
    flex-wrap: wrap;
    margin-top: 25px;
  }

  .hero-actions .btn {
    flex: 1;
    min-width: 145px;
    padding: 0 16px;
    font-size: 15.5px;
  }

  .hero-foot {
    left: 22px;
    right: 22px;
    padding-top: 11px;
    font-size: 12.5px;
  }

  .hide-small {
    display: none;
  }

  .editorial {
    padding-block: 32px 48px;
  }

  .section-head {
    padding-bottom: 24px;
  }

  .section-head h2 {
    font-size: 38px;
  }

  .workflow-grid {
    grid-template-columns: 1fr;
    gap: 22px;
    margin-top: 20px;
  }

  .card-media {
    aspect-ratio: 7 / 4;
  }

  .manifesto {
    padding: 70px 0;
  }

  .manifesto blockquote {
    font-size: clamp(27px, 8.2vw, 33px);
    letter-spacing: 0.01em;
  }

  .principles {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .recent {
    padding-top: 64px;
  }

  .recent-row {
    grid-template-columns: 52px minmax(0, 1fr) auto;
    gap: 12px;
    padding: 17px 6px;
  }

  .recent-row .badge {
    grid-column: 2 / 3;
    justify-self: start;
  }

  .recent-time,
  .recent-arrow {
    display: none;
  }

  .recent-main strong {
    font-size: 18px;
    white-space: normal;
  }

  .closing {
    padding-top: 62px;
    padding-bottom: 72px;
  }

  .closing-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .closing-copy {
    font-size: 19px;
  }

  .closing-grid .btn {
    justify-self: start;
  }

  .page {
    padding-top: 24px;
    padding-bottom: 42px;
  }

  .page-head {
    padding-bottom: 16px;
  }

  .compact-head {
    padding: 14px 16px;
  }

  .import-heading .page-visual {
    display: none;
  }

  .page-head h1,
  .compact-head h1 {
    font-size: clamp(30px, 9.2vw, 37px);
    line-height: 1.22;
    letter-spacing: 0.01em;
    text-wrap: balance;
    margin: 0;
  }

  .lede {
    font-size: 15.5px;
    line-height: 1.9;
  }

  .page-head-actions {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 11px;
  }

  .page-head-actions .badge {
    order: -1;
  }

  .step-rail {
    gap: 12px;
    margin-top: 18px;
  }

  .step-rail li {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
    padding: 9px 0 0;
  }

  .step-rail strong {
    font-size: 13px;
  }

  .workspace-grid,
  .decision-layout,
  .qa-layout,
  .knowledge-layout,
  .audit-layout {
    margin-top: 20px;
  }

  .workspace-main {
    gap: 16px;
  }

  .panel {
    padding: 19px;
  }

  .panel-head {
    margin-bottom: 16px;
  }

  .panel-head h2,
  .panel > h2 {
    font-size: 22px;
  }

  .panel-meta {
    gap: 8px;
    font-size: 13px;
  }

  .import-top {
    gap: 12px;
  }

  .dropzone {
    min-height: 190px;
    padding: 19px;
  }

  .file-card {
    min-height: auto;
    padding: 17px;
  }

  .file-facts {
    margin-top: 17px;
  }

  .check-strip {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }

  .preview-layout {
    min-height: 0;
  }

  .doc-sheet {
    margin: 11px;
    padding: 22px 18px 18px;
    font-size: 15px;
    line-height: 2;
  }

  .doc-block {
    padding-left: 32px;
  }

  .doc-block-id {
    left: 3px;
    font-size: 12.5px;
  }

  .check-row {
    grid-template-columns: 19px minmax(0, 1fr);
    padding: 12px;
  }

  .check-state {
    grid-column: 2;
    justify-self: start;
  }

  .party-grid {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .party-block {
    margin-top: 18px;
    padding-top: 18px;
  }

  .side-sticky {
    display: flex;
    align-items: stretch;
    gap: 12px;
  }

  .side-sticky > .snapshot-panel {
    grid-row: auto;
  }

  .snapshot-panel {
    padding: 20px;
  }

  .snapshot-panel > h2 {
    font-size: 22px;
  }

  .run-strip {
    grid-template-columns: 1fr 1fr;
    margin-top: 20px;
  }

  .run-strip > div {
    padding: 10px 11px;
  }

  .run-strip > div:nth-child(2n) {
    border-right: 0;
  }

  .run-strip > div:nth-child(3n) {
    border-right: 1px solid var(--line);
  }

  .run-strip > div:nth-child(2n) {
    border-right: 0;
  }

  .run-strip > div:nth-child(-n + 4) {
    border-bottom: 1px solid var(--line);
  }

  .metric-grid {
    grid-template-columns: 1fr 1fr;
    margin-top: 14px;
  }

  .metric {
    padding: 16px;
    border-bottom: 1px solid var(--line);
  }

  .metric:nth-child(2) {
    border-right: 0;
  }

  .metric:nth-child(n + 3) {
    border-bottom: 0;
  }

  .metric > strong {
    font-size: 28px;
  }

  .review-layout {
    margin-top: 17px;
  }

  .findings-panel {
    padding: 19px 16px 15px;
  }

  .finding-list {
    grid-template-columns: 1fr;
  }

  .finding-row:nth-child(odd) {
    border-right: 0;
  }

  .finding-row {
    padding: 13px 6px;
  }

  .detail-panel {
    padding: 21px 18px;
  }

  .detail-head {
    flex-direction: column;
    gap: 5px;
  }

  .detail-head h2 {
    font-size: 25px;
  }

  .detail-rule {
    padding-top: 0;
  }

  .detail-explanation {
    margin: 16px 0;
    font-size: 18px;
  }

  .evidence-card {
    padding: 14px;
  }

  .evidence-card blockquote {
    font-size: 16px;
  }

  .bottom-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .next-panel {
    grid-column: auto;
  }

  .next-panel .btn {
    max-width: none;
  }

  .candidate {
    padding: 16px 14px 14px;
  }

  .candidate-head {
    align-items: flex-start;
  }

  .candidate-head > .mono:last-child {
    display: none;
  }

  .candidate-reason {
    font-size: 16.5px;
  }

  .diff-row {
    grid-template-columns: 49px minmax(0, 1fr);
  }

  .diff-row > span {
    padding: 9px 7px;
    font-size: 12.5px;
  }

  .diff-row p {
    padding: 9px 10px;
    font-size: 14.5px;
  }

  .candidate-foot {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .decision-buttons button {
    flex: 1;
  }

  .decision-side {
    padding: 19px;
  }

  .scope-list {
    grid-template-columns: 1fr;
  }

  .scope-meta {
    grid-template-columns: 1fr;
  }

  .scope-meta > div:last-child {
    border-bottom: 0;
  }

  .question-panel,
  .supplement-panel,
  .answer-card {
    padding: 18px;
  }

  .question-box textarea {
    font-size: 19px;
  }

  .question-tools {
    flex-direction: column;
    align-items: stretch;
    gap: 11px;
  }

  .question-submit {
    justify-content: space-between;
  }

  .answer-text {
    font-size: 17.5px;
    line-height: 1.95;
  }

  .citation-item {
    grid-template-columns: 23px minmax(0, 1fr) 25px;
  }

  .qa-actions .text-link {
    margin-left: 0;
    width: 100%;
    margin-top: 4px;
  }

  .kb-hero {
    grid-template-columns: 1fr;
    gap: 20px;
    padding: 23px 19px;
    margin-top: 20px;
  }

  .kb-hero-main h2 {
    font-size: 29px;
  }

  .kb-stats {
    border-left: 0;
    border-top: 1px solid rgba(244, 239, 229, 0.16);
    padding-top: 15px;
  }

  .kb-stats > div {
    padding: 0 12px;
  }

  .kb-stats > div:first-child {
    padding-left: 0;
  }

  .kb-side {
    grid-column: auto;
  }

  .knowledge-tabs {
    gap: 18px;
  }

  .knowledge-list {
    grid-template-columns: 1fr;
  }

  .knowledge-item:nth-child(odd) {
    border-right: 0;
  }

  .knowledge-detail {
    padding: 20px 18px;
  }

  .kd-head {
    flex-direction: column;
    gap: 10px;
  }

  .kd-statuses,
  .kd-meta {
    grid-template-columns: 1fr;
  }

  .kd-content {
    padding: 14px;
  }

  .index-flow {
    grid-template-columns: 1fr;
  }

  .index-step {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .index-step:last-child {
    border-bottom: 0;
  }

  .index-step:nth-child(-n + 2) {
    border-bottom: 1px solid var(--line);
  }

  .index-foot {
    flex-direction: column;
    align-items: flex-start;
  }

  .audit-stats {
    grid-template-columns: 1fr 1fr;
    margin-top: 20px;
  }

  .audit-stats > div {
    padding: 15px;
    border-bottom: 1px solid var(--line);
  }

  .audit-stats > div:nth-child(2n) {
    border-right: 0;
  }

  .audit-stats > div:nth-child(n + 3) {
    border-bottom: 0;
  }

  .audit-stats strong {
    font-size: 27px;
  }

  .audit-toolbar {
    flex-wrap: wrap;
    padding: 8px;
    gap: 7px;
  }

  .search-field {
    flex-basis: 100%;
    min-height: 34px;
    border-bottom: 1px solid var(--line);
  }

  .audit-toolbar select {
    border-left: 0;
    padding: 4px 8px 4px 0;
    min-height: 26px;
  }

  .audit-toolbar .icon-button {
    margin-left: auto;
  }

  .audit-tabs {
    gap: 20px;
  }

  .audit-list-panel {
    overflow: hidden;
  }

  .chain-panel {
    padding: 20px 18px;
  }

  .chain-card header > .mono:last-child {
    margin-left: 0;
  }

  .chain-meta {
    gap: 6px 14px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .footer-links {
    grid-column: auto;
    grid-template-columns: 1fr 1fr;
    gap: 9px 24px;
    padding-top: 8px;
  }

  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 7px;
    font-size: 12.5px;
  }

}

@media (max-width: 430px) {
  .brand-copy small {
    display: none;
  }

  .mode-chip {
    font-size: 12.5px;
    padding: 5px 6px;
  }

  .hero-actions .btn {
    flex-basis: 100%;
  }

  .hero-foot {
    font-size: 12.5px;
  }

  .file-facts {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .check-strip {
    grid-template-columns: 1fr;
  }

  .question-submit .mono {
    display: none;
  }

  .question-submit .btn {
    width: 100%;
  }

  .audit-toolbar select {
    font-size: 13px;
  }
}

/* 320px 级窄屏：头部收紧，避免模式徽章顶破视口 */
@media (max-width: 360px) {
  .header-inner {
    padding: 0 16px;
    gap: 12px;
  }

  .mode-chip {
    font-size: 10px;
    padding: 4px 6px 3px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
