/* Botón flotante de WhatsApp (abajo a la derecha; el botón del plugin de accesibilidad va a la izquierda).
   Se carga aparte para que funcione con style.css y con styleSimplificadoCookies.css. */
.boton-chat {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 1000;
    width: 60px;
    height: 60px;
    padding: 0;
    border-radius: 50%;
    background: #0A8A4A; /* contraste 4,4:1 con el icono blanco */
    box-shadow: 0 4px 14px rgba(11, 34, 57, .35);
    animation: boton-chat-entrada .5s ease-out .6s both, boton-chat-latido 1.6s ease-in-out 1.4s 2;
}
/* Onda que se expande alrededor del botón (2 veces al cargar, menos de 5 segundos en total) */
.boton-chat::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 50%;
    box-shadow: 0 0 0 0 rgba(10, 138, 74, .55);
    animation: boton-chat-onda 1.6s ease-out 1.4s 2;
    pointer-events: none;
}
.boton-chat a {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    padding: 0 !important;
    border-radius: 50%;
    transition: transform .2s ease;
}
.boton-chat svg {
    width: 32px;
    height: 32px;
    fill: #fff;
}
.boton-chat a:hover {
    transform: scale(1.08);
}
.boton-chat a:focus-visible {
    outline: 3px solid #fff;
    outline-offset: 2px;
    box-shadow: 0 0 0 6px #0B2239;
}
@media only screen and (max-width: 767px) {
    .boton-chat {
        right: 16px;
        bottom: 16px;
        width: 56px;
        height: 56px;
    }
    .boton-chat svg {
        width: 30px;
        height: 30px;
    }
}
@keyframes boton-chat-entrada {
    from { opacity: 0; transform: translateY(40px) scale(.6); }
    to { opacity: 1; transform: none; }
}
@keyframes boton-chat-latido {
    0%, 100% { transform: scale(1); }
    15% { transform: scale(1.12) rotate(-8deg); }
    30% { transform: scale(1.05) rotate(6deg); }
    45% { transform: scale(1.1) rotate(-4deg); }
    60% { transform: scale(1); }
}
@keyframes boton-chat-onda {
    0% { box-shadow: 0 0 0 0 rgba(10, 138, 74, .55); }
    100% { box-shadow: 0 0 0 18px rgba(10, 138, 74, 0); }
}
@media (prefers-reduced-motion: reduce) {
    .boton-chat, .boton-chat::before { animation: none; }
    .boton-chat a { transition: none; }
    .boton-chat a:hover { transform: none; }
}
