/* 公告条：滚动文字只在左侧图标右侧裁切，不越过图标 */
.nb-announcement-icon {
    position: relative;
    z-index: 1;
    flex: 0 0 18px;
}
.nb-marquee-clip {
    flex: 1 1 auto;
    min-width: 0;
    height: 100%;
    overflow: hidden;
    display: flex;
    align-items: center;
}

/* SEO 面包屑 / 商品导语 */
.nb-seo-breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 8px;
    margin: 0 0 16px;
    color: #667085;
    font-size: 13px;
    line-height: 1.4;
}
.nb-seo-breadcrumb a {
    color: #667085;
    text-decoration: none;
}
.nb-seo-breadcrumb a:hover {
    color: var(--blue, #2f6feb);
}
.nb-seo-breadcrumb em {
    color: #101828;
    font-style: normal;
    font-weight: 600;
}
.nb-seo-breadcrumb-sep {
    color: #c3ccda;
    font-size: 12px;
}
.nb-buy-seo-lead {
    margin: 8px 0 0;
    color: #667085;
    font-size: 14px;
    line-height: 1.65;
}

.nb-checkout-hint {
    margin: 10px 0 0;
    color: #8a95a5;
    text-align: center;
    font-size: 12px;
}

.nb-buy-alert {
    margin: 0 0 18px;
    padding: 12px 16px;
    color: #b42318;
    border: 1px solid #fecdca;
    border-radius: 12px;
    background: #fff4f2;
    font-size: 14px;
}

.nb-buy-prompt-notice {
    padding: 12px 14px;
}

.nb-buy-prompt-copy {
    max-height: 118px;
    overflow-x: hidden;
    overflow-y: auto;
    padding-right: 8px;
    color: #758193;
    font-size: 12px;
    line-height: 1.75;
    scrollbar-color: #c3ccda transparent;
    scrollbar-width: thin;
}

.nb-buy-prompt-copy > :first-child {
    margin-top: 0;
}

.nb-buy-prompt-copy > :last-child {
    margin-bottom: 0;
}

.nb-buy-prompt-copy p,
.nb-buy-prompt-copy ul,
.nb-buy-prompt-copy ol,
.nb-buy-prompt-copy h1,
.nb-buy-prompt-copy h2,
.nb-buy-prompt-copy h3,
.nb-buy-prompt-copy h4 {
    margin: 0 0 6px;
    font-size: 12px;
    line-height: 1.75;
}

.nb-buy-prompt-copy img {
    width: auto;
    max-width: 100%;
    max-height: 82px;
    object-fit: contain;
    border-radius: 8px;
}

.nb-buy-prompt-copy::-webkit-scrollbar {
    width: 5px;
}

.nb-buy-prompt-copy::-webkit-scrollbar-thumb {
    border-radius: 999px;
    background: #c3ccda;
}

.nb-cart-stock-hint {
    margin: 12px 0 0;
    color: #cf4c14;
    text-align: center;
    font-size: 13px;
}

.nb-round-action,
.nb-mobile-cart-link {
    position: relative;
}

.nb-cart-count {
    position: absolute;
    z-index: 2;
    top: -6px;
    right: -6px;
    display: inline-grid;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    place-items: center;
    border: 2px solid #fff;
    border-radius: 999px;
    color: #fff;
    background: #ef334e;
    box-shadow: 0 4px 12px rgba(239, 51, 78, .28);
    font-size: 10px;
    font-weight: 800;
    line-height: 1;
}

.nb-mobile-cart-link .nb-cart-count {
    top: 4px;
    right: calc(50% - 24px);
}

.nb-error-page {
    display: grid;
    min-height: 560px;
    padding-top: 72px;
    padding-bottom: 72px;
    place-items: center;
}

.nb-error-card {
    width: min(100%, 620px);
    padding: 54px 44px;
    border: 1px solid #e1e8f2;
    border-radius: 28px;
    background: #fff;
    box-shadow: 0 24px 70px rgba(43, 72, 116, .1);
    text-align: center;
}

.nb-error-code {
    display: grid;
    width: 72px;
    height: 72px;
    margin: 0 auto 20px;
    place-items: center;
    border-radius: 24px;
    color: #fff;
    background: linear-gradient(135deg, #ff495c, #ff7b68);
    box-shadow: 0 16px 34px rgba(255, 73, 92, .24);
    font-size: 38px;
    font-weight: 800;
}

.nb-error-eyebrow {
    color: #2f73ea;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .14em;
}

.nb-error-card h1 {
    margin: 10px 0 12px;
    color: #172033;
    font-size: 32px;
}

.nb-error-card p {
    margin: 0;
    color: #7c889c;
    line-height: 1.8;
}

.nb-error-card a {
    display: inline-flex;
    min-width: 132px;
    min-height: 44px;
    margin-top: 28px;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: #fff;
    background: #2f73ea;
    box-shadow: 0 12px 26px rgba(47, 115, 234, .22);
    font-weight: 700;
}

@media (max-width: 640px) {
    .nb-error-page {
        min-height: 440px;
        padding: 36px 16px;
    }

    .nb-error-card {
        padding: 40px 24px;
        border-radius: 22px;
    }

    .nb-error-card h1 {
        font-size: 26px;
    }
}

/* —— 账单 / 扫码支付 —— */
.nb-bill-page,
.nb-qrpay-page {
    padding: 36px 0 72px;
}

.nb-bill-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 22px;
}

.nb-bill-eyebrow {
    display: inline-block;
    color: #2f73ea;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .14em;
}

.nb-bill-heading h1,
.nb-qrpay-card h1 {
    margin: 8px 0 8px;
    color: #172033;
    font-size: 32px;
    letter-spacing: -.5px;
}

.nb-bill-heading p,
.nb-qrpay-desc {
    margin: 0;
    color: #7c889c;
    line-height: 1.6;
}

.nb-bill-heading > a {
    padding: 10px 16px;
    color: #526176;
    border: 1px solid #dfe6ef;
    border-radius: 22px;
    background: rgba(255, 255, 255, .9);
    white-space: nowrap;
}

.nb-bill-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(280px, .9fr);
    gap: 20px;
    align-items: start;
}

