/* Chatbot Button */
.ai-chatbot-button {
    position: fixed;
    bottom: 20px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: var(--ai-chatbot-primary, #667eea);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: transform 0.3s ease;
}

.ai-chatbot-button:hover {
    transform: scale(1.1);
}

.ai-chatbot-button svg {
    width: 30px;
    height: 30px;
    fill: white;
}

.ai-chatbot-button.right {
    right: 20px;
}

.ai-chatbot-button.left {
    left: 20px;
}

/* Chat Window */
.ai-chatbot-window {
    position: fixed;
    bottom: 90px;
    width: 350px;
    height: 500px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
    display: flex;
    flex-direction: column;
    z-index: 9999;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

.ai-chatbot-window.open {
    opacity: 1;
    pointer-events: all;
    transform: translateY(0);
}

.ai-chatbot-window.right {
    right: 20px;
}

.ai-chatbot-window.left {
    left: 20px;
}

/* Header */
.ai-chatbot-header {
    background: var(--ai-chatbot-primary, #667eea);
    color: white;
    padding: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.ai-chatbot-header h3 {
    margin: 0;
    font-size: 16px;
    color: white;
}

.ai-chatbot-close {
    background: none;
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
    padding: 0;
    line-height: 1;
}

/* Messages Area */
.ai-chatbot-messages {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
    background: #f8f9fa;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.ai-chatbot-message {
    max-width: 80%;
    padding: 10px 14px;
    border-radius: 12px;
    font-size: 14px;
    line-height: 1.4;
    word-wrap: break-word;
}

.ai-chatbot-message.bot {
    background: white;
    color: #333;
    align-self: flex-start;
    border-bottom-left-radius: 2px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}

.ai-chatbot-message.user {
    background: var(--ai-chatbot-primary, #667eea);
    color: white;
    align-self: flex-end;
    border-bottom-right-radius: 2px;
}

.ai-chatbot-message .meta {
    font-size: 10px;
    opacity: 0.7;
    margin-top: 4px;
    display: block;
    text-align: right;
}

/* Input Area */
.ai-chatbot-input-area {
    padding: 15px;
    background: white;
    border-top: 1px solid #eee;
    display: flex;
    gap: 10px;
}

.ai-chatbot-input {
    flex: 1;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 20px;
    outline: none;
    font-size: 14px;
}

.ai-chatbot-input:focus {
    border-color: var(--ai-chatbot-primary, #667eea);
}

.ai-chatbot-send {
    background: var(--ai-chatbot-primary, #667eea);
    color: white;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.ai-chatbot-send:hover {
    background: var(--ai-chatbot-secondary, #5a67d8);
}

.ai-chatbot-send svg {
    width: 16px;
    height: 16px;
    fill: white;
}

/* Typing Indicator */
.ai-chatbot-typing {
    display: flex;
    gap: 4px;
    padding: 10px;
    background: white;
    border-radius: 12px;
    align-self: flex-start;
    border-bottom-left-radius: 2px;
    margin-bottom: 10px;
}

.ai-chatbot-typing span {
    width: 6px;
    height: 6px;
    background: #ccc;
    border-radius: 50%;
    animation: bounce 1.4s infinite ease-in-out both;
}

.ai-chatbot-typing span:nth-child(1) { animation-delay: -0.32s; }
.ai-chatbot-typing span:nth-child(2) { animation-delay: -0.16s; }

@keyframes bounce {
    0%, 80%, 100% { transform: scale(0); }
    40% { transform: scale(1); }
}

/* Suggestions */
.ai-chatbot-suggestions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

.ai-chatbot-suggestion {
    background: white;
    border: 1px solid var(--ai-chatbot-primary, #667eea);
    color: var(--ai-chatbot-primary, #667eea);
    padding: 6px 12px;
    border-radius: 16px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.ai-chatbot-suggestion:hover {
    background: var(--ai-chatbot-primary, #667eea);
    color: white;
}
