/**
 * Wedding Dance Sensations - Animations
 * Version premium, plus lente, plus visible, plus élégante
 *
 * Classes principales :
 * .reveal
 * .reveal-up
 * .reveal-left
 * .reveal-right
 * .reveal-scale
 * .reveal-soft
 * .reveal-stagger
 * .cards-premium-stagger
 * .testimonials-stagger
 * .pricing-stagger
 * .is-visible
 *
 * Micro-interactions :
 * .hover-lift
 * .hover-image
 * .hover-link
 */

:root {
	/* Durées */
	--wds-anim-duration-fast: 0.55s;
	--wds-anim-duration-base: 0.82s;
	--wds-anim-duration-slow: 1s;
	--wds-anim-duration-xslow: 1.15s;

	/* Courbe douce premium */
	--wds-anim-ease: cubic-bezier(0.22, 1, 0.36, 1);

	/* Distances d'entrée */
	--wds-reveal-distance: 26px;
	--wds-reveal-distance-soft: 18px;
	--wds-reveal-distance-horizontal: 30px;
	--wds-reveal-scale-start: 0.985;

	/* Hover */
	--wds-hover-lift-y: -5px;
	--wds-hover-image-scale: 1.018;

	/* Ombres */
	--wds-shadow-soft: 0 14px 30px rgba(74, 63, 59, 0.08);
	--wds-shadow-soft-hover: 0 20px 42px rgba(74, 63, 59, 0.12);

	/* Header scroll */
	--wds-header-bg-scrolled: rgba(251, 247, 242, 0.88);
	--wds-header-border-scrolled: rgba(74, 63, 59, 0.08);
	--wds-header-shadow-scrolled: 0 10px 28px rgba(74, 63, 59, 0.08);
}

/* -----------------------------------
   Base des reveals
----------------------------------- */

html.wds-animations-ready .reveal {
	opacity: 0;
	will-change: opacity, transform;
	backface-visibility: hidden;
	transition:
		opacity var(--wds-anim-duration-base) var(--wds-anim-ease),
		transform var(--wds-anim-duration-base) var(--wds-anim-ease);
}

html.wds-animations-ready .reveal.is-visible {
	opacity: 1;
	transform: none;
}

/* Directions */
html.wds-animations-ready .reveal-up {
	transform: translate3d(0, var(--wds-reveal-distance), 0);
}

html.wds-animations-ready .reveal-left {
	transform: translate3d(calc(var(--wds-reveal-distance-horizontal) * -1), 0, 0);
}

html.wds-animations-ready .reveal-right {
	transform: translate3d(var(--wds-reveal-distance-horizontal), 0, 0);
}

html.wds-animations-ready .reveal-scale {
	transform: translate3d(0, var(--wds-reveal-distance-soft), 0) scale(var(--wds-reveal-scale-start));
}

html.wds-animations-ready .reveal-soft {
	transform: translate3d(0, var(--wds-reveal-distance-soft), 0);
}

html.wds-animations-ready .reveal-none {
	transform: none;
}

/* Durées */
html.wds-animations-ready .reveal.duration-fast {
	transition-duration: var(--wds-anim-duration-fast);
}

html.wds-animations-ready .reveal.duration-base {
	transition-duration: var(--wds-anim-duration-base);
}

html.wds-animations-ready .reveal.duration-slow {
	transition-duration: var(--wds-anim-duration-slow);
}

html.wds-animations-ready .reveal.duration-xslow {
	transition-duration: var(--wds-anim-duration-xslow);
}

/* Delays utilitaires */
html.wds-animations-ready .reveal.delay-1 {
	transition-delay: 0.08s;
}

html.wds-animations-ready .reveal.delay-2 {
	transition-delay: 0.18s;
}

html.wds-animations-ready .reveal.delay-3 {
	transition-delay: 0.3s;
}

html.wds-animations-ready .reveal.delay-4 {
	transition-delay: 0.44s;
}

html.wds-animations-ready .reveal.delay-5 {
	transition-delay: 0.58s;
}

html.wds-animations-ready .reveal.delay-6 {
	transition-delay: 0.72s;
}

/* -----------------------------------
   Stagger de base
----------------------------------- */

