.report-topline {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr) max-content;
  align-items: center;
  gap: 8px 14px;
  margin-bottom: 13px;
}

.report-heading { min-width: 0; }
.report-heading h1 { font-size: 22px; line-height: 1.25; letter-spacing: -.025em; overflow-wrap: anywhere; }
.report-heading p { margin-top: 2px; color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }
.report-navigation { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 6px; min-width: 0; }
.report-topline .button { min-height: 32px; padding: 5px 8px; border-radius: 6px; font-size: 12px; }
.report-topline .back-button { margin: 0; white-space: nowrap; }

#report-pager {
  display: inline-flex;
  flex-wrap: nowrap;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
}

#report-pager .button { width: 31px; min-height: 30px; padding: 0; border: 0; font-size: 17px; }
#report-position { min-width: 54px; padding-inline: 4px; color: var(--muted); text-align: center; font-size: 12px; white-space: nowrap; }
#report-content { display: grid; gap: 14px; min-width: 0; }

.report-overview,
.report-main-primary,
.report-main-side,
.report-main-aside,
.report-main-history,
.report-main-geography,
.report-evidence { min-width: 0; }

.report-overview {
  display: grid;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--surface);
}

.report-overview-has-ingress { grid-template-columns: minmax(0, .68fr) minmax(0, 1.32fr); }
.report-ingress {
  display: grid;
  align-content: center;
  gap: 2px;
  min-width: 0;
  padding: 8px 14px;
  border-inline-end: 1px solid var(--line);
}
.report-routes, .report-ingress-line { min-width: 0; }
.report-routes { display: grid; align-content: center; }
.report-ingress-line { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 7px; }
.report-ingress-note, .report-ingress-endpoint, .report-ingress-candidates { color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }
.report-ingress-details { color: var(--muted); font-size: 12px; }
.report-ingress-details > summary { width: fit-content; }
.report-ingress-comparison { display: flex; flex-wrap: wrap; gap: 2px 7px; color: var(--accent); font-size: 12px; font-weight: 650; }
.report-ingress-comparison[data-known="false"] { color: var(--muted); font-weight: 400; }
.report-overview-has-ingress:has(.report-routes:empty) { grid-template-columns: minmax(0, 1fr); }
.report-overview-has-ingress:has(.report-routes:empty) .report-ingress { border-inline-end: 0; }

.report-route {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  align-items: center;
  gap: 8px 18px;
  min-width: 0;
  padding: 9px 14px;
}

.report-route + .report-route { border-top: 1px solid var(--line); }
.report-route-identity { display: grid; grid-template-columns: max-content minmax(0, 1fr); align-items: baseline; gap: 2px 9px; min-width: 0; }
.report-family { color: var(--muted); font-size: 12px; font-weight: 650; white-space: nowrap; }
.report-address { color: var(--text); font-size: 17px; font-variant-numeric: tabular-nums; font-weight: 700; overflow-wrap: anywhere; }
.report-address[data-tone="warn"] { color: var(--warn); font: 650 14px/1.35 Inter, "Segoe UI", system-ui, sans-serif; }
.report-network { grid-column: 2; min-width: 0; color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }
.report-egress-readings { display: grid; grid-column: 2; gap: 2px; min-width: 0; margin: 0; }
.report-egress-readings > div { display: grid; grid-template-columns: 68px minmax(0, 1fr); align-items: baseline; gap: 3px 7px; font-size: 12px; }
.report-egress-readings dt { color: var(--muted); overflow-wrap: anywhere; }
.report-egress-readings dd { margin: 0; }
.report-route-speed { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); min-width: 0; gap: 12px; margin: 0; }
.report-route-speed > * { min-width: 0; padding-inline-start: 12px; border-inline-start: 1px solid var(--line); }
.report-metric-label { display: block; color: var(--muted); font-size: 12px; }
.report-metric-value { display: inline; margin: 0; font-size: 18px; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1.2; }
.report-metric-unit { margin-inline-start: 4px; color: var(--muted); font-size: 12px; white-space: nowrap; }
.report-metric-missing { color: var(--muted); font-size: 13px; }

.report-main { display: grid; grid-template-columns: minmax(0, 1fr); align-items: start; gap: 14px; min-width: 0; }
.report-main-side { display: contents; }
.report-main-primary, .report-main-aside, .report-main-geography { display: grid; align-content: start; gap: 10px; }
.report-main-aside { grid-row: 1; }
.report-main-primary { grid-row: 2; }
.report-main-history { grid-row: 3; }
.report-main-geography { grid-row: 4; }

.report-aside-card {
  min-width: 0;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--surface);
  color: var(--text);
  font-size: 12px;
}

