:root {
  --bg: #0b1020;
  --panel: #172033;
  --panel-2: #1f2a44;
  --line: rgba(148, 163, 184, .18);
  --text: #eef2ff;
  --muted: #94a3b8;
  --blue: #6d8dff;
  --green: #22c55e;
  --red: #ef4444;
  --amber: #f59e0b;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  background: radial-gradient(circle at 15% 10%, rgba(109, 141, 255, .22), transparent 28%),
    radial-gradient(circle at 85% 18%, rgba(245, 158, 11, .12), transparent 24%),
    var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}
body.sheet-open { overflow: hidden; }
a { color: inherit; }
.page-grid {
  position: fixed;
  inset: 0;
  background-image: radial-gradient(rgba(148, 163, 184, .12) 1px, transparent 1px);
  background-size: 36px 36px;
  pointer-events: none;
}
.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 68px;
  padding: 12px clamp(18px, 4vw, 46px);
  border-bottom: 1px solid var(--line);
  background: rgba(11, 16, 32, .78);
  backdrop-filter: blur(18px);
}
.topnav {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-left: auto;
}
.topnav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
}
.topnav a:not(.topnav-primary):not(.topnav-muted) {
  opacity: .78;
}
.topnav a:hover { color: var(--text); }
.topnav a.topnav-primary {
  color: var(--text);
  font-weight: 900;
  padding: 4px 0;
  border-bottom: 2px solid rgba(109, 141, 255, .8);
}
.topnav a.topnav-primary:hover {
  color: var(--text);
}
.topnav a.topnav-muted {
  margin-left: 4px;
  padding-left: 14px;
  border-left: 1px solid rgba(148, 163, 184, .18);
  color: rgba(148, 163, 184, .72);
  font-weight: 700;
}
.topnav a.topnav-muted:hover {
  color: var(--text);
}
.brand-mark {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #6d8dff, #8b5cf6);
  font-weight: 800;
}
.topbar strong { display: block; font-size: 17px; }
.topbar span, .topbar-status { color: var(--muted); font-size: 13px; }
.topbar-status { margin-left: auto; }
.admin-link {
  margin-left: 6px;
  text-decoration: none;
  border: 1px solid var(--line);
  color: var(--muted);
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 13px;
}
.admin-auth-gate {
  min-height: calc(100vh - 160px);
  display: grid;
  place-items: center;
}
.admin-login-panel {
  width: min(720px, 100%);
  border: 1px solid rgba(109, 141, 255, .28);
  background: rgba(23, 32, 51, .84);
}
.admin-login-panel .input + .input {
  margin-top: 10px;
}
.admin-token-details {
  margin-top: 18px;
  border-top: 1px solid var(--line);
  padding-top: 14px;
  color: var(--muted);
}
.admin-token-details summary {
  cursor: pointer;
  color: rgba(148, 163, 184, .82);
  font-weight: 800;
}
.admin-token-details p {
  margin: 10px 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}
.back-link {
  text-decoration: none;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
}
.shell {
  position: relative;
  width: min(1480px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 80px;
}
.query-console {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(23, 32, 51, .78);
  box-shadow: 0 24px 70px rgba(0, 0, 0, .22);
  padding: 22px;
}
.query-console .lead {
  display: none;
}
.console-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
}
.console-head h1 {
  max-width: none;
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.18;
  color: rgba(238, 242, 255, .9);
}
.console-stats {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}
.console-stats span {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  font-size: 12px;
}
.console-stats strong { color: var(--text); font-size: 13px; }
.search-guide {
  margin: 18px 0 0;
  display: block;
  color: var(--text);
  font-size: clamp(20px, 3.2vw, 32px);
  line-height: 1.28;
  font-weight: 950;
}
.query-console .primary-query {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px;
  align-items: stretch;
}
.query-console .primary-query .input {
  height: 58px;
  font-size: 18px;
}
.query-console .primary-query button {
  height: 58px;
  font-size: 17px;
  font-weight: 900;
}
.app-search-bar {
  margin-bottom: 18px;
  padding: 18px;
  border: 1px solid rgba(109, 141, 255, .28);
  border-radius: 8px;
  background: rgba(15, 23, 42, .6);
}
.app-search-bar label {
  display: block;
  color: var(--text);
  font-size: 15px;
  font-weight: 900;
}
.app-search-bar p {
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}
.app-search-bar .primary-query { margin-top: 12px; }
.primary-query { margin-top: 18px; }
.primary-query .input { height: 52px; font-size: 16px; }
.primary-query button { min-width: 132px; }
.search-inline { margin-top: 14px; }
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 24px;
  align-items: stretch;
}
.kicker {
  margin: 0 0 10px;
  color: var(--blue);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
}
h1, h2, p { margin: 0; }
h1 {
  max-width: 780px;
  font-size: clamp(40px, 6vw, 78px);
  line-height: 1.05;
  letter-spacing: 0;
}
.lead {
  max-width: 760px;
  margin-top: 18px;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.8;
}
.hero-card, .panel, .detail-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(23, 32, 51, .82);
  box-shadow: 0 24px 70px rgba(0, 0, 0, .24);
}
.hero-card {
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.hero-card span { color: var(--amber); font-size: 13px; font-weight: 800; }
.hero-card strong { display: block; margin: 10px 0; font-size: 24px; line-height: 1.25; }
.hero-card p, .panel p { color: var(--muted); line-height: 1.7; }
.status-band {
  margin-top: 28px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: rgba(23, 32, 51, .72);
}
.status-band div { padding: 18px 22px; border-right: 1px solid var(--line); }
.status-band div:last-child { border-right: none; }
.status-band span { display: block; color: var(--muted); font-size: 13px; }
.status-band strong { display: block; margin-top: 8px; font-size: 20px; }
.tool-grid { margin-top: 28px; display: grid; grid-template-columns: 1fr 1.2fr; gap: 18px; }
.panel { padding: 22px; }
.panel h2 { font-size: 21px; margin-bottom: 8px; }
.auth-shell { width: min(780px, calc(100% - 32px)); }
.auth-panel h1 { font-size: clamp(30px, 5vw, 52px); }
.auth-grid {
  display: grid;
  gap: 12px;
  margin-top: 20px;
}
.auth-box {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  background: rgba(8, 13, 28, .34);
}
.auth-box h2 {
  margin: 0 0 6px;
  font-size: 18px;
}
.auth-box p {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}
.reset-box {
  border-color: rgba(109, 141, 255, .28);
}
.check-line {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}
.progress-action {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  padding: 0 14px;
  font-weight: 800;
}
.accent-panel { border-color: rgba(109, 141, 255, .38); }
.query-row { display: flex; gap: 10px; margin-top: 16px; }
.auth-divider {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 13px;
}
.input {
  width: 100%;
  height: 46px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(8, 13, 28, .72);
  color: var(--text);
  outline: none;
  padding: 0 14px;
  font-size: 15px;
}
.input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(109, 141, 255, .12); }
.compact-input {
  width: min(220px, 100%);
}
.compact-number {
  width: 92px;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(8, 13, 28, .72);
  color: var(--text);
  padding: 0 10px;
}
.quota-hint {
  margin-top: 10px;
  color: var(--muted);
  font-size: 13px;
}
.quota-hint a {
  color: var(--blue);
  font-weight: 700;
  margin-left: 4px;
}
button {
  border: none;
  border-radius: 8px;
  background: linear-gradient(135deg, #6d8dff, #6952e8);
  color: white;
  font-weight: 700;
  padding: 0 22px;
  cursor: pointer;
  white-space: nowrap;
}
button.link-button {
  width: fit-content;
  height: auto;
  margin-top: 12px;
  padding: 0;
  background: transparent;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}
button.link-button:hover { color: var(--text); }
.feedback { min-height: 22px; margin-top: 12px; color: var(--green); font-size: 14px; }
.task-progress {
  margin-top: 16px;
  padding: 14px;
  border: 1px solid rgba(109, 141, 255, .34);
  border-radius: 8px;
  background: rgba(8, 13, 28, .42);
  color: var(--text);
}
.task-progress.done { border-color: rgba(34,197,94,.42); }
.task-progress.failed { border-color: rgba(239,68,68,.55); }
.progress-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}
.progress-head strong { font-size: 15px; }
.progress-head span {
  color: var(--muted);
  font-size: 12px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}
