.nav-card {
  position: relative;
  background: rgba(13,16,26,0.9);
  border-radius: 1rem;
  border: 1px solid rgba(139,61,255,0.25);
  padding: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.nav-card::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  border-radius: inherit;
  background: radial-gradient(circle at top center, rgba(115,82,255,0.25), transparent 60%);
  opacity: .6;
}

.nav-card > .list-group-item {
  position: relative;
}

.nav-card.nav-card-stretch {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
}

.nav-card .list-group-item {
  border: none;
  border-radius: 0;
  padding: 1rem 1.25rem;
  font-weight: 500;
  color: rgba(255,255,255,0.72);
  background: transparent;
  transition: background .2s ease, color .2s ease;
  display: flex;
  align-items: center;
  gap: .65rem;
  z-index: 1;
}

.nav-card .list-group-item .bi {
  font-size: 1.1rem;
}

.nav-card .list-group-item span {
  flex: 1;
}

.nav-card .list-group-item:hover {
  color: #fff;
  background: rgba(139,61,255,0.18);
}

.nav-card .list-group-item.active,
.nav-card .list-group-item.list-group-item-action.active {
  background: linear-gradient(90deg, rgba(115,82,255,0.35), rgba(73,29,181,0.45)) !important;
  color: #fff !important;
  font-weight: 600;
}

@media (max-width: 991.98px) {
  .nav-card {
    margin-bottom: 1.5rem;
    min-height: auto;
  }
}

footer {
  background: #020617 !important;
  background-color: #020617 !important;
  border-top: 1px solid rgba(139,61,255,0.35);
  color: rgba(255,255,255,0.8);
  padding-top: 1.25rem;
  padding-bottom: 1.25rem;
  margin-top: auto;
}

footer.mainfooterstart {
  background: #020617 !important;
  background-color: #020617 !important;
  border-top: 1px solid rgba(139,61,255,0.35);
}

footer .small,
footer .small span,
footer a {
  color: rgba(255,255,255,0.8);
}

body.d-flex.flex-column,
body.min-vh-100.d-flex {
  display: flex !important;
  flex-direction: column;
  min-height: 100vh;
}

body.d-flex.flex-column > main,
body.min-vh-100.d-flex > main {
  flex: 1 0 auto;
}

body.d-flex.flex-column > footer,
body.min-vh-100.d-flex > footer {
  flex-shrink: 0;
}

@media (max-width: 575.98px) {
  footer {
    text-align: center;
  }
}

/* Sidebar Toggle Button Styles */
.sidebar-toggle-btn {
  display: block !important;
  border: 1px solid rgba(255,255,255,0.3) !important;
  padding: 0.375rem 0.75rem !important;
  background: transparent !important;
  color: rgba(255,255,255,0.8) !important;
  border-radius: 0.375rem;
  transition: all 0.2s ease;
}

.sidebar-toggle-btn:hover {
  background: rgba(255,255,255,0.1) !important;
  color: #fff !important;
  border-color: rgba(255,255,255,0.5) !important;
}

.sidebar-toggle-btn i {
  font-size: 1.25rem;
}

@media (min-width: 992px) {
  .sidebar-toggle-btn {
    display: none !important;
  }
}

/* Offcanvas Sidebar Styles */
.offcanvas-nav {
  background: #020617 !important;
  z-index: 9999 !important;
}

.offcanvas-nav .offcanvas-header {
  border-bottom: 1px solid rgba(139,61,255,0.25);
  padding: 1rem 1.25rem;
}

.offcanvas-nav .offcanvas-title {
  color: #fff;
  font-weight: 600;
}

.offcanvas-nav .nav-card {
  border-radius: 0;
  border: none;
  margin: 0;
  min-height: auto;
}

.offcanvas-nav .nav-card .list-group-item {
  border-bottom: 1px solid rgba(139,61,255,0.1);
}

.offcanvas-nav .nav-card .list-group-item:last-child {
  border-bottom: none;
}

/* Ensure offcanvas backdrop is below the offcanvas */
.offcanvas-backdrop {
  z-index: 9998 !important;
}
