/**
 * frost/post-banner — front end and editor. See inc/post-banner.php.
 *
 * Every value copies the hand-built Banner group on the top-nav pages (About,
 * Fellowships), measured from the rendered page, so a post banner and a page
 * banner sit side by side without a seam: the navy overlay and text shadow,
 * the height, Times at the max-72 size, a line height of 0.9, the x-large
 * tagline, and the content-width column on the site's root padding.
 *
 * Height: theme.json's "Banner" dimension preset. The page
 * banners pick the same preset as their Minimum height, so changing it there
 * moves every banner, page and post alike.
 *
 * Colour: --aa-banner-colour fills a banner with no photo, and --aa-banner-tint
 * lies over a photo. These defaults are navy; a chosen colour's class
 * (generated in inc/post-banner.php) swaps both. A gradient's class sets
 * --aa-banner-gradient instead, which does both jobs, and clears the tint.
 */

.wp-block-frost-post-banner {
	--aa-banner-colour: var(--wp--preset--color--primary, #0C2A4E);
	--aa-banner-tint: #1d314e78;
	--aa-banner-gradient: none;
	margin-block: 0;
	background-color: var(--aa-banner-colour);
	background-repeat: no-repeat;
	background-size: cover;
	text-shadow: 0 0 1em #000000cc;
}

.frost-post-banner__overlay {
	position: relative;
	padding-right: var(--wp--style--root--padding-right);
	padding-left: var(--wp--style--root--padding-left);
	background-color: var(--aa-banner-tint);
}

/* A gradient's tint over a photo: the gradient on a layer of its own at the
   tint's strength (0.47, the navy overlay's 0x78 and AA_POST_BANNER_TINT),
   since a gradient can't be mixed toward transparent the way a colour is.
   Empty, and so invisible, for colours. */
.frost-post-banner__overlay::before {
	content: "";
	position: absolute;
	inset: 0;
	background-image: var(--aa-banner-gradient);
	opacity: 0.47;
	pointer-events: none;
}

/* No photo: the colour or gradient alone, with no tint layer over it. */
.frost-post-banner--no-image {
	background-image: var(--aa-banner-gradient);
}

.frost-post-banner--no-image .frost-post-banner__overlay {
	background-color: transparent;
}

.frost-post-banner--no-image .frost-post-banner__overlay::before {
	content: none;
}

.frost-post-banner__inner {
	position: relative; /* above the gradient layer */
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: flex-start;
	gap: var(--wp--preset--spacing--small);
	max-width: var(--wp--style--global--content-size);
	min-height: var(--wp--preset--dimension--banner, 650px);
	margin-inline: auto;
	padding-block: var(--wp--preset--spacing--large);
	color: var(--wp--preset--color--base, #FFFFFF);
	font-family: var(--wp--preset--font-family--tex-gyre-termes, "Times New Roman", Times, serif);

	a {
		color: inherit;
	}
}

.wp-block-frost-post-banner .frost-post-banner__inner .wp-block-post-title {
	margin: var(--wp--preset--spacing--small) 0 0;
	padding: 0;
	color: inherit;
	font-family: inherit;
	font-size: var(--wp--preset--font-size--max-72);
	font-style: normal;
	font-weight: 400;
	line-height: 0.9;
	letter-spacing: normal;
	text-align: left;
}

.frost-post-banner__tagline {
	margin: 0;
	font-size: var(--wp--preset--font-size--x-large);
}
