/* ============================================================
   header.css
   Estilos del navbar fijo y menú móvil
   ============================================================ */

nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 200;
  height: 72px;
  padding: 0 5vw;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 2px 20px rgba(15, 28, 46, .06);
  transition: box-shadow .3s;
}

/* ── Logo ── */
.logo {
  text-decoration: none;
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.logo-img {
  height: 44px;
  width: auto;
  display: block;
  object-fit: contain;
}

@media (max-width: 480px) {
  .logo-img { height: 36px; }
}

/* ── Links de navegación ── */
.nav-links {
  display: flex;
  align-items: center;
  gap: .15rem;
  list-style: none;
}

.nav-links a {
  font-size: .73rem;
  font-weight: 600;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--sub);
  text-decoration: none;
  padding: .45rem .85rem;
  border-radius: 6px;
  transition: color .2s, background .2s;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--accent);
  background: rgba(26, 109, 255, .07);
}

/* ── Separador visual ── */
.nav-sep {
  width: 1px;
  height: 18px;
  background: var(--border);
  margin: 0 .5rem;
  flex-shrink: 0;
}

/* ── Botón CTA principal ── */
.nav-cta {
  background: var(--accent);
  color: #fff;
  padding: .55rem 1.4rem;
  border-radius: 8px;
  font-size: .73rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  text-decoration: none;
  flex-shrink: 0;
  box-shadow: 0 4px 14px rgba(26, 109, 255, .3);
  transition: background .2s, box-shadow .2s, transform .15s;
}

.nav-cta:hover {
  background: var(--accent2);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(26, 109, 255, .4);
}

/* ── Hamburger (móvil) ── */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px;
}

.hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
}

/* ── Menú móvil desplegable ── */
.mobile-menu {
  display: none;
  position: fixed;
  top: 72px; left: 0; right: 0;
  z-index: 199;
  background: #fff;
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  padding: 1.5rem 5vw 2rem;
  flex-direction: column;
  gap: .4rem;
}

.mobile-menu.open { display: flex; }

.mobile-menu a {
  font-size: .85rem;
  font-weight: 600;
  color: var(--sub);
  text-decoration: none;
  padding: .75rem 1rem;
  border-radius: 8px;
  transition: background .2s, color .2s;
}

.mobile-menu a:hover {
  color: var(--accent);
  background: rgba(26, 109, 255, .06);
}

/* ── Responsive ── */

/* Tablet landscape y menor: ocultar nav, mostrar hamburger */
@media (max-width: 960px) {
  .nav-links,
  .nav-sep,
  .nav-cta { display: none; }

  .hamburger { display: flex; }
}

/* Móvil: reducir padding del nav y tamaño del logo */
@media (max-width: 480px) {
  nav { padding: 0 4vw; height: 64px; }

  /* El menú móvil arranca justo debajo del nav reducido */
  .mobile-menu { top: 64px; padding: 1.2rem 4vw 1.6rem; }
}