/**
 * Podwires Bridge — canonical testimonial card ("Wall of Love").
 *
 * ONE card spec for every surface. Sites theme it by setting the custom
 * properties on their wrapper (e.g. .tm-wall, .pt-wall, .pw-wall):
 *
 *   .tm-wall { --pwb-card-bg: var(--tm-card); --pwb-text: var(--tm-text); … }
 *
 * Defaults live as var() fallbacks (NOT declarations on the elements), so a
 * wrapper-level override always wins via inheritance. Canonical constants
 * (star gold #FCD116, 14px radius, sizes) are shared by design — override
 * only the palette hooks per site.
 *
 * Palette hooks: --pwb-card-bg --pwb-card-border --pwb-text --pwb-muted --pwb-faint
 */

.pwb-testimonials {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
	gap: 14px;
	align-items: start; /* natural card heights — short quotes don't stretch */
}

.pwb-testimonial {
	background: var(--pwb-card-bg, #ffffff);
	border: 1px solid var(--pwb-card-border, rgba(0, 0, 0, 0.08));
	border-radius: var(--pwb-card-radius, 14px);
	padding: var(--pwb-card-pad, 18px);
	display: flex;
	flex-direction: column;
	margin: 0;
}

.pwb-testimonial .pwb-stars {
	color: var(--pwb-star, #FCD116);
	font-size: 13px;
	letter-spacing: 2px;
	margin-bottom: 10px;
	line-height: 1;
}

.pwb-testimonial blockquote {
	font-size: var(--pwb-quote-size, 13.5px);
	color: var(--pwb-text, #1f2430);
	line-height: 1.6;
	margin: 0 0 16px;
	padding: 0;
	border: 0;
	flex: 1;
	font-style: normal;
	background: none;
}

.pwb-testimonial-author {
	display: flex;
	align-items: center;
	gap: 10px;
	border-top: 1px solid var(--pwb-card-border, rgba(0, 0, 0, 0.08));
	padding-top: 12px;
}

.pwb-testimonial-author img {
	width: var(--pwb-avatar, 40px);
	height: var(--pwb-avatar, 40px);
	border-radius: 50%;
	object-fit: cover;
	flex-shrink: 0;
}

.pwb-testimonial-author strong {
	display: block;
	font-size: var(--pwb-name-size, 13px);
	font-weight: 600;
	color: var(--pwb-text, #1f2430);
	line-height: 1.3;
}

.pwb-testimonial-author .pwb-meta {
	display: block;
	font-size: var(--pwb-meta-size, 11px);
	color: var(--pwb-faint, #9ca3af);
	line-height: 1.3;
}

.pwb-empty {
	text-align: center;
	color: var(--pwb-muted, #6b7280);
	font-size: 13px;
}

/* ── Layout variants — container-only; cards keep the same DNA ──────────── */
.pwb-wall { position: relative; }

/* grid (default) already handled by .pwb-testimonials base grid */

/* masonry — CSS columns pack cards by height (no orphan rows, no stretch).
   column-width auto-picks the column count from the CONTAINER width, so a wide
   section (podwires.com ~1100px) gets 3 and a narrow one (podtoolbox ~672px)
   gets 2 — without viewport media queries that can't see the container. */
.pwb-layout-masonry .pwb-testimonials {
	display: block;
	columns: 300px;
	column-gap: 14px;
}
.pwb-layout-masonry .pwb-testimonial {
	break-inside: avoid;
	margin: 0 0 14px;
	width: 100%;
}

/* single — one big rotating quote, centered */
.pwb-layout-single .pwb-testimonials {
	display: block;
	max-width: 640px;
	margin: 0 auto;
}
.pwb-layout-single .pwb-testimonial:not(:first-child) { display: none; }
.pwb-layout-single .pwb-testimonial { text-align: center; border: none; background: none; padding: 0; }
.pwb-layout-single .pwb-stars { justify-content: center; }
.pwb-layout-single blockquote { font-size: 18px; line-height: 1.6; }
.pwb-layout-single .pwb-testimonial-author { justify-content: center; border: none; }

/* carousel — horizontal scroll-snap row + nav buttons */
.pwb-layout-carousel .pwb-testimonials {
	display: flex;
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	gap: 14px;
	padding-bottom: 6px;
	scrollbar-width: none;
}
.pwb-layout-carousel .pwb-testimonials::-webkit-scrollbar { display: none; }
.pwb-layout-carousel .pwb-testimonial {
	scroll-snap-align: start;
	flex: 0 0 300px;
	max-width: 300px;
}
.pwb-nav {
	position: absolute; top: 40%; z-index: 2;
	width: 34px; height: 34px; border-radius: 50%;
	border: 1px solid var(--pwb-card-border, rgba(0,0,0,.08));
	background: var(--pwb-card-bg, #fff); color: var(--pwb-text, #1f2430);
	font-size: 18px; line-height: 1; cursor: pointer;
}
.pwb-nav.pwb-prev { left: -6px; }
.pwb-nav.pwb-next { right: -6px; }
.pwb-nav:hover { opacity: .85; }

/* strip — avatars + aggregate rating (compact social-proof header) */
.pwb-layout-strip { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; justify-content: center; }
.pwb-strip-avatars { display: flex; }
.pwb-strip-avatar {
	width: 34px; height: 34px; border-radius: 50%; object-fit: cover;
	margin-left: -8px; border: 2px solid var(--pwb-card-bg, #fff);
}
.pwb-strip-avatars .pwb-strip-avatar:first-child { margin-left: 0; }
.pwb-strip-meta { font-size: 14px; color: var(--pwb-text, #1f2430); }
.pwb-strip-meta .pwb-stars { color: var(--pwb-star, #FCD116); }
.pwb-strip-count { color: var(--pwb-muted, #6b7280); }
