/*
 * WIZSP Quote Requests: front-end form.
 *
 * Colours and fonts come from the active theme's custom properties
 * (wizsp theme: --wz-c-*, --wz-f-*), with neutral fallbacks for any
 * other theme. Every rule carries two classes so it wins over theme
 * resets of single elements. The submit button is a .wp-element-button,
 * so it takes the theme's own button style.
 */

.wzq {
	--wzq-ink: var(--wz-c-navy, #0b1f3a);
	--wzq-text: var(--wz-c-ink, #1d2939);
	--wzq-muted: var(--wz-c-slate, #5b6676);
	--wzq-line: var(--wz-c-line, #d0d5dd);
	--wzq-accent: var(--wz-c-blue, #1f5eff);
	--wzq-error: #b42318;
	--wzq-error-bg: #fef3f2;
	--wzq-font: var(--wz-f-sans, inherit);
	font-family: var(--wzq-font);
	color: var(--wzq-text);
}

.wzq .wzq-form {
	margin: 0;
}

.wzq .wzq-form__grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 24px;
}

.wzq .wzq-field {
	display: flex;
	flex-direction: column;
	gap: 8px;
	min-width: 0;
	margin: 0;
	padding: 0;
	border: 0;
}

.wzq .wzq-field--full {
	grid-column: 1 / -1;
}

.wzq .wzq-field__label {
	display: block;
	margin: 0;
	padding: 0;
	font: 500 15px/1.35 var(--wzq-font);
	color: var(--wzq-ink);
}

.wzq fieldset.wzq-field > .wzq-field__label {
	margin-bottom: 4px;
}

.wzq .wzq-field__opt {
	font-weight: 400;
	color: var(--wzq-muted);
}

.wzq .wzq-input {
	box-sizing: border-box;
	width: 100%;
	min-height: 48px;
	margin: 0;
	padding: 12px 14px;
	font: 400 16px/1.4 var(--wzq-font);
	color: var(--wzq-text);
	background: #fff;
	border: 1px solid var(--wzq-line);
	border-radius: 2px;
	box-shadow: none;
	-webkit-appearance: none;
	appearance: none;
	transition: border-color .15s ease, box-shadow .15s ease;
}

.wzq .wzq-input:hover {
	border-color: var(--wzq-muted);
}

.wzq .wzq-input:focus,
.wzq .wzq-input:focus-visible {
	border-color: var(--wzq-accent);
	outline: 2px solid var(--wzq-accent);
	outline-offset: 0;
}

.wzq .wzq-input--select {
	padding-right: 40px;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%230b1f3a' stroke-width='1.5'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 16px center;
	background-size: 12px 8px;
	cursor: pointer;
}

.wzq .wzq-input--area {
	min-height: 120px;
	resize: vertical;
}

.wzq .wzq-input[aria-invalid="true"],
.wzq fieldset[aria-invalid="true"] .wzq-check input {
	border-color: var(--wzq-error);
}

.wzq .wzq-field__error {
	margin: 0;
	padding: 0;
	font: 400 14px/1.4 var(--wzq-font);
	color: var(--wzq-error);
}

.wzq .wzq-checks {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 12px 24px;
}

.wzq .wzq-check {
	display: flex;
	gap: 12px;
	align-items: flex-start;
	margin: 0;
	font: 400 15px/1.45 var(--wzq-font);
	color: var(--wzq-text);
	cursor: pointer;
}

.wzq .wzq-check input {
	flex: 0 0 18px;
	width: 18px;
	height: 18px;
	margin: 2px 0 0;
	accent-color: var(--wzq-ink);
	cursor: pointer;
}

.wzq .wzq-check a {
	color: inherit;
	text-decoration: underline;
	text-underline-offset: 2px;
}

.wzq .wzq-check a:hover {
	color: var(--wzq-accent);
}

.wzq .wzq-form__consent {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin-top: 32px;
	padding-top: 24px;
	border-top: 1px solid var(--wzq-line);
}

.wzq .wzq-form__actions {
	margin-top: 32px;
}

.wzq .wzq-form__submit {
	cursor: pointer;
}

.wzq .wzq-form__alert {
	margin: 0 0 24px;
	padding: 12px 16px;
	font: 400 15px/1.45 var(--wzq-font);
	color: var(--wzq-text);
	background: var(--wzq-error-bg);
	border-left: 3px solid var(--wzq-error);
}

.wzq .wzq-form__alert a {
	color: inherit;
	text-decoration: underline;
}

/* Honeypot: off screen, not display:none (some bots skip hidden fields). */
.wzq .wzq-form__hp {
	position: absolute !important;
	left: -10000px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

/* After sending. */
.wzq.wzq-done {
	display: flex;
	gap: 16px;
	align-items: flex-start;
	padding: 24px;
	background: #fff;
	border: 1px solid var(--wzq-line);
}

.wzq .wzq-done__mark {
	display: flex;
	flex: 0 0 32px;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	font: 500 16px/1 var(--wzq-font);
	color: #fff;
	background: var(--wzq-ink);
	border-radius: 2px;
}

.wzq .wzq-done__text {
	margin: 0;
	padding: 0;
	font: 400 20px/1.45 var(--wzq-font);
	color: var(--wzq-ink);
}

@media (max-width: 700px) {
	.wzq .wzq-form__grid,
	.wzq .wzq-checks {
		grid-template-columns: minmax(0, 1fr);
	}
}
