/* chatbot.css */

/* Chatbot Container: Fixed position in the bottom right */
.chatbot-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 300px;
    z-index: 1000; /* Ensure it's above other content */
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; /* Consistent font */
}

/* Toggle Button: The floating icon */
.chatbot-toggle-button {
    background-color: #8b5a5a; /* Primary navigation color */
    color: white;
    border: none;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    cursor: pointer;
    font-size: 24px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s ease, transform 0.3s ease;
    margin-left: auto; /* Aligns button to the right of its container */
}

.chatbot-toggle-button:hover {
    background-color: #704848; /* Darker primary color on hover */
    transform: scale(1.05);
}

/* Chat Window: The main chat interface */
.chat-window {
    background-color: #ffffff;
    border-radius: 10px;
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.4);
    margin-top: 10px;
    height: 400px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid #ddd;
    display: none; /* Hidden by default, JS will change this to 'flex' */
}

/* Chat Header */
.chat-header {
    background: linear-gradient(135deg, #8b5a5a 0%, #704848 100%); /* Matches nav gradient */
    color: white;
    padding: 12px;
    text-align: center;
    font-weight: 600;
    font-size: 1.1em;
}

/* Chat Body: Message display area */
.chat-body {
    flex-grow: 1;
    padding: 10px;
    overflow-y: auto;
    background-color: #f8f9fa; /* Matches body background color */
}

/* Message Styles */
.message {
    margin-bottom: 10px;
    padding: 8px 12px;
    border-radius: 15px;
    max-width: 80%;
    word-wrap: break-word;
    font-size: 0.9em;
    line-height: 1.4;
}

.user-message {
    background-color: #d1e7dd; /* Light color for user messages */
    margin-left: auto; /* Align to the right */
    text-align: right;
}

.bot-message {
    background-color: #eee; /* Light grey for bot messages */
    margin-right: auto; /* Align to the left */
}

/* Input Area */
.chat-input-area {
    display: flex;
    border-top: 1px solid #ddd;
    padding: 8px;
    background-color: #fff;
}

.chat-input-area input {
    flex-grow: 1;
    border: 1px solid #ccc;
    border-radius: 20px;
    padding: 8px 12px;
    margin-right: 5px;
    font-size: 14px;
    outline: none;
}

.chat-input-area button {
    background-color: #704848; /* Darker accent color */
    color: white;
    border: none;
    border-radius: 50%;
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.chat-input-area button:hover {
    background-color: #5a3a3a;
}