/* Formulaire de demande : publié seulement quand config.json branche le service (demande_api).
   La case d'autorisation et le message d'état restent dans la couleur de leur panneau. */

.register-form .autorisation { display: flex; gap: var(--s-3); align-items: center; min-height: 44px; margin-top: var(--s-2); }
.register-form .autorisation input[type="checkbox"] { flex: none; width: 20px; height: 20px; margin: 0; accent-color: var(--accent-fill); cursor: pointer; }
.register-form .autorisation label { display: flex; align-items: center; min-height: 44px; font-size: var(--text-small); line-height: 1.4; cursor: pointer; }
.register-form input[aria-invalid="true"] { border-width: 2px; border-color: var(--accent); }
.register-form .autorisation input[aria-invalid="true"] { outline: 2px solid var(--focus); outline-offset: 3px; }

/* Champ piège : hors de la vue et de l'arbre d'accessibilité ; un robot le remplit, pas vous. */
.piege { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }

.demande-etat { font-size: var(--text-body); line-height: 1.55; margin-top: var(--s-1); }
/* Vide, la zone reste dans l'arbre d'accessibilité (une zone role="status" doit exister avant
   son message) ; hors du flux, elle n'ajoute aucun espace. */
.demande-etat:empty { position: absolute; margin: 0; }
.demande-etat[data-niveau="erreur"] { border-left: 3px solid var(--accent); padding-left: var(--s-3); }
.demande-etat:focus { outline: none; }
.demande-form[aria-busy="true"] .button { opacity: .75; cursor: progress; }

/* Demande reçue : seul le message reste, à la place du titre et des champs, en serif, comme une
   phrase du rapport. */
.demande-form[data-etat="envoye"] > :not(.demande-etat) { display: none; }
.form-panel:has(.demande-form[data-etat="envoye"]) .form-title { display: none; }
.demande-form[data-etat="envoye"] .demande-etat { font: 400 clamp(20px, 1.8vw, 24px)/1.35 var(--serif); letter-spacing: -.005em; margin: 0; font-optical-sizing: auto; }

/* Le résumé du prestataire d'IA, replié sous le formulaire. */
.etape-plan { font-size: var(--text-small); line-height: 1.55; color: var(--ink-2); }
.etape-plan > summary { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--s-3); min-height: 44px; padding-block: var(--s-2); color: var(--ink); touch-action: manipulation; }
.etape-plan p { margin-top: var(--s-1); }
.etape-plan a { color: var(--ink); }