html.wds-animations-ready .reveal-stagger > * {
	opacity: 0;
	will-change: opacity, transform;
	backface-visibility: hidden;
	transform: translate3d(0, var(--wds-reveal-distance-soft), 0);
	transition:
		opacity var(--wds-anim-duration-base) var(--wds-anim-ease),
		transform var(--wds-anim-duration-base) var(--wds-anim-ease);
}

html.wds-animations-ready .reveal-stagger.is-visible > * {
	opacity: 1;
	transform: none;
}

html.wds-animations-ready .reveal-stagger.is-visible > *:nth-child(1) {
	transition-delay: 0.08s;
}

html.wds-animations-ready .reveal-stagger.is-visible > *:nth-child(2) {
	transition-delay: 0.2s;
}

html.wds-animations-ready .reveal-stagger.is-visible > *:nth-child(3) {
	transition-delay: 0.32s;
}

html.wds-animations-ready .reveal-stagger.is-visible > *:nth-child(4) {
	transition-delay: 0.44s;
}

html.wds-animations-ready .reveal-stagger.is-visible > *:nth-child(5) {
	transition-delay: 0.56s;
}

html.wds-animations-ready .reveal-stagger.is-visible > *:nth-child(6) {
	transition-delay: 0.68s;
}

/* -----------------------------------
   Variante premium pour les 3 cards
   du bloc rassurance
----------------------------------- */

html.wds-animations-ready .cards-premium-stagger > * {
	opacity: 0;
	will-change: opacity, transform;
	backface-visibility: hidden;
	transform: translate3d(0, 24px, 0);
	transition:
		opacity 1s var(--wds-anim-ease),
		transform 1s var(--wds-anim-ease);
}

html.wds-animations-ready .cards-premium-stagger.is-visible > * {
	opacity: 1;
	transform: none;
}

html.wds-animations-ready .cards-premium-stagger.is-visible > *:nth-child(1) {
	transition-delay: 0.12s;
}

html.wds-animations-ready .cards-premium-stagger.is-visible > *:nth-child(2) {
	transition-delay: 0.28s;
}

html.wds-animations-ready .cards-premium-stagger.is-visible > *:nth-child(3) {
	transition-delay: 0.44s;
}

html.wds-animations-ready .cards-premium-stagger.is-visible > *:nth-child(4) {
	transition-delay: 0.6s;
}

/* -----------------------------------
   Variante pour témoignages
----------------------------------- */

html.wds-animations-ready .testimonials-stagger > * {
	opacity: 0;
	will-change: opacity, transform;
	backface-visibility: hidden;
	transform: translate3d(0, 20px, 0);
	transition:
		opacity 0.9s var(--wds-anim-ease),
		transform 0.9s var(--wds-anim-ease);
}

html.wds-animations-ready .testimonials-stagger.is-visible > * {
	opacity: 1;
	transform: none;
}

html.wds-animations-ready .testimonials-stagger.is-visible > *:nth-child(1) {
	transition-delay: 0.1s;
}

html.wds-animations-ready .testimonials-stagger.is-visible > *:nth-child(2) {
	transition-delay: 0.24s;
}

html.wds-animations-ready .testimonials-stagger.is-visible > *:nth-child(3) {
	transition-delay: 0.38s;
}

html.wds-animations-ready .testimonials-stagger.is-visible > *:nth-child(4) {
	transition-delay: 0.52s;
}

/* -----------------------------------
   Variante pour formules / pricing
----------------------------------- */

html.wds-animations-ready .pricing-stagger > * {
	opacity: 0;
	will-change: opacity, transform;
	backface-visibility: hidden;
	transform: translate3d(0, 22px, 0);
	transition:
		opacity 0.95s var(--wds-anim-ease),
		transform 0.95s var(--wds-anim-ease);
}

html.wds-animations-ready .pricing-stagger.is-visible > * {
	opacity: 1;
	transform: none;
}

html.wds-animations-ready .pricing-stagger.is-visible > *:nth-child(1) {
	transition-delay: 0.1s;
}

html.wds-animations-ready .pricing-stagger.is-visible > *:nth-child(2) {
	transition-delay: 0.24s;
}

html.wds-animations-ready .pricing-stagger.is-visible > *:nth-child(3) {
	transition-delay: 0.38s;
}

