/*
 * Reno Emanu-El — Duda compatibility overrides
 *
 * Duda's CSS hides every element with entrance-animation attrs until its
 * runtime JS removes the hidden state. When the runtime doesn't fire the
 * animation handler (e.g. for elements below the fold whose IntersectionObserver
 * never trips, or any element after a JS error), the content stays invisible.
 *
 * This rule keeps animated elements visible by default — animations may not
 * play, but the content is always readable.
 */
.dmDesktopBody:not(.editGrid) [data-anim-desktop]:not([data-anim-desktop='none']),
.dmDesktopBody:not(.editGrid) [data-anim-extended],
.dmDesktopBody:not(.editGrid) .dmNewParagraph[data-anim-desktop]:not([data-anim-desktop='none']),
.dmDesktopBody:not(.editGrid) .dmNewParagraph[data-anim-extended],
#dmRoot:not(.editGrid) .flex-element [data-anim-extended] {
	visibility: visible !important;
	opacity: 1 !important;
}

/*
 * Live's stylesheet stack zeroes out the browser-default 8px body margin;
 * ours did not, producing a visible canvas border. Match live.
 */
body#dmRoot { margin: 0; }

/*
 * Homepage hero (bgGallery u_1243667655): the Duda runtime paints the slide
 * backgrounds, but on this local server the ~27 runtime chunks load slowly,
 * leaving a grey box for ~10s until bgGallery initializes. The runtime also
 * clears the hero's own background-image (inline, !important) early in init,
 * so a plain background rule can't hold. Paint the first slide image on an
 * ::after layer instead — JS only touches the element's inline style, never
 * the pseudo-element, so this persists.
 *
 * isolation:isolate makes the hero its own stacking context, so the
 * z-index:-1 layer stays INSIDE the hero (above its transparent background,
 * below bgGallery's injected slide layer + the content). Without it, z-index:-1
 * falls behind the white .dmInner ancestor and the image is never visible.
 */
#dm .dmBody div.u_1243667655.slider-container-no-bg {
	isolation: isolate;
}
#dm .dmBody div.u_1243667655.slider-container-no-bg::after {
	content: "";
	/* Duda puts a clearfix (display:table) on .dmRespRow::after — that
	   collapses this layer to 0x0. Force block so inset:0 stretches it. */
	display: block;
	position: absolute;
	inset: 0;
	z-index: -1;
	background-image: url(../../uploads/duda-mirror/_live/lirp-cdn.multiscreensite.com/4dab8296/dms3rep/multi/opt/DJI_0559-1920w.JPG);
	background-size: cover;
	background-position: 50% 50%;
	background-repeat: no-repeat;
	pointer-events: none;
}

/*
 * Hero overlay dedup: the scraped post_content already contains one
 * .bgExtraLayerOverlay (0.3 black), and the Duda runtime injects a second on
 * init. Two stacked 0.3 overlays darken the hero to ~0.51 — live renders only
 * one. Hide the duplicate so the hero tint matches renoemanuel.org exactly.
 */
#dm .dmBody div.u_1243667655 .bgExtraLayerOverlay + .bgExtraLayerOverlay {
	display: none !important;
}
