:root {
  --ink: #17211b;
  --ink-soft: #536057;
  --line: #d9dfd8;
  --line-strong: #bcc7be;
  --surface: #ffffff;
  --surface-soft: #f3f6f2;
  --surface-raised: #fbfcfa;
  --green: #176b52;
  --green-strong: #0f5742;
  --green-soft: #e2f0e9;
  --amber: #b85f14;
  --amber-soft: #f8eadb;
  --red: #b13d37;
  --red-soft: #f8e3e2;
  --blue: #315f86;
  --blue-soft: #e4edf5;
  --shadow-sm: 0 1px 2px rgba(23, 33, 27, 0.06);
  --shadow-md: 0 12px 36px rgba(23, 33, 27, 0.12);
  --radius: 8px;
  --sidebar-width: 248px;
}

* {
  box-sizing: border-box;
}

html {
  color-scheme: light;
  background: var(--surface-soft);
}

body {
  margin: 0;
  min-width: 320px;
  color: var(--ink);
  background: var(--surface-soft);
  font-family:
    "Noto Sans SC",
    "Microsoft YaHei UI",
    "PingFang SC",
    sans-serif;
  font-size: 14px;
  line-height: 1.55;
}

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

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
a:focus-visible {
  outline: 3px solid rgba(23, 107, 82, 0.24);
  outline-offset: 2px;
}

svg {
  width: 18px;
  height: 18px;
  stroke-width: 1.8;
}

.skip-link {
  position: fixed;
  z-index: 200;
  top: 10px;
  left: 10px;
  padding: 8px 12px;
  color: #fff;
  background: var(--ink);
  border-radius: 4px;
  transform: translateY(-160%);
}

.skip-link:focus {
  transform: translateY(0);
}

.app-shell {
  display: grid;
  grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
  min-height: 100vh;
}

.sidebar {
  position: sticky;
  top: 0;
  display: flex;
  flex-direction: column;
  height: 100vh;
  padding: 20px 14px 16px;
  color: #e9f0eb;
  background: #18352b;
  border-right: 1px solid #24483b;
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 4px 8px 22px;
}

.brand-mark {
  display: grid;
  width: 38px;
  height: 38px;
  color: #173a2d;
  background: #dfeadf;
  border-radius: 7px;
  place-items: center;
}

.brand strong,
.brand span {
  display: block;
}

.brand strong {
  font-size: 16px;
  letter-spacing: 0.02em;
}

.brand span {
  margin-top: 1px;
  color: #a8bdb2;
  font-size: 12px;
}

.nav-list {
  display: grid;
  gap: 4px;
}

.nav-item {
  display: grid;
  grid-template-columns: 22px 1fr auto;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 43px;
  padding: 0 11px;
  color: #c8d6ce;
  text-align: left;
  background: transparent;
  border: 0;
  border-radius: 6px;
  cursor: pointer;
}

.nav-item:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.07);
}

.nav-item.is-active {
  color: #fff;
  background: #285342;
  box-shadow: inset 3px 0 #8fc8a9;
}

.nav-item svg {
  width: 18px;
  height: 18px;
}

.nav-count {
  min-width: 23px;
  padding: 1px 6px;
  color: #d9e7de;
  font-size: 11px;
  text-align: center;
  background: rgba(255, 255, 255, 0.09);
  border-radius: 999px;
}

.nav-group-label {
  margin: 18px 11px 6px;
  color: #82978c;
  font-size: 10px;
  font-weight: 750;
  letter-spacing: 0.08em;
}

.nav-item-internal {
  min-height: 38px;
  color: #adc0b5;
  font-size: 13px;
}

