@charset "UTF-8";

:root {
  --paper: #fafbf9;
  --surface: #ffffff;
  --surface-muted: #f0f5f9;
  --ink: #18324b;
  --ink-soft: #3e5367;
  --muted: #526579;
  --line: #dce5ec;
  --line-strong: #76899b;
  --feihe: #bf2638;
  --evidence: #315e80;
  --quality: #35705a;
  --warning: #876321;
  --critical: #a52636;
  --sidebar: #f4f7fa;
  --sidebar-soft: #e8eff5;
  --brand-soft: #fceef0;
  --brand-hover: #f7e1e5;
  --info-soft: #edf4fa;
  --gold: #94733b;
  --gold-ink: #74551f;
  --gold-soft: #fcf8ef;
  --success-soft: #eaf3ee;
  --warning-soft: #fbf1df;
  --danger-soft: #f8e7e8;
  --shadow: 0 14px 38px rgba(23, 36, 49, 0.07);
  --shadow-soft: 0 5px 18px rgba(23, 36, 49, 0.06);
  --radius: 10px;
  --display: "Avenir Next", "PingFang SC", "Hiragino Sans GB", sans-serif;
  --body: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", sans-serif;
  --mono: "SFMono-Regular", "Cascadia Code", "Roboto Mono", monospace;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  font-size: 14px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

button,
select,
input {
  font: inherit;
}

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

button {
  color: inherit;
}

button:focus-visible,
select:focus-visible,
input:focus-visible,
a:focus-visible,
summary:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid var(--evidence);
  outline-offset: 2px;
}

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

.skip-link {
  position: fixed;
  z-index: 200;
  top: 12px;
  left: 12px;
  padding: 9px 14px;
  transform: translateY(-160%);
  border-radius: 6px;
  background: var(--ink);
  color: white;
  text-decoration: none;
}

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

.app-shell {
  min-height: 100vh;
}

.sidebar {
  position: fixed;
  z-index: 40;
  inset: 0 auto 0 0;
  display: flex;
  width: 226px;
  flex-direction: column;
  overflow-y: auto;
  padding: 22px 15px 18px;
  background: var(--sidebar);
  color: var(--ink);
}

.brand-lockup {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 0 7px 22px;
  color: var(--ink);
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 1px solid var(--feihe);
  background: var(--feihe);
  color: white;
  font-family: var(--display);
  font-size: 19px;
  font-weight: 800;
  transform: rotate(-3deg);
}

