body.tax-product_cat {
    outline: 10px solid red !important;
}

/* ============================================================
   SLV WooCommerce Layout (Optimized + Cleaned)
=========================================================== */

/* ===========================
   WRAPPER
=========================== */
.lsm-woo-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1.5rem 16px 2rem;
    box-sizing: border-box;
}

/* ===========================
   PRODUCT GRID
=========================== */
ul.products {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    column-gap: 1.75rem;
    row-gap: 3rem;
    margin: 0;
    padding: 0;
}

/* PRODUCT CARD */
ul.products li.lsm-product-card {
    background: var(--slv-phone-bg);
    border: 1px solid rgba(0,0,0,0.28);
    border-radius: 6px;
    padding: 0.75rem;
    display: flex;
    flex-direction: column;
    height: 100%;
    transition: all 0.25s ease;
}

ul.products li.lsm-product-card:hover {
    border-color: var(--slv-button-grad-end);
    box-shadow: 0 10px 25px rgba(15,23,42,0.12);
    transform: translateY(-2px);
}

/* TITLE */
ul.products li.lsm-product-card h2 {
    margin: 0.55rem 0 0.35rem;
    font-size: 1rem;
    font-weight: 700;
    color: var(--slv-primary);
    text-align: center;
    line-height: 1.25;
}

/* PRICE + STOCK */
ul.products li.lsm-product-card .price {
    display: block;
    text-align: center;
    font-size: 1rem;
    font-weight: 700;
    color: var(--slv-primary);
    margin: 0.25rem 0 0.15rem;
}

ul.products li.lsm-product-card .lsm-stock {
    display: inline-block;
    text-align: center;
    font-size: 0.78rem;
    font-weight: 600;
    color: #2e7d32;
    background: rgba(46, 125, 50, 0.12);
    padding: 2px 8px;
    border-radius: 12px;
    margin-bottom: 0.25rem;
}

.lsm-price-stock {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    margin-bottom: 0.35rem;
}

/* ACTIONS */
ul.products li.lsm-product-card .lsm-actions-flex {
    display: flex;
    align-items: center;
    gap: 6px;
    height: 28px;
    margin-top: auto;
}

ul.products li.lsm-product-card .quantity input.qty {
    width: 32px !important;
    height: 28px !important;
    padding: 0 !important;
    font-size: 0.72rem !important;
    text-align: center;
    border-radius: 4px;
    border: 1px solid rgba(0,0,0,0.25);
}

ul.products li.lsm-product-card .button {
    flex: 1;
    height: 28px !important;
    font-size: 0.72rem !important;
    padding: 0 6px !important;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    white-space: nowrap !important;
    border-radius: 4px !important;
    background: linear-gradient(
        to bottom,
        var(--slv-button-grad-start),
        var(--slv-button-grad-end)
    );
    color: var(--slv-primary);
}

/* ===========================
   PAGINATION
=========================== */
.woocommerce-pagination {
    margin-top: 3rem;
    text-align: center;
    width: 100%;
    display: block;
}

.woocommerce-pagination ul.page-numbers {
    display: inline-flex;
    gap: 6px;
    padding: 4px 8px;
    margin: 0;
    font-size: 0.75rem;
    list-style: none;
}

.woocommerce-pagination a,
.woocommerce-pagination span {
    padding: 6px 10px;
    border: 1px solid rgba(0,0,0,0.25);
    border-radius: 4px;
    font-size: 0.85rem;
    color: var(--slv-primary);
    background: var(--slv-phone-bg);
}

.woocommerce-pagination .current {
    background: var(--slv-primary);
    color: #fff;
    border-color: var(--slv-primary);
}

/* ============================================================
   SINGLE PRODUCT PAGE
=========================================================== */
.single-product .woocommerce-tabs {
    clear: both;
    margin-top: 3rem;
    display: block;
    border-top: 1px solid rgba(0,0,0,0.12);
    padding-top: 1.5rem;
}

.single-product .woocommerce-tabs ul.tabs {
    display: flex;
    gap: 1rem;
    list-style: none;
    padding: 0;
    margin: 0 0 1rem;
    border-bottom: 1px solid rgba(0,0,0,0.15);
}

.single-product .woocommerce-tabs ul.tabs li a {
    padding: 0.5rem 1rem;
    display: inline-block;
    font-weight: 600;
    color: var(--slv-primary);
    border-radius: 4px 4px 0 0;
}

.single-product .woocommerce-tabs ul.tabs li.active a {
    background: var(--slv-phone-bg);
    border-bottom: 2px solid var(--slv-primary);
}

.single-product .woocommerce-Tabs-panel {
    padding: 1rem 0;
    line-height: 1.6;
}

/* ADD TO CART ROW */
.single-product form.cart {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 1.25rem 0;
}

.single-product form.cart .quantity input.qty {
    width: 55px;
    height: 38px;
    font-size: 1rem;
    text-align: center;
    padding: 0;
}

.single-product form.cart button.single_add_to_cart_button {
    height: 38px;
    padding: 0 18px;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
}

/* ============================================================
   GPAY / EXPRESS CHECKOUT FIX
=========================================================== */
.single-product .woocommerce-product-form {
    display: block !important;
}

.single-product .wc-stripe-payment-request-wrapper {
    display: block !important;
    width: 100% !important;
    margin-top: 1.25rem !important;
    clear: both !important;
    padding: 0.5rem 0;
}

