/* ============================================
 * acf/hero — block-scoped styles
 *
 * Enqueued via block.json "style": "file:./hero.css".
 * Loaded only on pages where the block is used.
 *
 * Naming: BEM with `.blk-hero` root, `__element` for children,
 * `--modifier` for variants. Tokens come from :root in global.css.
 * ============================================ */

.blk-hero {
	padding: 32px 0 80px;
	text-align: center;
	position: relative;
}

/* Dotted radial backdrop that sits *outside* the white card. Mirrors
 * `.hero::before` from the static mockup (assets/styles.css). Extends 120px
 * above the section so the dots fade in behind the sticky nav. */
.blk-hero::before {
	content: "";
	position: absolute;
	top: -120px;
	left: 0;
	right: 0;
	bottom: 0;
	background-image:
		radial-gradient(ellipse 80% 70% at 50% 10%, rgba(255, 255, 255, 0.06), transparent 70%),
		radial-gradient(rgba(255, 255, 255, 0.18) 1px, transparent 1.2px);
	background-size: 100% 100%, 24px 24px;
	background-position: 0 0, 0 0;
	-webkit-mask-image: linear-gradient(to bottom, #000 0%, rgba(0, 0, 0, 0.65) 50%, transparent 100%);
	        mask-image: linear-gradient(to bottom, #000 0%, rgba(0, 0, 0, 0.65) 50%, transparent 100%);
	pointer-events: none;
	z-index: 0;
}
.blk-hero > .container { position: relative; z-index: 1; }
.blk-hero h1 {
	margin-bottom: 22px;
	max-width: 1080px;
	margin-left: auto;
	margin-right: auto;
}
.blk-hero__sub {
	font-size: clamp(16px, 1.6vw, 19px);
	color: var(--color-fg-muted);
	max-width: 640px;
	margin: 0 auto 36px;
	line-height: var(--leading-relaxed);
}
.blk-hero__cta {
	display: flex;
	gap: 28px;
	justify-content: center;
	align-items: center;
	flex-wrap: wrap;
	margin-bottom: 80px;
}
.blk-hero__cta .btn {
	padding: 13px 22px;
	font-size: var(--wp--preset--font-size--sm);
}
.blk-hero__mail {
	font-size: 15px;
	font-weight: var(--weight-medium);
	color: var(--color-fg);
	text-decoration: none;
	transition: opacity var(--duration-fast) var(--ease);
}
.blk-hero__mail:hover { opacity: 0.7; }
.blk-hero__box .blk-hero__mail { color: var(--color-fg-inverse); }

/* ---- Boxed (light) hero card ---- */
.blk-hero__box {
	position: relative;
	overflow: hidden;
	background: var(--color-bg-light);
	color: var(--color-fg-inverse);
	border-radius: var(--radius-lg);
	padding: 100px 40px 0;
	isolation: isolate;
	/* Bleed past the container's 24px gutter so the card meets the page edge. */
	margin-left: -24px;
	margin-right: -24px;
}
@media (max-width: 600px) {
	.blk-hero__box { margin-left: -12px; margin-right: -12px; }
}
.blk-hero__box::before {
	content: "";
	position: absolute;
	inset: 0;
	background-image: radial-gradient(var(--color-fg-inverse-faint) 1.2px, transparent 1.6px);
	background-size: 18px 18px;
	background-position: 0 0;
	-webkit-mask-image: linear-gradient(to top, transparent 0%, rgba(0,0,0,0.25) 30%, rgba(0,0,0,0.7) 65%, #000 100%);
	        mask-image: linear-gradient(to top, transparent 0%, rgba(0,0,0,0.25) 30%, rgba(0,0,0,0.7) 65%, #000 100%);
	pointer-events: none;
	z-index: 0;
}
.blk-hero__box > * { position: relative; z-index: 1; }
.blk-hero__box h1 { color: var(--color-fg-inverse); }
.blk-hero__box .blk-hero__sub { color: var(--color-fg-inverse-muted); }
.blk-hero__box .btn-primary {
	background: var(--color-btn-dark);
	color: var(--color-fg-white);
}
.blk-hero__box .btn-primary:hover {
	background: var(--color-btn-dark-hover);
	transform: translateY(-1px);
}
.blk-hero__box .btn-ghost {
	background: transparent;
	color: var(--color-fg-inverse);
	border-color: var(--color-border-inverse-strong);
}
.blk-hero__box .btn-ghost:hover {
	background: var(--color-overlay-inverse-3);
	border-color: var(--color-fg-inverse-dim);
}
.blk-hero__box .blk-hero__ticker-wrap {
	margin: 0 -40px;
	width: auto;
	border-top: 1px solid var(--color-border-inverse);
	padding: 22px 0;
}
.blk-hero__box .blk-hero__ticker {
	-webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
	        mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
/* Inside the light card, swap the dot to dark and the label color to inverse-muted. */
.blk-hero__box .blk-hero__ticker-item + .blk-hero__ticker-item::before {
	background: rgba(9, 9, 11, 0.85);
}
.blk-hero__box .blk-hero__ticker-label { color: var(--color-fg-inverse); }
@media (max-width: 720px) {
	.blk-hero__box { padding: 64px 24px 0; border-radius: 12px; }
	.blk-hero__box .blk-hero__ticker-wrap { margin: 0 -24px; padding: 18px 0; }
}

/* ---- Per-letter rise. hero.js wraps each char in __char-mask > __char-inner ---- */
.blk-hero h1 .blk-hero__line { display: block; line-height: 1.05; }
.blk-hero h1 .blk-hero__word-mask {
	display: inline-block;
	white-space: nowrap;
	vertical-align: bottom;
	padding-bottom: 0.06em;
	margin-bottom: -0.06em;
}
.blk-hero h1 .blk-hero__char-mask {
	display: inline-block;
	overflow: hidden;
	vertical-align: bottom;
	line-height: 1.05;
	padding-bottom: 0.04em;
	margin-bottom: -0.04em;
}
.blk-hero h1 .blk-hero__char-inner {
	display: inline-block;
	transform: translateY(110%);
	will-change: transform;
	animation: blk-hero-char-rise 0.45s var(--ease) forwards;
	animation-delay: calc(var(--base, 0.05s) + var(--i, 0) * 0.018s);
}
.blk-hero h1 .blk-hero__line--2 { --base: 0.28s; }
@keyframes blk-hero-char-rise { to { transform: translateY(0); } }
@media (prefers-reduced-motion: reduce) {
	.blk-hero h1 .blk-hero__char-inner { animation: none; transform: none; }
}

/* ---- Ticker (only used inside the hero) ---- */
.blk-hero__ticker-wrap { margin-top: 16px; }
.blk-hero__ticker {
	position: relative;
	overflow: hidden;
	mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
	-webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}
.blk-hero__ticker-track {
	display: flex;
	gap: 32px;
	width: max-content;
	animation: blk-hero-ticker 80s linear infinite;
	align-items: center;
}
@keyframes blk-hero-ticker {
	from { transform: translateX(0); }
	to   { transform: translateX(-50%); }
}
.blk-hero__ticker-item {
	display: inline-flex;
	align-items: center;
	flex-shrink: 0;
	padding: 0;
	border: none;
	background: transparent;
}
/* 5px square dot between consecutive items (suppressed before the very first). */
.blk-hero__ticker-item + .blk-hero__ticker-item::before {
	content: "";
	display: inline-block;
	width: 5px;
	height: 5px;
	background: var(--color-grid-dot);
	margin-right: 32px;
	flex-shrink: 0;
}
.blk-hero__ticker-label {
	font-family: var(--font-mono);
	font-size: var(--text-caption);
	font-weight: var(--weight-regular);
	color: var(--color-fg-muted);
	letter-spacing: var(--tracking-widest);
	text-transform: uppercase;
	line-height: var(--leading-snug);
	white-space: nowrap;
}
@media (prefers-reduced-motion: reduce) {
	.blk-hero__ticker-track { animation: none; }
}