/* Éléments de formulaire en DA « Souligné » (#118, suite de la proposition A #109) : pas de pilule ni de cadre, un trait de soulignement ;
   texte en Outfit (--btp-t4), libellés et messages en --btp-t5 ; focus = trait crème 3 px, erreur = trait bordeaux 3 px + message crème signé d'un filet bordeaux.
   Contrastes sur fond marine : texte 10,6:1, placeholder (72 %) ≥ 5,6:1, trait au repos (45 %) ≥ 3,4:1. Messages et validation : js/btp-forms.js. */
:root { --btp-f-line: rgba(245, 230, 211, 0.45); --btp-f-ph: rgba(237, 240, 247, 0.72); --btp-f-cream: var(--btp-red-light, #F5E6D3); --btp-f-red: var(--btp-red, #C43A3A); --btp-f-text: var(--btp-white, #EDF0F7); }

/* ---------- Champs texte, e-mail, téléphone, nombre, date, select, textarea ---------- */
html:not(#btp-f1):not(#btp-f2) body form :where(input:not([type=hidden], [type=checkbox], [type=radio], [type=submit], [type=button], [type=reset], [type=file], [type=range], [type=color], [name=btp_url]), textarea, select) {
    -webkit-appearance: none !important; appearance: none !important; box-sizing: border-box !important;
    width: 100%; min-height: 44px !important; margin: 0; padding: 0.7em 0 0.5em !important;
    background-color: transparent !important; background-image: none; border: 0 !important; border-bottom: 2px solid var(--btp-f-line) !important; border-radius: 0 !important; box-shadow: none !important; outline: none;
    font-family: var(--btp-fb) !important; font-size: var(--btp-t4) !important; line-height: var(--btp-lh-4, 1.6) !important; font-weight: 400 !important; letter-spacing: 0 !important; text-transform: none !important;
    color: var(--btp-f-text) !important; caret-color: var(--btp-f-cream); color-scheme: dark;
    transition: border-color 0.2s ease, box-shadow 0.2s ease !important;
}
html:not(#btp-f1):not(#btp-f2) body form :is(input, textarea)::placeholder { color: var(--btp-f-ph) !important; opacity: 1 !important; font-family: var(--btp-fb); }
html:not(#btp-f1):not(#btp-f2) body form textarea { resize: vertical; min-height: 6.5em !important; }
/* Survol, rempli, focus clavier, erreur, désactivé. */
html:not(#btp-f1):not(#btp-f2) body form :where(input:not([type=checkbox], [type=radio]), textarea, select):hover { border-bottom-color: rgba(245, 230, 211, 0.85) !important; }
html:not(#btp-f1):not(#btp-f2) body form :where(input:not([type=checkbox], [type=radio], [type=date]):not(:placeholder-shown), textarea:not(:placeholder-shown), select:has(option:checked:not([value=""]))) { border-bottom-color: var(--btp-f-cream) !important; }
html:not(#btp-f1):not(#btp-f2) body form :where(input:not([type=checkbox], [type=radio]), textarea, select):focus { border-bottom-color: var(--btp-f-cream) !important; box-shadow: inset 0 -1px 0 var(--btp-f-cream) !important; outline: none !important; }
html:not(#btp-f1):not(#btp-f2) body form :where(input:not([type=checkbox], [type=radio]), textarea, select)[aria-invalid="true"] { border-bottom-color: var(--btp-f-red) !important; box-shadow: inset 0 -1px 0 var(--btp-f-red) !important; }
html:not(#btp-f1):not(#btp-f2) body form :where(input:not([type=checkbox], [type=radio]), textarea, select)[aria-invalid="true"]:focus { box-shadow: inset 0 -1px 0 var(--btp-f-red), 0 3px 0 -1px var(--btp-f-cream) !important; }
html:not(#btp-f1):not(#btp-f2) body form :is(input, textarea, select, button):disabled { opacity: 0.5 !important; cursor: not-allowed !important; border-bottom-style: dashed !important; }
/* Liste déroulante : chevron crème dessiné, options sur fond marine. */
html:not(#btp-f1):not(#btp-f2) body form select {
    padding-right: 1.6em !important; cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5 11 1.5' fill='none' stroke='%23F5E6D3' stroke-width='1.6'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important; background-position: right 0.15em center !important; background-size: 0.75em auto !important;
}
html:not(#btp-f1):not(#btp-f2) body form select:has(option[value=""]:checked) { color: var(--btp-f-ph) !important; }
html:not(#btp-f1):not(#btp-f2) body form select option { background: var(--btp-primary, #212f59); color: var(--btp-f-text); }
/* Date : indicateur du calendrier en crème. */
html:not(#btp-f1):not(#btp-f2) body form input[type=date]::-webkit-calendar-picker-indicator { filter: invert(93%) sepia(12%) saturate(330%); opacity: 0.85; cursor: pointer; }
html:not(#btp-f1):not(#btp-f2) body form input[type=date]:not(:focus):invalid, html:not(#btp-f1):not(#btp-f2) body form input[type=date][value=""]:not(:focus) { color: var(--btp-f-ph) !important; }
/* Nombre : sans flèches génériques. */
html:not(#btp-f1):not(#btp-f2) body form input[type=number] { -moz-appearance: textfield !important; }
html:not(#btp-f1):not(#btp-f2) body form input[type=number]::-webkit-inner-spin-button, html:not(#btp-f1):not(#btp-f2) body form input[type=number]::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
/* Autofill Chrome et Firefox : ni fond jaune ni fond bleu. */
html:not(#btp-f1):not(#btp-f2) body form :is(input, textarea, select):-webkit-autofill,
html:not(#btp-f1):not(#btp-f2) body form :is(input, textarea, select):-webkit-autofill:is(:hover, :focus) {
    -webkit-text-fill-color: var(--btp-f-text) !important; caret-color: var(--btp-f-cream);
    transition: background-color 0s 2147483647s, color 0s 2147483647s !important; -webkit-box-shadow: none !important;
}
html:not(#btp-f1):not(#btp-f2) body form :is(input, textarea, select):autofill { background-color: transparent !important; background-image: none !important; filter: none !important; }

/* ---------- Cases à cocher, boutons radio (hors interrupteurs du bandeau cookies) ---------- */
html:not(#btp-f1):not(#btp-f2) body form :is(input[type=checkbox], input[type=radio]):not(.btp-ck-row input):not(.btp-form-cat input) {
    -webkit-appearance: none !important; appearance: none !important; flex: none; width: 1.15em !important; height: 1.15em !important; margin: 0 0.55em 0 0 !important; padding: 0 !important; vertical-align: -0.2em;
    background: transparent !important; border: 2px solid var(--btp-f-line) !important; border-radius: 0 !important; box-shadow: none !important; cursor: pointer; display: inline-grid; place-content: center;
}
html:not(#btp-f1):not(#btp-f2) body form input[type=radio]:not(.btp-ck-row input):not(.btp-form-cat input) { border-radius: 50% !important; }
html:not(#btp-f1):not(#btp-f2) body form :is(input[type=checkbox], input[type=radio]):not(.btp-ck-row input):not(.btp-form-cat input):checked { border-color: var(--btp-f-cream) !important; background: var(--btp-f-red) !important; box-shadow: inset 0 0 0 2px var(--btp-primary, #212f59) !important; }
html:not(#btp-f1):not(#btp-f2) body form :is(input[type=checkbox], input[type=radio]):not(.btp-ck-row input):focus-visible { outline: 2px solid var(--btp-f-cream) !important; outline-offset: 3px !important; }
html:not(#btp-f1):not(#btp-f2) body form :is(input[type=checkbox], input[type=radio])[aria-invalid="true"] { border-color: var(--btp-f-red) !important; }
/* Catégories de /contact/ (radios en mots) : comme les filtres A, actif crème souligné de bordeaux. */
html:not(#btp-f1):not(#btp-f2) body .btp-form-categories { column-gap: 22px !important; row-gap: 0 !important; }
html:not(#btp-f1):not(#btp-f2) body .btp-form-cat-label {
    display: inline-block !important; min-height: 44px; padding: max(0.3em, calc((44px - 1.2em) / 2)) 0 !important; line-height: 1.2 !important;
    background: transparent !important; border: 0 !important; border-radius: 0 !important; box-shadow: none !important;
    font-family: var(--btp-fd) !important; font-size: var(--btp-t6) !important; font-weight: 400 !important; letter-spacing: var(--btp-a-ls, 0.1em) !important; text-transform: uppercase !important;
    color: rgba(237, 240, 247, 0.62) !important; text-decoration: underline !important; text-decoration-color: transparent !important; text-decoration-thickness: 3px !important; text-underline-offset: 0.32em !important; text-decoration-skip-ink: none !important;
}
html:not(#btp-f1):not(#btp-f2) body .btp-form-cat-label > span { font: inherit !important; letter-spacing: inherit !important; text-transform: inherit !important; color: inherit !important; }
html:not(#btp-f1):not(#btp-f2) body .btp-form-cat-label .btp-form-cat-num { display: inline-block; font-size: 0.7em !important; text-decoration: none; margin-right: 0.35em; color: var(--btp-text, #8EA4B8) !important; }
html:not(#btp-f1):not(#btp-f2) body .btp-form-cat:hover .btp-form-cat-label { color: var(--btp-f-text) !important; text-decoration-color: rgba(245, 230, 211, 0.35) !important; background: transparent !important; }
html:not(#btp-f1):not(#btp-f2) body .btp-form-cat input:checked + .btp-form-cat-label { color: var(--btp-f-cream) !important; text-decoration-color: var(--btp-f-red) !important; background: transparent !important; }
html:not(#btp-f1):not(#btp-f2) body .btp-form-cat input:checked + .btp-form-cat-label .btp-form-cat-num { color: var(--btp-f-cream) !important; }
html:not(#btp-f1):not(#btp-f2) body .btp-form-cat input:focus-visible + .btp-form-cat-label { outline: 2px solid var(--btp-f-cream) !important; outline-offset: 4px !important; }

/* ---------- Fichier ---------- */
html:not(#btp-f1):not(#btp-f2) body form input[type=file] { font-family: var(--btp-fb); font-size: var(--btp-t5); color: var(--btp-f-text); border-bottom: 2px solid var(--btp-f-line); padding: 0.5em 0; background: transparent; }
html:not(#btp-f1):not(#btp-f2) body form input[type=file]::file-selector-button {
    margin-right: 1em; padding: 0.35em 0; background: transparent; border: 0; border-radius: 0; cursor: pointer;
    font-family: var(--btp-fd); font-size: var(--btp-t6); letter-spacing: var(--btp-a-ls, 0.1em); text-transform: uppercase; color: var(--btp-f-cream);
    text-decoration: underline; text-decoration-color: var(--btp-f-red); text-decoration-thickness: 3px; text-underline-offset: 0.32em;
}

/* ---------- Libellés visibles (sélecteurs des pages espaces) ---------- */
html:not(#btp-f1):not(#btp-f2) body .btpv-sel > span { font-family: var(--btp-fb) !important; font-size: var(--btp-t5) !important; font-weight: 600 !important; letter-spacing: var(--btp-ls-caps, 0.16em) !important; text-transform: uppercase !important; color: rgba(237, 240, 247, 0.8) !important; }
html:not(#btp-f1):not(#btp-f2) body .btpv-sel { background: transparent !important; border: 0 !important; border-radius: 0 !important; padding: 0 !important; }

/* ---------- Conteneurs en pilule (newsletter, contact de l'accueil) : plus de cadre ---------- */
html:not(#btp-f1):not(#btp-f2) body :is(.btp-newsletter-inline, .btp-contact-inline) { background: transparent !important; border: 0 !important; border-radius: 0 !important; box-shadow: none !important; }
html:not(#btp-f1):not(#btp-f2) body .btp-newsletter-inline { align-items: flex-end !important; gap: 0 18px !important; flex-wrap: wrap !important; }
html:not(#btp-f1):not(#btp-f2) body .btp-newsletter-inline input { flex: 1 1 12em !important; }
html:not(#btp-f1):not(#btp-f2) body .btp-contact-inline { flex-wrap: wrap; }

/* ---------- Messages d'erreur (js/btp-forms.js) ---------- */
html:not(#btp-f1):not(#btp-f2) body .btp-f-err {
    display: block; flex-basis: 100%; grid-column: 1 / -1; margin: 0.4em 0 0.6em !important; padding: 0 0 0 0.75em !important; border-left: 3px solid var(--btp-f-red);
    font-family: var(--btp-fb) !important; font-size: var(--btp-t5) !important; line-height: var(--btp-lh-5, 1.5) !important; font-weight: 500 !important; letter-spacing: 0 !important; text-transform: none !important; text-align: left !important;
    color: var(--btp-f-cream) !important; background: transparent !important;
}

/* Rangées à deux champs : une colonne sous 600 px, sans placeholder tronqué (/carte/). */
@media (max-width: 600px) { html:not(#btp-f1):not(#btp-f2) body :is(.btp-form-row, .btp-form-logo-row) { grid-template-columns: 1fr !important; } }

/* Bouton d'envoi en logo : jamais de mot coupé (traits d'union conditionnels, CJK) ; passage à la ligne entre deux mots, largeur bornée au formulaire. */
html:not(#btp-f1):not(#btp-f2) body .btp-btn-logo-submit { flex-wrap: wrap !important; max-width: 100% !important; box-sizing: border-box !important; row-gap: 0.2em !important; }
html:not(#btp-f1):not(#btp-f2) body .btp-btn-logo-submit .btp-submit-word { white-space: nowrap !important; -webkit-hyphens: none !important; hyphens: none !important; word-break: keep-all !important; overflow-wrap: normal !important; }
