.hidden {
  display: none !important;
}

.layout-shell {
  display: flex;
  min-height: 100vh;
}

.sidebar-collapsed #sidebar {
  width: 84px;
}

.sidebar-collapsed .sidebar-text {
  display: none;
}

.sidebar-section {
  margin-bottom: 16px;
  border: 1px solid #1f2d46;
  border-radius: 10px;
  background: #111c32;
  padding: 12px;
}

.filter-toolbar-grid {
  display: grid;
  grid-template-columns: minmax(220px, 1.3fr) repeat(4, minmax(150px, 1fr)) minmax(140px, 0.8fr) minmax(140px, 0.8fr);
  gap: 8px;
  align-items: start;
}

.filter-menu {
  position: relative;
}

.filter-menu-trigger {
  list-style: none;
  border: 1px solid #1f2d46;
  border-radius: 8px;
  background: #0b1425;
  color: #e2e8f0;
  font-size: 12px;
  font-weight: 600;
  padding: 7px 9px;
  cursor: pointer;
}

.filter-menu-trigger::-webkit-details-marker {
  display: none;
}

.filter-menu[open] .filter-menu-trigger {
  border-color: #3b82f6;
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}

.filter-options {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  z-index: 30;
  width: 100%;
  min-width: 220px;
  max-height: 240px;
  overflow: auto;
  border: 1px solid #1f2d46;
  border-radius: 8px;
  background: #0b1425;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.4);
  padding: 8px;
  display: grid;
  gap: 6px;
}

.filter-option {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: #d5deed;
}

.filter-option-input {
  accent-color: #3b82f6;
}

.sidebar-heading {
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #93a4c1;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid transparent;
  border-radius: 8px;
  padding: 8px 10px;
  color: #93a4c1;
  transition: all 0.2s ease;
}

.nav-link:hover {
  border-color: #1f2d46;
  color: #e2e8f0;
  background: #111c32;
}

.nav-link.active {
  border-color: #264f89;
  color: #bfdbfe;
  background: rgba(59, 130, 246, 0.14);
}

.field-label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  color: #93a4c1;
}

.field {
  width: 100%;
  border: 1px solid #1f2d46;
  border-radius: 8px;
  background: #0b1425;
  color: #e2e8f0;
  padding: 8px 10px;
  font-size: 13px;
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.field.compact {
  min-height: 34px;
  padding: 6px 8px;
  font-size: 12px;
}

.field-label.compact {
  gap: 4px;
  font-size: 11px;
}

.field:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.22);
}

.btn-primary,
.btn-muted,
.btn-ghost {
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  transition: transform 0.15s ease, background 0.2s ease, border-color 0.2s ease;
}

.btn-primary {
  border: 1px solid #2563eb;
  background: linear-gradient(180deg, #3b82f6, #2563eb);
  color: #eff6ff;
  padding: 8px 12px;
}

.btn-muted {
  border: 1px solid #334155;
  background: #18263f;
  color: #dbeafe;
  padding: 8px 12px;
}

.btn-ghost {
  border: 1px solid #26354f;
  background: #0f1a30;
  color: #cbd5e1;
  padding: 8px 12px;
}

.btn-primary:hover,
.btn-muted:hover,
.btn-ghost:hover {
  transform: translateY(-1px);
}

.sortable-col {
  cursor: pointer;
  user-select: none;
}

.sortable-col::after {
  content: " ↕";
  color: #64748b;
  font-size: 11px;
}

.finding-row:hover {
  background: #0f1b34;
}

.finding-row-critical {
  border-left: 3px solid #ef4444;
}

.badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.badge-status-pass {
  background: rgba(22, 163, 74, 0.2);
  color: #86efac;
}

.badge-status-fail {
  background: rgba(239, 68, 68, 0.2);
  color: #fca5a5;
}

.badge-status-fp {
  background: rgba(168, 85, 247, 0.24);
  color: #d8b4fe;
}

.badge-severity-critical {
  background: rgba(239, 68, 68, 0.2);
  color: #fca5a5;
}

.badge-severity-high {
  background: rgba(249, 115, 22, 0.2);
  color: #fdba74;
}

.badge-severity-medium {
  background: rgba(245, 158, 11, 0.2);
  color: #fcd34d;
}

.badge-severity-low {
  background: rgba(59, 130, 246, 0.2);
  color: #93c5fd;
}

.badge-severity-info {
  background: rgba(6, 182, 212, 0.2);
  color: #67e8f9;
}

.report-list-item {
  border: 1px solid #253652;
  border-radius: 10px;
  background: #0f1a30;
  padding: 10px;
}

.report-list-item.active {
  border-color: #3b82f6;
  background: rgba(59, 130, 246, 0.12);
}

.expanded-row {
  background: rgba(15, 23, 42, 0.78);
}

.skeleton-card {
  height: 92px;
  border-radius: 10px;
  border: 1px solid #1f2d46;
  background: linear-gradient(90deg, #0f1a30 25%, #1a2944 37%, #0f1a30 63%);
  background-size: 400% 100%;
  animation: shimmer 1.4s ease infinite;
}

.chart-canvas {
  position: relative;
  height: 240px;
  width: 100%;
}

.chart-canvas canvas {
  height: 100% !important;
  width: 100% !important;
}

@keyframes shimmer {
  0% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0 50%;
  }
}

*::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

*::-webkit-scrollbar-track {
  background: #0b1425;
}

*::-webkit-scrollbar-thumb {
  background: #26354f;
  border-radius: 999px;
}

*::-webkit-scrollbar-thumb:hover {
  background: #375074;
}

@media (max-width: 1280px) {
  .filter-toolbar-grid {
    grid-template-columns: repeat(3, minmax(160px, 1fr));
  }
}

@media (max-width: 1140px) {
  #sidebar {
    width: 88px;
  }

  .sidebar-text {
    display: none;
  }
}

@media (max-width: 840px) {
  .filter-toolbar-grid {
    grid-template-columns: repeat(2, minmax(140px, 1fr));
  }
}
