:root {
  color-scheme: dark;
  --red: #C81623;
  --red-dark: #7D0F18;
  --gold: #D4AF37;
  --gold-soft: #F0D982;
  --paper: #F9F6EF;
  --bg: #080C12;
  --bg-2: #0C131C;
  --panel: #101A26;
  --panel-2: #0D1722;
  --tile: #0B1420;
  --line: #203247;
  --line-strong: #2C425A;
  --ink: #EAF0F7;
  --title: #FFFFFF;
  --muted: #7F8D9E;
  --teal: #20C4BE;
  --green: #43E486;
  --warning: #FFC83D;
  --danger: #FF6B6B;
  --shadow: 0 18px 44px rgba(0, 0, 0, 0.34);
  --shadow-strong: 0 28px 70px rgba(0, 0, 0, 0.48);
}

* {
  box-sizing: border-box;
  letter-spacing: 0;
}

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(90deg, rgba(212, 175, 55, 0.025) 1px, transparent 1px),
    linear-gradient(rgba(212, 175, 55, 0.018) 1px, transparent 1px),
    linear-gradient(180deg, #0A0F16 0%, #08121A 52%, #080C12 100%);
  background-size: 46px 46px, 46px 46px, auto;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.66;
}

.app-shell { min-height: 100vh; }
a { color: inherit; text-decoration: none; }
button, input, textarea { font: inherit; }
h1, h2, h3, p { margin-top: 0; }
p { color: #AEB9C8; }
.muted { color: var(--muted); }

.nav, .inner {
  width: min(1280px, calc(100% - 56px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(7, 11, 17, 0.92);
  border-bottom: 1px solid rgba(44, 66, 90, 0.68);
  backdrop-filter: blur(14px);
}

.nav {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  font-weight: 900;
  white-space: nowrap;
}

.brand span:last-child {
  display: grid;
  gap: 1px;
  line-height: 1.08;
}

.brand strong {
  color: var(--title);
  font-size: 20px;
}

.brand small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.seal {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  color: var(--gold-soft);
  background: linear-gradient(145deg, rgba(125, 15, 24, 0.86), rgba(9, 14, 21, 0.96));
  border: 1px solid rgba(212, 175, 55, 0.52);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.05);
  font-family: "Songti SC", "STSong", "Noto Serif CJK SC", serif;
  font-weight: 900;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 22px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 760;
}

.nav-links a,
.nav-links button {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 2px;
  color: inherit;
  background: transparent;
  border: 0;
  border-radius: 0;
  cursor: pointer;
  font: inherit;
  font-weight: 780;
  white-space: nowrap;
}

.nav-links a:after,
.nav-links button:after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 2px;
  left: 0;
  height: 2px;
  background: transparent;
  border-radius: 999px;
  transition: background 0.18s ease, transform 0.18s ease;
  transform: scaleX(0.28);
}

.nav-links a:hover,
.nav-links button:hover {
  color: var(--ink);
  filter: none;
}

.nav-links a:hover:after,
.nav-links button:hover:after {
  background: rgba(212, 175, 55, 0.58);
  transform: scaleX(1);
}

.nav-links .nav-mode {
  min-height: 36px;
  padding: 0 2px;
  color: #B9C4D2;
  background: transparent;
  border: 0;
  border-radius: 0;
}

.nav-links .nav-mode.active {
  color: var(--paper);
  background: transparent;
}

.nav-links .nav-mode.active:after {
  right: 0;
  left: 0;
  background: var(--accent);
  transform: scaleX(1);
}

.view-switcher button {
  min-height: 38px;
  padding: 0 16px;
  color: #9FB0C3;
  background: rgba(16, 26, 38, 0.72);
  border: 1px solid rgba(44, 66, 90, 0.82);
  border-radius: 999px;
}

.view-switcher button.active {
  color: var(--paper);
  background: rgba(125, 15, 24, 0.34);
  border-color: rgba(200, 22, 35, 0.58);
}

button {
  min-height: 46px;
  padding: 0 18px;
  color: #FFF7E7;
  background: linear-gradient(180deg, #C91E2B, #8E1420);
  border: 1px solid rgba(200, 22, 35, 0.86);
  border-radius: 8px;
  cursor: pointer;
  font-weight: 900;
  white-space: nowrap;
}

button:hover { filter: brightness(1.06); }

button.secondary {
  color: var(--ink);
  background: rgba(16, 26, 38, 0.9);
  border-color: rgba(60, 82, 108, 0.95);
}

input, textarea {
  width: 100%;
  padding: 13px 14px;
  color: var(--ink);
  background: rgba(8, 15, 24, 0.92);
  border: 1px solid rgba(52, 75, 101, 0.86);
  border-radius: 8px;
  outline: none;
}

input::placeholder,
textarea::placeholder { color: #5F7186; }

input:focus,
textarea:focus {
  border-color: rgba(212, 175, 55, 0.82);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.13);
}

.hero {
  padding: 58px 0 8px;
}

.hero-panel {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(380px, 0.72fr);
  gap: 38px;
  min-height: 560px;
  padding: 58px;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(13, 23, 34, 0.94), rgba(8, 14, 22, 0.84)),
    linear-gradient(rgba(249, 246, 239, 0.035) 1px, transparent 1px);
  background-size: auto, 100% 34px;
  border: 1px solid rgba(65, 83, 107, 0.82);
  border-radius: 8px;
  box-shadow: var(--shadow-strong);
}

.hero-panel:after {
  content: "姓";
  position: absolute;
  right: 36px;
  bottom: -68px;
  color: rgba(255, 255, 255, 0.035);
  font-family: "Songti SC", "STSong", "Noto Serif CJK SC", serif;
  font-size: 260px;
  line-height: 1;
  pointer-events: none;
}

.hero-copy {
  position: relative;
  z-index: 1;
  max-width: 760px;
  align-self: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
  color: #B7A779;
  font-size: 15px;
  font-weight: 850;
}

.eyebrow:before {
  content: "姓";
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  color: var(--gold-soft);
  border: 1px solid rgba(212, 175, 55, 0.42);
  background: rgba(125, 15, 24, 0.22);
  font-family: "Songti SC", "STSong", "Noto Serif CJK SC", serif;
  font-size: 17px;
}

h1 {
  color: var(--title);
  font-family: "Songti SC", "STSong", "Noto Serif CJK SC", serif;
  line-height: 1.06;
  font-weight: 900;
}

.hero-copy h1 {
  max-width: 760px;
  margin: 0 0 22px;
  font-size: 72px;
}

.hero-copy h1:after {
  content: "AI 可信资料网络";
  display: block;
  color: var(--gold-soft);
}

.lead {
  max-width: 760px;
  margin: 0;
  color: #B7C1CE;
  font-size: 19px;
  font-weight: 700;
}

.summary-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 30px;
}

