:root {
  --nav: #0d2338;
  --nav2: #132f49;
  --ink: #15202b;
  --muted: #6f7d8a;
  --line: #e5e9ed;
  --bg: #f5f7f9;
  --white: #fff;
  --blue: #1775e5;
  --teal: #10a083;
  --orange: #f08b3e;
  --red: #d94b4b;
  --shadow: 0 8px 28px rgba(16, 39, 63, 0.08);
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font:
    14px/1.55 -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    "PingFang SC",
    "Microsoft YaHei",
    sans-serif;
}
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 232px;
  background: linear-gradient(180deg, var(--nav), #0b1d2e);
  color: #fff;
  padding: 28px 18px;
  display: flex;
  flex-direction: column;
  z-index: 3;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 10px 30px;
}
.brand-mark {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: linear-gradient(135deg, #28b8a2, #1775e5);
  display: grid;
  place-items: center;
  font-size: 18px;
  font-weight: 800;
  box-shadow: 0 8px 20px rgba(23, 117, 229, 0.25);
}
.brand strong,
.brand span {
  display: block;
}
.brand strong {
  font-size: 17px;
  letter-spacing: 0.04em;
}
.brand span {
  font-size: 9px;
  letter-spacing: 0.16em;
  color: #89a0b5;
  margin-top: 1px;
}
.sidebar nav {
  display: grid;
  gap: 7px;
}
.nav-item {
  width: 100%;
  border: 0;
  background: transparent;
  color: #9bb0c2;
  padding: 12px 14px;
  border-radius: 10px;
  text-align: left;
  font-size: 14px;
  cursor: pointer;
  display: flex;
  gap: 12px;
  align-items: center;
}
.nav-item span {
  width: 20px;
  text-align: center;
  font-weight: 800;
}
.nav-item:hover,
.nav-item.active {
  background: var(--nav2);
  color: #fff;
}
.nav-item.active {
  box-shadow: inset 3px 0 #28b8a2;
}
.sidebar-foot {
  margin-top: auto;
  border-top: 1px solid rgba(255, 255, 255, 0.09);
  padding: 22px 10px 0;
  display: flex;
  gap: 10px;
  align-items: center;
}
.sidebar-foot strong,
.sidebar-foot span {
  display: block;
}
.sidebar-foot strong {
  font-size: 12px;
}
.sidebar-foot span {
  font-size: 10px;
  color: #8ba0b3;
}
.health-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #f5b642;
  box-shadow: 0 0 0 5px rgba(245, 182, 66, 0.1);
}
.health-dot.ok {
  background: #39c89b;
  box-shadow: 0 0 0 5px rgba(57, 200, 155, 0.1);
}
.health-dot.bad {
  background: #ef6b6b;
}
main {
  margin-left: 232px;
  min-height: 100vh;
}
.topbar {
  height: 96px;
  padding: 20px 36px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(14px);
  position: sticky;
  top: 0;
  z-index: 2;
}
.topbar h1 {
  margin: 0;
  font-size: 24px;
  letter-spacing: -0.02em;
}
.eyebrow {
  margin: 0 0 4px;
  color: #8895a1;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.eyebrow.light {
  color: #8cc2d0;
}
.top-actions,
.toolbar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}
.mode-pill {
  padding: 7px 11px;
  border-radius: 999px;
  background: #edf3f8;
  color: #557085;
  font-size: 11px;
}
.btn {
  border: 0;
  border-radius: 9px;
  padding: 10px 16px;
  font-weight: 650;
  cursor: pointer;
  font-size: 13px;
  transition: 0.15s ease;
}
.btn:hover {
  transform: translateY(-1px);
}
.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}
.btn.primary {
  background: var(--blue);
  color: #fff;
  box-shadow: 0 6px 18px rgba(23, 117, 229, 0.18);
}
.btn.secondary {
  background: #edf2f6;
  color: #385269;
}
.btn.wide {
  width: 100%;
}
.text-btn {
  border: 0;
  background: none;
  color: var(--blue);
  cursor: pointer;
}
.view {
  display: none;
  padding: 28px 36px 48px;
}
.view.active {
  display: block;
}
.hero-card {
  min-height: 184px;
  background: linear-gradient(118deg, #102b44, #174f6a 72%, #137b7e);
  border-radius: 16px;
  color: #fff;
  padding: 33px 38px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: var(--shadow);
  overflow: hidden;
  position: relative;
}
.hero-card:after {
  content: "";
  position: absolute;
  width: 290px;
  height: 290px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 50%;
  right: -70px;
  top: -150px;
  box-shadow:
    0 0 0 45px rgba(255, 255, 255, 0.025),
    0 0 0 90px rgba(255, 255, 255, 0.02);
}
.hero-card h2 {
  font-size: 29px;
  margin: 4px 0 7px;
}
.hero-card p:not(.eyebrow) {
  margin: 0;
  color: #b8ced9;
}
.hero-status {
  position: relative;
  z-index: 1;
  text-align: right;
  padding-right: 18px;
}
.hero-status span,
.hero-status small,
.hero-status strong {
  display: block;
}
.hero-status span {
  color: #9bc0cc;
  font-size: 11px;
}
.hero-status strong {
  font-size: 22px;
  margin: 4px 0;
}
.hero-status small {
  color: #c1d4dc;
}
.metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin: 18px 0;
}
.metric-card {
  background: #fff;
  border-radius: 13px;
  padding: 19px 21px;
  box-shadow: var(--shadow);
  border-top: 3px solid #7ba6c7;
}
.metric-card.alert {
  border-color: var(--orange);
}
.metric-card.danger {
  border-color: var(--red);
}
.metric-card span,
.metric-card small,
.metric-card strong {
  display: block;
}
.metric-card span {
  color: #758390;
  font-size: 12px;
}
.metric-card strong {
  font-size: 29px;
  margin: 6px 0 2px;
}
.metric-card small {
  color: #9aa5ae;
}
.two-column {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 18px;
}
.panel {
  background: #fff;
  border-radius: 14px;
  padding: 23px;
  box-shadow: var(--shadow);
}
.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}
.panel h2,
.panel h3 {
  margin: 0;
}
.panel h3 {
  font-size: 17px;
}
.event-list {
  display: grid;
  gap: 8px;
}
.event-item {
  display: grid;
  grid-template-columns: 9px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border-radius: 9px;
  background: #f8fafb;
}
.event-item .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--orange);
}
.event-item.critical .dot {
  background: var(--red);
}
.event-item strong,
.event-item span {
  display: block;
}
.event-item span {
  font-size: 11px;
  color: var(--muted);
}
.event-price {
  text-align: right;
  color: var(--red);
  font-weight: 700;
}
.trend-chart {
  height: 225px;
  display: flex;
  align-items: flex-end;
  gap: 12px;
  padding: 18px 8px 0;
}
.trend-bar-wrap {
  flex: 1;
  text-align: center;
  min-width: 26px;
}
.trend-bar {
  height: 150px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 3px;
  border-bottom: 1px solid var(--line);
}
.bar {
  width: 10px;
  min-height: 3px;
  border-radius: 4px 4px 0 0;
  background: #79a8ce;
}
.bar.breach {
  background: var(--orange);
}
.trend-bar-wrap span {
  font-size: 10px;
  color: var(--muted);
}
.empty {
  color: #97a3ad;
  text-align: center;
  padding: 36px 10px;
  width: 100%;
}
.section-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}
.section-toolbar p {
  color: var(--muted);
  margin: 0;
}
.table-panel {
  padding: 0;
  overflow: hidden;
}
.filter-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 17px 20px;
  border-bottom: 1px solid var(--line);
}
input,
select,
textarea {
  width: 100%;
  border: 1px solid #dce3e8;
  background: #fff;
  border-radius: 8px;
  padding: 10px 11px;
  color: var(--ink);
  font: inherit;
  outline: none;
}
input:focus,
select:focus,
textarea:focus {
  border-color: #6ba9e8;
  box-shadow: 0 0 0 3px rgba(23, 117, 229, 0.08);
}
.search {
  max-width: 330px;
}
.filter-row select {
  width: 140px;
}
.result-count {
  margin-left: auto;
  color: var(--muted);
  font-size: 12px;
}
.table-wrap {
  overflow: auto;
}
table {
  width: 100%;
  border-collapse: collapse;
  min-width: 970px;
}
th,
td {
  padding: 13px 16px;
  border-bottom: 1px solid #edf0f2;
  text-align: left;
  vertical-align: middle;
}
th {
  font-size: 11px;
  color: #7a8791;
  background: #fbfcfd;
  font-weight: 700;
  letter-spacing: 0.02em;
}
td {
  font-size: 12px;
}
td strong,
td small {
  display: block;
}
td small {
  color: var(--muted);
  margin-top: 2px;
}
.price-down {
  color: var(--red);
  font-weight: 750;
}
.tag {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 4px 9px;
  background: #edf2f6;
  color: #536b7e;
  font-size: 10px;
  white-space: nowrap;
}
.tag.active,
.tag.confirmed {
  background: #e6f7f1;
  color: #08775f;
}
.tag.warning,
.tag.pending_confirmation {
  background: #fff2e7;
  color: #a85c20;
}
.tag.critical {
  background: #fdeaea;
  color: #b83434;
}
.tag.closed {
  background: #eef1f3;
  color: #7a8791;
}
.tag.processing,
.tag.waiting_recheck {
  background: #eaf2fc;
  color: #276aa7;
}
.table-action {
  border: 0;
  background: #edf2f6;
  color: #49647a;
  border-radius: 7px;
  padding: 6px 9px;
  cursor: pointer;
}
.config-action {
  background: #eaf3ff;
  color: #176fc8;
}
.verification-state {
  font-weight: 650;
}
.verification-state.verified {
  color: #148166;
}
.verification-state.pending {
  color: #b06a2c;
}
.report-layout {
  display: grid;
  grid-template-columns: 380px 1fr;
  gap: 18px;
}
.report-download {
  text-align: center;
  padding: 38px;
}
.report-icon {
  width: 58px;
  height: 58px;
  background: #e8f6ef;
  color: #1e8d60;
  border-radius: 16px;
  margin: 0 auto 18px;
  display: grid;
  place-items: center;
  font-size: 25px;
  font-weight: 800;
}
.report-download h2 {
  margin: 5px 0 7px;
}
.report-download p:not(.eyebrow) {
  color: var(--muted);
}
label {
  display: block;
  text-align: left;
  color: #61707c;
  font-size: 12px;
  font-weight: 600;
}
label input,
label select,
label textarea {
  margin-top: 6px;
  font-weight: 400;
}
.report-download label {
  margin: 24px 0 14px;
}
.run-list {
  display: grid;
  gap: 8px;
}
.run-item {
  padding: 13px;
  background: #f8fafb;
  border-radius: 9px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.run-item strong,
.run-item span {
  display: block;
}
.run-item span {
  font-size: 11px;
  color: var(--muted);
}
.settings-grid {
  display: grid;
  grid-template-columns: 1.3fr 0.7fr;
  gap: 18px;
}
.settings-form .btn {
  margin-top: 20px;
}
.form-grid {
  display: grid;
  gap: 13px;
  margin: 14px 0;
}
.form-grid.two {
  grid-template-columns: repeat(2, 1fr);
}
.form-grid.three {
  grid-template-columns: repeat(3, 1fr);
}
.switch input {
  display: none;
}
.switch span {
  display: block;
  width: 42px;
  height: 24px;
  border-radius: 20px;
  background: #ccd5dc;
  position: relative;
  cursor: pointer;
}
.switch span:after {
  content: "";
  position: absolute;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fff;
  left: 3px;
  top: 3px;
  transition: 0.2s;
}
.switch input:checked + span {
  background: var(--teal);
}
.switch input:checked + span:after {
  transform: translateX(18px);
}
.connection-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 17px 0;
  border-bottom: 1px solid var(--line);
}
.connection-row strong,
.connection-row span {
  display: block;
}
.connection-row div span {
  font-size: 11px;
  color: var(--muted);
}
.connection-card .btn {
  margin-top: 20px;
}
.hint {
  color: var(--muted);
  font-size: 11px;
}
dialog {
  border: 0;
  padding: 0;
  background: transparent;
  max-width: none;
}
dialog::backdrop {
  background: rgba(7, 21, 33, 0.58);
  backdrop-filter: blur(3px);
}
.dialog-card {
  width: min(760px, calc(100vw - 32px));
  max-height: calc(100vh - 40px);
  overflow: auto;
  background: #fff;
  border-radius: 16px;
  padding: 25px;
  box-shadow: 0 25px 70px rgba(0, 0, 0, 0.25);
}
.dialog-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
}
.dialog-head h2 {
  margin: 0;
}
.icon-btn {
  border: 0;
  background: #edf2f6;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 20px;
}
.dialog-card > label {
  margin: 13px 0;
}
.approval-only-section > label {
  max-width: 360px;
  margin-top: 16px;
}
.monitor-product-summary {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 13px;
  margin: -4px 0 16px;
  border: 1px solid #dfe8ef;
  border-radius: 12px;
  background: #f8fbfd;
}
.monitor-product-summary img,
.monitor-product-summary .product-placeholder {
  width: 58px;
  height: 58px;
  border-radius: 10px;
  object-fit: cover;
  flex: 0 0 auto;
}
.monitor-product-summary strong,
.monitor-product-summary small {
  display: block;
}
.monitor-product-summary strong {
  color: var(--ink);
  margin-bottom: 5px;
}
.monitor-product-summary small {
  color: var(--muted);
}
.checkout-rule-note {
  display: grid;
  gap: 5px;
  margin-top: 15px;
  padding: 13px 15px;
  border-left: 3px solid var(--teal);
  border-radius: 8px;
  background: #eef9f6;
  color: #3e5f58;
}
.checkout-rule-note strong {
  color: #176e5a;
}
.checkout-rule-note span {
  font-size: 11px;
  line-height: 1.7;
}
.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 9px;
  margin-top: 22px;
  padding-top: 17px;
  border-top: 1px solid var(--line);
}
.event-summary {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 18px;
}
.summary-box {
  padding: 13px;
  border-radius: 9px;
  background: #f7f9fb;
}
.summary-box span,
.summary-box strong {
  display: block;
}
.summary-box span {
  color: var(--muted);
  font-size: 10px;
}
.summary-box strong {
  font-size: 16px;
  margin-top: 3px;
}
.discount-box {
  grid-column: 1/-1;
}
.breach-list {
  display: grid;
  gap: 14px;
  padding: 18px;
  background: #f4f7f9;
}
.breach-card {
  overflow: hidden;
  border: 1px solid #e2e8ec;
  border-left: 4px solid #f1a36d;
  border-radius: 13px;
  background: #fff;
  box-shadow: 0 5px 18px rgba(26, 54, 74, 0.05);
}
.breach-card.critical {
  border-left-color: #dc5555;
}
.breach-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 13px 18px 10px;
}
.breach-card-head time {
  color: var(--muted);
  font-size: 11px;
}
.breach-badges,
.condition-chips,
.evidence-chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
}
.breach-card-body {
  display: grid;
  grid-template-columns: minmax(300px, 1.55fr) minmax(360px, 1fr) auto;
  align-items: center;
  gap: 24px;
  padding: 0 18px 16px;
}
.breach-product {
  min-width: 0;
}
.breach-product h3 {
  display: -webkit-box;
  overflow: hidden;
  margin: 0;
  color: #1c2b36;
  font-size: 14px;
  line-height: 1.55;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}