.brand-copy {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.brand-copy b {
  font-family: var(--display);
  font-size: 16px;
  letter-spacing: 0.04em;
}

.brand-copy small {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 8px;
  letter-spacing: 0.1em;
}

.primary-nav {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 4px;
}

.nav-label {
  margin: 14px 10px 7px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.nav-label-secondary {
  margin-top: 24px;
}

.nav-item {
  display: grid;
  width: 100%;
  grid-template-columns: 24px 1fr auto;
  align-items: center;
  gap: 8px;
  padding: 10px 11px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--ink-soft);
  cursor: pointer;
  text-align: left;
  transition: background-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.nav-item:hover {
  background: var(--sidebar-soft);
  color: var(--ink);
  transform: translateX(2px);
}

.nav-item.is-active {
  background: var(--brand-soft);
  color: var(--feihe);
  box-shadow: inset 3px 0 0 var(--feihe);
}

.nav-glyph {
  font-family: var(--mono);
  font-size: 17px;
  text-align: center;
}

.nav-count {
  min-width: 29px;
  padding: 1px 6px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  font-family: var(--mono);
  font-size: 9px;
  text-align: center;
}

.source-card {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin-top: 22px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.source-card b,
.source-card small {
  display: block;
}

.source-card b {
  color: var(--ink);
  font-size: 11px;
  font-weight: 600;
}

.source-card small {
  margin-top: 4px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 9px;
  line-height: 1.6;
}

.source-pulse {
  width: 7px;
  height: 7px;
  flex: 0 0 auto;
  margin-top: 4px;
  border-radius: 50%;
  background: var(--quality);
  box-shadow: 0 0 0 5px rgba(120, 182, 146, 0.12);
}

.workspace {
  min-height: 100vh;
  margin-left: 226px;
  padding: 32px clamp(20px, 3vw, 48px) 28px;
}

.topbar {
  display: flex;
  max-width: 1500px;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin: 0 auto 23px;
}

.eyebrow,
.section-kicker,
.panel-index {
  margin: 0;
  color: var(--evidence);
  font-family: var(--mono);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.title-block h1 {
  margin: 5px 0 3px;
  font-family: var(--display);
  font-size: clamp(25px, 2.4vw, 38px);
  line-height: 1.2;
  letter-spacing: -0.025em;
}

.title-block > p:last-child {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.top-actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 14px;
  padding-top: 6px;
}

.text-action {
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
}

.text-action:hover {
  color: var(--feihe);
}

.button {
  min-height: 38px;
  padding: 8px 14px;
  border: 1px solid transparent;
  border-radius: 7px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 650;
}

.button-secondary {
  border-color: var(--line-strong);
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}

.button-secondary:hover {
  border-color: var(--evidence);
  color: var(--evidence);
}

.button-primary {
  border-color: var(--evidence);
  background: var(--evidence);
  color: #fff;
  box-shadow: var(--shadow-soft);
}

.button-primary:hover {
  background: #27506e;
}

.filterbar {
  position: sticky;
  z-index: 30;
  top: 10px;
  display: flex;
  max-width: 1500px;
  min-height: 64px;
  align-items: center;
  gap: 10px;
  margin: 0 auto 25px;
  padding: 10px 12px;
  border: 1px solid rgba(198, 208, 213, 0.9);
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 8px 30px rgba(23, 36, 49, 0.07);
  backdrop-filter: blur(12px);
  transition: padding 160ms ease;
}

/* 滚动后收缩：只保留月份、品牌、品线与展开按钮，避免遮挡图表 */
.filterbar.is-compact {
  top: 0;
  min-height: 0;
  gap: 6px;
  padding: 5px 8px;
  box-shadow: 0 6px 22px rgba(23, 36, 49, 0.1);
}

.filterbar.is-compact .toggle-field,
.filterbar.is-compact .filter-reset {
  display: none;
}

.filterbar.is-compact .field,
.filterbar.is-compact .brand-filter summary {
  min-height: 34px;
  padding: 3px 8px;
}

.filterbar.is-compact .field > span,
.filterbar.is-compact .brand-filter summary span {
  display: none;
}

.filterbar.is-compact .field select {
  min-width: 88px;
  margin-top: 0;
}

.filterbar.is-compact .group-field {
  min-width: 104px;
}

.filterbar.is-compact .brand-filter {
  min-width: 112px;
}

.filterbar.is-compact .brand-filter summary b {
  padding-right: 16px;
}

.filterbar.is-compact .brand-filter summary::after {
  top: 50%;
  transform: translateY(-50%);
}

.filter-toggle {
  display: none;
  width: 34px;
  height: 34px;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  border: 1px solid var(--line-strong);
  border-radius: 7px;
  background: var(--surface);
  color: var(--ink-soft);
  cursor: pointer;
  font-size: 14px;
  line-height: 1;
}

.filterbar.is-compact .filter-toggle {
  display: inline-flex;
}

.filter-toggle:hover {
  border-color: var(--evidence);
  color: var(--evidence);
}

.field,
.brand-filter summary {
  display: flex;
  min-height: 42px;
  flex-direction: column;
  justify-content: center;
  padding: 5px 10px;
  border-right: 1px solid var(--line);
}

.field span,
.brand-filter summary span {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.field select {
  min-width: 112px;
  margin-top: 2px;
  padding: 0 24px 0 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
}

.compact-field select {
  min-width: 92px;
}

.group-field {
  min-width: 170px;
}

.brand-filter {
  position: relative;
  min-width: 154px;
}

.brand-filter summary {
  list-style: none;
  cursor: pointer;
}

.brand-filter summary::-webkit-details-marker {
  display: none;
}

.brand-filter summary::after {
  content: "⌄";
  position: absolute;
  top: 20px;
  right: 14px;
  color: var(--muted);
}

.brand-filter[open] summary::after {
  transform: rotate(180deg);
}

.brand-filter summary b {
  padding-right: 18px;
  font-size: 12px;
}

.brand-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  display: grid;
  width: 250px;
  gap: 4px;
  padding: 9px;
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  background: white;
  box-shadow: var(--shadow);
}

.brand-option {
  display: grid;
  grid-template-columns: 18px 10px 1fr auto;
  align-items: center;
  gap: 7px;
  padding: 7px 8px;
  border-radius: 6px;
  cursor: pointer;
}

.brand-option:hover {
  background: var(--surface-muted);
}

.brand-option input {
  accent-color: var(--feihe);
}

.brand-option-dot {
  width: 8px;
  height: 8px;
  border-radius: 2px;
}

.brand-option small {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 9px;
}

.toggle-field {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  padding: 0 7px;
  color: var(--ink-soft);
  cursor: pointer;
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
}

.toggle-field input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.toggle-track {
  position: relative;
  width: 31px;
  height: 18px;
  border-radius: 999px;
  background: var(--line-strong);
  transition: background-color 160ms ease;
}

.toggle-track::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: white;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
  transition: transform 160ms ease;
}

.toggle-field input:checked + .toggle-track {
  background: var(--feihe);
}

.toggle-field input:checked + .toggle-track::after {
  transform: translateX(13px);
}

.toggle-field input:focus-visible + .toggle-track {
  outline: 3px solid var(--evidence);
  outline-offset: 2px;
}

.filter-reset {
  padding: 8px 10px;
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-size: 11px;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.rank-section,
main,
.page-footer {
  max-width: 1500px;
  margin-right: auto;
  margin-left: auto;
}

.section-intro,
.view-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
}

.section-intro h2,
.view-heading h2 {
  margin: 2px 0 0;
  font-family: var(--display);
  font-size: 21px;
  letter-spacing: -0.015em;
}

.section-intro > p,
.view-heading > p,
.view-heading > div + p {
  max-width: 570px;
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  text-align: right;
}

.compact-intro {
  margin-bottom: 9px;
}

.exec-card {
  margin-bottom: 16px;
  padding: 20px 22px 14px;
  border: 1px solid rgba(191, 38, 56, 0.22);
  border-left: 4px solid var(--feihe);
  border-radius: var(--radius);
  background: linear-gradient(135deg, #fdf7f8, #ffffff 55%);
  box-shadow: var(--shadow-soft);
}

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

.exec-headline {
  margin: 6px 0 0;
  font-family: var(--display);
  font-size: clamp(20px, 2vw, 26px);
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.exec-context {
  flex: 0 0 auto;
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 11px;
}

.exec-ranks {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 13px;
}

.exec-rank-chip {
  padding: 4px 11px;
  border: 1px solid rgba(191, 38, 56, 0.25);
  border-radius: 999px;
  background: var(--brand-soft);
  color: #8f1d2c;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 700;
}

.exec-changes {
  display: grid;
  gap: 7px;
  margin: 13px 0 0;
  padding: 0;
  list-style: none;
}

.exec-changes li {
  position: relative;
  padding: 8px 12px 8px 34px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--surface);
  font-size: 13px;
}

/* 分组条目不带方向箭头：方向写在文字里（成本下降是改善，箭头会读反） */
.exec-changes li::before {
  content: "";
  position: absolute;
  top: 15px;
  left: 14px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--evidence);
}

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

.exec-action {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: start;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 6px;
  border-left: 3px solid var(--feihe);
  background: var(--brand-soft);
}

.exec-action b {
  padding: 2px 7px;
  border-radius: 4px;
  background: white;
  color: var(--feihe);
  font-family: var(--mono);
  font-size: 9px;
  white-space: nowrap;
}

.exec-action p {
  margin: 0;
  color: var(--ink);
  font-size: 12px;
  line-height: 1.6;
}

.exec-evidence {
  margin-top: 14px;
  border-top: 1px dashed var(--line-strong);
}

.exec-evidence > summary {
  display: flex;
  min-height: 42px;
  align-items: center;
  gap: 8px;
  color: var(--evidence);
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
}

.exec-evidence ul {
  margin: 8px 0;
  padding-left: 20px;
  color: var(--ink-soft);
  font-size: 12px;
  line-height: 1.7;
}

.exec-evidence li {
  margin-bottom: 4px;
}

.exec-evidence > p {
  margin: 8px 0 4px;
  color: var(--ink-soft);
  font-size: 12px;
}

.exec-evidence-sub {
  margin: 12px 0 4px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.rank-section {
  margin-bottom: 18px;
}

.rank-legend {
  display: inline-flex;
  gap: 10px;
  margin: 0 0 0 12px;
  color: var(--muted);
  font-size: 11px;
}

.rank-table-wrap {
  margin-top: 10px;
}

.rank-row {
  cursor: pointer;
}

.rank-row:hover {
  background: var(--info-soft);
}

.rank-row.is-self {
  background: color-mix(in srgb, var(--brand-soft) 55%, white);
}

.rank-row.is-self td:first-child {
  box-shadow: inset 3px 0 0 var(--feihe);
}

.rank-row.is-muted {
  opacity: 0.6;
}

.rank-row.is-focused {
  outline: 2px solid var(--feihe);
  outline-offset: -2px;
}

.rank-self-tag {
  margin-left: 6px;
  padding: 1px 5px;
  border-radius: 3px;
  background: var(--brand-soft);
  color: var(--feihe);
  font-size: 9px;
  font-style: normal;
  font-weight: 700;
}

.quality-entry {
  display: inline-flex;
  min-height: 38px;
  align-items: center;
  gap: 7px;
  padding: 8px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 7px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
  color: var(--ink-soft);
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
}

.quality-entry:hover {
  border-color: var(--evidence);
  color: var(--evidence);
}

.quality-entry.is-active {
  border-color: var(--feihe);
  background: var(--brand-soft);
  color: var(--feihe);
}

.quality-entry-icon {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.view {
  animation: view-enter 260ms ease both;
}

.view[hidden] {
  display: none;
}

@keyframes view-enter {
  from { opacity: 0; transform: translateY(5px); }
  to { opacity: 1; transform: translateY(0); }
}

.view-heading {
  margin-bottom: 14px;
  padding-bottom: 11px;
  border-bottom: 1px solid var(--line-strong);
}

.thesis-card {
  position: relative;
  display: grid;
  grid-template-columns: minmax(230px, 0.8fr) minmax(360px, 1.7fr);
  gap: 26px;
  margin-bottom: 14px;
  padding: 18px 21px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-left: 4px solid var(--evidence);
  border-radius: var(--radius);
  background: var(--info-soft);
  box-shadow: var(--shadow-soft);
}

.thesis-card::after {
  content: "SIGNAL";
  position: absolute;
  top: -10px;
  right: 18px;
  color: rgba(49, 94, 128, 0.045);
  font-family: var(--display);
  font-size: 66px;
  font-weight: 900;
  letter-spacing: -0.06em;
  pointer-events: none;
}

.thesis-lead {
  position: relative;
  z-index: 1;
}

.thesis-lead strong {
  display: block;
  font-family: var(--display);
  font-size: 18px;
  line-height: 1.35;
}

.thesis-lead span {
  display: inline-block;
  margin-top: 8px;
  padding: 3px 7px;
  border: 1px solid var(--evidence);
  border-radius: 4px;
  color: var(--evidence);
  font-family: var(--mono);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.thesis-body {
  position: relative;
  z-index: 1;
  margin: 0;
  color: var(--ink-soft);
  font-size: 13px;
  line-height: 1.8;
}

.thesis-body b {
  color: var(--ink);
}

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(140px, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.kpi-card {
  min-width: 0;
  padding: 14px 15px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 4px 14px rgba(23, 36, 49, 0.035);
}

.kpi-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  color: var(--muted);
  font-size: 10px;
}

.kpi-confidence {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--quality);
}

.kpi-confidence.is-partial {
  background: var(--warning);
}

.kpi-confidence.is-missing {
  background: var(--critical);
}

.kpi-value {
  margin: 7px 0 5px;
  overflow: hidden;
  font-family: var(--mono);
  font-size: clamp(19px, 1.8vw, 26px);
  font-weight: 780;
  letter-spacing: -0.055em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.kpi-value small {
  margin-left: 3px;
  color: var(--muted);
  font-family: var(--body);
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0;
}

.kpi-foot {
  display: flex;
  min-height: 32px;
  align-items: flex-end;
  justify-content: space-between;
  gap: 7px;
  color: var(--muted);
  font-size: 9px;
}

.kpi-delta {
  font-family: var(--mono);
  font-weight: 700;
}

.kpi-delta.is-up {
  color: var(--quality);
}

.kpi-delta.is-down {
  color: var(--critical);
}

.kpi-rank {
  text-align: right;
}

/* 图表单列全宽：保证品牌名、数值与图例的可读性 */
.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 14px;
  margin-bottom: 14px;
}

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

.view-heading,
.panel,
.rank-section,
.exec-card {
  scroll-margin-top: 88px;
}

.panel {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 5px 18px rgba(23, 36, 49, 0.035);
}

.panel-chart,
.alert-panel,
.timeline-panel,
.table-panel {
  padding: 16px 17px 11px;
}

.panel-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.panel-header h3 {
  margin: 2px 0 0;
  font-family: var(--display);
  font-size: 15px;
  letter-spacing: -0.01em;
}

.panel-header > p {
  max-width: 310px;
  margin: 1px 0 0;
  color: var(--muted);
  font-size: 10px;
  text-align: right;
}

.panel-index {
  color: var(--evidence);
  font-size: 8px;
}

.chart {
  width: 100%;
  height: 330px;
  margin-top: 4px;
}

.chart-large {
  height: 370px;
}

.chart-xl {
  height: 460px;
}

.chart-fallback {
  margin: 18px 0 8px;
  padding: 16px;
  border: 1px dashed var(--line-strong);
  background: var(--surface-muted);
  color: var(--muted);
  font-size: 12px;
}

.notice-card {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
  padding: 10px 13px;
  border: 1px solid #d6e1e8;
  border-left: 3px solid var(--evidence);
  border-radius: 7px;
  background: var(--info-soft);
  color: var(--ink-soft);
  font-size: 11px;
}

.notice-card b {
  color: var(--evidence);
  white-space: nowrap;
}

.segmented,
.action-filters,
.battle-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.segmented {
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--surface-muted);
}

.segmented button,
.action-filters button,
.battle-tabs button {
  border: 1px solid transparent;
  border-radius: 5px;
  background: transparent;
  cursor: pointer;
  font-size: 10px;
  font-weight: 650;
}

.segmented button {
  padding: 6px 9px;
  color: var(--muted);
}

.segmented button.is-active {
  background: var(--brand-soft);
  color: var(--feihe);
  box-shadow: 0 2px 7px rgba(23, 36, 49, 0.08);
}

.inline-field {
  min-height: auto;
  flex-direction: row;
  align-items: center;
  gap: 8px;
  padding: 0;
  border: 0;
}

.inline-field select {
  min-width: 145px;
  padding: 7px 24px 7px 9px;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  background: white;
}

.table-wrap {
  overflow-x: auto;
  margin-top: 12px;
  border: 1px solid var(--line);
  border-radius: 7px;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 11px;
}

th,
td {
  padding: 10px 11px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: middle;
}

th {
  background: var(--surface-muted);
  color: var(--muted);
  font-family: var(--mono);
  font-size: 8px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}

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

tbody tr[data-action] {
  cursor: pointer;
}

tbody tr[data-action]:hover {
  background: var(--info-soft);
}

.table-brand {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 700;
}

.table-dot {
  width: 7px;
  height: 7px;
  border-radius: 2px;
}

.metric-cell {
  font-family: var(--mono);
  font-weight: 650;
  white-space: nowrap;
}

.status-pill,
.severity-pill,
.type-pill,
.basis-pill {
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 9px;
  font-weight: 650;
  white-space: nowrap;
}

.status-complete {
  background: #eaf3ee;
  color: var(--quality);
}

.status-partial {
  background: #fbf1df;
  color: var(--warning);
}

.status-missing {
  background: #f8e7e8;
  color: var(--critical);
}

.row-action {
  border: 0;
  background: transparent;
  color: var(--evidence);
  cursor: pointer;
  font-size: 10px;
  font-weight: 700;
}

.action-filters {
  justify-content: flex-end;
}

.action-filters button {
  padding: 5px 8px;
  border-color: var(--line);
  color: var(--muted);
}

.action-filters button.is-active {
  border-color: var(--feihe);
  background: var(--brand-soft);
  color: var(--feihe);
}

.timeline {
  display: grid;
  gap: 9px;
  margin-top: 15px;
}

.timeline-row {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 12px;
  padding-bottom: 9px;
  border-bottom: 1px solid var(--line);
}

.timeline-row:last-child {
  border-bottom: 0;
}

.timeline-brand {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  padding-top: 8px;
  font-size: 11px;
  font-weight: 700;
}

.timeline-events {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 8px;
}

.action-card {
  position: relative;
  padding: 10px 11px;
  border: 1px solid var(--line);
  border-left: 3px solid var(--brand-color);
  border-radius: 6px;
  background: #fbfcfc;
  cursor: pointer;
  text-align: left;
}

.action-card:hover {
  border-color: var(--line-strong);
  background: white;
  box-shadow: var(--shadow-soft);
}

.action-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 8px;
}

.type-pill {
  min-height: 17px;
  background: var(--surface-muted);
  color: var(--ink-soft);
}

.action-card b {
  display: block;
  margin-top: 7px;
  font-size: 11px;
  line-height: 1.45;
}

.empty-state {
  padding: 32px 18px;
  color: var(--muted);
  text-align: center;
}

.battle-tabs {
  margin: 0 0 12px;
}

.battle-tabs button {
  flex: 1 1 180px;
  min-height: 52px;
  padding: 9px 12px;
  border-color: var(--line);
  background: white;
  color: var(--ink-soft);
  text-align: left;
}

.battle-tabs button span,
.battle-tabs button small {
  display: block;
}

.battle-tabs button span {
  font-size: 12px;
}

.battle-tabs button small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 9px;
  font-weight: 500;
}

.battle-tabs button.is-active {
  border-color: var(--feihe);
  background: var(--brand-soft);
  color: var(--feihe);
  box-shadow: inset 0 -2px 0 var(--feihe);
}

.battle-brief {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 20px;
  margin-bottom: 13px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.battle-brief h3,
.battle-brief p {
  margin: 0;
}

.battle-brief h3 {
  font-family: var(--display);
  font-size: 16px;
}

.battle-brief p {
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
}

.basis-pill {
  border: 1px solid #d5e0e6;
  background: #f4f8fa;
  color: var(--evidence);
}

.basis-pill.is-derived {
  border-color: var(--gold);
  background: var(--gold-soft);
  color: var(--gold-ink);
}

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

.strategy-card {
  position: relative;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-top: 4px solid var(--brand-color);
  border-radius: 8px;
  background: white;
  box-shadow: var(--shadow-soft);
}

.strategy-card.is-self {
  border-color: rgba(201, 45, 51, 0.45);
  border-top-color: var(--feihe);
}

.strategy-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 14px 15px 11px;
  border-bottom: 1px solid var(--line);
}

.strategy-card-head h3 {
  margin: 0;
  font-family: var(--display);
  font-size: 16px;
}

.strategy-brand {
  color: var(--muted);
  font-size: 10px;
}

.strategy-metric {
  text-align: right;
}

.strategy-metric b,
.strategy-metric small {
  display: block;
}

.strategy-metric b {
  font-family: var(--mono);
  font-size: 14px;
}

.strategy-metric small {
  color: var(--ink-soft);
  font-size: 10px;
}

.strategy-body {
  display: grid;
  gap: 12px;
  padding: 13px 15px 15px;
}

.strategy-fact span {
  display: block;
  margin-bottom: 3px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.strategy-fact p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 11px;
  line-height: 1.65;
}

.strategy-fact.is-proposition p {
  color: var(--ink);
  font-family: var(--display);
  font-size: 14px;
  font-weight: 700;
}

.strategy-evidence {
  padding-top: 8px;
  border-top: 1px dashed var(--line);
  color: var(--ink-soft);
  font-size: 10px;
  line-height: 1.5;
}

.strategy-metric.is-multi b {
  color: var(--warning);
  font-size: 12px;
}

/* 品线搜索按词分列：单词品线与多词品线不合并成一个可比数字 */
.strategy-search span,
.strategy-verify span {
  display: block;
  margin-bottom: 4px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.strategy-search ul {
  display: grid;
  margin: 0;
  padding: 0;
  gap: 3px;
  list-style: none;
}

.strategy-search li {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  padding: 3px 7px;
  border-radius: 4px;
  background: var(--surface-muted);
  font-size: 10px;
}

.strategy-search li i {
  color: var(--ink-soft);
  font-style: normal;
}

.strategy-search li b {
  font-family: var(--mono);
  font-size: 11px;
}

.strategy-search small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 8px;
}

.strategy-verify dl {
  display: grid;
  margin: 0;
  gap: 3px;
}

.strategy-verify dl > div {
  display: grid;
  grid-template-columns: 62px 1fr;
  gap: 8px;
  padding: 4px 7px;
  border-left: 2px solid var(--line-strong);
  border-radius: 0 4px 4px 0;
  background: var(--surface-muted);
}

.strategy-verify dl > div.is-pending {
  border-left-color: var(--warning);
  background: var(--warning-soft);
}

.strategy-verify dl > div.is-filled {
  border-left-color: var(--quality);
  background: var(--success-soft);
}

.strategy-verify dt {
  color: var(--muted);
  font-size: 9px;
}

.strategy-verify dd {
  margin: 0;
  color: var(--ink-soft);
  font-size: 9px;
  line-height: 1.55;
}

/* 数据信任提示条：一行说清当月缺口与受影响分析，明细收进展开区 */
.trust-strip {
  margin-bottom: 12px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-left: 3px solid var(--evidence);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}

.trust-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.trust-tag {
  flex: 0 0 auto;
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--info-soft);
  color: var(--evidence);
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 700;
}

.trust-tag.is-warn {
  background: var(--warning-soft);
  color: var(--warning);
}

.trust-headline {
  flex: 1 1 320px;
  margin: 0;
  color: var(--ink);
  font-size: 12px;
  line-height: 1.6;
}

.trust-link {
  flex: 0 0 auto;
  padding: 0;
  border: 0;
  background: none;
  color: var(--evidence);
  cursor: pointer;
  font-size: 11px;
}

.trust-details {
  margin-top: 6px;
}

.trust-details > summary {
  color: var(--muted);
  cursor: pointer;
  font-size: 11px;
  min-height: 28px;
  padding: 4px 0;
}

.trust-details dl {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 4px 0 2px;
}

.trust-details dl > div {
  padding: 8px 10px;
  border-left: 2px solid var(--line-strong);
  border-radius: 0 5px 5px 0;
  background: var(--surface-muted);
}

.trust-details dt {
  color: var(--muted);
  font-size: 10px;
}

.trust-details dd {
  margin: 2px 0 0;
}

.trust-details dd b {
  display: block;
  font-family: var(--mono);
  font-size: 14px;
}

.trust-details dd small {
  display: block;
  margin-top: 2px;
  color: var(--ink-soft);
  font-size: 10px;
  line-height: 1.5;
}

/* 排名与异常状态：用文字说明排除原因，不只靠颜色 */
.rank-dash {
  color: var(--muted);
}

.rank-exclude {
  display: block;
  margin-top: 3px;
  color: var(--warning);
  font-size: 9px;
  line-height: 1.4;
}

.metric-flag {
  display: inline-block;
  margin-left: 4px;
  padding: 1px 5px;
  border-radius: 4px;
  background: var(--danger-soft);
  color: var(--critical);
  font-size: 9px;
  font-style: normal;
}

.kpi-flag {
  margin: 5px 0 0;
  color: var(--warning);
  font-size: 9px;
  line-height: 1.45;
}

.issue-status {
  display: inline-block;
  padding: 2px 7px;
  border-radius: 4px;
  background: var(--surface-muted);
  color: var(--ink-soft);
  font-size: 10px;
  white-space: nowrap;
}

.issue-status-unverified {
  background: var(--danger-soft);
  color: var(--critical);
}

.issue-status-recomputed,
.issue-status-handled {
  background: var(--success-soft);
  color: var(--quality);
}

.issue-status-source,
.issue-status-documented {
  background: var(--warning-soft);
  color: var(--warning);
}

.issue-status + small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 9px;
  line-height: 1.45;
}

