/* Sanford Systems SEO: Google reviews. Fonts come from the website's theme;
   colours from the placement's settings (custom properties on .ssrv). */
.ssrv {
	--ssrv-gap: 24px;
	--ssrv-cols: var(--ssrv-per);
	background: var(--ssrv-bg);
	color: var(--ssrv-text);
	padding: clamp(20px, 4vw, 48px) clamp(16px, 4vw, 40px);
	box-sizing: border-box;
}
/* Columns follow the space the section is given, not the screen: a
   reviews block in a narrow column gets fewer side by side. */
.ssrv-body { container-type: inline-size; }
.ssrv *, .ssrv *::before, .ssrv *::after { box-sizing: border-box; }
.ssrv p { margin: 0; }
.ssrv-sr { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

.ssrv-head {
	background: var(--ssrv-card);
	border-radius: 16px;
	padding: clamp(20px, 3vw, 32px) clamp(20px, 3vw, 40px);
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
	flex-wrap: wrap;
	margin-bottom: var(--ssrv-gap);
}
.ssrv .ssrv-title { color: var(--ssrv-text); font-size: clamp(1.6rem, 3vw, 2.2rem); line-height: 1.15; margin: 0 0 6px; }
.ssrv-score { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.ssrv-avg { font-size: clamp(2rem, 4vw, 2.6rem); font-weight: 700; line-height: 1; }
.ssrv-count { opacity: 0.7; font-size: 1.05rem; }

.ssrv-btn {
	display: inline-block;
	background: var(--ssrv-btn);
	color: var(--ssrv-btn-text) !important;
	text-decoration: none !important;
	border-radius: 999px;
	padding: 14px 30px;
	font-weight: 700;
	font-size: 1.05rem;
	letter-spacing: 0.02em;
	line-height: 1.2;
	text-align: center;
	transition: filter 0.15s ease;
}
.ssrv-btn:hover { filter: brightness(1.06); }
.ssrv-btn:focus-visible, .ssrv-more:focus-visible, .ssrv-nav:focus-visible, .ssrv-track:focus-visible { outline: 3px solid var(--ssrv-link); outline-offset: 3px; }

/* Stars: the filled row is clipped to the rating over an outline row. */
.ssrv-stars { position: relative; display: inline-block; width: max-content; flex: none; line-height: 0; white-space: nowrap; vertical-align: middle; }
.ssrv-stars svg { width: 24px; height: 24px; margin-right: 2px; }
.ssrv-stars--lg svg { width: 30px; height: 30px; }
.ssrv-stars-off svg { fill: currentColor; opacity: 0.25; }
.ssrv-stars-on { position: absolute; inset: 0 auto 0 0; overflow: hidden; }
.ssrv-stars-on svg { fill: var(--ssrv-star); }

.ssrv-body { position: relative; }
.ssrv-track { list-style: none; margin: 0; padding: 0; }
.ssrv--grid .ssrv-track { display: grid; gap: var(--ssrv-gap); --ssrv-cols: var(--ssrv-per); grid-template-columns: repeat(var(--ssrv-cols), minmax(0, 1fr)); }
.ssrv--carousel .ssrv-track {
	--ssrv-cols: var(--ssrv-per);
	display: flex;
	gap: var(--ssrv-gap);
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	scroll-behavior: smooth;
	scrollbar-width: none;
	overscroll-behavior-x: contain;
}
.ssrv--carousel .ssrv-track::-webkit-scrollbar { display: none; }
.ssrv--carousel .ssrv-card { flex: 0 0 calc((100% - (var(--ssrv-cols) - 1) * var(--ssrv-gap)) / var(--ssrv-cols)); scroll-snap-align: start; }
.ssrv-card[hidden] { display: none !important; }

.ssrv-card {
	background: var(--ssrv-card);
	border-radius: 16px;
	padding: clamp(20px, 3vw, 36px);
	display: flex;
	flex-direction: column;
	gap: 14px;
	margin: 0;
}
.ssrv-who { display: flex; align-items: center; gap: 16px; }
.ssrv-avatar { width: 56px; height: 56px; border-radius: 50%; flex: 0 0 56px; object-fit: cover; display: block; }
.ssrv-initial { display: flex; align-items: center; justify-content: center; color: #fff; font-size: 1.6rem; font-weight: 600; font-family: system-ui, sans-serif; }
.ssrv-name { font-weight: 700; font-size: 1.2rem; line-height: 1.25; }
.ssrv-date { opacity: 0.7; font-size: 0.95rem; }
.ssrv-text { line-height: 1.5; font-size: 1.05rem; overflow-wrap: anywhere; }
.ssrv-js .ssrv-text.ssrv-clamp { display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.ssrv-more {
	align-self: flex-start;
	background: none;
	border: 0;
	padding: 0;
	margin: -6px 0 0;
	color: var(--ssrv-link);
	font: inherit;
	font-size: 1.05rem;
	cursor: pointer;
	text-decoration: none;
}
.ssrv-more:hover { text-decoration: underline; }

.ssrv-nav {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	z-index: 2;
	width: 46px;
	height: 46px;
	border-radius: 50%;
	border: 0;
	padding: 0;
	cursor: pointer;
	background: rgba(128, 128, 128, 0.85);
	color: #111;
	display: flex;
	align-items: center;
	justify-content: center;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}
.ssrv-nav[hidden] { display: none; }
.ssrv-nav svg { width: 24px; height: 24px; }
.ssrv-nav:disabled { opacity: 0.35; cursor: default; }
.ssrv-prev { left: -23px; }
.ssrv-next { right: -23px; }

@container (max-width: 820px) {
	.ssrv .ssrv-body .ssrv-track { --ssrv-cols: min(var(--ssrv-per), 2); }
}
@container (max-width: 520px) {
	.ssrv .ssrv-body .ssrv-track { --ssrv-cols: 1; }
}
@media (max-width: 700px) {
	.ssrv { --ssrv-gap: 16px; }
	.ssrv-head { flex-direction: column; text-align: center; }
	.ssrv-score { justify-content: center; }
	.ssrv-btn { width: 100%; max-width: 340px; }
	.ssrv-stars--lg svg { width: 24px; height: 24px; }
	/* Arrows under the reviews on small screens, clear of the words. */
	.ssrv--carousel .ssrv-body { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; }
	.ssrv--carousel .ssrv-track { order: 1; flex: 1 1 100%; min-width: 0; }
	.ssrv-nav { position: static; transform: none; order: 2; }
}
@media (prefers-reduced-motion: reduce) {
	.ssrv--carousel .ssrv-track { scroll-behavior: auto; }
	.ssrv-btn { transition: none; }
}
