/* Effets d'interaction (19/11/2026, demande de Tim) : titres mot par mot, halo
   qui suit la souris, grain pellicule. Retirer = supprimer l'enqueue fx dans inc/enqueue.php. */

/* 1. Titres révélés mot par mot */
.fx-w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .08em; margin-bottom: -.08em; }
.fx-w > span {
	display: inline-block;
	transform: translateY(105%);
	opacity: 0;
	transition: transform 800ms cubic-bezier(.2,.8,.2,1), opacity 600ms ease;
	transition-delay: calc(var(--fx-i, 0) * 45ms);
}
.fx-split.is-in .fx-w > span { transform: none; opacity: 1; }

/* 2. Halo turquoise qui suit la souris */
.fx-glow {
	position: absolute; inset: 0; border-radius: inherit; pointer-events: none; z-index: 0;
	background: radial-gradient(260px circle at var(--fx-x, 50%) var(--fx-y, 50%), rgba(82, 199, 163, .22), transparent 70%);
	opacity: 0; transition: opacity 300ms ease;
}
.fx-glow-host:hover > .fx-glow { opacity: 1; }
.btn > .fx-glow { background: radial-gradient(120px circle at var(--fx-x, 50%) var(--fx-y, 50%), rgba(255, 255, 255, .25), transparent 70%); }
html[data-theme="light"] .fx-glow { background: radial-gradient(260px circle at var(--fx-x, 50%) var(--fx-y, 50%), rgba(82, 199, 163, .18), transparent 70%); }

/* 3. Grain pellicule (statique, aucun coût au scroll) */
.fx-grain {
	position: fixed; inset: 0; z-index: 9990; pointer-events: none; opacity: .07;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .55 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
html[data-theme="light"] .fx-grain { opacity: .05; filter: invert(1); }

@media (prefers-reduced-motion: reduce) {
	.fx-w > span { transform: none; opacity: 1; transition: none; }
}
