/* Carrossel de Depoimentos — estilos base e responsivos */

.tce-carousel {
	--tce-slides-per-view: 3;
	--tce-gap: 24px;
	--tce-speed: 500ms;
	--tce-ease: ease;
	position: relative;
	width: 100%;
}

.tce-track-viewport {
	overflow: hidden;
	width: 100%;
}

.tce-track {
	display: flex;
	will-change: transform, opacity;
	transition: transform var(--tce-speed) var(--tce-ease);
}

.tce-slide {
	flex: 0 0 calc((100% - (var(--tce-slides-per-view) - 1) * var(--tce-gap)) / var(--tce-slides-per-view));
	margin-right: var(--tce-gap);
	box-sizing: border-box;
	display: flex;
}

.tce-slide:last-child {
	margin-right: 0;
}

.tce-slide-card {
	width: 100%;
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	background: #fff;
	border-radius: 12px;
	padding: 32px;
	box-sizing: border-box;
}

.tce-avatar {
	width: 64px;
	height: 64px;
	border-radius: 50%;
	object-fit: cover;
	margin-bottom: 16px;
}

.tce-rating {
	color: #ffb800;
	letter-spacing: 2px;
	margin-bottom: 12px;
	font-size: 16px;
}

.tce-content {
	color: #4a4a4a;
	line-height: 1.6;
	margin-bottom: 20px;
}

.tce-content p:last-child {
	margin-bottom: 0;
}

.tce-author {
	margin-top: auto;
}

.tce-name {
	font-weight: 700;
	color: #1a1a1a;
}

.tce-title {
	color: #8a8a8a;
	font-size: 0.9em;
}

/* ---- Navegação: setas ---- */
.tce-arrow {
	appearance: none;
	-webkit-appearance: none;
	-moz-appearance: none;
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	width: 40px;
	height: 40px;
	margin: 0;
	border: 0;
	border-radius: 50%;
	background: #fff;
	color: #1a1a1a;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	z-index: 2;
	padding: 0;
	line-height: 0;
	transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease, opacity 0.2s ease;
}

.tce-arrow svg {
	width: 40%;
	height: 40%;
	display: block;
	pointer-events: none;
}

.tce-arrow:hover {
	transform: translateY(-50%) scale(1.08);
	box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
}

.tce-arrow:active {
	transform: translateY(-50%) scale(0.96);
}

.tce-arrow:focus-visible {
	outline: 2px solid currentColor;
	outline-offset: 3px;
}

.tce-arrow:disabled,
.tce-arrow.is-disabled {
	opacity: 0.35;
	cursor: default;
	box-shadow: none;
}

.tce-arrow:disabled:hover,
.tce-arrow.is-disabled:hover {
	transform: translateY(-50%);
}

.tce-arrow-prev {
	left: -20px;
}

.tce-arrow-next {
	right: -20px;
}

/* ---- Navegação: dots ---- */
.tce-dots {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	margin-top: 24px;
}

.tce-dot {
	appearance: none;
	-webkit-appearance: none;
	-moz-appearance: none;
	width: 8px;
	height: 8px;
	margin: 0;
	border-radius: 999px;
	border: 0;
	background: #d9d9d9;
	cursor: pointer;
	padding: 0;
	display: block;
	transition: background-color 0.25s ease, width 0.25s ease, opacity 0.2s ease;
}

.tce-dot:hover {
	background: #bdbdbd;
}

.tce-dot:focus-visible {
	outline: 2px solid #8a8a8a;
	outline-offset: 3px;
}

.tce-dot.is-active {
	width: 24px;
	background: #f7931e;
}

.tce-dot.is-active:hover {
	background: #f7931e;
}

/* ---- Estilos de transição ---- */

/* fade: exibe sempre 1 card, crossfade entre slides */
.tce-carousel[data-transition="fade"] .tce-track {
	transition: none;
}

.tce-carousel[data-transition="fade"] .tce-slide {
	opacity: 0;
	position: absolute;
	inset: 0;
	pointer-events: none;
	transition: opacity var(--tce-speed) var(--tce-ease);
}

.tce-carousel[data-transition="fade"] .tce-slide.is-active {
	opacity: 1;
	position: relative;
	pointer-events: auto;
}

.tce-carousel[data-transition="fade"] .tce-track-viewport {
	position: relative;
	min-height: 1px;
}

/* slide-fade: desliza e ao mesmo tempo esmaece nas bordas da transição */
.tce-carousel[data-transition="slide-fade"] .tce-track.is-animating {
	opacity: 0.4;
}

/* zoom: leve escala durante a transição */
.tce-carousel[data-transition="zoom"] .tce-track {
	transition: transform var(--tce-speed) var(--tce-ease);
}

.tce-carousel[data-transition="zoom"] .tce-track.is-animating {
	transform-origin: center;
}

.tce-carousel[data-transition="zoom"] .tce-slide-card {
	transition: transform var(--tce-speed) var(--tce-ease), opacity var(--tce-speed) var(--tce-ease);
}

.tce-carousel[data-transition="zoom"] .tce-track.is-animating .tce-slide-card {
	transform: scale(0.92);
	opacity: 0.6;
}

/* flip: gira levemente o card durante a transição */
.tce-carousel[data-transition="flip"] .tce-track-viewport {
	perspective: 1200px;
}

.tce-carousel[data-transition="flip"] .tce-slide-card {
	transition: transform var(--tce-speed) var(--tce-ease), opacity var(--tce-speed) var(--tce-ease);
	backface-visibility: hidden;
}

.tce-carousel[data-transition="flip"] .tce-track.is-animating .tce-slide-card {
	transform: rotateY(8deg);
	opacity: 0.7;
}

/* ---- Responsivo: fallback caso os controles responsivos do Elementor
       não tenham sido customizados pelo usuário ---- */
@media (max-width: 1024px) {
	.tce-carousel {
		--tce-slides-per-view: 2;
	}
}

@media (max-width: 767px) {
	.tce-carousel {
		--tce-slides-per-view: 1;
		--tce-gap: 12px;
	}

	.tce-arrow-prev {
		left: 4px;
	}

	.tce-arrow-next {
		right: 4px;
	}

	.tce-arrow {
		width: 34px;
		height: 34px;
		box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
	}

	.tce-slide-card {
		padding: 20px;
	}
}
