/* Native related/up-sell links with the catalog's existing card styling. */
body.single-product .related.products,
body.single-product .up-sells.products {
	clear: both;
	width: 100%;
	margin-top: 2.5rem;
}

body.single-product .related.products > h2,
body.single-product .up-sells.products > h2 {
	margin: 0 0 1.5rem;
	color: #141a24;
	font-size: 1.5rem;
	font-weight: 700;
	line-height: 1.3;
}

body.single-product .related.products > ul.products,
body.single-product .up-sells.products > ul.products {
	display: grid !important;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 22px 18px;
	margin: 0 !important;
	padding: 0 !important;
	list-style: none;
}

body.single-product .related.products > ul.products::before,
body.single-product .related.products > ul.products::after,
body.single-product .up-sells.products > ul.products::before,
body.single-product .up-sells.products > ul.products::after {
	display: none;
}

body.single-product ul.products li.indufort-related-card {
	--indufort-related-blue: #0067ff;
	--indufort-related-blue-dark: #003b95;
	float: none !important;
	clear: none !important;
	display: flex;
	flex-direction: column;
	box-sizing: border-box;
	width: auto !important;
	min-width: 0;
	margin: 0 !important;
	padding: 15px;
	border: 1px solid #e5e7eb;
	border-radius: 10px;
	background: #fff;
	box-shadow: 0 2px 5px rgb(0 0 0 / 3.5%);
	text-align: left;
	transition: box-shadow 200ms ease, border-color 200ms ease;
}

body.single-product ul.products li.indufort-related-card:hover {
	border-color: #d8dde3;
	box-shadow: 0 12px 28px rgb(0 0 0 / 12%);
}

body.single-product .indufort-related-card .astra-shop-thumbnail-wrap {
	position: relative;
	margin: 0 0 14px;
}

body.single-product .indufort-related-card .astra-shop-thumbnail-wrap > a {
	display: block;
	border-radius: 8px;
}

body.single-product .indufort-related-card .astra-shop-thumbnail-wrap img {
	display: block;
	width: 100%;
	height: 200px !important;
	max-height: none;
	margin: 0 !important;
	border-radius: 8px;
	object-fit: contain;
}

body.single-product .indufort-related-card .astra-shop-summary-wrap {
	display: flex;
	flex: 1;
	flex-direction: column;
	min-width: 0;
	padding: 0;
	text-align: left;
}

body.single-product .indufort-related-card .indufort-related-meta {
	min-height: 2.75rem;
}

body.single-product .indufort-related-card .indufort-related-brand {
	margin: 0 0 2px;
	color: #8b94a3;
	font-size: 11px;
	font-weight: 700;
	line-height: 1.25;
	letter-spacing: 0.025em;
	text-transform: uppercase;
	overflow-wrap: anywhere;
}

body.single-product .indufort-related-card .indufort-related-sku {
	margin: 0 0 8px;
	color: #8b94a3;
	font-size: 10px;
	font-weight: 400;
	line-height: 1.3;
	letter-spacing: 0.015em;
	text-transform: uppercase;
	overflow-wrap: anywhere;
}

body.single-product .indufort-related-card .ast-loop-product__link {
	display: block;
	margin: 0 0 8px;
	color: #141a24;
	text-decoration: none;
}

body.single-product .indufort-related-card .woocommerce-loop-product__title {
	display: -webkit-box;
	min-height: 2.7em;
	max-height: 2.7em;
	margin: 0 !important;
	padding: 0;
	overflow: hidden;
	color: #141a24;
	font-size: 13px !important;
	font-weight: 750;
	line-height: 1.35 !important;
	letter-spacing: 0;
	text-transform: uppercase;
	text-overflow: ellipsis;
	overflow-wrap: anywhere;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
	line-clamp: 2;
	transition: color 200ms ease;
}

body.single-product .indufort-related-card:hover .woocommerce-loop-product__title,
body.single-product .indufort-related-card:focus-within .woocommerce-loop-product__title {
	color: var(--indufort-related-blue-dark);
}

body.single-product .indufort-related-card .indufort-related-stock {
	margin: auto 0 0;
	padding-top: 16px;
	font-size: 13px;
	font-weight: 700;
	line-height: 1.5;
	letter-spacing: 0.02em;
}

body.single-product .indufort-related-stock--instock {
	color: #16803c;
}

body.single-product .indufort-related-stock--outofstock,
body.single-product .indufort-related-stock--onbackorder {
	color: #dc2626;
}

/* The stock label below the title replaces Astra's duplicate image overlay. */
body.single-product .indufort-related-card .ast-shop-product-out-of-stock,
body.single-product .indufort-related-card .ast-woo-product-category,
body.single-product .indufort-related-card .star-rating,
body.single-product .indufort-related-card .price,
body.single-product .indufort-related-card .button,
body.single-product .indufort-related-card .added_to_cart,
body.single-product .indufort-related-card .ast-on-card-button {
	display: none !important;
}

body.single-product .indufort-related-card a:focus-visible {
	outline: 2px solid var(--indufort-related-blue-dark);
	outline-offset: 3px;
}

body.single-product .indufort-related-card:focus-within {
	border-color: var(--indufort-related-blue-dark);
}

@media (max-width: 1023px) {
	body.single-product .related.products > ul.products,
	body.single-product .up-sells.products > ul.products {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 16px;
	}
}

@media (max-width: 600px) {
	body.single-product .related.products {
		margin-bottom: 20px;
		padding-bottom: 20px;
	}

	body.single-product ul.products li.indufort-related-card {
		padding: 12px;
		border-radius: 8px;
	}

	body.single-product .indufort-related-card .astra-shop-thumbnail-wrap img {
		height: 160px !important;
	}

	body.single-product .indufort-related-card .woocommerce-loop-product__title {
		font-size: 12px !important;
	}

	body.single-product .indufort-related-card .indufort-related-brand {
		font-size: 10px;
	}
}

@media (max-width: 340px) {
	body.single-product .related.products > ul.products,
	body.single-product .up-sells.products > ul.products {
		grid-template-columns: minmax(0, 1fr);
	}
}

@media (prefers-reduced-motion: reduce) {
	body.single-product ul.products li.indufort-related-card,
	body.single-product .indufort-related-card .woocommerce-loop-product__title {
		transition: none;
	}
}
