/* ===== MENÚ LATERAL LEGAL ===== */
.legal-sidebar {
  position: fixed;
  left: 20px;
  top: 140px; /* Ajustado para estar debajo del header (80px + 20px padding + 40px extra) */
  width: 280px;
  background: rgba(26, 26, 46, 0.9);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: 16px;
  padding: 20px;
  z-index: 50; /* Z-index más bajo para que no interfiera */
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  max-height: 80vh;
  overflow-y: auto;
  transition: all 0.3s ease;
}

.legal-sidebar h3 {
  font-family: 'Poppins', system-ui, -apple-system, Segoe UI, Roboto, 'Helvetica Neue', Arial, sans-serif;
  font-size: 18px;
  font-weight: 600;
  color: #ffffff;
  margin: 0 0 20px 0;
  text-align: center;
  padding-bottom: 15px;
  border-bottom: 1px solid rgba(139, 92, 246, 0.3);
}

.legal-menu {
  list-style: none;
  margin: 0;
  padding: 0;
}

.legal-menu li {
  margin-bottom: 8px;
}

.legal-menu a {
  display: block;
  padding: 12px 16px;
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  border-radius: 8px;
  transition: all 0.3s ease;
  font-family: 'Avenir', system-ui, -apple-system, Segoe UI, Roboto, 'Helvetica Neue', Arial, sans-serif;
  font-size: 14px;
  font-weight: 400;
  position: relative;
}

.legal-menu a:hover {
  background: rgba(139, 92, 246, 0.2);
  color: #ffffff;
  transform: translateX(5px);
}

.legal-menu a.active {
  background: linear-gradient(135deg, #7a05e7, #872af1);
  color: #ffffff;
  font-weight: 600;
  box-shadow: 0 4px 15px rgba(139, 92, 246, 0.3);
}

.legal-menu a.active::before {
  content: '';
  position: absolute;
  left: -8px;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 20px;
  background: #ffffff;
  border-radius: 2px;
}

/* Responsive */
@media (max-width: 1200px) {
  .legal-sidebar {
    position: relative;
    left: auto;
    top: auto;
    width: 100%;
    max-width: 100%;
    margin-bottom: 30px;
    max-height: none;
  }
}

@media (max-width: 768px) {
  .legal-sidebar {
    padding: 15px;
  }
  
  .legal-sidebar h3 {
    font-size: 16px;
  }
  
  .legal-menu a {
    padding: 10px 12px;
    font-size: 13px;
  }
}

/* Scrollbar personalizado */
.legal-sidebar::-webkit-scrollbar {
  width: 6px;
}

.legal-sidebar::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 3px;
}

.legal-sidebar::-webkit-scrollbar-thumb {
  background: rgba(139, 92, 246, 0.5);
  border-radius: 3px;
}

.legal-sidebar::-webkit-scrollbar-thumb:hover {
  background: rgba(139, 92, 246, 0.7);
}



