/* 5th Axis — Related Products */

.axis5th-related-products {
	--axis5th-rp-columns: 3;
	--axis5th-rp-card-bg: #ffffff;
	--axis5th-rp-card-border: #e5e5e5;
	--axis5th-rp-eyebrow-color: #9a9a9a;
	--axis5th-rp-title-color: #1a1a1a;
	--axis5th-rp-desc-color: #6c6c6c;
	--axis5th-rp-btn-color: #1a1a1a;
	--axis5th-rp-btn-hover-bg: #1a1a1a;
	--axis5th-rp-btn-hover-color: #ffffff;
}

.axis5th-related-products__header {
	margin-bottom: 1.5rem;
}

.axis5th-related-products__eyebrow-label {
	font-size: 0.8rem;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var( --axis5th-rp-eyebrow-color );
	margin: 0 0 0.4rem;
}

.axis5th-related-products__heading {
	margin: 0;
}

.axis5th-related-products__grid {
	display: grid;
	grid-template-columns: repeat( var( --axis5th-rp-columns ), minmax( 0, 1fr ) );
	gap: 1.75rem;
}

.axis5th-related-products__card {
	display: flex;
	flex-direction: column;
	background: var( --axis5th-rp-card-bg );
	border: 1px solid var( --axis5th-rp-card-border );
	padding: 16px;
	overflow: hidden;
	transition: box-shadow 0.25s ease, border-color 0.25s ease;
}

.axis5th-related-products__card:hover {
	box-shadow: 0 8px 24px rgba( 0, 0, 0, 0.08 );
}

.axis5th-related-products__image {
	display: flex;
	align-items: center;
	justify-content: center;
	aspect-ratio: 16 / 11;
	background: #f5f5f5;
	padding: 1.75rem;
	height: 293px;
}

.axis5th-related-products__image img {
	width: 100%;
	height: 100%;
	object-fit: contain;
	display: block;
}

.axis5th-related-products__body {
	display: flex;
	flex-direction: column;
	padding-top: 20px;
	gap: 0.5rem;
}

.axis5th-related-products__eyebrow {
    font-family: var(--e-global-typography-57475c0-font-family), Sans-serif;
    font-size: var(--e-global-typography-57475c0-font-size);
    font-weight: 400;
    text-transform: uppercase;
    color: var(--e-global-color-secondary);
	margin: 0 0 0.4rem;
}

.axis5th-related-products__title {
	margin: 0;
	font-size: 20px;
	font-weight: 500;
	color: var(--e-global-color-accent);
}

.axis5th-related-products__title a {
	color: var( --axis5th-rp-title-color );
	text-decoration: none;
	display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
	height: 48px;
}

.axis5th-related-products__desc {
	margin: 0;
	font-size: 16px;
	line-height: 24px;
	font-weight: 400;
	color: var(--e-global-color-text);
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.axis5th-related-products__actions {
	display: flex;
	flex-wrap: nowrap;
	gap: 0.5rem;
	margin-top: 1rem;
}

.axis5th-related-products__btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.5rem;
	padding: 0.9rem 1.25rem;
	font-size: 14px;
	font-weight: 500;
	text-decoration: none;
	white-space: nowrap;
	background: transparent;
	color: var(--e-global-color-accent);
	border: 1px solid #E4E4E7;
	transition: background 0.2s ease, color 0.2s ease;
}

/* Request Quote, Add to cart and Explore share one row, so the buttons are
   tighter than the old two-button layout to fit a 3-column card. */
.axis5th-related-products .axis5th-related-products__actions .axis5th-related-products__btn {
	flex: 1 1 auto;
	min-width: 0;
	gap: 0.35rem;
	padding: 0.75rem 0.5rem;
	font-size: 13px;
}

.axis5th-related-products__btn--primary {
	border-color: #18181B;
}

.axis5th-related-products__btn:hover {
	background: var( --axis5th-rp-btn-hover-bg );
	color: var( --axis5th-rp-btn-hover-color );
}

.axis5th-related-products .axis5th-related-products__btn--cart {
	color: #ffffff;
	background: #dd2828;
	border-color: #dd2828;
}

.axis5th-related-products .axis5th-related-products__btn--cart:hover,
.axis5th-related-products .axis5th-related-products__btn--cart:focus-visible {
	color: #ffffff;
	background: #b91f1f;
	border-color: #b91f1f;
}

.axis5th-related-products .axis5th-related-products__btn--cart.loading {
	opacity: 0.7;
	cursor: progress;
}

.axis5th-related-products .axis5th-related-products__btn--cart.added {
	background: #2a7a2a;
	border-color: #2a7a2a;
}

/* WooCommerce inserts a "View cart" link after an AJAX add; the header cart
   already updates, and the link would break the button row. */
.axis5th-related-products__actions .added_to_cart {
	display: none;
}

