﻿/* Floating Social Media Container */
.floating-social-media {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Social Icon Styles */
.social-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    color: white;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
    position: relative;
    animation: slideInRight 0.5s ease forwards;
    opacity: 0;
}

    /* Individual Icon Colors */
    .social-icon.whatsapp {
        background: linear-gradient(45deg, #25D366, #128C7E);
        animation-delay: 0.1s;
    }

    .social-icon.facebook {
        background: linear-gradient(45deg, #3b5998, #2d4373);
        animation-delay: 0.2s;
    }

    .social-icon.instagram {
        background: linear-gradient(45deg, #f09433, #d62976, #962fbf, #4f5bd5);
        animation-delay: 0.3s;
    }

    .social-icon.twitter {
        background: linear-gradient(45deg, #1DA1F2, #0d8bd9);
        animation-delay: 0.4s;
    }

    .social-icon.linkedin {
        background: linear-gradient(45deg, #0077b5, #005582);
        animation-delay: 0.5s;
    }

    .social-icon.youtube {
        background: linear-gradient(45deg, #FF0000, #CC0000);
        animation-delay: 0.6s;
    }

    /* Icon Hover Effects */
    .social-icon:hover {
        transform: translateY(-5px) scale(1.1);
        box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
    }

    .social-icon i {
        font-size: 24px;
        transition: transform 0.3s ease;
    }

    .social-icon:hover i {
        transform: rotate(360deg);
    }

/* Tooltip Styles */
.tooltip {
    position: absolute;
    right: 70px;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    pointer-events: none;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

    .tooltip::after {
        content: '';
        position: absolute;
        right: -5px;
        top: 50%;
        transform: translateY(-50%);
        border-width: 5px 0 5px 5px;
        border-style: solid;
        border-color: transparent transparent transparent rgba(0, 0, 0, 0.8);
    }

.social-icon:hover .tooltip {
    opacity: 1;
    visibility: visible;
    right: 65px;
}

/* Mobile Responsive Styles */
@media (max-width: 768px) {
    .floating-social-media {
        right: 15px;
        bottom: 15px;
        gap: 10px;
    }

    .social-icon {
        width: 45px;
        height: 45px;
    }

        .social-icon i {
            font-size: 20px;
        }

    .tooltip {
        display: none; /* Hide tooltips on mobile for better UX */
    }
}

@media (max-width: 480px) {
    .floating-social-media {
        right: 10px;
        bottom: 10px;
        gap: 8px;
    }

    .social-icon {
        width: 40px;
        height: 40px;
    }

        .social-icon i {
            font-size: 18px;
        }
}

/* Animation Keyframes */
@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(100px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Pulse Animation for WhatsApp (optional) */
.social-icon.whatsapp {
    animation: slideInRight 0.5s ease forwards, pulse 2s infinite 1s;
}

@keyframes 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);
    }
}

/* Touch Device Optimizations */
@media (hover: none) and (pointer: coarse) {
    .social-icon:hover {
        transform: none;
    }

    .social-icon:active {
        transform: scale(0.95);
    }
}

/* RTL Support */
[dir="rtl"] .floating-social-media {
    right: auto;
    left: 20px;
}

[dir="rtl"] .tooltip {
    right: auto;
    left: 70px;
}

    [dir="rtl"] .tooltip::after {
        right: auto;
        left: -5px;
        transform: translateY(-50%) rotate(180deg);
    }

[dir="rtl"] .social-icon:hover .tooltip {
    right: auto;
    left: 65px;
}

@media (max-width: 768px) {
    [dir="rtl"] .floating-social-media {
        right: auto;
        left: 15px;
    }
}
