html.buy-modern {
    --modern-bg: #f6f8fb;
    --modern-text: #182230;
    --modern-muted: #65758b;
    --modern-line: rgba(15, 23, 42, .08);
    --modern-card: rgba(255, 255, 255, .92);
    --modern-brand: #2563eb;
    --modern-brand-2: #10b981;
    --modern-warning: #f97316;
    --modern-shadow: 0 18px 45px rgba(15, 23, 42, .10);
}

html.buy-modern body {
    color: var(--modern-text);
    background-color: var(--modern-bg) !important;
    background-attachment: fixed !important;
}

html.buy-modern body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    background:
        linear-gradient(135deg, rgba(246, 248, 251, .96), rgba(239, 246, 255, .90)),
        radial-gradient(circle at 15% 10%, rgba(37, 99, 235, .14), transparent 28%),
        radial-gradient(circle at 85% 0%, rgba(16, 185, 129, .13), transparent 28%);
    pointer-events: none;
}

html.buy-modern .navbar {
    padding: 14px 0;
    background: rgba(255, 255, 255, .82) !important;
    border-bottom: 1px solid rgba(255, 255, 255, .65);
    box-shadow: 0 12px 30px rgba(15, 23, 42, .08);
    backdrop-filter: blur(18px);
}

html.buy-modern .navbar .container {
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

html.buy-modern .navbar-brand a,
html.buy-modern .navbar .nav-link {
    color: var(--modern-text) !important;
}

html.buy-modern .navbar-brand img {
    width: 38px;
    height: 38px !important;
    object-fit: cover;
    box-shadow: 0 8px 22px rgba(37, 99, 235, .18) !important;
}

html.buy-modern .navbar-brand span {
    top: 1px !important;
    color: var(--modern-text) !important;
    font-size: 16px !important;
}

html.buy-modern .navbar .row {
    align-items: center;
    gap: 8px;
    margin: 0;
}

html.buy-modern .navbar .nav-link {
    padding: 9px 13px;
    border-radius: 999px;
    color: var(--modern-muted) !important;
    transition: color .22s ease, background .22s ease, transform .22s ease;
}

html.buy-modern .navbar .nav-link:hover {
    color: var(--modern-brand) !important;
    background: rgba(37, 99, 235, .09);
    transform: translateY(-1px);
}

html.buy-modern .content-wrapper {
    padding: 26px 0 48px;
}

html.buy-modern .container {
    max-width: 1280px;
}

html.buy-modern .card {
    margin: 18px 0;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, .78);
    border-radius: 18px;
    background: var(--modern-card);
    box-shadow: var(--modern-shadow);
    backdrop-filter: blur(16px);
    transition: transform .24s ease, box-shadow .24s ease, border-color .24s ease;
}

html.buy-modern .card:hover {
    border-color: rgba(37, 99, 235, .16);
    box-shadow: 0 22px 54px rgba(15, 23, 42, .13);
}

html.buy-modern .card .card-header {
    padding: 17px 22px !important;
    border-bottom: 1px solid var(--modern-line) !important;
    background: linear-gradient(90deg, rgba(37, 99, 235, .08), rgba(16, 185, 129, .06));
}

html.buy-modern .card-title {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--modern-text);
    font-size: 16px;
    font-weight: 800;
}

html.buy-modern .card-title i {
    color: var(--modern-brand);
}

html.buy-modern .card .card-block {
    padding: 20px 22px !important;
}

html.buy-modern .card-block p,
html.buy-modern .card-block font,
html.buy-modern .card-block span {
    line-height: 1.8;
}

html.buy-modern label {
    color: var(--modern-muted);
    font-weight: 700;
}

html.buy-modern .category,
html.buy-modern #product {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 14px;
}

html.buy-modern .button-click {
    min-height: 62px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    padding: 13px 15px;
    border: 1px solid rgba(15, 23, 42, .08);
    border-radius: 14px;
    color: var(--modern-text);
    background: rgba(255, 255, 255, .9);
    box-shadow: 0 10px 24px rgba(15, 23, 42, .07);
    transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease, background .22s ease;
}

html.buy-modern .button-click:hover {
    border-color: rgba(37, 99, 235, .30);
    background: #fff;
    box-shadow: 0 16px 34px rgba(15, 23, 42, .11);
    transform: translateY(-2px);
}