/* 最小行动闭环：证据到复盘一张卡说完 */
.todo-panel {
  margin-bottom: 14px;
  padding: 15px 18px 16px;
}

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

.todo-card {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 8px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-left: 3px solid var(--feihe);
  border-radius: 7px;
  background: var(--surface);
}

.todo-card header {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.todo-card h4 {
  margin: 0;
  font-size: 13px;
  line-height: 1.55;
}

.todo-status {
  flex: 0 0 auto;
  padding: 2px 7px;
  border-radius: 4px;
  background: var(--surface-muted);
  color: var(--ink-soft);
  font-size: 10px;
  white-space: nowrap;
}

.todo-status-1 { background: var(--info-soft); color: var(--evidence); }
.todo-status-2 { background: var(--success-soft); color: var(--quality); }
.todo-status-3 { background: var(--warning-soft); color: var(--warning); }

.todo-scope {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin: 0;
  color: var(--muted);
  font-size: 10px;
}

.todo-month {
  padding: 2px 7px;
  border-radius: 4px;
  background: var(--info-soft);
  color: var(--evidence);
  font-family: var(--mono);
}

.todo-month.is-history {
  background: var(--warning-soft);
  color: var(--warning);
}

.todo-problem {
  margin: 0;
  color: var(--ink-soft);
  font-size: 11px;
  line-height: 1.6;
}

.todo-checks {
  margin: 0;
  padding-left: 18px;
  color: var(--ink-soft);
  font-size: 11px;
  line-height: 1.6;
}

.todo-detail > summary {
  color: var(--evidence);
  cursor: pointer;
  font-size: 11px;
  min-height: 30px;
  padding: 4px 0;
}

.todo-more {
  grid-column: 1 / -1;
}

.todo-more > summary {
  padding: 8px 0 4px;
  color: var(--muted);
  cursor: pointer;
  font-size: 11px;
}

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

.todo-facts {
  display: grid;
  margin: 0;
  gap: 4px;
}

.todo-facts > div {
  display: grid;
  grid-template-columns: 66px 1fr;
  gap: 8px;
}

.todo-facts dt {
  color: var(--muted);
  font-size: 10px;
}

.todo-facts dd {
  margin: 0;
  color: var(--ink-soft);
  font-size: 11px;
  line-height: 1.55;
}

.todo-inputs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 7px;
  padding-top: 8px;
  border-top: 1px dashed var(--line);
}

