@font-face {
    font-family: HarmonyOS;
    font-style: normal;
    font-display: swap;
    src: url(/assets/static/font/HarmonyOS_Sans_SC_Medium.subset.woff2) format('woff2')
}

.perfect_scrollbar, .perfect_scrollbar input, .perfect_scrollbar textarea, .perfect_scrollbar div, .perfect_scrollbar a {
    font-family: HarmonyOS;
}

.pvr_chat_button {
    z-index: 9999;
    position: fixed;
    bottom: 80px;
    right: 35px;
    background: linear-gradient(to left, #8f94fb, #4e54c8);
    box-shadow: 0 2px 30px 0 #ffd7e88c;
    border-radius: 75px;
    color: #fff;
    padding: 12px 20px;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    vertical-align: middle;
    font-size: 14px;
    cursor: pointer;
    -webkit-transition: all 0.2s ease;
    transition: all 0.2s ease;
}

.pvr_chat_button.chat_left {
    left: 35px;
    right: unset;
}

.pvr_chat_button i {
    vertical-align: middle;
    display: inline-block;
    font-size: 15px;
}

.pvr_chat_button span {
    vertical-align: middle;
    display: inline-block;
    font-weight: 600;
}

.pvr_chat_button i + span {
    margin-left: 15px;
}

.pvr_chat_button:hover {
    -webkit-transform: scale(1.05);
    transform: scale(1.05);
    background: linear-gradient(to left, #8f94fb, #4e54c8);
    box-shadow: 0 2px 30px 0 rgba(78, 84, 200, 0.8);
}

.pvr_chat_wrapper {
    z-index: 9999;
    position: fixed;
    bottom: 75px;
    right: 35px;
    visibility: hidden;
    opacity: 0;
    background: transparent !important;
    -webkit-transform: translateY(14px) scale(.98);
    transform: translateY(14px) scale(.98);
    -webkit-transform-origin: right bottom;
    transform-origin: right bottom;
    -webkit-transition: opacity .2s ease, transform .2s ease, visibility .2s ease;
    transition: opacity .2s ease, transform .2s ease, visibility .2s ease;
}

.pvr_chat_wrapper.chat_left {
    left: 35px;
    right: unset;
    -webkit-transform-origin: left bottom;
    transform-origin: left bottom;
}

.pvr_chat_wrapper.active {
    visibility: visible;
    opacity: 1;
    -webkit-transform: translateY(0) scale(1);
    transform: translateY(0) scale(1);
}

.pvr_chat_wrapper .pvr_chat_content {
    position: relative;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto;
    max-height: min(560px, calc(100vh - 120px));
    overflow: hidden;
    padding: 0;
    border: 1px solid #e9edf3;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 18px 44px rgba(35, 40, 52, .16);
}

.pvr_chat_wrapper .chat_header {
    position: relative;
    border-bottom: 0;
    background: linear-gradient(to left, #8f94fb, #4e54c8);
}

.pvr_chat_wrapper .pvr_chat_content .pvr-user-w {
    min-height: 64px;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    gap: 12px;
    padding: 12px 56px 12px 14px;
}

.pvr_chat_wrapper .pvr_chat_content .pvr-user-w .pvr-user-avatar-w {
    width: 40px;
    height: 40px;
    -webkit-box-flex: 0;
    -ms-flex: none;
    flex: none;
}

.pvr_chat_wrapper .pvr_chat_content .pvr-user-w .pvr-user-avatar-w .user-avatar {
    width: 100%;
    height: 100%;
    overflow: hidden;
    border-radius: 12px;
    background: rgba(255, 255, 255, .9);
    border: 2px solid rgba(255, 255, 255, .75);
}

.pvr_chat_wrapper .pvr_chat_content .pvr-user-w .pvr-user-avatar-w .user-avatar img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.pvr_chat_wrapper .pvr_chat_content .pvr-user-w .user-name {
    min-width: 0;
    -webkit-box-flex: 1;
    -ms-flex: 1;
    flex: 1;
    padding-left: 0;
}

.pvr_chat_wrapper .pvr_chat_content .pvr-user-w .user-title {
    display: block;
    overflow: hidden;
    margin: 0;
    padding: 0;
    color: #fff;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.4;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pvr_chat_wrapper .pvr_chat_content .pvr-user-w .user-title a {
    color: inherit;
    text-decoration: none;
}

.pvr_chat_wrapper .pvr_chat_content .close_chat {
    position: absolute;
    top: 12px;
    right: 14px;
    width: 34px;
    height: 34px;
    display: inline-grid;
    place-items: center;
    -webkit-box-flex: 0;
    -ms-flex: none;
    flex: none;
    border: 0;
    border-radius: 8px;
    color: #fff;
    background: transparent;
    font-size: 15px;
    line-height: 1;
    text-shadow: 0 1px 4px rgba(0, 0, 0, .55);
    cursor: pointer;
}

.pvr_chat_wrapper .pvr_chat_content .close_chat:hover {
    background: rgba(255, 255, 255, .16);
}

.pvr_chat_wrapper .chat-messages {
    height: 376px;
    min-height: 240px;
    padding: 12px 14px;
    position: relative;
    overflow: hidden;
    background: #fbfcfe;
}

.pvr_chat_wrapper .chat-messages .message {
    margin-bottom: 10px;
}

.pvr_chat_wrapper .chat-messages .message .message-content,
.pvr_chat_wrapper .chat-messages.theme_1 .message .message-content,
.pvr_chat_wrapper .chat-messages.theme_2 .message .message-content,
.pvr_chat_wrapper .chat-messages.theme_3 .message .message-content,
.pvr_chat_wrapper .chat-messages.theme_4 .message .message-content {
    max-width: 82%;
    display: inline-block;
    padding: 9px 12px;
    border: 1px solid #e8edf3;
    border-radius: 13px 13px 13px 4px;
    color: #2b313a;
    background: #fff;
    box-shadow: 0 6px 16px rgba(35, 40, 52, .05);
    font-size: 13px;
    line-height: 1.55;
    text-align: left;
}

.pvr_chat_wrapper .chat-messages.theme_1 .message.self .message-content,
.pvr_chat_wrapper .chat-messages.theme_2 .message.self .message-content,
.pvr_chat_wrapper .chat-messages.theme_3 .message.self .message-content,
.pvr_chat_wrapper .chat-messages.theme_4 .message.self .message-content {
    border-color: transparent;
    border-radius: 13px 13px 4px 13px;
    color: #fff;
    background: #6b6fe6;
    box-shadow: 0 8px 18px rgba(107, 111, 230, .2);
}

.pvr_chat_wrapper .chat-messages .message.self {
    text-align: right;
}

.pvr_chat_wrapper .chat-messages .message .message-time,
.pvr_chat_wrapper .chat-messages.theme_2 .message .message-time {
    margin-top: 4px;
    color: #a0a8b3;
    font-size: 11px;
    line-height: 1.4;
}

.pvr_chat_wrapper .chat-messages .date-break {
    text-align: center;
    margin-bottom: 10px;
    color: #9aa3ad;
    font-size: 12px;
}

.message-history {
    text-align: center;
    margin-bottom: 12px;
}

.message-history .history-show {
    min-height: 30px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 12px;
    border: 1px solid #e3e8ef;
    border-radius: 999px;
    color: #66707c;
    background: #fff;
    font-size: 12px;
    line-height: 1;
    cursor: pointer;
}

.message-history .history-show:hover {
    border-color: #d2d9e4;
    color: #3d4652;
}

.pvr_chat_wrapper .chat-controls {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr) 62px;
    gap: 8px;
    align-items: stretch;
    padding: 10px;
    border-top: 1px solid #edf0f5;
    background: #fff;
}

.pvr_chat_wrapper .chat-controls .message-input {
    width: 100%;
    height: 52px;
    min-height: 52px;
    max-height: 52px;
    display: block;
    resize: none;
    padding: 14px 12px;
    border: 1px solid #dfe5ee;
    border-radius: 10px;
    outline: none;
    color: #232932;
    background-color: #fff;
    font-size: 13px;
    line-height: 1.45;
}

.pvr_chat_wrapper .chat-controls .message-input:focus {
    border-color: #9aa7ef;
    box-shadow: 0 0 0 3px rgba(107, 111, 230, .12);
}

.pvr_chat_wrapper .chat-controls .message-input:disabled {
    color: #9aa3ad;
    background: #f7f9fc;
}

.pvr_chat_wrapper .chat-controls .send_image,
.pvr_chat_wrapper .chat-controls .send_message {
    min-width: 0;
    width: 100%;
    height: 52px;
    display: inline-grid;
    place-items: center;
    border-radius: 10px;
    text-decoration: none;
}

.pvr_chat_wrapper .chat-controls .send_image {
    border: 1px solid #e2e7ef;
    color: #7a8390;
    background: #fff;
    font-size: 18px;
}

.pvr_chat_wrapper .chat-controls .send_image:hover {
    border-color: #d4dbe6;
    color: #555f6d;
    background: #f8fafc;
}

.pvr_chat_wrapper .chat-controls .send_message {
    color: #fff;
    background: #6b6fe6;
    box-shadow: 0 8px 16px rgba(107, 111, 230, .2);
    font-size: 14px;
    font-weight: 700;
}

.pvr_chat_wrapper .chat-controls .send_message:hover {
    background: #5f63dc;
}

.send_message {
    float: none;
}

.pvr_chat_wrapper .material-icons {
    font-size: 18px !important;
}

.bot-keywords {
    font-size: 13px;
    font-weight: normal;
    cursor: pointer;
    color: #5f63dc !important;
    display: block;
}

@media (max-width: 768px) {
    .pvr_chat_wrapper {
        left: 18px;
        right: 18px;
        bottom: 112px;
        -webkit-transform-origin: center bottom;
        transform-origin: center bottom;
    }

    .pvr_chat_wrapper.chat_left {
        left: 18px;
        right: 18px;
    }

    .pvr_chat_wrapper .pvr_chat_content {
        width: 100%;
        max-width: none;
        max-height: min(52vh, 430px);
        border-radius: 16px;
    }

    .pvr_chat_wrapper .pvr_chat_content .pvr-user-w {
        min-height: 56px;
        gap: 10px;
        padding: 10px 50px 10px 12px;
    }

    .pvr_chat_wrapper .pvr_chat_content .pvr-user-w .pvr-user-avatar-w {
        width: 36px;
        height: 36px;
    }

    .pvr_chat_wrapper .pvr_chat_content .pvr-user-w .user-name {
        display: block !important;
        min-width: 0;
        opacity: 1 !important;
        visibility: visible !important;
    }

    .pvr_chat_wrapper .pvr_chat_content .pvr-user-w .user-title {
        display: block !important;
        color: #fff !important;
        font-size: 14px;
        opacity: 1 !important;
        visibility: visible !important;
    }

    .pvr_chat_wrapper .pvr_chat_content .close_chat {
        top: 11px;
        right: 12px;
    }

    .pvr_chat_wrapper .chat-messages {
        height: calc(52vh - 128px);
        min-height: 170px;
        max-height: 300px;
    }

    .pvr_chat_wrapper .chat-controls {
        grid-template-columns: 52px minmax(0, 1fr) 62px;
    }
}