.nb-bill-card {
    padding: 24px;
    border: 1px solid #e1e8f2;
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 16px 40px rgba(43, 72, 116, .07);
}

.nb-bill-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 16px;
}

.nb-bill-card-head h2 {
    margin: 0;
    font-size: 18px;
    color: #172033;
}

.nb-bill-sn {
    color: #2f73ea;
    font-size: 13px;
    font-weight: 700;
    word-break: break-all;
}

.nb-bill-rows {
    list-style: none;
    margin: 0;
    padding: 0;
}

.nb-bill-rows li {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    padding: 12px 0;
    border-top: 1px solid #eef2f7;
    color: #7c889c;
    font-size: 14px;
}

.nb-bill-rows li:first-child {
    border-top: 0;
    padding-top: 0;
}

.nb-bill-rows strong {
    color: #172033;
    text-align: right;
    font-weight: 700;
    word-break: break-all;
}

.nb-bill-rows strong.is-price {
    color: #ff495c;
    font-size: 18px;
}

.nb-bill-tip {
    margin: 0 0 16px;
    color: #7c889c;
    font-size: 13px;
    line-height: 1.6;
}

.nb-bill-total {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    margin-bottom: 18px;
    padding: 14px 16px;
    border-radius: 14px;
    background: #f5f8fc;
    color: #7c889c;
}

.nb-bill-total strong {
    color: #ff495c;
    font-size: 28px;
    letter-spacing: -.5px;
}

.nb-bill-pay-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 48px;
    border-radius: 14px;
    color: #fff !important;
    background: linear-gradient(135deg, #2f73ea, #5b8def);
    box-shadow: 0 12px 26px rgba(47, 115, 234, .24);
    font-weight: 800;
}

.nb-bill-secondary {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 42px;
    margin-top: 10px;
    color: #526176;
    border: 1px solid #dfe6ef;
    border-radius: 14px;
    background: #fff;
    font-weight: 600;
}

.nb-bill-error {
    margin: 0 0 12px;
    color: #ef4444;
    font-size: 14px;
}

.nb-qrpay-page {
    display: grid;
    place-items: center;
}

.nb-qrpay-card {
    width: min(100%, 460px);
    padding: 36px 28px;
    border: 1px solid #e1e8f2;
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 20px 50px rgba(43, 72, 116, .1);
    text-align: center;
}

.nb-qrpay-amount {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 10px;
    margin: 18px 0 20px;
    color: #7c889c;
}

.nb-qrpay-amount strong {
    color: #ff495c;
    font-size: 34px;
    letter-spacing: -.8px;
}

.nb-qrpay-frame {
    display: grid;
    place-items: center;
    width: 248px;
    height: 248px;
    margin: 0 auto 16px;
    border: 1px solid #e1e8f2;
    border-radius: 18px;
    background: #f8fafc;
}

.nb-qrpay-frame img {
    display: block;
    width: 220px;
    height: 220px;
    border-radius: 8px;
}

.nb-qrpay-sn {
    margin: 0 0 14px;
    color: #7c889c;
    font-size: 13px;
    word-break: break-all;
}

.nb-qrpay-status {
    margin: 14px 0 8px;
    color: #2f73ea;
    font-size: 14px;
    font-weight: 600;
}

