/*
 * Base styles only. Colors and fonts inherit from the theme, and every
 * visual choice can be overridden from the Elementor widget's Style tab.
 */
.hmr-form {
	--hmr-gap: 1.5rem;
	--hmr-label-gap: 0.4rem;
	--hmr-accent: currentColor;
	--hmr-error: #b3261e;
	--hmr-button-width: auto;
	display: flex;
	flex-direction: column;
	gap: var(--hmr-gap);
	max-inline-size: 100%;
}

.hmr-form [hidden] {
	display: none !important;
}

.hmr-field,
.hmr-field fieldset {
	display: flex;
	flex-direction: column;
	gap: var(--hmr-label-gap);
	margin: 0;
	padding: 0;
	border: 0;
	min-inline-size: 0;
}

.hmr-label {
	font-weight: 600;
	padding: 0;
}

.hmr-required {
	color: var(--hmr-error);
}

.hmr-help,
.hmr-privacy,
.hmr-counter {
	margin: 0;
	font-size: 0.9em;
	opacity: 0.8;
}

.hmr-counter {
	text-align: end;
}

.hmr-form input[type="text"],
.hmr-form input[type="email"],
.hmr-form input[type="tel"],
.hmr-form input[type="url"],
.hmr-form textarea {
	inline-size: 100%;
	box-sizing: border-box;
	padding: 0.7em 0.9em;
	border: 1px solid color-mix(in srgb, currentColor 35%, transparent);
	border-radius: 6px;
	background: transparent;
	color: inherit;
	font: inherit;
}

.hmr-form input[type="file"] {
	max-inline-size: 100%;
	font: inherit;
}

.hmr-form input[type="file"]::file-selector-button {
	margin-inline-end: 0.8em;
	padding: 0.5em 1em;
	border: 1px solid color-mix(in srgb, currentColor 35%, transparent);
	border-radius: 6px;
	background: transparent;
	color: inherit;
	font: inherit;
	cursor: pointer;
}

.hmr-form input[dir="ltr"] {
	text-align: start;
}

.hmr-form input:focus-visible,
.hmr-form textarea:focus-visible {
	outline: 2px solid var(--hmr-accent);
	outline-offset: 1px;
}

.hmr-form input[type="checkbox"],
.hmr-form input[type="radio"] {
	accent-color: var(--hmr-accent);
	inline-size: 1.1em;
	block-size: 1.1em;
	margin: 0;
	flex-shrink: 0;
}

.hmr-choices {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem 1.5rem;
}

.hmr-choices--grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(12rem, 1fr));
}

.hmr-choice {
	display: flex;
	align-items: center;
	gap: 0.5em;
	cursor: pointer;
}

.hmr-preview {
	position: relative;
	inline-size: fit-content;
}

.hmr-form .hmr-remove-photo,
.hmr-form .hmr-remove-photo:hover,
.hmr-form .hmr-remove-photo:focus {
	position: absolute;
	inset-block-start: 0;
	inset-inline-end: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	inline-size: 2rem;
	block-size: 2rem;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: #fff;
	color: #333;
	box-shadow: 0 1px 4px rgb(0 0 0 / 30%);
	font: inherit;
	font-size: 1.3rem;
	line-height: 1;
	cursor: pointer;
}

.hmr-form .hmr-remove-photo:focus-visible {
	outline: 2px solid var(--hmr-accent);
	outline-offset: 2px;
}

.hmr-preview img {
	display: block;
	inline-size: 8rem;
	block-size: 8rem;
	object-fit: cover;
	border-radius: 50%;
}

.hmr-field.is-invalid input:not([type="checkbox"]):not([type="radio"]),
.hmr-field.is-invalid textarea {
	border-color: var(--hmr-error);
}

.hmr-error {
	margin: 0;
	color: var(--hmr-error);
	font-size: 0.9em;
}

.hmr-alert {
	padding: 0.8em 1em;
	border: 1px solid var(--hmr-error);
	border-radius: 6px;
	color: var(--hmr-error);
}

.hmr-actions {
	display: flex;
}

.hmr-submit {
	inline-size: var(--hmr-button-width);
	padding: 0.8em 2.2em;
	border: 0;
	border-radius: 6px;
	cursor: pointer;
	font: inherit;
	font-weight: 600;
}

.hmr-submit[disabled] {
	opacity: 0.6;
	cursor: progress;
}

.hmr-success {
	padding: 1em;
	font-weight: 600;
}

/* Honeypot: invisible to people, present for bots. */
.hmr-hp {
	position: absolute !important;
	inset-inline-start: -10000px;
	inline-size: 1px;
	block-size: 1px;
	overflow: hidden;
}

@media (prefers-reduced-motion: no-preference) {
	.hmr-submit {
		transition: background-color 0.15s ease, opacity 0.15s ease;
	}
}
