/* AI Chatbot Premium Styling */
.ai-chatbot-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 10000;
    font-family: 'Inter', sans-serif;
}

.ai-chatbot-button {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    padding: 0;
    overflow: visible;
    animation: ai-genie-float 4s ease-in-out infinite;
}

#ai-chat-icon {
    width: 60px;
    height: 60px;
    object-fit: contain;
    filter: drop-shadow(0 5px 15px rgba(0,0,0,0.2));
}

@keyframes ai-genie-float {
    0% { transform: translateY(0px) rotate(0deg); }
    25% { transform: translateY(-8px) rotate(2deg); }
    50% { transform: translateY(-15px) rotate(0deg); }
    75% { transform: translateY(-8px) rotate(-2deg); }
    100% { transform: translateY(0px) rotate(0deg); }
}

.ai-chatbot-button:hover {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 15px 30px rgba(0, 114, 255, 0.5);
}

.ai-chatbot-container {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 380px;
    height: 550px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(15px);
    border-radius: 20px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
    display: none;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.5);
    transform-origin: bottom right;
    transition: all 0.3s ease;
    opacity: 0;
    transform: scale(0.8);
}

.ai-chatbot-container.active {
    display: flex;
    opacity: 1;
    transform: scale(1);
}

.ai-chatbot-header {
    padding: 20px;
    background: linear-gradient(135deg, #00c6ff 0%, #0072ff 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: mb-2;
}

.ai-chatbot-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
}

.ai-chatbot-header .close-btn {
    margin-left: auto;
    cursor: pointer;
    background: none;
    border: none;
    color: white;
    font-size: 20px;
}

.ai-chatbot-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.ai-message {
    max-width: 80%;
    padding: 12px 16px;
    border-radius: 15px;
    font-size: 14px;
    line-height: 1.5;
}

.ai-message.bot {
    background: #f0f2f5;
    color: #1c1e21;
    align-self: flex-start;
    border-bottom-left-radius: 2px;
}

.ai-message.user {
    background: #0072ff;
    color: white;
    align-self: flex-end;
    border-bottom-right-radius: 2px;
}

.ai-chatbot-input-area {
    padding: 15px;
    border-top: 1px solid #eee;
    display: flex;
    gap: 10px;
}

.ai-chatbot-input {
    flex: 1;
    border: 1px solid #ddd;
    border-radius: 25px;
    padding: 10px 20px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.3s;
}

.ai-chatbot-input:focus {
    border-color: #0072ff;
}

.ai-chatbot-send {
    background: #0072ff;
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.3s;
}

.ai-chatbot-send:hover {
    background: #0056b3;
}

.ai-typing-indicator {
    display: none;
    align-self: flex-start;
    background: #f0f2f5;
    padding: 10px 15px;
    border-radius: 15px;
}

.ai-dot {
    width: 6px;
    height: 6px;
    background: #90949c;
    border-radius: 50%;
    display: inline-block;
    animation: ai-blink 1.4s infinite both;
    margin: 0 2px;
}

.ai-dot:nth-child(2) { animation-delay: 0.2s; }
.ai-dot:nth-child(3) { animation-delay: 0.4s; }

@keyframes ai-blink {
    0% { opacity: .2; }
    20% { opacity: 1; }
    100% { opacity: .2; }
}

@media (max-width: 480px) {
    .ai-chatbot-container {
        width: calc(100vw - 40px);
        height: calc(100vh - 120px);
    }
}
