/* Fond noir et suppression des marges du thème, uniquement sur la page qui porte le hero Aimé Design. */
body:has([data-aime="hero"], [data-aime="page"]) { background-color: #000; }
body:has([data-aime="hero"], [data-aime="page"]) .site-content,
body:has([data-aime="hero"], [data-aime="page"]) .content-area,
body:has([data-aime="hero"], [data-aime="page"]) .site-main { margin: 0; padding: 0; }
body:has([data-aime="hero"], [data-aime="page"]) .site.grid-container { max-width: 100%; }
body:has([data-aime="hero"], [data-aime="page"]) .inside-article { background: #000; margin: 0; padding: 0; }
body:has([data-aime="hero"], [data-aime="page"]) .entry-content { margin: 0; }
/* Les sections pleine largeur ne dépassent pas de la barre de défilement. */
body:has([data-aime="hero"], [data-aime="page"]) .entry-content > .alignfull { margin-left: 0; margin-right: 0; max-width: 100%; width: 100%; }

/* Visionneuse plein écran de la galerie. */
[data-aime="gallery"] .gb-carousel-item img { cursor: zoom-in; }
[data-aime="gallery"] .gb-carousel-item img:focus-visible { outline: 2px solid #fff; outline-offset: -4px; }
html.aime-lightbox-open { overflow: hidden; }
.aime-lightbox { background: rgba(0, 0, 0, 0.95); border: 0; color: #fff; height: 100vh; height: 100dvh; margin: 0; max-height: none; max-width: none; overflow: hidden; padding: 0; position: fixed; inset: 0; touch-action: pinch-zoom; width: 100%; }
.aime-lightbox[open] { align-items: center; display: flex; justify-content: center; }
.aime-lightbox::backdrop { background: rgba(0, 0, 0, 0.6); }
.aime-lightbox__img { height: auto; max-height: calc(100% - 8rem); max-width: calc(100% - 10rem); object-fit: contain; user-select: none; -webkit-user-drag: none; width: auto; }
.aime-lightbox .aime-lightbox__btn { align-items: center; background: rgba(0, 0, 0, 0.55); border: 1px solid rgba(255, 255, 255, 0.5); border-radius: 50%; color: #fff; cursor: pointer; display: flex; height: 3rem; justify-content: center; padding: 0; position: absolute; width: 3rem; }
.aime-lightbox .aime-lightbox__btn:hover, .aime-lightbox .aime-lightbox__btn:focus-visible { background: #fff; color: #000; }
.aime-lightbox__btn svg { fill: none; height: 1.25rem; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.75; width: 1.25rem; }
.aime-lightbox__close { right: 1rem; top: 1rem; }
.aime-lightbox__prev { left: 1rem; top: calc(50% - 1.5rem); }
.aime-lightbox__next { right: 1rem; top: calc(50% - 1.5rem); }
.aime-lightbox__count { bottom: 1.25rem; font-family: 'Poppins', sans-serif; font-size: 0.875rem; font-weight: 300; left: 0; letter-spacing: 0.08em; margin: 0; position: absolute; right: 0; text-align: center; }
@media (max-width: 767px) {
	.aime-lightbox__img { max-height: calc(100% - 11rem); max-width: 100%; }
	.aime-lightbox__prev, .aime-lightbox__next { bottom: 0.75rem; top: auto; }
}

/* Invitation à faire défiler : le chevron descend doucement. */
[data-aime="scroll-cue"] { transition: opacity 0.4s, visibility 0.4s, background-color 0.2s, color 0.2s; }
[data-aime="scroll-cue"].is-hidden { opacity: 0; pointer-events: none; visibility: hidden; }
[data-aime="scroll-cue"] > span { animation: aime-scroll-cue 2.2s ease-in-out infinite; }
@keyframes aime-scroll-cue {
	0% { opacity: 0; transform: translateY(-0.6rem); }
	35%, 65% { opacity: 1; }
	100% { opacity: 0; transform: translateY(0.6rem); }
}
[data-aime="gallery-section"]:focus { outline: none; }
@media (prefers-reduced-motion: reduce) {
	[data-aime="scroll-cue"] > span { animation: none; }
}

/* Images agrandissables de la page Contact. */
img[data-aime-zoom] { cursor: zoom-in; }
img[data-aime-zoom]:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }

/* ---- Narration de l'accueil ---- */
[data-aime-reveal] { transition: opacity 0.9s ease, transform 0.9s cubic-bezier(0.2, 0.7, 0.2, 1); }
[data-aime-reveal].aime-wait { opacity: 0; transform: translate3d(0, 2rem, 0); }
[data-aime-drift] img { will-change: transform; }
[data-aime="scene"] img { opacity: 0; transition: opacity 0.8s ease, transform 1.6s ease; transform: scale(1.06); }
[data-aime="scene"]:not(.has-active) img:first-child, [data-aime="scene"] img.is-active { opacity: 1; transform: scale(1); }
.aime-thread { background: linear-gradient(#f2c27b, rgba(199, 148, 90, 0.35)); bottom: 0; box-shadow: 0 0 10px 1px rgba(242, 194, 123, 0.35); left: 0.5rem; pointer-events: none; position: fixed; top: 0; transform: scaleY(0); transform-origin: top; width: 1px; z-index: 20; }

/* ---- Mosaïque de photographies ---- */
[data-aime-tile] img { transition: transform 1.2s cubic-bezier(0.2, 0.7, 0.2, 1), filter 0.6s; }
[data-aime-tile] figcaption { background: linear-gradient(transparent, rgba(0, 0, 0, 0.85)); bottom: 0; left: 0; padding: 2.5rem 1rem 0.75rem; pointer-events: none; position: absolute; right: 0; }
@media (hover: hover) {
	[data-aime-tile] figcaption { opacity: 0; transform: translateY(0.75rem); transition: opacity 0.4s, transform 0.4s; }
	[data-aime-tile]:hover figcaption, [data-aime-tile]:focus-within figcaption { opacity: 1; transform: none; }
	[data-aime-tile]:hover img { transform: scale(1.07); }
	[data-aime="visionneuse"]:hover [data-aime-tile]:not(:hover) img { filter: brightness(0.6); }
}
@media (prefers-reduced-motion: reduce) {
	[data-aime-tile] img, [data-aime-tile] figcaption, [data-aime="scene"] img { transition: none; }
	.aime-thread { display: none; }
}