.todo-inputs label {
  display: grid;
  gap: 3px;
}

.todo-inputs label span {
  color: var(--muted);
  font-size: 10px;
}

.todo-inputs input,
.todo-inputs select {
  min-height: 32px;
  padding: 4px 7px;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  background: var(--surface);
  color: var(--ink);
  font-size: 11px;
}

.todo-review {
  grid-column: 1 / -1;
}

.todo-storage-note {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.55;
}

/* 品线资料缺口：合并成一块紧凑区域，不逐行重复“待指定” */
.strategy-gap {
  padding: 7px 9px;
  border-left: 2px solid var(--warning);
  border-radius: 0 5px 5px 0;
  background: var(--warning-soft);
}

.strategy-gap b {
  display: block;
  margin-bottom: 3px;
  color: var(--warning);
  font-size: 10px;
}

.strategy-gap ul {
  display: grid;
  margin: 0;
  padding: 0;
  gap: 2px;
  list-style: none;
}

.strategy-gap li {
  display: grid;
  grid-template-columns: 68px 1fr;
  gap: 6px;
  color: var(--ink-soft);
  font-size: 10px;
  line-height: 1.5;
}

.strategy-gap li i {
  color: var(--warning);
  font-style: normal;
}

.strategy-gap small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 9px;
  line-height: 1.5;
}

