.bundle-customization-pagination {
    text-align: center;
    margin-top: 15px;
}

.bundle-customization-pagination-page {
    display: inline-block;
    padding: 4px 8px;
    cursor: pointer;
    line-height: 1;
}

.bundle-customization-pagination-page.customization-active {
    font-weight: 700;
    border: 2px solid;
    border-radius: 3px;
}

.bundle-customization-pagination-ellipsis {
    display: inline-block;
    padding: 4px 8px;
    line-height: 1;
    color: inherit;
    cursor: default;
    user-select: none;
}

.bundle-customization-items-count {
    padding: 5px 0;
    text-align: right;
}

.tomich-in-bundle {
    margin: 30px 0;
    padding: 25px;
    background: #ffffff;
    box-shadow: 0 0 10px 5px rgba(0, 0, 0, 0.08);
    border-radius: 4px;
    width: 100%;
    flex-basis: 100%;
    grid-column: 1 / -1;
    clear: both;
    box-sizing: border-box;
}

.tomich-in-bundle-text {
    margin-bottom: 25px;
    padding: 10px;
    background: #333333;
    color: #ffffff;
    text-align: center;
    text-transform: uppercase;
    font-size: 2em;
    font-weight: 700;
    line-height: 1.3;
}

.tomich-in-bundle-text br {
    display: none;
}

.tomich-in-bundle .woocommerce ul.products,
.tomich-in-bundle ul.products {
    display: block;
}

.tomich-in-bundle ul.products li.product {
    width: 100%;
    float: none;
    clear: both;
}

.tomich-in-bundle ul.products li.product::after {
    content: "";
    display: block;
    clear: both;
}

.tomich-in-bundle ul.products li.product .product-action-wrap {
    display: inline-block;
    width: auto;
}

.tomich-in-bundle ul.products li.product .product-action-wrap .button,
.tomich-in-bundle ul.products li.product .button {
    width: auto !important;
    display: inline-block !important;
}

.tomich-in-bundle .price {
    color: #000000;
}

.tomich-in-bundle h2.woocommerce-loop-product__title {
    font-size: 1.1em;
    line-height: 1.3;
    margin-bottom: 8px;
}

.tomich-in-bundle span.onsale,
.tomich-in-bundle .onsale {
    display: none;
}

.tomich-in-bundle .yith-add-to-wishlist-button-block,
.tomich-in-bundle .yith-add-to-wishlist-button-block--initialized,
.tomich-in-bundle .yith-wcwl-add-to-wishlist-button,
.tomich-in-bundle span.yith-wcwl-add-to-wishlist-button__label,
.tomich-in-bundle #yith-wcwl-icon-heart-outline,
.tomich-in-bundle svg.yith-wcwl-icon {
    display: none !important;
}

th.bundled_item_col.bundled_item_details_head,
th.bundled_item_col.bundled_item_qty_head,
td.bundled_item_col.bundled_item_qty_col {
    display: none;
}

.swbt-hide-bundle-ui .bundled_product_summary,
.swbt-hide-bundle-ui .bundle-customization-items-count,
.swbt-hide-bundle-ui .bundle-customization-pagination,
.swbt-hide-bundle-ui .swbt-bundle-items-heading {
    display: none !important;
}

.sw-show-on-bundles {
    display: none;
}

.woocommerce-product-type-bundle .sw-show-on-bundles {
    display: block;
}

.woocommerce-product-type-bundle .sw-hide-on-bundles {
    display: none !important;
}

@media only screen and (max-width: 799px) {
    .tomich-in-bundle {
        margin-left: 15px;
        margin-right: 15px;
    }
    .tomich-in-bundle-text {
        font-size: 1.5em;
        padding: 8px;
    }
    .tomich-in-bundle .woocommerce ul.products,
    .tomich-in-bundle ul.products {
        display: flex;
        flex-wrap: wrap;
        gap: 15px;
    }
    .tomich-in-bundle .tomich-in-bundle-products ul.products li.product,
    .tomich-in-bundle ul.products li.product,
    body .tomich-in-bundle.tomich-in-bundle .tomich-in-bundle-products ul.products li.product,
    body .tomich-in-bundle.tomich-in-bundle ul.products li.product {
        width: calc(50% - 22px) !important;
        float: none !important;
        clear: none !important;
        text-align: center;
    }
    .tomich-in-bundle .tomich-in-bundle-products ul.products li.product:only-child,
    .tomich-in-bundle ul.products li.product:only-child,
    body .tomich-in-bundle.tomich-in-bundle .tomich-in-bundle-products ul.products li.product:only-child,
    body .tomich-in-bundle.tomich-in-bundle ul.products li.product:only-child {
        width: 100% !important;
    }
    .tomich-in-bundle ul.products li.product a img {
        margin-left: auto;
        margin-right: auto;
    }
    .tomich-in-bundle ul.products li.product .star-rating {
        margin: 6px auto;
        display: block;
        font-size: 0.85em;
    }
}

@media only screen and (min-width: 800px) {
    .tomich-in-bundle ul.products li.product a img {
        width: 20%;
        float: left;
    }
    .tomich-in-bundle ul.products li.product .woocommerce-loop-product__title,
    .tomich-in-bundle ul.products li.product .price {
        float: right;
        clear: right;
        width: 75%;
        text-align: right;
        margin-bottom: 8px;
    }
    .tomich-in-bundle ul.products li.product .star-rating {
        float: right;
        clear: right;
        margin: 0 0 8px;
        font-size: 0.9em;
    }
    .tomich-in-bundle ul.products li.product .product-action-wrap,
    .tomich-in-bundle ul.products li.product .button {
        float: right;
        clear: right;
    }
    .tomich-in-bundle h2.woocommerce-loop-product__title {
        margin-bottom: 0;
        padding: 0;
        font-weight: 600;
        font-size: 1.5em;
    }
    .tomich-in-bundle ul.products li.product:only-child {
        width: 100% !important;
        max-width: 100% !important;
        float: none !important;
        clear: none !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
}

/* === TABULAR LAYOUT MOBILE GRID === */
/* Bundle products in tabular layout get a card-based grid layout on mobile */

@media only screen and (max-width: 799px) {
    .bundle_form.layout_tabular table.bundled_products,
    .bundle_form.layout_tabular table.bundled_products tbody {
        display: block;
        width: 100%;
    }

    .bundle_form.layout_tabular table.bundled_products thead {
        display: none;
    }

    .bundle_form.layout_tabular table.bundled_products tbody {
        display: flex;
        flex-wrap: wrap;
        gap: 15px;
    }

    .bundle_form.layout_tabular table.bundled_products tr.bundled_product {
        display: block;
        width: 100%;
        box-sizing: border-box;
    }

    .bundle_form.layout_tabular table.bundled_products td.bundled_item_col {
        display: block;
        width: 100%;
        padding: 8px 0;
    }

    .bundle_form.layout_tabular .bundled_product_image,
    .bundle_form.layout_tabular .bundled_product_image img {
        max-width: 100%;
        height: auto;
        margin: 0 auto;
    }
}

@media only screen and (min-width: 500px) and (max-width: 799px) {
    .bundle_form.layout_tabular table.bundled_products tr.bundled_product {
        width: calc(50% - 22px);
    }
}

@media only screen and (max-width: 499px) {
    .bundle_form.layout_tabular table.bundled_products tr.bundled_product {
        width: 100%;
    }
}
