/* T1 Reviews. Colours and fonts follow the Elementor Site Kit (global colours / typography) when present. */
.t1r {
	--t1r-cols: 3;
	--t1r-gap: 24px;
	--t1r-radius: 16px;
	--t1r-text: var(--e-global-color-text, #1f2937);
	--t1r-heading: var(--e-global-color-primary, var(--t1r-text));
	--t1r-muted: var(--e-global-color-secondary, #6b7280);
	--t1r-star: var(--e-global-color-accent, #f5a524);
	--t1r-star-empty: color-mix(in srgb, var(--t1r-muted) 28%, transparent);
	--t1r-line: color-mix(in srgb, var(--t1r-muted) 22%, transparent);
	--t1r-surface: color-mix(in srgb, var(--t1r-heading) 5%, #fff);
	--t1r-card-bg: #fff;
	--t1r-link: var(--t1r-heading);
	--t1r-yandex: #fc3f1d;
	--t1r-2gis: #19aa1e;
	color: var(--t1r-text);
	font-family: var(--e-global-typography-text-font-family, inherit), sans-serif;
	font-size: 16px;
	line-height: 1.55;
}

.t1r *,
.t1r *::before,
.t1r *::after {
	box-sizing: border-box;
}

.t1r--auto {
	--t1r-cols: var(--t1r-cols-d, 3);
}

@media (max-width: 1024px) {
	.t1r--auto:not(.t1r--one) {
		--t1r-cols: 2;
	}
}

@media (max-width: 767px) {
	.t1r--auto {
		--t1r-cols: 1;
	}
}

/* Stars: a five-star strip filled to --t1r-fill. */
.t1r-stars {
	--t1r-star-size: 18px;
	display: inline-block;
	flex: none;
	width: calc(var(--t1r-star-size) * 5);
	height: var(--t1r-star-size);
	background: linear-gradient(90deg, var(--t1r-star) var(--t1r-fill, 100%), var(--t1r-star-empty) var(--t1r-fill, 100%));
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2.6l2.9 6 6.5.8-4.8 4.5 1.2 6.5L12 17.2l-5.8 3.2 1.2-6.5L2.6 9.4l6.5-.8z'/%3E%3C/svg%3E") left center / var(--t1r-star-size) var(--t1r-star-size) repeat-x;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2.6l2.9 6 6.5.8-4.8 4.5 1.2 6.5L12 17.2l-5.8 3.2 1.2-6.5L2.6 9.4l6.5-.8z'/%3E%3C/svg%3E") left center / var(--t1r-star-size) var(--t1r-star-size) repeat-x;
}

.t1r-stars--sm {
	--t1r-star-size: 14px;
}

.t1r-stars--lg {
	--t1r-star-size: 24px;
}

.t1r-dot {
	display: inline-block;
	flex: none;
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: currentColor;
}

.t1r-source--yandex .t1r-dot,
.t1r-card--yandex .t1r-dot {
	color: var(--t1r-yandex);
}

.t1r-source--2gis .t1r-dot,
.t1r-card--2gis .t1r-dot {
	color: var(--t1r-2gis);
}

/* Summary */
.t1r-summary {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 20px 32px;
	margin-bottom: var(--t1r-gap);
	padding: 24px 28px;
	border-radius: var(--t1r-radius);
	background: var(--t1r-surface);
}

.t1r-summary__total {
	display: flex;
	align-items: center;
	gap: 16px;
}

.t1r-summary__score {
	color: var(--t1r-heading);
	font-family: var(--e-global-typography-primary-font-family, inherit), sans-serif;
	font-size: 56px;
	font-weight: 800;
	line-height: 1;
	letter-spacing: -0.02em;
	font-variant-numeric: tabular-nums;
}

.t1r-summary__meta {
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.t1r-summary__caption {
	color: var(--t1r-muted);
	font-size: 14px;
}

.t1r-summary__sources {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
}

.t1r-source {
	display: flex;
	flex-direction: column;
	gap: 8px;
	min-width: 220px;
	padding: 14px 16px;
	border: 1px solid var(--t1r-line);
	border-radius: calc(var(--t1r-radius) - 4px);
	background: var(--t1r-card-bg);
}

.t1r .t1r-source__main {
	display: grid;
	grid-template-columns: 1fr auto;
	gap: 4px 12px;
	align-items: center;
	color: var(--t1r-text);
	text-decoration: none;
}

.t1r-source__name {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-weight: 600;
}

.t1r-source__rating {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	grid-row: span 2;
}

.t1r-source__rating b {
	color: var(--t1r-heading);
	font-size: 22px;
	font-weight: 700;
	font-variant-numeric: tabular-nums;
}

.t1r-source__count {
	color: var(--t1r-muted);
	font-size: 14px;
}

.t1r .t1r-source__add {
	align-self: flex-start;
	color: var(--t1r-link);
	font-size: 14px;
	font-weight: 500;
	text-decoration: underline;
	text-decoration-color: var(--t1r-star);
	text-underline-offset: 3px;
}

.t1r .t1r-source__main:hover .t1r-source__count,
.t1r .t1r-source__add:hover {
	color: var(--t1r-heading);
	text-decoration-thickness: 2px;
}

/* Cards */
.t1r-list {
	display: grid;
	grid-template-columns: repeat(var(--t1r-cols), minmax(0, 1fr));
	gap: var(--t1r-gap);
	align-items: start;
}

.t1r--slider .t1r-list {
	grid-template-columns: none;
	grid-auto-flow: column;
	grid-auto-columns: calc((100% - (var(--t1r-cols) - 1) * var(--t1r-gap)) / var(--t1r-cols));
	align-items: stretch;
	overflow-x: auto;
	overscroll-behavior-x: contain;
	scroll-snap-type: x mandatory;
	scrollbar-width: none;
}

.t1r--slider .t1r-list::-webkit-scrollbar {
	display: none;
}

.t1r--slider .t1r-card {
	scroll-snap-align: start;
}

.t1r-card {
	display: flex;
	flex-direction: column;
	gap: 14px;
	height: 100%;
	padding: 24px;
	border: 1px solid var(--t1r-line);
	border-radius: var(--t1r-radius);
	background: var(--t1r-card-bg);
}

.t1r-card__head {
	display: flex;
	align-items: center;
	gap: 12px;
	min-width: 0;
}

.t1r-card__avatar {
	position: relative;
	display: grid;
	flex: none;
	place-items: center;
	width: 44px;
	height: 44px;
	overflow: hidden;
	border-radius: 50%;
	background: var(--t1r-surface);
	color: var(--t1r-heading);
	font-size: 15px;
	font-weight: 600;
}

.t1r-card__avatar img {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.t1r-card__who {
	display: flex;
	flex-direction: column;
	min-width: 0;
}

.t1r-card__name {
	overflow: hidden;
	color: var(--t1r-heading);
	font-weight: 600;
	line-height: 1.3;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.t1r-card__date {
	color: var(--t1r-muted);
	font-size: 14px;
}

.t1r-card__rating {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
}

.t1r-card__source {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	color: var(--t1r-muted);
	font-size: 13px;
	font-weight: 500;
}

.t1r-card__text {
	display: -webkit-box;
	overflow: hidden;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: var(--t1r-lines, 6);
	overflow-wrap: anywhere;
}

.t1r-card.is-open .t1r-card__text {
	display: block;
	-webkit-line-clamp: unset;
}

.t1r .t1r-card__more {
	align-self: flex-start;
	margin: -6px 0 0;
	padding: 0;
	border: 0;
	background: none;
	color: var(--t1r-link);
	font: inherit;
	font-size: 15px;
	font-weight: 500;
	text-decoration: underline;
	text-decoration-color: var(--t1r-star);
	text-underline-offset: 3px;
	cursor: pointer;
}

.t1r .t1r-card__more:hover,
.t1r .t1r-card__more:focus {
	background: none;
	color: var(--t1r-heading);
}

.t1r-card__more[hidden] {
	display: none;
}

.t1r-card__answer {
	padding: 12px 14px;
	border-left: 3px solid var(--t1r-star);
	border-radius: 0 8px 8px 0;
	background: var(--t1r-surface);
	font-size: 14px;
}

.t1r-card__answer-title {
	display: block;
	margin-bottom: 2px;
	color: var(--t1r-heading);
	font-weight: 600;
}

.t1r .t1r-card__link {
	margin-top: auto;
	padding-top: 4px;
	color: var(--t1r-muted);
	font-size: 14px;
	text-decoration: none;
}

.t1r .t1r-card__link::after {
	content: " \2192";
}

.t1r .t1r-card__link:hover {
	color: var(--t1r-heading);
}

/* Slider navigation */
.t1r-nav {
	display: flex;
	justify-content: flex-end;
	gap: 8px;
	margin-top: 16px;
}

.t1r .t1r-nav__btn {
	display: grid;
	place-items: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 1px solid var(--t1r-line);
	border-radius: 50%;
	background: var(--t1r-card-bg);
	color: var(--t1r-heading);
	font-size: 18px;
	line-height: 1;
	cursor: pointer;
}

.t1r .t1r-nav__btn:hover:not(:disabled) {
	border-color: var(--t1r-star);
	background: var(--t1r-card-bg);
	color: var(--t1r-heading);
}

.t1r .t1r-nav__btn:disabled {
	opacity: 0.4;
	cursor: default;
}

.t1r a:focus-visible,
.t1r button:focus-visible,
.t1r-list:focus-visible {
	outline: 2px solid var(--t1r-star);
	outline-offset: 2px;
}

@media (max-width: 767px) {
	.t1r {
		--t1r-gap: 16px;
	}

	.t1r-summary {
		padding: 20px;
	}

	.t1r-summary__score {
		font-size: 44px;
	}

	.t1r-summary__sources,
	.t1r-source {
		width: 100%;
		min-width: 0;
	}

	.t1r-card {
		padding: 20px;
	}

	.t1r--slider .t1r-list {
		grid-auto-columns: 86%;
	}
}

/* Compact badge [t1_reviews_rating] */
.t1r-badge {
	--t1r-star: var(--e-global-color-accent, #f5a524);
	--t1r-star-empty: rgba(127, 127, 127, 0.3);
	display: inline-flex;
	align-items: center;
	gap: 8px;
	line-height: 1;
}

.t1r-badge__score {
	font-weight: 700;
	font-variant-numeric: tabular-nums;
}

.t1r-badge__count {
	opacity: 0.75;
	font-size: 0.875em;
}

.t1r-empty {
	padding: 12px 16px;
	border: 1px dashed #c3c4c7;
	color: #50575e;
	font-size: 14px;
}