/* 当月缺失的指标降级呈现，不与当月已填指标同权重 */
.kpi-card.is-pending {
  border-style: dashed;
  border-color: var(--warning);
  background: var(--warning-soft);
  box-shadow: none;
}

.kpi-card.is-pending .kpi-foot {
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
}

.kpi-card.is-pending .kpi-rank {
  text-align: left;
}

.kpi-card.is-pending .kpi-value {
  color: var(--warning);
  font-family: var(--body);
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0;
}

.exec-limits {
  display: grid;
  margin: 12px 0 0;
  padding: 9px 12px;
  gap: 4px;
  border-radius: 6px;
  background: var(--surface-muted);
  color: var(--muted);
  font-size: 10px;
  line-height: 1.6;
  list-style: none;
}

.quality-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(150px, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.quality-stat {
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}

.quality-stat span,
.quality-stat small,
.quality-stat b {
  display: block;
}

.quality-stat span {
  color: var(--muted);
  font-size: 9px;
}

.quality-stat b {
  margin-top: 6px;
  font-family: var(--mono);
  font-size: 25px;
  letter-spacing: -0.05em;
}

.quality-stat small {
  margin-top: 2px;
  color: var(--ink-soft);
  font-size: 9px;
}

.quality-stat.is-critical b {
  color: var(--critical);
}

.health-matrix {
  overflow-x: auto;
  padding: 14px 16px 16px;
}

.health-grid {
  display: grid;
  min-width: 650px;
  grid-template-columns: 90px repeat(8, minmax(54px, 1fr)) 58px;
  gap: 4px;
  align-items: stretch;
}

.health-cell {
  display: grid;
  min-height: 31px;
  place-items: center;
  padding: 4px;
  border-radius: 4px;
  font-size: 8px;
  text-align: center;
}

.health-head {
  color: var(--muted);
  font-family: var(--mono);
  font-weight: 700;
}

.health-brand {
  justify-content: start;
  font-size: 10px;
  font-weight: 700;
}

.health-complete {
  background: #dcebe3;
  color: var(--quality);
}

.health-partial {
  background: #f7e9cd;
  color: var(--warning);
}

.health-missing {
  background: #f4dadd;
  color: var(--critical);
}

.health-score {
  border: 1px solid var(--line);
  background: var(--surface-muted);
  color: var(--ink);
  font-family: var(--mono);
  font-weight: 700;
}

.severity-critical {
  background: #f4dadd;
  color: var(--critical);
}

.severity-high {
  background: #fae9d3;
  color: var(--warning);
}

.severity-medium {
  background: #e8eef4;
  color: var(--evidence);
}

.alert-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 9px;
  margin-top: 13px;
}

