/* Custom Banner (inc/custom-banner.php): black, optional background image, white H1. */
.custom-banner {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 280px;
	padding: 3em 0;
	overflow: hidden;
	background-color: #000;
}

.custom-banner__image {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center;
}

/* Darken the photo a little so the white title stays readable on any image. */
.custom-banner--has-image::after {
	content: "";
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.4);
}

.custom-banner__inner {
	position: relative;
	z-index: 1;
	text-align: center;
}

/* Same type as the theme's page H1 (Oswald 500, uppercase, white). */
.custom-banner__title {
	margin: 0;
	font-family: "Oswald", sans-serif;
	font-size: clamp(2.25rem, 6vw, 4em);
	font-weight: 500;
	line-height: 1.2;
	color: #fff;
	text-transform: uppercase;
}

/* Space between the banner and the page content, which the title block used to provide. */
.has-custom-banner .mainContentBody > .container {
	padding-top: 2.5em;
}

/* Phones: the mobile menu bar is fixed over the top ~95px of the page, so the banner
   runs up behind it (both are black) and the title starts below it. */
@media (max-width: 767px) {
	.custom-banner {
		--mobile-header-height: 95px;

		min-height: calc(180px + var(--mobile-header-height));
		padding: calc(2em + var(--mobile-header-height)) 0 2em;
	}
}