.sidebar-footer {
  margin-top: auto;
  padding: 16px 9px 4px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.service-state {
  display: flex;
  align-items: center;
  gap: 9px;
}

.service-state strong,
.service-state span {
  display: block;
}

.service-state strong {
  color: #eef5f0;
  font-size: 12px;
}

.service-state span {
  color: #9fb3a8;
  font-size: 11px;
}

.status-dot {
  width: 9px;
  height: 9px;
  background: #d49a4b;
  border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(212, 154, 75, 0.12);
}

.status-dot.is-online {
  background: #79c89d;
  box-shadow: 0 0 0 4px rgba(121, 200, 157, 0.12);
}

.status-dot.is-offline {
  background: #df7770;
  box-shadow: 0 0 0 4px rgba(223, 119, 112, 0.12);
}

.sidebar-footer p {
  margin: 13px 0 0;
  color: #82978c;
  font-size: 11px;
  line-height: 1.5;
}

.main-panel {
  min-width: 0;
}

.topbar {
  position: sticky;
  z-index: 30;
  top: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 84px;
  padding: 16px clamp(20px, 3vw, 42px);
  background: rgba(243, 246, 242, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}

.topbar h1 {
  margin: 0;
  font-size: 24px;
  line-height: 1.2;
  letter-spacing: 0;
}

.eyebrow {
  margin: 0 0 4px;
  color: var(--green);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.topbar-actions {
  display: flex;
  gap: 9px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 36px;
  padding: 0 13px;
  color: var(--ink);
  font-weight: 650;
  white-space: nowrap;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  cursor: pointer;
}

.button:hover {
  border-color: #8e9b91;
}

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

.button svg {
  width: 16px;
  height: 16px;
}

.button-primary {
  color: #fff;
  background: var(--green);
  border-color: var(--green);
}

.button-primary:hover {
  background: var(--green-strong);
  border-color: var(--green-strong);
}

.button-quiet {
  color: var(--ink-soft);
  background: transparent;
}

.button-danger {
  color: var(--red);
  border-color: #e1b7b3;
}

.button-sm {
  min-height: 31px;
  padding: 0 10px;
  font-size: 12px;
}

.icon-button {
  display: inline-grid;
  width: 34px;
  height: 34px;
  padding: 0;
  color: var(--ink-soft);
  background: transparent;
  border: 1px solid transparent;
  border-radius: 6px;
  cursor: pointer;
  place-items: center;
}

.icon-button:hover {
  color: var(--ink);
  background: var(--surface);
  border-color: var(--line);
}

.view-root {
  padding: 28px clamp(20px, 3vw, 42px) 48px;
}

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

.page-intro h2 {
  margin: 0;
  font-size: 20px;
  line-height: 1.3;
}

.page-intro p {
  max-width: 780px;
  margin: 5px 0 0;
  color: var(--ink-soft);
}

.metrics-band {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-bottom: 24px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.metric {
  min-height: 108px;
  padding: 19px 20px;
  border-right: 1px solid var(--line);
}

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

.metric-label {
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--ink-soft);
  font-size: 12px;
}

.metric-label svg {
  width: 15px;
  height: 15px;
  color: var(--green);
}

.metric-value {
  display: flex;
  align-items: baseline;
  gap: 5px;
  margin-top: 12px;
  font-size: 27px;
  font-weight: 780;
  line-height: 1;
}

.metric-value small {
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 600;
}

.metric-note {
  margin-top: 8px;
  color: var(--ink-soft);
  font-size: 11px;
}

.feature-band {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 28px;
  align-items: center;
  margin-bottom: 24px;
  padding: 25px 28px;
  color: #eef5f0;
  background:
    linear-gradient(115deg, rgba(255, 255, 255, 0.04), transparent 42%),
    #183f31;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.feature-copy {
  min-width: 0;
}

.feature-index {
  display: inline-block;
  margin-bottom: 9px;
  color: #9dd0b7;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.feature-copy h2 {
  margin: 0;
  color: #fff;
  font-size: 21px;
  line-height: 1.3;
}

.feature-copy p {
  max-width: 900px;
  margin: 9px 0 14px;
  color: #c7d9ce;
  font-size: 13px;
}

.feature-copy .tag {
  color: #d9e9df;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.14);
}

.feature-action {
  display: grid;
  justify-items: end;
  gap: 4px;
  padding-left: 24px;
  border-left: 1px solid rgba(255, 255, 255, 0.15);
}

.feature-action strong {
  color: #fff;
  font-size: 32px;
  line-height: 1;
}

.feature-action strong small {
  margin-left: 3px;
  color: #a9c7b8;
  font-size: 12px;
}

.feature-action > span {
  margin-bottom: 11px;
  color: #a9c7b8;
  font-size: 11px;
}

.feature-action .button {
  color: #17382c;
  background: #e4eee7;
  border-color: #e4eee7;
}

.public-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 310px;
  gap: 34px;
  align-items: stretch;
  margin-bottom: 30px;
  overflow: hidden;
  color: #edf5f0;
  background: #173d30;
  border-radius: var(--radius);
  box-shadow: 0 18px 48px rgba(23, 61, 48, 0.16);
}

.public-hero-main {
  padding: 42px 44px 38px;
}

.public-kicker,
.public-section-head span,
.timeline-intro > span,
.public-text-block > span,
.public-action-block > span,
.public-source-footer > div > span {
  display: block;
  margin-bottom: 9px;
  color: #92c8ac;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.07em;
}

.public-hero h2 {
  max-width: 880px;
  margin: 0;
  color: #fff;
  font-size: clamp(28px, 3vw, 42px);
  line-height: 1.18;
  letter-spacing: -0.02em;
}

.public-hero-main > p {
  max-width: 920px;
  margin: 18px 0 18px;
  color: #c8d9cf;
  font-size: 15px;
  line-height: 1.75;
}

.public-hero .tag {
  color: #dcebe2;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.14);
}

.public-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.button-light {
  color: #17382c;
  background: #e5efe8;
  border-color: #e5efe8;
}

.button-dark-outline {
  color: #e4eee7;
  background: transparent;
  border-color: rgba(255, 255, 255, 0.3);
}

.button-dark-outline:hover {
  border-color: rgba(255, 255, 255, 0.58);
}

.public-hero-facts {
  display: grid;
  align-content: center;
  padding: 28px 30px;
  background: rgba(255, 255, 255, 0.055);
  border-left: 1px solid rgba(255, 255, 255, 0.12);
}

.public-fact {
  padding: 14px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.public-fact:last-child {
  border-bottom: 0;
}

.public-fact span,
.public-fact strong {
  display: block;
}

.public-fact span {
  margin-bottom: 3px;
  color: #91aa9d;
  font-size: 11px;
}

.public-fact strong {
  color: #f3f7f4;
  font-size: 14px;
}

.public-section {
  margin-bottom: 30px;
}

.public-section-head {
  margin-bottom: 15px;
}

.public-section-head h2,
.timeline-intro h2,
.public-text-block h2,
.public-action-block h2 {
  margin: 0;
  font-size: 22px;
  line-height: 1.3;
}

.conclusion-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.conclusion-item {
  min-height: 218px;
  padding: 24px 22px;
  border-right: 1px solid var(--line);
}

.conclusion-item:last-child {
  border-right: 0;
}

.conclusion-index {
  color: var(--green);
  font-size: 11px;
  font-weight: 800;
}

.conclusion-item h3 {
  margin: 23px 0 9px;
  font-size: 17px;
}

.conclusion-item p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 13px;
  line-height: 1.7;
}

.conclusion-item small {
  display: block;
  margin-top: 18px;
  color: #819087;
  font-size: 11px;
}

.timeline-band {
  display: grid;
  grid-template-columns: 0.8fr 1.7fr;
  gap: 30px;
  align-items: center;
  margin-bottom: 30px;
  padding: 28px 30px;
  background: #e7efe9;
  border: 1px solid #cfddd3;
  border-radius: var(--radius);
}

.timeline-intro p {
  margin: 8px 0 0;
  color: var(--ink-soft);
  font-size: 12px;
}

.timeline-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.timeline-step {
  min-height: 104px;
  padding: 17px;
  background: #fff;
  border: 1px solid #cfdcd3;
  border-radius: 6px;
}

.timeline-step strong,
.timeline-step span {
  display: block;
}

.timeline-step strong {
  color: var(--green-strong);
  font-size: 17px;
}

.timeline-step span {
  margin-top: 14px;
  color: var(--ink-soft);
  font-size: 12px;
}

.public-insight-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(300px, 0.75fr);
  gap: 30px;
  margin-bottom: 30px;
}

.public-text-block,
.public-action-block {
  padding: 28px 30px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.public-text-block p {
  margin: 14px 0 0;
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.75;
}

.public-action-block ol {
  margin: 19px 0 0;
  padding-left: 22px;
}

.public-action-block li {
  margin: 11px 0;
  color: #354239;
}

.public-source-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  padding: 20px 0 4px;
  border-top: 1px solid var(--line);
}

.public-source-footer strong,
.public-source-footer p {
  display: block;
}

.public-source-footer strong {
  font-size: 13px;
}

.public-source-footer p {
  margin: 3px 0 0;
  color: var(--ink-soft);
  font-size: 11px;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.75fr) minmax(270px, 0.75fr);
  gap: 22px;
  align-items: start;
}

