/*
 * Entrance motion, front end only (not an editor style): the page title rises
 * in once on load, sections fade in as they scroll into view
 * (assets/js/reveal.js).
 * Nothing moves with reduced motion. Transform only on the title: on a
 * section it would break the sticky and fixed elements inside it.
 */
@media (prefers-reduced-motion: no-preference) {

	main h1,
	main .archive-intro > h1 + * {
		animation: ragazzo-title-in 0.9s cubic-bezier(0.22, 1, 0.36, 1) 0.1s both;
	}

	main .archive-intro > h1 + * {
		animation-delay: 0.25s;
	}

	.has-reveal .is-reveal {
		opacity: 0;
		transition: opacity 0.9s cubic-bezier(0.22, 1, 0.36, 1);
	}

	.has-reveal .is-reveal.is-revealed {
		opacity: 1;
	}
}

@keyframes ragazzo-title-in {

	from {
		opacity: 0;
		transform: translateY(0.3em);
	}
}

@media print {

	.has-reveal .is-reveal {
		opacity: 1;
		transition: none;
	}
}

/*
 * Smooth scroll (assets/js/smooth-scroll.js): Lenis drives the scroll, so the
 * native smoothing in base.css is off while it runs. Rules from lenis.css.
 */
html.lenis,
html.lenis body {
	height: auto;
}

html.lenis {
	scroll-behavior: auto;
}

.lenis:not(.lenis-autoToggle).lenis-stopped {
	overflow: clip;
}

.lenis [data-lenis-prevent] {
	overscroll-behavior: contain;
}

.lenis.lenis-smooth iframe {
	pointer-events: none;
}

.lenis.lenis-autoToggle {
	transition-property: overflow;
	transition-duration: 1ms;
	transition-behavior: allow-discrete;
}
