/* Brotega Hero — lettering BG, character cutout, headline + description */

.ortega-brotega-hero.is-text-entrance-pending .ortega-brotega-hero__headline,
.ortega-brotega-hero.is-text-entrance-pending .ortega-brotega-hero__description,
.ortega-brotega-hero.is-text-entrance-pending .ortega-brotega-hero__character {
	visibility: hidden;
}

.ortega-brotega-hero {
	--ortega-brh-blue: #0058a4;
	--ortega-brh-blue-deep: #004a8f;
	--ortega-brh-yellow: #ffe400;
	--ortega-brh-white: #fff;
	--ortega-brh-copy: #d7e4f5;
	--ortega-brh-pad-x: clamp(1.25rem, 4.5vw, 4rem);
	isolation: isolate;
	margin-inline: calc(50% - 50vw);
	max-width: 100vw;
	overflow: hidden;
	position: relative;
	width: 100vw;
}

.ortega-brotega-hero__backdrop {
	background-color: var(--ortega-brh-blue);
	inset: 0;
	position: absolute;
	z-index: 0;
}

.ortega-brotega-hero__lettering {
	inset: 0;
	overflow: hidden;
	pointer-events: none;
	position: absolute;
	z-index: 1;
}

.ortega-brotega-hero__lettering-img {
	display: block;
	height: 100%;
	object-fit: cover;
	object-position: center center;
	opacity: 0.95;
	width: 100%;
}

.ortega-brotega-hero__inner {
	align-items: center;
	box-sizing: border-box;
	display: grid;
	gap: clamp(1.5rem, 3vw, 2.5rem);
	grid-template-columns: minmax(0, 1fr);
	margin-inline: auto;
	max-width: 1880px;
	min-height: clamp(28rem, 72vw, 42rem);
	padding:
		clamp(6.5rem, 14vw, 8.5rem)
		var(--ortega-brh-pad-x)
		clamp(2.5rem, 6vw, 4rem);
	position: relative;
	width: 100%;
	z-index: 3;
}

.ortega-brotega-hero--has-character .ortega-brotega-hero__inner {
	/* Content left, character right on desktop; stacked on mobile. */
	grid-template-columns: minmax(0, 1fr);
}

.ortega-brotega-hero__content {
	display: flex;
	flex-direction: column;
	gap: clamp(1rem, 2.5vw, 1.5rem);
	max-width: 36rem;
	position: relative;
	z-index: 3;
}

.ortega-brotega-hero__headline {
	color: var(--ortega-brh-yellow);
	font-family: var(--ortega-font-display);
	font-size: var(--ortega-type-hero-lg--mobile);
	font-weight: 700;
	line-height: 0.9;
	margin: 0;
	text-transform: uppercase;
}

.ortega-brotega-hero__headline :is(p, h1, h2, h3) {
	color: inherit;
	font-size: inherit;
	line-height: inherit;
	margin: 0;
}

.ortega-brotega-hero__headline :is(p, h1, h2, h3) + :is(p, h1, h2, h3) {
	margin-top: 0.02em;
}

/* Smaller white lead-in / closing lines (wrapped in span). */
.ortega-brotega-hero__headline :is(span, .ortega-brotega-hero__headline-accent) {
	color: var(--ortega-brh-white);
	display: block;
	font-size: var(--ortega-type-hero-sm--mobile);
	line-height: 1;
	margin-bottom: 0.06em;
}

.ortega-brotega-hero__description {
	color: var(--ortega-brh-copy);
	font-family: var(--ortega-font-copy, var(--ortega-font-body));
	font-size: var(--ortega-type-body-lg, 1.125rem);
	font-weight: 400;
	line-height: 1.45;
	margin: 0;
	max-width: 28rem;
}

.ortega-brotega-hero__description p {
	margin: 0;
}

.ortega-brotega-hero__description p + p {
	margin-top: 0.75em;
}

.ortega-brotega-hero__figure {
	align-items: flex-end;
	display: flex;
	justify-content: center;
	margin: 0;
	position: relative;
	width: 100%;
	z-index: 2;
}

.ortega-brotega-hero__character {
	display: block;
	height: auto;
	max-height: clamp(280px, 78vw, 420px);
	max-width: 100%;
	object-fit: contain;
	object-position: bottom center;
	width: auto;
}

.ortega-brotega-hero-placeholder {
	background: #e8f1fb;
	border: 1px dashed var(--ortega-brh-blue, #0058a4);
	color: var(--ortega-brh-blue, #0058a4);
	font-family: var(--ortega-font-body);
	padding: 1.5rem;
	text-align: center;
}

/* Mobile: content first, character below in normal flow. */
@media (max-width: 781px) {
	.ortega-brotega-hero__inner {
		align-items: stretch;
		min-height: 0;
		padding-bottom: 0;
		padding-top: clamp(5.5rem, 18vw, 7rem);
	}

	.ortega-brotega-hero__content {
		max-width: 100%;
	}

	.ortega-brotega-hero__description {
		max-width: 22rem;
	}

	.ortega-brotega-hero__figure {
		justify-content: center;
		margin-inline: calc(-1 * var(--ortega-brh-pad-x));
		width: calc(100% + (2 * var(--ortega-brh-pad-x)));
	}

	.ortega-brotega-hero--has-character .ortega-brotega-hero__inner {
		/* Keep space between copy and character; no pad below figure. */
		gap: clamp(1.25rem, 4vw, 2rem);
	}

	.ortega-brotega-hero__character {
		max-height: clamp(300px, 85vw, 460px);
		width: min(100%, 420px);
	}

	.ortega-brotega-hero__lettering-img {
		object-position: 35% center;
	}
}

/* Desktop: content left, character right. */
@media (min-width: 782px) {
	.ortega-brotega-hero--has-character .ortega-brotega-hero__inner {
		align-items: end;
		gap: clamp(1rem, 2vw, 2rem);
		grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
		min-height: clamp(32rem, 56vw, 44rem);
		padding-bottom: 0;
		padding-top: clamp(7rem, 10vw, 9rem);
	}

	.ortega-brotega-hero:not(.ortega-brotega-hero--has-character) .ortega-brotega-hero__inner {
		min-height: clamp(32rem, 56vw, 44rem);
		padding-bottom: clamp(3rem, 5vw, 4.5rem);
		padding-top: clamp(7rem, 10vw, 9rem);
	}

	.ortega-brotega-hero__content {
		align-self: center;
		max-width: 34rem;
		padding-bottom: clamp(2.5rem, 4vw, 4rem);
	}

	.ortega-brotega-hero__headline {
		font-size: var(--ortega-type-hero-lg);
	}

	.ortega-brotega-hero__headline :is(span, .ortega-brotega-hero__headline-accent) {
		font-size: var(--ortega-type-hero-sm);
	}

	.ortega-brotega-hero__figure {
		align-self: end;
		justify-content: flex-end;
		/* Bleed slightly past the right edge like the design. */
		margin-right: calc(-1 * var(--ortega-brh-pad-x));
		max-width: none;
	}

	.ortega-brotega-hero__character {
		max-height: clamp(420px, 58vw, 780px);
		object-position: bottom right;
		width: min(100%, 780px);
	}
}

@media (min-width: 1100px) {
	.ortega-brotega-hero--has-character .ortega-brotega-hero__inner {
		grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.2fr);
	}

	.ortega-brotega-hero__character {
		max-height: min(780px, 72vh);
	}
}
