/**
 * HG Automotive — public enquiry forms.
 *
 * @package HG_Automotive
 * @since 0.9.0
 */

.hg-auto-lead {
	margin: 0 0 var(--hg-auto-space-6, 1.5rem);
	padding: var(--hg-auto-space-5, 1.25rem);
	max-width: 28rem;
	background: var(--hg-auto-color-surface-elevated, #fff);
	border: 1px solid var(--hg-auto-color-border, #d7dde5);
	border-radius: var(--hg-auto-radius, 6px);
}

.hg-auto-lead__title {
	margin: 0 0 var(--hg-auto-space-2, 0.5rem);
	font-family: var(--hg-auto-font-display, Georgia, serif);
	font-size: 1.35rem;
	line-height: 1.25;
	color: var(--hg-auto-color-ink, #12171e);
}

.hg-auto-lead__intro {
	margin: 0 0 var(--hg-auto-space-4, 1rem);
	color: var(--hg-auto-color-muted, #6b7785);
	font-size: 0.9375rem;
}

.hg-auto-lead__form {
	margin: 0;
}

.hg-auto-lead__field {
	display: flex;
	flex-direction: column;
	gap: var(--hg-auto-space-2, 0.35rem);
	margin: 0 0 var(--hg-auto-space-3, 0.75rem);
}

.hg-auto-lead__label {
	margin: 0;
	font-size: 0.75rem;
	font-weight: 700;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: var(--hg-auto-color-muted, #6b7785);
}

.hg-auto-lead__required {
	color: var(--hg-auto-color-danger, #b42318);
	text-transform: none;
	letter-spacing: 0;
}

.hg-auto-lead__control {
	width: 100%;
	max-width: 100%;
	min-height: 2.75rem;
	padding: 0.5rem 0.65rem;
	border: 1px solid var(--hg-auto-color-border, #d7dde5);
	border-radius: var(--hg-auto-radius, 6px);
	background: var(--hg-auto-color-surface, #f4f6f8);
	color: var(--hg-auto-color-ink, #12171e);
	font: inherit;
	box-sizing: border-box;
}

textarea.hg-auto-lead__control {
	min-height: 7rem;
	resize: vertical;
}

.hg-auto-lead__control[aria-invalid="true"] {
	border-color: var(--hg-auto-color-danger, #b42318);
}

.hg-auto-lead__control:focus-visible {
	outline: none;
	border-color: var(--hg-auto-color-accent, var(--hg-color-primary));
	box-shadow: var(--hg-auto-focus);
	background: var(--hg-auto-color-surface-elevated, #fff);
}

.hg-auto-lead__hint {
	margin: calc(-1 * var(--hg-auto-space-2, 0.35rem)) 0 var(--hg-auto-space-3, 0.75rem);
	color: var(--hg-auto-color-muted, #6b7785);
	font-size: 0.8125rem;
}

.hg-auto-lead__error {
	color: var(--hg-auto-color-danger, #b42318);
	font-size: 0.8125rem;
}

.hg-auto-lead__field--consent {
	flex-direction: column;
}

.hg-auto-lead__consent {
	display: flex;
	align-items: flex-start;
	gap: var(--hg-auto-space-2, 0.5rem);
	font-size: 0.875rem;
	line-height: 1.45;
	color: var(--hg-auto-color-steel, #3a4656);
}

.hg-auto-lead__consent input {
	margin-top: 0.2rem;
	flex-shrink: 0;
}

.hg-auto-lead__actions {
	margin: var(--hg-auto-space-4, 1rem) 0 0;
}

.hg-auto-lead__submit {
	min-height: 2.75rem;
	padding: 0.55rem 1.25rem;
	border: 1px solid var(--hg-auto-color-accent, var(--hg-color-primary));
	border-radius: var(--hg-auto-radius-sm, var(--hg-auto-radius));
	background: var(--hg-auto-color-accent, var(--hg-color-primary));
	color: #fff;
	font: inherit;
	font-weight: 700;
	cursor: pointer;
}

.hg-auto-lead__submit:hover,
.hg-auto-lead__submit:focus-visible {
	background: var(--hg-auto-color-accent-hover, var(--hg-color-primary-hover));
	border-color: var(--hg-auto-color-accent-hover, var(--hg-color-primary-hover));
	color: #fff;
}

.hg-auto-lead__submit[disabled] {
	opacity: 0.6;
	cursor: default;
}

.hg-auto-lead__counter {
	display: block;
	margin-top: var(--hg-auto-space-1, 0.25rem);
	color: var(--hg-auto-color-muted, #6b7785);
	font-size: 0.75rem;
	text-align: right;
}

.hg-auto-lead__success {
	margin: 0 0 var(--hg-auto-space-4, 1rem);
	padding: var(--hg-auto-space-3, 0.75rem) var(--hg-auto-space-4, 1rem);
	border-left: 3px solid var(--hg-auto-color-success, #067647);
	background: #e8f6ee;
}

.hg-auto-lead__success-message {
	margin: 0;
	font-weight: 700;
	color: var(--hg-auto-color-ink, #12171e);
}

.hg-auto-lead__success-reference {
	margin: var(--hg-auto-space-2, 0.4rem) 0 0;
	font-size: 0.875rem;
	color: var(--hg-auto-color-steel, #3a4656);
}

.hg-auto-lead__errors {
	margin: 0 0 var(--hg-auto-space-4, 1rem);
	padding: var(--hg-auto-space-3, 0.75rem) var(--hg-auto-space-4, 1rem);
	border-left: 3px solid var(--hg-auto-color-danger, #b42318);
	background: #fdecec;
}

.hg-auto-lead__errors-title {
	margin: 0;
	font-weight: 700;
}

.hg-auto-lead__errors-list {
	margin: var(--hg-auto-space-2, 0.4rem) 0 0;
	padding-left: 1.1rem;
	font-size: 0.875rem;
}

.hg-auto-lead--closed {
	padding: var(--hg-auto-space-4, 1rem);
}

.hg-auto-lead__closed-message {
	margin: 0;
	color: var(--hg-auto-color-muted, #6b7785);
}

/* Honeypot: hidden without display:none so fillers that skip display:none still fill it. */
.hg-auto-lead__hp {
	position: absolute;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

/* Vehicle single: nest neatly inside the conversion sidebar. */
.hg-auto-vs__aside .hg-auto-lead {
	margin-top: 0;
	max-width: none;
}

/* Dealer profile: sit with other contact sections. */
.hg-auto-dp__main .hg-auto-lead {
	max-width: 36rem;
}
