:root {
  --brand: #0066cc;
  --brand-dark: #004f9e;
  --accent-green: #16a34a;
  --accent-orange: #f97316;
  --surface-light: #f4f8ff;
  --surface-dark: #0b1220;
  --text-light: #0f172a;
  --text-dark: #e2e8f0;
}

* {
  font-family: "Sora", sans-serif;
}

body {
  background:
    radial-gradient(circle at 15% 15%, rgba(0, 102, 204, 0.2) 0, rgba(0, 102, 204, 0) 45%),
    radial-gradient(circle at 85% 10%, rgba(22, 163, 74, 0.14) 0, rgba(22, 163, 74, 0) 42%),
    linear-gradient(165deg, #f5faff 0%, #eef5ff 45%, #f9fcff 100%);
  color: var(--text-light);
}

html.dark body {
  background:
    radial-gradient(circle at 80% 20%, rgba(0, 102, 204, 0.2) 0, rgba(0, 102, 204, 0) 40%),
    radial-gradient(circle at 20% 10%, rgba(249, 115, 22, 0.12) 0, rgba(249, 115, 22, 0) 35%),
    linear-gradient(165deg, #060a14 0%, #0b1326 45%, #0f172a 100%);
  color: var(--text-dark);
}

.theme-bg {
  min-height: 100vh;
}

.glass-card {
  border-radius: 1rem;
  border: 1px solid rgba(148, 163, 184, 0.25);
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
  backdrop-filter: blur(10px);
}

html.dark .glass-card {
  border-color: rgba(71, 85, 105, 0.6);
  background: rgba(15, 23, 42, 0.75);
  box-shadow: 0 18px 32px rgba(0, 0, 0, 0.35);
}

.login-stat {
  border-radius: 0.9rem;
  padding: 0.9rem;
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid rgba(148, 163, 184, 0.35);
}

html.dark .login-stat {
  background: rgba(15, 23, 42, 0.5);
  border-color: rgba(71, 85, 105, 0.55);
}

.login-stat h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin-top: 0.15rem;
}

.offline-banner {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 60;
  padding: 0.48rem 1rem;
  text-align: center;
  font-size: 0.8rem;
  color: #78350f;
  background: linear-gradient(90deg, #fef3c7 0%, #ffedd5 100%);
  border-bottom: 1px solid rgba(217, 119, 6, 0.25);
}

.sidebar-panel {
  background: rgba(255, 255, 255, 0.92);
  border-right: 1px solid rgba(148, 163, 184, 0.25);
}

html.dark .sidebar-panel {
  background: rgba(2, 6, 23, 0.86);
  border-color: rgba(71, 85, 105, 0.5);
}

.nav-item {
  width: 100%;
  text-align: left;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.92rem;
  padding: 0.62rem 0.72rem;
  border-radius: 0.78rem;
  color: #334155;
  border: 1px solid transparent;
  transition: all 160ms ease;
}

html.dark .nav-item {
  color: #cbd5e1;
}

.nav-item:hover {
  background: rgba(0, 102, 204, 0.1);
  border-color: rgba(0, 102, 204, 0.2);
}

.nav-item.active {
  color: #fff;
  background: linear-gradient(125deg, var(--brand) 0%, #1d88f8 100%);
  border-color: transparent;
  box-shadow: 0 8px 18px rgba(0, 102, 204, 0.25);
}

.input-field,
.input-field-sm,
textarea,
select,
input {
  border: 1px solid #cbd5e1;
  border-radius: 0.75rem;
  background: rgba(255, 255, 255, 0.85);
  padding: 0.62rem 0.75rem;
  width: 100%;
  outline: none;
  transition: all 180ms ease;
}

.input-field-sm {
  min-width: 135px;
  padding: 0.45rem 0.55rem;
  font-size: 0.86rem;
}

html.dark .input-field,
html.dark .input-field-sm,
html.dark textarea,
html.dark select,
html.dark input {
  background: rgba(15, 23, 42, 0.8);
  border-color: #475569;
}

input:focus,
textarea:focus,
select:focus,
.input-field:focus,
.input-field-sm:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(0, 102, 204, 0.15);
}

.btn-primary,
.btn-outline {
  border-radius: 0.75rem;
  padding: 0.58rem 0.95rem;
  font-weight: 600;
  transition: all 180ms ease;
}

.btn-primary {
  color: #fff;
  background: linear-gradient(120deg, var(--brand) 0%, #1d88f8 100%);
  border: 1px solid transparent;
}

.btn-primary:hover {
  transform: translateY(-1px);
  filter: brightness(1.03);
  box-shadow: 0 8px 20px rgba(0, 102, 204, 0.28);
}

.btn-outline {
  color: #334155;
  border: 1px solid #cbd5e1;
  background: rgba(255, 255, 255, 0.65);
}

html.dark .btn-outline {
  color: #e2e8f0;
  border-color: #475569;
  background: rgba(15, 23, 42, 0.4);
}

.btn-outline:hover {
  border-color: var(--brand);
  color: var(--brand);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 760px;
}

.data-table th,
.data-table td {
  text-align: left;
  font-size: 0.83rem;
  padding: 0.65rem 0.55rem;
  border-bottom: 1px solid rgba(148, 163, 184, 0.3);
  white-space: nowrap;
}

.data-table th {
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.7rem;
  color: #64748b;
}

html.dark .data-table th {
  color: #94a3b8;
}

.pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 0.22rem 0.68rem;
  font-size: 0.78rem;
  font-weight: 600;
  border: 1px solid transparent;
}

.pill-open,
.pill-pending,
.pill-low {
  color: #0369a1;
  background: #e0f2fe;
  border-color: #7dd3fc;
}

.pill-in-progress,
.pill-medium {
  color: #b45309;
  background: #fff7ed;
  border-color: #fdba74;
}

.pill-resolved,
.pill-approved,
.pill-high {
  color: #166534;
  background: #dcfce7;
  border-color: #86efac;
}

.pill-critical,
.pill-rejected,
.pill-breached {
  color: #b91c1c;
  background: #fee2e2;
  border-color: #fca5a5;
}

.timeline-item {
  border-left: 3px solid rgba(0, 102, 204, 0.35);
  padding-left: 0.8rem;
  margin-left: 0.35rem;
}

.out-of-range {
  background: rgba(254, 226, 226, 0.65);
}

html.dark .out-of-range {
  background: rgba(127, 29, 29, 0.35);
}

.toast {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  z-index: 80;
  border-radius: 0.75rem;
  padding: 0.7rem 0.95rem;
  font-size: 0.86rem;
  color: #fff;
  background: rgba(15, 23, 42, 0.92);
  box-shadow: 0 16px 28px rgba(0, 0, 0, 0.3);
}

.fade-in {
  animation: reveal 220ms ease;
}

@keyframes reveal {
  from {
    opacity: 0;
    transform: translateY(5px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 768px) {
  .sidebar-panel {
    box-shadow: 12px 0 30px rgba(2, 6, 23, 0.2);
  }
}
