/* -----------------------------------------------------
   SUPERCHAT – BBQ Themed + Left Side Launcher
   Smoky colors, BBQ red, pig mascot ready
------------------------------------------------------ */

/* CHAT LAUNCHER (Floating Avatar Button) */
#superchat-launcher {
    position: fixed;
    bottom: 24px;
    left: 24px; /* moved from right → left */
    width: 64px;
    height: 64px;

    background: #ffffff;
    border-radius: 50%;
    overflow: hidden;

    display: flex;
    justify-content: center;
    align-items: center;

    cursor: pointer;
    z-index: 9999999;

    box-shadow: 0 6px 16px rgba(0,0,0,0.18);
    transition: transform 0.2s ease, box-shadow 0.2s ease;

    border: 3px solid #7f1d1d; /* BBQ red accent */
}

#superchat-launcher:hover {
    transform: scale(1.08);
    box-shadow: 0 10px 22px rgba(0,0,0,0.24);
}

#superchat-launcher img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* CHAT WINDOW */
#superchat-window {
    position: fixed;
    bottom: 105px;
    left: 24px; /* moved to left */
    width: 360px;
    height: 520px;

    background: #fff7ef; /* BBQ parchment background */
    border-radius: 14px;
    overflow: hidden;

    box-shadow: 0 20px 50px rgba(0,0,0,0.25);
    display: flex;
    flex-direction: column;

    z-index: 9999999;
}

#superchat-window.hidden {
    display: none;
}

/* HEADER */
#superchat-header {
    padding: 14px 18px;

    background: linear-gradient(135deg, #4c1d0f, #7f1d1d); /* smoked wood → BBQ red */
    color: #fff;

    display: flex;
    justify-content: space-between;
    align-items: center;

    font-size: 1.05rem;
    font-weight: 600;
}

#superchat-close {
    background: transparent;
    border: none;
    color: #fff;
    font-size: 20px;
    cursor: pointer;
    padding: 0;
    opacity: 0.75;
    transition: opacity 0.2s ease;
}

#superchat-close:hover {
    opacity: 1;
}

/* MESSAGES AREA */
#superchat-messages {
    flex: 1;
    padding: 16px;
    overflow-y: auto;
    background: #f3f0ea; /* light ash BBQ parchment */
}

/* SCROLLBAR */
#superchat-messages::-webkit-scrollbar {
    width: 6px;
}
#superchat-messages::-webkit-scrollbar-thumb {
    background: rgba(0,0,0,0.25);
    border-radius: 10px;
}

/* MESSAGE WRAPPER */
.msg {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 14px;
    max-width: 85%;
}

/* USER MESSAGE */
.msg.user {
    margin-left: auto;
    flex-direction: row-reverse;
}

.msg.user .bubble {
    background: #b91c1c; /* BBQ sauce red */
    color: #fff;
}

/* BOT MESSAGE */
.msg.bot .bubble {
    background: #f5e3c3; /* parchment menu color */
    color: #3a2a1a;
    border: 1px solid #d8b892; /* smoked brown edge */
}

/* AVATARS */
.avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 0 3px 7px rgba(0,0,0,0.2);
}

/* MESSAGE BUBBLE */
.bubble {
    padding: 10px 14px;
    border-radius: 14px;
    max-width: 240px;
    line-height: 1.4;
    font-size: 0.95rem;
    box-shadow: 0 3px 8px rgba(0,0,0,0.12);
}

/* INPUT AREA */
#superchat-input-area {
    padding: 12px;
    background: #fff7ef;
    border-top: 1px solid #d6c2a4;
    display: flex;
    gap: 10px;
}

#superchat-input {
    flex: 1;
    padding: 10px 12px;
    border-radius: 10px;
    border: 1px solid #d1d5db;
    background: #f9fafb;
    font-size: 0.95rem;
    transition: border-color 0.2s ease;
}

#superchat-input:focus {
    border-color: #b91c1c; /* BBQ red focus */
    outline: none;
}

/* SEND BUTTON */
#superchat-send {
    padding: 10px 16px;
    background: #4c1d0f; /* smoked oak */
    color: #fff;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.2s ease, transform 0.15s ease;
}

#superchat-send:hover {
    background: #7f1d1d; /* BBQ red */
    transform: translateY(-1px);
}

/* TYPING ANIMATION */
.typing .typing-bubble::after {
    content: "...";
    animation: typingDots 1s infinite steps(3);
}

@keyframes typingDots {
    0% { content: "."; }
    33% { content: ".."; }
    66% { content: "..."; }
}
