/* Chatbox Container */
.chatbox {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 260px;         /* Small and subtle */
    height: 380px;        /* Compact height */
    z-index: 1000;
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
    display:none;
}


/* Chatbox Support - Always Visible */
.chatbox__support {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
    background: white;
    border-radius: 20px;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.2);
    overflow: hidden;
}

/* Chatbox Header */
.chatbox__header {
    background: linear-gradient(90deg, #8E2DE2, #4A00E0);
    color: white;
    display: flex;
    align-items: center;
    padding: 15px;
    font-size: 1.2rem;
    font-weight: bold;
    border-top-left-radius: 20px;
    border-top-right-radius: 20px;
}

/* Header Image */
.chatbox__image--header img {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    margin-right: 10px;
}

/* Ensure the message container is a flex column */
.chatbox__messages {
    display: flex;
    flex-direction: column;
    align-items: flex-start; /* Default messages align to the left */
    padding: 15px;
    overflow-y: auto;
    max-height: 350px;
    scroll-behavior: smooth;
}

/* Base message style (Increased Font Size) */
.chatbox__messages div {
    font-size: 1.2rem; /* Increased font size */
    margin: 8px 0;
    padding: 14px 20px; /* More padding for better readability */
    border-radius: 10px;
    max-width: 75%;
    word-wrap: break-word;
    display: flex; /* Allows better alignment */
}

/* User messages (Right-aligned with a box) */
.chatbox__messages div:nth-child(odd) {
    background: #8E2DE2; /* Purple Background */
    color: white; /* White text */
    font-weight: bold;
    text-align: left;
    border-radius: 15px 15px 5px 15px; /* Speech bubble style */
    align-self: flex-end; /* Moves entire box to the right */
}

/* Bot messages (Left-aligned with a box) */
.chatbox__messages div:nth-child(even) {
    background: #f3f3f3; /* Light Gray Background */
    color: #333; /* Darker text */
    font-style: italic;
    text-align: left;
    border-radius: 15px 15px 15px 5px; /* Speech bubble style */
    align-self: flex-start; /* Moves entire box to the left */
}

/* Ensure the message input box is fixed at the bottom */
.chatbox__footer {
    position: absolute;
    bottom: 0;
    width: 100%;
    display: flex;
    align-items: center;
    padding: 15px;
    background: white;
    border-bottom-left-radius: 20px;
    border-bottom-right-radius: 20px;
}


/* Suggestions Box */
.suggestions-box {
    position: absolute;
    bottom: 60px; /* Position above the input field */
    width: 90%;
    background: white;
    border: 1px solid #ddd;
    border-radius: 10px;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.1);
    padding: 10px;
    display: none; /* Hidden by default */
    max-height: 150px;
    overflow-y: auto;
    z-index: 1000; /* Ensure it's above other elements */
}

/* Suggestion Items */
.suggestion-item {
    padding: 10px;
    margin: 5px 0;
    background: #f9f9f9;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.3s ease;
    font-size: 0.9rem;
    color: #333;
}

.suggestion-item:hover {
    background: #e0e0e0; /* Highlight on hover */
}

/* Selected Suggestion */
.suggestion-item.selected {
    background: #581B98; /* Highlight selected item */
    color: white;
}


/* Chatbox Footer */
.chatbox__footer {
    display: flex;
    align-items: center;
    padding: 15px;
    background: white;
    border-bottom-left-radius: 20px;
    border-bottom-right-radius: 20px;
}

/* Message Input */
.chatbox__footer input {
    flex: 1;
    padding: 12px;
    border: none;
    border-radius: 20px;
    outline: none;
    background: #f1f1f1;
    font-size: 0.9rem;
    padding-left: 15px;
    color: #666;
    width: 100%;
}

/* Send Button */
.chatbox_send--footer {
    background: linear-gradient(90deg, #8E2DE2, #4A00E0);
    border: none;
    color: white;
    font-size: 0.9rem;
    font-weight: bold;
    padding: 8px 20px;
    border-radius: 20px;
    margin-left: 10px;
    cursor: pointer;
    transition: background 0.3s ease-in-out;
}

.chatbox_send--footer:hover {
    background: linear-gradient(90deg, #6d19c7, #3a00a1);
}

/* Remove Hidden Button */
.chatbox__button {
    display: none;
}
