/**
 * NT Projektai – "NT atsiliepimai – Titulinis" widget.
 * Base section styles: nt-home-section.css.
 */

.nt-home-testimonials {
	--ntt-cols: 4;
	--ntt-gap: 24px;
	--ntt-card-bg: #fff;
	--ntt-card-border: #e9e3d8;
	--ntt-card-radius: 20px;
	--ntt-star: #1f5d48;
	--ntt-soft: #e7ede4;
	background-color: #f7f4ee;
}

/* Header + photo. */
.nt-home-testimonials__top {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: var(--nth-columns-gap);
	align-items: end;
	margin-bottom: var(--nth-block-gap);
}

.nt-home-testimonials--has-image .nt-home-testimonials__top {
	grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
}

.nt-home-testimonials--image-left .nt-home-testimonials__top {
	grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
}

.nt-home-testimonials--image-left .nt-home-section__media {
	order: -1;
}

.nt-home-testimonials .nt-home-section__header {
	padding-bottom: 8px;
}

/* Cards. */
.nt-home-testimonials .nt-home-testimonials__grid {
	display: grid;
	grid-template-columns: repeat(var(--ntt-cols), minmax(0, 1fr));
	gap: var(--ntt-gap);
	margin: 0;
	padding: 0;
	list-style: none;
}

.nt-home-testimonials .nt-home-testimonials__card {
	position: relative;
	display: flex;
	flex-direction: column;
	min-width: 0;
	margin: 0;
	padding: 32px 28px 28px;
	border: 1px solid var(--ntt-card-border);
	border-radius: var(--ntt-card-radius);
	background-color: var(--ntt-card-bg);
	box-shadow: 0 1px 2px rgba(38, 41, 42, 0.04), 0 18px 40px -26px rgba(38, 41, 42, 0.18);
}

.nt-home-testimonials__mark {
	position: absolute;
	top: 22px;
	right: 22px;
	width: 40px;
	height: 40px;
	color: var(--ntt-soft);
	pointer-events: none;
}

.nt-home-testimonials__rating {
	display: flex;
	gap: 3px;
	margin-bottom: 18px;
	color: var(--ntt-star);
	line-height: 0;
}

.nt-home-testimonials__star {
	display: block;
	fill: currentColor;
}

.nt-home-testimonials__star.is-empty {
	opacity: 0.22;
}

.nt-home-testimonials .nt-home-testimonials__quote {
	flex: 1 0 auto;
	margin: 0;
	padding: 0;
	border: 0;
	background: none;
	quotes: none;
}

.nt-home-testimonials .nt-home-testimonials__quote::before,
.nt-home-testimonials .nt-home-testimonials__quote::after {
	content: none;
}

.nt-home-testimonials .nt-home-testimonials__text {
	position: relative;
	margin: 0;
	color: #3d4142;
	font-family: var(--nth-font-body);
	font-size: 16px;
	font-style: normal;
	line-height: 1.65;
	overflow-wrap: break-word;
}

.nt-home-testimonials__author {
	display: flex;
	align-items: center;
	gap: 12px;
	margin-top: 24px;
	padding-top: 20px;
	border-top: 1px solid var(--ntt-card-border);
}

.nt-home-testimonials .nt-home-testimonials__avatar {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	margin: 0;
	border-radius: 50%;
	background-color: var(--ntt-soft);
	color: var(--nth-accent);
	font-family: var(--nth-font-heading);
	font-size: 17px;
	font-weight: 600;
	line-height: 1;
	object-fit: cover;
}

.nt-home-testimonials__who {
	display: flex;
	flex-direction: column;
	min-width: 0;
}

.nt-home-testimonials .nt-home-testimonials__name {
	color: #26292a;
	font-family: var(--nth-font-heading);
	font-size: 16px;
	font-style: normal;
	font-weight: 600;
	line-height: 1.35;
}

.nt-home-testimonials .nt-home-testimonials__role {
	color: #7a7e7f;
	font-size: 14px;
	line-height: 1.4;
}

/* ------------------------------------------------------------------ */
/* Responsive                                                          */
/* ------------------------------------------------------------------ */

@media (max-width: 1024px) {
	.nt-home-testimonials {
		--ntt-cols: 2;
		--ntt-gap: 20px;
	}

	.nt-home-testimonials--has-image .nt-home-testimonials__top,
	.nt-home-testimonials--image-left .nt-home-testimonials__top {
		grid-template-columns: minmax(0, 1fr);
	}

	.nt-home-testimonials--image-left .nt-home-section__media {
		order: 0;
	}

	.nt-home-testimonials .nt-home-section__header {
		padding-bottom: 0;
	}
}

@media (max-width: 767px) {
	.nt-home-testimonials {
		--ntt-cols: 1;
		--ntt-gap: 16px;
	}

	.nt-home-testimonials .nt-home-testimonials__card {
		padding: 26px 22px 22px;
	}

	.nt-home-testimonials__mark {
		top: 18px;
		right: 18px;
		width: 34px;
		height: 34px;
	}
}