.breach-product p {
  overflow: hidden;
  margin: 6px 0 10px;
  color: var(--muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.breach-owner {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 11px;
}
.breach-owner strong {
  color: #395266;
  font-size: 12px;
}
.breach-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(92px, 1fr));
  overflow: hidden;
  border: 1px solid #ebeff2;
  border-radius: 10px;
  background: #fafbfc;
}
.breach-metrics > div {
  min-width: 0;
  padding: 12px 14px;
  border-right: 1px solid #ebeff2;
}
.breach-metrics > div:last-child {
  border-right: 0;
}
.breach-metrics span,
.breach-metrics small {
  display: block;
  color: var(--muted);
  font-size: 10px;
}
.breach-metrics strong {
  display: inline-block;
  margin-top: 4px;
  font-size: 15px;
}
.breach-metrics small {
  display: inline-block;
  margin-left: 5px;
}
.event-handle {
  min-width: 88px;
  border: 1px solid #d8e4ed;
  background: #eef5fa;
  color: #315b79;
}
.price-trace-strip {
  padding: 12px 18px 14px;
  border-top: 1px solid #edf1f4;
  background: #f7fafc;
}
.trace-heading,
.trace-detail-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.trace-heading > span {
  color: #526c7f;
  font-size: 11px;
  font-weight: 750;
}
.trace-heading > b,
.trace-detail-head > span {
  border-radius: 999px;
  padding: 4px 8px;
  background: #e7f6f0;
  color: #158067;
  font-size: 10px;
  font-weight: 650;
}
.price-trace-strip.partial .trace-heading > b,
.price-trace-strip.unavailable .trace-heading > b,
.price-trace-detail.partial .trace-detail-head > span,
.price-trace-detail.unavailable .trace-detail-head > span {
  background: #fff0e4;
  color: #a65d27;
}
.trace-equation {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: 7px;
  margin-top: 9px;
}
.trace-equation > span {
  display: flex;
  min-width: 104px;
  flex-direction: column;
  justify-content: center;
  border: 1px solid #dfe8ee;
  border-radius: 8px;
  padding: 7px 10px;
  background: #fff;
}
.trace-equation > span small {
  overflow: hidden;
  max-width: 220px;
  color: #7d8a94;
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.trace-equation > span strong {
  margin-top: 2px;
  color: #2b4050;
  font-size: 12px;
}
.trace-equation > i {
  align-self: center;
  color: #8a98a3;
  font-size: 15px;
  font-style: normal;
  font-weight: 700;
}
.trace-equation .trace-final {
  border-color: #f0cccc;
  background: #fff8f8;
}
.trace-equation .trace-final strong,
.trace-equation .trace-unexplained strong {
  color: var(--red);
}
.trace-equation .trace-unexplained {
  border-color: #f1cfac;
  background: #fff8ef;
}
.trace-breach-line {
  margin-top: 9px;
  color: #687b89;
  font-size: 10px;
}
.trace-breach-line strong {
  color: #334b5d;
}
.trace-breach-line b {
  color: var(--red);
}
.price-trace-detail {
  grid-column: 1/-1;
  overflow: hidden;
  border: 1px solid #dce6ed;
  border-radius: 10px;
  background: #fbfcfd;
}
.trace-detail-head {
  padding: 12px 14px;
  border-bottom: 1px solid #e6ecef;
}
.trace-detail-head > strong {
  color: #2d4658;
  font-size: 12px;
}
.price-trace-detail > p {
  margin: 0;
  padding: 14px;
  color: var(--muted);
  font-size: 11px;
}
.price-trace-detail ol {
  margin: 0;
  padding: 0;
  list-style: none;
}
.price-trace-detail li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 9px 14px;
  border-bottom: 1px solid #edf1f3;
}
.price-trace-detail li > span b,
.price-trace-detail li > span small {
  display: block;
}
.price-trace-detail li > span b {
  color: #395063;
  font-size: 11px;
}
.price-trace-detail li > span small {
  margin-top: 2px;
  color: #8b98a1;
  font-size: 9px;
}
.price-trace-detail li > strong {
  color: #2c4354;
  font-size: 12px;
  white-space: nowrap;
}
.price-trace-detail li.unexplained {
  background: #fff8ee;
}
.price-trace-detail li.unexplained strong {
  color: #a95b24;
}
.price-trace-detail li.trace-total {
  border-bottom: 0;
  background: #f6f9fb;
}
.price-trace-detail li.trace-total > strong {
  color: var(--red);
  font-size: 14px;
}
.trace-approval {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 11px 14px;
  border-top: 1px solid #dfe7ec;
  background: #eef4f8;
  color: #526b7e;
  font-size: 10px;
}
.trace-approval i {
  color: #8d9aa4;
  font-style: normal;
}
.trace-context {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  padding: 9px 14px;
  border-top: 1px solid #e4eaee;
  color: #7d8b95;
  font-size: 9px;
}
.breach-evidence {
  display: grid;
  grid-template-columns: minmax(180px, 0.55fr) minmax(360px, 1.45fr);
  gap: 22px;
  padding: 12px 18px 14px;
  border-top: 1px solid #edf1f4;
  background: #fbfcfd;
}
.evidence-title,
.dialog-evidence-title {
  display: block;
  margin-bottom: 7px;
  color: #7d8992;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.04em;
}
.condition-chip,
.condition-clear,
.evidence-chip,
.evidence-empty {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  padding: 5px 9px;
  font-size: 10px;
}
.condition-chip {
  background: #fff0e6;
  color: #9b592d;
}
.condition-clear {
  background: #e8f6f1;
  color: #168066;
}
.evidence-chip {
  max-width: 100%;
  border: 1px solid #dce7ee;
  background: #fff;
  color: #425a6c;
}
.evidence-chip b {
  overflow: hidden;
  max-width: 430px;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.evidence-chip em {
  color: var(--red);
  font-style: normal;
  font-weight: 700;
  white-space: nowrap;
}
.evidence-chip small {
  color: #9b592d;
}
.evidence-empty {
  padding-left: 0;
  color: #98a4ad;
}
.discount-box .condition-chips {
  margin: 7px 0 13px;
}
.discount-box .dialog-evidence-title {
  margin-top: 6px;
}
.toast {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 20;
  background: #112a40;
  color: #fff;
  padding: 12px 18px;
  border-radius: 9px;
  box-shadow: var(--shadow);
  transform: translateY(90px);
  opacity: 0;
  transition: 0.2s;
}
.toast.show {
  transform: translateY(0);
  opacity: 1;
}
.toast.error {
  background: #a73d3d;
}
@media (max-width: 1050px) {
  .metrics {
    grid-template-columns: repeat(2, 1fr);
  }
  .two-column,
  .settings-grid {
    grid-template-columns: 1fr;
  }
  .report-layout {
    grid-template-columns: 1fr;
  }
  .report-download {
    max-width: none;
  }
  .breach-card-body {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .event-handle {
    justify-self: start;
  }
  .breach-evidence {
    grid-template-columns: 1fr;
    gap: 12px;
  }
}
@media (max-width: 760px) {
  .sidebar {
    width: 72px;
    padding: 22px 10px;
  }
  .breach-list {
    padding: 10px;
  }
  .breach-card-head,
  .breach-card-body,
  .price-trace-strip,
  .breach-evidence {
    padding-left: 13px;
    padding-right: 13px;
  }
  .breach-metrics {
    grid-template-columns: 1fr;
  }
  .breach-metrics > div {
    border-right: 0;
    border-bottom: 1px solid #ebeff2;
  }
  .breach-metrics > div:last-child {
    border-bottom: 0;
  }
  .trace-equation > span {
    min-width: calc(50% - 24px);
  }
  .brand {
    padding: 0 7px 25px;
  }
  .brand > div:last-child,
  .nav-item:not(.active) {
    font-size: 0;
  }
  .brand-mark {
    width: 38px;
  }
  .nav-item {
    justify-content: center;
    padding: 13px;
  }
  .nav-item span {
    font-size: 16px;
  }
  .sidebar-foot {
    display: none;
  }
  main {
    margin-left: 72px;
  }
  .topbar {
    padding: 18px 20px;
  }
  .view {
    padding: 20px;
  }
  .mode-pill {
    display: none;
  }
  .hero-card {
    padding: 25px;
    display: block;
  }
  .hero-status {
    text-align: left;
    margin-top: 22px;
  }
  .metrics {
    grid-template-columns: 1fr 1fr;
  }
  .topbar h1 {
    font-size: 20px;
  }
  .form-grid.two,
  .form-grid.three,
  .event-summary {
    grid-template-columns: 1fr;
  }
  .section-toolbar {
    align-items: flex-start;
    gap: 12px;
  }
  .toolbar-actions {
    flex-wrap: wrap;
    justify-content: flex-end;
  }
  .filter-row {
    flex-wrap: wrap;
  }
  .result-count {
    width: 100%;
    margin: 0;
  }
  .search {
    max-width: none;
  }
}
.event-item {
  border: 0;
  width: 100%;
  text-align: left;
  cursor: pointer;
  color: inherit;
}
@media (max-width: 760px) {
  .brand > div:last-child {
    display: none;
  }
  .nav-item {
    font-size: 0;
  }
  .nav-item span {
    font-size: 16px;
  }
}
.onboarding-panel {
  margin-bottom: 18px;
  padding: 25px 28px;
  background: linear-gradient(135deg, #fff, #f4f9ff);
  border: 1px solid #e2edf8;
}
.step-heading {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}
.step-heading > span,
.dialog-section-title > span {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  background: var(--blue);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 800;
  flex: 0 0 auto;
}
.step-heading h2 {
  font-size: 20px;
  margin: 0;
}
.step-heading p:not(.eyebrow),
.dialog-head p {
  margin: 3px 0 0;
  color: var(--muted);
}
.sku-entry-row {
  display: flex;
  gap: 10px;
  max-width: 760px;
  margin: 20px 0 13px 44px;
}
.sku-entry-row input {
  font-size: 16px;
  font-weight: 650;
  letter-spacing: 0.03em;
}
.sku-entry-row.compact {
  margin: 12px 0 10px;
  max-width: none;
}
.sku-entry-row.compact .btn {
  white-space: nowrap;
}
.entry-options {
  margin-left: 44px;
  display: flex;
  align-items: center;
  gap: 9px;
  flex-wrap: wrap;
}
.entry-options > span {
  font-size: 11px;
  color: var(--muted);
}
.target-toolbar {
  margin-top: 4px;
}
.target-toolbar strong {
  color: var(--ink);
}
.target-table {
  min-width: 1450px;
}
.product-cell {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 300px;
}
.product-cell img,
.product-placeholder {
  width: 56px;
  height: 56px;
  border: 1px solid #edf0f2;
  border-radius: 9px;
  object-fit: cover;
  flex: 0 0 auto;
  background: #fff;
}
.product-placeholder {
  display: grid;
  place-items: center;
  background: #fff0f0;
  color: #c73d3d;
  font-weight: 800;
}
.product-link {
  display: block;
  max-width: 300px;
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
}
.product-link:hover {
  color: var(--blue);
}
.row-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.enrich-action {
  color: #176cbf;
  background: #e8f2ff;
}
.danger-action {
  color: #b13c3c;
  background: #fff0f0;
}
.tag.draft {
  background: #fff2e7;
  color: #a85c20;
}
.dialog-section {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 18px;
  margin-top: 14px;
}
.dialog-section-title {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-bottom: 13px;
}
.dialog-section-title > span {
  width: 26px;
  height: 26px;
  border-radius: 7px;
}
.dialog-section-title strong,
.dialog-section-title small {
  display: block;
}
.dialog-section-title small {
  color: var(--muted);
  font-size: 10px;
}
.platform-preview {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #f7f9fb;
  border-radius: 8px;
  padding: 10px 12px;
  margin: 10px 0 14px;
}
.platform-preview p {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
}
.platform-preview:has(.parsed-product-card) {
  display: block;
  padding: 0;
  overflow: hidden;
  border: 1px solid #dbe6ef;
  background: #fff;
}
.parsed-product-card {
  display: grid;
  grid-template-columns: 126px minmax(0, 1fr);
  gap: 16px;
  padding: 14px;
}
.parsed-product-image {
  width: 126px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 10px;
  background: #f6f8fa;
  color: var(--muted);
  font-size: 11px;
}
.parsed-product-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #fff;
}
.parsed-product-body {
  min-width: 0;
}
.parsed-product-head {
  display: flex;
  align-items: center;
  gap: 9px;
}
.parsed-product-head small {
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.parsed-product-body h4 {
  margin: 10px 0 12px;
  font-size: 14px;
  line-height: 1.55;
}
.parsed-product-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.parsed-product-fields span {
  min-width: 0;
  padding: 8px 9px;
  border-radius: 8px;
  background: #f6f8fa;
}
.parsed-product-fields small,
.parsed-product-fields strong {
  display: block;
}
.parsed-product-fields small {
  color: var(--muted);
  font-size: 9px;
}
.parsed-product-fields strong {
  margin-top: 2px;
  font-size: 11px;
  line-height: 1.4;
  overflow-wrap: anywhere;
}
.parsed-product-body > a {
  display: inline-flex;
  margin-top: 10px;
  color: #176cbf;
  font-size: 11px;
  font-weight: 700;
  text-decoration: none;
}
.account-snapshots label {
  background: #f5f9ff;
  border-radius: 10px;
  padding: 12px;
}
.small-dialog {
  width: min(560px, calc(100vw - 32px));
}
.batch-note {
  background: #f5f8fb;
  border-radius: 9px;
  padding: 13px;
  margin-top: 15px;
}
.batch-note strong,
.batch-note span {
  display: block;
}
.batch-note span {
  font-size: 11px;
  color: var(--muted);
  margin-top: 3px;
}
@media (max-width: 760px) {
  .onboarding-panel {
    padding: 20px;
  }
  .sku-entry-row {
    margin: 17px 0 12px;
    display: grid;
  }
  .entry-options {
    margin-left: 0;
  }
  .target-toolbar {
    display: block;
  }
  .target-toolbar .btn {
    margin-top: 10px;
  }
  .dialog-section {
    padding: 14px;
  }
  .sku-entry-row.compact {
    display: grid;
  }
  .product-link {
    max-width: 220px;
  }
  .target-table {
    min-width: 0;
  }
  .target-table thead {
    display: none;
  }
  .target-table,
  .target-table tbody,
  .target-table tr,
  .target-table td {
    display: block;
    width: 100%;
  }
  .target-table tbody {
    padding: 12px;
    background: #f7f9fb;
  }
  .target-table tr {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 12px;
    margin-bottom: 12px;
    overflow: hidden;
    box-shadow: 0 3px 12px rgba(16, 39, 63, 0.05);
  }
  .target-table td {
    display: grid;
    grid-template-columns: 100px minmax(0, 1fr);
    gap: 8px;
    padding: 10px 12px;
    border-bottom: 1px solid #edf0f2;
  }
  .target-table td:before {
    content: attr(data-label);
    color: var(--muted);
    font-size: 10px;
    font-weight: 700;
  }
  .target-table td:first-child {
    display: block;
    padding: 14px;
  }
  .target-table td:first-child:before {
    display: none;
  }
  .target-table td:last-child {
    border-bottom: 0;
  }
  .target-table .product-cell {
    min-width: 0;
  }
  .target-table .row-actions {
    justify-content: flex-end;
  }
  .table-wrap {
    overflow: visible;
  }
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}
.collector-setup {
  padding: 27px 29px;
  margin-bottom: 18px;
}
.collector-intro {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}
.collector-intro .download-btn {
  white-space: nowrap;
  margin-top: 6px;
}
.install-steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-top: 23px;
}
.install-steps > div {
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 15px;
  background: #f9fbfc;
  min-height: 104px;
}
.install-steps b {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #dfeeff;
  color: #176cbf;
  font-size: 11px;
  margin-bottom: 9px;
}
.install-steps strong,
.install-steps span {
  display: block;
}
.install-steps span {
  color: var(--muted);
  font-size: 11px;
  margin-top: 3px;
}
.account-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
.account-card {
  padding: 21px;
}
.account-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.account-card h3 {
  font-size: 18px;
  margin: 7px 0 0;
}
.account-type-check {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 16px;
  padding: 10px 11px;
  border: 1px solid #e1e8ee;
  border-radius: 9px;
  background: #f7f9fb;
  font-size: 10px;
}
.account-type-check span {
  color: var(--muted);
}
.account-type-check span strong {
  color: var(--text);
}
.account-type-check i {
  color: #8fa0af;
  font-style: normal;
}
.account-type-check b {
  margin-left: auto;
  padding: 3px 7px;
  border-radius: 999px;
  background: #fff1dc;
  color: #9a611d;
  white-space: nowrap;
}
.account-type-check.matched {
  border-color: #cfeadf;
  background: #f1faf6;
}
.account-type-check.matched b {
  background: #dff4ea;
  color: #08745e;
}
.account-type-check.mismatch {
  border-color: #f1cece;
  background: #fff6f6;
}
.account-type-check.mismatch b {
  background: #ffe3e3;
  color: #b13c3c;
}
.account-detection-detail {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 10px;
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: 9px;
  background: #f6f9fc;
  color: #587085;
  font-size: 12px;
}
.account-detection-detail strong {
  color: #2d4960;
}
.account-detection-detail small {
  grid-column: 2;
  color: #8999a7;
}
.account-type {
  display: inline-flex;
  padding: 3px 8px;
  border-radius: 999px;
  font-size: 10px;
  background: #e7f2ff;
  color: #1f6db5;
}
.account-type.plus {
  background: #fff0d9;
  color: #966019;
}
.account-scope-panel {
  display: grid;
  grid-template-columns: minmax(260px, 0.72fr) minmax(520px, 1.28fr);
  gap: 24px;
  align-items: center;
  margin-bottom: 16px;
  border-left: 4px solid #1ebca9;
}
.account-scope-panel h2 {
  margin: 3px 0 7px;
  font-size: 19px;
}
.account-scope-panel p:not(.eyebrow) {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}
.account-scope-tabs {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 10px;
}
.account-scope-tab {
  border: 1px solid #dfe7ec;
  border-radius: 12px;
  background: #f8fafb;
  padding: 13px 14px;
  text-align: left;
  cursor: pointer;
  color: var(--ink);
  transition: .16s ease;
}
.account-scope-tab:hover {
  border-color: #9cc9dc;
  transform: translateY(-1px);
}
.account-scope-tab.active {
  border-color: #1ebca9;
  background: #edfbf8;
  box-shadow: 0 0 0 3px rgba(30, 188, 169, .08);
}
.account-scope-tab strong,
.account-scope-tab small {
  display: block;
}
.account-scope-tab strong {
  margin: 8px 0 4px;
  font-size: 14px;
}
.account-scope-tab small {
  color: var(--muted);
}
.account-scope-empty {
  padding: 18px;
  border: 1px dashed #e6b77f;
  border-radius: 10px;
  color: #9a6325;
  background: #fff8ed;
}
.product-owner-banner {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 5px 12px;
  align-items: center;
  margin: 0 0 16px;
  padding: 12px 14px;
  border: 1px solid #cde7e2;
  background: #f1fbf9;
  border-radius: 10px;
}
.product-owner-banner > span {
  grid-row: 1 / span 2;
  color: #6c7e88;
  font-size: 11px;
}
.product-owner-banner strong {
  display: flex;
  align-items: center;
  gap: 8px;
}
.product-owner-banner small {
  color: var(--muted);
}
.owner-account {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 6px;
  font-weight: 650;
}
.owner-account .account-type,
.product-owner-banner .account-type {
  font-style: normal;
  padding: 2px 6px;
}
.account-price {
  color: #172b3a;
}
.account-products-action {
  margin-right: auto;
  background: #e8f8f5;
  color: #087765;
}
.account-meta {
  display: grid;
  grid-template-columns: 1.1fr 1fr 0.9fr;
  gap: 12px;
  margin: 18px 0;
}
.account-meta > div {
  padding: 11px;
  background: #f7f9fb;
  border-radius: 8px;
  min-width: 0;
}
.account-meta span,
.account-meta strong {
  display: block;
}
.account-meta span {
  color: var(--muted);
  font-size: 9px;
}
.account-meta strong {
  font-size: 11px;
  margin-top: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.pairing-box {
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1px dashed #8ab5dc;
  background: #f2f8fd;
  border-radius: 10px;
  padding: 12px;
}
.pairing-box span {
  font-size: 10px;
  color: #5d7283;
}
.pairing-box strong {
  font-size: 22px;
  letter-spacing: 0.14em;
  color: #174c7b;
}
.pairing-box .table-action {
  margin-left: auto;
}
.account-actions {
  display: flex;
  justify-content: flex-end;
  gap: 7px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.account-error {
  margin: 10px 0 0;
  color: #a83c3c;
  background: #fff1f1;
  border-radius: 7px;
  padding: 8px 10px;
  font-size: 11px;
}
.account-empty {
  grid-column: 1/-1;
}
.security-note {
  margin-top: 16px;
  border-left: 4px solid var(--teal);
  display: flex;
  gap: 12px;
  align-items: center;
}
.security-note span {
  color: var(--muted);
}
.evidence-link {
  display: inline-flex;
  margin-top: 8px;
  color: var(--blue);
  font-size: 11px;
  text-decoration: none;
}
.evidence-link:hover {
  text-decoration: underline;
}
.schedule-status {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  background: #f5f9fd;
  border: 1px solid #deebf5;
  border-radius: 11px;
  padding: 14px 15px;
  margin-bottom: 14px;
}
.schedule-status strong,
.schedule-status span {
  display: block;
}
.schedule-status strong {
  margin-top: 7px;
  color: #29465e;
}
.schedule-status p {
  margin: 0;
  max-width: 52%;
  color: var(--muted);
  font-size: 11px;
}
.preset-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: end;
  margin-bottom: 8px;
}
.preset-row .btn {
  margin: 0;
  height: 41px;
}
.advanced-settings {
  margin-top: 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px 14px;
}
.advanced-settings summary {
  cursor: pointer;
  color: #49647a;
  font-weight: 700;
}
.advanced-settings .form-grid {
  margin-bottom: 7px;
}
.retry-hint {
  color: #a85c20 !important;
}
.retry-hint.running {
  color: #2175c9 !important;
  font-weight: 600;
}
@media (max-width: 760px) {
  .schedule-status {
    display: block;
  }
  .schedule-status p {
    max-width: none;
    margin-top: 9px;
  }
  .preset-row {
    grid-template-columns: 1fr;
  }
  .preset-row .btn {
    width: 100%;
  }
}
@media (max-width: 1050px) {
  .account-scope-panel {
    grid-template-columns: 1fr;
  }
  .install-steps {
    grid-template-columns: repeat(2, 1fr);
  }
  .account-grid {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 760px) {
  .account-scope-tabs {
    grid-template-columns: 1fr;
  }
  .product-owner-banner {
    grid-template-columns: 1fr;
  }
  .product-owner-banner > span {
    grid-row: auto;
  }
  .parsed-product-card {
    grid-template-columns: 86px minmax(0, 1fr);
    gap: 11px;
  }
  .parsed-product-image {
    width: 86px;
  }
  .parsed-product-fields {
    grid-template-columns: 1fr;
  }
  .account-type-check {
    align-items: flex-start;
    flex-wrap: wrap;
  }
  .account-type-check b {
    margin-left: 0;
  }
  .collector-setup {
    padding: 20px;
  }
  .collector-intro {
    display: block;
  }
  .collector-intro .download-btn {
    width: 100%;
    margin-top: 16px;
  }
  .install-steps {
    grid-template-columns: 1fr;
  }
  .account-toolbar {
    display: block;
  }
  .account-toolbar .btn {
    width: 100%;
    margin-top: 12px;
  }
  .account-meta {
    grid-template-columns: 1fr;
  }
  .pairing-box {
    flex-wrap: wrap;
  }
  .pairing-box .table-action {
    margin-left: 0;
  }
  .account-actions {
    flex-wrap: wrap;
  }
  .security-note {
    display: block;
  }
  .security-note span {
    display: block;
    margin-top: 4px;
  }
}

/* ---- 多地区对比 / 通知台账 / fan-out（0.9.0 新增） ---- */
.tag.danger { background: #fdeaea; color: #b83434; }
.region-compare { display: grid; gap: 16px; }
.region-card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.region-card-head strong { font-size: 15px; }
.region-card-head span { color: var(--muted); font-size: 13px; }
.region-spread { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 13px; }
.region-card .target-table th, .region-card .target-table td { padding: 8px 10px; }
tr.breach-row { background: #fdf3f3; }
.inline-check { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; color: var(--ink); }
.fanout-accounts { display: grid; gap: 8px; max-height: 260px; overflow: auto; margin: 10px 0; }
.fanout-account { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; }
.fanout-account small { display: block; color: var(--muted); margin-top: 2px; }

/* ---- 价格趋势(0.9.4 新增) ---- */
.trend-stats { display: flex; flex-wrap: wrap; gap: 10px; margin: 6px 0 14px; }
.trend-stat { flex: 1 1 90px; background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; }
.trend-stat span { display: block; color: var(--muted); font-size: 12px; }
.trend-stat strong { font-size: 16px; }
.trend-body { min-height: 240px; }
.trend-svg { width: 100%; height: auto; }
.trend-line { stroke: var(--blue); stroke-width: 2; }
.trend-approval { stroke: var(--orange); stroke-width: 1.5; stroke-dasharray: 5 4; }
.trend-dot { fill: var(--blue); }
.trend-dot.breach { fill: var(--red); }
.trend-axis { fill: var(--muted); font-size: 11px; }