.alert-card {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 9px;
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fbfcfc;
}

.alert-icon {
  display: grid;
  width: 27px;
  height: 27px;
  place-items: center;
  border-radius: 50%;
  background: var(--surface-muted);
  color: var(--evidence);
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 800;
}

.alert-card.is-risk .alert-icon {
  background: #f8e4e5;
  color: var(--critical);
}

.alert-card.is-opportunity .alert-icon {
  background: #e1eee7;
  color: var(--quality);
}

.alert-card b,
.alert-card p {
  margin: 0;
}

.alert-card b {
  font-size: 11px;
}

.alert-card p {
  margin-top: 3px;
  color: var(--muted);
  font-size: 9px;
  line-height: 1.55;
}

.page-footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-top: 22px;
  padding-top: 14px;
  border-top: 1px solid var(--line-strong);
  color: var(--muted);
  font-family: var(--mono);
  font-size: 8px;
}

.drawer-backdrop {
  position: fixed;
  z-index: 79;
  inset: 0;
  background: rgba(13, 23, 31, 0.38);
  backdrop-filter: blur(2px);
}

.detail-drawer {
  position: fixed;
  z-index: 80;
  inset: 0 0 0 auto;
  width: min(470px, 92vw);
  padding: 30px 28px;
  overflow-y: auto;
  border-left: 1px solid var(--line-strong);
  background: white;
  box-shadow: -24px 0 60px rgba(13, 23, 31, 0.18);
  transform: translateX(102%);
  transition: transform 220ms ease;
}

