/* ==========================================================================
   Testimonials Widget – Swiper Slider
   ========================================================================== */

/* Outer wrapper: flex row — [swiper] [prev] [next]
   Arrows sit outside the swiper so they don't overlap content.           */
.cew-testimonials-wrapper {
	position: relative;
	display: flex;
	flex-direction: row;
	align-items: center;
	gap: 12px;
	width: 100%;
	/* Room below for the pagination dots */
}

/* ── Swiper container ───────────────────────────────────────────────────── */
.cew-testimonials-swiper {
	flex: 1;
	min-width: 0;       /* prevents flex blowout */
	width: 100%;
	overflow: hidden;
	position: relative; /* pagination dots position relative to this */
}

.cew-testimonials-swiper .swiper-wrapper {
	align-items: stretch;
}

/* Center slides when there are 1 or 2 (they don't fill the full container) */
.cew-testimonials-swiper--centered .swiper-wrapper {
	justify-content: center;
}

.cew-testimonials-swiper .swiper-slide {
	width: 688px!important;
}

/* ── Navigation arrows ──────────────────────────────────────────────────── */
.cew-testimonials-prev,
.cew-testimonials-next {
	flex-shrink: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 42px;
	height: 42px;
	color: #fff;
	cursor: pointer;
	transition: background 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
	z-index: 10;
	padding: 0;
	line-height: 1;
	/* Keep arrows vertically centred with the slides, not the whole wrapper
	   (wrapper has extra bottom padding for the dots) */
	align-self: flex-start;
	    position: absolute;
    top: 50%;
    transform: translateY(-50%);
	background-color: transparent!important;
	border: 0px;
}

.cew-testimonials-prev svg,
.cew-testimonials-next svg {
	width: 18px;
	height: 18px;
	display: block;
}
.cew-testimonials-prev {
	left: -38px!important;
}
.cew-testimonials-next {
	right: -38px!important;
}

.cew-testimonials-prev.swiper-button-disabled,
.cew-testimonials-next.swiper-button-disabled {
	opacity: 0.3;
	pointer-events: none;
}

/* ── Pagination dots ────────────────────────────────────────────────────── */
.cew-testimonials-pagination {
	position: absolute !important;
	bottom: -36px !important; /* sits in the padding-bottom area of wrapper */
	left: 0 !important;
	width: 100% !important;
	display: flex;
	justify-content: center;
	gap: 6px;
	padding: 0;
	line-height: 1;
}

/* Override Swiper default bullet styles */
.cew-testimonials-pagination .swiper-pagination-bullet {
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.25);
	opacity: 1;
	transition: background 0.2s ease, transform 0.2s ease, width 0.2s ease;
	cursor: pointer;
	display: inline-block;
	margin: 0 !important;
}

.cew-testimonials-pagination .swiper-pagination-bullet-active {
	background: #e63946;
	width: 24px;
	border-radius: 4px;
	transform: none;
}

/* ── Card ───────────────────────────────────────────────────────────────── */
.cew-testimonial {
	--cew-card-min-height: 180px;
	background: #121212;
	border-radius: 10px;
	overflow: hidden;
	color: #fff;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
	height: 100%;
}

.cew-testimonial__inner {
	display: flex;
	flex-direction: row;
	min-height: var(--cew-card-min-height);
	height: 100%;
}

/* ── Media / photo ──────────────────────────────────────────────────────── */
.cew-testimonial__media {
	flex-shrink: 0;
	width: 256px;	
    height: 296px;
	background: #121212;
	overflow: hidden;
}

.cew-testimonial__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: top center;
	display: block;
}

/* ── Text content ───────────────────────────────────────────────────────── */
.cew-testimonial__content {
	flex: 1;
	padding: 32px;
	display: flex;
	flex-direction: column;
	justify-content: flex-start;
	position: relative;
}

/* decorative quote mark */
.cew-testimonial__content::after {
	content: '';
	position: absolute;
	bottom: 0;
	right: 48px;
	width: 130px;
	height: 120px;
	background-image: url('../../../../themes/buddyboss-theme-child/assets/images/quote.png');
	background-size: contain;
	background-repeat: no-repeat;
	background-position: bottom right;
	pointer-events: none;
	user-select: none;
}

/* ── Star rating ────────────────────────────────────────────────────────── */
.cew-testimonial__rating {
	display: flex;
	gap: 3px;
	margin-bottom: 0px;
}

.cew-testimonial__star {
	display: inline-block;
	width: 32px;
	height: 32px; /* 31:29 aspect ratio → 18 × 29/31 ≈ 17 */
	fill: rgba(255, 255, 255, 0.18);
	flex-shrink: 0;
}

.cew-testimonial__star--filled {
	fill: #F0163E;
}

/* ── Quote ──────────────────────────────────────────────────────────────── */
.cew-testimonial__quote {
	padding: 0;
	border: none;
	font-size: 16px;
	line-height: 28px;
	font-family: 'Config';
	color: #fff;
	font-style: normal;
	margin: 20px 0 0 0;
}

.cew-testimonial__quote p {
	font-size: 16px;
	line-height: 24px;
	font-family: 'Config';
	color: #fff;
}

.cew-testimonial__quote p:last-child {
	margin-bottom: 0;
}

/* ── Footer: name + title ───────────────────────────────────────────────── */
.cew-testimonial__footer {
	margin-top: auto;
	display: flex;
	flex-direction: column;
	gap: 0.1rem;
}

.cew-testimonial__name {
	font-family: 'Config';
	font-weight: 600;
	font-style: normal;
	font-size: 16px;
	color: #fff;
}

.cew-testimonial__title {
	font-family: 'Config';
	font-size: 14px;
	color: #BDBDBD;
}

.cew-testimonial__title::before {
	content: "— ";
}

/* ── Empty state ────────────────────────────────────────────────────────── */
.cew-testimonials__empty {
	margin: 0;
	padding: 1rem;
	color: #666;
}

/* ==========================================================================
   Responsive
   ========================================================================== */

/* At 1200px: multiple slides start from the left instead of centering */
@media (max-width: 1200px) {
	.cew-testimonials-swiper--centered.cew-testimonials-swiper--has-multiple .swiper-wrapper {
		justify-content: flex-start;
	}
}


/* Mobile: stack card vertically, image on top, smaller arrows */
@media (max-width: 767px) {
	.cew-testimonials-wrapper {
		gap: 6px;
	}
	.cew-testimonials-swiper .swiper-slide {
		width: 100%!important;
	}

	.cew-testimonials-prev,
	.cew-testimonials-next {
		width: 34px;
		height: 34px;
	}

	.cew-testimonials-prev svg,
	.cew-testimonials-next svg {
		width: 30px;
		height: 30px;
	}

	.cew-testimonial__inner {
		flex-direction: column;
		min-height: unset;
	}

	.cew-testimonial__media {
		width: 100%;
		height: 240px;
	}

	.cew-testimonial__media img {
		object-position: center center;
	}

	.cew-testimonial__content {
		padding: 1rem 1.25rem 1.25rem;
	}
	.cew-testimonial__star {
		width: 16px;
		height: 16px;
	}
	.cew-testimonial__quote p:last-child {
	margin-bottom: 20px;
}
}