.progress-bar {
  height: 8px;
  margin-top: 12px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(148, 163, 184, .18);
}
.progress-bar i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #6d8dff, #22c55e);
  transition: width .35s ease;
}
.task-progress.failed .progress-bar i { background: linear-gradient(90deg, #f59e0b, #ef4444); }
.progress-steps {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  margin-top: 10px;
}
.progress-steps span {
  position: relative;
  padding-top: 12px;
  color: var(--muted);
  font-size: 12px;
  text-align: center;
}
.progress-steps span::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  transform: translateX(-50%);
  background: rgba(148, 163, 184, .4);
}
.progress-steps span.active { color: var(--text); }
.progress-steps span.active::before { background: var(--green); box-shadow: 0 0 0 4px rgba(34,197,94,.12); }
.task-progress p {
  margin-top: 10px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}
.progress-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  margin-top: 10px;
  padding: 0 12px;
  border-radius: 8px;
  background: rgba(34,197,94,.16);
  color: var(--green);
  text-decoration: none;
  font-size: 13px;
  font-weight: 800;
}
.section-head {
  margin-top: 42px;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
}
.section-head h2 { font-size: 30px; }
.legend { color: var(--muted); font-size: 13px; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--amber); margin-right: 6px; }
.report-grid {
  margin-top: 18px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}
.report-card {
  position: relative;
  display: block;
  min-height: 350px;
  padding: 20px 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  text-decoration: none;
  transition: transform .2s, border-color .2s, background .2s;
}
.alert-corner {
  position: absolute;
  top: 12px;
  right: 12px;
  display: inline-flex;
  gap: 6px;
  align-items: center;
  z-index: 2;
}
.alert-chip,
.state-chip,
.new-chip {
  min-height: 22px;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 0 8px;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .02em;
}
.state-chip {
  border: 1px solid rgba(148, 163, 184, .22);
  background: rgba(148, 163, 184, .14);
  color: var(--muted);
}
.state-chip.stronger {
  border-color: rgba(34, 197, 94, .5);
  background: rgba(34, 197, 94, .16);
  color: var(--green);
}
.state-chip.weaker,
.state-chip.changed {
  border-color: rgba(245, 158, 11, .5);
  background: rgba(245, 158, 11, .16);
  color: var(--amber);
}
.state-chip.invalidated {
  border-color: rgba(239, 68, 68, .58);
  background: rgba(239, 68, 68, .18);
  color: var(--red);
}
.alert-chip {
  border: 1px solid rgba(148, 163, 184, .2);
  background: rgba(148, 163, 184, .12);
  color: var(--muted);
}
.alert-chip.p0 {
  border-color: rgba(239, 68, 68, .56);
  background: rgba(239, 68, 68, .18);
  color: var(--red);
}
.alert-chip.p1 {
  border-color: rgba(245, 158, 11, .5);
  background: rgba(245, 158, 11, .16);
  color: var(--amber);
}
.new-chip {
  background: rgba(109, 141, 255, .18);
  color: var(--blue);
}
.report-card:hover { transform: translateY(-3px); border-color: rgba(109, 141, 255, .42); background: var(--panel-2); }
.sample-card {
  min-height: 270px;
}
.sample-card .quote-price strong {
  font-size: 20px;
}
.sample-body {
  margin-top: 14px;
  color: var(--muted);
  line-height: 1.7;
}
.sample-generate {
  width: 100%;
  height: 42px;
  margin-top: 16px;
}
.report-card.amber { border-color: rgba(245, 158, 11, .56); }
.report-card.red { border-color: rgba(239, 68, 68, .68); }
.quote-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}
.code { color: var(--blue); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 13px; }
.quote-head .code {
  display: inline-flex;
  min-height: 26px;
  align-items: center;
  padding: 0 9px;
  border-radius: 6px;
  background: rgba(109, 141, 255, .14);
  margin-top: 8px;
}
.badge { padding: 5px 8px; border-radius: 8px; font-size: 12px; font-weight: 800; background: rgba(34,197,94,.16); color: var(--green); }
.badge.amber { background: rgba(245,158,11,.16); color: var(--amber); }
.badge.red { background: rgba(239,68,68,.16); color: var(--red); }
.report-card h3 { margin: 0; font-size: 22px; }
.quote-price {
  text-align: right;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}