html.buy-modern .button-click.checked {
    color: #fff;
    border-color: transparent;
    background: linear-gradient(135deg, var(--modern-brand), var(--modern-brand-2));
    box-shadow: 0 16px 34px rgba(37, 99, 235, .22);
}

html.buy-modern .commodity-icon {
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    margin: 0;
    object-fit: cover;
    border-radius: 11px;
}

html.buy-modern #product .button-click {
    min-height: 82px;
    font-size: 15px;
    font-weight: 800;
}

html.buy-modern #product .commodity-icon {
    width: 58px;
    height: 58px;
    flex-basis: 58px;
}

html.buy-modern .empty-commodity {
    opacity: .52;
    filter: grayscale(.25);
}

html.buy-modern .shopInfoHtml .row {
    row-gap: 18px;
}

html.buy-modern .description {
    color: #334155;
    border-radius: 14px;
    background: rgba(248, 250, 252, .84);
}

html.buy-modern .productName {
    color: var(--modern-text);
    font-weight: 900;
}

html.buy-modern .round,
html.buy-modern .form-control {
    min-height: 42px;
    border: 1px solid rgba(15, 23, 42, .12);
    border-radius: 12px;
    background: rgba(255, 255, 255, .92);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .75);
}

html.buy-modern .round:focus,
html.buy-modern .form-control:focus {
    border-color: rgba(37, 99, 235, .48) !important;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, .12);
}

html.buy-modern .pay_type {
    gap: 12px;
}

html.buy-modern .pay_type .button-click,
html.buy-modern .pay-button {
    color: #fff;
    border: 0;
    background: linear-gradient(135deg, var(--modern-brand), #1d4ed8);
    box-shadow: 0 14px 28px rgba(37, 99, 235, .22);
}

html.buy-modern .sliderbar-container {
    border-radius: 16px;
    background: rgba(248, 250, 252, .92);
    box-shadow: inset 0 0 0 1px rgba(15, 23, 42, .06);
}

html.buy-modern .content-icp {
    color: var(--modern-muted);
    border-radius: 16px;
    background: rgba(255, 255, 255, .74);
    box-shadow: 0 12px 28px rgba(15, 23, 42, .08);
}

@media (max-width: 768px) {
    html.buy-modern .navbar {
        padding: 10px 0;
    }

    html.buy-modern .navbar .container {
        display: block;
    }

    html.buy-modern .navbar .row {
        margin-top: 12px;
        gap: 6px;
    }

    html.buy-modern .navbar .nav-link {
        padding: 8px 10px;
        font-size: 13px;
    }

    html.buy-modern .content-wrapper {
        padding-top: 12px;
    }

    html.buy-modern .card {
        margin: 14px 0;
        border-radius: 15px;
    }

    html.buy-modern .card .card-header,
    html.buy-modern .card .card-block {
        padding-left: 16px !important;
        padding-right: 16px !important;
    }

    html.buy-modern .category,
    html.buy-modern #product {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    html.buy-modern #product .button-click {
        min-height: 74px;
    }

    html.buy-modern .round,
    html.buy-modern .form-control {
        width: 100% !important;
    }
}

@media (prefers-reduced-motion: reduce) {
    html.buy-modern *,
    html.buy-modern *::before,
    html.buy-modern *::after {
        transition: none !important;
        animation: none !important;
    }
}

html.buy-modern .buy-catalog-layout {
    display: grid;
    grid-template-columns: minmax(280px, 360px) minmax(0, 1fr);
    gap: 24px;
    align-items: start;
}

html.buy-modern .buy-panel {
    margin-top: 18px;
}

html.buy-modern .buy-category-panel {
    position: sticky;
    top: 18px;
}

html.buy-modern .buy-panel-kicker {
    display: block;
    margin-bottom: 10px;
    color: var(--modern-muted);
    font-size: 11px;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
}

html.buy-modern .buy-product-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

html.buy-modern .buy-mobile-filter-btn,
html.buy-modern .buy-filter-close,
html.buy-modern .buy-mobile-filter-mask,
html.buy-modern .buy-return-list {
    display: none;
}

html.buy-modern .buy-product-search {
    width: min(360px, 100%);
    min-height: 48px;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 5px 6px 5px 15px;
    border: 1px solid rgba(15, 23, 42, .12);
    border-radius: 999px;
    background: rgba(255, 255, 255, .86);
}

