/*
 * The About page (page-templates/about.php, parts/about/body.php), in the Home B shell.
 * The product page's look: a white top with the breadcrumb, the condensed h1 and the
 * lead, then a light grey ground with each section as square white boxes under its
 * condensed title. Line icons over one soft yellow spot (parts/product-sheet/v1/icons.php),
 * yellow only as the spot and the Call fill, no shadows, no numbers, no small yellow
 * squares. Breakpoints 40rem, 48rem, 64rem. Every rule under body.hdc-about.
 */

@layer tokens {
	body.hdc-about {
		--ab-ground: #eef1f5;
		--ab-tint: #f5f7fa;
		--ab-line: #dfe3e8;
		/* 5.2:1 on the ground, 5.8:1 on white. */
		--ab-mute: #5b6571;
		--ab-spot: #ffdb5c;
		--ab-r: 2px;
		--ab-pad: 1.25rem;
		--ab-space: 3rem;
		--ab-mono: ui-monospace, "SFMono-Regular", "Cascadia Mono", consolas, menlo, monospace;
	}

	@media (min-width: 48rem) {
		body.hdc-about {
			--ab-pad: 2rem;
			--ab-space: 4rem;
		}
	}

	@media (min-width: 64rem) {
		body.hdc-about {
			--ab-pad: 2.5rem;
			--ab-space: 5rem;
		}
	}
}

