/**
 * Product listing pages — space between last product row and footer specifications bar.
 *
 * footer-redesign.css pulls the footer up with negative margin-top; on listing pages
 * that causes overlap with the last row of Add to cart buttons.
 */

/* Stop pulling specifications bar into the product grid */
body.ln-product-listing-page .footer-wrapper > footer#main-footer .elementor-240.elementor-location-footer {
	margin-top: 0 !important;
}

/* White breathing room after the last product row (desktop) */
body.ln-product-listing-page #main .elementor-wc-products {
	margin-bottom: 56px !important;
}

body.ln-product-listing-page #main .elementor-wc-products ul.products {
	margin-bottom: 0 !important;
}

@media (max-width: 1024px) {
	body.ln-product-listing-page #main .elementor-wc-products {
		margin-bottom: 32px !important;
	}
}

@media (max-width: 767px) {
	body.ln-product-listing-page #main .elementor-wc-products {
		margin-bottom: 24px !important;
	}

	/*
	 * /shop + /gifting mobile: second column was clipping because the grid used a
	 * 20px gap with fixed track sizes wider than the padded content box.
	 * Use fluid 2-col tracks + 12px gap so both columns fit with balanced side inset.
	 */
	body.woocommerce-shop #main,
	body.ln-shop-page-parity #main,
	body.page-id-988149 #main {
		padding-left: 16px !important;
		padding-right: 16px !important;
		box-sizing: border-box !important;
		width: 100% !important;
		max-width: 100% !important;
	}

	body.woocommerce-shop #main .elementor-wc-products,
	body.ln-shop-page-parity #main .elementor-wc-products,
	body.page-id-988149 #main .elementor-wc-products,
	body.woocommerce-shop #main .elementor-wc-products ul.products,
	body.ln-shop-page-parity #main .elementor-wc-products ul.products,
	body.page-id-988149 #main .elementor-wc-products ul.products {
		width: 100% !important;
		max-width: 100% !important;
		box-sizing: border-box !important;
	}

	body.woocommerce-shop #main .elementor-wc-products ul.products,
	body.ln-shop-page-parity #main .elementor-wc-products ul.products,
	body.page-id-988149 #main .elementor-wc-products ul.products {
		display: grid !important;
		grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
		column-gap: 12px !important;
		row-gap: 24px !important;
		margin-left: 0 !important;
		margin-right: 0 !important;
		padding-left: 0 !important;
		padding-right: 0 !important;
	}

	body.woocommerce-shop #main .elementor-wc-products ul.products li.product,
	body.ln-shop-page-parity #main .elementor-wc-products ul.products li.product,
	body.page-id-988149 #main .elementor-wc-products ul.products li.product {
		width: auto !important;
		max-width: none !important;
		min-width: 0 !important;
		margin: 0 !important;
		float: none !important;
		box-sizing: border-box !important;
	}

	/*
	 * /gifting only: product titles max 2 lines with ellipsis.
	 * min-height keeps Add to Cart vertically aligned across cards.
	 */
	body.page-id-988149 #main .elementor-wc-products ul.products li.product .woocommerce-loop-product__title,
	body.page-id-988149 #main .elementor-wc-products ul.products li.product h2.woocommerce-loop-product__title {
		display: -webkit-box !important;
		-webkit-box-orient: vertical !important;
		-webkit-line-clamp: 2 !important;
		line-clamp: 2 !important;
		overflow: hidden !important;
		text-overflow: ellipsis !important;
		min-height: 2.5em !important;
		max-height: 2.5em !important;
	}
}
