/* CEO Dashboard — KPI card grid (styled after the CGX reference). */
#tab-dashboard .cd-wrap { padding: 18px 20px 40px; background: #0d1b33; min-height: 100%; }

/* Top bar */
#tab-dashboard .cd-topbar {
  display: flex; align-items: center; justify-content: space-between;
  background: linear-gradient(90deg, #1b3a6b, #16305b);
  border: 1px solid #27447a; border-radius: 12px;
  padding: 16px 20px; margin-bottom: 16px;
}
#tab-dashboard .cd-topbar-title { color: #eaf1fb; font-weight: 800; letter-spacing: .04em; font-size: 18px; }
#tab-dashboard .cd-topbar-right { display: flex; align-items: center; gap: 10px; }
#tab-dashboard .cd-live { display: inline-flex; align-items: center; gap: 6px; color: #37d67a; font-weight: 700; font-size: 12px; letter-spacing: .08em; }
#tab-dashboard .cd-live-dot { width: 8px; height: 8px; border-radius: 50%; background: #37d67a; box-shadow: 0 0 0 3px rgba(55,214,122,.2); }
#tab-dashboard #cd-period, #tab-dashboard .cd-refresh {
  background: #10254a; color: #dbe7f7; border: 1px solid #2d4d80;
  border-radius: 8px; padding: 7px 12px; font-size: 13px; font-weight: 600; cursor: pointer;
}
#tab-dashboard .cd-refresh:hover { background: #16305f; }

/* Grid */
#tab-dashboard .cd-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 14px; grid-auto-flow: row dense;
}

/* Card */
#tab-dashboard .cd-card {
  background: linear-gradient(160deg, #21467f 0%, #16325f 100%);
  border: 1px solid #2c4f86; border-radius: 14px;
  padding: 16px 18px; min-height: 150px;
  display: flex; flex-direction: column;
  box-shadow: 0 8px 20px rgba(0,0,0,.22);
}
#tab-dashboard .cd-card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
#tab-dashboard .cd-card-label { color: #eaf1fb; font-weight: 800; font-size: 13px; letter-spacing: .06em; }
#tab-dashboard .cd-card-sub { color: #9fb6d6; font-size: 11.5px; margin-top: 3px; line-height: 1.3; }
#tab-dashboard .cd-card-period { color: #b9cbe6; font-size: 11px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.12); border-radius: 6px; padding: 3px 8px; white-space: nowrap; }
#tab-dashboard .cd-card-body { flex: 1; display: flex; align-items: center; margin: 10px 0 8px; }
#tab-dashboard .cd-card-foot { min-height: 16px; }

/* Numbers */
#tab-dashboard .cd-hero { color: #ffffff; font-weight: 800; font-size: 40px; line-height: 1; letter-spacing: -0.02em; }
#tab-dashboard .cd-hero-split { display: flex; gap: 28px; }
#tab-dashboard .cd-hero-split3 { gap: 20px; }
#tab-dashboard .cd-hero-sm { color: #ffffff; font-weight: 800; font-size: 30px; line-height: 1; }
#tab-dashboard .cd-hero-cap { color: #9fb6d6; font-size: 11px; font-weight: 700; letter-spacing: .08em; margin-top: 6px; }
#tab-dashboard .cd-delta { font-size: 12.5px; font-weight: 700; }
#tab-dashboard .cd-delta-note { color: #9fb6d6; font-weight: 500; }

/* Chart card spans 2 cols x 2 rows */
#tab-dashboard .cd-chart-card { grid-column: span 2; grid-row: span 2; min-height: 320px; }
#tab-dashboard .cd-chart-hero { color: #fff; font-weight: 800; font-size: 34px; text-align: center; margin: 6px 0 4px; letter-spacing: -0.02em; }
#tab-dashboard .cd-chart-hero-note { display: block; color: #9fb6d6; font-size: 12px; font-weight: 500; margin-top: 2px; }
#tab-dashboard .cd-chart { width: 100%; height: auto; display: block; margin-top: 6px; }
#tab-dashboard .cd-bar-val { fill: #cfe0f5; font-size: 12px; font-weight: 600; }
#tab-dashboard .cd-bar-lab { fill: #9fb6d6; font-size: 12px; }

#tab-dashboard .cd-loading { color: #cfe0f5; padding: 60px; text-align: center; font-size: 15px; }

/* Responsive: collapse to 2 columns, then 1 */
@media (max-width: 1100px) {
  #tab-dashboard .cd-grid { grid-template-columns: repeat(2, 1fr); }
  #tab-dashboard .cd-chart-card { grid-column: span 2; grid-row: span 1; }
}
@media (max-width: 640px) {
  #tab-dashboard .cd-grid { grid-template-columns: 1fr; }
  #tab-dashboard .cd-chart-card { grid-column: span 1; }
  #tab-dashboard .cd-hero { font-size: 34px; }
}
