/* Nextech Insights Carousel — full-bleed Everon-style cards */

.nx-insights {
	--nx-brand: #2A388F;
	--nx-white: #ffffff;
	--nx-gap: 14px;
	/* Stay inside parent container — match its width */
	width: 100%;
	max-width: 100%;
	position: relative;
	box-sizing: border-box;
	background: transparent;
	color: var(--nx-white);
	padding: 20px;
	overflow: hidden;
}

.nx-insights *,
.nx-insights *::before,
.nx-insights *::after {
	box-sizing: border-box;
}

.nx-insights__inner {
	width: 100%;
	max-width: none;
	margin: 0 auto;
	padding: 0;
	position: relative;
}

.nx-insights__title {
	display: none;
}

.nx-insights__nav {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 16px;
	margin: 0 0 24px;
	padding: 0;
}

.nx-insights__arrow {
	appearance: none;
	width: 42px;
	height: 42px;
	border-radius: 50%;
	border: 1.5px solid rgba(255, 255, 255, 0.5);
	background: transparent;
	color: #ffffff;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	padding: 0;
	transition: background 0.2s, border-color 0.2s, opacity 0.2s;
}

.nx-insights__arrow:hover,
.nx-insights__arrow:focus {
	background: rgba(255, 255, 255, 0.12);
	border-color: #ffffff;
	color: #ffffff !important;
	outline: none;
}

.nx-insights__arrow:disabled {
	opacity: 0.3;
	cursor: default;
}

.nx-insights__viewport {
	overflow: hidden;
	width: 100%;
	padding: 0;
}

.nx-insights__track {
	display: flex;
	gap: var(--nx-gap);
	will-change: transform;
	transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}

.nx-insights__card {
	flex: 0 0 calc((100% - (var(--nx-gap) * 0.2)) / 1.2);
	margin: 0;
	border-radius: 14px;
	overflow: hidden;
	position: relative;
	height: 340px;
	background: #1a2460;
}

.nx-insights__link {
	display: block;
	width: 100%;
	height: 100%;
	position: relative;
	text-decoration: none !important;
	color: #ffffff !important;
}

.nx-insights__link:hover,
.nx-insights__link:focus,
.nx-insights__link:active,
.nx-insights__link:visited {
	color: #ffffff !important;
	text-decoration: none !important;
}

.nx-insights__media {
	position: absolute;
	inset: 0;
}

.nx-insights__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform 0.5s ease;
}

.nx-insights__card:hover .nx-insights__media img {
	transform: scale(1.05);
}

.nx-insights__overlay {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	padding: 24px 20px 22px;
	background: linear-gradient(
		180deg,
		rgba(0, 0, 0, 0) 0%,
		rgba(0, 0, 0, 0.35) 35%,
		rgba(0, 0, 0, 0.75) 100%
	);
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 6px;
	min-height: 40%;
	justify-content: flex-end;
	transition: background 0.3s ease;
}

.nx-insights__card:hover .nx-insights__overlay {
	background: linear-gradient(
		180deg,
		rgba(0, 0, 0, 0.05) 0%,
		rgba(0, 0, 0, 0.5) 30%,
		rgba(0, 0, 0, 0.88) 100%
	);
}

.nx-insights__card-title {
	margin: 0;
	font-size: 1rem;
	font-weight: 700;
	line-height: 1.35;
	color: #ffffff !important;
}

.nx-insights__excerpt {
	margin: 0;
	font-size: 0.78rem;
	font-weight: 400;
	line-height: 1.45;
	color: rgba(255, 255, 255, 0.9) !important;
	max-height: 0;
	opacity: 0;
	overflow: hidden;
	transform: translateY(6px);
	transition: max-height 0.35s ease, opacity 0.3s ease, transform 0.3s ease, margin 0.3s ease;
}

.nx-insights__card:hover .nx-insights__excerpt,
.nx-insights__card:focus-within .nx-insights__excerpt {
	max-height: 4.5em;
	opacity: 1;
	transform: none;
	margin: 2px 0 2px;
}

.nx-insights__cta {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-size: 0.85rem;
	font-weight: 600;
	color: #ffffff !important;
	text-decoration: none !important;
}

.nx-insights__link:hover .nx-insights__cta,
.nx-insights__link:focus .nx-insights__cta,
.nx-insights__cta:hover {
	color: #ffffff !important;
}

/* ─── Tablet: 3 in row ─── */
@media (min-width: 768px) {
	.nx-insights {
		padding: 0;
	}

	.nx-insights__nav {
		margin-bottom: 28px;
	}

	.nx-insights__card {
		flex: 0 0 calc((100% - (var(--nx-gap) * 2)) / 3);
		height: 380px;
	}

	.nx-insights__card-title {
		font-size: 1.05rem;
	}
}

/* ─── Desktop: 5 in row ─── */
@media (min-width: 1024px) {
	.nx-insights {
		padding: 0;
	}

	.nx-insights__card {
		flex: 0 0 calc((100% - (var(--nx-gap) * 4)) / 5);
		height: 400px;
		border-radius: 14px;
	}

	.nx-insights__overlay {
		padding: 24px 20px 22px;
	}

	.nx-insights__card-title {
		font-size: 1.1rem;
	}

	.nx-insights__excerpt {
		font-size: 0.8rem;
	}
}
