/* Existing CSS */
.sidebar {
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  padding: 58px 0 0; /* Height of navbar */
  box-shadow: 0 2px 5px 0 rgb(0 0 0 / 5%), 0 2px 10px 0 rgb(0 0 0 / 5%);
  width: 240px;
  z-index: 600;
  background-color: #f8f9fa;
  display: none; /* Inicialmente oculta */
}

@media (max-width: 991.98px) {
  .sidebar {
    width: 100%;
  }
}

.sidebar .active {
  border-radius: 5px;
  box-shadow: 0 2px 5px 0 rgb(0 0 0 / 16%), 0 2px 10px 0 rgb(0 0 0 / 12%);
}

.fade-in-left {
  animation: fadeInLeft 0.3s forwards;
  display: block !important; /* Garante que a sidebar fique visível */
}

.fade-out-left {
  animation: fadeOutLeft 0.3s forwards;
  display: block !important; /* Garante que a sidebar fique visível durante a animação */
}

@keyframes fadeInLeft {
  from {
    opacity: 0;
    transform: translateX(-100%);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes fadeOutLeft {
  from {
    opacity: 1;
    transform: translateX(0);
  }
  to {
    opacity: 0;
    transform: translateX(-100%);
  }
}

.sidebar-collapsed .sidebar {
  display: none !important;
}

#sidebarToggle {
  width: 40px;
}

#sidebarToggle i {
  transition: transform 0.3s ease, opacity 0.3s ease;
}
