/* nav.css - Comportamiento igual que mobile para todos los tamaños */

.nav, .nav.show {
  transition: opacity 0.5s cubic-bezier(.4,0,.2,1), transform 0.5s cubic-bezier(.4,0,.2,1), box-shadow 0.5s cubic-bezier(.4,0,.2,1);
  will-change: opacity, transform, box-shadow;
  overflow: hidden !important; 
  padding: 12px 8px; 
}

.nav {
  position: absolute;
  top: 56px;
  left: 0;
  width: 100%;
  background: white;
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
  border-radius: 12px;
  flex-direction: column;
  z-index: 9999;
  border: none;
  padding-top: 0;
  padding-bottom: 0;
  padding-left: 8px;
  padding-right: 8px;
  box-shadow: none;
  max-height: 0;
  opacity: 0;
  transform: translateY(-32px) scale(0.98);
  pointer-events: none;
  filter: blur(4px) grayscale(0.1);
}

.nav.show {
  height: auto;
  min-height: 0;
  max-height: 1000px;
  opacity: 1;
  padding-top: 12px;
  padding-bottom: 12px;
  padding-left: 8px;
  padding-right: 8px;
  overflow-y: auto;
  overflow-x: hidden;
  top: 80px;
  left: 140px;
  right: 10px !important;
  width: auto !important;
  border-radius: 12px;
  border: 1px solid #e0e6ed;
  max-width: 400px !important;
  margin: 10px 0 !important;
  pointer-events: auto;
  transform: translateY(0) scale(1);
  box-shadow: 0 16px 48px rgba(0,0,0,0.22);
  filter: none;
}

.nav-btn {
  width: 100%;
  text-align: left;
  padding: 12px 22px;
  border-radius: 8px;
  font-size: 1.05rem;
  margin: 2px 0;
  background: transparent;
  color: var(--text-primary);
  transition: background 0.2s, color 0.2s;
  font-weight: 500;
  box-shadow: none;
  white-space: nowrap;
}

.nav-btn:hover,
.nav-btn.active {
  background: var(--primary-color);
  color: #fff;
}

@media (max-width: 1400px) {
  .nav.show {
    left: 10px;
  }
}

@media (max-width: 768px) {
  .nav.show {
    max-height: 80vh;
    min-height: 0;
    top: 50px;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
  }
}

@media (min-width: 0px) {
  .nav {
    display: flex;
    flex-direction: column;
  }
}
