/* Social Chat Bubble Custom Styles */

#social-chat-container {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

/* Main button pulse animation */
#chat-toggle-btn {
    position: relative;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

#chat-toggle-btn::before {
    content: '';
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    border-radius: 50%;
    background: inherit;
    opacity: 0;
    animation: pulse-ring 2s cubic-bezier(0.215, 0.61, 0.355, 1) infinite;
}

@keyframes pulse-ring {
    0% {
        transform: scale(0.9);
        opacity: 0.5;
    }
    50% {
        opacity: 0.3;
    }
    100% {
        transform: scale(1.3);
        opacity: 0;
    }
}

/* Menu slide up animation */
#chat-menu {
    animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Button hover effects */
#chat-toggle-btn:hover {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

#chat-toggle-btn:active {
    transform: scale(0.95);
}

/* Chat option hover effects */
#chat-menu a {
    text-decoration: none;
    display: flex;
}

#chat-menu a:hover {
    transform: translateX(2px);
}

/* Smooth transitions */
#chat-menu,
#chat-menu a,
#chat-toggle-btn {
    transition: all 0.3s ease;
}

/* Notification badge */
.notification-badge {
    position: absolute;
    top: -2px;
    right: -2px;
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
    border-radius: 9999px;
    width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: bold;
    animation: badge-pulse 2s infinite;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.4);
    border: 2px solid white;
}

@keyframes badge-pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

/* Mobile responsiveness */
@media (max-width: 640px) {
    #social-chat-container {
        bottom: 1rem;
        right: 1rem;
    }
    
    #chat-toggle-btn {
        width: 56px;
        height: 56px;
    }
    
    #chat-toggle-btn svg {
        width: 28px;
        height: 28px;
    }
    
    #chat-menu {
        width: calc(100vw - 2rem);
        max-width: 300px;
    }
}

/* Print styles - hide chat bubble when printing */
@media print {
    #social-chat-container {
        display: none !important;
    }
}

/* Focus styles for accessibility */
#chat-toggle-btn:focus,
#chat-close-btn:focus {
    outline: 3px solid rgba(59, 130, 246, 0.5);
    outline-offset: 2px;
}

/* Icon animations */
#chat-menu a svg {
    transition: transform 0.2s ease;
}

#chat-menu a:hover svg:last-child {
    transform: translateX(3px);
}

/* Gradient background animation */
@keyframes gradient-shift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

#chat-toggle-btn {
    background-size: 200% 200%;
    animation: gradient-shift 3s ease infinite;
}

/* WhatsApp green hover */
#chat-menu a:has(.bg-green-500):hover {
    background-color: rgba(34, 197, 94, 0.05);
}

/* LINE green hover */
#chat-menu a:has(.bg-green-400):hover {
    background-color: rgba(74, 222, 128, 0.05);
}

/* Shadow effects */
#chat-menu {
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 
                0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* Close button hover effect */
#chat-close-btn {
    border-radius: 50%;
    padding: 2px;
}

#chat-close-btn:hover {
    background-color: rgba(255, 255, 255, 0.2);
}