.nb-qrpay-card .nb-bill-pay-btn {
    margin-top: 8px;
}

@media (max-width: 900px) {
    .nb-bill-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .nb-bill-heading {
        flex-direction: column;
        align-items: flex-start;
    }

    .nb-bill-heading h1,
    .nb-qrpay-card h1 {
        font-size: 26px;
    }

    .nb-qrpay-card {
        padding: 28px 18px;
    }
}

.nb-user-menu {
    position: relative;
    flex: 0 0 auto;
}

.nb-user-trigger {
    gap: 8px;
    max-width: 180px;
    cursor: pointer;
}

.nb-user-trigger > span:last-child {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.nb-user-avatar {
    width: 26px;
    height: 26px;
    display: inline-grid;
    place-items: center;
    flex: 0 0 26px;
    border-radius: 50%;
    color: #fff;
    background: #2f73ea;
    font-size: 11px;
    font-weight: 800;
}

.nb-user-dropdown {
    position: absolute;
    z-index: 90;
    top: calc(100% + 8px);
    right: 0;
    width: 202px;
    overflow: hidden;
    border: 1px solid #e1e7ef;
    border-radius: 0 0 20px 20px;
    background: #fff;
    box-shadow: 0 18px 42px rgba(24, 39, 65, .14);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(-8px);
    transition: opacity .16s ease, transform .16s ease, visibility .16s ease;
}

.nb-user-menu.is-open .nb-user-dropdown {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
}

.nb-user-dropdown a,
.nb-user-dropdown button {
    width: 100%;
    min-height: 46px;
    padding: 0 16px;
    display: flex;
    align-items: center;
    gap: 10px;
    border: 0;
    border-bottom: 1px solid #edf1f5;
    color: #1f2937;
    background: #fff;
    font-size: 14px;
    text-align: left;
    cursor: pointer;
}

.nb-user-dropdown a:hover,
.nb-user-dropdown button:hover {
    color: #2f6feb;
    background: #f7faff;
}

.nb-user-dropdown form {
    margin: 0;
}

.nb-user-dropdown form:last-child button {
    border-bottom: 0;
}

.nb-user-menu-icon {
    width: 18px;
    flex: 0 0 18px;
    color: #374151;
    font-size: 17px;
    line-height: 1;
    text-align: center;
}

@media (max-width: 900px) {
    .nb-user-menu {
        display: none;
    }
}

.nb-captcha-row {
    grid-template-columns: minmax(0, 1fr) 140px;
    align-items: center;
}

.nb-captcha-row img {
    display: block;
    width: 140px;
    height: 50px;
    object-fit: contain;
    background: #f8fafc;
    user-select: none;
}

@media (max-width: 420px) {
    .nb-captcha-row {
        grid-template-columns: minmax(0, 1fr) 120px;
    }

    .nb-captcha-row img {
        width: 120px;
    }
}

/* 注册页：服务条款 / 隐私政策勾选 */
.nb-auth-agree {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 4px 0 14px;
    color: #64748b;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.55;
    cursor: pointer;
    user-select: none;
}

.nb-auth-agree input[type="checkbox"] {
    width: 16px;
    height: 16px;
    margin-top: 2px;
    flex: 0 0 auto;
    accent-color: #2f6feb;
    cursor: pointer;
}

.nb-auth-agree a {
    color: #2f6feb;
    font-weight: 700;
    text-decoration: none;
}

.nb-auth-agree a:hover {
    text-decoration: underline;
}

.nb-auth-alert {
    margin: 0 0 14px;
    padding: 10px 12px;
    border: 1px solid #fecaca;
    border-radius: 12px;
    background: #fff4f4;
    color: #b42318;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.5;
}

.nb-quantity button:disabled {
    color: #aab3bf;
    background: #f3f5f8;
    cursor: not-allowed;
    opacity: .65;
}

/* ========== 首页商品卡：封面风格（图片恢复原比例/四列） ========== */
.nb-product-grid--cover {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 16px !important;
}

.nb-product-card--cover {
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
    border: 1px solid #edf0f5 !important;
    border-radius: 12px !important;
    background: #fff !important;
    box-shadow: 0 10px 24px rgba(44, 73, 116, 0.06) !important;
    transition: box-shadow .2s ease, transform .2s ease;
}

.nb-product-card--cover:hover {
    box-shadow: 0 14px 30px rgba(44, 73, 116, 0.1) !important;
    transform: translateY(-1px);
}

/* 恢复原来商品图区域大小（接近 1:1） */
.nb-product-cover {
    position: relative;
    display: block;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: linear-gradient(145deg, #e8eef7, #f4f7fb);
    text-decoration: none;
}

.nb-product-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .35s ease;
}

.nb-product-card--cover:hover .nb-product-cover img {
    transform: scale(1.04);
}

.nb-product-pin {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 4;
    display: inline-flex;
    align-items: center;
    height: 26px;
    padding: 0 10px;
    border-radius: 6px;
    color: #fff;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.06em;
    line-height: 1;
    box-shadow: 0 6px 16px rgba(217, 119, 6, 0.35);
}

.nb-product-cover-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 2;
    max-width: 46%;
    padding: 5px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.92);
    color: #334155;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
}

