/* ==========================================================================
   Page Hero Block
   ========================================================================== */

.pillar-page-hero {
	position: relative;
	display: flex;
	align-items: center;
	min-height: var(--pillar-page-hero-min-height, 55vh);
	overflow: hidden;
	color: var(--pillar-white, #fff);
}

.pillar-page-hero__media {
	position: absolute;
	inset: 0;
	z-index: 0;
}

.pillar-page-hero__image {
	width: 100%;
	height: 100%;
	background-size: cover;
	background-position: center;
	background-repeat: no-repeat;
}

.pillar-page-hero__overlay {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, var(--pillar-page-hero-overlay-opacity, 0.55));
}

.pillar-page-hero__content {
	position: relative;
	z-index: 1;
	width: 100%;
	padding: calc(var(--pillar-header-height, 72px) + 2.5rem) clamp(1.5rem, 4vw, 3.5rem) clamp(2.5rem, 6vh, 4rem);
}

.pillar-page-hero__inner {
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto;
	align-items: center;
	gap: clamp(2rem, 5vw, 4rem);
	max-width: 1320px;
	margin: 0 auto;
}

.pillar-page-hero__text {
	max-width: 780px;
}

.pillar-page-hero__breadcrumb {
	margin: 0 0 1.25rem;
	font-size: clamp(0.65rem, 1vw, 0.75rem);
	font-weight: 600;
	line-height: 1.4;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--pillar-yellow, #ffa800);
}

.pillar-page-hero__title {
	font-size: clamp(2rem, 4.4vw, 3.35rem);
	font-weight: 700;
	line-height: 1.22;
	letter-spacing: -0.01em;
}

.pillar-page-hero__title p {
	margin: 0;
}

.pillar-page-hero__title p + p {
	margin-top: 0.2em;
}

.pillar-page-hero__title strong {
	font-weight: 700;
}

.pillar-page-hero__description {
	margin: 0.85rem 0 0;
	max-width: 36em;
	font-size: clamp(1.05rem, 1.45vw, 1.3rem);
	font-weight: 400;
	line-height: 1.55;
	color: rgba(255, 255, 255, 0.92);
}

.pillar-page-hero__lines {
	display: flex;
	align-items: flex-end;
	justify-content: flex-end;
	gap: clamp(0.65rem, 1.5vw, 1.1rem);
	min-height: clamp(120px, 18vh, 200px);
	padding-right: clamp(0.5rem, 2vw, 1.5rem);
}

.pillar-page-hero__line {
	position: relative;
	display: block;
	width: 3px;
	height: clamp(120px, 18vh, 200px);
	border-radius: 2px;
	flex-shrink: 0;
	overflow: hidden;
	background: rgba(181, 181, 181, 0.55);
}

.pillar-page-hero__line-fill {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	height: 100%;
	border-radius: inherit;
	background: var(--pillar-yellow, #ffa800);
	transform: scaleY(0);
	transform-origin: bottom center;
	will-change: transform;
}

/* Sequential: each selected line fills bottom→top; next starts when previous finishes */
.pillar-page-hero.is-revealed .pillar-page-hero__line-fill {
	animation: pillar-page-hero-line-fill 1.95s cubic-bezier(0.22, 1, 0.36, 1) forwards;
	animation-delay: calc(var(--pillar-line-order, 0) * 1.95s);
}

@keyframes pillar-page-hero-line-fill {
	from {
		transform: scaleY(0);
	}
	to {
		transform: scaleY(1);
	}
}

@media (prefers-reduced-motion: reduce) {
	.pillar-page-hero__line-fill {
		transform: scaleY(1);
		animation: none !important;
	}
}

.editor-styles-wrapper .pillar-page-hero__line-fill {
	transform: scaleY(1);
	animation: none !important;
}

.pillar-page-hero--preview-empty {
	background: #1a1a1a;
}

.pillar-page-hero--preview-empty::after {
	content: "Set a Background image in the block fields →";
	position: absolute;
	bottom: 2rem;
	left: 50%;
	transform: translateX(-50%);
	font-size: 0.875rem;
	opacity: 0.5;
	z-index: 2;
}

.wp-block-acf-page-hero {
	margin: 0;
	max-width: none;
}

.editor-styles-wrapper .pillar-page-hero {
	min-height: 50vh;
}

@media (max-width: 768px) {
	.pillar-page-hero__inner {
		grid-template-columns: 1fr;
	}

	.pillar-page-hero__lines {
		justify-content: flex-start;
		min-height: auto;
		padding-right: 0;
	}

	.pillar-page-hero__line {
		height: clamp(80px, 14vh, 120px);
	}
}
