/* Archivo: nav.css
   Creado por: D4niel (19-06-2025)
   Modificado: 23-06-2025 */

header {
  position: fixed;
  top: 0;
  width: 100%;
  padding: 1rem 0;
  background-color: #DBEFE1;
  backdrop-filter: blur(10px);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  z-index: 1000;
  transform: translateY(-100%);
  animation: slideDown 0.6s forwards 0.5s;
}

@keyframes slideDown {
  to {
    transform: translateY(0);
  }
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

.main-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-size: 1.75rem;
  font-weight: 700;
  color: #3A3A3C;
}

/* NAV LINKS: escritorio */
.nav-links {
  list-style: none;
  display: flex;
  gap: 2rem;
}

.nav-links a {
  position: relative;
  color: #3A3A3C;
  text-decoration: none;
  font-weight: 600;
  padding: 0.5rem;
  transition: var(--transition);
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0;
  height: 2px;
  background: var(--color-secondary);
  transition: var(--transition);
}

.nav-links a:hover::after {
  width: 100%;
}

/* BOTÓN HAMBURGUESA: oculto por defecto */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
}

/* Contact FAB - Creado por: D4niel (19-06-2025) */
.contact-fab {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 1500;
  display: flex;
  flex-direction: column-reverse;
  align-items: center;
}

.fab-toggle {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--color-primary);
  color: #fff;
  font-size: 1.5rem;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease;
}

.fab-toggle i {
  pointer-events: none;
}

.fab-buttons {
  display: none;
  margin-bottom: 0.5rem;
  flex-direction: column;
  gap: 0.5rem;
}

.fab-btn {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--color-secondary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transition: transform 0.3s ease;
}

.fab-btn:hover {
  transform: scale(1.1);
}

.fab-whatsapp {
  background: #25d366;
}
.fab-call {
  background: #0073e6;
}

/* Media query para móviles hasta 480px */
@media screen and (max-width: 480px) {
  .nav-toggle {
    display: block;
    color: #3A3A3C;
  }
  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: #DBEFE1;
    flex-direction: column;
    gap: 0;
    overflow: hidden;
    max-height: 0;
    transition: max-height 0.3s ease;
  }
  .nav-links li + li {
    border-top: 1px solid rgba(0,0,0,0.1);
  }
  .nav-links a {
    display: block;
    padding: 1rem;
  }
  /* Cuando nav tenga clase .open, desplegar */
  .main-nav.open .nav-links {
    max-height: 500px; /* suficiente para mostrar todos los ítems */
  }
}