@layer components {
	.hdc-about .hdc-ab-main {
		overflow-x: clip;
	}

	/* ---------------------------------------------------------------- Line icons */
	.hdc-about .hdc-v1-line {
		flex: none;
		width: 1.25em;
		height: 1.25em;
		overflow: visible;
		fill: none;
		stroke: currentColor;
		stroke-width: 2;
		stroke-linecap: round;
		stroke-linejoin: round;
	}

	.hdc-about .hdc-v1-line--spot {
		width: 2rem;
		height: 2rem;
		color: var(--ink);
		stroke-width: 1.5;
	}

	.hdc-about .hdc-v1-line__ink * {
		vector-effect: non-scaling-stroke;
	}

	.hdc-about .hdc-v1-line__spot {
		fill: var(--ab-spot);
		stroke: none;
	}

	/* ---------------------------------------------------------------- Top */
	.hdc-about .hdc-ab-top {
		padding-bottom: 2.5rem;
		background: var(--white);
	}

	.hdc-about .hdc-ab-crumbs__list {
		display: flex;
		flex-wrap: wrap;
		margin: 0;
		padding: 1rem 0 0;
		list-style: none;
		color: var(--steel);
		font-size: 0.875rem;
		--link: var(--steel);
		--link-hover: var(--ink);
		--link-line: none;
		--link-hover-line: underline;
	}

	.hdc-about .hdc-ab-crumbs__item + .hdc-ab-crumbs__item::before {
		content: "/";
		margin-inline: 0.5rem;
		color: var(--control);
	}

	.hdc-about .hdc-ab-crumbs__item [aria-current] {
		color: var(--ink);
		font-weight: 600;
	}

	.hdc-about .hdc-ab-h1 {
		max-width: 30ch;
		margin: 1.5rem 0 1.25rem;
		color: var(--ink);
		font-size: clamp(2.25rem, 1.6rem + 2.6vw, 3.75rem);
		font-stretch: 75%;
		font-weight: 800;
		line-height: 1;
		text-wrap: balance;
	}

	.hdc-about .hdc-ab-lead {
		display: grid;
		gap: 0.75rem;
		max-width: 46rem;
		color: var(--body);
		font-size: 1.125rem;
		line-height: 1.55;
	}

	.hdc-about .hdc-ab-lead p {
		margin: 0;
	}

	.hdc-about .hdc-ab-lead p + p {
		color: var(--ab-mute);
		font-size: 1rem;
	}

	/* ---------------------------------------------------------------- Ground and sections */
	.hdc-about .hdc-ab-ground {
		padding-bottom: var(--ab-space);
		background: var(--ab-ground);
	}

	.hdc-about .hdc-ab-sec {
		padding-top: var(--ab-space);
	}

	.hdc-about .hdc-ab-h2 {
		margin: 0 0 1.25rem;
		color: var(--ink);
		font-size: clamp(1.875rem, 1.45rem + 1.4vw, 2.625rem);
		font-stretch: 75%;
		font-weight: 800;
		line-height: 1.02;
		text-wrap: balance;
	}

	.hdc-about .hdc-ab-head {
		margin-bottom: 1.25rem;
	}

	.hdc-about .hdc-ab-head .hdc-ab-h2 {
		margin-bottom: 0.5rem;
	}

	.hdc-about .hdc-ab-head__text {
		max-width: 46rem;
		margin: 0;
		color: var(--ab-mute);
		font-size: 1rem;
		line-height: 1.5;
	}

	.hdc-about .hdc-ab-box {
		min-width: 0;
		margin: 0;
		padding: var(--ab-pad);
		border-radius: var(--ab-r);
		background: var(--white);
	}

	/* ---------------------------------------------------------------- The company on record */
	.hdc-about .hdc-ab-cards {
		display: grid;
		gap: 1rem;
		margin: 0;
		padding: 0;
		list-style: none;
	}

	.hdc-about .hdc-ab-card {
		display: flex;
		flex-direction: column;
		min-width: 0;
		padding: 1.5rem var(--ab-pad) var(--ab-pad);
		border-radius: var(--ab-r);
		background: var(--white);
	}

	.hdc-about .hdc-ab-card__top {
		display: flex;
		align-items: center;
		gap: 0.75rem;
		margin-bottom: 1rem;
	}

	.hdc-about .hdc-ab-card__label {
		margin: 0;
		color: var(--ab-mute);
		font-size: 0.75rem;
		font-weight: 650;
		letter-spacing: 0.12em;
		text-transform: uppercase;
	}

	.hdc-about .hdc-ab-card__title {
		margin: 0;
		color: var(--ink);
		font-size: 1.5rem;
		font-stretch: 75%;
		font-weight: 800;
		line-height: 1.1;
	}

	.hdc-about .hdc-ab-card__value {
		margin: 0.5rem 0 0;
		padding: 0.5rem 0.625rem;
		border-radius: var(--ab-r);
		background: var(--ab-tint);
		color: var(--ink);
		font-family: var(--ab-mono);
		font-size: 0.8125rem;
		line-height: 1.4;
		overflow-wrap: anywhere;
	}

	.hdc-about .hdc-ab-card__text {
		margin: 0.875rem 0 0;
		color: var(--body);
		font-size: 0.9375rem;
		line-height: 1.55;
	}

	/* The button sits at the foot of the card, so the cards in a row line up. */
	.hdc-about .hdc-ab-card__act,
	.hdc-about .hdc-ab-card__rates {
		margin-top: auto;
		padding-top: 1.25rem;
	}

	.hdc-about .hdc-ab-card__check {
		display: inline-flex;
		align-items: center;
		gap: 0.5rem;
		min-height: 2.75rem;
		padding: 0 1rem;
		border: 1px solid var(--ink);
		border-radius: var(--ab-r);
		font-size: 0.9375rem;
		font-weight: 700;
		transition: background-color 0.15s, color 0.15s;
		--link: var(--ink);
		--link-hover: var(--white);
		--link-line: none;
		--link-hover-line: none;
	}

	.hdc-about .hdc-ab-card__check:hover {
		background: var(--ink);
	}

	.hdc-about .hdc-ab-card__out {
		width: 1rem;
		height: 1rem;
	}

	/* The reviews card: Google and Trustpilot, the header's scores, each in its own box. */
	/* Side by side while each box has 9.5rem, else one under the other. */
	.hdc-about .hdc-ab-card__rates {
		display: grid;
		grid-template-columns: repeat(auto-fit, minmax(9.5rem, 1fr));
		gap: 0.5rem;
	}

	.hdc-about .hdc-ab-rate {
		display: grid;
		grid-template-areas: "logo logo" "num stars" "count count";
		grid-template-columns: auto minmax(0, 1fr);
		align-items: center;
		gap: 0.375rem 0.5rem;
		min-width: 0;
		padding: 0.75rem 0.875rem;
		border: 1px solid var(--ab-line);
		border-radius: var(--ab-r);
		background: var(--white);
		color: var(--ink);
		transition: border-color 0.15s;
		--link: var(--ink);
		--link-hover: var(--ink);
		--link-line: none;
		--link-hover-line: none;
	}

	.hdc-about .hdc-ab-rate:hover {
		border-color: var(--control);
	}

	.hdc-about .hdc-ab-rate__logo {
		display: inline-flex;
		grid-area: logo;
		align-items: center;
		gap: 0.375rem;
		min-height: 1.375rem;
		font-size: 0.9375rem;
		font-weight: 700;
	}

	.hdc-about .hdc-ab-rate__logo .hdc-rv-logo {
		width: 1.125rem;
		height: 1.125rem;
	}

	.hdc-about .hdc-ab-rate__logo .hdc-rv-logo--full {
		width: auto;
		height: 1.25rem;
	}

	.hdc-about .hdc-ab-rate__num {
		grid-area: num;
		font-size: 1.5rem;
		font-stretch: 75%;
		font-weight: 800;
		font-variant-numeric: tabular-nums;
		line-height: 1;
	}

	.hdc-about .hdc-ab-rate__stars {
		grid-area: stars;
		min-width: 0;
		font-size: 0.875rem;
	}

	.hdc-about .hdc-ab-rate__count {
		grid-area: count;
		color: var(--steel);
		font-size: 0.8125rem;
		font-weight: 600;
	}

	.hdc-about .hdc-ab-rate:hover .hdc-ab-rate__count {
		color: var(--ink);
		text-decoration: underline;
		text-underline-offset: 0.2em;
	}

	/* The stars filled to the score (hdc_home_b_rev_stars()), as on the product page. */
	.hdc-about .hdc-rv-stars {
		display: inline-flex;
		position: relative;
		line-height: 0;
	}

	.hdc-about .hdc-rv-stars__unlit,
	.hdc-about .hdc-rv-stars__lit {
		display: flex;
		gap: 0.125em;
	}

	.hdc-about .hdc-rv-stars__unlit {
		color: var(--fog);
	}

	.hdc-about .hdc-rv-stars__lit {
		position: absolute;
		inset: 0 auto 0 0;
		width: calc(var(--full) * 1.125em + var(--frac) * 1em);
		overflow: hidden;
		color: var(--accent);
	}

	.hdc-about .hdc-rv-stars__star {
		flex: none;
		width: 1em;
		height: 1em;
		fill: currentColor;
	}

	.hdc-about .hdc-rv-out {
		display: inline-block;
		width: 0.875em;
		height: 0.875em;
		margin-left: 0.25em;
		vertical-align: -0.1em;
	}

	/* ---------------------------------------------------------------- Who runs it */
	.hdc-about .hdc-ab-owner {
		display: grid;
		gap: 1.5rem;
	}

	.hdc-about .hdc-ab-owner__card {
		display: grid;
		grid-template-columns: auto minmax(0, 1fr);
		align-items: center;
		gap: 0.125rem 1rem;
	}

	.hdc-about .hdc-ab-owner__mark {
		display: inline-flex;
		grid-row: span 2;
		align-items: center;
		justify-content: center;
		width: 4.5rem;
		height: 4.5rem;
		border-radius: var(--ab-r);
		background: var(--ink);
		color: var(--white);
		font-size: 1.75rem;
		font-stretch: 75%;
		font-weight: 800;
		letter-spacing: 0.04em;
	}

	.hdc-about .hdc-ab-owner__name {
		align-self: end;
		margin: 0;
		color: var(--ink);
		font-size: 1.375rem;
		font-stretch: 75%;
		font-weight: 800;
		line-height: 1.1;
	}

	.hdc-about .hdc-ab-owner__role {
		align-self: start;
		margin: 0;
		color: var(--ab-mute);
		font-size: 0.9375rem;
	}

	.hdc-about .hdc-ab-owner__text {
		display: grid;
		gap: 0.875rem;
		max-width: 46rem;
		color: var(--body);
		font-size: 1rem;
		line-height: 1.6;
	}

	.hdc-about .hdc-ab-owner__text p {
		margin: 0;
	}

	/* ---------------------------------------------------------------- How we sell */
	.hdc-about .hdc-ab-steps {
		display: grid;
		gap: 1.5rem;
		margin: 0;
		padding: 0;
		list-style: none;
	}

	.hdc-about .hdc-ab-steps__item {
		display: grid;
		grid-template-columns: 2rem minmax(0, 1fr);
		align-content: start;
		gap: 0.25rem 0.875rem;
	}

	.hdc-about .hdc-ab-steps__icon {
		grid-row: span 2;
	}

	.hdc-about .hdc-ab-steps__title {
		margin: 0;
		color: var(--ink);
		font-size: 1.1875rem;
		font-stretch: 75%;
		font-weight: 750;
		line-height: 1.15;
	}

	.hdc-about .hdc-ab-steps__text {
		margin: 0;
		color: var(--ab-mute);
		font-size: 0.9375rem;
		line-height: 1.5;
	}

	.hdc-about .hdc-ab-act {
		display: grid;
		gap: 0.625rem;
		margin-top: 2rem;
		padding-top: 1.75rem;
		border-top: 1px solid var(--line);
	}

	/* Call: the yellow block, the number after the word. */
	.hdc-about .hdc-ab-call {
		justify-content: center;
		min-height: 3.25rem;
		padding: 0.5rem 1.5rem;
		background: var(--accent);
		color: var(--ink);
		font-size: 1.0625rem;
		font-weight: 750;
		font-variant-numeric: tabular-nums;
	}

	.hdc-about .hdc-ab-call:hover {
		background: var(--accent-strong);
	}

	.hdc-about .hdc-ab-call .hdc-icon {
		width: 1.25rem;
		height: 1.25rem;
	}

	.hdc-about .hdc-ab-btn .hdc-v1-line {
		width: 1.25rem;
		height: 1.25rem;
	}

	/* ---------------------------------------------------------------- Contact */
	.hdc-about .hdc-ab-contact {
		display: grid;
		gap: 1.25rem;
	}

	.hdc-about .hdc-ab-contact__item {
		display: grid;
		gap: 0.375rem;
		min-width: 0;
	}

	.hdc-about .hdc-ab-contact dt {
		display: flex;
		align-items: center;
		gap: 0.625rem;
		color: var(--ab-mute);
		font-size: 0.875rem;
		font-weight: 600;
	}

	.hdc-about .hdc-ab-contact dd {
		margin: 0;
		min-width: 0;
		color: var(--ink);
		font-size: 1rem;
		font-weight: 700;
		overflow-wrap: anywhere;
	}

	/* The email breaks only after its @ (a wbr in the markup). */
	.hdc-about .hdc-ab-contact__value {
		overflow-wrap: normal;
		--link: var(--ink);
		--link-hover: var(--ink);
		--link-line: none;
		--link-hover-line: underline;
		font-variant-numeric: tabular-nums;
	}

	.hdc-about .hdc-ab-contact dd.hdc-ab-contact__post {
		font-size: 1rem;
		font-weight: 600;
		line-height: 1.5;
	}

	/* Talk to us follows on the same ground, no seam. */
	.hdc-about .hdc-ab-ground + .hdc-b-talk {
		padding-top: 0;
	}

	/* ---------------------------------------------------------------- 40rem */
	@media (min-width: 40rem) {
		.hdc-about .hdc-ab-contact {
			grid-template-columns: repeat(2, minmax(0, 1fr));
			gap: 2rem;
		}

		.hdc-about .hdc-ab-contact dd {
			margin-left: 2.625rem;
			font-size: 1.125rem;
		}

		.hdc-about .hdc-ab-cards {
			grid-template-columns: repeat(2, minmax(0, 1fr));
		}

		.hdc-about .hdc-ab-act {
			grid-template-columns: repeat(2, max-content);
		}

		.hdc-about .hdc-ab-steps {
			grid-template-columns: repeat(2, minmax(0, 1fr));
			gap: 2rem 2.5rem;
		}
	}

	/* ---------------------------------------------------------------- 64rem */
	@media (min-width: 64rem) {
		.hdc-about .hdc-ab-top {
			padding-bottom: 3.5rem;
		}

		.hdc-about .hdc-ab-cards {
			grid-template-columns: repeat(3, minmax(0, 1fr));
			gap: 1.25rem;
		}

		.hdc-about .hdc-ab-card {
			padding: 2rem;
		}

		.hdc-about .hdc-ab-owner {
			grid-template-columns: 18rem minmax(0, 1fr);
			gap: 3rem;
			align-items: start;
		}

		.hdc-about .hdc-ab-owner__card {
			grid-template-columns: minmax(0, 1fr);
			gap: 0.375rem;
		}

		.hdc-about .hdc-ab-owner__mark {
			grid-row: auto;
			width: 7rem;
			height: 7rem;
			margin-bottom: 0.75rem;
			font-size: 2.75rem;
		}

		.hdc-about .hdc-ab-steps {
			grid-template-columns: repeat(5, minmax(0, 1fr));
			gap: 2rem;
		}

		.hdc-about .hdc-ab-steps__item {
			grid-template-columns: minmax(0, 1fr);
			gap: 0.5rem;
		}

		.hdc-about .hdc-ab-steps__icon {
			grid-row: auto;
			margin-bottom: 0.5rem;
		}

	}

	/* ---------------------------------------------------------------- 80rem */
	@media (min-width: 80rem) {
		.hdc-about .hdc-ab-contact {
			grid-template-columns: repeat(3, minmax(0, 1fr));
		}
	}

	@media (prefers-reduced-motion: reduce) {
		.hdc-about .hdc-ab-card__check,
		.hdc-about .hdc-ab-rate {
			transition: none;
		}
	}
}
