/* Police Shootings of Dogs — tracker stylesheet.
   For jnix.netlify.app. Reuses the site's theme variables
   (--article-bg-color, --text-muted, --heading-color, --border-color) so it
   follows the same light/dark behavior as the rest of the site. Mirrors
   mpv-dashboard.css with a dst- prefix. */

.dst-container {
  margin-top: 2rem;
}

.dst-loading,
.dst-error {
  text-align: center;
  padding: 3rem;
  color: var(--text-muted, #666);
}

.dst-error {
  color: #c62828;
}

.dst-meta {
  font-size: 0.85rem;
  color: var(--text-muted, #666);
  margin-bottom: 1.5rem;
}

.dst-meta a {
  color: #1565c0;
}

/* Stat tiles */
.dst-stats-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

.dst-stat-tile {
  background: var(--article-bg-color, #f8f9fa);
  border: 1px solid var(--border-color, #e0e0e0);
  border-radius: 8px;
  padding: 1.25rem;
  text-align: center;
}

.dst-stat-value {
  font-size: 2rem;
  font-weight: 700;
  color: var(--heading-color, #1a1a1a);
  line-height: 1.2;
}

.dst-stat-label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--text-muted, #666);
  margin-top: 0.25rem;
}

.dst-stat-delta {
  font-size: 0.8rem;
  font-weight: 600;
  margin-top: 0.35rem;
}

/* More incidents this year than last reads as a worsening trend. */
.dst-stat-delta.up {
  color: #c62828;
}

.dst-stat-delta.down {
  color: #2e7d32;
}

/* Chart grid */
.dst-chart-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

@media (min-width: 900px) {
  .dst-chart-grid.dst-two-col {
    grid-template-columns: 1fr 1fr;
  }
}

.dst-chart-card {
  background: var(--article-bg-color, #fff);
  border: 1px solid var(--border-color, #e0e0e0);
  border-radius: 8px;
  padding: 1.25rem;
}

.dst-chart-title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--heading-color, #1a1a1a);
  margin: 0 0 0.75rem 0;
}

.dst-chart {
  width: 100%;
  min-height: 320px;
}

#dst-chart-states {
  min-height: 480px;
}

.dst-chart-note {
  font-size: 0.75rem;
  color: var(--text-muted, #666);
  margin: 0.5rem 0 0 0;
}

.dst-empty {
  text-align: center;
  padding: 2.5rem 1.25rem;
  color: var(--text-muted, #666);
  background: var(--article-bg-color, #f8f9fa);
  border: 1px solid var(--border-color, #e0e0e0);
  border-radius: 8px;
}

/* Recent incidents list */
.dst-incident-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.dst-incident {
  padding: 1rem 0;
  border-bottom: 1px solid var(--border-color, #e0e0e0);
}

.dst-incident:last-child {
  border-bottom: none;
}

.dst-incident-head {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.dst-incident-loc {
  font-weight: 600;
  color: var(--heading-color, #1a1a1a);
}

.dst-incident-date {
  font-size: 0.85rem;
  color: var(--text-muted, #666);
  white-space: nowrap;
}

.dst-incident-agency {
  font-size: 0.85rem;
  color: var(--text-muted, #666);
  margin-top: 0.15rem;
}

.dst-incident-summary {
  font-size: 0.9rem;
  line-height: 1.5;
  margin: 0.5rem 0 0 0;
}

.dst-incident-tags {
  margin-top: 0.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.dst-tag {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 0.15rem 0.45rem;
  border-radius: 4px;
  background: rgba(21, 101, 192, 0.10);
  color: #1565c0;
}

.dst-tag-pending {
  background: rgba(198, 40, 40, 0.10);
  color: #c62828;
  vertical-align: middle;
  margin-left: 0.4rem;
}

.dst-incident-sources {
  margin-top: 0.5rem;
  font-size: 0.8rem;
}

.dst-incident-sources a {
  color: #1565c0;
}

.dst-notes {
  font-size: 0.85rem;
  line-height: 1.6;
  color: var(--text-muted, #666);
  border-top: 1px solid var(--border-color, #e0e0e0);
  margin-top: 1rem;
  padding-top: 1.25rem;
}

.dst-notes h3 {
  font-size: 0.95rem;
  color: var(--heading-color, #1a1a1a);
  margin: 0 0 0.5rem 0;
}

@media (max-width: 480px) {
  .dst-stat-value {
    font-size: 1.5rem;
  }
}