.metric {
  min-height: 104px;
  padding: 16px;
  background: rgba(9, 16, 26, 0.72);
  border: 1px solid rgba(74, 96, 122, 0.72);
  border-radius: 8px;
}

.metric strong {
  display: block;
  color: var(--gold-soft);
  font-size: 18px;
}

.metric span {
  display: block;
  margin-top: 6px;
  color: #A9B5C4;
  font-size: 13px;
  line-height: 1.55;
}

.ops-panel {
  position: relative;
  z-index: 1;
  align-self: center;
  width: 100%;
  padding: 24px;
  background: rgba(9, 16, 26, 0.82);
  border: 1px solid rgba(212, 175, 55, 0.24);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.panel-kicker {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.panel-kicker strong { color: var(--green); }

.ops-panel h2 {
  margin-bottom: 16px;
}

.ops-panel .muted {
  margin: 14px 0 18px;
  font-size: 13px;
}

.query-row {
  display: grid;
  grid-template-columns: 1fr 112px;
  gap: 10px;
  margin: 0;
  padding: 8px;
  background: rgba(5, 10, 17, 0.8);
  border: 1px solid rgba(80, 101, 128, 0.82);
  border-radius: 8px;
}

.query-row input {
  min-height: 56px;
  padding-left: 16px;
  background: rgba(255, 255, 255, 0.025);
  border: 0;
  font-size: 18px;
}

.query-row button {
  min-height: 56px;
}

.hot-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: stretch;
  gap: 10px;
  max-width: 980px;
  margin: 0 auto;
}

.chip {
  flex: 0 0 64px;
  min-width: 64px;
  min-height: 72px;
  display: grid;
  place-items: center;
  padding: 0 8px;
  color: var(--paper);
  background: rgba(16, 26, 38, 0.9);
  border: 1px solid rgba(65, 83, 107, 0.86);
  border-radius: 8px;
  font-family: "Songti SC", "STSong", "Noto Serif CJK SC", serif;
  font-size: 28px;
  font-weight: 900;
  line-height: 1.05;
  text-align: center;
  white-space: nowrap;
  cursor: pointer;
}

.chip[data-surname-length="2"] {
  flex-basis: 96px;
  min-width: 96px;
  font-size: 24px;
}

.chip[data-surname-length="3"],
.chip[data-surname-length="4"] {
  flex-basis: 112px;
  min-width: 112px;
  font-size: 20px;
}

.chip:hover {
  color: var(--gold-soft);
  border-color: rgba(212, 175, 55, 0.62);
  background: rgba(125, 15, 24, 0.28);
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 3px 12px;
  color: #9AE8D8;
  background: rgba(32, 196, 190, 0.09);
  border: 1px solid rgba(32, 196, 190, 0.28);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 850;
  white-space: nowrap;
}

.view-switcher {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin: 0 auto 20px;
}

[data-app-view].hidden { display: none; }

section {
  margin: 24px 0;
  padding: 34px;
  background: rgba(16, 26, 38, 0.9);
  border: 1px solid rgba(52, 75, 101, 0.86);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.section-band {
  position: relative;
  overflow: hidden;
}

.section-band > * {
  position: relative;
  z-index: 1;
}

h2 {
  margin-bottom: 24px;
  color: var(--title);
  font-size: 28px;
  line-height: 1.25;
  font-weight: 900;
}

h2:before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 28px;
  margin-right: 12px;
  vertical-align: -6px;
  background: linear-gradient(var(--gold-soft), var(--red));
  border-radius: 999px;
}

h3 {
  margin-bottom: 10px;
  color: var(--title);
  font-size: 20px;
  line-height: 1.3;
}

.back-home {
  display: inline-flex;
  margin: 0 0 24px;
  color: var(--muted);
  font-weight: 820;
}

.back-home:before {
  content: "←";
  margin-right: 8px;
}

.profile-head {
  position: relative;
  display: grid;
  grid-template-columns: 168px 1fr;
  gap: 30px;
  align-items: center;
  min-height: 248px;
  margin-bottom: 28px;
  padding: 36px;
  overflow: hidden;
  background:
    linear-gradient(90deg, rgba(24, 36, 50, 0.96), rgba(12, 22, 34, 0.82)),
    linear-gradient(rgba(249, 246, 239, 0.028) 1px, transparent 1px);
  background-size: auto, 100% 30px;
  border: 1px solid rgba(65, 83, 107, 0.96);
  border-radius: 8px;
}

.profile-head:after {
  content: attr(data-surname);
  position: absolute;
  right: 28px;
  top: -48px;
  color: rgba(255, 255, 255, 0.035);
  font-family: "Songti SC", "STSong", "Noto Serif CJK SC", serif;
  font-size: 260px;
  line-height: 1;
  white-space: nowrap;
  pointer-events: none;
}

.profile-head.surname-long:after {
  right: 20px;
  top: -18px;
  font-size: 160px;
}

.surname-mark {
  display: grid;
  place-items: center;
  width: 150px;
  aspect-ratio: 1;
  color: var(--gold-soft);
  background: rgba(125, 15, 24, 0.22);
  border: 1px solid rgba(212, 175, 55, 0.38);
  border-radius: 8px;
  font-family: "Songti SC", "STSong", "Noto Serif CJK SC", serif;
  font-size: 72px;
  font-weight: 900;
  line-height: 1.05;
  text-align: center;
  white-space: nowrap;
}

.surname-mark.surname-long {
  font-size: 52px;
}

.profile-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 10px;
}

