﻿:root {
    --vs-primary: #473bf0;
    --vs-primary-2: #5b4bff;
    --vs-border: #e6e8ee;
    --vs-bot: #eef2ff;
    --vs-user: #e8fff3;
    --vs-text: #1f2937;
}

/* دکمه FAB */
.vs-btn-fab {
    position: fixed !important;
    bottom: 22px !important;
    left: 22px !important;
    top: auto !important;
    z-index: 2147483647 !important;
    /*width: 72px;
    height: 72px;*/ /* اندازه بزرگ‌تر */
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color:transparent;
    border: 0;
   /* box-shadow: 0 10px 25px rgba(0,0,0,.2);*/
    cursor: pointer;
    padding: 0;
}

.vs-left {
    left: 22px;
    right: auto;
}
/* ↙ گوشه چپ */
.vs-btn-fab img {
    pointer-events: none;
    border-radius: 50%;
 /*   width: 64px;
    height: 64px;*/
}

/* باکس چت */
.vs-chatbox {
    position: fixed;
    bottom: 96px;
    z-index: 99998;
    width: 360px;
    max-height: 70vh;
    display: none;
    flex-direction: column;
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 18px 40px rgba(0,0,0,.25);
}

    .vs-chatbox.vs-left {
        left: 22px;
        right: auto;
    }

@media (max-width:480px) {
    .vs-chatbox {
        left: 10px !important;
        right: 10px !important;
        width: auto;
    }
}

.vs-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    color: #fff;
    background: linear-gradient(125deg,var(--vs-primary),#2a246a);
}

.vs-brand {
    display: flex;
    gap: 10px;
    align-items: center
}

.vs-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #fff
}

.vs-title {
    font-weight: 700;
    font-size: 14px
}

.vs-sub {
    opacity: .85;
    font-size: 12px
}

.vs-close {
    background: transparent;
    border: 0;
    color: #fff;
    font-size: 16px;
    cursor: pointer
}

.vs-messages {
    padding: 14px;
    height: calc(70vh - 160px);
    overflow: auto;
    background: #fafbff
}

.vs-msg {
    display: flex;
    margin: 8px 0
}

.vs-bot {
    justify-content: flex-start
}

.vs-user {
    justify-content: flex-end
}

.vs-bubble {
    max-width: 80%;
    padding: 10px 12px;
    border-radius: 14px;
    line-height: 1.7;
    font-size: 14px;
    color: var(--vs-text);
    white-space: pre-wrap
}

.vs-bot .vs-bubble {
    background: var(--vs-bot);
    border: 1px solid #dfe4ff
}

.vs-user .vs-bubble {
    background: var(--vs-user);
    border: 1px solid #d6f5e5
}

.vs-typing {
    padding: 6px 16px 10px;
    background: #fafbff;
    border-top: 1px solid var(--vs-border)
}

    .vs-typing .dot {
        width: 8px;
        height: 8px;
        margin: 0 2px;
        border-radius: 50%;
        display: inline-block;
        background: #9aa3b2;
        animation: blink 1.2s infinite ease-in-out
    }

        .vs-typing .dot:nth-child(2) {
            animation-delay: .2s
        }

        .vs-typing .dot:nth-child(3) {
            animation-delay: .4s
        }

@keyframes blink {
    0%,80%,100% {
        opacity: .2
    }

    40% {
        opacity: 1
    }
}

.vs-input {
    display: flex;
    gap: 8px;
    align-items: center;
    border-top: 1px solid var(--vs-border);
    padding: 10px 12px;
    background: #fff
}

    .vs-input input {
        flex: 1;
        border: 1px solid var(--vs-border);
        border-radius: 10px;
        padding: 10px 12px;
        font-size: 14px
    }

.vs-send {
    background: var(--vs-primary);
    color: #fff;
    border: 0;
    border-radius: 10px;
    padding: 10px 14px;
    cursor: pointer
}
