/* NHR Blocks — Core Block Extensions: shared styles (front end + editor) */

/*
 * Group block with "Floating / stacked children" enabled: every direct
 * child occupies the same grid cell. Each child's justify-self /
 * align-self / z-index (base + any breakpoints) is generated per
 * instance and shipped as its own <style> tag right next to the block
 * (see src/core-extensions/index.js, buildPositionCss) rather than
 * here, since breakpoint pixel values are user-defined and a static
 * stylesheet can't contain a dynamic value.
 */
.nhr-grid-floating {
	position: relative;
	overflow: hidden;
}

.nhr-grid-floating > * {
	grid-column: 1 / -1;
	grid-row: 1 / -1;
}

/*
 * Video block with Height/Width/Object-fit set. Values are baked in as
 * CSS custom properties on the block's own <figure> wrapper; the inner
 * <video> element (rendered by core, not reachable via block attributes)
 * picks them up here.
 */
.wp-block-video.nhr-video-sized {
	height: var( --nhr-video-height, auto );
	width: var( --nhr-video-width, 100% );
}

.wp-block-video.nhr-video-sized video {
	width: 100%;
	height: 100%;
	object-fit: var( --nhr-video-object-fit, initial );
	display: block;
}
