
.custom-product-card {
	list-style: none;
	margin: 0;
	padding: 0;
	overflow: hidden;
	background: #fff;
	transition: transform 0.2s ease, box-shadow 0.2s ease;
	border: 2px solid #9999993d;
}

.custom-product-card:hover {
	transform: translateY(-2px);
}

.product-card-container {
	position: relative;
	display: flex;
	flex-direction: column;
	height: 100%;
}

/* Product Image Container */
.product-image-container {
	position: relative;
	background: #eeeeee;
	isolation: isolate;
	width: 100%;
	height: 160px; /* fixed height to ensure image area */
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
}

.product-image-container img {
	max-width: 100%;
	max-height: 100%;
	width: auto;
	height: auto;
	display: block;
	mix-blend-mode: multiply;
	transition: transform 0.3s ease;
}

.product-image-container > a { 
	width: 180px;
}

.custom-product-card:hover .product-image-container img {
	transform: scale(1.05);
}

/* Product Info Container */
.product-info-container {
	padding: 10px;
	flex-grow: 1;
	display: flex;
	flex-direction: column;
}

/* Product Title */
.product-title-wrapper h2,
.product-title-wrapper .woocommerce-loop-product__title {
	font-size: 16px;
	color: #333;
	margin: 0;
	line-height: 1.4;
	display: -webkit-box;
	line-clamp: 2;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	text-overflow: ellipsis;
	font-family: poppins;
	font-weight: 500;
}

.category-page-row .product-title-wrapper .woocommerce-loop-product__title {
	font-size: 13px;
}

.product-title-wrapper a {
	text-decoration: none;
	color: inherit;
}

.product-title-wrapper a:hover {
	color: #0073aa;
}

/* Product Meta (Rating & Price) */
.product-meta-wrapper {
	margin-top: auto;
}

/* Star Rating */
.star-rating {
	font-size: 12px;
	margin-bottom: 8px;
}

/* Price Styling */
.price {
	font-weight: 600;
	font-size: 18px;
	color: #333;
	margin: 0;
	display: flex;
	align-items: center;
	gap: 8px;
}


/* Hide wishlist heart icon (YITH or similar) */
.yith-wcwl-add-to-wishlist,
.yith-wcwl-add-button {
	display: none !important;
}

/* Improve onsale ribbon */
.onsale {
	background: #000 !important;
	color: #fff !important;
	padding: 6px 10px !important;
	font-size: 12px !important;
	font-weight: 700 !important;
	letter-spacing: 0.5px;
	border-radius: 0 0 4px 0 !important;
	clip-path: polygon(0 0, 100% 0, 90% 100%, 0% 100%);
}

.badge-container {
	top: -2px !important;
	left: -4px !important;
	margin: 0 !important;
}

.badge-container .callout .badge-inner {
	background: none !important;
	background-color: #00000000 !important;
}

.product-main .badge-container {
	top: 0 !important;
	left: 0 !important;
	margin: 0 !important;
}

.listrak-badge-inner {
	background-color: transparent !important;
    color: #fcb526;
    font-weight: bold !important;
    text-transform: uppercase;
    padding: 0px 0px 0px 4px;
}

/* Save Percentage */
.save-percentage {
	background:rgb(255, 231, 232);
	color: rgb(224, 0, 22);
	padding: 3px 7px;
	border-radius: 3px;
	font-size: .85rem;
	font-weight: 600;
	display: inline-block;
	margin: 6px 0 4px 0;
	letter-spacing: 0.3px;
	line-height: 1;
}

/* MSRP tweaks */
.msrp-text, .msrp-price{
	font-size: .7rem;
	color: gray !important;
	margin-top: 2px;
}

.msrp .amount {
	color: gray !important;
	font-weight: 400 !important;
}

/* ======== Grid Layout ======== */
ul.products {
	display: flex;
	flex-wrap: wrap;
	gap: 24px; /* horizontal & vertical spacing */
	padding: 0;
}

.category-page-row li.custom-product-card {
	display: block;
	flex: 1 1 calc(25% - 20px); /* 4 per row desktop */
	max-width: calc(25% - 20px) !important;
	margin-bottom: 15px; /* fallback vertical spacing for browsers without flex gap */
}

.home li.custom-product-card {
	display: block;
	flex: 1 1 calc(25% - 17px); /* 4 per row desktop */
	max-width: calc(25%) !important;
	margin-bottom: 15px; /* fallback vertical spacing for browsers without flex gap */
}

.category-page-row .products, .div > .dbi-custom-column-gap {
	column-gap: 20px;
}

.products-section-wrapper.layout-two-by-two .products-section li.custom-product-card {
	max-width: none !important;
	flex: 1 1 auto !important;
	height: 100%;
}

@media (min-width: 1025px) and (max-width: 1120px) {
	.products-section-wrapper.layout-two-by-two .products-section li.custom-product-card {
		min-width: 220px;
	}

	.products-section-wrapper.layout-two-by-two .product-image-container {
		height: 150px;
	}
}

.msrp-lowest-price-wrapper {
	display: flex;
	align-items: center;
}

.lowest-price {
	font-size: .85rem;
	margin-bottom: 6px;
	margin-top: 8px;
}

