.custom-sidenav {
  position: fixed;
  width: 300px;
  height: 100%;
  background-color: #fff;
  box-shadow: 0 2px 5px 0 rgba(0,0,0,0.16), 0 2px 10px 0 rgba(0,0,0,0.12);
  z-index: 1000;
  top: 0;
  will-change: transform;
  backface-visibility: hidden;
  transform: translateX(-100%);
  transition: transform 0.3s ease-out;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.custom-sidenav.right-aligned {
  right: 0;
  transform: translateX(100%);
}

.sidenav-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0,0,0,0.5);
  z-index: 999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease-out;
  will-change: opacity;
}

/* Estilos para elementos dentro del sidenav */
.custom-sidenav a {
  display: block;
  padding: 1rem;
  color: #444;
  text-decoration: none;
  transition: background-color 0.2s ease;
}

.custom-sidenav a:hover {
  background-color: rgba(0,0,0,0.05);
}

.custom-sidenav .divider {
  height: 1px;
  background-color: #e0e0e0;
  margin: 8px 0;
}

/* Responsive */
@media only screen and (max-width: 992px) {
  .custom-sidenav {
    width: 240px;
  }
}

/* Animaciones */
@keyframes slideIn {
  from {
    transform: translateX(-100%);
  }
  to {
    transform: translateX(0);
  }
}

@keyframes slideOut {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-100%);
  }
}

/* Versión derecha de las animaciones */
@keyframes slideInRight {
  from {
    transform: translateX(100%);
  }
  to {
    transform: translateX(0);
  }
}

@keyframes slideOutRight {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(100%);
  }
}
