.stats-hero .hero-panel {
  margin-bottom: 0.5rem;
}

.stats-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
  margin-bottom: 1.25rem;
  padding: 1rem;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  background: #fafbfc;
}

.stats-period {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.stats-chip {
  font: inherit;
  font-weight: 700;
  padding: 0.45rem 0.85rem;
  border: 1px solid var(--border-color);
  border-radius: 999px;
  background: #fff;
  cursor: pointer;
  color: var(--text-color);
}

.stats-chip:hover,
.stats-chip.is-active {
  border-color: var(--gradient-headline-start);
  color: var(--gradient-headline-start);
}

.stats-chip.is-active {
  background: rgba(207, 0, 85, 0.06);
}

.stats-filter {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.95rem;
}

.stats-filter select {
  font: inherit;
  padding: 0.45rem 0.65rem;
  border: 1px solid var(--border-color);
  border-radius: 6px;
  min-width: 160px;
}

.stats-error {
  color: var(--error-color);
  font-weight: 700;
  margin: 0 0 1rem;
}

.stats-kpis {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.stats-kpi-card {
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 1rem 1.1rem;
  background: #fff;
}

.stats-kpi-card h2 {
  margin: 0 0 0.35rem;
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-color-light);
}

.stats-kpi-value {
  margin: 0;
  font-size: 2rem;
  font-weight: 900;
  line-height: 1.1;
}

.stats-kpi-hint {
  margin: 0.35rem 0 0;
  font-size: 0.9rem;
  color: var(--text-color-light);
}

.stats-panel {
  margin-bottom: 2rem;
}

.stats-chart-hint {
  margin: -0.25rem 0 0.75rem;
  color: var(--text-color-light);
  font-size: 0.9rem;
}

.stats-bl-zero-summary {
  margin: -0.35rem 0 0.75rem;
  padding: 0.55rem 0.75rem;
  border-radius: 6px;
  background: rgba(207, 0, 85, 0.06);
  border: 1px solid rgba(207, 0, 85, 0.15);
  color: var(--text-color);
  font-size: 0.9rem;
}

.stats-chart {
  width: 100%;
  height: 320px;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  background: #fff;
}

.stats-chart-tall {
  height: 520px;
}

.stats-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border-color);
  border-radius: 8px;
}

.stats-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.stats-table th,
.stats-table td {
  padding: 0.65rem 0.85rem;
  border-bottom: 1px solid #eee;
  text-align: left;
}

.stats-table th {
  background: #fafbfc;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--text-color-light);
}

.stats-quality {
  margin-bottom: 3rem;
  padding: 1.25rem;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  background: #fafbfc;
}

.stats-quality-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.75rem 1.5rem;
  margin: 0 0 1rem;
}

.stats-quality-list div {
  margin: 0;
}

.stats-quality-list dt {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-color-light);
  margin-bottom: 0.15rem;
}

.stats-quality-list dd {
  margin: 0;
  font-weight: 700;
}

.stats-disclaimer {
  margin: 0;
  font-size: 0.9rem;
  color: var(--text-color-light);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 700px) {
  .stats-chart-tall {
    height: 420px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .stats-chip {
    transition: none;
  }
}
