/*
=================================================================
    WHATSAPP FLOATING BUTTON
=================================================================

Floating WhatsApp button displayed on all pages
Clean, modern design with smooth animations

Author: Poli Central
Version: 1.0.0
*/

/* ========================================
   FLOATING BUTTON CONTAINER
   ======================================== */

.whatsapp-float {
    position: fixed;
    width: 60px;
    height: 60px;
    bottom: 30px;
    right: 30px;
    background-color: #25d366;
    color: #ffffff;
    border-radius: 50px;
    text-align: center;
    font-size: 30px;
    box-shadow: 2px 2px 12px rgba(0, 0, 0, 0.3);
    z-index: 9999;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.whatsapp-float:hover {
    background-color: #128c7e;
    color: #ffffff;
    box-shadow: 2px 2px 16px rgba(0, 0, 0, 0.4);
    transform: scale(1.1);
    text-decoration: none;
}

.whatsapp-float:focus {
    outline: 2px solid #25d366;
    outline-offset: 2px;
}

/* ========================================
   WHATSAPP ICON
   ======================================== */

.whatsapp-float-icon {
    width: 35px;
    height: 35px;
    fill: #ffffff;
    transition: all 0.3s ease;
}

.whatsapp-float:hover .whatsapp-float-icon {
    transform: rotate(15deg);
}

/* ========================================
   TOOLTIP (OPTIONAL)
   ======================================== */

.whatsapp-float-tooltip {
    position: absolute;
    right: 70px;
    top: 50%;
    transform: translateY(-50%);
    background-color: #ffffff;
    color: #333;
    padding: 10px 15px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    white-space: nowrap;
    font-size: 14px;
    font-weight: 500;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    pointer-events: none;
}

.whatsapp-float-tooltip::after {
    content: '';
    position: absolute;
    right: -8px;
    top: 50%;
    transform: translateY(-50%);
    width: 0;
    height: 0;
    border-left: 8px solid #ffffff;
    border-top: 8px solid transparent;
    border-bottom: 8px solid transparent;
}

.whatsapp-float:hover .whatsapp-float-tooltip {
    opacity: 1;
    visibility: visible;
}

/* ========================================
   PULSE ANIMATION
   ======================================== */

@keyframes whatsapp-pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7);
    }
    70% {
        box-shadow: 0 0 0 15px rgba(37, 211, 102, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0);
    }
}

.whatsapp-float {
    animation: whatsapp-pulse 2s infinite;
}

.whatsapp-float:hover {
    animation: none;
}

/* ========================================
   RESPONSIVE ADJUSTMENTS
   ======================================== */

/* Tablets */
@media (max-width: 768px) {
    .whatsapp-float {
        width: 55px;
        height: 55px;
        bottom: 25px;
        right: 25px;
        font-size: 28px;
    }

    .whatsapp-float-icon {
        width: 32px;
        height: 32px;
    }

    .whatsapp-float-tooltip {
        display: none;
    }
}

/* Mobile phones */
@media (max-width: 480px) {
    .whatsapp-float {
        width: 50px;
        height: 50px;
        bottom: 20px;
        right: 20px;
        font-size: 26px;
    }

    .whatsapp-float-icon {
        width: 30px;
        height: 30px;
    }
}

/* ========================================
   ACCESSIBILITY
   ======================================== */

/* High contrast mode support */
@media (prefers-contrast: high) {
    .whatsapp-float {
        border: 2px solid #ffffff;
    }
}

/* Reduced motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
    .whatsapp-float {
        animation: none;
        transition: none;
    }

    .whatsapp-float:hover {
        transform: none;
    }

    .whatsapp-float-icon {
        transition: none;
    }
}
