/**
 * Related Categories section — [megavar_related_categories] shortcode
 */

.megavar-related-categories {
	padding: 60px 40px;
}

.megavar-related-categories__title {
	font-family: "New Science", sans-serif;
	font-size: 1.75rem;
	font-weight: 700;
	color: #111111 !important;
	text-transform: uppercase;
	letter-spacing: 0.03em;
	margin: 0 0 32px;
	text-align: center;
}

.megavar-related-categories__grid {
	list-style: none;
	margin: 0 auto;
	padding: 0;
	max-width: 1500px;
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 16px;
}

/* ============================================================
   Card — background image with dark overlay
   Mirrors .other-services-card pattern
   ============================================================ */
.megavar-related-categories__card {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: 30px;
	padding: 10%;
	box-sizing: border-box;
	background-position: center center;
	background-size: cover;
	background-repeat: no-repeat;
	border-top: 5px solid var(--e-global-color-primary);
	border-right: 0;
	border-bottom: 0;
	border-left: 0;
	border-style: solid;
	min-height: 320px;
}

.megavar-related-categories__card::before {
	content: "";
	position: absolute;
	inset: 0;
	background-color: rgba(0, 0, 0, 0.7);
	z-index: 0;
}

.megavar-related-categories__card>* {
	position: relative;
	z-index: 1;
}

/* ============================================================
   Card row — title+arrow / desc+arrow
   ============================================================ */
.megavar-related-categories__card-row {
	display: flex;
	flex-direction: row;
	align-items: center;
	flex-wrap: nowrap;
	column-gap: 12px;
	row-gap: 0;
	margin: 0;
	padding: 0;
}

/* ============================================================
   Card title (category name)
   ============================================================ */
.megavar-related-categories__card-title {
	font-family: "New Science", sans-serif;
	font-size: 1.0625rem;
	font-weight: 600;
	text-transform: uppercase;
	line-height: 1.4;
	color: #ffffff;
	text-align: left;
	flex: 1;
	margin: 0;
}

.megavar-related-categories__card-title a {
	color: #ffffff;
	text-decoration: none;
}

.megavar-related-categories__card-title a:hover {
	text-decoration: underline;
}

/* ============================================================
   Card description ("when to use" text)
   ============================================================ */
.megavar-related-categories__card-desc {
	font-family: "Century Gothic", sans-serif;
	font-size: 0.9375rem;
	font-weight: 400;
	color: #ffffff;
	flex: 1;
	margin: 0;
	line-height: 1.5;
}

/* ============================================================
   Arrow
   ============================================================ */
.megavar-related-categories__card-arrow {
	width: 31px;
	height: 20px;
	display: block;
	flex-shrink: 0;
}

.megavar-related-categories__card-arrow img {
	width: 31px;
	height: 20px;
	display: block;
}

/* ============================================================
   Responsive — Mobile (max-width 767px)
   ============================================================ */
@media (max-width: 767px) {
	.megavar-related-categories {
		padding: 40px 24px;
	}

	.megavar-related-categories__title {
		font-size: 1.3rem;
	}

	.megavar-related-categories__grid {
		grid-template-columns: 1fr;
	}
}
