/**
 * Testimonials Marquee — Pure CSS infinite scroll
 * Modeled after the working ticker component.
 *
 * @package FashionXpart
 * @since FashionXpart 1.0
 */

@keyframes marquee-ltr {
	from { transform: translateX(0); }
	to { transform: translateX(-50%); }
}

@keyframes marquee-rtl {
	from { transform: translateX(-50%); }
	to { transform: translateX(0); }
}

/* Container */
.wp-block-group.fxp-testimonials-marquee {
	overflow: hidden;
	padding: clamp(20px, 3vw, 35px) 0;
	background: var(--wp--preset--color--off-white);
	-webkit-mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
	mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
}

/* Row — Group block with flex layout (same as ticker track) */
.wp-block-group.fxp-marquee-row {
	display: flex;
	flex-wrap: nowrap;
	width: max-content;
	max-width: none !important;
}

.wp-block-group.fxp-marquee-row .wp-block-group__layout {
	max-width: none !important;
	display: flex !important;
	flex-wrap: nowrap !important;
	width: max-content !important;
}

.wp-block-group.fxp-marquee-row + .wp-block-group.fxp-marquee-row {
	margin-top: 12px;
}

/* Animation */
.wp-block-group.fxp-marquee-row--ltr {
	animation: marquee-ltr 30s linear infinite;
}

.wp-block-group.fxp-marquee-row--rtl {
	animation: marquee-rtl 30s linear infinite;
}

/* Pause on hover */
.wp-block-group.fxp-marquee-row:hover {
	animation-play-state: paused;
}

/* Card */
.fxp-testimonial-card {
	flex-shrink: 0;
	width: 260px;
	background: var(--wp--preset--color--base);
	border: 1px solid var(--wp--preset--color--light-gray);
	border-radius: 12px;
	padding: 20px;
	display: flex;
	flex-direction: column;
	gap: 16px;
}

/* Quote */
.fxp-testimonial-quote {
	color: var(--wp--preset--color--light-gray);
	font-weight: 700;
	font-size: 3rem;
	line-height: 1;
	user-select: none;
	margin: 0;
}

/* Text */
.fxp-testimonial-text {
	font-size: var(--wp--preset--font-size--small);
	color: var(--wp--preset--color--dark-gray);
	line-height: 1.7;
	margin: 0;
	flex: 1;
}

/* Separator */
.fxp-testimonial-separator {
	border: none;
	border-top: 1px solid var(--wp--preset--color--light-gray);
	margin: 0;
	width: 100%;
}

/* Author */
.fxp-testimonial-author {
	display: flex;
	align-items: center;
	gap: 12px;
}

.fxp-testimonial-avatar {
	width: 36px;
	height: 36px;
	min-width: 36px;
	border-radius: 50%;
	background: var(--wp--preset--color--light-gray);
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	color: var(--wp--preset--color--dark-gray);
	overflow: hidden;
	line-height: 0;
}

.fxp-testimonial-avatar svg {
	width: 18px;
	height: 18px;
}

.fxp-testimonial-name {
	font-size: var(--wp--preset--font-size--small);
	font-weight: 600;
	color: var(--wp--preset--color--contrast);
	margin: 0;
	line-height: 1.3;
}

/* Tablet */
@media (min-width: 600px) {
	.fxp-testimonial-card {
		width: 280px;
		padding: 24px;
		gap: 18px;
	}

	.fxp-testimonial-avatar {
		width: 40px;
		height: 40px;
		min-width: 40px;
	}

	.fxp-testimonial-avatar svg {
		width: 20px;
		height: 20px;
	}
}

/* Desktop */
@media (min-width: 1024px) {
	.fxp-testimonial-card {
		width: 300px;
		padding: 28px;
		gap: 20px;
	}

	.fxp-testimonial-avatar {
		width: 44px;
		height: 44px;
		min-width: 44px;
	}
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
	.wp-block-group.fxp-marquee-row {
		animation: none !important;
	}
}