.report-aside-card :is(h2, h3) { margin: 0 0 6px; font-size: 14px; line-height: 1.35; letter-spacing: -.012em; }
.report-aside-card .report-aside-family { margin-top: 8px; color: var(--muted); font-size: 12px; }
.report-aside-card:has(.report-geo-summary) { display: grid; grid-template-columns: minmax(0, 1fr) max-content; gap: 4px 8px; }
.report-aside-card:has(.report-geo-summary) h2 { margin-bottom: 0; }
.report-aside-card:has(.report-geo-summary) .report-aside-link { grid-column: 2; grid-row: 1; margin-top: 0; }
.report-aside-note { color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }
.report-aside-card .report-aside-note + .report-aside-note { margin-top: 4px; }
.report-facts { display: grid; gap: 0; margin: 0; }
.report-facts > div { display: grid; grid-template-columns: minmax(80px, 1fr) minmax(0, 1fr); align-items: baseline; gap: 8px; padding-block: 4px; }
.report-facts > div + div { border-top: 1px solid var(--line); }
.report-facts dt { color: var(--muted); overflow-wrap: anywhere; }
.report-facts dd { margin: 0; color: var(--text); font-weight: 650; text-align: right; overflow-wrap: anywhere; }
.report-facts dd .report-result { justify-content: flex-end; }
.report-facts + .report-aside-note { margin-top: 5px; }
.report-facts [data-tone="ok"], .report-metric-value[data-tone="ok"] { color: var(--ok); }
.report-facts [data-tone="warn"], .report-metric-value[data-tone="warn"] { color: var(--warn); }
.report-facts [data-tone="bad"], .report-metric-value[data-tone="bad"] { color: var(--bad); }
.report-facts [data-tone="muted"], .report-metric-value[data-tone="muted"] { color: var(--muted); }

.report-geo-summary { display: flex; grid-column: 1 / -1; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; color: var(--muted); font-size: 12px; }
.report-geo-line { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 7px; }
.report-geo-summary strong { color: var(--text); font-weight: 650; }
.report-geo-readings { display: flex; flex-wrap: wrap; gap: 3px 9px; }
.report-country { display: inline-flex; align-items: center; gap: 5px; }
.report-flag {
  display: inline-block;
  flex: none;
  width: 16px;
  height: 12px;
  border-radius: 2px;
  background: url("/report-flags.png") no-repeat;
  background-size: 416px 312px;
  box-shadow: 0 0 0 1px var(--border);
}
.report-aside-link { display: inline-block; margin-top: 5px; text-underline-offset: 2px; }
.report-history-table { width: 100%; border-collapse: collapse; text-align: left; }
.report-history-table th, .report-history-table td { padding: 4px 0; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
.report-history-table :is(th, td) + :is(th, td) { padding-inline-start: 8px; }
.report-history-table th { color: var(--muted); font-weight: 600; }
.report-history-table tr:last-child td { border-bottom: 0; }
.report-history-table + .report-aside-note { margin-top: 5px; }

.report-evidence { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 350px), 1fr)); align-items: start; gap: 10px 14px; }
.report-evidence-title, .report-evidence-wide { grid-column: 1 / -1; }
.report-evidence-title { font-size: 16px; }
.report-section {
  min-width: 0;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--surface);
}

.report-section-heading {
  display: flex;
  align-items: baseline;
  gap: 5px 9px;
  padding: 9px 12px;
}

.report-section-heading h2 {
  font-size: 15px;
  line-height: 1.35;
  letter-spacing: -.016em;
}

.report-section-count {
  color: var(--muted);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.report-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 9px;
  padding: 0 12px 9px;
}

.report-toolbar .report-search { flex: 1 1 125px; min-height: 32px; max-width: 190px; padding-inline: 8px; font-size: 12px; }
.report-toolbar .report-search input { padding-block: 5px; }
.report-metric-note { margin-inline-start: auto; color: var(--muted); font-size: 12px; }

.report-sort {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--muted);
  font-size: 12px;
}

.report-sort select {
  min-height: 32px;
  max-width: 100%;
  padding: 3px 7px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: var(--surface);
  color: var(--text);
}

.report-table-wrap {
  min-width: 0;
  overflow: auto;
  border-top: 1px solid var(--line);
  border-radius: 0 0 8px 8px;
}

.report-table-wrap:focus-visible {
  outline-offset: -2px;
}

.report-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  color: var(--text);
  text-align: left;
  font-size: 13px;
}

.report-service-table[data-family-count="2"] {
  min-width: 660px;
}

