/* Formulaire de contact (WPForms #199, page Contact) — mêmes codes que le panier et la validation de commande
 * (checkout.css) : sans carte, libellés 16 px / 600, saisie 18 px, champs arrondis 6 px avec halo bleu au focus,
 * bouton pilule pleine largeur. Un champ par ligne. */

#wpforms-199 {
	--mpe-ct-text: var(--ast-global-color-2, #000034);
	--mpe-ct-muted: #707070;
	--mpe-ct-line: #E7E8EE;
	--mpe-ct-accent: var(--ast-global-color-0, #1f53f3);
	--mpe-ct-red: #dc2626;
	/* Variables WPForms « modern » */
	--wpforms-field-border-radius: 6px;
	--wpforms-field-border-color: #D9D9D9;
	--wpforms-field-text-color: var(--mpe-ct-text);
	--wpforms-label-color: var(--mpe-ct-text);
	--wpforms-label-error-color: var(--mpe-ct-red);
	--wpforms-button-border-radius: 999px;
	--wpforms-button-background-color: var(--mpe-ct-accent);
	max-width: 700px;
	margin: 0 auto;
	padding: 0;
	border: 0;
	background: none;
}

/* Intro (bloc Paragraphe « mpe-contact-intro » placé au-dessus du formulaire dans l'éditeur) :
 * séparée des champs par un filet. */
.mpe-contact-intro {
	max-width: 700px; margin: 0 auto !important; padding: 0;
	color: var(--ast-global-color-2, #000034); font-size: var(--wp--preset--font-size--medium, 24px); line-height: 1.45; letter-spacing: .02em; text-align: center; /* = intro de la FAQ */
}
.mpe-contact-intro::after { content: ""; display: block; height: 1px; margin: 24px 0; background: #E7E8EE; }
.mpe-contact-intro a { color: var(--ast-global-color-0, #1f53f3); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }
.mpe-contact-intro a:hover { color: var(--ast-global-color-2, #000034); }
/* « ~ » et non « + » : WPForms insère une balise <style> entre le paragraphe et le formulaire */
.mpe-contact-intro ~ #wpforms-199 { margin-top: 0 !important; }

/* Un champ par ligne (les pots de miel restent en position absolue, hors flux) */
#wpforms-199 .wpforms-field-container { display: flex; flex-direction: column; gap: 24px; }
#wpforms-199 .wpforms-field { margin: 0; padding: 0; }

/* Libellés */
#wpforms-199 .wpforms-field-label {
	margin: 0 0 8px; padding: 0; color: var(--mpe-ct-text); font-size: 16px; font-weight: 600; line-height: 1.4;
}
#wpforms-199 .wpforms-required-label { color: var(--mpe-ct-red); font-weight: 700; }
#wpforms-199 .mpe-champs-obligatoires { margin: 0 0 24px; color: var(--mpe-ct-muted); font-size: 14px; line-height: 1.5; }
#wpforms-199 .wpforms-field-sublabel,
#wpforms-199 .wpforms-field-description { color: var(--mpe-ct-muted); font-size: 14px; }

/* Champs */
#wpforms-199 .wpforms-field input[type="text"],
#wpforms-199 .wpforms-field input[type="email"],
#wpforms-199 .wpforms-field input[type="tel"],
#wpforms-199 .wpforms-field textarea {
	width: 100%; max-width: none; height: 54px; min-height: 54px; padding: 0 16px;
	border: 1px solid #D9D9D9; border-radius: 6px; background: #fff; box-shadow: none;
	color: var(--mpe-ct-text); font-size: 18px; line-height: 52px; transition: border-color .15s, box-shadow .15s;
}
#wpforms-199 .wpforms-field textarea { height: auto; min-height: 160px; padding: 14px 16px; line-height: 1.5; resize: vertical; }
#wpforms-199 .wpforms-field input::placeholder,
#wpforms-199 .wpforms-field textarea::placeholder { color: #9A9AA5; }
#wpforms-199 .wpforms-field input:focus,
#wpforms-199 .wpforms-field textarea:focus {
	border-color: var(--mpe-ct-accent); outline: 0; box-shadow: 0 0 0 3px rgba(31, 83, 243, .15);
}

/* Téléphone (intl-tel-input) : drapeau aligné sur la hauteur du champ */
#wpforms-199 .wpforms-field-phone .iti { width: 100%; }
#wpforms-199 .wpforms-field-phone .iti input[type="tel"] { padding-left: 56px; }

/* Erreurs */
#wpforms-199 .wpforms-field input.wpforms-error,
#wpforms-199 .wpforms-field textarea.wpforms-error { border-color: var(--mpe-ct-red); box-shadow: none; }
#wpforms-199 em.wpforms-error,
#wpforms-199 label.wpforms-error { display: block; margin: 6px 0 0; padding: 0; color: var(--mpe-ct-red); font-size: 14px; font-style: normal; font-weight: 500; }

/* Bouton : même pilule que « Commander » */
#wpforms-199 .wpforms-submit-container { margin: 24px 0 0; padding: 0; }
#wpforms-199 button.wpforms-submit {
	display: inline-flex; align-items: center; justify-content: center; gap: 10px; width: 100%; height: auto; min-height: 56px; margin: 0; padding: 0 24px;
	border: 0; border-radius: 999px; background: var(--mpe-ct-accent); color: #fff; font-size: 18px; font-weight: 700; line-height: 1.2;
	box-shadow: none; transition: filter .2s;
}
#wpforms-199 button.wpforms-submit:hover,
#wpforms-199 button.wpforms-submit:focus-visible { background: var(--mpe-ct-accent); filter: brightness(.92); }
#wpforms-199 button.wpforms-submit:focus-visible { outline: 0; box-shadow: 0 0 0 3px rgba(31, 83, 243, .25); }
#wpforms-199 button.wpforms-submit:focus::after { display: none; } /* contour pointillé WPForms */

/* Message de confirmation */
#wpforms-confirmation-199 {
	max-width: 700px; margin: 0 auto; padding: 20px 24px; border: 0; border-radius: 12px;
	background: #ECFDF3; color: #166534; font-size: 18px; text-align: center;
}

@media (max-width: 600px) {
	.mpe-contact-intro::after { margin: 20px 0; }
}