.nb-product-card--cover .nb-soldout-mask {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: grid;
    place-items: center;
    background: rgba(15, 23, 42, 0.42);
    color: #fff;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.04em;
}

.nb-product-card--cover .nb-product-body {
    display: flex;
    flex-direction: column;
    gap: 7px;
    padding: 12px 12px 12px !important;
    flex: 1 1 auto;
}

.nb-product-cat {
    color: #94a3b8;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.nb-product-card--cover h2 {
    margin: 0 !important;
    font-size: 15px !important;
    font-weight: 800 !important;
    line-height: 1.35 !important;
}

.nb-product-card--cover h2 a {
    color: #0f172a;
    text-decoration: none;
}

.nb-product-card--cover h2 a:hover {
    color: #2563eb;
}

.nb-product-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.nb-chip {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    padding: 0 9px;
    border-radius: 999px;
    border: 1px solid #e2e8f0;
    background: #f8fafc;
    color: #64748b;
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
    white-space: nowrap;
}

.nb-chip--guest {
    color: #c2410c;
    border-color: #fed7aa;
    background: #fff7ed;
}

.nb-chip--member {
    color: #6d28d9;
    border-color: #ddd6fe;
    background: #f5f3ff;
}

.nb-buy-login-tip {
    margin: 0 0 12px;
    padding: 12px 14px;
    border: 1px solid #ddd6fe;
    border-radius: 12px;
    background: #f5f3ff;
    color: #5b21b6;
}

.nb-buy-login-tip strong {
    display: block;
    margin-bottom: 4px;
    font-size: 13px;
}

.nb-buy-login-tip p {
    margin: 0;
    font-size: 13px;
    line-height: 1.5;
}

.nb-buy-login-tip a {
    color: #6d28d9;
    font-weight: 700;
    text-decoration: underline;
}

.nb-self-select {
    margin: 0 0 22px;
    padding: 16px 16px 18px;
    border: 1px solid #e6edf5;
    border-radius: 16px;
    background: #f8fbff;
}
.nb-self-select-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 6px;
}
.nb-self-select-head h2 {
    margin: 0;
    font-size: 18px;
}
.nb-self-select-head span {
    color: #2f6feb;
    font-weight: 700;
    font-size: 13px;
}
.nb-self-select-hint {
    margin: 0 0 12px;
    color: #667085;
    font-size: 13px;
    line-height: 1.6;
}
.nb-self-select-search {
    width: 100%;
    margin: 0 0 12px;
    padding: 10px 12px;
    border: 1px solid #d7e0ea;
    border-radius: 10px;
    background: #fff;
}
.nb-self-select-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(132px, 1fr));
    gap: 8px;
}
.nb-self-select-item {
    padding: 10px 8px;
    border: 1px solid #d7e0ea;
    border-radius: 10px;
    background: #fff;
    color: #101828;
    font-weight: 600;
    cursor: pointer;
    word-break: break-all;
}
.nb-self-select-item:hover {
    border-color: #2f6feb;
    color: #2f6feb;
}
.nb-self-select-item.is-active {
    border-color: #2f6feb;
    background: #eef4ff;
    color: #1d4ed8;
    box-shadow: 0 0 0 1px #2f6feb inset;
}
.nb-self-select-item.is-incart,
.nb-self-select-item:disabled {
    opacity: .55;
    cursor: not-allowed;
    background: #f2f4f7;
}
.nb-self-select-empty {
    margin: 8px 0 0;
    color: #98a2b3;
    font-size: 13px;
}
.nb-self-select-summary {
    margin: 10px 0 0;
    color: #2f6feb;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.5;
}
.nb-chip.is-self,
.nb-product-tag.is-self {
    color: #b45309;
    border-color: #fde68a;
    background: #fffbeb;
}
.nb-cart-qty.is-locked,
.nb-co-quantity.is-locked {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 48px;
    padding: 6px 12px;
    border: 1px solid #e6edf5;
    border-radius: 10px;
    background: #f8fafc;
    font-weight: 700;
}
.nb-co-self-select {
    margin: 6px 0 0;
    color: #2f6feb;
    font-size: 13px;
}

.nb-btn-block {
    width: 100%;
    text-align: center;
}

