/**
 * Cover Carousel – style.css
 *
 * The carousel slides are absolutely positioned behind the cover's
 * existing ::before overlay and inner content via z-index layering.
 *
 * z-index ladder (core cover uses these internally):
 *   slides container  → z-index: 0
 *   core ::after dim  → z-index: 1  (the dark overlay span)
 *   inner container   → z-index: 1  (the text / inner blocks)
 */

/* ── Ensure the wrapper establishes a stacking context ── */
.wp-block-cover.has-carousel {
	isolation: isolate;
}

/* ── Slides container ── */
.cover-carousel__slides {
	position:    absolute;
	inset:       0;             /* top/right/bottom/left: 0 */
	z-index:     0;
	overflow:    hidden;
	pointer-events: none;
}

/* ── Individual slide ── */
.cover-carousel__slide {
	position:            absolute;
	inset:               0;
	background-size:     cover;
	background-position: center;
	background-repeat:   no-repeat;

	opacity:    0;
	transition: opacity 1000ms ease-in-out;
	will-change: opacity;
}

.cover-carousel__slide.is-active {
	opacity: 1;
}

/* ── Respect reduced motion ── */
@media (prefers-reduced-motion: reduce) {
	.cover-carousel__slide {
		transition: none;
	}
}
