body {
  background-color: #f8f9fa;
}

.app-shell {
  width: 100%;
}

.app-sidebar {
  width: 250px;
  position: sticky;
  top: 0;
  min-height: 100vh;
}

.icon-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.sidebar-brand {
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.sidebar-brand-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
  font-size: 1.1rem;
}

.sidebar-brand-text {
  font-size: 0.95rem;
  letter-spacing: 0.18em;
}

.app-sidebar .nav-link {
  border-radius: 0.5rem;
  font-weight: 500;
  padding: 0.65rem 1rem;
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
}

.app-sidebar .nav-icon {
  width: 1.2rem;
  height: 1.2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.app-sidebar .nav-link.active {
  background-color: rgba(255, 255, 255, 0.15);
  color: #fff;
}

.app-sidebar .nav-link:hover {
  color: #fff;
  background-color: rgba(255, 255, 255, 0.08);
}

.sidebar-brand {
  padding: 0.35rem 0.65rem;
  border-radius: 0.9rem;
  background: rgba(255, 255, 255, 0.06);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
  transition: background-color 0.2s ease, box-shadow 0.2s ease;
}

.sidebar-brand:hover {
  background: rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
}

.sidebar-brand-name {
  display: inline-flex;
  align-items: center;
  letter-spacing: 0.04em;
}

.app-main {
  background-color: #f8f9fa;
}

.app-content {
  width: 100%;
  max-width: none;
}

.guest-shell {
  max-width: 640px;
}

.card {
  border: none;
  border-radius: 0.75rem;
}

.card-body {
  padding: 2rem;
}

.member-row {
  cursor: pointer;
}

.rank-chief > *,
.rank-chief {
  background-color: #ffffff !important;
}

.rank-captain > *,
.rank-captain {
  background-color: #f8d7da !important;
}

.rank-firefighter > *,
.rank-firefighter {
  background-color: #fff3cd !important;
}

.rank-probationary > *,
.rank-probationary {
  background-color: #cfe2ff !important;
}

.member-row.selected,
.member-row.selected > * {
  background-color: #e9f5ff !important;
}

.apparatus-row {
  cursor: pointer;
  transition: background-color 0.15s ease;
}

.apparatus-row.selected,
.apparatus-row.selected > * {
  background-color: #fff1da !important;
  box-shadow: inset 0 0 0 999px rgba(255, 193, 7, 0.15);
}

.members-table {
  width: 100%;
}

.members-table th,
.members-table td {
  white-space: normal;
  word-break: keep-all;
}

.member-actions form {
  margin-bottom: 0;
}

.incident-form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.incident-section.card {
  border: 1px solid rgba(0, 0, 0, 0.05);
}

.incident-section .card-header {
  padding: 1.25rem 2rem 0.75rem;
  background: linear-gradient(135deg, rgba(220, 53, 69, 0.08), rgba(13, 110, 253, 0.06));
  border-bottom: none;
}

.incident-section .card-title {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 600;
}

.incident-section .card-subtitle {
  margin-top: 0.25rem;
}

.incident-grid {
  display: grid;
  gap: 1rem 1.5rem;
}

@media (min-width: 768px) {
  .incident-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 992px) {
  .incident-grid--timeline {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.incident-checkbox-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
}

.incident-checkbox-group .form-check {
  min-width: 200px;
}

.incident-summary-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: flex-end;
}

html {
  scroll-behavior: smooth;
}

.settings-shortcuts {
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  padding: 0.75rem 1rem;
}

.settings-shortcuts__heading {
  margin-bottom: 0.5rem;
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.65);
  text-transform: uppercase;
}

.settings-shortcuts__link {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.8);
  letter-spacing: 0.02em;
  text-decoration: none;
  display: inline-block;
  line-height: 1.35;
}

.settings-shortcuts__link:hover {
  color: #fff;
}

.settings-category-list {
  margin-top: 1.5rem;
}

.list-group-item.category-card {
  border: none;
  padding: 0;
  background-color: transparent;
  margin-bottom: 1.5rem;
}

.category-card__header {
  width: 100%;
  border-radius: 0.75rem;
  padding: 1.15rem 1.5rem;
  border: 1px solid rgba(13, 110, 253, 0.25);
  border-left-width: 0.45rem;
  border-left-color: rgba(13, 110, 253, 0.9);
  border-right-width: 1px;
  border-right-color: rgba(13, 110, 253, 0.15);
  background: linear-gradient(
    115deg,
    rgba(13, 110, 253, 0.08),
    rgba(13, 110, 253, 0.02)
  );
  box-shadow: 0 0.35rem 0.85rem rgba(13, 110, 253, 0.12);
  gap: 0.75rem;
}

.category-card__controls {
  white-space: nowrap;
}

.category-card__body {
  transition: max-height 0.3s ease;
  margin-top: 0.75rem;
  padding: 0 1.25rem 1.25rem;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 0 0 0.75rem 0.75rem;
  background-color: #fff;
}

.category-card__body--collapsed {
  display: none;
}

.subcategory-row {
  flex: 1;
}

.mutual-aid-row {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.mutual-aid-form {
  margin: 0;
}

.settings-leave-prompt {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  background-color: rgba(0, 0, 0, 0.35);
  z-index: 1300;
  padding: 1rem;
}

.settings-leave-prompt--visible {
  display: flex;
}

.settings-leave-prompt__panel {
  background-color: #fff;
  border-radius: 0.75rem;
  padding: 1.5rem;
  width: min(420px, 100%);
  box-shadow: 0 0.75rem 1.5rem rgba(0, 0, 0, 0.25);
}

.app-sidebar button.nav-link {
  background-color: transparent;
  border: 0;
  width: 100%;
}

.settings-modal .modal-content {
  border-radius: 1rem;
}

.settings-modal__sidebar {
  background-color: #f4f6f9;
}

.settings-modal__nav .list-group-item {
  border: 0;
  border-left: 3px solid transparent;
  font-weight: 600;
  color: #2f3a4c;
  padding: 0.85rem 1rem;
}

.settings-modal__nav .list-group-item.active {
  background-color: #0d6efd;
  border-left-color: #0b5ed7;
  color: #fff;
}

.settings-modal__nav .list-group-item.disabled {
  background-color: #e9ecef;
  border-left-color: #d3d7db;
  color: #9aa3ad;
  pointer-events: none;
}

.settings-panel__section + .settings-panel__section {
  margin-top: 1.75rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
}

.settings-account-list li {
  padding: 0.4rem 0;
  border-bottom: 1px dashed rgba(0, 0, 0, 0.1);
}

.settings-account-list li:last-child {
  border-bottom: 0;
}

.settings-panel__muted {
  background-color: #f1f3f5;
  border-radius: 0.75rem;
  padding: 1.25rem;
}

@media (max-width: 991.98px) {
  .settings-modal__sidebar {
    border-right: 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
  }

  .settings-modal__nav .list-group-item {
    border-left: 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  }
}

@media (max-width: 575.98px) {
  .card-body {
    padding: 1.5rem;
  }

  .incident-section .card-header {
    padding-left: 1.5rem;
    padding-right: 1.5rem;
  }
}

.settings-leave-prompt {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  background-color: rgba(0, 0, 0, 0.35);
  z-index: 1300;
  padding: 1rem;
}

.settings-leave-prompt--visible {
  display: flex;
}

.settings-leave-prompt__panel {
  background-color: #fff;
  border-radius: 0.75rem;
  padding: 1.5rem;
  width: min(420px, 100%);
  box-shadow: 0 0.75rem 1.5rem rgba(0, 0, 0, 0.25);
}