.nb-chip.is-auto {
    color: #0369a1;
    border-color: #bae6fd;
    background: #f0f9ff;
}

.nb-chip.is-manual {
    color: #475569;
    border-color: #e2e8f0;
    background: #f8fafc;
}

.nb-chip.is-stock {
    color: #047857;
    border-color: #a7f3d0;
    background: #ecfdf5;
}

.nb-chip.is-pin {
    color: #b45309;
    background: #fff7ed;
    border-color: #fdba74;
}

.nb-chip.is-soldout {
    color: #b91c1c;
    border-color: #fecaca;
    background: #fef2f2;
}

.nb-product-desc {
    margin: 0;
    color: #64748b;
    font-size: 12.5px;
    line-height: 1.55;
    /* 固定两行高度，简介为空时卡片也对齐 */
    height: calc(1.55em * 2);
    min-height: calc(1.55em * 2);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.nb-product-desc.is-empty {
    visibility: hidden;
    user-select: none;
}

.nb-product-foot {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 12px;
    margin-top: auto;
    padding-top: 10px;
    border-top: 1px solid #f1f5f9;
}

.nb-product-card--cover .nb-product-price {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 4px 8px;
    margin: 0 !important;
}

.nb-product-card--cover .nb-product-price small {
    width: 100%;
    color: #94a3b8;
    font-size: 11px;
    font-weight: 600;
}

.nb-product-card--cover .nb-product-price strong {
    color: #0f172a;
    font-size: 18px;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.nb-product-card--cover .nb-product-price del {
    color: #94a3b8;
    font-size: 12px;
}

.nb-product-go {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    flex: 0 0 auto;
    border-radius: 50%;
    color: #64748b;
    background: #f1f5f9;
    transition: color .15s ease, background .15s ease, transform .15s ease;
}

.nb-product-go svg {
    width: 18px;
    height: 18px;
    display: block;
}

.nb-product-go:hover {
    color: #fff;
    background: #2563eb;
    transform: translateX(2px);
}

.nb-product-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.nb-product-tag.is-auto {
    background: #18a967;
}

.nb-product-tag.is-manual {
    background: #f59e0b;
}

.nb-product-tag.is-soldout {
    background: #7f8a99;
}

@media (max-width: 1100px) {
    .nb-product-grid--cover {
        grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    }
}

@media (max-width: 800px) {
    .nb-product-grid--cover {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }
}

@media (max-width: 480px) {
    .nb-product-grid--cover {
        grid-template-columns: 1fr !important;
        gap: 12px !important;
    }

    .nb-product-cover {
        aspect-ratio: 1 / 1;
    }
}

.nb-brand-logo.is-custom-logo {
    width: auto;
    max-width: 140px;
    height: 42px;
    object-fit: contain;
}

/* 手机底部导航 Telegram 客服入口 */
.nb-category-scroll {
    display: flex;
    align-items: center;
    flex: 1 1 auto;
    min-width: 0;
}

.nb-category-arrow {
    display: none;
}

.nb-mobile-back-top {
    display: none;
}

body.nb-dialog-open {
    overflow: hidden;
}

.nb-theme-alert {
    position: fixed;
    z-index: 200;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 20px;
    opacity: 0;
    transition: opacity .16s ease;
}

.nb-theme-alert[hidden] {
    display: none !important;
}

.nb-theme-alert.is-open {
    opacity: 1;
}

.nb-theme-alert__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, .52);
    backdrop-filter: blur(4px);
}

.nb-theme-alert__dialog {
    position: relative;
    width: min(390px, 100%);
    padding: 26px 24px 22px;
    overflow: hidden;
    color: #0f172a;
    border: 1px solid rgba(255, 255, 255, .85);
    border-radius: 22px;
    background: linear-gradient(180deg, #fff 0%, #f8fbff 100%);
    box-shadow: 0 24px 70px rgba(15, 23, 42, .28);
    transform: translateY(12px) scale(.97);
    transition: transform .18s ease;
}

.nb-theme-alert.is-open .nb-theme-alert__dialog {
    transform: translateY(0) scale(1);
}

.nb-theme-alert__dialog::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #2563eb, #38bdf8);
}

.nb-theme-alert__icon {
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    margin-bottom: 15px;
    color: #2563eb;
    border-radius: 15px;
    background: #eaf2ff;
}

