/* HPN Ads — advertising enquiry form. Uses the HPN theme's tokens when available. */

.hpn-enq {
	--enq-line: var(--hpn-line, #e3e6ea);
	--enq-muted: var(--hpn-muted, #5b6470);
	--enq-brand: var(--hpn-brand, #3dae2b);
	--enq-brand-dark: var(--hpn-brand-dark, #1f7a1a);
	--enq-radius: var(--hpn-radius, 6px);
}

.hpn-enq__hp {
	position: absolute !important;
	left: -9999px !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.hpn-enq__grid {
	display: grid;
	gap: 0 1rem;
	grid-template-columns: minmax(0, 1fr);
}

@media (min-width: 640px) {
	.hpn-enq__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

.hpn-enq__field {
	margin: 0 0 1rem;
}

.hpn-enq__field label,
.hpn-enq__interests legend {
	display: block;
	margin-bottom: 0.35rem;
	font-size: 0.875rem;
	font-weight: 600;
}

.hpn-enq__optional {
	color: var(--enq-muted);
	font-weight: 400;
}

.hpn-enq input[type="text"],
.hpn-enq input[type="email"],
.hpn-enq input[type="tel"],
.hpn-enq select,
.hpn-enq textarea {
	width: 100%;
	min-height: 46px;
	padding: 0.6em 0.8em;
	border: 1px solid #c4cad1;
	border-radius: var(--enq-radius);
	background: #fff;
	font: inherit;
}

.hpn-enq textarea {
	min-height: 110px;
	resize: vertical;
}

.hpn-enq input:focus,
.hpn-enq select:focus,
.hpn-enq textarea:focus {
	border-color: var(--enq-brand-dark);
	outline: 3px solid rgb(61 174 43 / 0.35);
	outline-offset: 0;
}

.hpn-enq [aria-invalid="true"] {
	border-color: #b32d2e;
}

.hpn-enq__interests {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	margin: 0 0 1rem;
	padding: 0;
	border: 0;
}

.hpn-enq__interests legend {
	width: 100%;
	padding: 0;
}

.hpn-enq__interests label {
	display: inline-flex;
	align-items: center;
	gap: 0.45rem;
	padding: 0.5rem 0.85rem;
	border: 1px solid var(--enq-line);
	border-radius: 999px;
	background: #fff;
	font-size: 0.875rem;
	cursor: pointer;
}

.hpn-enq__interests label:has(input:checked) {
	border-color: var(--enq-brand-dark);
	background: #eef7ec;
}

.hpn-enq__interests input {
	accent-color: var(--enq-brand-dark);
}

.hpn-enq__consent {
	display: flex;
	gap: 0.6rem;
	align-items: flex-start;
	margin: 0 0 1.25rem;
	color: var(--enq-muted);
	font-size: 0.8125rem;
	line-height: 1.5;
}

.hpn-enq__consent input {
	flex: none;
	width: 18px;
	height: 18px;
	margin-top: 0.1rem;
	accent-color: var(--enq-brand-dark);
}

.hpn-enq__actions {
	margin: 0;
}

.hpn-enq__submit {
	width: 100%;
	min-height: 50px;
	font-size: 1.0625rem;
}

@media (min-width: 640px) {
	.hpn-enq__submit {
		width: auto;
		padding-inline: 2em;
	}
}

.hpn-enq__result {
	margin-top: 1.25rem;
	padding: 1.1rem 1.25rem;
	border-left: 4px solid var(--enq-brand);
	border-radius: var(--enq-radius);
	background: #eef7ec;
}

.hpn-enq__result-text {
	margin: 0 0 0.75rem;
	color: var(--enq-brand-dark);
	font-weight: 600;
}

.hpn-enq__result-text:last-child {
	margin-bottom: 0;
}

.hpn-enq__error {
	margin: 1rem 0 0;
	color: #b32d2e;
	font-weight: 600;
}

.hpn-enq.is-sent .hpn-enq__grid,
.hpn-enq.is-sent .hpn-enq__interests,
.hpn-enq.is-sent .hpn-enq__field,
.hpn-enq.is-sent .hpn-enq__consent,
.hpn-enq.is-sent .hpn-enq__actions {
	display: none;
}