.profile-title-row h3 {
  margin-bottom: 0;
  font-family: "Songti SC", "STSong", "Noto Serif CJK SC", serif;
  font-size: 40px;
}

.profile-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 10px 0 14px;
}

.meta-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 34px;
  padding: 4px 14px;
  color: #A8B8CB;
  background: rgba(33, 47, 65, 0.78);
  border: 1px solid rgba(76, 99, 128, 0.84);
  border-radius: 999px;
  font-size: 14px;
  font-weight: 850;
  white-space: nowrap;
}

.meta-pill small {
  color: #8190A2;
  font-size: 12px;
  font-weight: 820;
}

.profile-source-count {
  color: var(--gold-soft);
  background: rgba(212, 175, 55, 0.11);
  border-color: rgba(212, 175, 55, 0.42);
}

.profile-review-status {
  color: var(--green);
  background: rgba(67, 228, 134, 0.09);
  border-color: rgba(67, 228, 134, 0.3);
}

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

.profile-actions button,
.review-actions button,
.admin-tools button {
  min-height: 36px;
  padding: 0 12px;
  font-size: 13px;
}

.action-status,
.source-status,
.workspace-status,
.feedback-result,
.harness-result {
  min-height: 24px;
  color: var(--green);
  font-size: 13px;
  font-weight: 800;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 18px;
}