.quote-price strong {
  display: block;
  font-size: 28px;
  line-height: 1;
}
.quote-price span {
  display: block;
  margin-top: 8px;
  font-size: 15px;
  font-weight: 800;
}
.rise { color: var(--red); }
.fall { color: var(--green); }
.summary { color: var(--muted); line-height: 1.65; min-height: 78px; }
.thesis {
  margin-top: 10px;
  color: var(--blue);
  font-size: 13px;
  font-weight: 700;
}
.decision-line {
  margin-top: 12px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  padding: 10px;
  border-radius: 8px;
  background: rgba(8, 13, 28, .38);
}
.decision-line strong {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
}
.decision-line span { color: var(--muted); font-size: 12px; text-align: right; }
.decision-line.red strong { color: var(--red); }
.decision-line.amber strong { color: var(--amber); }
.decision-line.green strong { color: var(--green); }
.state-callout {
  margin-top: 12px;
  min-height: 46px;
  display: grid;
  grid-template-columns: 68px 1fr;
  align-items: center;
  gap: 10px;
  border: 1px solid rgba(148, 163, 184, .16);
  border-radius: 8px;
  padding: 10px 12px;
  background: rgba(8, 13, 28, .38);
}
.state-callout strong {
  font-size: 15px;
}
.state-callout span {
  color: var(--muted);
  font-size: 12px;
  text-align: right;
}
.state-callout.stronger { border-color: rgba(34, 197, 94, .38); }
.state-callout.stronger strong { color: var(--green); }
.state-callout.weaker,
.state-callout.changed { border-color: rgba(245, 158, 11, .45); }
.state-callout.weaker strong,
.state-callout.changed strong { color: var(--amber); }
.state-callout.invalidated { border-color: rgba(239, 68, 68, .52); }
.state-callout.invalidated strong { color: var(--red); }
.tip-button {
  position: relative;
  width: 18px;
  height: 18px;
  min-width: 18px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  border: 1px solid rgba(148, 163, 184, .35);
  border-radius: 50%;
  background: rgba(15, 23, 42, .72);
  color: var(--muted);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
  cursor: help;
  z-index: 6;
}
.with-help {
  display: flex;
  align-items: center;
  gap: 8px;
}
.with-help .tip-button {
  margin-top: 2px;
}
.tip-button:hover,
.tip-button:focus,
.tip-button[aria-expanded="true"] {
  border-color: rgba(109, 141, 255, .72);
  color: var(--text);
  outline: none;
}
.tip-button:focus-visible {
  box-shadow: 0 0 0 3px rgba(109, 141, 255, .28);
}
.tip-popover {
  position: absolute;
  right: 0;
  top: 26px;
  width: min(300px, 72vw);
  padding: 10px 12px;
  border: 1px solid rgba(109, 141, 255, .42);
  border-radius: 8px;
  background: #101827;
  color: var(--text);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.6;
  text-align: left;
  white-space: normal;
  box-shadow: 0 16px 40px rgba(0, 0, 0, .36);
  z-index: 80;
  cursor: default;
  pointer-events: auto;
}
.tip-popover[hidden] {
  display: none;
}
.tip-popover strong,
.tip-popover span {
  display: block;
}
.tip-popover strong {
  margin-bottom: 6px;
  color: var(--text);
}
.tip-popover span {
  color: var(--muted);
}
.scan-metrics {
  margin-top: 14px;
  display: grid;
  gap: 0;
}
.scan-metrics p {
  min-height: 34px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid rgba(148, 163, 184, .10);
  color: var(--muted);
}
.scan-metrics p:last-child { border-bottom: none; }
.scan-metrics strong {
  color: var(--text);
  font-size: 14px;
  text-align: right;
}
.scan-metrics strong.hot { color: var(--red); }
.radar-strip {
  margin-top: 12px;
  padding: 10px;
  border: 1px solid rgba(148, 163, 184, .18);
  border-radius: 8px;
  background: rgba(8, 13, 28, .38);
}
.radar-strip strong {
  display: block;
  font-size: 13px;
}
.radar-strip span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}
.radar-strip.green { border-color: rgba(34,197,94,.38); }
.radar-strip.amber { border-color: rgba(245,158,11,.45); }
.radar-strip.red { border-color: rgba(239,68,68,.52); }
.tag-row {
  min-height: 27px;
  margin-top: 10px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.tag-row em,
.radar-groups em,
.signal-footer em {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  background: rgba(109, 141, 255, .12);
  color: #b9c6ff;
  font-style: normal;
  font-size: 12px;
  line-height: 1;
}
.signal-footer {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid rgba(239, 68, 68, .24);
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.watch-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}
.watch-meta span {
  min-height: 26px;
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 9px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}
.attention-line {
  margin-top: 14px;
  min-height: 42px;
  display: grid;
  grid-template-columns: minmax(96px, auto) 1fr;
  align-items: center;
  gap: 12px;
  border: 1px solid rgba(148, 163, 184, .16);
  border-radius: 8px;
  padding: 10px 12px;
  background: rgba(15, 23, 42, .42);
}
.attention-line strong {
  font-size: 14px;
  color: var(--text);
}
.attention-line span {
  color: var(--muted);
  font-size: 12px;
  text-align: right;
}
.attention-line.red {
  border-color: rgba(239, 68, 68, .48);
  background: rgba(127, 29, 29, .16);
}
.attention-line.red strong { color: var(--red); }
.attention-line.amber {
  border-color: rgba(245, 158, 11, .42);
  background: rgba(120, 53, 15, .14);
}
.attention-line.amber strong { color: var(--amber); }
.attention-line.green strong { color: var(--green); }
.signal-footer.quiet { border-top-color: rgba(148, 163, 184, .12); }
.signal-footer em {
  background: rgba(239, 68, 68, .12);
  color: #fecaca;
}
.signal-footer.quiet em {
  background: rgba(109, 141, 255, .12);
  color: #b9c6ff;
}
.metric { padding: 10px; border-radius: 8px; background: rgba(8, 13, 28, .42); }
.metric span { display: block; color: var(--muted); font-size: 12px; }
.metric strong { display: block; margin-top: 4px; font-size: 16px; }
.empty-state {
  margin-top: 18px;
  padding: 52px 20px;
  text-align: center;
  border: 1px dashed var(--line);
  border-radius: 8px;
  color: var(--muted);
}
.hidden { display: none; }
.toast {
  position: fixed;
  right: 20px;
  top: 84px;
  transform: translateX(140%);
  transition: transform .25s;
  padding: 12px 16px;
  border-radius: 8px;
  background: #0f766e;
  color: white;
  z-index: 50;
}
.toast.show { transform: translateX(0); }
.detail-shell { max-width: 1180px; }
.detail-card { padding: 28px; }
.mobile-report-hero,
.mobile-sticky-nav,
.mobile-bottom-nav,
.mobile-dashboard-summary {
  display: none;
}
.detail-title { display: flex; justify-content: space-between; gap: 18px; align-items: start; }
.detail-title h1 { font-size: clamp(32px, 5vw, 54px); }
.warning-list { display: grid; gap: 10px; margin-top: 24px; }
.warning {
  padding: 14px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: rgba(8, 13, 28, .35);
}
.warning.amber { border-color: rgba(245,158,11,.5); }
.warning.red { border-color: rgba(239,68,68,.55); }
.warning.info { border-color: rgba(109,141,255,.5); }
.detail-metrics { margin-top: 24px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.validity-blocker {
  margin-bottom: 18px;
  padding: 16px;
  border: 1px solid rgba(239,68,68,.62);
  border-radius: 8px;
  background: rgba(127, 29, 29, .20);
}
.validity-blocker strong {
  display: block;
  color: #fecaca;
  font-size: 20px;
}
.validity-blocker p {
  margin-top: 8px;
  color: var(--text);
  line-height: 1.65;
}
.validity-blocker div {
  margin-top: 12px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.v5-card-grid {
  margin-top: 22px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}
.v5-card {
  min-height: 218px;
  padding: 18px;
  border: 1px solid rgba(109, 141, 255, .30);
  border-radius: 8px;
  background: rgba(8, 13, 28, .34);
}
.v5-card.green { border-color: rgba(34,197,94,.42); }
.v5-card.amber { border-color: rgba(245,158,11,.52); }
.v5-card.red { border-color: rgba(239,68,68,.58); }
.v5-card > span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}
.v5-card h2 {
  margin-top: 10px;
  font-size: 23px;
  line-height: 1.22;
}
.v5-card p {
  margin-top: 10px;
  color: var(--muted);
  line-height: 1.6;
}
.v5-mini-list {
  margin-top: 14px;
  display: grid;
  gap: 8px;
}
.v5-mini-list p {
  margin: 0;
  min-height: 30px;
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding-top: 8px;
  border-top: 1px solid rgba(148,163,184,.13);
}
.v5-mini-list b {
  color: var(--muted);
  font-size: 12px;
}
.v5-mini-list strong {
  text-align: right;
  font-size: 13px;
}
.decision-flow {
  margin-top: 22px;
  display: grid;
  grid-template-columns: .95fr 1.05fr;
  gap: 14px;
}
.flow-card {
  min-height: 178px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(8, 13, 28, .34);
}
.flow-card.green { border-color: rgba(34,197,94,.42); }
.flow-card.amber { border-color: rgba(245,158,11,.48); }
.flow-card.red { border-color: rgba(239,68,68,.58); }
.flow-card span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}
.flow-card h2 {
  margin: 10px 0 0;
  font-size: 26px;
}
.flow-card p {
  margin-top: 10px;
  color: var(--muted);
  line-height: 1.65;
}
.condition-panel { margin-top: 22px; }
.section-head.compact { margin-top: 0; }
.condition-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
.condition-row {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(23, 32, 51, .42);
}
.condition-row + .condition-row { margin-top: 10px; }
.condition-row.green { border-color: rgba(34,197,94,.34); }
.condition-row.amber { border-color: rgba(245,158,11,.42); }
.condition-row.red { border-color: rgba(239,68,68,.48); }
.condition-row strong,
.condition-row span {
  display: inline-flex;
  margin-right: 8px;
}
.condition-row span {
  color: var(--blue);
  font-size: 12px;
  font-weight: 800;
}
.condition-row p {
  margin-top: 8px;
  color: var(--text);
  font-size: 13px;
  line-height: 1.5;
}
.condition-row em {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}
.event-intelligence-panel {
  margin-top: 22px;
}
.event-intelligence-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, .85fr);
  gap: 14px;
}
.event-list-card {
  grid-row: span 2;
}
.event-list {
  display: grid;
  gap: 12px;
}
.event-card {
  padding: 14px;
  border: 1px solid rgba(109, 141, 255, .24);
  border-radius: 8px;
  background: rgba(11, 18, 32, .46);
}
.event-card.quiet {
  border-color: rgba(148, 163, 184, .22);
}
.event-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}
.event-head span,
.event-head em {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
}
.event-head span {
  padding: 4px 8px;
  background: rgba(109, 141, 255, .16);
  color: #aebcff;
}
.event-head em {
  color: var(--muted);
  font-style: normal;
}
.event-card h3 {
  margin: 0;
  font-size: 18px;
}
.event-card > p {
  color: var(--muted);
  line-height: 1.65;
}
.attention-feedback-card {
  border-color: rgba(34, 197, 94, .26);
}
.attention-meter-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.attention-meter {
  padding: 12px;
  border: 1px solid rgba(148, 163, 184, .18);
  border-radius: 8px;
  background: rgba(23, 32, 51, .42);
}
.attention-meter h3 {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}
.attention-meter strong {
  display: block;
  margin-top: 10px;
  color: var(--text);
  font-size: 18px;
}
.attention-meter span,
.attention-meter p {
  display: block;
  margin-top: 4px;
  color: var(--blue);
  font-size: 12px;
  font-weight: 800;
}
.evidence-item + .evidence-item { margin-top: 12px; }
.evidence-item strong { display: block; }
.evidence-item p {
  margin-top: 6px;
  color: var(--muted);
  line-height: 1.6;
}
.evidence-matrix-module {
  grid-column: 1 / -1;
}
.evidence-matrix-row {
  padding: 14px 0;
  border-top: 1px solid rgba(148,163,184,.14);
}
.evidence-matrix-row:first-of-type {
  border-top: none;
  padding-top: 0;
}
.evidence-matrix-row h3 {
  margin: 0 0 12px;
  font-size: 18px;
}
.evidence-matrix-row > div {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 12px;
}
.evidence-matrix-row section {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(8, 13, 28, .28);
}
.evidence-matrix-row section > span {
  display: block;
  margin-bottom: 8px;
  color: var(--blue);
  font-size: 12px;
  font-weight: 800;
}
.evidence-matrix-row section p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}
.evidence-matrix-row section p + p {
  margin-top: 10px;
}
.evidence-matrix-row section strong {
  display: block;
  color: var(--text);
  font-size: 13px;
}
.evidence-matrix-row section p span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}
.sticky-actions {
  position: sticky;
  bottom: 14px;
  z-index: 8;
  margin-top: 18px;
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(11, 16, 32, .86);
  backdrop-filter: blur(14px);
}
.mobile-help-sheet[hidden] { display: none; }
.mobile-help-sheet {
  position: fixed;
  inset: 0;
  z-index: 120;
}
.mobile-help-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, .55);
}
.mobile-help-panel {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 22px 18px calc(22px + env(safe-area-inset-bottom));
  border: 1px solid rgba(109, 141, 255, .32);
  border-radius: 18px 18px 0 0;
  background: #101827;
  box-shadow: 0 -20px 55px rgba(0, 0, 0, .42);
}
.mobile-help-panel h2 {
  margin: 0;
  padding-right: 42px;
  font-size: 22px;
}
.mobile-help-panel p {
  margin-top: 12px;
  color: var(--muted);
  line-height: 1.75;
}
.mobile-help-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  min-width: 36px;
  border-radius: 50%;
  padding: 0;
  font-size: 24px;
}
.radar-panel,
.decision-panel {
  margin-top: 22px;
  padding: 18px;
  border: 1px solid rgba(148, 163, 184, .18);
  border-radius: 8px;
  background: rgba(8, 13, 28, .36);
}
.radar-panel.green, .decision-panel.green { border-color: rgba(34,197,94,.42); }
.radar-panel.amber, .decision-panel.amber { border-color: rgba(245,158,11,.48); }
.radar-panel.red, .decision-panel.red { border-color: rgba(239,68,68,.58); }
.radar-panel h2, .decision-panel h2 { margin: 0; font-size: 24px; }
.radar-panel p, .decision-panel p { margin-top: 8px; color: var(--muted); line-height: 1.65; }
.action-grid {
  margin-top: 16px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.action-grid div {
  padding: 14px;
  border-radius: 8px;
  background: rgba(23, 32, 51, .64);
}
.action-grid span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}
.action-grid strong {
  display: block;
  margin-top: 6px;
  font-size: 20px;
}
.radar-groups,
.signal-groups {
  margin-top: 16px;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
.radar-groups div,
.signal-groups div {
  padding: 12px;
  border-radius: 8px;
  background: rgba(23, 32, 51, .58);
}
.radar-groups span,
.signal-groups span {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}
.radar-groups em,
.signal-groups em {
  margin: 0 6px 6px 0;
}
.source-note { margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--line); color: var(--muted); line-height: 1.7; }
.planner-panel {
  margin-top: 22px;
  border: 1px solid rgba(109, 141, 255, .34);
  border-radius: 8px;
  background: rgba(8, 13, 28, .34);
}
.planner-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px;
}
.planner-head h2 {
  margin: 0;
  font-size: 24px;
}
.planner-head p {
  margin-top: 6px;
  color: var(--muted);
  line-height: 1.6;
}
.planner-toggle,
.secondary-btn {
  min-height: 42px;
}
.secondary-btn {
  border: 1px solid var(--line);
  background: rgba(148, 163, 184, .10);
  color: var(--text);
}
.planner-body {
  border-top: 1px solid var(--line);
  padding: 18px;
}
.planner-context {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border-radius: 8px;
  background: rgba(23, 32, 51, .58);
}
.planner-context span {
  color: var(--muted);
  font-size: 13px;
  text-align: right;
}
.planner-tabs {
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}
.planner-tab {
  min-height: 38px;
  padding: 0 10px;
  border: 1px solid var(--line);
  background: rgba(23, 32, 51, .62);
  color: var(--muted);
}
.planner-tab.active {
  border-color: rgba(109, 141, 255, .64);
  background: rgba(109, 141, 255, .18);
  color: var(--text);
}
.planner-grid {
  margin-top: 14px;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, .95fr);
  gap: 14px;
}
.planner-form,
.planner-result {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(23, 32, 51, .44);
}
.planner-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.planner-field span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}
.planner-field input,
.planner-field select {
  width: 100%;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(8, 13, 28, .72);
  color: var(--text);
  outline: none;
  padding: 0 10px;
}
.planner-advanced {
  margin-top: 12px;
  color: var(--muted);
}
.planner-advanced summary {
  cursor: pointer;
  font-weight: 800;
}
.planner-advanced .planner-fields {
  margin-top: 12px;
}
.planner-advanced p,
.planner-privacy {
  margin-top: 10px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}
