/**
 * Full-page overlay while a Gravity Form final submission is in progress.
 */

/* Hide Gravity Forms' default button/AJAX spinner — our overlay replaces it. */
img.gform_ajax_spinner,
[id^="gform_ajax_spinner_"],
.gform_ajax_spinner,
.gform-loader {
	display: none !important;
	visibility: hidden !important;
	opacity: 0 !important;
	width: 0 !important;
	height: 0 !important;
	margin: 0 !important;
	padding: 0 !important;
	border: 0 !important;
	animation: none !important;
}

/* Keep submit button label visible if GF marks it as spinning. */
.gform_wrapper .gform-button.gform-has-spinner,
.gform_wrapper .gform_button.gform-has-spinner,
.gform_wrapper .gform-theme-button.gform-has-spinner {
	color: inherit !important;
	-webkit-text-fill-color: currentColor !important;
}

.woods-gform-spinner-overlay {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(0, 0, 0, 0.45);
	/* Fade via visibility only — opacity on this element would tint the SVG. */
	opacity: 1;
	visibility: hidden;
	pointer-events: none;
	transition: visibility 0.2s ease;
}

.woods-gform-spinner-overlay.is-visible {
	visibility: visible;
	pointer-events: auto;
}

.woods-gform-spinner {
	display: block;
	width: 8rem;
	height: 8rem;
	background-color: #fff;
	border-radius: 0.5rem;
	box-shadow: 0 0.5rem 1.5rem rgba(0, 0, 0, 0.2);
}

.woods-gform-spinner-label {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

body.woods-gform-submitting {
	overflow: hidden;
}
