/* ========== INICIO: Estilos Botón WhatsApp ========== */
.whatsapp-container {
    position: fixed;
    bottom: 65px;
    right: 65px;
    z-index: 9999;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Botón principal */
.whatsapp-float {
    position: relative;
    width: 60px;
    height: 60px;
    background: #25D366;
    color: white;
    border-radius: 50px;
    text-align: center;
    font-size: 30px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all 0.3s ease;
    overflow: hidden;
    cursor: pointer;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.4);
}

.whatsapp-float:hover .whatsapp-text {
    max-width: 120px;
    margin-left: 8px;
    opacity: 1;
}

/* Icono SVG */
.whatsapp-icon {
    width: 30px;
    height: 30px;
    transition: all 0.3s ease;
}

/* Texto del botón */
.whatsapp-text {
    position: absolute;
    right: 65px;
    background: #25D366;
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    white-space: nowrap;
    font-size: 14px;
    font-weight: 500;
    opacity: 0;
    transition: all 0.3s ease;
    max-width: 0;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

/* Efecto de pulso */
.whatsapp-pulse {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: rgba(37, 211, 102, 0.5);
    animation: pulse-whatsapp 2s infinite;
    pointer-events: none;
    z-index: 99;
}

@keyframes pulse-whatsapp {
    0% {
        transform: translate(-50%, -50%) scale(0.95);
        opacity: 1;
    }

    70% {
        transform: translate(-50%, -50%) scale(1.5);
        opacity: 0;
    }

    100% {
        transform: translate(-50%, -50%) scale(0.95);
        opacity: 0;
    }
}

/* Tooltip/Mensaje */
.whatsapp-tooltip {
    position: absolute;
    bottom: 80px;
    right: 0;
    background: white;
    border-radius: 10px;
    padding: 15px 20px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
    min-width: 250px;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s ease;
    pointer-events: none;
    border: 1px solid #e0e0e0;
}

.whatsapp-tooltip.show {
    opacity: 1;
    transform: translateY(0);
    pointer-events: all;
}

.whatsapp-tooltip::after {
    content: '';
    position: absolute;
    bottom: -10px;
    right: 30px;
    width: 0;
    height: 0;
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-top: 10px solid white;
}

.whatsapp-tooltip p {
    margin: 0;
    color: #333;
    font-size: 14px;
    line-height: 1.5;
}

.tooltip-close {
    position: absolute;
    top: 5px;
    right: 10px;
    cursor: pointer;
    font-size: 20px;
    color: #999;
    line-height: 1;
    transition: color 0.3s ease;
}

.tooltip-close:hover {
    color: #333;
}

/* Animación de entrada */
.whatsapp-float {
    animation: slideInUp 0.5s ease-out;
}

@keyframes slideInUp {
    from {
        transform: translateY(100px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Efecto de shake para llamar atención */
.whatsapp-shake {
    animation: shake 0.5s ease-in-out;
}

@keyframes shake {

    0%,
    100% {
        transform: rotate(0deg);
    }

    25% {
        transform: rotate(-10deg);
    }

    75% {
        transform: rotate(10deg);
    }
}

/* Responsive */
@media (max-width: 768px) {
    .whatsapp-container {
        bottom: 15px;
        right: 15px;
    }

    .whatsapp-float {
        width: 55px;
        height: 55px;
    }

    .whatsapp-icon {
        width: 28px;
        height: 28px;
    }

    .whatsapp-tooltip {
        min-width: 200px;
        right: -10px;
    }

    .whatsapp-text {
        display: none;
    }
}

/* Estados adicionales */
.whatsapp-float:active {
    transform: scale(0.95);
}

/* Modo oscuro (opcional) */
@media (prefers-color-scheme: dark) {
    .whatsapp-tooltip {
        background: #2a2a2a;
        color: white;
        border-color: #444;
    }

    .whatsapp-tooltip p {
        color: white;
    }

    .whatsapp-tooltip::after {
        border-top-color: #2a2a2a;
    }

    .tooltip-close {
        color: #ccc;
    }

    .tooltip-close:hover {
        color: white;
    }
}

/* ========== FIN: Estilos Botón WhatsApp ========== */