/* dmarcboard app — threats module styles (uses tokens.css variables). */
.thr { --thr-compliant: var(--chart-pass); --thr-forwarded: #3b82f6; --thr-non_compliant: #d97706; --thr-threat: var(--chart-fail); --thr-blocked: #94a3b8; }
.thr-top { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); }
.thr-verdict-fail { border-top-color: var(--chart-fail); }

/* score */
.thr-score > * + * { margin-top: 12px; }
.thr-score-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; }
.thr-score-val { display: flex; align-items: baseline; gap: 2px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.thr-score-n { font-size: 40px; font-weight: 700; letter-spacing: -0.03em; line-height: 1; }
.thr-score-of { font-size: 16px; font-weight: 600; color: var(--subtle-fg); }
.thr-score-pass .thr-score-n { color: var(--pass); }
.thr-score-warn .thr-score-n { color: var(--warn); }
.thr-score-fail .thr-score-n { color: var(--fail); }
.thr-score .meter { height: 8px; }
.thr-factors { list-style: none; margin: 12px 0 0; padding: 0; font-size: 13.5px; }
.thr-factors li { display: flex; gap: 10px; align-items: baseline; padding: 6px 0; border-top: 1px solid var(--border); }
.thr-factor-imp { flex: none; min-width: 38px; text-align: center; font-weight: 700; font-variant-numeric: tabular-nums; color: var(--fail); background: var(--fail-bg); border-radius: 6px; padding: 0 6px; font-size: 12.5px; }
.thr-factor-ok { display: flex; gap: 8px; align-items: center; color: var(--pass); font-size: 14px; }

/* classification */
.thr-split { display: flex; height: 14px; border-radius: 99px; overflow: hidden; background: #e8ebf3; margin-top: 14px; }
.thr-seg { display: block; height: 100%; min-width: 3px; }
.thr-seg + .thr-seg { border-left: 2px solid #fff; }
.thr-seg-compliant, .thr-sw-compliant { background: var(--thr-compliant); }
.thr-seg-forwarded, .thr-sw-forwarded { background: var(--thr-forwarded); }
.thr-seg-non_compliant, .thr-sw-non_compliant { background: var(--thr-non_compliant); }
.thr-seg-threat, .thr-sw-threat { background: var(--thr-threat); }
.thr-classes { list-style: none; margin: 16px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.thr-class { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.thr-class-head { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.thr-class-n { margin-left: auto; font-weight: 650; font-variant-numeric: tabular-nums; }

/* chart */
.swatch.thr-c-delivered, .chart-svg .bar.thr-c-delivered { background: var(--chart-fail); fill: var(--chart-fail); }
.swatch.thr-c-blocked, .chart-svg .bar.thr-c-blocked { background: var(--thr-blocked); fill: var(--thr-blocked); }

/* map */
.thr-geo { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); align-items: start; }
.thr-geo-map { padding: 18px 20px 18px 24px; border-right: 1px solid var(--border); }
.thr-map { display: block; width: 100%; height: auto; }
.thr-map-land { fill: none; stroke: #cfd6e4; stroke-width: 6.2; stroke-linecap: round; }
.thr-map-halo { fill: var(--chart-fail); fill-opacity: .16; stroke: var(--chart-fail); stroke-opacity: .35; stroke-width: 1.5; }
.thr-map-dot { fill: var(--chart-fail); stroke: #fff; stroke-width: 2; }
.thr-map-pt:hover .thr-map-halo { fill-opacity: .3; }
.thr-geo-table .table th:first-child, .thr-geo-table .table td:first-child { padding-left: 16px; }
.thr-geo-more { padding: 8px 16px 14px; }
.thr-rank { display: inline-block; min-width: 18px; color: var(--subtle-fg); font-size: 12px; font-variant-numeric: tabular-nums; }
.thr-cc { display: inline-block; margin-right: 7px; padding: 0 5px; border-radius: 4px; background: var(--neutral-bg); color: var(--muted-fg); font: 600 11px/18px var(--mono); vertical-align: 1px; }

/* reputation */
.thr-rep-notes { border-bottom: 1px solid var(--border); }
.thr-filters { padding-top: 14px; padding-bottom: 12px; }
.thr-ips td { vertical-align: top; }
.thr-ips td:first-child { min-width: 150px; }
.thr-sub { display: block; margin-top: 2px; }
.thr-net { display: block; font-weight: 500; }
.thr-ips .muted.small:not(.show-sm-only) { display: block; }
.thr-ips .thr-cc + * { display: inline; }
.thr-bls { display: inline-flex; flex-wrap: wrap; gap: 4px; }
.thr-bl { display: inline-block; padding: 1px 7px; border-radius: 6px; font-size: 12px; font-weight: 600; line-height: 18px; white-space: nowrap; border: 1px solid; }
.thr-bl-critical { color: var(--fail); background: var(--fail-bg); border-color: var(--fail-bd); }
.thr-bl-warning { color: var(--warn); background: var(--warn-bg); border-color: var(--warn-bd); }
.thr-bl-expected, .thr-bl-info { color: var(--neutral); background: var(--neutral-bg); border-color: #e2e8f0; }
.thr-bl-clean { display: inline-flex; align-items: center; gap: 4px; color: var(--pass); font-size: 13px; }
.thr-sm-bl { margin-top: 4px; }
.thr-risk-note { display: block; margin-top: 4px; color: var(--fail); }
.thr-row-critical > td { background: #fff8f8; }
.thr-more { padding-top: 10px; padding-bottom: 14px; border-top: 1px solid var(--border); }

/* lookalikes */
.thr-look td { vertical-align: top; }
.thr-new { margin-left: 8px; vertical-align: 1px; }
.thr-dns { display: flex; flex-direction: column; gap: 2px; font-family: var(--mono); font-size: 12px; color: var(--muted-fg); overflow-wrap: anywhere; }
.thr-dns b { color: var(--subtle-fg); font-weight: 600; }

@media (max-width: 1100px) {
  .thr-top { grid-template-columns: minmax(0, 1fr); }
  .thr-geo { grid-template-columns: minmax(0, 1fr); }
  .thr-geo-map { border-right: 0; border-bottom: 1px solid var(--border); }
}
@media (max-width: 900px) {
  .thr-classes { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .thr-classes { grid-template-columns: minmax(0, 1fr); }
  .thr-geo-map { padding: 12px; }
  .thr-score-n { font-size: 34px; }
  .thr-ips td:first-child { min-width: 0; }
}