.report-table th, .report-table td {
  padding: 5px 8px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}

.report-table th:first-child, .report-table td:first-child {
  padding-inline-start: 12px;
}

.report-table tbody tr:last-child > *,
.report-table tbody .report-result-row:has(+ .report-diagnostics:last-child[hidden]) > * { border-bottom: 0; }

.report-table thead th {
  background: var(--surface-raised);
  color: var(--muted);
  font-size: 12px;
  font-weight: 650;
}

.report-table .report-check-column { width: 33%; }
.report-main-geography .report-check-column { width: 49%; }
.report-main-geography .report-evidence-cell,
.report-main-geography .report-evidence-column { width: 31px; }
.report-table .report-region-column, .report-table .report-region-cell { width: 20%; }
.report-region-value { display: inline-flex; flex-wrap: wrap; align-items: baseline; gap: 3px 5px; }
.report-region-value + .report-region-value { margin-inline-start: 8px; }
.report-region-code { font-weight: 650; white-space: nowrap; }
.report-service-scope { color: var(--muted); font-size: 12px; font-weight: 400; line-height: 1.3; }
.report-aux-count { display: block; color: var(--warn); font-size: 12px; font-weight: 600; line-height: 1.3; }
.report-aux-count[data-tone="ok"] { color: var(--muted); font-weight: 400; }
.report-table .report-service-subcheck > th { padding-inline-start: 17px; }
.report-service-subcheck > * { background: var(--surface-raised); }

.report-table .report-family-column {
  color: var(--text);
}

.report-table .report-measurement-column,
.report-table .report-latency-cell {
  width: 67px;
  text-align: right;
  white-space: nowrap;
}

.report-table .report-evidence-cell,
.report-table .report-evidence-column {
  width: 40px;
  padding-inline: 3px 6px;
  text-align: right;
}

.report-table tbody th {
  background: transparent;
  color: var(--text);
  font-weight: 600;
  overflow-wrap: anywhere;
}

.report-table tbody td { overflow-wrap: anywhere; }

.report-table .report-result-row:hover th,
.report-table .report-result-row:hover td {
  background: var(--surface-hover);
}

.report-result {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 2px 6px;
  min-width: 0;
}

.report-value {
  font-weight: 650;
  overflow-wrap: anywhere;
}

.report-status {
  display: inline-flex;
  align-items: baseline;
  gap: 5px;
  color: var(--muted);
  font-size: 12px;
}

.report-status::before {
  content: "";
  width: 5px;
  height: 5px;
  flex: 0 0 5px;
  border-radius: 50%;
  background: currentColor;
}

.report-status[data-tone="ok"] { color: var(--ok); }
.report-status[data-tone="warn"] { color: var(--warn); }
.report-status[data-tone="bad"] { color: var(--bad); }

.report-http, .report-attempts {
  color: var(--muted);
  font-size: 11px;
  white-space: nowrap;
}

.report-http {
  padding: 1px 4px;
  border: 1px solid var(--line);
  border-radius: 4px;
}

.report-latency {
  display: inline-block;
  min-width: 38px;
  padding: 2px 5px;
  border: 1px solid transparent;
  border-radius: 5px;
  color: var(--text);
  font-size: 12px;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
  line-height: 1.25;
  text-align: right;
  white-space: nowrap;
}

.report-latency[data-latency="ok"] {
  border-color: var(--ok-border, transparent);
  background: var(--ok-bg, var(--surface-raised));
  color: var(--ok);
}

.report-latency[data-latency="warn"] {
  border-color: var(--warn-border, transparent);
  background: var(--warn-bg, var(--surface-raised));
  color: var(--warn);
}

.report-latency[data-latency="bad"] {
  border-color: var(--bad-border, transparent);
  background: var(--bad-bg, var(--surface-raised));
  color: var(--bad);
}

.report-no-value {
  color: var(--muted);
}

.report-row-toggle {
  display: inline-grid;
  width: 28px;
  height: 25px;
  place-items: center;
  padding: 0;
  border: 1px solid transparent;
  border-radius: 5px;
  background: transparent;
  color: var(--muted);
}

.report-row-toggle span {
  width: 7px;
  height: 7px;
  border-right: 1.5px solid;
  border-bottom: 1.5px solid;
  transform: translateY(-2px) rotate(45deg);
}

.report-row-toggle:hover,
.report-row-toggle[aria-expanded="true"] {
  border-color: var(--accent-border, var(--border));
  background: var(--accent-bg, var(--surface-raised));
  color: var(--accent);
}

.report-row-toggle[aria-expanded="true"] span {
  transform: translateY(2px) rotate(225deg);
}

