/* seemb1 购买清单悬浮购物车 */

/* 右侧 #nav-fixed 内：与 email/qq/qrcode 等同款 30px 圆形图标 */
#nav-fixed .seemb1-buy-cart-item > a {
    display: block;
    position: relative;
    line-height: 0;
}

#nav-fixed .seemb1-buy-cart-item > a img {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: block;
}

#nav-fixed .seemb1-buy-cart-item .seemb1-buy-cart-badge {
    position: absolute;
    top: -3px;
    right: -3px;
    min-width: 14px;
    height: 14px;
    padding: 0 3px;
    border-radius: 7px;
    background: #e74c3c;
    color: #fff;
    font-size: 10px;
    line-height: 14px;
    text-align: center;
    box-sizing: border-box;
    display: none;
    pointer-events: none;
}

#nav-fixed .seemb1-buy-cart-item.has-items .seemb1-buy-cart-badge {
    display: block;
}

.seemb1-buy-cart-panel {
    position: fixed;
    top: 50%;
    right: 46px;
    z-index: 55;
    width: 300px;
    max-height: min(70vh, 520px);
    transform: translateY(-50%) translateX(16px);
    background: #fff;
    border-radius: 8px;
    box-shadow: -4px 4px 24px rgba(0, 0, 0, 0.12);
    display: flex;
    flex-direction: column;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
}

.seemb1-buy-cart-panel.is-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(-50%) translateX(0);
}

.seemb1-buy-cart-panel__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    border-bottom: 1px solid #eee;
    font-size: 16px;
    font-weight: 600;
    color: #353c7c;
}

.seemb1-buy-cart-panel__close {
    border: 0;
    background: transparent;
    font-size: 22px;
    line-height: 1;
    color: #999;
    cursor: pointer;
    padding: 0 4px;
}

.seemb1-buy-cart-panel__body {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    padding: 8px 0;
}

.seemb1-buy-cart-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.seemb1-buy-cart-list__item {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 10px 16px;
    border-bottom: 1px solid #f3f3f3;
}

.seemb1-buy-cart-list__main {
    flex: 1 1 auto;
    min-width: 0;
}

.seemb1-buy-cart-list__pn {
    font-size: 14px;
    font-weight: 600;
    color: #353c7c;
    word-break: break-all;
}

.seemb1-buy-cart-list__mfr {
    margin-top: 4px;
    font-size: 12px;
    color: #888;
    word-break: break-all;
}

.seemb1-buy-cart-list__remove {
    flex: 0 0 auto;
    border: 0;
    background: transparent;
    color: #999;
    font-size: 12px;
    cursor: pointer;
    padding: 2px 0;
}

.seemb1-buy-cart-list__remove:hover {
    color: #e74c3c;
}

.seemb1-buy-cart-empty {
    margin: 0;
    padding: 28px 16px;
    text-align: center;
    font-size: 14px;
    color: #999;
}

.seemb1-buy-cart-panel__foot {
    padding: 12px 16px 16px;
    border-top: 1px solid #eee;
}

.seemb1-buy-cart-panel__calc {
    width: 100%;
    border: 0;
    border-radius: 4px;
    padding: 10px 16px;
    min-height: 40px;
    line-height: 1.4;
    background: #353c7c;
    color: #fff;
    font-size: 15px;
    cursor: pointer;
}

.seemb1-buy-cart-panel__calc:disabled {
    background: #c5c8de;
    cursor: not-allowed;
}

.seemb1-buy-cart-panel__calc:not(:disabled):hover {
    opacity: 0.92;
}

/* 移动端：#nav-fixed 隐藏时的独立入口，仍用同款 30px 图标 */
.seemb1-buy-cart-mobile {
    display: none;
    position: fixed;
    right: 10px;
    bottom: 80px;
    z-index: 55;
}

.seemb1-buy-cart-mobile__btn {
    position: relative;
    border: 0;
    padding: 0;
    background: transparent;
    cursor: pointer;
    line-height: 0;
}

.seemb1-buy-cart-mobile__btn img {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: block;
}

.seemb1-buy-cart-mobile .seemb1-buy-cart-badge {
    position: absolute;
    top: -3px;
    right: -3px;
    min-width: 14px;
    height: 14px;
    padding: 0 3px;
    border-radius: 7px;
    background: #e74c3c;
    color: #fff;
    font-size: 10px;
    line-height: 14px;
    text-align: center;
    box-sizing: border-box;
    display: none;
    pointer-events: none;
}

.seemb1-buy-cart-mobile.has-items .seemb1-buy-cart-badge {
    display: block;
}

.seemb1-buy-cart-toast {
    position: fixed;
    top: 88px;
    left: 50%;
    z-index: 60;
    transform: translateX(-50%) translateY(-12px);
    padding: 10px 18px;
    border-radius: 4px;
    background: rgba(53, 60, 124, 0.92);
    color: #fff;
    font-size: 14px;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
}

.seemb1-buy-cart-toast.is-show {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

@media (max-width: 900px) {
    #nav-fixed .seemb1-buy-cart-item {
        display: none !important;
    }

    .seemb1-buy-cart-mobile {
        display: block;
    }

    .seemb1-buy-cart-panel {
        right: 12px;
        left: 12px;
        width: auto;
        max-width: none;
        top: auto;
        bottom: 140px;
        transform: translateY(12px);
    }

    .seemb1-buy-cart-panel.is-open {
        transform: translateY(0);
    }
}