.planner-actions {
  margin-top: 14px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.inline-actions {
  align-items: center;
}
.admin-help {
  background: rgba(15, 23, 42, .72);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  margin: 12px 0 18px;
  padding: 14px;
}
.admin-help summary {
  color: var(--text);
  cursor: pointer;
  font-weight: 900;
}
.role-help-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 12px;
}
.role-help-grid article {
  background: rgba(8, 13, 28, .42);
  border: 1px solid rgba(148, 163, 184, .18);
  border-radius: 8px;
  padding: 10px;
}
.role-help-grid strong {
  color: var(--text);
  display: block;
  margin-bottom: 5px;
}
.role-help-grid span {
  display: block;
  font-size: 13px;
  line-height: 1.55;
}
.parallel-panel {
  margin-top: 18px;
}
.parallel-form {
  max-width: none;
}
.wide-field {
  grid-column: 1 / -1;
}
.parallel-reasons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 12px 0;
}
.parallel-reasons label {
  align-items: center;
  background: rgba(99,102,241,.14);
  border: 1px solid rgba(129,140,248,.26);
  border-radius: 8px;
  color: #cbd5e1;
  display: inline-flex;
  font-size: 13px;
  gap: 6px;
  min-height: 34px;
  padding: 6px 10px;
}
.parallel-reasons input {
  accent-color: #818cf8;
}
.planner-status {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(8, 13, 28, .36);
}
.planner-status.green { border-color: rgba(34,197,94,.42); }
.planner-status.amber { border-color: rgba(245,158,11,.50); }
.planner-status.red { border-color: rgba(239,68,68,.58); }
.planner-status span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}
.planner-status strong {
  display: block;
  margin-top: 5px;
  font-size: 18px;
}
.planner-status p {
  margin-top: 6px;
  color: var(--muted);
  line-height: 1.55;
}
.planner-kpis {
  margin-top: 12px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.planner-kpis div {
  min-height: 64px;
  padding: 10px;
  border-radius: 8px;
  background: rgba(8, 13, 28, .42);
}
.planner-kpis span {
  display: block;
  color: var(--muted);
  font-size: 12px;
}
.planner-kpis strong {
  display: block;
  margin-top: 6px;
  font-size: 18px;
}
.parallel-outcome-card {
  margin-top: 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(15, 23, 42, .42);
}
.parallel-demo,
.parallel-readout {
  margin-bottom: 12px;
  padding: 12px;
  border: 1px solid rgba(109, 141, 255, .22);
  border-radius: 8px;
  background: rgba(109, 141, 255, .08);
}
.parallel-demo strong,
.parallel-readout strong {
  display: block;
  color: var(--text);
  font-size: 15px;
}
.parallel-demo p,
.parallel-readout p {
  margin-top: 6px;
  color: var(--muted);
  line-height: 1.55;
}
.parallel-demo span {
  display: inline-flex;
  margin-top: 8px;
  color: var(--blue);
  font-size: 12px;
  font-weight: 800;
}
.parallel-readout {
  margin-top: 12px;
  margin-bottom: 0;
  border-color: rgba(34, 197, 94, .24);
  background: rgba(34, 197, 94, .08);
}
.parallel-checkpoints {
  margin-top: 12px;
  display: grid;
  gap: 8px;
}
.checkpoint-row {
  display: grid;
  grid-template-columns: 54px 96px 80px 90px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  min-height: 38px;
  padding: 8px 10px;
  border-radius: 8px;
  background: rgba(8, 13, 28, .42);
  color: var(--muted);
  font-size: 13px;
}
.checkpoint-row strong {
  color: var(--text);
}
.checkpoint-row.FILLED span:nth-child(2) { color: var(--green); }
.checkpoint-row.UNFILLABLE span:nth-child(2) { color: var(--amber); }
.checkpoint-row em {
  font-style: normal;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.planner-table {
  margin-top: 12px;
  display: grid;
  gap: 8px;
}
.planner-table h3 {
  margin: 0;
  font-size: 16px;
}
.priority-modules {
  margin-top: 16px;
}
.driver-list,
.future-variable-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}
.driver-row,
.future-variable-row {
  padding: 12px;
  border-radius: 8px;
  background: rgba(8, 13, 28, .42);
  border: 1px solid rgba(148, 163, 184, .12);
}
.driver-row div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.driver-row strong,
.future-variable-row strong {
  color: var(--text);
}
.driver-row span,
.future-variable-row span {
  color: var(--blue);
  font-weight: 700;
  margin-right: 6px;
}
.driver-row p,
.future-variable-row p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.55;
}
.driver-row em,
.future-variable-row em {
  display: block;
  margin-top: 8px;
  color: var(--amber);
  font-style: normal;
  font-size: 12px;
}
.planner-table p {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  min-height: 30px;
  border-bottom: 1px solid rgba(148, 163, 184, .10);
  color: var(--muted);
}
.planner-table strong {
  color: var(--text);
  text-align: right;
}
.planner-warnings {
  margin-top: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.planner-warnings em {
  min-height: 26px;
  display: inline-flex;
  align-items: center;
  padding: 0 9px;
  border-radius: 999px;
  background: rgba(245, 158, 11, .14);
  color: var(--amber);
  font-style: normal;
  font-size: 12px;
}
.planner-foot {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}
.question-grid {
  margin-top: 22px;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
}
.question-card {
  min-height: 164px;
  padding: 14px;
  border: 1px solid rgba(148, 163, 184, .18);
  border-radius: 8px;
  background: rgba(8, 13, 28, .34);
}
.question-card.green { border-color: rgba(34,197,94,.38); }
.question-card.amber { border-color: rgba(245,158,11,.44); }
.question-card.red { border-color: rgba(239,68,68,.56); }
.question-card span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}
.question-card strong {
  display: block;
  margin-top: 8px;
  font-size: 17px;
}
.question-card.green strong { color: var(--green); }
.question-card.amber strong { color: var(--amber); }
.question-card.red strong { color: var(--red); }
.question-card p {
  margin-top: 10px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}
