/* Chatbot Floating Action Button */
.chatbot-fab {
    position: fixed;
    bottom: 20px;
    left: 20px;
    /* Moved to left */
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #0288d1, #01579b);
    border-radius: 50%;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 2500;
    /* Increased z-index to be safe */
    transition: transform 0.3s ease;
}

.chatbot-fab>* {
    /* Generic icon styling for i or svg */
    color: white;
    font-size: 28px;
}

.chatbot-fab:hover {
    transform: scale(1.1);
}

/* Remove img specific styles, focus on i or svg centering is handled by flex above */


/* Chat Window - Glassmorphism */
.chatbot-window {
    position: fixed;
    bottom: 90px;
    left: 20px;
    /* Moved to left */
    width: 350px;
    max-height: 500px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.5);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.15);
    display: none;
    /* Hidden by default */
    flex-direction: column;
    z-index: 1000;
    overflow: hidden;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.chatbot-window.active {
    display: flex;
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Header */
.chatbot-header {
    background: linear-gradient(135deg, #0288d1, #01579b);
    color: white;
    padding: 15px;
    font-weight: bold;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chatbot-close {
    cursor: pointer;
    font-size: 1.2rem;
    opacity: 0.8;
}

.chatbot-close:hover {
    opacity: 1;
}

/* Body */
.chatbot-body {
    padding: 15px;
    overflow-y: auto;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 400px;
}

/* Messages */
.chat-message {
    padding: 10px 15px;
    border-radius: 15px;
    max-width: 85%;
    line-height: 1.4;
    font-size: 0.9rem;
    animation: popIn 0.3s ease;
}

@keyframes popIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.chat-message.bot {
    background: #f1f3f4;
    color: #333;
    align-self: flex-start;
    border-bottom-left-radius: 2px;
}

.chat-message.user {
    background: #0288d1;
    color: white;
    align-self: flex-end;
    border-bottom-right-radius: 2px;
}

/* Options/Buttons */
.chat-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 10px;
}

.chat-option-btn {
    background: white;
    border: 1px solid #0288d1;
    color: #0288d1;
    padding: 8px 12px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.85rem;
    text-align: left;
    transition: all 0.2s;
}

.chat-option-btn:hover {
    background: #0288d1;
    color: white;
}

/* Mobile Responsive */
@media (max-width: 480px) {
    .chatbot-window {
        width: 100%;
        bottom: 0;
        right: 0;
        border-radius: 15px 15px 0 0;
        height: 80vh;
        max-height: 80vh;
    }
}