/* WhatsApp Floating Button Styles */
.whatsapp-float {
    position: fixed;
    width: 60px;
    height: 60px;
    bottom: 20px;
    right: 20px;
    background-color: #25d366;
    color: white;
    border-radius: 50px;
    text-align: center;
    font-size: 30px;
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.4);
    z-index: 1000;
    transition: all 0.3s ease;
    opacity: 0;
    transform: scale(0.8) translateY(20px);
}

.whatsapp-float.whatsapp-loaded {
    opacity: 1;
    transform: scale(1) translateY(0);
}

.whatsapp-float:hover {
    background-color: #128c7e;
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.6);
}

.whatsapp-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    text-decoration: none;
    color: inherit;
    border-radius: 50px;
    position: relative;
    overflow: hidden;
}

.whatsapp-link:hover,
.whatsapp-link:focus {
    color: white;
    text-decoration: none;
}

.whatsapp-icon {
    width: 32px;
    height: 32px;
    transition: transform 0.3s ease;
}

.whatsapp-text {
    position: absolute;
    right: 70px;
    background-color: #25d366;
    color: white;
    padding: 8px 12px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    opacity: 0;
    transform: translateX(10px);
    transition: all 0.3s ease;
    pointer-events: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.whatsapp-text::after {
    content: '';
    position: absolute;
    top: 50%;
    right: -5px;
    transform: translateY(-50%);
    width: 0;
    height: 0;
    border-left: 5px solid #25d366;
    border-top: 5px solid transparent;
    border-bottom: 5px solid transparent;
}

.whatsapp-float:hover .whatsapp-text {
    opacity: 1;
    transform: translateX(0);
}

.whatsapp-float:hover .whatsapp-icon {
    transform: rotate(10deg);
}

/* Pulse animation for attention */
.whatsapp-float::before {
    content: '';
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    border-radius: 50px;
    background-color: #25d366;
    opacity: 0.3;
    animation: whatsapp-pulse 2s infinite;
    z-index: -1;
}

@keyframes whatsapp-pulse {
    0% {
        transform: scale(1);
        opacity: 0.3;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.1;
    }
    100% {
        transform: scale(1);
        opacity: 0.3;
    }
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    .whatsapp-float {
        width: 55px;
        height: 55px;
        bottom: 15px;
        right: 15px;
    }
    
    .whatsapp-icon {
        width: 28px;
        height: 28px;
    }
    
    .whatsapp-text {
        font-size: 12px;
        padding: 6px 10px;
        right: 65px;
    }
}

@media (max-width: 480px) {
    .whatsapp-float {
        width: 50px;
        height: 50px;
        bottom: 10px;
        right: 10px;
    }
    
    .whatsapp-icon {
        width: 24px;
        height: 24px;
    }
    
    /* Hide text on very small screens to save space */
    .whatsapp-text {
        display: none;
    }
}

/* Ensure compatibility with Bootstrap */
.whatsapp-float * {
    box-sizing: border-box;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .whatsapp-float {
        border: 2px solid #000;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .whatsapp-float,
    .whatsapp-icon,
    .whatsapp-text {
        transition: none;
    }
    
    .whatsapp-float::before {
        animation: none;
    }
}