.section-block {
  min-width: 0;
}

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

.section-head h2,
.section-head h3 {
  margin: 0;
  font-size: 16px;
}

.section-head h3 {
  font-size: 14px;
}

.section-head p {
  margin: 2px 0 0;
  color: var(--ink-soft);
  font-size: 12px;
}

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

.surface-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 52px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
}

.surface-header h3 {
  margin: 0;
  font-size: 14px;
}

.surface-body {
  padding: 16px;
}

.table-wrap {
  overflow-x: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

.data-table th,
.data-table td {
  padding: 12px 14px;
  text-align: left;
  vertical-align: middle;
  border-bottom: 1px solid var(--line);
}

.data-table th {
  color: var(--ink-soft);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.03em;
  background: #f8faf7;
}

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

.data-table tbody tr {
  cursor: pointer;
}

.data-table tbody tr:hover {
  background: #f8fbf8;
}

.policy-title-cell strong {
  display: block;
  overflow: hidden;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.policy-title-cell span {
  display: block;
  overflow: hidden;
  margin-top: 3px;
  color: var(--ink-soft);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 23px;
  padding: 2px 8px;
  color: #445149;
  font-size: 11px;
  font-weight: 650;
  background: #eef2ee;
  border: 1px solid #dfe5df;
  border-radius: 999px;
}

.tag-green {
  color: #135d47;
  background: var(--green-soft);
  border-color: #c6e2d4;
}

.tag-amber {
  color: #8e4812;
  background: var(--amber-soft);
  border-color: #efcfac;
}

.tag-red {
  color: #8f302b;
  background: var(--red-soft);
  border-color: #edc6c3;
}

.tag-blue {
  color: #285477;
  background: var(--blue-soft);
  border-color: #c7d9e8;
}

.source-list {
  display: grid;
}

.source-item {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
}

.source-item:last-child {
  border-bottom: 0;
}

.source-icon {
  display: grid;
  width: 34px;
  height: 34px;
  color: var(--green);
  background: var(--green-soft);
  border-radius: 6px;
  place-items: center;
}

.source-item strong,
.source-item span {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.source-item strong {
  font-size: 12px;
}

.source-item span {
  margin-top: 2px;
  color: var(--ink-soft);
  font-size: 11px;
}

.progress-track {
  width: 100%;
  height: 7px;
  overflow: hidden;
  background: #e6ebe6;
  border-radius: 999px;
}

.progress-bar {
  height: 100%;
  background: var(--green);
  border-radius: inherit;
}

.progress-bar.warning {
  background: var(--amber);
}

.progress-bar.danger {
  background: var(--red);
}

.progress-value {
  margin-top: 7px;
  color: var(--ink-soft);
  font-size: 11px;
}

.toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
  padding: 12px 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.search-field {
  position: relative;
  flex: 1 1 280px;
}

.search-field svg {
  position: absolute;
  top: 50%;
  left: 11px;
  width: 16px;
  height: 16px;
  color: var(--ink-soft);
  transform: translateY(-50%);
}

.input,
.select,
.textarea {
  width: 100%;
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
}

.input,
.select {
  min-height: 38px;
  padding: 7px 10px;
}

.search-field .input {
  padding-left: 35px;
}

.textarea {
  min-height: 140px;
  padding: 10px 11px;
  line-height: 1.6;
  resize: vertical;
}

.textarea-lg {
  min-height: 240px;
}

.input:hover,
.select:hover,
.textarea:hover {
  border-color: #98a69b;
}

.input:focus,
.select:focus,
.textarea:focus {
  border-color: var(--green);
  outline: 3px solid rgba(23, 107, 82, 0.12);
  outline-offset: 0;
}

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

.field {
  min-width: 0;
}

.field-span-2 {
  grid-column: span 2;
}

.field-span-3 {
  grid-column: 1 / -1;
}

.field label,
.field-label {
  display: block;
  margin-bottom: 6px;
  color: #38453d;
  font-size: 12px;
  font-weight: 700;
}

.field-hint {
  margin-top: 5px;
  color: var(--ink-soft);
  font-size: 11px;
}

.check-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.check-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 34px;
  padding: 6px 10px;
  color: #435048;
  background: #fff;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  cursor: pointer;
}

.check-chip:has(input:checked) {
  color: var(--green-strong);
  background: var(--green-soft);
  border-color: #91bba6;
}

.check-chip input {
  width: 15px;
  height: 15px;
  margin: 0;
  accent-color: var(--green);
}

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

.workbench-main {
  display: grid;
  gap: 20px;
}

.side-stack {
  position: sticky;
  top: 108px;
  display: grid;
  gap: 16px;
}

.step-list {
  display: grid;
  gap: 0;
}

.step-item {
  position: relative;
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr);
  gap: 10px;
  min-height: 72px;
  padding-bottom: 16px;
}

.step-item:not(:last-child)::before {
  position: absolute;
  top: 27px;
  bottom: 0;
  left: 12px;
  width: 1px;
  background: var(--line);
  content: "";
}

.step-number {
  position: relative;
  z-index: 1;
  display: grid;
  width: 26px;
  height: 26px;
  color: var(--ink-soft);
  font-size: 11px;
  font-weight: 750;
  background: #eef2ee;
  border: 1px solid var(--line);
  border-radius: 50%;
  place-items: center;
}

.step-item.is-complete .step-number,
.step-item.is-active .step-number {
  color: #fff;
  background: var(--green);
  border-color: var(--green);
}

.step-item.is-active .step-number {
  box-shadow: 0 0 0 5px rgba(23, 107, 82, 0.1);
}

.step-item strong,
.step-item span {
  display: block;
}

.step-item strong {
  padding-top: 2px;
  font-size: 12px;
}

.step-item span {
  margin-top: 3px;
  color: var(--ink-soft);
  font-size: 11px;
}

.evidence-block {
  overflow: hidden;
}

.evidence-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 15px 16px;
  border-bottom: 1px solid var(--line);
}

