/* Fiesta Marquee — three opposite-direction CSS marquees */

.ortega-fiesta-marquee {
	/* Light orange (Yellow 600) — matches edge-orange-up.svg / footer handoff. */
	--ortega-fm-bg: #ffd000;
	--ortega-fm-orange: #f17e08;
	/* Even optical gap between lines — keep ink clear of the line above. */
	--ortega-fm-gap: 0;
	--ortega-fm-pad-y: clamp(0.35rem, 1.2vw, 0.85rem);
	/* Slight nudge only; never enough to collide with the line above. */
	--ortega-fm-line-nudge-2: 0;
	/* Condensed caps have extra box air above — small pull to match Let’s→Make it. */
	--ortega-fm-line-nudge-3: calc(var(--ortega-fm-size-unit) * -0.38);
	/* Type scale unit — lines use 2 / 4 / 6 × this value (max 200 / 400 / 600). */
	--ortega-fm-size-unit: clamp(18px, 5.25vw, 100px);
	background-color: var(--ortega-fm-bg);
	isolation: isolate;
	margin-block-start: 0 !important;
	margin-inline: calc(50% - 50vw);
	max-width: 100vw;
	overflow: hidden;
	position: relative;
	width: 100vw;
}

.ortega-fiesta-marquee .edge {
	left: 0;
	right: 0;
	width: 100%;
}

.ortega-fiesta-marquee .edge.top {
	transform: none;
	z-index: 3;
}

.ortega-fiesta-marquee .edge.bottom {
	transform: scaleY(-1);
	z-index: 3;
}

.ortega-fiesta-marquee .edge.yellow {
	background-color: var(--ortega-fm-bg);
}

.ortega-fiesta-marquee__inner {
	display: flex;
	flex-direction: column;
	gap: var(--ortega-fm-gap);
	padding-block: var(--ortega-fm-pad-y);
	position: relative;
	z-index: 2;
}

.ortega-fiesta-marquee__row {
	overflow: hidden;
	position: relative;
	width: 100%;
}

.ortega-fiesta-marquee__track {
	align-items: center;
	/* CSS fallback when JS is unavailable; JS disables this via --js class. */
	animation: ortega-fiesta-marquee-scroll 36s linear infinite;
	display: flex;
	/* Space between repeats scales with each line’s type size. */
	gap: 0.275em;
	width: max-content;
	will-change: transform;
}

.ortega-fiesta-marquee__row--rtl .ortega-fiesta-marquee__track {
	animation-direction: reverse;
	animation-duration: 40s;
}

.ortega-fiesta-marquee__row--line-3 .ortega-fiesta-marquee__track {
	animation-duration: 44s;
}

/* Scroll-velocity driven marquees (see fiesta-marquee-block.js). */
.ortega-fiesta-marquee--js .ortega-fiesta-marquee__track {
	animation: none;
}

.ortega-fiesta-marquee__segment {
	display: inline-flex;
	flex-shrink: 0;
}

.ortega-fiesta-marquee__text {
	color: var(--ortega-fm-orange);
	display: block;
	letter-spacing: 0.01em;
	/* Keep leading tall enough that glyph ink doesn’t collide with the next row. */
	line-height: 0.92;
	text-transform: uppercase;
	white-space: nowrap;
}

/* Line 1 — Berthold Block heavy (bold is the heaviest cut in the kit). 2× */
.ortega-fiesta-marquee__row--line-1 .ortega-fiesta-marquee__track {
	font-size: calc(var(--ortega-fm-size-unit) * 2);
}

.ortega-fiesta-marquee__row--line-1 .ortega-fiesta-marquee__text {
	font-family: var(--ortega-font-display);
	font-size: 1em;
	font-weight: 700;
}

/* Line 2 — Berthold Block bold. 4× */
.ortega-fiesta-marquee__row--line-2 {
	margin-top: var(--ortega-fm-line-nudge-2);
}

.ortega-fiesta-marquee__row--line-2 .ortega-fiesta-marquee__track {
	font-size: calc(var(--ortega-fm-size-unit) * 4);
}

.ortega-fiesta-marquee__row--line-2 .ortega-fiesta-marquee__text {
	font-family: var(--ortega-font-display);
	font-size: 1em;
	font-weight: 700;
}

/* Line 3 — Berthold Block Condensed. 6× */
.ortega-fiesta-marquee__row--line-3 {
	margin-top: var(--ortega-fm-line-nudge-3);
}

.ortega-fiesta-marquee__row--line-3 .ortega-fiesta-marquee__track {
	font-size: calc(var(--ortega-fm-size-unit) * 6);
}

.ortega-fiesta-marquee__row--line-3 .ortega-fiesta-marquee__text {
	font-family: var(--ortega-font-display-condensed);
	font-size: 1em;
	font-weight: 400;
	line-height: 0.88;
}

.ortega-fiesta-marquee-placeholder {
	background: #fff3b0;
	border: 1px dashed var(--ortega-fm-orange, #f17e08);
	color: var(--ortega-fm-orange, #f17e08);
	font-family: var(--ortega-font-body);
	padding: 1.5rem;
	text-align: center;
}

@keyframes ortega-fiesta-marquee-scroll {
	from {
		transform: translate3d(0, 0, 0);
	}

	to {
		transform: translate3d(-50%, 0, 0);
	}
}

@media (prefers-reduced-motion: reduce) {
	.ortega-fiesta-marquee__track {
		animation: none;
	}
}