html.wds-animations-ready .pricing-stagger.is-visible > *:nth-child(4) {
	transition-delay: 0.52s;
}

html.wds-animations-ready .pricing-stagger.is-visible > *:nth-child(5) {
	transition-delay: 0.66s;
}

/* -----------------------------------
   Hover premium
----------------------------------- */

.hover-lift {
	transition:
		transform var(--wds-anim-duration-fast) var(--wds-anim-ease),
		box-shadow var(--wds-anim-duration-fast) var(--wds-anim-ease),
		border-color var(--wds-anim-duration-fast) var(--wds-anim-ease),
		background-color var(--wds-anim-duration-fast) var(--wds-anim-ease);
}

.hover-lift:hover,
.hover-lift:focus-within {
	transform: translateY(var(--wds-hover-lift-y));
	box-shadow: var(--wds-shadow-soft-hover);
}

.hover-image {
	overflow: hidden;
}

.hover-image img,
.hover-image picture img,
.hover-image .wp-block-image img,
.hover-image .kb-image img {
	transform-origin: center center;
	transition:
		transform var(--wds-anim-duration-slow) var(--wds-anim-ease),
		filter var(--wds-anim-duration-slow) var(--wds-anim-ease);
}

.hover-image:hover img,
.hover-image:hover picture img,
.hover-image:hover .wp-block-image img,
.hover-image:hover .kb-image img,
.hover-image:focus-within img,
.hover-image:focus-within picture img,
.hover-image:focus-within .wp-block-image img,
.hover-image:focus-within .kb-image img {
	transform: scale(var(--wds-hover-image-scale));
}

.hover-link a,
a.hover-link {
	position: relative;
	text-decoration: none;
	background-image: linear-gradient(currentColor, currentColor);
	background-repeat: no-repeat;
	background-position: left 100%;
	background-size: 0% 1px;
	transition:
		background-size var(--wds-anim-duration-fast) var(--wds-anim-ease),
		color var(--wds-anim-duration-fast) var(--wds-anim-ease),
		opacity var(--wds-anim-duration-fast) var(--wds-anim-ease);
}

.hover-link a:hover,
.hover-link a:focus-visible,
a.hover-link:hover,
a.hover-link:focus-visible {
	background-size: 100% 1px;
}

/* -----------------------------------
   Boutons
----------------------------------- */

.wp-block-button__link,
.kb-button,
button,
input[type="button"],
input[type="submit"],
input[type="reset"] {
	transition:
		transform var(--wds-anim-duration-fast) var(--wds-anim-ease),
		box-shadow var(--wds-anim-duration-fast) var(--wds-anim-ease),
		background-color var(--wds-anim-duration-fast) var(--wds-anim-ease),
		border-color var(--wds-anim-duration-fast) var(--wds-anim-ease),
		color var(--wds-anim-duration-fast) var(--wds-anim-ease);
}

.wp-block-button__link:hover,
.wp-block-button__link:focus-visible,
.kb-button:hover,
.kb-button:focus-visible,
button:hover,
button:focus-visible,
input[type="button"]:hover,
input[type="button"]:focus-visible,
input[type="submit"]:hover,
input[type="submit"]:focus-visible,
input[type="reset"]:hover,
input[type="reset"]:focus-visible {
	transform: translateY(-2px);
	box-shadow: var(--wds-shadow-soft);
}

/* -----------------------------------
   Header au scroll
----------------------------------- */

.site-header,
#main-header,
#masthead {
	transition:
		background-color var(--wds-anim-duration-fast) var(--wds-anim-ease),
		box-shadow var(--wds-anim-duration-fast) var(--wds-anim-ease),
		border-color var(--wds-anim-duration-fast) var(--wds-anim-ease),
		backdrop-filter var(--wds-anim-duration-fast) var(--wds-anim-ease),
		-webkit-backdrop-filter var(--wds-anim-duration-fast) var(--wds-anim-ease);
}

body.wds-scrolled .site-header,
body.wds-scrolled #main-header,
body.wds-scrolled #masthead {
	background-color: var(--wds-header-bg-scrolled);
	border-color: var(--wds-header-border-scrolled);
	box-shadow: var(--wds-header-shadow-scrolled);
	backdrop-filter: blur(10px);
	-webkit-backdrop-filter: blur(10px);
}

