/**
 * Customer stories + trust band.
 *
 * Loaded after theme.css and deliberately additive: every selector here is a
 * new .story-* / .trust-* name, so nothing in the base design system changes
 * shape when this file is present or absent. Colours come from the tokens only
 * — the Customizer's brand override must keep working here too.
 */

/* ══ Customer stories ══ */

.story-tabs {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 8px;
	margin: 0 0 32px;
}

.story-tab {
	appearance: none;
	font: inherit;
	font-size: 0.87rem;
	font-weight: 600;
	line-height: 1;
	color: var(--text-2);
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: var(--r-full);
	padding: 10px 18px;
	cursor: pointer;
	transition: color 0.18s var(--ease), border-color 0.18s var(--ease), background 0.18s var(--ease), box-shadow 0.18s var(--ease);
}

.story-tab:hover { color: var(--text); border-color: var(--text-3); }

.story-tab.is-on {
	color: var(--on-brand, #fff);
	background: var(--brand-grad);
	border-color: transparent;
	box-shadow: var(--shadow-sm);
}

.story-grid { align-items: stretch; }

.story-card {
	display: flex;
	flex-direction: column;
	margin: 0;
	padding: 26px;
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: var(--r-lg);
	box-shadow: var(--shadow-sm);
	transition: transform 0.22s var(--ease), box-shadow 0.22s var(--ease), border-color 0.22s var(--ease);
}

.story-card:hover {
	transform: translateY(-3px);
	border-color: color-mix(in srgb, var(--brand) 28%, var(--border));
	box-shadow: var(--shadow);
}

/* The filter sets the hidden attribute; without this the flex display wins. */
.story-card[hidden] { display: none; }

.story-metric {
	display: flex;
	flex-direction: column;
	gap: 2px;
	margin-bottom: 18px;
	padding-bottom: 18px;
	border-bottom: 1px solid var(--border-soft);
}

.story-metric__value {
	font-size: clamp(2.1rem, 5vw, 2.8rem);
	font-weight: 800;
	line-height: 1.05;
	letter-spacing: -0.02em;
	background: var(--brand-grad);
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
	/* Long values must wrap rather than widen the grid track. */
	overflow-wrap: anywhere;
}

.story-metric__label {
	font-size: 0.84rem;
	font-weight: 500;
	line-height: 1.4;
	color: var(--text-2);
}

.story-stars {
	color: #f59e0b;
	letter-spacing: 2px;
	font-size: 0.88rem;
	margin-bottom: 10px;
}

.story-quote {
	margin: 0 0 22px;
	font-size: 0.97rem;
	line-height: 1.7;
	color: var(--text-2);
}

/* A metric card leads with the number, so the quote is supporting evidence
   and reads one step quieter than a quote-only card. */
.story-card:not(.story-card--metric) .story-quote {
	font-size: 1.05rem;
	color: var(--text);
}

.story-by {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 12px;
	margin-top: auto;
}

.story-by__avatar {
	width: 42px;
	height: 42px;
	flex: none;
	border-radius: var(--r-full);
	object-fit: cover;
	background: var(--bg-mute);
}

.story-by__avatar--initial {
	display: grid;
	place-items: center;
	font-weight: 700;
	font-size: 1rem;
	color: var(--on-brand, #fff);
	background: var(--brand-grad);
}

.story-by__who {
	display: flex;
	flex-direction: column;
	min-width: 0;
}

.story-by__name { font-weight: 650; font-size: 0.93rem; color: var(--text); }
.story-by__role { font-size: 0.82rem; color: var(--text-3); }

.story-by__size {
	margin-left: auto;
	flex: none;
	font-size: 0.72rem;
	font-weight: 600;
	letter-spacing: 0.02em;
	color: var(--text-3);
	background: var(--bg-mute);
	border-radius: var(--r-full);
	padding: 4px 10px;
}

/* ══ Trust band ══ */

.trust-card {
	padding: 22px;
	background: var(--surface);
	border: 1px solid var(--border-soft);
	border-radius: var(--r-md);
	transition: border-color 0.2s var(--ease);
}

/* Calm on purpose: no lift, no gradient. This band is scanned for credibility,
   and anything that looks like marketing motion undercuts it. */
.trust-card:hover { border-color: var(--border); }

.trust-card__icon {
	display: inline-grid;
	place-items: center;
	width: 38px;
	height: 38px;
	margin-bottom: 14px;
	border-radius: var(--r);
	color: var(--brand);
	background: color-mix(in srgb, var(--brand) 10%, transparent);
}

.trust-card__icon svg { width: 20px; height: 20px; }

.trust-card__title {
	margin: 0;
	font-size: 1rem;
	font-weight: 650;
	line-height: 1.35;
	color: var(--text);
}

.trust-card__status {
	display: inline-block;
	margin-top: 8px;
	font-size: 0.72rem;
	font-weight: 600;
	color: var(--text-2);
	background: var(--bg-mute);
	border: 1px solid var(--border-soft);
	border-radius: var(--r-full);
	padding: 3px 9px;
}

.trust-card__note {
	margin: 10px 0 0;
	font-size: 0.88rem;
	line-height: 1.6;
	color: var(--text-2);
}

.trust-links {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 10px 26px;
	margin-top: 32px;
	padding-top: 24px;
	border-top: 1px solid var(--border-soft);
}

.trust-link {
	font-size: 0.88rem;
	font-weight: 550;
	color: var(--text-2);
	text-decoration: none;
	border-bottom: 1px solid transparent;
	transition: color 0.18s var(--ease), border-color 0.18s var(--ease);
}

.trust-link:hover {
	color: var(--brand);
	border-bottom-color: currentColor;
}

/* ══ Responsive ══ */

@media (max-width: 900px) {
	.story-card { padding: 22px; }
	.trust-card { padding: 20px; }
}

@media (max-width: 560px) {
	.story-tabs { margin-bottom: 24px; }

	.story-tab {
		padding: 9px 14px;
		font-size: 0.82rem;
	}

	.story-card { padding: 20px; }

	.story-by__size {
		margin-left: 0;
		/* Below the name once the row can no longer hold both. */
		order: 3;
	}
}

@media (prefers-reduced-motion: reduce) {
	.story-card,
	.story-tab,
	.trust-card,
	.trust-link { transition: none; }

	.story-card:hover { transform: none; }
}