.detail-drawer.is-open {
  transform: translateX(0);
}

.detail-drawer h2 {
  margin: 5px 36px 18px 0;
  font-family: var(--display);
  font-size: 24px;
  line-height: 1.3;
}

.drawer-close {
  position: absolute;
  top: 18px;
  right: 18px;
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: white;
  cursor: pointer;
  font-size: 20px;
}

.drawer-section {
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.drawer-section h3 {
  margin: 0 0 8px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: 0.1em;
}

.drawer-section p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 12px;
  line-height: 1.75;
}

.drawer-metrics {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.drawer-metric {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface-muted);
}

.drawer-metric span,
.drawer-metric b {
  display: block;
}

.drawer-metric span {
  color: var(--muted);
  font-size: 9px;
}

.drawer-metric b {
  margin-top: 3px;
  font-family: var(--mono);
  font-size: 16px;
}

.drawer-action-list {
  display: grid;
  gap: 7px;
}

.drawer-action-item {
  padding: 9px 10px;
  border-left: 3px solid var(--evidence);
  background: var(--info-soft);
}

.drawer-action-item b,
.drawer-action-item p {
  display: block;
  margin: 0;
}

.drawer-action-item p {
  margin-top: 3px;
  font-size: 10px;
}

.toast {
  position: fixed;
  z-index: 120;
  right: 24px;
  bottom: 24px;
  max-width: 340px;
  padding: 11px 14px;
  border-radius: 7px;
  background: var(--ink);
  color: white;
  box-shadow: var(--shadow);
  font-size: 11px;
}

