/* =====================================================
   MOBILE UX ENHANCEMENTS
   Floating Action Button (FAB) & Mobile Optimizations
   ===================================================== */

/* WhatsApp Floating Button */
.whatsapp-fab {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 60px;
    height: 60px;
    background: var(--canela);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 20px rgba(173, 115, 50, 0.4);
    z-index: 1000;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    text-decoration: none;
    animation: fabEntrance 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275) 1s backwards;
}

.whatsapp-fab svg {
    width: 32px;
    height: 32px;
    fill: white;
    transition: transform 0.3s ease;
}

.whatsapp-fab:hover {
    transform: translateY(-4px) scale(1.05);
    background: var(--canela-dark);
    box-shadow: 0 10px 30px rgba(173, 115, 50, 0.6);
}

.whatsapp-fab:hover svg {
    transform: rotate(15deg) scale(1.1);
}

.whatsapp-fab:active {
    transform: translateY(0) scale(0.95);
    box-shadow: 0 2px 10px rgba(173, 115, 50, 0.3);
}

/* Optional: Pulse Effect to draw attention */
.whatsapp-fab::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 2px solid var(--canela);
    opacity: 0;
    z-index: -1;
    animation: pulse-ring 2s infinite;
}

@keyframes fabEntrance {
    from {
        opacity: 0;
        transform: scale(0.5) translateY(20px);
    }

    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

@keyframes pulse-ring {
    0% {
        transform: scale(0.8);
        opacity: 0.8;
    }

    100% {
        transform: scale(1.5);
        opacity: 0;
    }
}

/* Adjust position on mobile to avoid overlapping with bottom bar if present (iOS Safari) */
@media (max-width: 768px) {
    .whatsapp-fab {
        bottom: 20px;
        right: 20px;
        width: 56px;
        height: 56px;
    }

    .whatsapp-fab svg {
        width: 30px;
        height: 30px;
    }
}