/* ais-phone-testimonial-slider frontend styles (prefix: aispts-) */

.aispts-wrapper {
	--aispts-visible: 3;
	display: flex;
	align-items: center;
	gap: 16px;
	position: relative;
	width: 100%;
}

.aispts-viewport {
	overflow: hidden;
	flex: 1 1 auto;
	width: 100%;
}

.aispts-track {
	display: flex;
	gap: 24px;
	transition: transform 0.5s ease;
}

.aispts-slide {
	flex: 0 0 calc((100% - (var(--aispts-visible) - 1) * 24px) / var(--aispts-visible));
	min-width: 0;
}

.aispts-phone {
	position: relative;
	overflow: hidden;
}

/* interactive hover effect — toggled via the "Hover Interaction" widget setting */
.aispts-phone.aispts-hover-fx {
	cursor: pointer;
	transition: transform 0.35s ease;
	will-change: transform;
}

.aispts-phone.aispts-hover-fx:hover {
	transform: translateY(0px) scale(0.95);
}

.aispts-phone.aispts-hover-fx:active {
	transform: translateY(-2px) scale(0.99);
}

/* soft shine sweep across the phone card on hover */
.aispts-phone.aispts-hover-fx::before {
	content: "";
	position: absolute;
	top: 0;
	left: -75%;
	width: 50%;
	height: 100%;
	background: linear-gradient(
		120deg,
		rgba(255, 255, 255, 0) 0%,
		rgba(255, 255, 255, 0.35) 50%,
		rgba(255, 255, 255, 0) 100%
	);
	transform: skewX(-20deg);
	transition: left 0.6s ease;
	pointer-events: none;
	z-index: 3;
}

.aispts-phone.aispts-hover-fx:hover::before {
	left: 130%;
}

@media (prefers-reduced-motion: reduce) {
	.aispts-phone.aispts-hover-fx {
		transition: none;
	}
	.aispts-phone.aispts-hover-fx::before {
		display: none;
	}
}

.aispts-phone-img {
	width: 100%;
	height: auto;
	display: block;
}

.aispts-phone-overlay {
	position: absolute;
	inset: 0;
	background: linear-gradient(to top, rgba(0, 0, 0, 0.75) 0%, rgba(0, 0, 0, 0) 45%);
	pointer-events: none;
}

.aispts-play-btn {
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	width: 56px;
	height: 56px;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.9);
	border: none;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	padding: 0;
	transition: transform 0.25s ease, background-color 0.25s ease;
}

.aispts-play-btn:hover {
	transform: translate(-50%, -50%) scale(1.08);
}

.aispts-play-btn svg,
.aispts-play-btn img {
	width: 22px;
	height: 22px;
}

.aispts-play-btn svg {
	fill: #111;
}

.aispts-phone-text {
	position: absolute;
	left: 16px;
	right: 16px;
	bottom: 16px;
	color: #fff;
	text-align: left;
	pointer-events: none;
}

.aispts-tag {
	font-size: 13px;
	font-weight: 700;
	text-transform: uppercase;
	margin-bottom: 4px;
	color: #fff;
}

.aispts-tag-highlight {
	color: #7bdcb5;
}

.aispts-name {
	font-size: 16px;
	font-weight: 700;
	color: #fff;
}

.aispts-role {
	font-size: 12px;
	opacity: 0.85;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	color: rgba(255, 255, 255, 0.8);
}

.aispts-arrow {
	flex: 0 0 auto;
	width: 40px;
	height: 40px;
	border-radius: 50%;
	border: 1px solid #ddd;
	background: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	transition: background-color 0.2s ease, opacity 0.2s ease;
	color: #111;
}

.aispts-arrow:hover {
	background: #f2f2f2;
}

.aispts-arrow[disabled] {
	opacity: 0.35;
	cursor: not-allowed;
}

.aispts-arrow svg,
.aispts-arrow img {
	width: 16px;
	height: 16px;
}

.aispts-arrow svg {
	fill: #111;
}

@media (max-width: 1024px) {
	.aispts-wrapper {
		--aispts-visible: var(--aispts-visible-tablet, 2);
	}
}

@media (max-width: 767px) {
	.aispts-wrapper {
		--aispts-visible: var(--aispts-visible-mobile, 1);
	}
}

/* ---------------- Video popup ---------------- */

.aispts-popup-overlay {
	position: fixed;
	top: 0;
	left: 0;
	width: 100vw;
	height: 100vh;
	background: rgba(0, 0, 0, 0.85);
	display: flex;
	align-items: center;
	justify-content: center;
	z-index: 99999;
	opacity: 0;
	transition: opacity 0.25s ease;
	padding: 24px;
	box-sizing: border-box;
}

.aispts-popup-overlay.is-visible {
	opacity: 1;
}

.aispts-popup-inner {
	position: relative;
	height: min(90vh, calc(90vw * 16 / 9));
	width: min(90vw, calc(90vh * 9 / 16));
	max-width: 480px;
	max-height: 90vh;
	background: #000;
	border-radius: 12px;
	overflow: hidden;
	box-sizing: border-box;
}

@media (max-width: 600px) {
	.aispts-popup-overlay {
		padding: 12px;
	}

	.aispts-popup-inner {
		height: min(92vh, calc(94vw * 16 / 9));
		width: min(94vw, calc(92vh * 9 / 16));
		border-radius: 8px;
	}
}

.aispts-popup-media {
	width: 100%;
	height: 100%;
	border: 0;
	object-fit: cover;
	display: block;
}

.aispts-popup-close {
	position: absolute;
	top: 8px;
	right: 8px;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.9);
	border: none;
	font-size: 20px;
	line-height: 1;
	cursor: pointer;
	z-index: 2;
}

body.aispts-popup-open {
	overflow: hidden;
}
