/*
 * AUK Global: page template additions.
 *
 * Loaded after auk.css. Holds only what the page templates need and auk.css does not provide.
 */

/* An eyebrow inside a .copy column is still an eyebrow. Without this, ".copy p" (which is more
   specific than ".auk-eyebrow") turns it into a body paragraph, as it did in the design file. */
.copy .auk-eyebrow {
	margin: 0 0 var(--space-2);
	font: 500 12px/18px var(--font-mono);
	letter-spacing: .04em;
}

/* Home hero form: the fields line up along their top edge, so an error message under one field
   does not push its neighbours out of line. The button drops by the height of a label row. */
.herogrid--4 {
	align-items: start;
}

.herogrid--4 > .auk-btn {
	margin-top: 24px;
}

/* Buttons inside a centred empty state follow its alignment. */
.auk-empty:not(.auk-empty--left) .auk-actions {
	justify-content: center;
}

@media (max-width: 1100px) {
	/* Three cards inside half a row are too narrow to read on a small laptop: stack them, as phones already do. */
	.grid2 .grid3--tight {
		grid-template-columns: 1fr;
	}

	/* The stacked cards make the text column very tall. The photo beside it keeps a landscape-friendly
	   height instead of stretching into a narrow portrait crop. */
	.grid2 > .auk-media {
		align-self: center;
		height: 440px;
	}
}

@media (max-width: 900px) {
	/* One column again: back to the min-height set in auk.css. */
	.grid2 > .auk-media {
		align-self: stretch;
		height: auto;
	}

	/* One column: the button sits under the fields and needs no label offset. */
	.herogrid--4 > .auk-btn {
		margin-top: 0;
	}

	/* Beside the testimonial the figures stack; once the testimonial sits above them they share a row. */
	.auk-statcol {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

@media (max-width: 640px) {
	.auk-statcol {
		grid-template-columns: 1fr;
	}
}