.report-table .report-diagnostics td {
  padding: 10px 12px 12px;
  background: var(--surface-raised);
}

.report-diagnostics-inner {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 242px), 1fr));
  gap: 10px 18px;
}

.report-diagnostic-family h3 {
  margin: 0 0 8px;
  font-size: 12px;
}

.report-diagnostic-fields {
  display: grid;
  grid-template-columns: minmax(80px, max-content) minmax(0, 1fr);
  gap: 3px 8px;
  margin: 0;
  font-size: 12px;
}

.report-diagnostic-fields dt { color: var(--muted); }
.report-diagnostic-fields dd { margin: 0; overflow-wrap: anywhere; }
.report-related-checks { display: grid; gap: 8px; margin-top: 9px; }
.report-related-checks > section { padding-top: 8px; border-top: 1px solid var(--line); }
.report-related-checks h3 { margin: 0 0 5px; font-size: 13px; }
.report-related-result { margin-bottom: 5px; color: var(--muted); font-size: 12px; }

.report-empty, #report-content > .empty-state {
  padding: 12px;
  color: var(--muted);
}

@media (min-width: 1120px) {
  .report-main { grid-template-columns: minmax(0, 2.25fr) minmax(260px, 1fr); }
  .report-main-side { display: grid; align-content: start; grid-row: 1; grid-column: 2; gap: 10px; }
  .report-main-side > * { grid-row: auto; }
  .report-main-primary { grid-row: 1; grid-column: 1; }
}

@media (min-width: 660px) and (max-width: 1119px) {
  .report-main-aside { grid-template-columns: repeat(auto-fit, minmax(min(100%, 195px), 1fr)); }
  .report-main-geography { grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); }
}

@media (max-width: 980px) {
  .report-topline { grid-template-columns: max-content minmax(0, 1fr); }
  .report-heading { grid-column: 1 / -1; grid-row: 2; }
  .report-overview-has-ingress { grid-template-columns: minmax(0, 1fr); }
  .report-ingress { border-inline-end: 0; border-block-end: 1px solid var(--line); }
  .report-overview-has-ingress:has(.report-routes:empty) .report-ingress { border-block-end: 0; }
}

@media (max-width: 650px) {
  .workspace:has([data-panel="report"]:not([hidden])) { padding-top: 12px; }
  #report-content, .report-main, .report-main-aside { gap: 8px; }
  .report-heading h1 { font-size: 19px; }
  .report-topline { gap: 6px; margin-bottom: 9px; }
  .report-navigation { gap: 4px; }
  .report-topline .button { gap: 4px; padding-inline: 5px; }
  #report-pager .button { width: 25px; }
  #report-position { min-width: 45px; }
  .report-route { grid-template-columns: minmax(0, 1fr); gap: 5px; padding: 7px 9px; }
  .report-egress-readings { grid-column: 1 / -1; }
  .report-ingress { padding: 6px 9px; }
  .report-route-speed { gap: 6px; padding-top: 4px; border-top: 1px solid var(--line); }
  .report-route-speed > * { padding-inline-start: 0; border-inline-start: 0; }
  .report-metric-value { font-size: 16px; }
  .report-metric-missing { font-size: 12px; }
  .report-aside-card { padding: 7px 9px; }
  .report-aside-card :is(h2, h3) { margin-bottom: 4px; }
  .report-facts > div { padding-block: 3px; }
  .report-section-heading { padding: 7px 9px; }
  .report-toolbar { padding-inline: 9px; }
  .report-toolbar .report-search { flex-basis: 112px; max-width: 100%; }
  .report-metric-note { margin-inline-start: auto; }
  .report-service-table[data-family-count="2"] { min-width: 590px; }
  .report-table th, .report-table td { padding: 5px; }
  .report-table th:first-child, .report-table td:first-child { padding-inline-start: 8px; }
  .report-table .report-measurement-column, .report-table .report-latency-cell { width: 50px; }
  .report-table .report-evidence-cell, .report-table .report-evidence-column { width: 31px; padding-inline-end: 4px; }
  .report-row-toggle { width: 25px; height: 32px; }
  .report-latency { min-width: 31px; padding-inline: 3px; }
}

@media (max-width: 430px) {
  .report-topline .back-button { justify-self: start; }
  .report-service-table .report-region-column, .report-service-table .report-region-cell { width: auto; }
  .report-sort > span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
}

@media (max-width: 325px) {
  .report-aside-card:has(.report-geo-summary) { grid-template-columns: minmax(0, 1fr); }
  .report-aside-card:has(.report-geo-summary) .report-aside-link { grid-column: 1; grid-row: auto; }
}
