/* Enhanced Floating Buttons Component */
.floating-buttons-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
    z-index: 1000;
}

.floating-action {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    text-decoration: none;
    box-shadow: var(--shadow-floating);
    transition: var(--transition-elastic);
    position: relative;
    overflow: hidden;
    border: none;
    cursor: pointer;
    animation: float 3s ease-in-out infinite;
}

.floating-action::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent, rgba(255,255,255,0.2), transparent);
    background-size: 200% 200%;
    opacity: 0;
    transition: var(--transition);
}

.floating-action::after {
    content: attr(data-tooltip);
    position: absolute;
    right: 70px;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: var(--spacing-xs) var(--spacing-sm);
    border-radius: var(--border-radius);
    font-size: 0.8rem;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: var(--transition);
    z-index: 1001;
}

.floating-action:hover::before {
    opacity: 1;
    animation: shimmer 1.5s ease-in-out infinite;
}

.floating-action:hover::after {
    opacity: 1;
    transform: translateY(-50%) translateX(-5px);
}

.floating-action:hover {
    transform: scale(1.1);
    box-shadow: var(--shadow-neon-hover);
}

.floating-action:active {
    transform: scale(0.95);
}

/* Specific button styles */
.products-float {
    background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
    animation-delay: 0.1s;
}

.products-float:hover {
    background: linear-gradient(135deg, var(--color-primary-light), var(--color-primary));
}

.whatsapp-float {
    background: linear-gradient(135deg, #25D366, #128C7E);
    animation-delay: 0.2s;
}

.whatsapp-float:hover {
    background: linear-gradient(135deg, #25D366, #25D366);
    box-shadow: 0 0 30px rgba(37, 211, 102, 0.6);
}

.scroll-top {
    background: linear-gradient(135deg, var(--color-secondary), var(--color-secondary-dark));
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-elastic);
    animation-delay: 0.3s;
}

.scroll-top.visible {
    opacity: 1;
    visibility: visible;
}

.scroll-top:hover {
    background: linear-gradient(135deg, var(--color-secondary-light), var(--color-secondary));
    box-shadow: 0 0 30px rgba(64, 224, 224, 0.6);
}

.call-float {
    background: linear-gradient(135deg, var(--color-accent), #e55039);
    animation-delay: 0.4s;
}

.call-float:hover {
    background: linear-gradient(135deg, #ff6b6b, var(--color-accent));
    box-shadow: 0 0 30px rgba(255, 107, 107, 0.6);
}

/* Floating text for products button */
.floating-text {
    position: absolute;
    font-size: 0.7rem;
    font-weight: var(--font-weight-bold);
    bottom: -18px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 2px 6px;
    border-radius: 4px;
    opacity: 0;
    transition: var(--transition);
    white-space: nowrap;
}

.products-float:hover .floating-text {
    opacity: 1;
    bottom: -22px;
}

/* Pulse animation for attention */
.floating-action.pulse {
    animation: pulse-attention 2s ease-in-out infinite;
}

@keyframes pulse-attention {
    0%, 100% {
        box-shadow: var(--shadow-floating);
    }
    50% {
        box-shadow: 
            var(--shadow-floating),
            0 0 30px rgba(0, 112, 211, 0.8);
        transform: scale(1.05);
    }
}

/* Sequential entrance animation */
.floating-action:nth-child(1) { animation-delay: 0.1s; }
.floating-action:nth-child(2) { animation-delay: 0.3s; }
.floating-action:nth-child(3) { animation-delay: 0.5s; }
.floating-action:nth-child(4) { animation-delay: 0.7s; }

/* Mobile responsive */
@media (max-width: 768px) {
    .floating-buttons-container {
        bottom: 15px;
        right: 15px;
        gap: var(--spacing-xs);
    }
    
    .floating-action {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }
    
    .floating-action::after {
        display: none;
    }
    
    .floating-text {
        font-size: 0.6rem;
        bottom: -15px;
    }
    
    .products-float:hover .floating-text {
        bottom: -18px;
    }
}

@media (max-width: 480px) {
    .floating-buttons-container {
        bottom: 10px;
        right: 10px;
    }
    
    .floating-action {
        width: 45px;
        height: 45px;
        font-size: 1rem;
    }
}

/* High contrast mode */
@media (prefers-contrast: high) {
    .floating-action {
        border: 2px solid white;
    }
    
    .floating-action::after {
        background: black;
        border: 1px solid white;
    }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .floating-action {
        animation: none;
    }
    
    .floating-action:hover {
        transform: none;
    }
}

/* Products Float Button */
.products-float {
    position: fixed;
    bottom: 90px;
    right: 30px;
    background: var(--gradient-primary);
    color: var(--color-white);
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: var(--border-radius-xl);
    text-decoration: none;
    font-weight: var(--font-weight-bold);
    box-shadow: var(--shadow-heavy);
    z-index: 997;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    animation: productFloat 3s ease-in-out infinite, productPulse 2s infinite;
}

.products-float:hover {
    transform: translateY(-5px) scale(1.1);
    box-shadow: 0 20px 60px rgba(0, 112, 211, 0.4);
}

@keyframes productFloat {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-5px); }
}

@keyframes productPulse {
    0%, 100% {
        box-shadow: var(--shadow-heavy), 0 0 0 0 rgba(0, 112, 211, 0.7);
    }
    50% {
        box-shadow: 0 15px 40px rgba(0, 112, 211, 0.6), 0 0 0 15px rgba(0, 112, 211, 0);
    }
}

/* WhatsApp Float Button */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, #25D366, #128C7E);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-white);
    font-size: 2rem;
    text-decoration: none;
    box-shadow: 0 10px 30px rgba(37, 211, 102, 0.4);
    z-index: 998;
    transition: var(--transition);
    animation: whatsappPulse 2s infinite, whatsappFloat 3s ease-in-out infinite;
    backdrop-filter: blur(10px);
}

.whatsapp-float:hover {
    transform: scale(1.2);
    box-shadow: 0 15px 40px rgba(37, 211, 102, 0.6);
    background: linear-gradient(135deg, #128C7E, #075E54);
}

@keyframes whatsappPulse {
    0%, 100% {
        box-shadow: 0 10px 30px rgba(37, 211, 102, 0.4), 0 0 0 0 rgba(37, 211, 102, 0.7);
    }
    50% {
        box-shadow: 0 15px 40px rgba(37, 211, 102, 0.6), 0 0 0 20px rgba(37, 211, 102, 0);
    }
}

@keyframes whatsappFloat {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-8px); }
}

/* Responsive */
@media (max-width: 768px) {
    .products-float {
        bottom: 80px;
        right: 20px;
        padding: var(--spacing-sm) var(--spacing-sm);
        font-size: 0.9rem;
    }

    .whatsapp-float {
        bottom: 20px;
        right: 20px;
        width: 60px;
        height: 60px;
        font-size: 1.8rem;
    }
}

@media (max-width: 480px) {
    .products-float {
        font-size: 0.8rem;
        padding: 0.8rem var(--spacing-sm);
    }
}
