/*! ManPack testimonial slider 1.5.2 (Figma: Section=Testimonials) */
.mpt {
	--mpt-w: 520px;
	--mpt-lines: 4;
	--mpt-gap: 24px;
	--mpt-fade: 140px;
	--mpt-card: #F7F7FD;
	--mpt-text: #2B2640;
	--mpt-name: #10082C;
	--mpt-role: #6E6A85;
	--mpt-star: #FDB022;
	--mpt-accent: #0A4DFA;
	--mpt-ease: cubic-bezier(.19, 1, .22, 1);
	position: relative;
	width: 100%;
	font-family: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
	-webkit-user-select: none;
	user-select: none;
}
.mpt *, .mpt *::before, .mpt *::after { box-sizing: border-box; }

/* row with soft edges, as in Figma (white gradients over both ends) */
.mpt-viewport {
	overflow: hidden;
	padding: 12px 0 28px;
	margin: -12px 0 8px; /* room below for the card hover lift + Figma's gap to the buttons */
	cursor: grab;
	touch-action: pan-y;
	-webkit-mask-image: linear-gradient(90deg, transparent, #000 var(--mpt-fade), #000 calc(100% - var(--mpt-fade)), transparent);
	mask-image: linear-gradient(90deg, transparent, #000 var(--mpt-fade), #000 calc(100% - var(--mpt-fade)), transparent);
}
.mpt.is-drag .mpt-viewport { cursor: grabbing; }
.mpt-track {
	display: flex;
	align-items: stretch; /* every card in the row is the same height */
	gap: var(--mpt-gap);
	width: max-content;
	will-change: transform;
}
.mpt:not(.is-ready) .mpt-track { padding-left: var(--mpt-fade); } /* before JS: start clear of the fade */

/* ---------- card ---------- */
.mpt-card {
	display: flex;
	flex-direction: column;
	gap: 18px;
	flex: 0 0 auto;
	width: min(var(--mpt-w), calc(100vw - 48px));
	padding: 32px;
	border-radius: 24px;
	background: var(--mpt-card);
	border: 1px solid rgba(16, 8, 44, .05);
	box-shadow: 0 1px 0 rgba(255, 255, 255, .9) inset;
	transition: transform .5s var(--mpt-ease), box-shadow .5s var(--mpt-ease), border-color .5s var(--mpt-ease);
}
@media (hover: hover) {
	.mpt:not(.is-drag) .mpt-card:hover {
		transform: translate3d(0, -4px, 0);
		border-color: rgba(10, 77, 250, .14);
		box-shadow: 0 24px 48px -28px rgba(16, 8, 44, .28);
	}
}

.mpt-rating { display: flex; align-items: center; gap: 12px; line-height: 1; }
.mpt-stars { position: relative; display: inline-block; height: 20px; line-height: 0; }
.mpt-stars svg { width: 20px; height: 20px; margin-right: 4px; fill: currentColor; }
.mpt-stars-bg { color: rgba(16, 8, 44, .12); white-space: nowrap; }
.mpt-stars-fg { position: absolute; inset: 0 auto 0 0; overflow: hidden; white-space: nowrap; color: var(--mpt-star); }
.mpt-score { font-size: 16px; font-weight: 600; color: var(--mpt-name); }

.mpt-body { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }
.mpt-text {
	font-size: 16px;
	line-height: 1.5;
	font-weight: 400;
	color: var(--mpt-text);
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: var(--mpt-lines);
	line-clamp: var(--mpt-lines);
	overflow: hidden;
	/* fixed block: every card shows the same number of lines */
	min-height: calc(var(--mpt-lines) * 1.5em);
}
/* in the card, paragraphs run on so the line clamp is exact in every browser;
   the pop-up shows them as separate paragraphs */
.mpt-text p { margin: 0; display: inline; }
.mpt-text p + p::before { content: " "; }
.mpt-text strong, .mpt-text b { font-weight: 600; color: var(--mpt-name); }

.mpt-more {
	all: unset;
	position: relative;
	display: inline-block;
	cursor: pointer;
}
.mpt-more[hidden] { display: inline-block; visibility: hidden; } /* keep its line so cards stay aligned */
.mpt-more::after { content: ""; position: absolute; inset: -10px -8px; } /* bigger tap area, same look */
.mpt-more:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; border-radius: 2px; }

.mpt-author { display: flex; align-items: center; gap: 14px; margin-top: auto; padding-top: 6px; }
.mpt-avatar {
	flex: 0 0 48px;
	width: 48px;
	height: 48px;
	border-radius: 50%;
	background: #fff;
	box-shadow: 0 6px 16px -8px rgba(16, 8, 44, .25), 0 0 0 1px rgba(16, 8, 44, .05);
	display: grid;
	place-items: center;
	overflow: hidden;
}
.mpt-avatar img { width: 80% !important; height: 80% !important; object-fit: contain; border-radius: 0 !important; -webkit-user-drag: none; }
.mpt-who { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.mpt-name { font-size: 16px; line-height: 1.35; font-weight: 600; color: var(--mpt-name); }
.mpt-role { font-size: 13px; line-height: 1.4; color: var(--mpt-role); }

/* ---------- arrows (on the faded edges; touch screens swipe instead) ---------- */
.mpt-nav { position: absolute; inset: 50% 0 auto; display: flex; justify-content: space-between; padding: 0 clamp(8px, 2vw, 32px); pointer-events: none; transform: translateY(-50%); }
.mpt-arrow {
	all: unset;
	box-sizing: border-box;
	pointer-events: auto;
	width: 48px;
	height: 48px;
	border-radius: 50%;
	display: grid;
	place-items: center;
	cursor: pointer;
	color: var(--mpt-name);
	background: rgba(255, 255, 255, .92);
	box-shadow: 0 10px 28px -12px rgba(16, 8, 44, .35), 0 0 0 1px rgba(16, 8, 44, .06);
	-webkit-backdrop-filter: blur(8px);
	backdrop-filter: blur(8px);
	transition: background-color .3s, color .3s, transform .4s var(--mpt-ease), opacity .4s;
}
.mpt-arrow svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.mpt-arrow:hover { background: var(--mpt-accent); color: #fff; }
.mpt-arrow:active { transform: scale(.94); }
.mpt-arrow:focus-visible { outline: 2px solid var(--mpt-accent); outline-offset: 3px; }
@media (hover: hover) {
	.mpt-nav .mpt-arrow { opacity: 0; transform: scale(.9); }
	.mpt:hover .mpt-nav .mpt-arrow, .mpt-nav .mpt-arrow:focus-visible { opacity: 1; transform: none; }
}
@media (hover: none), (max-width: 767px) { .mpt-nav { display: none; } }

/* ---------- pop-up ---------- */
.mpt-dialog {
	width: min(680px, calc(100vw - 32px));
	max-height: min(86vh, 760px);
	padding: 0;
	border: 0;
	border-radius: 28px;
	background: transparent;
	overflow: visible;
	color: var(--mpt-text);
	-webkit-user-select: text;
	user-select: text;
}
.mpt-dialog::backdrop { background: rgba(11, 6, 32, .55); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.mpt-dlg-card {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: 22px;
	max-height: min(86vh, 760px);
	padding: 44px 44px 28px;
	border-radius: 28px;
	background:
		radial-gradient(120% 60% at 100% 0%, rgba(10, 77, 250, .07), transparent 60%),
		#fff;
	box-shadow: 0 40px 100px -30px rgba(11, 6, 32, .55);
	overflow: hidden;
}
.mpt-dlg-body { display: flex; flex-direction: column; gap: 22px; overflow-y: auto; overscroll-behavior: contain; padding: 0 4px 10px 0; }
.mpt-dlg-body .mpt-rating { padding-right: 48px; }
.mpt-dlg-body .mpt-text { display: block; -webkit-line-clamp: unset; line-clamp: none; overflow: visible; min-height: 0; font-size: 18px; line-height: 1.6; }
.mpt-dlg-body .mpt-text p { display: block; margin: 0 0 .8em; }
.mpt-dlg-body .mpt-text p:last-child { margin-bottom: 0; }
.mpt-dlg-body .mpt-text p + p::before { display: none; }
.mpt-dlg-body .mpt-author { margin-top: 4px; padding-top: 20px; border-top: 1px solid rgba(16, 8, 44, .08); }
.mpt-dlg-body::before { /* big quote mark */
	content: "\201C";
	position: absolute;
	top: 6px;
	right: 84px;
	font: 700 120px/1 Georgia, serif;
	color: rgba(10, 77, 250, .08);
	pointer-events: none;
}
.mpt-close {
	all: unset;
	position: absolute;
	z-index: 2;
	top: 18px;
	right: 18px;
	width: 40px;
	height: 40px;
	border-radius: 50%;
	display: grid;
	place-items: center;
	cursor: pointer;
	color: var(--mpt-name);
	background: rgba(16, 8, 44, .05);
	transition: background-color .3s, transform .4s var(--mpt-ease);
}
.mpt-close svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.mpt-close:hover { background: rgba(16, 8, 44, .1); transform: rotate(90deg); }
.mpt-close:focus-visible { outline: 2px solid var(--mpt-accent); outline-offset: 2px; }
.mpt-dlg-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.mpt-count { font: 500 13px/1 "Inter", system-ui, sans-serif; letter-spacing: .04em; color: var(--mpt-role); }
.mpt-dlg-nav { display: flex; gap: 10px; }
.mpt-dlg-nav .mpt-arrow { width: 44px; height: 44px; background: #F3F4FB; box-shadow: none; }
.mpt-dlg-nav .mpt-arrow:hover { background: var(--mpt-accent); color: #fff; }

@media (prefers-reduced-motion: no-preference) {
	.mpt-dialog[open] .mpt-dlg-card { animation: mpt-pop .55s var(--mpt-ease) both; }
	.mpt-dialog[open]::backdrop { animation: mpt-fade .35s ease both; }
	.mpt-dialog.is-closing .mpt-dlg-card { animation: mpt-pop-out .22s ease-in both; }
	.mpt-dialog.is-closing::backdrop { animation: mpt-fade .22s ease-in reverse both; }
	.mpt-dlg-body.is-swap { animation: mpt-swap .45s var(--mpt-ease) both; }
}
@keyframes mpt-pop { from { opacity: 0; transform: translate3d(0, 24px, 0) scale(.96); } to { opacity: 1; transform: none; } }
@keyframes mpt-pop-out { to { opacity: 0; transform: translate3d(0, 12px, 0) scale(.98); } }
@keyframes mpt-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes mpt-swap { from { opacity: 0; transform: translate3d(var(--mpt-dir, 16px), 0, 0); } to { opacity: 1; transform: none; } }
html.mpt-lock { overflow: hidden; }

/* ---------- tablet / phone ---------- */
@media (max-width: 1279px) {
	.mpt { --mpt-fade: 64px; --mpt-gap: 20px; }
	.mpt-card { padding: 28px; }
}
@media (max-width: 767px) {
	.mpt { --mpt-fade: 16px; --mpt-gap: 14px; }
	.mpt-card { padding: 24px 22px; gap: 16px; border-radius: 20px; }
	.mpt-text { font-size: 15px; }
	.mpt-stars svg { width: 18px; height: 18px; }
	.mpt-avatar { flex-basis: 44px; width: 44px; height: 44px; }
	.mpt-name { font-size: 15px; }
	.mpt-role { font-size: 12.5px; }
	.mpt-dialog { width: 100vw; max-width: 100vw; max-height: 92vh; margin: auto 0 0; border-radius: 24px 24px 0 0; }
	.mpt-dlg-card { max-height: 92vh; padding: 36px 22px 20px; border-radius: 24px 24px 0 0; }
	.mpt-dlg-body .mpt-text { font-size: 16px; }
	.mpt-dlg-body::before { right: 64px; font-size: 96px; }
	.mpt-close { top: 14px; right: 14px; }
}
@media (max-width: 767px) and (prefers-reduced-motion: no-preference) {
	.mpt-dialog[open] .mpt-dlg-card { animation-name: mpt-sheet; }
	@keyframes mpt-sheet { from { transform: translate3d(0, 100%, 0); } to { transform: none; } }
}

/* ---------- theme guard: the theme styles every <button> (blue fill, white
   text, padding, uppercase); these buttons keep the Figma look ---------- */
.mpt button.mpt-more, .mpt button.mpt-arrow, .mpt button.mpt-close {
	min-width: 0 !important;
	min-height: 0 !important;
	margin: 0 !important;
	border: 0 !important;
	text-transform: none !important;
	letter-spacing: 0 !important;
	text-shadow: none !important;
	line-height: 1 !important;
}
.mpt button.mpt-more {
	height: auto !important;
	padding: 0 !important;
	background: none !important;
	box-shadow: none !important;
	color: var(--mpt-text) !important;
	font: 500 14px/1.4 "Inter", system-ui, sans-serif !important;
	text-decoration: underline !important;
	text-decoration-thickness: 1px !important;
	text-underline-offset: 3px !important;
	transition: text-underline-offset .25s ease, opacity .25s ease !important;
}
.mpt button.mpt-more:hover, .mpt button.mpt-more:focus, .mpt button.mpt-more:active { background: none !important; color: var(--mpt-text) !important; text-underline-offset: 5px !important; }
.mpt button.mpt-arrow { padding: 0 !important; color: var(--mpt-name) !important; background: rgba(255, 255, 255, .92) !important; box-shadow: 0 10px 28px -12px rgba(16, 8, 44, .35), 0 0 0 1px rgba(16, 8, 44, .06) !important; }
.mpt .mpt-dlg-nav button.mpt-arrow { background: #F3F4FB !important; box-shadow: none !important; }
.mpt button.mpt-arrow:hover, .mpt .mpt-dlg-nav button.mpt-arrow:hover { background: var(--mpt-accent) !important; color: #fff !important; }
.mpt button.mpt-close { padding: 0 !important; color: var(--mpt-name) !important; background: rgba(16, 8, 44, .05) !important; box-shadow: none !important; }
.mpt button.mpt-close:hover { background: rgba(16, 8, 44, .1) !important; color: var(--mpt-name) !important; }
.mpt button.mpt-arrow svg, .mpt button.mpt-close svg { stroke: currentColor !important; fill: none !important; }