.module-grid {
  margin-top: 24px;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}
.info-module {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(8, 13, 28, .28);
}
.info-module h2 {
  margin: 0 0 14px;
  font-size: 20px;
}
.compact-list {
  display: grid;
  gap: 10px;
}
.compact-list p {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  color: var(--muted);
}
.compact-list strong {
  color: var(--text);
  font-size: 16px;
}
.module-note {
  margin: 12px 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}
.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.tag-cloud em {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(109, 141, 255, .12);
  color: #b9c6ff;
  font-style: normal;
  font-size: 13px;
}
.report-sections {
  margin-top: 24px;
  display: grid;
  gap: 14px;
}
.report-section {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(8, 13, 28, .28);
  padding: 18px;
}
.report-section h2 { margin: 0 0 8px; font-size: 20px; }
.report-section p { color: var(--muted); line-height: 1.65; }
.report-section ul { margin: 12px 0 0; padding-left: 20px; color: var(--text); line-height: 1.75; }
.simple-page .lead { max-width: 760px; }
.identity-strip {
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}
.identity-strip div {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(8, 13, 28, .36);
  padding: 12px 14px;
}
.identity-strip span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 5px;
}
.identity-strip strong {
  display: block;
  font-size: 14px;
  word-break: break-word;
}
.watch-suggestion {
  margin-top: 16px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(8, 13, 28, .36);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
}
.watch-suggestion.green { border-color: rgba(34,197,94,.45); }
.watch-suggestion.amber { border-color: rgba(245,158,11,.52); }
.watch-suggestion span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 6px;
}
.watch-suggestion strong {
  display: block;
  font-size: 20px;
}
.watch-suggestion.green strong { color: var(--green); }
.watch-suggestion.amber strong { color: var(--amber); }
.watch-suggestion p {
  max-width: 760px;
  margin-top: 8px;
  color: var(--muted);
  line-height: 1.6;
}
.data-quality-strip {
  margin-top: 16px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(8, 13, 28, .36);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
}
.data-quality-strip.READY { border-color: rgba(34,197,94,.38); }
.data-quality-strip.LIMITED { border-color: rgba(245,158,11,.52); }
.data-quality-strip.BLOCKED { border-color: rgba(239,68,68,.62); }
.data-quality-strip span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  margin-bottom: 6px;
}
.data-quality-strip strong {
  display: block;
  font-size: 20px;
}
.data-quality-strip.READY strong { color: var(--green); }
.data-quality-strip.LIMITED strong { color: var(--amber); }
.data-quality-strip.BLOCKED strong { color: var(--red); }
.data-quality-strip p {
  margin-top: 8px;
  color: var(--muted);
  line-height: 1.6;
}
.version-list {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}
.version-list a,
.version-list > span {
  display: grid;
  grid-template-columns: 80px 90px 1fr 90px;
  gap: 10px;
  align-items: center;
  color: var(--text);
  text-decoration: none;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 12px;
  background: rgba(8, 13, 28, .28);
}
.version-summary-card {
  border-color: rgba(148, 163, 184, .22);
}
.version-summary-card.green { border-color: rgba(34, 197, 94, .45); }
.version-summary-card.amber { border-color: rgba(245, 158, 11, .5); }
.version-summary-card.red { border-color: rgba(239, 68, 68, .58); }
.version-summary-card .state-chip {
  margin-bottom: 12px;
}
.fundamental-wide {
  grid-column: span 1;
}
.leader-tags {
  margin-top: 8px;
}
.admin-shell { width: min(1280px, calc(100% - 32px)); }
.table-wrap {
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.table-wrap table {
  width: max-content;
  min-width: 100%;
  max-width: none;
  border-collapse: collapse;
}
.table-wrap th,
.table-wrap td {
  overflow-wrap: anywhere;
}
.ops-bar-row span,
.trace-detail-grid span,
.radar-review-digest {
  overflow-wrap: anywhere;
  word-break: break-word;
}
.home-share-row button,
.radar-review-digest,
.topnav-workbench {
  touch-action: manipulation;
  -webkit-tap-highlight-color: rgba(109, 141, 255, .24);
}
.share-card-trigger,
.radar-review-digest,
.topnav-workbench {
  min-height: 44px;
}
.admin-table-wrap {
  margin-top: 18px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(23, 32, 51, .72);
}
.admin-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 1100px;
}
.compact-table .admin-table {
  min-width: 640px;
}
.admin-table th,
.admin-table td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
  font-size: 13px;
}
.admin-table th {
  color: var(--muted);
  font-weight: 700;
  background: rgba(8, 13, 28, .35);
}
.rule-table { min-width: 980px; }
.rule-param-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(160px, 1fr));
  gap: 10px;
}
.rule-param {
  display: grid;
  gap: 4px;
}
.rule-param label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}
.rule-param input {
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(8, 13, 28, .72);
  color: var(--text);
  padding: 0 10px;
  outline: none;
}
.rule-param input:focus { border-color: var(--blue); }
.rule-switch {
  width: 18px;
  height: 18px;
  accent-color: #6d8dff;
}
.admin-actions {
  margin-top: 12px;
  display: flex;
  align-items: center;
  gap: 14px;
}
.status-pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(148, 163, 184, .14);
  color: var(--muted);
  font-weight: 800;
  font-size: 12px;
}
.status-pill.done, .status-pill.success, .status-pill.green { background: rgba(34,197,94,.14); color: var(--green); }
.status-pill.pending, .status-pill.retrying, .status-pill.running { background: rgba(245,158,11,.14); color: var(--amber); }
.status-pill.failed, .status-pill.red { background: rgba(239,68,68,.14); color: var(--red); }
.status-pill.amber { background: rgba(245,158,11,.14); color: var(--amber); }
.status-pill.gray { background: rgba(148,163,184,.14); color: var(--muted); }

