/*--------------------------------------------------
Wave footer (end of the page content). Script: js/wave-footer.js

Modeled on the bloom.dev "Creative + Developer" block: a dense field of
thin vertical lines that flow slowly and bend away from the cursor with a
springy return, binary ticker strips, and an oversized title whose letters
rise in and roll over when hovered. Colours follow the page: the lines and
the title use the text colour of the section around them, the star the
accent colour.
---------------------------------------------------*/

.wf-footer {
	--wf-accent: #FFD400;                     /* same as data-primary-color */
	--wf-field: clamp(48px, 9vh, 110px);     /* the band above the title where the lines fade in */
	--wf-fade: 70%;                          /* lines fully visible from this far down */
	--wf-pad: 80px;
	--wf-label-font: 'Geologica', sans-serif;
	position: relative;
	width: 100%;
	box-sizing: border-box;
	padding: var(--wf-field) 0 clamp(24px, 4vw, 56px);
	overflow: hidden;
	color: inherit;
	isolation: isolate;
}

/* The line field covers the whole block; the title sits above it. No hard
   edges: the lines fade in from transparent at the top to full at
   --wf-fade of the block's height, and fade out again over the bottom
   padding, under the last strip */
.wf-canvas {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	display: block;
	z-index: 0;
	pointer-events: none;
	-webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 var(--wf-fade, 70%), #000 calc(100% - clamp(24px, 4vw, 56px)), transparent 100%);
	mask-image: linear-gradient(to bottom, transparent 0, #000 var(--wf-fade, 70%), #000 calc(100% - clamp(24px, 4vw, 56px)), transparent 100%);
}

/* The field runs on below the block (the next-page section, the footer):
   no fade at the bottom then */
.wf-footer.wf-extended .wf-canvas {
	-webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 var(--wf-fade, 70%));
	mask-image: linear-gradient(to bottom, transparent 0, #000 var(--wf-fade, 70%));
}

/* Its canvases there, added by the JS as the first child of each section,
   under the section's content. The JS sets the height (at most a screen and
   a bit; it then follows the scroll inside a taller section) */
.wf-canvas-ext {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	display: block;
	z-index: 0;
	pointer-events: none;
	transition: opacity 0.3s ease;
}

/* Out of the way while the next page loads (the next-page title moves up
   to become its hero) */
.show-loader .wf-canvas-ext,
.load-next-page .wf-canvas-ext {
	opacity: 0;
}

.wf-strip {
	position: relative;
	z-index: 1;
	display: flex;
	align-items: center;
	gap: 18px;
	height: 30px;
	margin: 0 var(--wf-pad);
	border-top: 1px solid currentColor;
	border-bottom: 1px solid currentColor;
	font-family: var(--wf-label-font);
	font-variant-numeric: tabular-nums;
	font-size: 10px;
	line-height: 1;
	letter-spacing: 0.06em;
	white-space: nowrap;
	overflow: hidden;
	opacity: 0.85;
}

.wf-strip + .wf-title {
	margin-top: 0;
}

.wf-strip span {
	flex: 0 0 auto;
}

.wf-strip .wf-slashes {
	flex: 1 1 auto;
	min-width: 0;
	overflow: hidden;
	opacity: 0.6;
}

.wf-title {
	position: relative;
	z-index: 1;
	margin: 0;
	padding: 0.06em var(--wf-pad) 0;
	font-size: var(--wf-size, 14.5vw);
	font-weight: 600;
	line-height: 0.92;
	letter-spacing: -0.045em;
	text-transform: uppercase;
	white-space: nowrap;
	color: inherit;
}

.wf-title a,
.wf-title a:hover {
	color: inherit;
	text-decoration: none;
}

.wf-link {
	display: inline-flex;
	align-items: center;
	gap: 0.1em;
	max-width: 100%;
	border-radius: 4px;
}

.wf-link:focus-visible {
	outline: 2px solid var(--wf-accent);
	outline-offset: 6px;
}

.wf-word {
	display: inline-block;
}

.wf-star {
	display: inline-block;
	width: 0.28em;
	height: 0.28em;
	margin: 0 0.12em;
	color: var(--wf-accent);
	transition: transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}

.wf-star svg {
	display: block;
	width: 100%;
	height: 100%;
	fill: currentColor;
}

.wf-link:hover .wf-star,
.wf-link:focus-visible .wf-star {
	transform: rotate(180deg) scale(1.15);
}

/* Letters, split by the JS: each rolls over to a copy of itself */
.wf-ch {
	position: relative;
	display: inline-block;
	overflow: hidden;
	vertical-align: top;
	padding-bottom: 0.02em;
}

.wf-ch-in {
	position: relative;
	display: inline-block;
	transform: translate3d(0, 0, 0);
}

.wf-ch-in::after {
	content: attr(data-letter);
	position: absolute;
	left: 0;
	top: 100%;
	visibility: hidden;
}

/* The copy only shows while the letter rolls over to it */
.wf-ch-in.is-rolling::after {
	visibility: visible;
}

.wf-ch-in.is-rolling {
	transform: translate3d(0, -100%, 0);
	transition: transform 0.55s cubic-bezier(0.76, 0, 0.24, 1);
}

/* Reveal: the letters rise in, one after another */
.wf-ready .wf-ch-in {
	transform: translate3d(0, 105%, 0);
}

.wf-ready.wf-in .wf-ch-in {
	transform: translate3d(0, 0, 0);
	transition: transform 1s cubic-bezier(0.22, 1, 0.36, 1) calc(var(--i, 0) * 45ms);
}

.wf-ready.wf-in .wf-ch-in.is-rolling {
	transform: translate3d(0, -100%, 0);
	transition: transform 0.55s cubic-bezier(0.76, 0, 0.24, 1);
}

.wf-ready .wf-star {
	transform: scale(0) rotate(-90deg);
}

.wf-ready.wf-in .wf-star {
	transform: none;
	transition: transform 1.1s cubic-bezier(0.22, 1, 0.36, 1) 0.25s;
}

.wf-ready.wf-in .wf-link:hover .wf-star,
.wf-ready.wf-in .wf-link:focus-visible .wf-star {
	transform: rotate(180deg) scale(1.15);
	transition-delay: 0s;
}

@media only screen and (max-width: 1466px) {
	.wf-footer {
		--wf-pad: 60px;
	}
}

@media only screen and (max-width: 1024px) {
	.wf-footer {
		--wf-pad: 40px;
		--wf-field: clamp(40px, 7vh, 80px);
	}
}

@media only screen and (max-width: 767px) {
	.wf-footer {
		--wf-pad: 20px;
		--wf-field: clamp(32px, 6vh, 56px);
	}

	.wf-strip {
		gap: 10px;
		height: 26px;
		font-size: 9px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.wf-ready .wf-ch-in,
	.wf-ready .wf-star,
	.wf-ch-in.is-rolling {
		transform: none !important;
		transition: none !important;
	}
}

/* .wf-bg (js/wave-footer.js): the same field as a section's background,
   behind its content (about.html: the pinned layer of the parallax
   captions). The canvas is the element's first child; the lines fade out at
   its top and bottom edges instead of stopping there */
.wf-bg > .wf-canvas {
	-webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 14%, #000 86%, transparent 100%);
	mask-image: linear-gradient(to bottom, transparent 0, #000 14%, #000 86%, transparent 100%);
}
