/* 页脚联系：简洁列表，自动换行，无横向滚动 */
.footer-gk-contact {
    flex: 1 1 0;
    min-width: 0;
    max-width: 100%;
    align-self: center;
}

.footer-gk-contact__list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(148px, 1fr));
    gap: 14px 28px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.footer-gk-contact__item {
    margin: 0;
    padding: 0;
    min-width: 0;
}

.footer-gk-contact__link {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 2px 0;
    color: inherit;
    text-decoration: none;
    transition: opacity .2s ease, transform .2s ease;
    border: none;
    background: none;
    font: inherit;
    cursor: pointer;
    text-align: left;
    width: 100%;
}

button.footer-gk-contact__link--btn {
    width: auto;
}

.footer-gk-contact__link--static {
    cursor: default;
}

.footer-gk-contact__link:hover,
.footer-gk-contact__link:focus,
button.footer-gk-contact__link--btn:hover,
button.footer-gk-contact__link--btn:focus {
    color: inherit;
    text-decoration: none;
    opacity: .82;
    transform: translateX(2px);
}

.footer-gk-contact__icon {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    object-fit: contain;
}

.footer-gk-contact__body {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.footer-gk-contact__label {
    font-size: 11px;
    line-height: 1.3;
    color: #9ca3af;
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.footer-gk-contact__no {
    font-size: 14px;
    line-height: 1.25;
    color: #374151;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    letter-spacing: .02em;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.footer-gk-contact__link:hover .footer-gk-contact__no,
button.footer-gk-contact__link--btn:hover .footer-gk-contact__no {
    color: #194bf1;
}

@media (max-width: 1199px) {
    .footer-gk-contact {
        flex: 1 1 100%;
        order: 2;
    }
}

@media (max-width: 991px) {
    .footer-gk-contact {
        order: 2;
        width: 100%;
    }

    .footer-gk-contact__list {
        grid-template-columns: repeat(auto-fill, minmax(132px, 1fr));
        gap: 12px 20px;
    }
}

@media (max-width: 575px) {
    .footer-gk-contact__list {
        grid-template-columns: 1fr 1fr;
        gap: 12px 16px;
    }

    .footer-gk-contact__label,
    .footer-gk-contact__no {
        white-space: normal;
    }
}

/* 右侧 QQ 售前售后咨询（与交流群 / 页脚同源） */
.qq-consult-float {
    position: fixed;
    top: 38%;
    right: 0;
    z-index: 1080;
    width: 32px;
    height: 136px;
    font-size: 13px;
    pointer-events: none;
}

.qq-consult-float__tab {
    position: relative;
    z-index: 1;
    width: 32px;
    height: 136px;
    border: none;
    border-radius: 8px 0 0 8px;
    background: linear-gradient(180deg, #2f7dff, #1a5fe8);
    color: #fff;
    box-shadow: -3px 2px 12px rgba(26, 95, 232, .3);
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 10px 4px;
    pointer-events: auto;
}

.qq-consult-float__tab-icon {
    width: 16px;
    height: 16px;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.qq-consult-float__tab-text {
    writing-mode: vertical-rl;
    text-orientation: upright;
    white-space: nowrap;
    letter-spacing: 4px;
    font-size: 13px;
    font-weight: 700;
    line-height: 1;
    flex-shrink: 0;
}

.qq-consult-float__tab-caret {
    font-size: 12px;
    opacity: .9;
    transition: transform .2s ease;
}

.qq-consult-float.is-open .qq-consult-float__tab-caret,
.qq-consult-float:hover .qq-consult-float__tab-caret {
    transform: rotate(180deg);
}

.qq-consult-float__panel {
    position: absolute;
    right: 32px;
    bottom: 0;
    width: 0;
    max-height: min(70vh, 480px);
    overflow: hidden;
    opacity: 0;
    background: #fff;
    border-radius: 12px 0 0 12px;
    box-shadow: -6px 0 24px rgba(0, 0, 0, .12);
    border: 1px solid #e8eef8;
    border-right: none;
    display: flex;
    flex-direction: column;
    transition: width .28s ease, opacity .22s ease;
    pointer-events: none;
}

.qq-consult-float.is-open .qq-consult-float__panel,
.qq-consult-float:hover .qq-consult-float__panel {
    width: min(280px, calc(100vw - 44px));
    opacity: 1;
    pointer-events: auto;
}

.qq-consult-float__head {
    padding: 14px 16px 10px;
    background: linear-gradient(135deg, #eff6ff, #f8fbff);
    border-bottom: 1px solid #eef2f7;
    flex-shrink: 0;
}

.qq-consult-float__title {
    display: block;
    font-size: 15px;
    font-weight: 700;
    color: #1e3a8a;
    line-height: 1.3;
}

.qq-consult-float__sub {
    display: block;
    margin-top: 2px;
    font-size: 11px;
    color: #94a3b8;
}

.qq-consult-float__list {
    grid-template-columns: 1fr !important;
    gap: 10px 0 !important;
    padding: 12px 16px;
    max-height: min(52vh, 420px);
    overflow-y: auto;
}

.qq-consult-float__more {
    display: block;
    margin: 0 16px 14px;
    padding: 8px 0;
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    color: #1a5fe8;
    text-decoration: none;
    border-top: 1px dashed #e5eaf3;
}

.qq-consult-float__more:hover,
.qq-consult-float__more:focus {
    color: #1248b8;
    text-decoration: none;
}

body.user-member-layout .qq-consult-float,
body.has-rank-float .qq-consult-float {
    display: none;
}

@media (min-width: 1201px) {
    /* 贴在右侧统计条收起按钮正下方 */
    body:has(.home-site-stats) .qq-consult-float {
        top: calc(72px + (100vh - 96px) / 2 + 37px);
        bottom: auto;
    }
}

@media (max-width: 767px) {
    .qq-consult-float {
        top: auto;
        bottom: 88px;
        height: 128px;
    }

    .qq-consult-float__tab {
        height: 128px;
    }

    .qq-consult-float:hover .qq-consult-float__panel {
        width: 0;
        opacity: 0;
        pointer-events: none;
    }

    .qq-consult-float.is-open .qq-consult-float__panel {
        width: min(280px, calc(100vw - 44px));
        opacity: 1;
        pointer-events: auto;
    }
}