.noscript {
  position: fixed;
  z-index: 150;
  inset: auto 20px 20px;
  padding: 12px;
  background: #fff3d9;
  color: #684413;
}

@media (max-width: 1280px) {
  .kpi-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .todo-grid,
  .todo-grid-inner {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 1050px) {
  .alert-list {
    grid-template-columns: repeat(2, 1fr);
  }

  .filterbar {
    flex-wrap: wrap;
  }

  .toggle-field {
    margin-left: 0;
  }
}

@media (max-width: 860px) {
  .sidebar {
    position: sticky;
    top: 0;
    width: 100%;
    height: auto;
    flex-direction: row;
    align-items: center;
    overflow: visible;
    padding: 9px 12px;
  }

  .brand-lockup {
    flex: 0 0 auto;
    padding: 0 8px 0 0;
  }

  .brand-mark {
    width: 32px;
    height: 32px;
    font-size: 16px;
  }

  .brand-copy small,
  .source-card,
  .nav-label,
  .nav-item span:not(.nav-glyph),
  .nav-count {
    display: none;
  }

  .brand-copy b {
    font-size: 13px;
  }

  .primary-nav {
    display: flex;
    min-width: 0;
    flex-direction: row;
    justify-content: flex-end;
    gap: 3px;
  }

  .nav-item {
    display: grid;
    width: 38px;
    height: 38px;
    grid-template-columns: 1fr;
    place-items: center;
    padding: 0;
  }

  .workspace {
    margin-left: 0;
    padding: 24px 16px;
  }

  .topbar {
    margin-bottom: 17px;
  }

  .filterbar {
    position: static;
  }
}

@media (max-width: 680px) {
  .workspace {
    padding: 18px 11px;
  }

  .topbar,
  .section-intro,
  .view-heading,
  .panel-header,
  .page-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .top-actions {
    width: 100%;
    justify-content: space-between;
  }

  .filterbar {
    align-items: stretch;
  }

  .field,
  .brand-filter {
    min-width: calc(50% - 6px);
    flex: 1 1 calc(50% - 6px);
  }

  .field,
  .brand-filter summary {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .toggle-field {
    flex: 1 1 auto;
  }

  .brand-menu {
    position: fixed;
    z-index: 70;
    inset: auto 10px 12px;
    width: auto;
    max-height: 65vh;
    overflow-y: auto;
  }

  .thesis-card {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .exec-actions {
    grid-template-columns: 1fr;
  }

  .exec-head {
    flex-direction: column;
    gap: 2px;
  }

  .kpi-grid,
  .quality-stats,
  .strategy-grid,
  .alert-list {
    grid-template-columns: 1fr 1fr;
  }

  .todo-grid,
  .todo-grid-inner,
  .trust-details dl {
    grid-template-columns: 1fr;
  }

  .panel-header > p,
  .section-intro > p,
  .view-heading > p,
  .view-heading > div + p {
    max-width: none;
    text-align: left;
  }

  .chart,
  .chart-large {
    height: 320px;
  }

  .chart-xl {
    height: 420px;
  }

  .timeline-row {
    grid-template-columns: 1fr;
  }

  .timeline-brand {
    padding-top: 0;
  }
}

@media (max-width: 460px) {
  .brand-copy {
    display: none;
  }

  .primary-nav {
    justify-content: space-between;
  }

  .nav-item {
    width: 35px;
  }

  .kpi-grid,
  .quality-stats,
  .strategy-grid,
  .alert-list,
  .todo-inputs {
    grid-template-columns: 1fr;
  }

  .panel-chart,
  .alert-panel,
  .timeline-panel,
  .table-panel {
    padding: 13px 12px 8px;
  }

  .field,
  .brand-filter {
    min-width: 100%;
    flex-basis: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

@media print {
  body {
    background: white;
  }

  .sidebar,
  .filterbar,
  .top-actions,
  .drawer-backdrop,
  .detail-drawer,
  .toast {
    display: none !important;
  }

  .workspace {
    margin: 0;
    padding: 12px;
  }

  .view[hidden] {
    display: none !important;
  }

  .panel,
  .kpi-card,
  .thesis-card {
    break-inside: avoid;
    box-shadow: none;
  }
}

/* 研判分层：结论、要点、证据、限制、建议 */
.insight-points {
  margin: 6px 0 0;
  padding-left: 18px;
  color: var(--ink-soft);
  font-size: 12px;
  line-height: 1.6;
}

.insight-label {
  margin: 10px 0 4px;
  color: var(--evidence);
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
}

.insight-limits {
  color: var(--muted);
}