.single-product .wc-stripe-payment-request-button {
    border-radius: 6px !important;
    overflow: hidden;
}

.single-product form.cart {
    display: flex !important;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap !important;
}

.single-product form.cart .gpay-button-fill {
    flex: 0 0 100% !important;
    order: 999 !important;
    margin-top: 1.25rem !important;
    display: block !important;
    clear: both !important;
}

.single-product form.cart .gpay-button {
    width: 100% !important;
    display: block !important;
}

/* ============================================================
   SHOP HEADER — HIDE TITLE + SUBTITLE
=========================================================== */
.lsm-shop-header,
.lsm-shop-subtitle,
.lsm-shop-title {
    display: none !important;
}

/* ============================================================
   FINAL CLEAN SPACING FIXES — SAFE VERSION
=========================================================== */

/* Remove Smart Slider margins */
.woocommerce-shop .n2-section-smartslider,
.woocommerce-product-category .n2-section-smartslider {
    margin-top: 0 !important;
    margin-bottom: 0 !important;
}

/* Space above sorting bar */
.woocommerce-shop .woocommerce-ordering,
.woocommerce-product-category .woocommerce-ordering {
    margin-top: 10px !important;
}

/* Space below sorting bar */
.woocommerce-shop .woocommerce-ordering,
.woocommerce-product-category .woocommerce-ordering {
    margin-bottom: 20px !important;
}

/* Space above product grid */
.woocommerce-shop ul.products,
.woocommerce-product-category ul.products {
    margin-top: 20px !important;
}

/* REMOVE TOP GAP ABOVE SLIDER + CATEGORY IMAGES */
body.woocommerce-shop .lsm-main,
body.tax-product_cat .lsm-main,
body.tax-product_tag .lsm-main {
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* Force category banner image into page container */
.woocommerce-product-category .woocommerce-products-header img {
    width: 100%;
    max-width: 1200px;
    height: auto;
    display: block;
    margin: 0 auto;
    object-fit: cover;
}

/* CATEGORY PAGES — remove category title */
body.tax-product_cat h1.page-title {
    display: none !important;
}

/* CATEGORY PAGES — remove white gap under nav */
body.tax-product_cat .lsm-nav {
    margin-bottom: 0 !important;
}

/* Center category title */
.woocommerce-products-header .page-title {
    text-align: center !important;
    width: 100%;
    margin: 10px 0 20px 0 !important;
}

/* Remove WooCommerce header padding */
body.tax-product_cat .woocommerce-products-header {
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* FIX NAV WIDTH + HEIGHT ON WOOCOMMERCE PAGES */
body.woocommerce .lsm-nav .lsm-container,
body.tax-product_cat .lsm-nav .lsm-container,
body.tax-product_tag .lsm-nav .lsm-container {
    max-width: 1200px;   /* restore normal width */
    margin: 0 auto;      /* center it */
    padding-left: 15px;  /* match your site */
    padding-right: 15px;
    /* adjust these to match your normal header height */
    padding-top: 0;
    padding-bottom: 0;
}

/* ADD TO CART BUTTON TEXT COLOR */
.lsm-featured-wrapper .add_to_cart_button,
.add_to_cart_button,
.button.product_type_simple.add_to_cart_button {
    color: #ffffff !important; /* white text */
}

/* FIX HEADER HEIGHT ON WOOCOMMERCE PAGES */
body.woocommerce .lsm-header-main,
body.tax-product_cat .lsm-header-main,
body.tax-product_tag .lsm-header-main {
    padding-top: 0 !important;
    padding-bottom: 0 !important;
}

body.woocommerce .lsm-header-main .lsm-container,
body.tax-product_cat .lsm-header-main .lsm-container,
body.tax-product_tag .lsm-header-main .lsm-container {
    padding-top: 0 !important;
    padding-bottom: 0 !important;
}


body.tax-product_cat .term-description img {
    max-width: 100% !important;
    height: auto !important;
    display: block;
    margin: 0 auto;
}

/* FORCE CATEGORY IMAGE TO MATCH THEME WIDTH */
body.tax-product_cat .woocommerce-products-header .lsm-container {
    max-width: 1200px !important;
    margin: 0 auto !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
}

/* MAKE THE IMAGE RESPONSIVE */
body.tax-product_cat .woocommerce-products-header img {
    width: 100% !important;
    height: auto !important;
    display: block !important;
    margin: 0 auto !important;
}

/* FORCE CATEGORY IMAGE INTO A CONTAINER */
body.tax-product_cat .woocommerce-products-header {
    display: flex;
    justify-content: center;
}

body.tax-product_cat .woocommerce-products-header img {
    width: 100%;
    max-width: 1200px; /* match your theme width */
    height: auto;
    display: block;
}

/* Force category banner image into page container */
.woocommerce-product-category .woocommerce-products-header img {
    width: 100%;
    max-width: 1200px;
    height: auto;
    display: block;
    margin: 0 auto;
    object-fit: cover;
}

/* FIX CATEGORY PAGE OVERFLOW */
body.tax-product_cat .lsm-main {
    max-width: 1200px;
    margin: 0 auto;
    overflow-x: hidden;
    padding-left: 15px;
    padding-right: 15px;
    box-sizing: border-box;
}