.info,
.phase,
.source,
.status-tile,
.pipeline-step,
.draft-card,
.review-item,
.source-item {
  background: rgba(9, 16, 26, 0.68);
  border: 1px solid rgba(52, 75, 101, 0.82);
  border-radius: 8px;
}

.info {
  padding: 12px 14px;
}

.info small,
.review-item small,
.field label,
.glyph span,
.route-node span {
  display: block;
  color: var(--muted);
}

.field label {
  margin: 0 0 6px;
  font-size: 13px;
  font-weight: 800;
}

.module-tabs {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  margin: 26px 0 22px;
  padding: 8px;
  background: rgba(8, 15, 24, 0.88);
  border: 1px solid rgba(52, 75, 101, 0.88);
  border-radius: 8px;
}

.module-tabs button {
  color: var(--muted);
  background: transparent;
  border-color: transparent;
}

.module-tabs button.active {
  color: var(--paper);
  background: rgba(125, 15, 24, 0.36);
  border-color: rgba(200, 22, 35, 0.52);
}

.panel { display: none; padding-top: 10px; }
.panel.active { display: block; }

.grid-2,
.grid-3,
.timeline,
.glyph-row,
.config-grid,
.status-board,
.pipeline {
  display: grid;
  gap: 14px;
}

.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.timeline { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.glyph-row { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.config-grid { grid-template-columns: 1.2fr 0.8fr; margin: 12px 0; }
.status-board, .pipeline { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.card {
  padding: 20px;
  background: rgba(9, 16, 26, 0.68);
  border: 1px solid rgba(52, 75, 101, 0.82);
  border-radius: 8px;
  box-shadow: inset 3px 0 0 rgba(212, 175, 55, 0.46);
}

.card p,
.card li,
li { color: #AEB9C8; }
ul { margin: 8px 0 0; padding-left: 19px; }
li { margin: 5px 0; }

.card .tag,
.phase .tag { justify-self: end; }

.phase {
  padding: 16px;
}

.phase strong,
.status-tile strong,
.pipeline-step strong,
.route-node strong {
  color: var(--gold-soft);
}

.migration-map {
  position: relative;
  min-height: 420px;
  margin-bottom: 16px;
  overflow: hidden;
  background:
    linear-gradient(90deg, rgba(212, 175, 55, 0.045) 1px, transparent 1px),
    linear-gradient(rgba(249, 246, 239, 0.035) 1px, transparent 1px),
    rgba(8, 15, 24, 0.82);
  background-size: 30px 30px;
  border: 1px solid rgba(52, 75, 101, 0.86);
  border-radius: 8px;
}

.migration-geo-map {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.migration-geo-map svg,
.migration-map svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.migration-geo-map svg {
  position: static;
  display: block;
}

.migration-region {
  fill: rgba(28, 44, 63, 0.82);
  stroke: rgba(122, 150, 185, 0.42);
  stroke-width: 1.2;
  transition: fill 160ms ease, stroke 160ms ease, filter 160ms ease;
}

.migration-region.active {
  fill: rgba(212, 175, 55, 0.5);
  stroke: rgba(249, 246, 239, 0.92);
  filter: drop-shadow(0 0 10px rgba(212, 175, 55, 0.34));
}

.migration-region.focused {
  fill: rgba(200, 22, 35, 0.6);
  stroke: rgba(249, 246, 239, 0.96);
}

.migration-label {
  fill: rgba(249, 246, 239, 0.82);
  font-size: 11px;
  text-anchor: middle;
  pointer-events: none;
}

.migration-map path.route-line {
  fill: none;
  stroke: var(--gold);
  stroke-width: 2.6;
  stroke-linecap: round;
  stroke-dasharray: 9 7;
  opacity: 0.72;
  pointer-events: none;
}

.migration-map-fallback {
  z-index: 1;
  pointer-events: none;
}

.route-node {
  position: absolute;
  z-index: 2;
  width: min(190px, 38vw);
  min-height: 86px;
  padding: 10px 12px;
  background: rgba(12, 22, 34, 0.96);
  border: 1px solid rgba(212, 175, 55, 0.48);
  border-radius: 8px;
  box-shadow: var(--shadow);
  cursor: pointer;
}

.route-node.active {
  border-color: rgba(249, 246, 239, 0.88);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.34), 0 0 0 2px rgba(212, 175, 55, 0.18);
}

.route-node:before {
  content: "";
  position: absolute;
  left: 12px;
  top: -7px;
  width: 12px;
  height: 12px;
  background: var(--red);
  border: 2px solid #071019;
  border-radius: 50%;
}

.route-node p {
  margin: 5px 0 0;
  color: #AEB9C8;
  font-size: 13px;
  line-height: 1.45;
}

.route-x-0 { left: 0%; } .route-x-5 { left: 5%; } .route-x-10 { left: 10%; } .route-x-15 { left: 15%; } .route-x-20 { left: 20%; } .route-x-25 { left: 25%; } .route-x-30 { left: 30%; } .route-x-35 { left: 35%; } .route-x-40 { left: 40%; } .route-x-45 { left: 45%; } .route-x-50 { left: 50%; } .route-x-55 { left: 55%; } .route-x-60 { left: 60%; } .route-x-65 { left: 65%; } .route-x-70 { left: 70%; } .route-x-75 { left: 75%; } .route-x-80 { left: 80%; } .route-x-85 { left: 85%; } .route-x-90 { left: 90%; } .route-x-95 { left: 95%; } .route-x-100 { left: 100%; }
.route-y-0 { top: 0%; } .route-y-5 { top: 5%; } .route-y-10 { top: 10%; } .route-y-15 { top: 15%; } .route-y-20 { top: 20%; } .route-y-25 { top: 25%; } .route-y-30 { top: 30%; } .route-y-35 { top: 35%; } .route-y-40 { top: 40%; } .route-y-45 { top: 45%; } .route-y-50 { top: 50%; } .route-y-55 { top: 55%; } .route-y-60 { top: 60%; } .route-y-65 { top: 65%; } .route-y-70 { top: 70%; } .route-y-75 { top: 75%; } .route-y-80 { top: 80%; } .route-y-85 { top: 85%; } .route-y-90 { top: 90%; } .route-y-95 { top: 95%; } .route-y-100 { top: 100%; }

.source-list,
.review-list,
.source-stack,
.source-form,
.workspace-tools {
  display: grid;
  gap: 10px;
}

.source,
.status-tile,
.pipeline-step,
.draft-card {
  padding: 14px;
}

.visual-grid {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 14px;
  align-items: stretch;
}

.totem-box {
  min-height: 220px;
  display: grid;
  place-items: center;
  color: var(--gold-soft);
  background: rgba(125, 15, 24, 0.2);
  border: 1px solid rgba(212, 175, 55, 0.4);
  border-radius: 8px;
  font-family: "Songti SC", "STSong", "Noto Serif CJK SC", serif;
  font-size: 92px;
  font-weight: 920;
  line-height: 1.05;
  text-align: center;
  white-space: nowrap;
}

.totem-box.surname-long {
  font-size: 58px;
}

.glyph {
  min-height: 88px;
  display: grid;
  place-items: center;
  padding: 10px;
  background: rgba(9, 16, 26, 0.72);
  border: 1px solid rgba(52, 75, 101, 0.86);
  border-radius: 8px;
  text-align: center;
}

.glyph strong {
  display: block;
  color: var(--gold-soft);
  font-size: 30px;
  line-height: 1.1;
}

.notice {
  margin-top: 12px;
  padding: 12px 14px;
  color: #AEB9C8;
  background: rgba(212, 175, 55, 0.06);
  border-left: 4px solid var(--gold);
  border-radius: 8px;
}

.harness-board {
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(360px, 0.88fr);
  gap: 14px;
}

.source-item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 10px 12px;
}

.source-item input {
  width: auto;
  accent-color: var(--red);
}

.draft-card pre {
  max-height: 300px;
  overflow: auto;
  margin: 10px 0 0;
  padding: 12px;
  color: #DCE6F3;
  background: #071019;
  border: 1px solid rgba(52, 75, 101, 0.86);
  border-radius: 8px;
  white-space: pre-wrap;
  word-break: break-word;
  font-size: 13px;
  line-height: 1.55;
}

.status-tile strong {
  display: block;
  font-size: 22px;
  line-height: 1.12;
}

.status-tile span {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.feedback-desk {
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px solid rgba(52, 75, 101, 0.86);
}

.desk-head,
.admin-tools,
.tool-row,
.review-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.desk-head { justify-content: space-between; }
.tool-row, .review-actions { flex-wrap: wrap; }
.review-actions { justify-content: flex-end; }

.review-item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 12px 14px;
}

.review-item strong { color: var(--title); }
.audit-request-id { margin-top: 3px; word-break: break-all; }
.source-form textarea { min-height: 92px; }
.workspace-tools textarea { min-height: 88px; font-size: 13px; }

.feedback {
  display: grid;
  grid-template-columns: 1fr 180px;
  gap: 10px;
  align-items: end;
}

textarea {
  min-height: 120px;
  resize: vertical;
}

.admin-shell {
  background:
    linear-gradient(90deg, rgba(212, 175, 55, 0.018) 1px, transparent 1px),
    linear-gradient(180deg, #080C12 0%, #0B121B 100%);
  background-size: 40px 40px, auto;
}

.admin-intro {
  padding: 46px 0 6px;
}

.admin-intro h1 {
  max-width: none;
  margin: 0 0 14px;
  font-size: 48px;
}

.admin-intro .lead {
  margin: 0;
  max-width: 840px;
}

.admin-overview {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 28px;
}

.admin-shell section {
  margin-top: 18px;
}

.admin-shell .card,
.admin-shell .status-tile,
.admin-shell .pipeline-step,
.admin-shell .review-item,
.admin-shell .source-item,
.admin-shell .draft-card {
  background: rgba(10, 18, 28, 0.82);
}

.admin-shell #profileEditor .card,
.admin-shell #surnameTask .card {
  box-shadow: inset 3px 0 0 rgba(200, 22, 35, 0.56);
}

.quick-surname-card {
  margin-bottom: 14px;
}

.task-grid {
  display: grid;
  grid-template-columns: minmax(360px, 0.82fr) minmax(0, 1fr);
  gap: 16px;
  align-items: stretch;
}

.quick-surname-row {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto;
  gap: 12px;
  align-items: end;
}

.inline-details,
.admin-details {
  margin-top: 14px;
  border: 1px solid rgba(44, 66, 90, 0.76);
  border-radius: 8px;
  background: rgba(8, 15, 24, 0.42);
}

.inline-details summary,
.admin-details summary {
  padding: 14px 16px;
  color: var(--title);
  cursor: pointer;
  font-weight: 900;
}

.inline-details > *:not(summary),
.admin-details > *:not(summary) {
  margin: 0 16px 16px;
}

.compact-source-form {
  padding-top: 2px;
}

.review-workbench {
  display: grid;
  gap: 14px;
}

.advanced-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 14px;
}

.admin-token-grid {
  margin-top: 14px;
  align-items: end;
}

.harness-config-card {
  box-shadow: inset 3px 0 0 rgba(212, 175, 55, 0.5);
}

.workspace-tools #resetDataBtn {
  color: #FFE8E8;
  border-color: rgba(255, 107, 107, 0.6);
  background: rgba(125, 15, 24, 0.42);
}

.login-shell {
  background:
    linear-gradient(90deg, rgba(249, 246, 239, 0.025) 1px, transparent 1px),
    linear-gradient(180deg, #080C12 0%, #0D1722 100%);
  background-size: 42px 42px, auto;
}

.login-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 32px;
}

.login-panel {
  width: min(980px, 100%);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 420px);
  gap: 22px;
  margin: 0;
  padding: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.login-context,
.login-card {
  padding: 34px;
  background: rgba(13, 23, 34, 0.88);
  border: 1px solid rgba(65, 83, 107, 0.82);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.login-context {
  display: grid;
  align-content: space-between;
  min-height: 460px;
  background:
    linear-gradient(135deg, rgba(24, 36, 50, 0.94), rgba(8, 14, 22, 0.9)),
    linear-gradient(rgba(249, 246, 239, 0.03) 1px, transparent 1px);
  background-size: auto, 100% 34px;
}

.login-context h1 {
  margin: 0 0 16px;
  font-size: 54px;
}

.login-context .lead {
  margin: 0;
  max-width: 520px;
}

.login-card h2 {
  margin-bottom: 8px;
}

.login-card h2:before {
  background: linear-gradient(var(--gold-soft), var(--red));
}

.login-proof {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.login-proof span {
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  color: var(--gold-soft);
  border: 1px solid rgba(212, 175, 55, 0.38);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 850;
}

.login-form {
  display: grid;
  gap: 10px;
  margin-top: 22px;
}

.login-form label {
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
}

.site-footer {
  margin-top: 22px;
  padding: 22px 0 36px;
  color: var(--muted);
  border-top: 1px solid rgba(52, 75, 101, 0.72);
  text-align: center;
  font-size: 13px;
}

.hidden { display: none; }

@media (max-width: 1100px) {
  .hero-panel {
    grid-template-columns: 1fr;
    padding: 44px;
  }
  .hot-list {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }
  .admin-overview {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .nav {
    align-items: flex-start;
    flex-direction: column;
    padding: 12px 0;
  }
  .nav-links { flex-wrap: wrap; }
  .hero {
    padding-top: 32px;
  }
  .hero-panel {
    min-height: auto;
    padding: 30px 20px;
  }
  .hero-copy h1,
  .login-context h1,
  .admin-intro h1 {
    font-size: 40px;
  }
  .lead {
    font-size: 16px;
  }
  .summary-grid,
  .query-row,
  .profile-head,
  .grid-2,
  .grid-3,
  .timeline,
  .feedback,
  .visual-grid,
  .harness-board,
  .pipeline,
  .config-grid,
  .status-board,
  .info-grid,
  .admin-overview,
  .task-grid,
  .advanced-grid,
  .quick-surname-row,
  .login-panel {
    grid-template-columns: 1fr;
  }
  .chip { min-height: 68px; }
  section {
    padding: 24px;
  }
  .module-tabs {
    grid-template-columns: 1fr;
  }
  .admin-tools,
  .profile-title-row {
    align-items: stretch;
    flex-direction: column;
  }
  .profile-actions {
    justify-content: flex-start;
  }
  .migration-map {
    min-height: auto;
    display: grid;
    gap: 10px;
    padding: 12px;
  }
  .migration-map svg { display: none; }
  .route-node {
    position: relative;
    left: auto;
    top: auto;
    width: 100%;
  }
  .login-page {
    padding: 18px;
  }
  .login-context,
  .login-card {
    padding: 24px;
  }
}

@media (max-width: 560px) {
  .nav, .inner {
    width: min(100% - 28px, 1280px);
  }
  .hot-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .brand {
    white-space: normal;
  }
  .profile-head {
    padding: 22px;
  }
  .surname-mark {
    width: 112px;
    font-size: 56px;
  }
}

@media print {
  .site-header, .ops-panel, .view-switcher, .module-tabs, .feedback, .site-footer, .profile-actions, .action-status { display: none; }
  body {
    color: #111;
    background: #fff;
  }
  section, .hero-panel {
    color: #111;
    background: #fff;
    box-shadow: none;
    break-inside: avoid;
  }
}
