/* Sweptt Admin — matches frontend purple palette */

:root {
  --sw-radius: 0.625rem;
}

/* Sidebar */
#nav-sidebar {
  border-right: 1px solid #e5e7eb;
}

/* Branding */
#nav-sidebar .sidebar-title {
  font-weight: 600;
  letter-spacing: -0.02em;
}

/* Nav items — rounder corners */
#nav-sidebar a {
  border-radius: var(--sw-radius);
}

/* Cards / modules */
.module, .card {
  border-radius: var(--sw-radius);
  border: 1px solid #e5e7eb;
  box-shadow: none !important;
}

/* Buttons */
.button, input[type=submit], input[type=button], .submit-row input {
  border-radius: var(--sw-radius);
}

/* Table rows */
#result_list tr:hover td {
  background-color: #f9fafb;
}

/* Password fields */
#id_password1,
#id_password2 {
  font-family: monospace;
  font-size: 1rem;
  letter-spacing: 0.05em;
  width: 100%;
  box-sizing: border-box;
}

/* KPI cards on dashboard */
.cf-kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

.cf-kpi-card {
  border: 1px solid #e5e7eb;
  border-radius: var(--sw-radius);
  padding: 1.25rem 1.5rem;
  background: #fff;
}

.cf-kpi-card .cf-kpi-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #6b7280;
  margin-bottom: 0.25rem;
}

.cf-kpi-card .cf-kpi-value {
  font-size: 2rem;
  font-weight: 700;
  color: #111827;
  line-height: 1.1;
}

.cf-kpi-card .cf-kpi-desc {
  font-size: 0.75rem;
  color: #9ca3af;
  margin-top: 0.25rem;
}

/* Breakdown tables */
.cf-breakdown-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

.cf-breakdown-card {
  border: 1px solid #e5e7eb;
  border-radius: var(--sw-radius);
  padding: 1.25rem 1.5rem;
  background: #fff;
}

.cf-breakdown-card h3 {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #6b7280;
  margin: 0 0 1rem 0;
}

.cf-breakdown-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.6rem;
}

.cf-breakdown-row-label {
  font-size: 0.875rem;
  color: #374151;
  width: 80px;
  flex-shrink: 0;
}

.cf-bar-track {
  flex: 1;
  height: 6px;
  background: #f3f4f6;
  border-radius: 999px;
  overflow: hidden;
}

.cf-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #5114D6, #8023FF);
  border-radius: 999px;
}

.cf-breakdown-count {
  font-size: 0.8rem;
  font-weight: 600;
  color: #111827;
  width: 28px;
  text-align: right;
  flex-shrink: 0;
}

/* Health badges */
.cf-health-grid {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}

.cf-health-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  border: 1px solid transparent;
}

.cf-health-badge.ok {
  background: #f0fdf4;
  color: #15803d;
  border-color: #bbf7d0;
}

.cf-health-badge.error {
  background: #fef2f2;
  color: #b91c1c;
  border-color: #fecaca;
}

.cf-health-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}

.cf-health-badge.ok .cf-health-dot   { background: #22c55e; }
.cf-health-badge.error .cf-health-dot { background: #ef4444; }