@media (max-width: 860px) {
  .hero, .tool-grid, .status-band, .report-grid, .detail-metrics, .radar-groups, .signal-groups, .action-grid, .module-grid, .question-grid, .identity-strip, .decision-flow, .condition-grid, .v5-card-grid, .event-intelligence-grid, .attention-meter-grid, .evidence-matrix-row > div { grid-template-columns: 1fr; }
  .console-head { align-items: start; flex-direction: column; }
  .console-stats { justify-content: flex-start; }
  .status-band div { border-right: none; border-bottom: 1px solid var(--line); }
  .status-band div:last-child { border-bottom: none; }
  .query-row { flex-direction: column; }
  button { height: 46px; }
  .section-head { align-items: start; flex-direction: column; }
  .topnav { order: 4; width: 100%; margin-left: 0; }
  .version-list a,
  .version-list > span { grid-template-columns: 1fr; }
  .sticky-actions { position: static; flex-direction: column; }
}

@media (max-width: 640px) {
  body {
    background: var(--bg);
    padding-bottom: env(safe-area-inset-bottom);
  }
  .page-grid {
    background-size: 28px 28px;
    opacity: .55;
  }
  .topbar {
    min-height: 56px;
    gap: 10px;
    padding: calc(8px + env(safe-area-inset-top)) 12px 8px;
  }
  .topnav {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 8px;
  }
  .topnav a {
    display: none;
    min-height: 40px;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--line);
    border-radius: 8px;
    font-size: 13px;
  }
  .topnav #homeAuthLink,
  .topnav #homeLoginLink {
    display: inline-flex;
  }
  .topnav a.topnav-primary {
    padding: 0 10px;
    border-bottom: 1px solid rgba(109, 141, 255, .55);
  }
  .topnav a.topnav-muted {
    margin-left: 0;
    padding: 0 10px;
    border-left: 1px solid var(--line);
  }
  .brand-mark {
    width: 34px;
    height: 34px;
    border-radius: 8px;
    font-size: 13px;
  }
  .topbar strong {
    font-size: 15px;
    line-height: 1.15;
  }
  .topbar span {
    display: none;
  }
  .topbar-status {
    display: none;
  }
  .admin-link {
    margin-left: auto;
    min-height: 34px;
    padding: 0 10px;
    display: inline-flex;
    align-items: center;
  }
  .back-link {
    min-height: 36px;
    padding: 0 10px;
    display: inline-flex;
    align-items: center;
    font-size: 13px;
  }
  .shell {
    width: min(100% - 20px, 420px);
    padding: 12px 0 calc(72px + env(safe-area-inset-bottom));
  }
  .table-wrap {
    margin-left: 0;
    margin-right: 0;
  }
  .home-share-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
  }
  .home-share-row button,
  .radar-review-digest {
    width: 100%;
    max-width: 100%;
    min-height: 56px;
    height: auto;
    padding-top: 13px;
    padding-bottom: 13px;
    line-height: 1.28;
    white-space: normal;
  }
  .share-card-trigger {
    display: flex;
    align-items: center;
    justify-content: center;
  }
  .query-console,
  .detail-card {
    padding: 14px;
    box-shadow: none;
  }
  .query-console .lead {
    display: none;
  }
  .console-head {
    gap: 12px;
  }
  .kicker {
    margin-bottom: 6px;
    font-size: 11px;
    letter-spacing: .08em;
  }
  .console-head h1,
  h1 {
    font-size: 24px;
    line-height: 1.16;
  }
  .search-guide {
    margin-top: 14px;
    font-size: 24px;
    line-height: 1.26;
  }
  .console-stats {
    width: 100%;
    display: none;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
  }
  .console-stats span {
    min-width: 0;
    min-height: 40px;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 2px;
    padding: 4px;
    font-size: 11px;
    text-align: center;
  }
  .console-stats strong {
    font-size: 14px;
  }
  .primary-query {
    margin-top: 14px;
  }
  .query-console .primary-query {
    grid-template-columns: 1fr;
  }
  .query-row {
    gap: 8px;
  }
  .input,
  .primary-query .input {
    height: 48px;
    font-size: 16px;
    padding: 0 12px;
  }
  button,
  .primary-query button {
    width: 100%;
    min-width: 0;
    height: 48px;
    font-size: 16px;
  }
  .search-inline {
    margin-top: 10px;
  }
  .task-progress {
    margin-top: 12px;
    padding: 12px;
  }
  .progress-head {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }
  .progress-steps {
    gap: 4px;
  }
  .progress-steps span {
    font-size: 11px;
  }
  .progress-action {
    width: 100%;
    min-height: 38px;
  }
  .section-head {
    margin-top: 24px;
    gap: 6px;
  }
  .section-head h2 {
    font-size: 22px;
  }
  .legend {
    font-size: 12px;
  }
  .report-grid {
    margin-top: 12px;
    gap: 10px;
  }
  .report-card {
    min-height: 0;
    padding: 14px;
    overflow: hidden;
  }
  .alert-corner {
    position: static;
    justify-content: flex-end;
    flex-wrap: wrap;
    margin: 0 0 8px;
  }
  .report-card:hover {
    transform: none;
  }
  .quote-head {
    gap: 10px;
    padding-bottom: 10px;
  }
  .quote-head > div:first-child {
    min-width: 0;
  }
  .report-card h3 {
    font-size: 19px;
    line-height: 1.2;
    word-break: break-word;
  }
  .quote-head .code {
    min-height: 23px;
    margin-top: 6px;
    padding: 0 7px;
    font-size: 12px;
  }
  .quote-price strong {
    font-size: 23px;
  }
  .quote-price span {
    margin-top: 5px;
    font-size: 14px;
    max-width: 128px;
    line-height: 1.35;
    white-space: normal;
    word-break: keep-all;
  }
  .decision-line {
    margin-top: 10px;
    padding: 9px 10px;
  }
  .decision-line strong {
    font-size: 14px;
  }
  .decision-line span {
    font-size: 12px;
  }
  .scan-metrics {
    margin-top: 10px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 12px;
  }
  .scan-metrics p {
    min-height: 30px;
    gap: 6px;
  }
  .scan-metrics span {
    font-size: 12px;
  }
  .scan-metrics strong {
    font-size: 13px;
  }
  .signal-footer {
    margin-top: 10px;
    padding-top: 10px;
  }
  .signal-footer em {
    min-height: 24px;
    max-width: 100%;
    line-height: 1.25;
  }
  .empty-state {
    padding: 34px 14px;
  }
  .toast {
    left: 12px;
    right: 12px;
    top: auto;
    bottom: 18px;
    transform: translateY(140%);
    text-align: center;
  }
  .toast.show {
    transform: translateY(0);
  }
  .detail-shell {
    max-width: 420px;
  }
  .mobile-report-hero {
    display: block;
    margin: -2px 0 14px;
    padding: 14px;
    border: 1px solid rgba(109, 141, 255, .32);
    border-radius: 8px;
    background: rgba(8, 13, 28, .46);
  }
  .mobile-report-identity {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
  }
  .mobile-report-identity strong,
  .mobile-report-identity span {
    display: block;
  }
  .mobile-report-identity strong {
    font-size: 18px;
    line-height: 1.2;
  }
  .mobile-report-identity span {
    margin-top: 5px;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.45;
  }
  .mobile-report-identity em {
    flex: 0 0 auto;
    display: inline-flex;
    min-height: 26px;
    align-items: center;
    border-radius: 999px;
    padding: 0 8px;
    background: rgba(109, 141, 255, .16);
    color: #b9c6ff;
    font-style: normal;
    font-size: 12px;
    font-weight: 900;
  }
  .mobile-blocker {
    margin-top: 12px;
    padding: 12px;
    border: 1px solid rgba(245, 158, 11, .42);
    border-radius: 8px;
    background: rgba(120, 53, 15, .12);
  }
  .mobile-blocker.red {
    border-color: rgba(239, 68, 68, .52);
    background: rgba(127, 29, 29, .16);
  }
  .mobile-blocker strong,
  .mobile-blocker span {
    display: block;
  }
  .mobile-blocker strong {
    color: var(--amber);
    font-size: 18px;
  }
  .mobile-blocker.red strong { color: #fecaca; }
  .mobile-blocker span {
    margin-top: 4px;
    color: var(--text);
    font-weight: 900;
  }
  .mobile-blocker p {
    margin-top: 8px;
    color: var(--muted);
    line-height: 1.6;
  }
  .mobile-summary-list {
    margin-top: 12px;
    display: grid;
    gap: 8px;
  }
  .mobile-summary-row {
    min-height: 52px;
    display: grid;
    grid-template-columns: 74px minmax(0, 1fr) 14px;
    align-items: center;
    gap: 8px;
    padding: 9px 10px;
    border: 1px solid rgba(148, 163, 184, .16);
    border-radius: 8px;
    background: rgba(15, 23, 42, .46);
    text-decoration: none;
  }
  .mobile-summary-row span {
    color: var(--muted);
    font-size: 13px;
    font-weight: 900;
  }
  .mobile-summary-row strong {
    color: var(--text);
    font-size: 14px;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
  .mobile-summary-row i {
    color: var(--blue);
    font-style: normal;
    font-size: 20px;
  }
  .mobile-primary-actions {
    margin-top: 12px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }
  .mobile-primary-actions button,
  .mobile-primary-actions a {
    min-height: 46px;
    width: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    text-align: center;
    text-decoration: none;
    font-weight: 900;
  }
  .mobile-main-action {
    border: 1px solid rgba(34, 197, 94, .42);
    background: rgba(34, 197, 94, .18);
    color: #86efac;
  }
  .mobile-secondary-action {
    border: 1px solid rgba(109, 141, 255, .35);
    background: rgba(109, 141, 255, .14);
    color: #c7d2fe;
  }
  .mobile-sticky-nav {
    position: sticky;
    top: calc(56px + env(safe-area-inset-top));
    z-index: 9;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 4px;
    margin: 0 -6px 12px;
    padding: 6px;
    border: 1px solid rgba(148, 163, 184, .14);
    border-radius: 8px;
    background: rgba(11, 16, 32, .92);
    backdrop-filter: blur(14px);
  }
  .mobile-sticky-nav a {
    min-height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 7px;
    color: var(--muted);
    text-decoration: none;
    font-size: 12px;
    font-weight: 900;
  }
  .mobile-sticky-nav a:focus,
  .mobile-sticky-nav a:hover,
  .mobile-sticky-nav a.active {
    background: rgba(109, 141, 255, .16);
    color: var(--text);
  }
  .detail-title,
  .identity-strip,
  .v5-card-grid,
  .validity-blocker {
    display: none;
  }
  #section-current,
  #section-risk,
  #section-conditions,
  #section-changes,
  #section-next,
  #section-data {
    scroll-margin-top: 118px;
  }
  .detail-title {
    align-items: flex-start;
  }
  .detail-title h1 {
    font-size: 30px;
  }
  .badge {
    white-space: nowrap;
  }
  .decision-panel {
    margin-top: 16px;
    padding: 14px;
  }
  .decision-panel h2 {
    font-size: 22px;
  }
  .decision-panel p {
    line-height: 1.55;
  }
  .action-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }
  .action-grid div {
    padding: 12px 10px;
  }
  .action-grid strong {
    font-size: 17px;
    line-height: 1.25;
  }
  .signal-groups {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .question-grid {
    margin-top: 12px;
    gap: 8px;
  }
  .question-card {
    min-height: 0;
    padding: 12px;
  }
  .question-card strong {
    font-size: 16px;
  }
  .question-card p {
    margin-top: 7px;
    line-height: 1.55;
  }
  .detail-metrics {
    margin-top: 14px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }
  .watch-suggestion {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    padding: 14px;
  }
  .watch-suggestion strong {
    font-size: 18px;
  }
  .metric {
    min-height: 68px;
    padding: 10px;
  }
  .metric strong {
    font-size: 14px;
    line-height: 1.35;
    word-break: break-word;
  }
  .module-grid {
    margin-top: 14px;
    gap: 10px;
  }
  .info-module {
    padding: 14px;
  }
  .info-module h2 {
    font-size: 18px;
    margin-bottom: 10px;
  }
  .compact-list p {
    min-height: 28px;
  }
  .compact-list strong {
    font-size: 14px;
    text-align: right;
  }
  .source-note {
    margin-top: 18px;
    font-size: 12px;
    line-height: 1.6;
  }
  .event-intelligence-grid,
  .condition-grid {
    grid-template-columns: 1fr;
  }
  .attention-meter-grid {
    grid-template-columns: 1fr 1fr;
  }
  .sticky-actions {
    position: sticky;
    bottom: calc(10px + env(safe-area-inset-bottom));
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    padding: 10px;
  }
  .sticky-actions > :nth-child(n+3) {
    display: none;
  }
  .sticky-actions button,
  .sticky-actions a {
    width: 100%;
    min-height: 44px;
  }
  .mobile-dashboard-summary {
    display: block;
    margin-top: 12px;
    padding: 14px;
    border: 1px solid rgba(109, 141, 255, .28);
    border-radius: 8px;
    background: rgba(8, 13, 28, .42);
  }
  .dashboard-change-head strong,
  .dashboard-change-head span {
    display: block;
  }
  .dashboard-change-head strong {
    font-size: 18px;
  }
  .dashboard-change-head span {
    margin-top: 5px;
    color: var(--muted);
    line-height: 1.5;
  }
  .dashboard-change-list {
    margin-top: 12px;
    display: grid;
    gap: 8px;
  }
  .dashboard-change-row {
    display: grid;
    grid-template-columns: 76px minmax(0, 1fr);
    gap: 4px 10px;
    padding: 10px;
    border: 1px solid rgba(245, 158, 11, .34);
    border-radius: 8px;
    background: rgba(120, 53, 15, .10);
    text-decoration: none;
  }
  .dashboard-change-row span {
    grid-row: span 2;
    color: var(--blue);
    font-size: 13px;
    font-weight: 900;
  }
  .dashboard-change-row strong {
    font-size: 14px;
  }
  .dashboard-change-row em {
    color: var(--muted);
    font-size: 12px;
    font-style: normal;
    line-height: 1.45;
  }
  .dashboard-change-row.p1,
  .dashboard-change-row.red {
    border-color: rgba(239, 68, 68, .46);
    background: rgba(127, 29, 29, .14);
  }
  .dashboard-change-row.quiet {
    border-color: rgba(148, 163, 184, .16);
    background: rgba(15, 23, 42, .38);
  }
  .mobile-bottom-nav {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 60;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    padding: 6px 6px calc(6px + env(safe-area-inset-bottom));
    border-top: 1px solid rgba(148, 163, 184, .18);
    background: rgba(11, 16, 32, .94);
    backdrop-filter: blur(16px);
  }
  .mobile-bottom-nav a {
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--muted);
    text-decoration: none;
    font-size: 12px;
    font-weight: 900;
  }
  .mobile-bottom-nav a:hover,
  .mobile-bottom-nav a:focus {
    color: var(--text);
  }
  .app-search-bar {
    margin-top: 12px;
    margin-bottom: 12px;
    padding: 14px;
  }
  .tip-popover {
    display: none;
  }
  .alert-corner {
    position: static;
    justify-content: flex-end;
    flex-wrap: wrap;
    margin: -2px 0 8px;
  }
  .alert-chip,
  .state-chip,
  .new-chip {
    max-width: 100%;
  }
  .quote-head {
    align-items: flex-start;
  }
  .quote-price {
    min-width: 96px;
    max-width: 42%;
  }
  .quote-price strong {
    overflow-wrap: anywhere;
  }
  .quote-price span {
    line-height: 1.25;
  }
  .tip-button {
    width: 24px;
    height: 24px;
    min-width: 24px;
    cursor: pointer;
  }
  .rule-data-line,
  .condition-row em {
    display: none;
  }
  .rule-detail summary {
    min-height: 40px;
    display: flex;
    align-items: center;
  }
  .dashboard-section .report-card .quote-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
  }
  .dashboard-section .report-card .quote-price {
    min-width: 0;
    max-width: 132px;
  }
  .dashboard-section .report-card .quote-price strong,
  .dashboard-section .report-card .quote-price span {
    text-align: right;
    overflow-wrap: anywhere;
  }
  .watch-meta {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .watch-meta span {
    min-width: 0;
    overflow-wrap: anywhere;
  }
  .signal-footer em {
    overflow-wrap: anywhere;
  }
  .mobile-help-panel {
    max-height: 72vh;
    overflow: auto;
  }
  .progress-steps {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
  .progress-steps span {
    text-align: center;
  }
  .planner-head {
    align-items: flex-start;
    flex-direction: column;
    padding: 14px;
  }
  .planner-toggle {
    width: 100%;
  }
  .planner-body {
    padding: 12px;
  }
  .planner-context {
    flex-direction: column;
  }
  .planner-context span {
    text-align: left;
  }
  .planner-tabs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .planner-grid,
  .planner-fields,
  .planner-kpis {
    grid-template-columns: 1fr;
  }
  .checkpoint-row {
    grid-template-columns: 44px 1fr 1fr;
  }
  .checkpoint-row em {
    grid-column: 1 / -1;
    white-space: normal;
  }
  .planner-actions button {
    width: 100%;
  }
}

@media print {
  .topbar, .planner-form, .planner-toggle, .planner-tabs, .detail-metrics, .module-grid, .question-grid { display: none !important; }
  body { background: white; color: #111827; }
  .detail-card, .planner-panel, .planner-result { box-shadow: none; border-color: #d1d5db; background: white; color: #111827; }
}

@media (min-width: 861px) and (max-width: 1180px) {
  .report-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .question-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (min-width: 1181px) and (max-width: 1420px) {
  .report-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

.share-card-modal[hidden] {
  display: none;
}
.share-card-modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(2, 6, 23, .78);
  backdrop-filter: blur(12px);
}
.share-card-dialog {
  width: min(520px, 100%);
  max-height: min(760px, calc(100vh - 36px));
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid rgba(109, 141, 255, .36);
  border-radius: 8px;
  background: rgba(15, 23, 42, .98);
  box-shadow: 0 24px 80px rgba(0, 0, 0, .48);
  padding: 16px;
}
.share-card-topline,
.share-card-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.share-card-topline span {
  color: #c7d2fe;
  font-weight: 900;
}
.share-card-topline button {
  min-height: 34px;
  padding: 0 14px;
}
.share-image-result {
  margin-top: 14px;
  border: 1px solid rgba(148, 163, 184, .18);
  border-radius: 8px;
  overflow: hidden;
  background: rgba(8, 13, 28, .62);
}
.share-image-result img {
  display: block;
  width: 100%;
  height: auto;
}
.share-observation-card,
.share-copy-fallback {
  margin-top: 14px;
}
.share-observation-card {
  padding: 16px;
  border: 1px solid rgba(148, 163, 184, .18);
  border-radius: 8px;
  background: rgba(8, 13, 28, .62);
}
.share-copy-fallback textarea {
  width: 100%;
  min-height: 150px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(8, 13, 28, .72);
  color: var(--text);
  padding: 12px;
}
.share-card-status {
  min-height: 22px;
  margin: 12px 0;
  color: var(--muted);
}
.share-card-status.success {
  color: #86efac;
}
.share-card-status.error {
  color: #fecaca;
}
.share-card-actions button {
  flex: 1;
  min-height: 44px;
}