html.buy-modern .buy-product-search i {
    color: var(--modern-muted);
}

html.buy-modern .buy-product-search .form-control {
    min-height: 34px;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

html.buy-modern .product-search-btn {
    min-width: 74px;
    height: 38px;
    border: 0;
    border-radius: 999px;
    color: #fff;
    background: #050505;
    font-weight: 800;
    transition: transform .2s ease, background .2s ease;
}

html.buy-modern .product-search-btn:hover {
    background: var(--modern-brand);
    transform: translateY(-1px);
}

html.buy-modern .buy-category-panel .category {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

html.buy-modern .buy-category-panel .category-button {
    width: 100%;
    min-height: 46px;
    justify-content: flex-start;
    border-radius: 999px;
    box-shadow: none;
    font-size: 14px;
}

html.buy-modern .category-name {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

html.buy-modern .category-count {
    min-width: 30px;
    margin-left: auto;
    padding: 3px 9px;
    border-radius: 999px;
    color: var(--modern-muted);
    background: rgba(15, 23, 42, .06);
    font-size: 12px;
    text-align: center;
}

html.buy-modern .category-button.checked .category-count {
    color: var(--modern-text);
    background: rgba(255, 255, 255, .82);
}

html.buy-modern .buy-product-table-head,
html.buy-modern #product .buy-product-row {
    display: grid;
    grid-template-columns: minmax(280px, 1fr) 96px 86px 96px;
    align-items: center;
    gap: 16px;
}

html.buy-modern .buy-product-table-head {
    padding: 13px 16px;
    border: 1px solid var(--modern-line);
    border-bottom: 0;
    border-radius: 16px 16px 0 0;
    color: var(--modern-muted);
    background: rgba(248, 250, 252, .92);
    font-size: 13px;
    font-weight: 800;
}

html.buy-modern #product {
    display: block;
    border: 1px solid var(--modern-line);
    border-radius: 0 0 16px 16px;
    overflow: hidden;
    background: rgba(255, 255, 255, .72);
}

html.buy-modern #product .buy-product-row {
    width: 100%;
    min-height: 78px;
    margin: 0;
    padding: 14px 16px;
    border: 0;
    border-bottom: 1px solid var(--modern-line);
    border-radius: 0;
    background: rgba(255, 255, 255, .72);
    box-shadow: none;
}

html.buy-modern #product .buy-product-row:last-child {
    border-bottom: 0;
}

html.buy-modern #product .buy-product-row:hover {
    background: #fff;
    transform: none;
}

html.buy-modern .buy-product-main {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 14px;
}

html.buy-modern .buy-product-copy {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 7px;
}

html.buy-modern .buy-product-name {
    overflow: hidden;
    color: var(--modern-text);
    font-size: 14px;
    font-weight: 900;
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
}

html.buy-modern .buy-product-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

html.buy-modern .buy-delivery {
    display: inline-flex;
    align-items: center;
    min-height: 22px;
    padding: 2px 9px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 800;
}

html.buy-modern .buy-delivery.auto {
    color: #047857;
    background: rgba(16, 185, 129, .14);
}

html.buy-modern .buy-delivery.manual {
    color: #b45309;
    background: rgba(245, 158, 11, .17);
}

html.buy-modern .buy-product-price {
    color: #050505;
    font-size: 15px;
    font-weight: 900;
}

html.buy-modern .buy-product-stock {
    color: var(--modern-muted);
    font-size: 13px;
    font-weight: 700;
}

html.buy-modern .buy-product-action {
    justify-self: end;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-width: 76px;
    min-height: 36px;
    padding: 7px 12px;
    border-radius: 999px;
    color: #fff;
    background: #050505;
    font-size: 13px;
    font-weight: 900;
}

@media (min-width: 1320px) {
    html.buy-modern .container {
        max-width: 1360px;
    }

    html.buy-modern .buy-catalog-layout {
        grid-template-columns: minmax(300px, 390px) minmax(0, 1fr);
    }
}

html.buy-modern .buy-empty-product {
    padding: 28px;
    color: var(--modern-muted);
    text-align: center;
}

html.buy-modern .buy-detail-layout {
    align-items: flex-start;
}

html.buy-modern .buy-order-pane {
    order: 1;
}

html.buy-modern .buy-description-pane {
    order: 2;
    padding: 18px;
}

