/* Chatbot Floating Widget Styles */
#chatbot-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

#chatbot-button {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #007bff, #0056b3);
    color: white;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

#chatbot-button:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}

#chatbot-button svg {
    width: 30px;
    height: 30px;
}

#chatbot-window {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 350px;
    height: 500px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    display: none;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

#chatbot-window.active {
    display: flex;
}

#chatbot-header {
    background: linear-gradient(135deg, #007bff, #0056b3);
    color: white;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#chatbot-header h5 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
}

#chatbot-close {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    font-size: 1.5rem;
    line-height: 1;
}

#chatbot-messages {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.chat-message {
    max-width: 80%;
    padding: 10px 15px;
    border-radius: 15px;
    font-size: 0.9rem;
    line-height: 1.4;
}

.chat-message.bot {
    align-self: flex-start;
    background: #f0f2f5;
    color: #333;
    border-bottom-left-radius: 5px;
}

.chat-message.user {
    align-self: flex-end;
    background: #007bff;
    color: white;
    border-bottom-right-radius: 5px;
}

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

#chatbot-input {
    flex: 1;
    border: 1px solid #ddd;
    border-radius: 20px;
    padding: 8px 15px;
    outline: none;
    font-size: 0.9rem;
}

#chatbot-send {
    background: #007bff;
    color: white;
    border: none;
    border-radius: 50%;
    width: 35px;
    height: 35px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* RTL Support */
[dir="rtl"] #chatbot-widget {
    right: auto;
    left: 20px;
}

[dir="rtl"] #chatbot-window {
    right: auto;
    left: 0;
}

[dir="rtl"] .chat-message.bot {
    border-bottom-left-radius: 15px;
    border-bottom-right-radius: 5px;
}

[dir="rtl"] .chat-message.user {
    border-bottom-right-radius: 15px;
    border-bottom-left-radius: 5px;
}

.typing-indicator {
    font-style: italic;
    font-size: 0.8rem;
    color: #888;
    margin-bottom: 5px;
}
