.floorplan-zoom-trigger {
	position: relative;
	display: inline-block;
	max-width: 100%;
	cursor: zoom-in;
}
.floorplan-zoom-badge {
	position: absolute;
	right: 12px;
	bottom: 12px;
	padding: 8px 12px;
	border-radius: 4px;
	background: #fff;
	color: #222;
}
.floorplan-zoom:not([open]) { display: none; }
.floorplan-zoom[open] {
	position: fixed;
	inset: 0;
	display: grid;
	grid-template-rows: auto minmax(0, 1fr);
	box-sizing: border-box;
	width: 100%;
	height: 100%;
	max-width: none;
	max-height: none;
	margin: 0;
	padding: 0;
	border: 0;
	background: #202020;
	color: #fff;
	overflow: hidden;
}
.floorplan-zoom-tools {
	display: flex;
	align-items: center;
	gap: 6px;
	padding: 8px 12px;
}
.floorplan-zoom-tools button {
	display: grid;
	place-items: center;
	flex: 0 0 44px;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 1px solid #777;
	border-radius: 4px;
	background: #343434;
	color: #fff;
	font-size: 17px;
	cursor: pointer;
}
.floorplan-zoom-tools button:disabled { opacity: .45; cursor: default; }
.floorplan-zoom-tools button:not(:disabled):hover { background: #505050; }
.floorplan-zoom-tools button:focus-visible,
.floorplan-zoom-viewport:focus-visible { outline: 2px solid #ffcf48; outline-offset: -3px; }
.floorplan-zoom-tools [data-zoom-close] { margin-inline-start: auto; }
/* Suppress browser gestures only over the image so pinch zoom stays in the viewer. */
.floorplan-zoom-viewport { overflow: auto; overscroll-behavior: contain; touch-action: none; }
/* Center when fitted, but let the entire image scroll into view when enlarged. */
.floorplan-zoom-stage {
	display: grid;
	place-items: center;
	width: max-content;
	min-width: 100%;
	min-height: 100%;
}
.floorplan-zoom-stage img { display: block; max-width: none; height: auto; }
.floorplan-zoom-stage img.is-pannable { cursor: grab; user-select: none; }
.floorplan-zoom-stage img.is-pannable:active { cursor: grabbing; }
.floorplan-zoom-stage img:not([src]) { visibility: hidden; }
.floorplan-zoom-viewport:has([data-zoom-error]:not([hidden])) .floorplan-zoom-stage { display: none; }
.floorplan-zoom-viewport [data-zoom-error] { padding: 16px; }
