/**
 * Senior HR Forum – page-load heading motion (Update 14).
 *
 * On every page load the page's main heading block (eyebrow, H1, intro line, buttons)
 * rises gently from below and fades in, once, with a short stagger. CSS only:
 * - it runs once per load (CSS animations do not repeat);
 * - if CSS animations are unsupported, everything is simply visible;
 * - visitors who ask for reduced motion get no movement at all.
 * Targets every hero/title band used across the templates, plus any future
 * "*-hero" or "*-title-band" section, so new page heroes get it too.
 */
@media (prefers-reduced-motion: no-preference) {
	@keyframes shf-rise-in {
		from { opacity: 0; transform: translate3d(0, 28px, 0); }
		to   { opacity: 1; transform: none; }
	}

	/* Eyebrow / kicker above the heading */
	:is(.shf-hero, .shf-about-hero, .shf-events-hero, .shf-title-band, .shf-page-hero, [class*="-hero "], [class$="-hero"])
		:is(.shf-accent-bar, .shf-kicker, .shf-eyebrow, .wp-block-post-terms),
	/* The page's H1 */
	:is(.shf-hero, .shf-about-hero, .shf-events-hero, .shf-title-band, .shf-page-hero, [class*="-hero "], [class$="-hero"]) h1,
	/* Intro line, date, description */
	:is(.shf-hero, .shf-about-hero, .shf-events-hero, .shf-title-band, .shf-page-hero, [class*="-hero "], [class$="-hero"])
		:is([class*="hero__sub"], [class*="hero__intro"], [class*="hero__lead"], .wp-block-post-date, .wp-block-term-description),
	/* Buttons and search under the intro */
	:is(.shf-hero, .shf-about-hero, .shf-events-hero, .shf-title-band, .shf-page-hero, [class*="-hero "], [class$="-hero"])
		:is([class*="hero__buttons"], .wp-block-search, .shf-event-chips) {
		animation: shf-rise-in 720ms cubic-bezier(0.22, 0.61, 0.36, 1) both;
	}

	:is(.shf-hero, .shf-about-hero, .shf-events-hero, .shf-title-band, .shf-page-hero, [class*="-hero "], [class$="-hero"]) h1 {
		animation-delay: 110ms;
	}
	:is(.shf-hero, .shf-about-hero, .shf-events-hero, .shf-title-band, .shf-page-hero, [class*="-hero "], [class$="-hero"])
		:is([class*="hero__sub"], [class*="hero__intro"], [class*="hero__lead"], .wp-block-post-date, .wp-block-term-description) {
		animation-delay: 230ms;
	}
	:is(.shf-hero, .shf-about-hero, .shf-events-hero, .shf-title-band, .shf-page-hero, [class*="-hero "], [class$="-hero"])
		:is([class*="hero__buttons"], .shf-event-chips) {
		animation-delay: 340ms;
	}
	:is(.shf-hero, .shf-about-hero, .shf-events-hero, .shf-title-band, .shf-page-hero, [class*="-hero "], [class$="-hero"]) .wp-block-search {
		animation-delay: 430ms;
	}
	/* Never animate inside the block editor canvas. */
	.editor-styles-wrapper :is(h1, p, div, ul) { animation: none !important; }
}
