/*
 * GSTORE_MALL_ONLINE_SUPPORT_CSS_V1
 *
 * 与原 contact-support 核心完全独立。
 */


/* ==========================================================
 * Desktop
 * ========================================================== */

html[data-theme-scope="front"]
.contact-support-root
.gstore-online-support-direct-v1{
    position:absolute;

    right:0;
    top:calc(100% + 8px);

    z-index:3;

    display:inline-flex;

    align-items:center;
    justify-content:center;

    width:54px;
    min-height:58px;

    padding:8px 10px;

    border:0;

    border-radius:
        16px 0 0 16px;

    background:
        linear-gradient(
            180deg,
            #3b82f6 0%,
            #2563eb 100%
        );

    color:#fff;

    box-shadow:
        0 10px 20px
        rgba(37,99,235,.20);

    text-decoration:none;

    cursor:pointer;

    pointer-events:auto;
}


html[data-theme-scope="front"]
.contact-support-root
.gstore-online-support-direct-v1:hover{
    background:
        linear-gradient(
            180deg,
            #4f8cff 0%,
            #1d4ed8 100%
        );
}


html[data-theme-scope="front"]
.gstore-online-support-direct-text-v1{
    writing-mode:vertical-rl;

    text-orientation:upright;

    letter-spacing:.08em;

    font-size:12px;
    font-weight:800;

    line-height:1.08;
}


/* ==========================================================
 * Mobile modal item
 * ========================================================== */

html[data-theme-scope="front"]
.contact-support-item
.gstore-online-support-mobile-copy-v1{
    min-width:0;
}


html[data-theme-scope="front"]
.contact-support-item.gstore-online-support-mobile-v1{
    border-color:
        rgba(37,99,235,.28);

    background:
        linear-gradient(
            180deg,
            #eff6ff 0%,
            #ffffff 100%
        );
}


html[data-theme-scope="front"]
.contact-support-item.gstore-online-support-mobile-v1:hover{
    border-color:
        rgba(37,99,235,.48);

    box-shadow:
        0 12px 24px
        rgba(37,99,235,.12);
}


html[data-theme-scope="front"]
.contact-support-item.gstore-online-support-mobile-v1
.contact-support-item-badge{
    background:
        linear-gradient(
            180deg,
            #60a5fa 0%,
            #2563eb 100%
        );

    color:#fff;
}


/* ==========================================================
 * Dark
 * ========================================================== */

html[data-theme="dark"][data-theme-scope="front"]
.contact-support-item.gstore-online-support-mobile-v1{
    background:#101d32;

    border-color:#315b96;
}


html[data-theme="dark"][data-theme-scope="front"]
.contact-support-item.gstore-online-support-mobile-v1:hover{
    background:#142541;

    border-color:#4f83c9;
}


/* ==========================================================
 * Mobile:
 * 不显示第二根悬浮条。
 * ========================================================== */

@media (max-width:900px){

    html[data-theme-scope="front"]
    .gstore-online-support-direct-v1{
        display:none !important;
    }
}


/*
 * ==========================================================
 * GSTORE_MALL_SUPPORT_UNREAD_FALLBACK_V1
 * ==========================================================
 */

.gstore-mall-support-unread-v1 {
    position: fixed;

    top:
        max(
            18px,
            env(safe-area-inset-top)
        );

    right: 18px;

    z-index: 9999;

    display: flex;
    align-items: stretch;

    width: min(
        380px,
        calc(100vw - 36px)
    );

    box-sizing: border-box;

    border:
        1px solid
        rgba(96,165,250,.38);

    border-radius: 14px;

    overflow: hidden;

    background:
        #111827;

    box-shadow:
        0 16px 45px
        rgba(0,0,0,.32);
}

.gstore-mall-support-unread-link-v1 {
    flex: 1 1 auto;

    min-width: 0;

    display: flex;
    align-items: center;

    gap: 11px;

    padding:
        13px 8px 13px 14px;

    color:
        #f8fafc;

    text-decoration:
        none;
}

.gstore-mall-support-unread-dot-v1 {
    flex: 0 0 auto;

    width: 11px;
    height: 11px;

    border-radius: 999px;

    background:
        #3b82f6;

    box-shadow:
        0 0 0 5px
        rgba(59,130,246,.14);
}

.gstore-mall-support-unread-copy-v1 {
    flex: 1 1 auto;

    min-width: 0;

    display: flex;
    flex-direction: column;

    gap: 3px;
}

.gstore-mall-support-unread-title-v1 {
    color:
        #ffffff;

    font-size:
        14px;

    font-weight:
        800;

    line-height:
        1.4;
}

.gstore-mall-support-unread-body-v1 {
    color:
        #cbd5e1;

    font-size:
        12px;

    line-height:
        1.5;
}

.gstore-mall-support-unread-close-v1 {
    flex: 0 0 auto;

    width: 42px;

    border: 0;

    background:
        transparent;

    color:
        #94a3b8;

    font-size:
        22px;

    cursor:
        pointer;
}

.gstore-mall-support-unread-close-v1:hover {
    color:
        #ffffff;

    background:
        rgba(255,255,255,.05);
}

@media (max-width: 640px) {
    .gstore-mall-support-unread-v1 {
        top:
            max(
                14px,
                env(safe-area-inset-top)
            );

        left: 14px;
        right: 14px;

        width: auto;
    }

    .gstore-mall-support-unread-link-v1 {
        padding:
            12px 6px 12px 13px;
    }
}
