/**
 * minimum hdr boss — frontend.
 *
 * The rule that matters: nothing in this file hides the real element. Every
 * hiding rule is scoped to .mhb-on, which ONLY the engine adds, and only after
 * a canvas has actually rendered. A Firefox visitor, an SDR display, a tainted
 * cross-origin logo or a dead GPU all mean .mhb-on never lands — and then the
 * page below is simply the page, at normal brightness.
 */

.mhb-t {
	position: relative;
}

.mhb-canvas {
	position: absolute;
	pointer-events: none;
}

/* mark — the canvas replaces the artwork. The image is kept in the DOM for alt
   text, indexing and the no-render fallback; only its paint is hidden.
   .mhb-t__src is the shortcode's own <img>; .mhb-src is an image we targeted by
   selector and left in place (never wrapped, so its sizing is untouched). Both
   are scoped so sibling images in the same container are not affected. */
.mhb-t--mark.mhb-on .mhb-t__src,
.mhb-t--mark.mhb-on .mhb-src {
	opacity: 0;
}

/* plate — the canvas supplies the fill and the glow, so the element's own
   background steps aside. Its text/icon stays live on top. */
.mhb-t--plate .mhb-canvas {
	z-index: 0;
}

.mhb-t--plate > *:not(.mhb-canvas) {
	position: relative;
	z-index: 1;
}

.mhb-t--plate.mhb-on {
	background-color: transparent !important;
	border-color: transparent !important;
}

/* textmark — the canvas sits on top and carries the glyphs. We hide the real
   text (rather than remove it) so it stays selectable, copyable and indexable.
   The highlight still paints when you drag-select it. */
.mhb-t--textmark .mhb-canvas {
	z-index: 2;
}

/* Hide the DOM text ROBUSTLY. A theme (Divi especially) wraps heading text in a
   child element with its own colour, so `color:transparent` on the host alone
   never reaches it — the original then ghosts through under the glow. Force it
   on the host AND every descendant, and cover the two other ways text stays
   visible: -webkit-text-fill-color (used for gradient text, wins over color)
   and text-shadow (a shadow is not a fill, so transparent colour leaves it). */
.mhb-t--textmark.mhb-on,
.mhb-t--textmark.mhb-on * {
	color: transparent !important;
	-webkit-text-fill-color: transparent !important;
	text-shadow: none !important;
}

/* traced — a halo behind fully live text. Nothing is hidden at all. */
.mhb-t--traced .mhb-canvas {
	z-index: 0;
}

.mhb-t--traced > *:not(.mhb-canvas) {
	position: relative;
	z-index: 1;
}