.nb-theme-alert__icon svg {
    width: 26px;
    height: 26px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.nb-theme-alert__copy h2 {
    margin: 0 0 8px;
    font-size: 19px;
    line-height: 1.35;
}

.nb-theme-alert__copy p {
    margin: 0;
    color: #64748b;
    font-size: 14px;
    line-height: 1.7;
    white-space: pre-wrap;
}

.nb-theme-alert__actions {
    display: flex;
    gap: 10px;
    margin-top: 21px;
}

.nb-theme-alert__confirm,
.nb-theme-alert__recharge {
    flex: 1;
    height: 44px;
    color: #fff;
    border: 0;
    border-radius: 13px;
    background: linear-gradient(135deg, #3478ee, #2563db);
    box-shadow: 0 9px 20px rgba(37, 99, 235, .24);
    font-weight: 750;
    cursor: pointer;
}

.nb-theme-alert__recharge {
    display: grid;
    place-items: center;
    box-sizing: border-box;
    color: #dc2626;
    border: 1px solid #fecaca;
    background: #fff7f7;
    box-shadow: none;
    font-weight: 750;
    text-decoration: none;
}

.nb-theme-alert__recharge[hidden] {
    display: none;
}

.nb-theme-alert.is-danger .nb-theme-alert__dialog {
    border: 2px solid #ef4444;
    box-shadow: 0 24px 70px rgba(220, 38, 38, .25);
}

.nb-theme-alert.is-danger .nb-theme-alert__dialog::before {
    background: linear-gradient(90deg, #ef4444, #fb7185);
}

.nb-theme-alert.is-danger .nb-theme-alert__icon {
    color: #dc2626;
    background: #fff1f2;
}

.nb-theme-alert.is-danger .nb-theme-alert__copy h2 {
    color: #b91c1c;
}

.nb-theme-alert__confirm:focus-visible {
    outline: 3px solid rgba(37, 99, 235, .25);
    outline-offset: 3px;
}

@media (max-width: 640px) {
    .nb-theme-alert {
        padding: 16px;
        align-items: end;
        padding-bottom: calc(78px + env(safe-area-inset-bottom, 0px));
    }

    .nb-theme-alert__dialog {
        width: 100%;
        padding: 22px 20px 18px;
        border-radius: 20px;
        transform: translateY(24px) scale(.985);
    }

    .nb-theme-alert__icon {
        width: 44px;
        height: 44px;
        margin-bottom: 12px;
        border-radius: 14px;
    }

    .nb-category-scroll {
        width: 100%;
        gap: 4px;
    }

    .nb-category-list {
        scroll-snap-type: x proximity;
        scroll-padding-inline: 6px;
        overscroll-behavior-inline: contain;
        -webkit-overflow-scrolling: touch;
    }

    .nb-category-list a {
        scroll-snap-align: start;
    }

    .nb-category-arrow {
        display: grid;
        place-items: center;
        width: 30px;
        height: 36px;
        padding: 0;
        flex: 0 0 30px;
        color: #2563eb;
        border: 0;
        border-radius: 12px;
        background: #eff6ff;
        box-shadow: 0 3px 10px rgba(37, 99, 235, .12);
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
    }

    .nb-category-arrow[hidden] {
        display: none !important;
    }

    .nb-category-arrow:disabled {
        color: #a8b4c5;
        background: #f5f7fa;
        box-shadow: none;
        opacity: .6;
    }

    .nb-category-arrow svg {
        width: 17px;
        height: 17px;
        fill: none;
        stroke: currentColor;
        stroke-width: 2.2;
        stroke-linecap: round;
        stroke-linejoin: round;
    }

    .nb-mobile-tabs.has-support {
        grid-template-columns: repeat(5, 1fr);
    }

    .nb-mobile-tabs .nb-mobile-support-tab svg {
        width: 18px;
        height: 18px;
        color: #229ed9;
        flex: 0 0 auto;
    }

    .nb-mobile-back-top {
        position: fixed;
        right: 14px;
        bottom: calc(70px + env(safe-area-inset-bottom, 0px));
        z-index: 49;
        display: flex;
        width: 42px;
        height: 42px;
        padding: 4px 0 3px;
        align-items: center;
        justify-content: center;
        flex-direction: column;
        gap: 0;
        color: #fff;
        border: 1px solid rgba(255, 255, 255, .72);
        border-radius: 50%;
        background: rgba(37, 99, 235, .92);
        box-shadow: 0 8px 22px rgba(37, 99, 235, .3);
        backdrop-filter: blur(8px);
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
    }

    .nb-mobile-back-top[hidden] {
        display: none !important;
    }

    .nb-mobile-back-top svg {
        width: 17px;
        height: 15px;
        fill: none;
        stroke: currentColor;
        stroke-width: 2.2;
        stroke-linecap: round;
        stroke-linejoin: round;
    }

    .nb-mobile-back-top span {
        font-size: 8px;
        font-weight: 800;
        line-height: 1;
        letter-spacing: .25px;
    }

    .nb-mobile-back-top:active {
        transform: scale(.94);
    }
}

/* ========== 站点页脚（三栏 + 底栏，参考现代站布局） ========== */
.nb-site-footer {
    margin-top: 28px;
    border-top: 1px solid #e8eef5;
    background: #fff;
    color: #475569;
}

.nb-site-footer__inner {
    padding: 40px 0 0;
}

.nb-site-footer__main {
    display: grid;
    grid-template-columns: minmax(220px, 1.35fr) minmax(160px, .75fr) minmax(200px, .9fr);
    gap: 36px 48px;
    padding-bottom: 32px;
}

.nb-site-footer__logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    color: #0f172a;
    text-decoration: none;
}

.nb-site-footer__logo img {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    object-fit: cover;
    background: #eff6ff;
}

.nb-site-footer__logo img.is-custom {
    width: auto;
    max-width: 120px;
    height: 36px;
    border-radius: 8px;
    object-fit: contain;
}

.nb-site-footer__logo strong {
    font-size: 17px;
    font-weight: 800;
    letter-spacing: -.02em;
}

.nb-site-footer__brand p {
    margin: 0;
    max-width: 340px;
    color: #64748b;
    font-size: 13px;
    line-height: 1.7;
}

.nb-site-footer__col h3 {
    margin: 0 0 14px;
    color: #0f172a;
    font-size: 14px;
    font-weight: 800;
}

.nb-site-footer__col ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 10px;
}

.nb-site-footer__col a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #64748b;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    transition: color .15s;
}

