:root {
  --adc-bg: #f6f8fb;
  --adc-card: #ffffff;
  --adc-border: rgba(15, 23, 42, 0.08);
  --adc-text: #0f172a;
  --adc-muted: rgba(15, 23, 42, 0.62);
  --adc-muted-2: rgba(15, 23, 42, 0.48);

  --adc-primary: #4f46e5; /* indigo */
  --adc-accent: #06b6d4; /* cyan */
  --adc-nav: #0b1220;

  --adc-radius: 14px;
  --adc-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
}

html,
body {
  height: 100%;
}

body {
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  background: var(--adc-bg);
  color: var(--adc-text);
}

.adc-navbar {
  background: radial-gradient(1200px 500px at 0% 0%, rgba(79, 70, 229, 0.35), transparent 60%),
    radial-gradient(900px 450px at 100% 0%, rgba(6, 182, 212, 0.28), transparent 60%),
    var(--adc-nav);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.adc-logo {
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #fff;
  font-size: 18px;
}

.adc-badge {
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: rgba(255, 255, 255, 0.9);
  font-weight: 600;
}

.adc-pill {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.08);
  padding: 6px 10px;
  border-radius: 999px;
  backdrop-filter: blur(10px);
}

.adc-card {
  border: 1px solid var(--adc-border);
  border-radius: var(--adc-radius);
  box-shadow: var(--adc-shadow);
}

.adc-card .card-body {
  padding: 18px;
}

.adc-section {
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
  color: rgba(15, 23, 42, 0.75);
}

.adc-sub {
  margin-top: 2px;
  font-size: 13px;
  color: var(--adc-muted);
}

.adc-label {
  font-size: 12px;
  color: var(--adc-muted);
  font-weight: 600;
}

.adc-help {
  font-size: 12px;
  color: var(--adc-muted-2);
}

.adc-hr {
  border-top: 1px solid var(--adc-border);
  opacity: 1;
}

.adc-btn {
  background: linear-gradient(135deg, var(--adc-primary), #3b82f6);
  border: 0;
  color: #fff;
  font-weight: 700;
  border-radius: 12px;
  padding: 8px 12px;
  box-shadow: 0 10px 20px rgba(79, 70, 229, 0.18);
}

.adc-btn:hover {
  filter: brightness(1.02);
  transform: translateY(-1px);
}

.adc-btn-soft {
  background: rgba(79, 70, 229, 0.08);
  border: 1px solid rgba(79, 70, 229, 0.18);
  color: #3730a3;
  font-weight: 700;
  border-radius: 12px;
}

.adc-btn-soft:hover {
  background: rgba(79, 70, 229, 0.12);
}

.adc-seg {
  border: 1px solid var(--adc-border);
  color: rgba(15, 23, 42, 0.75);
  background: #fff;
  font-weight: 700;
}

.btn-check:checked + .adc-seg {
  background: rgba(79, 70, 229, 0.1);
  border-color: rgba(79, 70, 229, 0.25);
  color: #312e81;
}

.adc-kpi {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.9), #fff);
  border: 1px solid var(--adc-border);
  border-radius: var(--adc-radius);
  padding: 14px 14px;
  box-shadow: 0 10px 25px rgba(15, 23, 42, 0.06);
}

.adc-kpi-label {
  font-size: 12px;
  color: var(--adc-muted);
  font-weight: 700;
}

.adc-kpi-value {
  margin-top: 4px;
  font-size: 22px;
  letter-spacing: -0.02em;
  font-weight: 800;
}

.adc-kpi-compact .adc-kpi-value {
  font-size: 20px;
}

.adc-kpi-delta {
  margin-top: 6px;
  font-size: 12px;
  color: var(--adc-muted);
  font-variant-numeric: tabular-nums;
}

.adc-cell {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.adc-cell-value {
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.adc-cell-delta {
  margin-top: 3px;
  font-size: 11px;
  color: var(--adc-muted-2);
  font-variant-numeric: tabular-nums;
}

.adc-state {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--adc-muted);
  background: rgba(15, 23, 42, 0.03);
  border: 1px solid var(--adc-border);
  padding: 10px 12px;
  border-radius: 12px;
}

.adc-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--adc-primary), var(--adc-accent));
  box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.15);
}

.adc-loading {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--adc-muted);
  font-weight: 600;
  font-size: 13px;
}

/* TomSelect tweaks */
.ts-control {
  border-radius: 12px !important;
  border-color: var(--adc-border) !important;
  padding: 8px 10px !important;
}

.ts-dropdown {
  border-radius: 12px !important;
  border-color: var(--adc-border) !important;
  box-shadow: var(--adc-shadow) !important;
}

/* Anomalies page */
.adc-sticky-filters {
  position: sticky;
  top: 10px;
  z-index: 5;
}

.adc-details {
  border: 1px solid var(--adc-border);
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.04);
}

.adc-details > summary {
  list-style: none;
  cursor: pointer;
  padding: 12px 14px;
}

.adc-details > summary::-webkit-details-marker {
  display: none;
}

.adc-details-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.adc-details-day {
  margin-bottom: 12px;
}

.adc-details-day[open] > summary {
  border-bottom: 1px solid var(--adc-border);
}

.adc-details-sev {
  margin: 0 12px;
}

.adc-details-metric {
  margin: 0 12px;
}

.adc-details-sev[open] > summary,
.adc-details-metric[open] > summary {
  border-bottom: 1px solid var(--adc-border);
}

.adc-table thead th {
  font-size: 12px;
  color: var(--adc-muted);
  font-weight: 800;
  border-bottom: 1px solid var(--adc-border) !important;
}

.adc-table tbody td {
  font-size: 13px;
  border-top: 1px solid rgba(15, 23, 42, 0.06) !important;
}

/* Heatmap + expandable day table */
.adc-heat-table tbody tr.adc-click-row {
  cursor: pointer;
}

.adc-heat-table tbody tr.adc-click-row:hover td {
  filter: brightness(0.99);
}

.adc-heat-table tbody tr.adc-click-row.is-open td {
  box-shadow: inset 0 0 0 9999px rgba(79, 70, 229, 0.04);
}

.adc-heat {
  font-variant-numeric: tabular-nums;
  font-weight: 800;
  border-radius: 8px;
}

.adc-expand-inner {
  border: 1px solid var(--adc-border);
  border-radius: 12px;
  padding: 12px 12px;
  background: rgba(255, 255, 255, 0.75);
}

.adc-mini-card {
  border: 1px solid var(--adc-border);
  border-radius: 12px;
  padding: 10px 12px;
  background: #fff;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.03);
}