body.wds-scrolled .site-header .site-main-header-wrap,
body.wds-scrolled #main-header .site-main-header-wrap,
body.wds-scrolled #masthead .site-main-header-wrap,
body.wds-scrolled .site-header .site-header-row-container-inner,
body.wds-scrolled #main-header .site-header-row-container-inner,
body.wds-scrolled #masthead .site-header-row-container-inner {
	transition: padding var(--wds-anim-duration-fast) var(--wds-anim-ease);
}

/* -----------------------------------
   Utilitaires
----------------------------------- */

.anim-shadow-soft {
	box-shadow: var(--wds-shadow-soft);
}

.anim-rounded-soft {
	border-radius: 20px;
}

.anim-overflow-hidden {
	overflow: hidden;
}

/* -----------------------------------
   Responsive
----------------------------------- */

@media (max-width: 1024px) {
	:root {
		--wds-reveal-distance: 22px;
		--wds-reveal-distance-soft: 16px;
		--wds-reveal-distance-horizontal: 24px;
		--wds-hover-lift-y: -4px;
	}
}

@media (max-width: 767px) {
	:root {
		--wds-reveal-distance: 18px;
		--wds-reveal-distance-soft: 12px;
		--wds-reveal-distance-horizontal: 18px;
		--wds-hover-lift-y: -2px;
		--wds-hover-image-scale: 1.012;
	}

	html.wds-animations-ready .reveal {
		transition-duration: 0.72s;
	}

	html.wds-animations-ready .reveal-stagger > *,
	html.wds-animations-ready .cards-premium-stagger > *,
	html.wds-animations-ready .testimonials-stagger > *,
	html.wds-animations-ready .pricing-stagger > * {
		transition-duration: 0.78s;
	}

	/* Cascade plus compacte sur mobile */
	html.wds-animations-ready .cards-premium-stagger.is-visible > *:nth-child(1),
	html.wds-animations-ready .testimonials-stagger.is-visible > *:nth-child(1),
	html.wds-animations-ready .pricing-stagger.is-visible > *:nth-child(1) {
		transition-delay: 0.08s;
	}

	html.wds-animations-ready .cards-premium-stagger.is-visible > *:nth-child(2),
	html.wds-animations-ready .testimonials-stagger.is-visible > *:nth-child(2),
	html.wds-animations-ready .pricing-stagger.is-visible > *:nth-child(2) {
		transition-delay: 0.18s;
	}

	html.wds-animations-ready .cards-premium-stagger.is-visible > *:nth-child(3),
	html.wds-animations-ready .testimonials-stagger.is-visible > *:nth-child(3),
	html.wds-animations-ready .pricing-stagger.is-visible > *:nth-child(3) {
		transition-delay: 0.28s;
	}

	html.wds-animations-ready .cards-premium-stagger.is-visible > *:nth-child(4),
	html.wds-animations-ready .testimonials-stagger.is-visible > *:nth-child(4),
	html.wds-animations-ready .pricing-stagger.is-visible > *:nth-child(4) {
		transition-delay: 0.38s;
	}

	html.wds-animations-ready .pricing-stagger.is-visible > *:nth-child(5) {
		transition-delay: 0.48s;
	}
}

/* -----------------------------------
   Accessibilité
----------------------------------- */

@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}

	html.wds-animations-ready .reveal,
	html.wds-animations-ready .reveal-stagger > *,
	html.wds-animations-ready .cards-premium-stagger > *,
	html.wds-animations-ready .testimonials-stagger > *,
	html.wds-animations-ready .pricing-stagger > *,
	.hover-lift,
	.hover-image img,
	.hover-image picture img,
	.hover-image .wp-block-image img,
	.hover-image .kb-image img,
	.hover-link a,
	a.hover-link,
	.wp-block-button__link,
	.kb-button,
	button,
	input[type="button"],
	input[type="submit"],
	input[type="reset"],
	.site-header,
	#main-header,
	#masthead {
		transition: none !important;
		animation: none !important;
		transform: none !important;
		opacity: 1 !important;
	}
}