.nb-site-footer__col a:hover {
    color: #2563eb;
}

.nb-site-footer__ico {
    width: 18px;
    color: #94a3b8;
    font-size: 12px;
    text-align: center;
}

.nb-site-footer__contact {
    display: grid;
    gap: 10px;
    justify-items: start;
}

.nb-site-footer__contact-btn {
    display: inline-flex !important;
    align-items: center;
    gap: 8px;
    min-height: 40px;
    padding: 0 14px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 12px !important;
    background: #f8fafc !important;
    color: #334155 !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    text-decoration: none !important;
    transition: border-color .15s, background .15s, color .15s;
}

.nb-site-footer__contact-btn:hover {
    border-color: #93c5fd !important;
    background: #eff6ff !important;
    color: #1d4ed8 !important;
}

.nb-site-footer__contact-btn svg {
    width: 16px;
    height: 16px;
    flex: 0 0 auto;
}

.nb-site-footer__extra {
    color: #64748b;
    font-size: 13px;
    line-height: 1.65;
}

.nb-site-footer__extra img {
    max-width: 140px;
    max-height: 140px;
    object-fit: contain;
}

.nb-site-footer__muted {
    margin: 0;
    color: #94a3b8;
    font-size: 13px;
    line-height: 1.6;
}

.nb-site-footer__bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px 20px;
    padding: 16px 0 22px;
    border-top: 1px solid #eef2f7;
}

.nb-site-footer__copy {
    color: #94a3b8;
    font-size: 12px;
    line-height: 1.5;
}

.nb-site-footer__legal {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 16px;
}

.nb-site-footer__legal a {
    color: #64748b;
    font-size: 12px;
    font-weight: 600;
    text-decoration: none;
}

.nb-site-footer__legal a:hover {
    color: #2563eb;
}

/* 兼容旧类名（避免残留样式干扰） */
.nb-footer-grid,
.nb-footer-points,
.nb-footer-html,
.nb-footer-bottom {
    /* no-op kept for cache safety */
}

@media (max-width: 900px) {
    .nb-site-footer__main {
        grid-template-columns: 1fr 1fr;
        gap: 28px 24px;
    }

    .nb-site-footer__brand {
        grid-column: 1 / -1;
    }
}

@media (max-width: 640px) {
    .nb-site-footer__inner {
        padding-top: 28px;
    }

    .nb-site-footer__main {
        grid-template-columns: 1fr;
        gap: 24px;
        padding-bottom: 24px;
    }

    .nb-site-footer__bar {
        flex-direction: column;
        align-items: flex-start;
        padding-bottom: 28px;
    }
}

/* 登录注册页隐藏页脚 */
.nb-auth-body .nb-site-footer {
    display: none !important;
}

/* 手机端隐藏页脚（已有底部 Tab，避免重复占屏） */
@media (max-width: 900px) {
    .nb-site-footer {
        display: none !important;
    }
}

