﻿#ai-chat-widget {
    position: fixed;
    left: 40px;
    bottom: 40px;
    z-index: 99999;
    font-family: inherit;
    direction: rtl;
}

#ai-chat-button {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg,#006860,#00a398);
    color: #fff;
    font-size: 26px;
    cursor: pointer;
    box-shadow: 0 10px 25px rgba(37,99,235,.35), 0 0 0 8px rgba(37,99,235,.08);
    transition: .25s;
    text-align: center;
}

    #ai-chat-button:hover {
        transform: translateY(-3px);
    }

#ai-chat-box {
    display: none;
    position: absolute;
    left: 0;
    bottom: 78px;
    width: 340px;
    height: 470px;
    background: url(https://cdn.goftino.com/static/assets/img/bgchat.png);
    border-radius: 18px;
    box-shadow: 0 12px 35px rgba(0,0,0,.25);
    overflow: hidden;
    border: 1px solid #e5e7eb;
}

.ai-chat-header {
    height: 45px;
    background: linear-gradient(-90deg,#006760, transparent);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 14px;
    font-weight: 200;
    letter-spacing: -1.5px;
    border-bottom: 1px solid #ddd;
}

#ai-chat-close {
    background: transparent;
    border: none;
    color: #6f6f6f;
    font-size: 26px;
    cursor: pointer;
}

#ai-chat-messages {
    height: 350px;
    padding: 14px;
    overflow-y: auto;
}

.ai-message {
    max-width: 85%;
    padding: 9px;
    border-radius: 10px;
    margin-bottom: 10px;
    font-size: 14px;
    line-height: 1.8;
    white-space: pre-wrap;
    font-weight: 200;
    text-align: justify;
}

    .ai-message.user {
        background: #efe;
        color: #181818;
        margin-left: auto;
        border-bottom-left-radius: 0px;
        font-weight: 200;
        font-size: 12px;
        color: #000;
    }

    .ai-message.bot {
        background: linear-gradient(-90deg,#fff, #fff);
        color: #111827;
        margin-right: auto;
        border-bottom-right-radius: 0px;
        font-size: 12px;
        border: 1px solid #fff;
    }

    .ai-message.loading {
        color: #6b7280;
        font-style: italic;
    }

.ai-chat-input {
    height: 75px;
    display: flex;
    gap: 19px;
    padding: 16px;
    border-top: 1px solid #e5e7eb;
    background: #fff;
}

#ai-chat-text {
    flex: 1;
    border: 1px solid #d1d5db;
    border-radius: 12px;
    padding: 0 12px;
    outline: none;
    font-family: inherit;
}

#ai-chat-send {
    width: 70px;
    border: none;
    border-radius: 12px;
    background: #006760;
    color: #fff;
    cursor: pointer;
    font-family: inherit;
    text-align: center;
    height: 38px;
}

.ai-feedback {
    display: flex;
    gap: 6px;
    margin-top: 4px;
    margin-left: 6px;
    margin-right: 46px;
}

    .ai-feedback button {
        border: none;
        background: #f1f5f9;
        cursor: pointer;
        border-radius: 8px;
        padding: 3px 7px;
        font-size: 13px;
        transition: .2s;
    }

        .ai-feedback button:hover {
            background: #e2e8f0;
        }

        .ai-feedback button.active {
            background: #dbeafe;
            border: 1px solid #60a5fa;
        }

.ai-quick-questions {
    display: flex;
    flex-direction: column;
    gap: 7px;
    margin: 8px 0 12px 0;
    max-width: 92%;
    align-items: flex-start;
}

    .ai-quick-questions button {
        width: 100%;
        max-width: 100%;
        border: 1px solid #d8e7e5;
        background: rgba(255,255,255,.92);
        color: #006760;
        border-radius: 11px;
        padding: 7px 11px;
        font-family: inherit;
        font-size: 12px;
        line-height: 1.7;
        cursor: pointer;
        direction: rtl;
        box-shadow: 0 4px 12px rgba(0,0,0,.05);
        transition: .2s;
        text-align: center;
        font-weight: bold;
    }

        .ai-quick-questions button:hover {
            background: #eafff9;
            border-color: #00a398;
            transform: translateX(-2px);
        }

        .ai-quick-questions button:active {
            transform: scale(.98);
        }
.ai-history-toggle {
    width: 100%;
    margin: 8px 0 12px 0;
}

    .ai-history-toggle button {
        width: 100%;
        border: 1px dashed #006760;
        background: #f0fffc;
        color: #006760;
        border-radius: 12px;
        padding: 9px 12px;
        font-family: inherit;
        font-size: 12.5px;
        cursor: pointer;
        text-align: center;
    }
.ai-otp-resend-box {
    width: 100%;
    margin: 8px 0 12px 0;
}

    .ai-otp-resend-box button {
        width: 100%;
        border: 1px solid #006760;
        background: #f0fffc;
        color: #006760;
        border-radius: 12px;
        padding: 9px 12px;
        font-family: inherit;
        font-size: 12.5px;
        cursor: pointer;
        text-align: center;
    }

        .ai-otp-resend-box button:disabled {
            opacity: .65;
            cursor: not-allowed;
        }
@media (max-width: 480px) {
    #ai-chat-widget {
        left: 14px;
        bottom: 14px;
    }

    #ai-chat-box {
        width: calc(100vw - 28px);
        height: 460px;
        left: 0;
    }
}
