/* ══════════════════════════════════════════
   SITE HEADER — siempre blanco, siempre visible
   Válido para HOME, MAPA, BUSCAR, y todas las páginas
═══════════════════════════════════════════ */

.site-header {
  background: #fff;
  border-bottom: 1px solid rgba(15, 23, 42, 0.05);
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.02);
  position: sticky;
  top: 0;
  z-index: 200;
}

.site-header__inner {
  display: flex;
  align-items: center;
  height: 60px;
  padding: 0 40px;
  max-width: 100%;
  gap: 0;
}

/* Logo */
.site-header__logo {
  display: flex;
  align-items: center;
  gap: 7px;
  text-decoration: none;
  margin-right: auto;
  flex-shrink: 0;
}

.site-header__logo-icon {
  font-size: 20px;
  line-height: 1;
  flex-shrink: 0;
}

.site-header__logo-text {
  font-size: 20px;
  font-weight: 500;
  color: #0b1d35;
  letter-spacing: -0.025em;
  font-family: -apple-system, BlinkMacSystemFont, 'Inter', sans-serif;
}
.site-header__logo-text span { color: #4A90D9; }

/* Nav links */
.site-header__nav {
  display: flex;
  align-items: center;
  gap: 28px;
  margin-right: 24px;
}

.site-header__link {
  font-size: 14px;
  color: #555;
  text-decoration: none;
  font-weight: 400;
  font-family: -apple-system, BlinkMacSystemFont, 'Inter', sans-serif;
  transition: color 0.12s;
  white-space: nowrap;
}
.site-header__link:hover { color: #0b1d35; }
.site-header__link--active { color: #0b1d35; font-weight: 500; }

/* Actions */
.site-header__actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.site-header__btn {
  padding: 8px 20px;
  background: #0b1d35;
  color: #fff;
  border-radius: 9px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  font-family: -apple-system, BlinkMacSystemFont, 'Inter', sans-serif;
  transition: opacity 0.12s;
  white-space: nowrap;
}
.site-header__btn:hover { opacity: 0.82; }

.site-header__user {
  font-size: 14px;
  color: #4A90D9;
  text-decoration: none;
  font-weight: 500;
}

/* Hamburger */
.site-header__hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  cursor: pointer;
  background: none;
  border: none;
  margin-left: 8px;
  flex-shrink: 0;
}
.site-header__hamburger span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: #0b1d35;
  border-radius: 2px;
  transition: all 0.2s;
}
.site-header__hamburger[aria-expanded="true"] span:nth-child(1) { transform: rotate(45deg) translateY(9px); }
.site-header__hamburger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.site-header__hamburger[aria-expanded="true"] span:nth-child(3) { transform: rotate(-45deg) translateY(-9px); }

/* Menú móvil — oculto por defecto SIEMPRE */
.site-header__mobile-menu {
  display: none;
}
.site-header__mobile-link {
  padding: 11px 12px;
  font-size: 15px;
  color: #333;
  text-decoration: none;
  border-radius: 8px;
  font-family: -apple-system, BlinkMacSystemFont, 'Inter', sans-serif;
}
.site-header__mobile-link:hover { background: #f5f5f5; }
.site-header__mobile-btn {
  margin-top: 8px;
  padding: 12px;
  background: #0b1d35;
  color: #fff;
  text-align: center;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
  font-family: -apple-system, BlinkMacSystemFont, 'Inter', sans-serif;
}

/* RESPONSIVE */
@media (max-width: 768px) {
  .site-header__inner { 
    padding: 0 16px; 
    justify-content: center;
  }
  .site-header__logo { margin-right: 0; }
  .site-header__nav   { display: none; }
  .site-header__actions { display: none; }
  .site-header__hamburger { display: none; }
  .site-header__logo-text { font-size: 18px; }

  /* Solo visible en móvil Y cuando JS lo activa */
  .site-header__mobile-menu.is-open {
    display: flex;
    flex-direction: column;
    gap: 4px;
    border-top: 1px solid #f0f0f0;
    padding: 8px 16px 16px;
    background: #fff;
  }
}

@media (max-width: 360px) {
  .site-header__btn { padding: 7px 14px; font-size: 13px; }
}

/* ══════════════════════════════════════════
   MOBILE BOTTOM NAVIGATION
═══════════════════════════════════════════ */
.mobile-bottom-nav {
  display: none;
}

@media (max-width: 768px) {
  .mobile-bottom-nav {
    display: flex;
    position: fixed;
    bottom: calc(env(safe-area-inset-bottom, 0px) + 16px);
    left: 20px;
    right: 20px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 999px;
    box-shadow: 0 8px 32px rgba(15, 23, 42, 0.12), 0 0 0 1px rgba(15, 23, 42, 0.04);
    z-index: 1000;
    padding: 10px 28px;
    justify-content: space-between;
    align-items: center;
  }

  .mobile-bottom-nav__item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    text-decoration: none;
    color: #94A3B8; /* Slate 400 */
    font-size: 11px;
    font-weight: 500;
    transition: color 0.2s;
  }

  .mobile-bottom-nav__item svg {
    width: 24px;
    height: 24px;
    stroke-width: 1.5;
    transition: all 0.2s;
  }

  .mobile-bottom-nav__item.active {
    color: #2563EB; /* Blue 600 */
  }

  .mobile-bottom-nav__item.active svg {
    stroke: #2563EB;
    stroke-width: 2.2;
  }

  /* Añadir padding al body para que el contenido no quede oculto bajo la nav */
  body {
    padding-bottom: calc(85px + env(safe-area-inset-bottom, 0px));
  }
}