/* ========== 政策页 / Open API 文档卡片 ========== */
.nb-legal {
    padding: 28px 0 56px;
    max-width: 920px;
}
.nb-legal-crumb {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
    color: #8b96a7;
    font-size: 13px;
}
.nb-legal-crumb a { color: #2f6feb; text-decoration: none; }
.nb-legal-crumb em { color: #334155; font-style: normal; }
.nb-legal-card {
    border: 1px solid #e5ebf3;
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 12px 36px rgba(25, 50, 86, .05);
    overflow: hidden;
}
.nb-legal-head {
    padding: 28px 28px 18px;
    border-bottom: 1px solid #eef2f7;
    background: linear-gradient(180deg, #f8fbff, #fff);
}
.nb-legal-label {
    display: inline-block;
    margin-bottom: 10px;
    color: #2f6feb;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .14em;
}
.nb-legal-head h1 {
    margin: 0 0 8px;
    color: #0f172a;
    font-size: 28px;
    font-weight: 800;
    line-height: 1.25;
}
.nb-legal-head > p {
    margin: 0 0 4px;
    color: #64748b;
    font-size: 14px;
    line-height: 1.6;
}
.nb-legal-body {
    padding: 8px 28px 8px;
    color: #1e293b;
    font-size: 15px;
    line-height: 1.75;
}
.nb-legal-foot {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 28px 22px;
    border-top: 1px solid #eef2f7;
    background: #fafbfc;
}
.nb-legal-foot a {
    color: #2f6feb;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
}
.nb-legal-foot a.is-primary {
    display: inline-flex;
    align-items: center;
    min-height: 38px;
    padding: 0 16px;
    border-radius: 999px;
    color: #fff;
    background: #2f6feb;
}

.dj-api-spec {
    padding: 12px 0 20px;
    color: #1e293b;
    font-size: 14px;
    line-height: 1.7;
}
.dj-api-lead {
    margin: 0 0 18px;
    color: #475569;
}
.dj-api-block {
    margin: 0 0 18px;
    padding: 18px 18px 8px;
    border: 1px solid #eef2f7;
    border-radius: 14px;
    background: #fbfcfe;
}
.dj-api-spec h3 {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 12px;
    color: #0f172a;
    font-size: 16px;
    font-weight: 800;
}
.dj-api-spec h3 span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 999px;
    background: #2f6feb;
    color: #fff;
    font-size: 12px;
    font-weight: 800;
    flex: 0 0 22px;
}
.dj-api-spec h4 {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 16px 0 8px;
    color: #0f172a;
    font-size: 14px;
    font-weight: 800;
}
.dj-api-spec p,
.dj-api-spec ul,
.dj-api-spec ol { margin: 0 0 .75em; }
.dj-api-spec ul,
.dj-api-spec ol { padding-left: 1.25em; }
.dj-api-spec code {
    padding: 1px 6px;
    border-radius: 5px;
    background: #eef2ff;
    color: #3730a3;
    font-size: 12px;
}
.dj-api-spec pre {
    overflow: auto;
    margin: 0 0 1em;
    padding: 12px 14px;
    border: 1px solid #1e293b;
    border-radius: 10px;
    background: #0f172a;
    color: #e2e8f0;
    font-size: 12px;
    line-height: 1.55;
    white-space: pre-wrap;
    word-break: break-word;
}
.dj-api-kvs {
    display: grid;
    gap: 8px;
    margin: 0 0 12px;
}
.dj-api-kv {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 10px 12px;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    background: #fff;
}
.dj-api-kv span {
    color: #64748b;
    font-size: 12px;
    font-weight: 700;
}
.dj-api-kv code {
    background: transparent;
    color: #0f172a;
    font-size: 13px;
    padding: 0;
    word-break: break-all;
}
.dj-api-table {
    overflow-x: auto;
    margin: 0 0 1em;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    background: #fff;
}
.dj-api-spec table {
    width: 100%;
    margin: 0;
    border-collapse: collapse;
    font-size: 13px;
}
.dj-api-spec th,
.dj-api-spec td {
    border-bottom: 1px solid #eef2f7;
    padding: 10px 12px;
    text-align: left;
    vertical-align: top;
}
.dj-api-spec tr:last-child td { border-bottom: 0; }
.dj-api-spec th {
    background: #f8fafc;
    color: #334155;
    font-weight: 700;
}
.dj-api-method {
    display: inline-flex;
    align-items: center;
    min-width: 46px;
    justify-content: center;
    padding: 2px 8px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .02em;
}
.dj-api-method.is-get { color: #166534; background: #dcfce7; }
.dj-api-method.is-post { color: #1e40af; background: #dbeafe; }

.uc-card .dj-api-spec { margin-top: 8px; }
.uc-card .dj-api-block { background: #fff; }

@media (max-width: 720px) {
    .nb-legal { padding: 18px 0 40px; }
    .nb-legal-head,
    .nb-legal-body,
    .nb-legal-foot { padding-left: 16px; padding-right: 16px; }
    .nb-legal-head h1 { font-size: 22px; }
    .dj-api-block { padding: 14px 12px 6px; }
}