.lowest-price-amount span.woocommerce-Price-amount {
	color: black !important;
	font-weight: bold !important;
	font-size: 1.3rem;
}

.msrp-lowest-price-wrapper .lowest-price-amount {
	padding-left: 9px;
}

/* Responsive Design */
@media (max-width: 1024px) {
	li.custom-product-card {
		flex: 1 1 calc(25% - 16px); /* 4 per row */
		max-width: calc(25% - 16px);
	}
}

@media (max-width: 768px) {
	/* Avoid fixed anchor width that can overflow small columns */
	.product-info-container {
		padding: 8px;
	}
	
	.product-title-wrapper h2,
	.product-title-wrapper .woocommerce-loop-product__title {
		font-size: 13px;
	}
	
	.price {
		font-size: 14px;
	}

	.category-page-row .products, div > .dbi-custom-column-gap {
		margin: 0px !important;
		column-gap: 3%;
	}

	.msrp span.woocommerce-Price-amount {
		font-size: 0.7rem !important;
		text-decoration: line-through;
	}

	.lowest-price-amount span.woocommerce-Price-amount {
		color: black !important;
		font-weight: bold !important;
		font-size: 1rem;
	}

	/* Clamp link width so images stay centered without overflowing */
	.product-image-container > a {
		width: 100%;
		max-width: 180px;
		margin-left: auto;
		margin-right: auto;
	}
}

@media (max-width: 480px) {
	.lowest-price-amount span.woocommerce-Price-amount {
		color: black !important;
		font-weight: bold !important;
		font-size: 1.1rem;
	}

	.msrp span.woocommerce-Price-amount {
		font-size: 12px !important;
		text-decoration: line-through;
	}
	
	.category-page-row .products, div > .dbi-custom-column-gap {
		margin: 0px !important;
		column-gap: 4%;
	}
	
	.custom-product-card .stamped-product-reviews-badge {
		display: flex !important;
		flex-direction: column !important;
		align-items: flex-start !important;
		white-space: nowrap !important;
		line-height: 1.2 !important;
	}
	
	.custom-product-card .stamped-product-reviews-badge .stamped-badge {
		margin: 0 !important;
		margin-bottom: 2px !important;
	}
	
	.custom-product-card .stamped-product-reviews-badge[data-id] {
		font-size: 11px !important; 
	}
}

@media (max-width: 425px) {
	li.custom-product-card,
	.category-page-row li.custom-product-card,
	.home li.custom-product-card {
		flex: 1 1 calc(50% - 8px); /* 2 per row */
		max-width: calc(50% - 8px) !important;
	}
}

@media (max-width: 375px) {
	.msrp-text {
		display: none !important;
	}
}

/* ================= Wishlist Icon (fix visibility/position) ================= */
.product-image-container .image-tools {
	opacity: 1 !important;
	visibility: visible !important;
	transform: none !important;
	position: absolute;
	z-index: 2;
	pointer-events: auto;
}

.product-image-container .image-tools .wishlist-icon {
	display: block !important;
}

.dbi-wishlist-button.button.is-outline.circle.icon {
	width: 36px;
	height: 36px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 0;
}

.dbi-wishlist-button .icon-heart,
.dbi-wishlist-button .icon-heart:before {
	font-size: 16px;
}

.badge-container .callout .badge-inner {
	background: none !important;
	background-color: #00000000 !important;
}

.product-image-container {
	position: relative;
}

.product-image-container .wishlist-icon {
	position: absolute;
	top: 0.75rem;
	right: 0.75rem;
	z-index: 5;
	display: flex;
	align-items: center;
	justify-content: center;
	opacity: 0;
	pointer-events: none;
	transition: opacity .2s ease;
}

.product-card-container:hover .wishlist-icon,
.product-card-container:focus-within .wishlist-icon {
	opacity: 1;
	pointer-events: auto;
}

.product-image-container .dbi-wishlist-button {
	width: 34px;
	height: 34px;
	padding: 0;
	display: flex;
	align-items: center;
	justify-content: center;
}

.product-image-container .dbi-wishlist-button i {
	font-size: 14px;
	line-height: 1;
}

.product-image-container .wishlist-popup {
	padding: 0.35rem 0.75rem;
	border-radius: 5px;
	margin-top: 0.25rem;
	right: 0;
	min-width: 130px;
	text-align: center;
}

.product-image-container .wishlist-popup:after {
	display: none;
}

.product-info .yith-add-to-wishlist-button-block {
	float: initial !important;
	margin: 0 !important;
}

.yith-add-to-wishlist-button-block {
	margin: 2px auto !important;
}

.yith-wcwl-add-to-wishlist-button:is(button) {
	padding: 0px 0px !important;
}

@media (max-width: 768px) {
	.product-image-container .yith-wcwl-add-to-wishlist-button:is(button) {
		font-size: .75rem !important;
	}

	.product-image-container .wishlist-icon {
		opacity: 1;
		pointer-events: auto;
	}
}

@media (max-width: 425px) {
	.product-image-container .wishlist-icon {
		width: 25px !important;
		height: 25px !important;
	}

	.product-image-container .dbi-wishlist-button {
		font-size: 13px !important;
	}

	.product-image-container .dbi-wishlist-button.button.is-outline.circle.icon {
		height: 30px !important;
	}
}