.evidence-title {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.evidence-index {
  display: grid;
  flex: 0 0 auto;
  width: 26px;
  height: 26px;
  color: var(--green);
  font-size: 12px;
  font-weight: 800;
  background: var(--green-soft);
  border-radius: 50%;
  place-items: center;
}

.evidence-title strong,
.evidence-title span {
  display: block;
}

.evidence-title strong {
  font-size: 13px;
}

.evidence-title span {
  margin-top: 2px;
  color: var(--ink-soft);
  font-size: 11px;
}

.evidence-body {
  display: grid;
  gap: 12px;
  padding: 16px;
}

.source-fetch-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

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

.report-document {
  padding: 32px 36px 44px;
}

.report-document h2 {
  margin: 0;
  font-size: 25px;
  line-height: 1.3;
}

.report-kicker {
  margin-bottom: 8px;
  color: var(--green);
  font-size: 12px;
  font-weight: 750;
}

.report-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.report-section {
  padding-top: 26px;
  margin-top: 26px;
  border-top: 1px solid var(--line);
}

.report-section:first-of-type {
  border-top: 0;
}

.report-section h3 {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 13px;
  font-size: 17px;
}

.report-section h3 span {
  display: grid;
  width: 25px;
  height: 25px;
  color: #fff;
  font-size: 11px;
  background: var(--green);
  border-radius: 5px;
  place-items: center;
}

.report-section h4 {
  margin: 18px 0 7px;
  font-size: 14px;
}

.report-section p {
  margin: 0 0 11px;
}

.report-section ul,
.report-section ol {
  margin: 0;
  padding-left: 22px;
}

.report-section li {
  margin: 7px 0;
}

.report-summary {
  padding: 16px 17px;
  color: #173d2f;
  background: #e8f2ec;
  border-left: 4px solid var(--green);
  border-radius: 0 6px 6px 0;
}

.source-quote {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
}

.source-quote:last-child {
  border-bottom: 0;
}

.source-quote .tag {
  align-self: start;
}

.source-quote p {
  margin: 0;
}

.comparison-table th:first-child,
.comparison-table td:first-child {
  width: 120px;
}

.risk-list {
  display: grid;
  gap: 9px;
}

.risk-item {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 10px;
  padding: 11px 12px;
  background: #fafbf9;
  border: 1px solid var(--line);
  border-radius: 5px;
}

.risk-level {
  color: var(--red);
  font-size: 11px;
  font-weight: 800;
}

.risk-item strong,
.risk-item p {
  display: block;
  margin: 0;
}

.risk-item p {
  margin-top: 3px;
  color: var(--ink-soft);
  font-size: 12px;
}

.profile-layout {
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  gap: 22px;
  align-items: start;
}

.profile-summary {
  padding: 20px;
}

.avatar-block {
  display: flex;
  align-items: center;
  gap: 13px;
  padding-bottom: 17px;
  border-bottom: 1px solid var(--line);
}

.avatar {
  display: grid;
  width: 48px;
  height: 48px;
  color: #fff;
  background: var(--green);
  border-radius: 8px;
  place-items: center;
}

.avatar svg {
  width: 24px;
  height: 24px;
}

.avatar-block strong,
.avatar-block span {
  display: block;
}

.avatar-block span {
  margin-top: 3px;
  color: var(--ink-soft);
  font-size: 12px;
}

.definition-list {
  display: grid;
  gap: 13px;
  margin-top: 17px;
}

.definition-list dt {
  color: var(--ink-soft);
  font-size: 11px;
  font-weight: 700;
}

.definition-list dd {
  margin: 3px 0 0;
  font-size: 12px;
}

.empty-state {
  display: grid;
  min-height: 320px;
  padding: 30px;
  text-align: center;
  place-items: center;
}

.empty-state-inner {
  max-width: 430px;
}

.empty-icon {
  display: grid;
  width: 54px;
  height: 54px;
  margin: 0 auto 14px;
  color: var(--green);
  background: var(--green-soft);
  border-radius: 8px;
  place-items: center;
}

.empty-icon svg {
  width: 26px;
  height: 26px;
}

.empty-state h3 {
  margin: 0;
  font-size: 17px;
}

.empty-state p {
  margin: 7px 0 0;
  color: var(--ink-soft);
}

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

.split-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

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

.mono {
  font-family:
    "Cascadia Mono",
    "SFMono-Regular",
    Consolas,
    monospace;
}

.prompt-editor {
  min-height: 420px;
  font-family:
    "Cascadia Mono",
    "SFMono-Regular",
    Consolas,
    monospace;
  font-size: 12px;
  line-height: 1.7;
}

.toast-region {
  position: fixed;
  z-index: 150;
  right: 18px;
  bottom: 18px;
  display: grid;
  gap: 9px;
  width: min(360px, calc(100vw - 36px));
}

.toast {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 9px;
  padding: 12px 13px;
  color: #fff;
  background: #213d32;
  border-radius: 7px;
  box-shadow: var(--shadow-md);
  animation: toast-in 180ms ease-out;
}

.toast.is-error {
  background: #873b35;
}

.toast strong,
.toast span {
  display: block;
}

.toast span {
  margin-top: 2px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 11px;
}

.toast-icon {
  display: grid;
  width: 28px;
  height: 28px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 5px;
  place-items: center;
}

.loading-layer {
  position: fixed;
  z-index: 180;
  inset: 0;
  display: grid;
  background: rgba(15, 28, 22, 0.45);
  backdrop-filter: blur(3px);
  place-items: center;
}

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

.loading-box {
  width: min(340px, calc(100vw - 40px));
  padding: 24px;
  text-align: center;
  background: #fff;
  border-radius: 8px;
  box-shadow: var(--shadow-md);
}

.spinner {
  display: block;
  width: 34px;
  height: 34px;
  margin: 0 auto 13px;
  border: 3px solid #dbe5dd;
  border-top-color: var(--green);
  border-radius: 50%;
  animation: spin 700ms linear infinite;
}

.loading-box strong {
  font-size: 14px;
}

.loading-box p {
  margin: 5px 0 0;
  color: var(--ink-soft);
  font-size: 12px;
}

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

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

@media (max-width: 1180px) {
  .metrics-band {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .metric:nth-child(-n + 2) {
    border-bottom: 1px solid var(--line);
  }

  .dashboard-grid,
  .workbench-layout,
  .report-shell {
    grid-template-columns: minmax(0, 1fr);
  }

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

  .feature-action {
    justify-items: start;
    padding: 18px 0 0;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    border-left: 0;
  }

  .public-hero {
    grid-template-columns: minmax(0, 1fr) 270px;
  }

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

  .conclusion-item:nth-child(2) {
    border-right: 0;
  }

  .conclusion-item:nth-child(-n + 2) {
    border-bottom: 1px solid var(--line);
  }

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

  .side-stack {
    position: static;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

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

  .sidebar {
    position: sticky;
    z-index: 60;
    top: 0;
    height: auto;
    padding: 10px 12px;
    border-right: 0;
    border-bottom: 1px solid #24483b;
  }

  .brand {
    padding: 0 4px 10px;
  }

  .nav-list {
    display: flex;
    gap: 5px;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .nav-item {
    display: flex;
    flex: 0 0 auto;
    width: auto;
    min-height: 36px;
    padding: 0 10px;
    white-space: nowrap;
  }

  .nav-item.is-active {
    box-shadow: inset 0 -3px #8fc8a9;
  }

  .nav-count,
  .nav-group-label,
  .sidebar-footer {
    display: none;
  }

  .topbar {
    position: static;
    padding: 16px 18px;
  }

  .view-root {
    padding: 20px 18px 40px;
  }

  .field-grid,
  .profile-layout,
  .side-stack {
    grid-template-columns: minmax(0, 1fr);
  }

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

  .public-hero-main {
    padding: 32px 26px 30px;
  }

  .public-hero-facts {
    padding: 20px 26px;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    border-left: 0;
  }

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

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

  .public-source-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .field-span-2,
  .field-span-3 {
    grid-column: auto;
  }

  .topbar-actions .button-quiet {
    display: none;
  }
}

@media (max-width: 620px) {
  .topbar {
    align-items: flex-start;
  }

  .topbar h1 {
    font-size: 20px;
  }

  .topbar-actions .button-primary span {
    display: none;
  }

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

  .conclusion-item,
  .conclusion-item:nth-child(2) {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .conclusion-item:last-child {
    border-bottom: 0;
  }

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

  .metric,
  .metric:nth-child(2) {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .metric:last-child {
    border-bottom: 0;
  }

  .report-document {
    padding: 22px 18px 32px;
  }

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

  .data-table {
    table-layout: auto;
  }
}

@media print {
  .sidebar,
  .topbar,
  .side-stack,
  .toast-region,
  .button {
    display: none !important;
  }

  .app-shell,
  .report-shell {
    display: block;
  }

  .view-root {
    padding: 0;
  }

  .report-document {
    border: 0;
    box-shadow: none;
  }
}
