/* Chat Bubble */
#chat-bubble {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
}

#chat-toggle {
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, background-color 0.3s ease;
}

#chat-toggle:hover {
    transform: scale(1.1);
    background-color: #0056b3;
}

/* Chat Window */
.chat-window {
    width: 320px;
    height: 450px;
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    display: none;
    flex-direction: column;
    overflow: hidden;
    position: fixed;
    bottom: 80px;
    right: 20px;
}

/* Header */
.chat-header {
    background-color: #007bff;
    color: white;
    padding: 15px;
    font-size: 16px;
    font-weight: bold;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-header .close-chat {
    background: none;
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
}

/* Chat Body */
.chat-body {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
    display: flex;
    direction: rtl;
    text-align: right;
    flex-direction: column;
    gap: 10px;
}

/* Chat Messages */
.message {
    max-width: 70%;
    padding: 10px 15px;
    border-radius: 15px;
    font-size: 14px;
    word-wrap: break-word;
    overflow-wrap: break-word;
    display: inline-block;
}

.user-message {
    background-color: #d1e7dd;
    align-self: flex-end;
    text-align: right;
}

.assistant-message {
    background-color: #fbf8cc;
    align-self: flex-start;
    text-align: left;
}

/* Chat Input */
.chat-form {
    display: flex;
    align-items: center;
    padding: 10px;
    border-top: 1px solid #ddd;
    background-color: #f8f9fa;
}

.chat-form input {
    flex: 1;
    border: none;
    border-radius: 20px;
    padding: 10px 15px;
    margin-right: 10px;
    font-size: 14px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.chat-form button {
    background-color: #007bff;
    border: none;
    border-radius: 50%;
    color: white;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.chat-form button:hover {
    background-color: #0056b3;
}