html.buy-modern .buy-detached-description {
    display: block;
    margin: 14px 0 0;
    padding: 18px 20px;
}

html.buy-modern .buy-detached-description::before {
    content: "宝贝详情";
    display: block;
    margin: 0 -20px 16px;
    padding: 0 20px 14px;
    border-bottom: 1px solid var(--modern-line);
    color: var(--modern-text);
    font-size: 16px;
    font-weight: 900;
}

@media (max-width: 768px) {
    html.buy-modern .buy-catalog-layout {
        display: block;
    }

    html.buy-modern .buy-category-panel {
        position: fixed;
        top: 28px;
        bottom: 28px;
        left: 16px;
        z-index: 42;
        width: min(78vw, 330px);
        margin: 0;
        overflow: auto;
        transform: translateX(calc(-100% - 28px));
        transition: transform .24s ease;
        box-shadow: 0 24px 60px rgba(15, 23, 42, .25);
    }

    html.buy-modern .buy-catalog-layout.filter-open .buy-category-panel {
        transform: translateX(0);
    }

    html.buy-modern .buy-mobile-filter-mask {
        position: fixed;
        inset: 0;
        z-index: 41;
        background: rgba(15, 23, 42, .36);
        backdrop-filter: blur(2px);
    }

    html.buy-modern .buy-catalog-layout.filter-open .buy-mobile-filter-mask {
        display: block;
    }

    html.buy-modern .buy-category-panel .card-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
    }

    html.buy-modern .buy-filter-close {
        width: 34px;
        height: 34px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border: 1px solid var(--modern-line);
        border-radius: 50%;
        color: var(--modern-text);
        background: rgba(248, 250, 252, .95);
        font-size: 22px;
        line-height: 1;
    }

    html.buy-modern .buy-product-header {
        display: block;
    }

    html.buy-modern .buy-mobile-filter-btn {
        width: 100%;
        min-height: 38px;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        margin-top: 14px;
        border: 1px solid rgba(15, 23, 42, .12);
        border-radius: 999px;
        color: var(--modern-text);
        background: #fff;
        box-shadow: 0 8px 20px rgba(15, 23, 42, .08);
        font-size: 14px;
        font-weight: 900;
    }

    html.buy-modern .buy-product-search {
        width: 100%;
        margin-top: 10px;
        border-radius: 18px;
        flex-wrap: wrap;
        padding: 9px 10px 10px 14px;
    }

    html.buy-modern .buy-product-search .product-search-btn {
        width: 100%;
        margin-top: 10px;
    }

    html.buy-modern .buy-product-table-head {
        display: none;
    }

    html.buy-modern #product {
        display: grid;
        grid-template-columns: 1fr;
        gap: 10px;
        border: 0;
        border-radius: 0;
        background: transparent;
    }

    html.buy-modern #product .buy-product-row {
        display: grid;
        grid-template-columns: 1fr auto;
        gap: 10px 12px;
        min-height: 92px;
        border: 1px solid var(--modern-line);
        border-radius: 16px;
        background: rgba(255, 255, 255, .92);
    }

    html.buy-modern .buy-product-main {
        grid-column: 1 / -1;
    }

    html.buy-modern .buy-product-action {
        grid-column: 2;
        grid-row: 2 / span 2;
        align-self: center;
    }

    html.buy-modern .buy-product-stock {
        grid-column: 1;
    }

    html.buy-modern .buy-product-name {
        white-space: normal;
        font-size: 14px;
    }

    html.buy-modern .buy-description-pane {
        width: auto;
    }

    html.buy-modern .buy-catalog-layout.catalog-collapsed .buy-product-panel {
        display: none;
    }

    html.buy-modern .buy-return-list {
        width: calc(100% - 30px);
        min-height: 40px;
        display: none;
        align-items: center;
        justify-content: center;
        gap: 8px;
        margin: 6px auto 12px;
        border: 1px solid rgba(15, 23, 42, .12);
        border-radius: 999px;
        color: var(--modern-text);
        background: rgba(255, 255, 255, .92);
        box-shadow: 0 8px 20px rgba(15, 23, 42, .08);
        font-size: 14px;
        font-weight: 900;
    }

    html.buy-modern .shopInfoHtml .card-header {
        display: none;
    }

    html.buy-modern .shopInfoHtml {
        margin-top: 10px;
    }
}
