/**
 * Testimonials carousel ("Velilerimiz Ne Diyor?", ReferencesSection) — a deliberate change from the
 * original grid (2026-09-30). The generated block markup is untouched. Everything here is scoped to
 * .ep-carousel-ready, which assets/js/site/carousel.js adds to the grid together with the controls
 * (.ep-carousel-*): without JS, and in the block editor's preview, the original grid shows every quote
 * in full. With it, quotes are clamped to a fixed number of lines so every card has the same height.
 * Class names come from the original compiled CSS (assets/next), which never changes.
 */

.ReferencesSection-module__bPQJNG__grid.ep-carousel-ready {
	display: flex;
	gap: 16px;
	overflow-x: auto;
	overscroll-behavior-x: contain;
	scroll-snap-type: x mandatory;
	scroll-behavior: smooth;
	/* Phones: the track bleeds to the screen edges and the next card peeks in. */
	margin: 0 calc(-1 * var(--margin-mobile));
	padding: 4px var(--margin-mobile) 12px;
	scroll-padding-inline: var(--margin-mobile);
	scrollbar-width: none;
}

.ReferencesSection-module__bPQJNG__grid.ep-carousel-ready::-webkit-scrollbar {
	display: none;
}

/* Arrow/dot paging scrolls programmatically; WebKit fights smooth scrolls against mandatory snapping. */
.ReferencesSection-module__bPQJNG__grid.ep-carousel-moving {
	scroll-snap-type: none;
}

.ReferencesSection-module__bPQJNG__grid.ep-carousel-ready > * {
	display: flex;
	flex: 0 0 86%;
	height: auto;
	scroll-snap-align: start;
}

/* Cards travel with the track; the per-card scroll reveal would fire mid-swipe. */
.ReferencesSection-module__bPQJNG__grid.ep-carousel-ready > .scroll-reveal {
	opacity: 1;
	transform: none;
	transition: none;
}

.ep-carousel-ready .ReferencesSection-module__bPQJNG__card {
	flex: 1;
	height: auto;
}

.ep-carousel-ready .ReferencesSection-module__bPQJNG__quote {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 8;
	line-clamp: 8;
	overflow: hidden;
}

.ep-carousel-ready .ReferencesSection-module__bPQJNG__author {
	padding-top: 16px;
	border-top: 1px solid var(--color-surface-variant);
}

.ep-carousel-ready:focus-visible {
	outline: 2px solid var(--color-secondary);
	outline-offset: 2px;
	border-radius: 8px;
}

@media (min-width: 768px) {
	.ReferencesSection-module__bPQJNG__grid.ep-carousel-ready {
		gap: 24px;
		margin: 0 -4px;
		padding: 4px 4px 12px;
		scroll-padding-inline: 4px;
	}

	.ReferencesSection-module__bPQJNG__grid.ep-carousel-ready > * {
		flex-basis: calc((100% - 24px) / 2);
	}

	.ep-carousel-ready .ReferencesSection-module__bPQJNG__quote {
		-webkit-line-clamp: 7;
		line-clamp: 7;
	}
}

@media (min-width: 1024px) {
	.ReferencesSection-module__bPQJNG__grid.ep-carousel-ready > * {
		flex-basis: calc((100% - 48px) / 3);
	}
}

.ep-carousel-more {
	display: inline-flex;
	align-items: center;
	align-self: flex-start;
	gap: 6px;
	margin-top: -6px;
	padding: 4px 0;
	border: 0;
	background: none;
	cursor: pointer;
	font-family: var(--font-bold);
	font-size: 14px;
	font-weight: 700;
	color: var(--color-primary);
}

.ep-carousel-more svg {
	width: 16px;
	height: 16px;
	transition: transform 0.2s ease;
}

.ep-carousel-more:hover span {
	text-decoration: underline;
	text-underline-offset: 3px;
}

.ep-carousel-more:hover svg {
	transform: translateX(3px);
}

.ep-carousel-nav {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 16px;
	margin-top: 28px;
}

.ep-carousel-arrow {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 1px solid var(--color-outline-variant);
	border-radius: 50%;
	background: var(--color-white);
	color: var(--color-primary);
	cursor: pointer;
	transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, opacity 0.2s ease;
}

.ep-carousel-arrow:hover:not(:disabled) {
	border-color: var(--color-primary);
	background: var(--color-primary);
	color: var(--color-white);
}

.ep-carousel-arrow:disabled {
	opacity: 0.35;
	cursor: default;
}

.ep-carousel-dots {
	display: flex;
	align-items: center;
	gap: 4px;
}

.ep-carousel-dot {
	position: relative;
	width: 16px;
	height: 24px;
	padding: 0;
	border: 0;
	background: none;
	cursor: pointer;
	transition: width 0.25s ease;
}

.ep-carousel-dot::before {
	content: "";
	position: absolute;
	top: 50%;
	left: 50%;
	width: 8px;
	height: 8px;
	border-radius: 4px;
	background: var(--color-outline-variant);
	transform: translate(-50%, -50%);
	transition: width 0.25s ease, background-color 0.25s ease;
}

.ep-carousel-dot[aria-current="true"] {
	width: 32px;
}

.ep-carousel-dot[aria-current="true"]::before {
	width: 24px;
	background: var(--color-primary);
}

.ep-carousel-counter {
	min-width: 64px;
	text-align: center;
	font-family: var(--font-medium);
	font-size: 14px;
	font-variant-numeric: tabular-nums lining-nums;
	color: var(--color-on-surface-variant);
}

.ep-carousel-more:focus-visible,
.ep-carousel-arrow:focus-visible,
.ep-carousel-dot:focus-visible {
	outline: 2px solid var(--color-secondary);
	outline-offset: 2px;
}

.ep-carousel-dots[hidden],
.ep-carousel-counter[hidden],
.ep-carousel-more[hidden] {
	display: none;
}

@media (prefers-reduced-motion: reduce) {
	.ReferencesSection-module__bPQJNG__grid.ep-carousel-ready {
		scroll-behavior: auto;
	}

	.ep-carousel-more svg,
	.ep-carousel-arrow,
	.ep-carousel-dot,
	.ep-carousel-dot::before {
		transition: none;
	}
}
