/* Gedeelde stijlen voor alle DataRadar dashboards */

/* ── Breadcrumb nav (extra niveau boven basis navbar) ── */
.nav-active-name.linked {
  font-weight: 600;
  color: rgba(255,255,255,0.75);
  text-decoration: none;
  transition: color 0.15s;
}
.nav-active-name.linked:hover { color: #fff; }

.nav-current {
  font-weight: 700;
  font-size: 0.95rem;
  color: #fff;
  white-space: nowrap;
}

/* ── Dashboard page header ── */
.dash-header {
  background: linear-gradient(135deg, var(--primary-color) 0%, #1e3a6e 100%);
  color: white;
  padding: 40px 24px 36px;
}

.dash-header-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.dash-header-left h1 {
  color: #fff;
  font-size: clamp(1.4rem, 3vw, 2rem);
  margin-bottom: 6px;
}

.dash-header-left p {
  color: rgba(255,255,255,0.75);
  font-size: 0.9rem;
  max-width: 520px;
  line-height: 1.5;
}

.dash-header-meta {
  display: flex;
  gap: 10px;
  margin-top: 14px;
  flex-wrap: wrap;
}

.dash-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 14px;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.2);
  color: rgba(255,255,255,0.85);
}

.dash-badge.live { background: rgba(16,185,129,0.2); border-color: rgba(16,185,129,0.4); color: #6ee7b7; }

.dash-header-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}

.dash-update-info {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.55);
  text-align: right;
}

.dash-back-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 0.82rem;
  font-weight: 600;
  color: rgba(255,255,255,0.75);
  text-decoration: none;
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 6px;
  padding: 6px 14px;
  transition: all 0.18s;
}

.dash-back-btn:hover {
  background: rgba(255,255,255,0.08);
  color: #fff;
  border-color: rgba(255,255,255,0.4);
}

/* ── Main content wrapper ── */
.dash-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 36px 24px 60px;
}

/* ── KPI Cards ── */
.kpi-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 32px;
}

.kpi-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  border: 1.5px solid var(--border);
  padding: 20px 22px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.kpi-label {
  font-size: 0.76rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
}

.kpi-value {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--primary-color);
  line-height: 1.15;
}

.kpi-sub {
  font-size: 0.78rem;
  color: var(--text-light);
  margin-top: 2px;
}

.kpi-delta {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 0.78rem;
  font-weight: 600;
  margin-top: 4px;
}
.kpi-delta.up   { color: #059669; }
.kpi-delta.down { color: #dc2626; }

/* ── Chart cards ── */
.charts-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-bottom: 24px;
}

.charts-grid.single { grid-template-columns: 1fr; }
.charts-grid.triple { grid-template-columns: repeat(3, 1fr); }

@media (max-width: 900px) {
  .charts-grid,
  .charts-grid.triple { grid-template-columns: 1fr; }
}

.chart-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  border: 1.5px solid var(--border);
  padding: 22px 22px 18px;
  display: flex;
  flex-direction: column;
}

.chart-card.wide { grid-column: 1 / -1; }

.chart-card-title {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--primary-color);
  margin-bottom: 4px;
}

.chart-card-sub {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.chart-area {
  position: relative;
  flex: 1;
  min-height: 220px;
}

/* ── Loading skeleton ── */
.skeleton {
  background: linear-gradient(90deg, #f0f4f8 25%, #e4eaf2 50%, #f0f4f8 75%);
  background-size: 200% 100%;
  animation: shimmer 1.4s infinite;
  border-radius: 6px;
}

@keyframes shimmer {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.skeleton-kpi {
  height: 80px;
  border-radius: var(--radius);
}

.skeleton-chart {
  height: 260px;
  border-radius: var(--radius);
}

/* ── Error state ── */
.error-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  color: var(--text-muted);
  gap: 10px;
  text-align: center;
}

.error-state i { font-size: 2rem; color: #fca5a5; }
.error-state p { font-size: 0.86rem; }

/* ── Data tabel ── */
.data-table-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  border: 1.5px solid var(--border);
  overflow: hidden;
  margin-top: 20px;
}

.data-table-header {
  padding: 16px 22px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.data-table-header h3 {
  font-size: 0.92rem;
  color: var(--primary-color);
}

.data-table-source {
  font-size: 0.74rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 5px;
}

.data-table-wrap {
  overflow-x: auto;
}

table.dash-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.84rem;
}

.dash-table th {
  background: var(--light-color);
  padding: 10px 16px;
  text-align: left;
  font-size: 0.76rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  white-space: nowrap;
  border-bottom: 1px solid var(--border);
}

.dash-table td {
  padding: 11px 16px;
  border-bottom: 1px solid #f3f4f6;
  color: var(--text-color);
  white-space: nowrap;
}

.dash-table tbody tr:last-child td { border-bottom: none; }
.dash-table tbody tr:hover td { background: var(--hover-bg); }

.dash-table .num { text-align: right; font-variant-numeric: tabular-nums; }

/* ── Coming soon (placeholders) ── */
.coming-soon {
  max-width: 680px;
  margin: 60px auto;
  text-align: center;
  padding: 0 24px;
}

.coming-soon-icon {
  width: 72px;
  height: 72px;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  margin: 0 auto 24px;
}

.coming-soon h2 {
  font-size: 1.5rem;
  margin-bottom: 10px;
}

.coming-soon > p {
  color: var(--text-light);
  margin-bottom: 36px;
}

.planned-features {
  background: var(--card-bg);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 28px;
  text-align: left;
  margin-bottom: 28px;
}

.planned-features h4 {
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.planned-features ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.planned-features li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.88rem;
  color: var(--text-color);
}

.planned-features li i {
  color: var(--secondary-color);
  width: 16px;
  flex-shrink: 0;
}

.sources-row {
  display: flex;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.source-chip {
  font-size: 0.76rem;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 14px;
  background: var(--accent-light);
  border: 1px solid #bfdbfe;
  color: var(--secondary-color);
}

/* ── Responsive ── */
@media (max-width: 640px) {
  .dash-header-right { align-items: flex-start; }
  .kpi-row { grid-template-columns: 1fr 1fr; }
  .charts-grid { gap: 14px; }
  .dash-main { padding: 24px 16px 48px; }
}
