/* Company NED stats canvas stage — do not edit hashed site.vN.css */
.page-type-company-stats .company-hero--compact {
  background:
    radial-gradient(1200px 280px at 12% -20%, rgba(198, 161, 58, 0.16), transparent 60%),
    radial-gradient(900px 240px at 88% 0%, rgba(22, 132, 134, 0.18), transparent 55%);
}

.page-type-company-stats .stats-kpi-card {
  position: relative;
  overflow: hidden;
  border-radius: 14px;
  box-shadow: 0 8px 24px rgba(7, 91, 91, 0.06);
}
.page-type-company-stats .stats-kpi-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--gold, #c6a13a), #e8c872 45%, var(--jade-light, #168486));
}
.page-type-company-stats .stats-kpi-num {
  letter-spacing: -0.03em;
}

.stats-viz {
  --viz-ink: #e8f6f4;
  --viz-muted: rgba(232, 246, 244, 0.62);
  position: relative;
  margin: 0 0 24px;
  overflow: hidden;
  border-radius: 18px;
  color: var(--viz-ink);
  background:
    radial-gradient(80% 120% at 0% 0%, rgba(198, 161, 58, 0.16), transparent 46%),
    radial-gradient(70% 90% at 100% 100%, rgba(62, 207, 190, 0.12), transparent 42%),
    linear-gradient(165deg, #043536 0%, #075b5b 46%, #053c3e 100%);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.08) inset,
    0 22px 48px rgba(4, 53, 54, 0.28);
}
.stats-viz[hidden] {
  display: none !important;
}
.stats-viz:focus-visible {
  outline: 2px solid var(--gold, #c6a13a);
  outline-offset: 3px;
}

.stats-viz-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px 20px;
  padding: 18px 22px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.stats-viz-kicker {
  margin: 0 0 4px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold, #c6a13a);
}
.stats-viz-title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 650;
  letter-spacing: -0.01em;
}
.stats-viz-hint {
  margin: 4px 0 0;
  font-size: 0.8rem;
  color: var(--viz-muted);
}
.stats-viz-insight {
  margin: 6px 0 0;
  font-size: 0.82rem;
  color: #f0e0a8;
  font-variant-numeric: tabular-nums;
}

.stats-metric {
  display: inline-flex;
  padding: 3px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.stats-metric button {
  appearance: none;
  margin: 0;
  padding: 7px 14px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--viz-muted);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
}
.stats-metric button:hover {
  color: #fff;
}
.stats-metric button.is-on {
  background: linear-gradient(180deg, #d4b45a, var(--gold, #c6a13a));
  color: #fff;
  box-shadow: 0 4px 12px rgba(198, 161, 58, 0.28);
}

.stats-viz-stage {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(220px, 0.78fr);
  gap: 0;
  align-items: stretch;
  min-height: 0;
}
.stats-viz-canvas-wrap {
  position: relative;
  min-height: 280px;
  min-width: 0;
}
.stats-viz-canvas-wrap canvas {
  display: block;
  width: 100%;
  height: 100%;
  cursor: crosshair;
}
.stats-viz-legend {
  min-width: 0;
  min-height: 0;
  overflow: auto;
  padding: 12px 16px 18px 8px;
  border-left: 1px solid rgba(255, 255, 255, 0.08);
  scrollbar-width: thin;
  scrollbar-color: rgba(198, 161, 58, 0.45) transparent;
}
.stats-viz-legend ol {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 4px;
}
.stats-viz-legend li {
  display: grid;
  grid-template-columns: 10px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  padding: 7px 8px;
  border-radius: 8px;
  cursor: pointer;
}
.stats-viz-legend li:hover,
.stats-viz-legend li.is-hot {
  background: rgba(255, 255, 255, 0.07);
}
.stats-viz-swatch {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.08);
}
.stats-viz-lname {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.8rem;
}
.stats-viz-lval {
  font-size: 0.75rem;
  font-variant-numeric: tabular-nums;
  color: var(--viz-muted);
  white-space: nowrap;
}

.stats-viz-tip {
  position: absolute;
  z-index: 3;
  min-width: 160px;
  max-width: 260px;
  padding: 10px 12px;
  border-radius: 10px;
  pointer-events: none;
  color: #f4fffd;
  background: rgba(6, 28, 30, 0.92);
  border: 1px solid rgba(198, 161, 58, 0.35);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(8px);
  transform: translate(-8px, -110%);
}
.stats-viz-tip[hidden] {
  display: none !important;
}
.stats-viz-tip strong {
  display: block;
  font-size: 0.88rem;
  font-weight: 650;
  margin-bottom: 4px;
}
.stats-viz-tip span {
  display: block;
  font-size: 0.78rem;
  color: rgba(232, 246, 244, 0.78);
  font-variant-numeric: tabular-nums;
  line-height: 1.45;
  white-space: pre-line;
}

.page-type-company-stats .stats-hub:has(.stats-viz:not([hidden])) .stats-bars {
  display: none;
}
.page-type-company-stats .stats-table tr.is-hot td {
  background: #e7f4f2;
}
.page-type-company-stats .stats-panel {
  border-radius: 16px;
}

@media (max-width: 860px) {
  .stats-viz-stage {
    grid-template-columns: 1fr;
    min-height: 0;
  }
  .stats-viz-canvas-wrap {
    min-height: 340px;
    height: 360px;
  }
  .stats-viz-legend {
    max-height: 240px;
    border-left: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding: 10px 14px 16px;
  }
}

@media (max-width: 640px) {
  .stats-viz-head {
    padding: 14px 14px 10px;
  }
  .stats-viz-canvas-wrap {
    height: 300px;
    min-height: 300px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .stats-metric button.is-on {
    box-shadow: none;
  }
}

@media print {
  .stats-viz {
    display: none !important;
  }
  .page-type-company-stats .stats-hub:has(.stats-viz:not([hidden])) .stats-bars {
    display: grid;
  }
}
