/* RBS - External Map Embed
   Minimal styling. Height is controlled by the resizer script; we only set
   safe defaults here.

   NB: deliberately NO `transition` on `height`. The embedded map fills its
   iframe viewport, so while the height animated the child re-measured a
   shrinking viewport and reported it back — a feedback loop that collapsed
   the iframe down to its min-height. Snapping the height avoids that. */

iframe.rbs-external-map {
	width: 100%;
	border: 0;
	display: block;
	overflow: hidden;
}

/* Wrapper: positioning context for the loading overlay. */
.rbs-external-map-wrap {
	position: relative;
	display: block;
}

/* Loading overlay: covers the (min-height-sized) iframe until the map reports
   its first height; the script then swaps .rbs-is-loading for .rbs-is-loaded. */
.rbs-external-map-loader {
	position: absolute;
	top: 0;
	right: 0;
	bottom: 0;
	left: 0;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 12px;
	background: #f0f0f1;
	color: #50575e;
	font-size: 14px;
	line-height: 1.4;
	text-align: center;
	opacity: 1;
	visibility: visible;
	transition: opacity 0.35s ease, visibility 0.35s ease;
}

.rbs-external-map-wrap.rbs-is-loaded .rbs-external-map-loader {
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
}

.rbs-external-map-spinner {
	width: 32px;
	height: 32px;
	border: 3px solid rgba(0, 0, 0, 0.12);
	border-top-color: #50575e;
	border-radius: 50%;
	animation: rbs-external-map-spin 0.8s linear infinite;
}

@keyframes rbs-external-map-spin {
	to {
		transform: rotate(360deg);
	}
}

@media (prefers-reduced-motion: reduce) {
	.rbs-external-map-spinner {
		animation: none;
	}
}

.rbs-external-map-error {
	margin: 0.5em 0;
	padding: 0.5em 0.75em;
	border-left: 4px solid #d63638;
	background: #fcf0f1;
	color: #8a1f1f;
	font-size: 0.9em;
}
