/* Header fijo */
header {
    position: sticky;
    top: 0;
    z-index: 60;
    background: var(--primary);
    box-shadow: 0 2px 12px rgba(0, 0, 0, .08);
    padding: .6rem clamp(1rem, 3vw, 2rem);
    display: flex;
    align-items: center;
    gap: 1rem;
    justify-content: space-between;
}

/* Nav desktop */
nav ul {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap
}

nav a {
    padding: .55rem .8rem;
    border-radius: 999px;
    font-weight: 600;
    color: var(--primary-ink)
}

nav a:hover {
    background: #111;
    color: #fff
}

/* Iconos RRSS */
.social-icon img {
    display: block
}

/* WhatsApp flotante: reutiliza tu enlace existente del header */
a.social-icon[href*="wa.me"] {
    position: fixed;
    right: 18px;
    bottom: 18px;
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #25d366;
    box-shadow: 0 10px 24px rgba(0, 0, 0, .25);
    z-index: 95;
}

a.social-icon[href*="wa.me"] img {
    width: 28px;
    height: 28px;
    filter: brightness(0) invert(1)
}

/* Móvil: menú oculto/desplegable (usa body.nav-open desde JS) */
@media (max-width:900px) {
    nav {
        position: fixed;
        inset: 64px 0 auto 0;
        background: var(--primary);
        transform: translateY(-120%);
        transition: .3s;
        padding: 1rem
    }

    body.nav-open nav {
        transform: translateY(0)
    }

    nav ul {
        flex-direction: column;
        align-items: flex-start;
        gap: .4rem
    }

    nav li {
        width: 100%
    }

    nav a {
        display: block;
        width: 100%;
        background: #111;
        color: #fff
    }

    /* Oculta el espacio original del li que contenía el WhatsApp ya que ahora es flotante */
}

/* Botón hamburguesa */
.hamburger {
    display: none;
    border: 0;
    background: #111;
    color: #fff;
    border-radius: 10px;
    padding: .5rem .75rem;
    font-size: 1.1rem;
}

/* Mostrar en mobile junto al logo */
@media (max-width:900px) {
    .hamburger {
        display: inline-flex;
        align-items: center;
        justify-content: center
    }
}

/* Botón flotante de WhatsApp (siempre visible) */
/* Botón flotante de WhatsApp */
/* WhatsApp flotante */
a.social-icon[href*="wa.me"] {
    position: fixed;
    right: max(18px, env(safe-area-inset-right));
    bottom: max(18px, env(safe-area-inset-bottom));
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #25d366;
    box-shadow: 0 10px 24px rgba(0, 0, 0, .25);
    z-index: 95;
    transition: transform .25s ease, box-shadow .25s ease, background .25s ease;
}

a.social-icon[href*="wa.me"] img {
    width: 28px;
    height: 28px;
    filter: brightness(0) invert(1);
    transition: transform .25s ease;
}

/* Hover con mini animación */
@media (hover:hover) {
    a.social-icon[href*="wa.me"]:hover {
        transform: scale(1.08) translateY(-2px);
        box-shadow: 0 14px 28px rgba(0, 0, 0, .3);
        background: #20bd5a;
        /* tono más oscuro */
    }

    a.social-icon[href*="wa.me"]:hover img {
        transform: rotate(-8deg) scale(1.1);
    }
}

/* En pantallas muy chicas lo achicamos un poco */
@media (max-width:360px) {
    a.social-icon[href*="wa.me"] {
        width: 48px;
        height: 48px;
    }

    a.social-icon[href*="wa.me"] img {
        width: 24px;
        height: 24px;
    }
}