/* FLOATING ICON */
#chatToggleBtn {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 58px;
    height: 58px;
    border-radius: 50%;
    background: #0aa357;
    color: #fff;
    font-size: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 9999;
}

/* CHAT POPUP */
#chatPopup {
    position: fixed;
    bottom: 25px;
    right: 1px;
    width: 400px;
    height: 600px;
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 12px 40px rgba(0,0,0,.2);
    display: none;
    flex-direction: column;
    z-index: 9999;
}

/* HEADER */
.chat-header {
    background: #0aa357;
    color: #fff;
    padding: 12px 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 18px 18px 0 0;
}

.chat-header-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.chat-avatar {
    width: 42px;
    height: 42px;
    background: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 10px;
    overflow: hidden;
}

.chat-avatar img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 4px;
}

#closeChat {
    cursor: pointer;
    font-size: 18px;
}

/* BODY */
.chat-body {
    flex: 1;
    padding: 15px;
    background: #f8f9fa;
    overflow-y: auto;
    font-family: Arial, sans-serif;
}

.chat.admin .msg {
    background: #f1f3f5;
    padding: 10px 14px;
    border-radius: 14px;
    font-size: 14px;
}

/* FAQ GRID (DESKTOP) */
.faq-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.faq-btn {
    border: 1px solid #0aa357;
    background: #fff;
    color: #0aa357;
    border-radius: 22px;
    padding: 8px 12px;
    font-size: 13px;
    cursor: pointer;
}

/* FOOTER */
.chat-footer {
    padding: 12px;
    background: #ffffff;
    border-top: 1px solid #e0e0e0; 
}

.chat-input-wrapper {
    display: flex;
    align-items: center;
    background: #f8f9fa;
    border-radius: 30px;
    padding: 6px 10px;
}

.chat-footer input {
    border: none;
    outline: none;
    background: transparent;
    flex: 1;
    padding: 8px 10px;
    font-size: 14px;
}

.chat-footer button {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: #02a35d;
    color: #fff;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.chat-footer button:hover {
    background: #028a4f;
}

.powered {
    text-align: center;
    font-size: 11px;
    padding: 5px;
    color: #888;
}

.chat {
    display: flex;
    margin-bottom: 12px;
}

/* ADMIN (BOT) MESSAGE */
.chat.admin {
    justify-content: flex-start;
}

.chat.admin .msg {
    background: #f1f3f5;
    color: #000;
    padding: 12px 16px;
    border-radius: 14px;
    max-width: 75%;
    font-size: 14px;
}

/* USER MESSAGE (GREEN BUTTON STYLE) */
.chat.user {
    justify-content: flex-end;
}

.chat.user .msg {
    background: #0aa357;
    color: #fff;
    padding: 10px 14px;
    border-radius: 14px;
    max-width: 75%;
    font-size: 14px;
    font-weight: 500;
}


/* ✅ MOBILE AUTO SWITCH */
@media (max-width: 768px) {
    #chatPopup {
        width: 95%;
        height: 90%;
        right: 2.5%;
        bottom: 80px;
        border-radius: 14px;
    }
}