/* Floating Chatbot Button Styles */
.chatbot-float-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 9999;
}

.chatbot-close-btn {
    position: absolute;
    top: -6px;
    right: -6px;
    width: 24px;
    height: 24px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(0, 0, 0, 0.1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    z-index: 10001;
}

.chatbot-close-btn:hover {
    background: rgba(255, 255, 255, 0.95);
    transform: scale(1.15);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
    border: 1px solid rgba(0, 0, 0, 0.15);
}

.chatbot-close-btn:active {
    transform: scale(1.05);
    transition: transform 0.1s ease;
}

.chatbot-float-container:hover .chatbot-close-btn {
    opacity: 1;
    visibility: visible;
    animation: closeButtonAppear 0.3s ease-out;
}

.chatbot-close-icon {
    width: 12px;
    height: 12px;
    fill: #666;
    transition: transform 0.2s ease;
}

.chatbot-close-btn:hover .chatbot-close-icon {
    transform: rotate(90deg);
    fill: #333;
}

/* Close button appear animation */
@keyframes closeButtonAppear {
    0% {
        opacity: 0;
        transform: scale(0.5) rotate(-180deg);
    }
    70% {
        transform: scale(1.1) rotate(-10deg);
    }
    100% {
        opacity: 1;
        transform: scale(1) rotate(0deg);
    }
}

.chatbot-float-button {
    width: 60px;
    height: 60px;
    background: #333;
    border-radius: 50%;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    border: none;
    text-decoration: none;
    position: relative;
}

.chatbot-float-button:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 25px rgba(0, 0, 0, 0.4);
    background: #555;
}

.chatbot-float-button:active {
    transform: scale(0.95);
}

.chatbot-icon {
    width: 28px;
    height: 28px;
    fill: white;
    transition: all 0.3s ease;
}

.chatbot-float-button:hover .chatbot-icon {
    transform: rotate(10deg);
}

/* Tooltip */
.chatbot-tooltip {
    position: absolute;
    right: 70px;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 12px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    font-family: Arial, sans-serif;
}

.chatbot-tooltip::after {
    content: '';
    position: absolute;
    right: -5px;
    top: 50%;
    transform: translateY(-50%);
    border: 5px solid transparent;
    border-left-color: rgba(0, 0, 0, 0.8);
}

.chatbot-float-button:hover .chatbot-tooltip {
    opacity: 1;
    visibility: visible;
}

/* Responsive adjustments */
@media screen and (max-width: 768px) {
    .chatbot-button-container {
        bottom: 15px;
        right: 15px;
    }
    
    .chatbot-float-button {
        width: 55px;
        height: 55px;
    }
    
    .chatbot-icon {
        width: 24px;
        height: 24px;
    }
    
    .chatbot-close-btn {
        width: 22px;
        height: 22px;
        top: -5px;
        right: -5px;
    }
    
    .chatbot-close-icon {
        width: 10px;
        height: 10px;
    }
    
    .chatbot-tooltip {
        font-size: 10px;
        padding: 6px 10px;
        right: 65px;
    }
}

@media screen and (max-width: 480px) {
    .chatbot-button-container {
        bottom: 10px;
        right: 10px;
    }
    
    .chatbot-float-button {
        width: 50px;
        height: 50px;
    }
    
    .chatbot-icon {
        width: 22px;
        height: 22px;
    }
    
    .chatbot-close-btn {
        width: 20px;
        height: 20px;
        top: -4px;
        right: -4px;
    }
    
    .chatbot-close-icon {
        width: 9px;
        height: 9px;
    }
}

/* Animation for attention */
@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

.chatbot-float-button.pulse {
    animation: pulse 2s infinite;
}
