/* Formulaire d'adhésion en ligne — FEDEPSAD (mobile first, charte PSAD) */
.adh {
	--adh-blue: #003399;
	--adh-teal: #00B0A9;
	--adh-teal-dark: #00807b;
	--adh-orange: #f28d01;
	--adh-ink: #1d2433;
	--adh-muted: #5b6472;
	--adh-line: #cfd7df;
	--adh-soft: #f3f7f8;
	--adh-err: #b42318;
	--adh-ok: #067647;
	font-family: 'Sora', Arial, sans-serif;
	color: var(--adh-ink);
	max-width: 960px;
	margin: 0 auto;
	padding: 28px 16px 48px;
	box-sizing: border-box;
	font-size: 15px;
	line-height: 1.5;
}
.adh *, .adh *::before, .adh *::after { box-sizing: border-box; }
.adh [hidden] { display: none !important; }

.adh-hero { margin-bottom: 20px; }
.adh-kicker { color: var(--adh-teal-dark); font-weight: 700; text-transform: uppercase; letter-spacing: .08em; font-size: 12px; margin: 0 0 4px; }
.adh-hero h2 { color: var(--adh-blue); font-size: 24px; line-height: 1.25; margin: 0 0 8px; }
.adh-hero p { margin: 0; color: var(--adh-muted); }

/* --- progression --- */
.adh-progress { position: sticky; top: var(--adh-sticky-top, 0px); z-index: 20; background: #fff; padding: 10px 0 8px; margin-bottom: 14px; border-bottom: 1px solid #eef1f4; }
.adh-stepper { display: flex; list-style: none; margin: 0 0 8px; padding: 0; gap: 4px; }
.adh-stepper li { flex: 1; margin: 0; padding: 0; }
.adh-stepper li::before { display: none; }
.adh-stepper-btn { width: 100%; background: none; border: 0; padding: 4px 0; display: flex; flex-direction: column; align-items: center; gap: 2px; color: var(--adh-muted); font: inherit; font-size: 11px; cursor: default; }
.adh-stepper-btn:not([disabled]) { cursor: pointer; }
.adh-stepper-n { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; border: 2px solid var(--adh-line); font-weight: 700; background: #fff; }
.adh-stepper li.is-done .adh-stepper-n { background: var(--adh-teal); border-color: var(--adh-teal); color: #fff; }
.adh-stepper li.is-current .adh-stepper-n { border-color: var(--adh-blue); color: var(--adh-blue); }
.adh-stepper li.is-current .adh-stepper-l { color: var(--adh-blue); font-weight: 700; }
.adh-stepper-l { display: none; }
.adh-bar { height: 6px; background: #e6ebef; border-radius: 3px; overflow: hidden; }
.adh-bar span { display: block; height: 100%; width: 0; background: linear-gradient(90deg, #0F4490, #0492A2, #00B0A9); transition: width .3s; }
.adh-meta { margin: 6px 0 0; font-size: 12.5px; color: var(--adh-muted); }
#adh-saved.is-ok { color: var(--adh-ok); }

/* --- cartes & grilles --- */
.adh-step-title { scroll-margin-top: 160px; font-size: 21px; color: var(--adh-blue); margin: 8px 0 14px; outline: none; }
.adh-step-title span { display: block; font-size: 12px; color: var(--adh-teal-dark); text-transform: uppercase; letter-spacing: .06em; }
.adh-card { background: #fff; border: 1px solid #e3e8ed; border-radius: 10px; padding: 18px 16px; margin-bottom: 16px; box-shadow: 0 1px 2px rgba(17, 25, 38, .04); }
.adh-card-title { font-size: 16px; color: var(--adh-blue); margin: 0 0 4px; padding-left: 10px; border-left: 4px solid var(--adh-teal); }
.adh-intro { color: var(--adh-muted); font-size: 14px; margin: 6px 0 4px; }
.adh-grid { display: flex; flex-wrap: wrap; margin: 0 -8px; }
.adh-f { padding: 0 8px; margin: 12px 0 0; width: 100%; min-width: 0; border: 0; position: relative; }
fieldset.adh-f { padding: 0 8px; margin: 12px 0 0; }
.adh-w-quarter { width: 50%; }
.adh-f-heading { margin-top: 18px; }
.adh-subhead { font-size: 14px; color: var(--adh-blue); margin: 0; font-weight: 700; }

.adh label, .adh legend { display: block; font-weight: 600; font-size: 14px; margin: 0 0 5px; color: var(--adh-ink); padding: 0; }
.adh legend { float: left; width: 100%; }
.adh fieldset > *:not(legend) { clear: both; }
.adh-depts { width: 100%; }
.adh-req { color: var(--adh-err); }
.adh-f > label { padding-right: 30px; }
.adh input[type=text], .adh input[type=email], .adh input[type=tel], .adh input[type=url], .adh input[type=date],
.adh input[type=search], .adh select, .adh textarea {
	display: block; width: 100%; min-height: 46px; padding: 10px 12px; font: inherit; font-size: 16px; color: var(--adh-ink);
	background: #fff; border: 1.5px solid var(--adh-line); border-radius: 7px; -webkit-appearance: none; appearance: none; line-height: 1.3;
}
.adh select { background-image: linear-gradient(45deg, transparent 50%, #5b6472 50%), linear-gradient(135deg, #5b6472 50%, transparent 50%); background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 34px; }
.adh textarea { min-height: 90px; resize: vertical; }
.adh input:focus, .adh select:focus, .adh textarea:focus { outline: none; border-color: var(--adh-blue); box-shadow: 0 0 0 3px rgba(0, 51, 153, .18); }
.adh :focus-visible { outline: 3px solid rgba(0, 51, 153, .45); outline-offset: 2px; }
.adh-f.is-invalid input, .adh-f.is-invalid select, .adh-f.is-invalid textarea { border-color: var(--adh-err); background: #fff8f7; }
.adh-f.is-valid input { border-color: #7cc7a6; }
.adh-error { color: var(--adh-err); font-size: 13px; margin: 5px 0 0; font-weight: 600; }
.adh-hint { color: var(--adh-muted); font-size: 12.5px; margin: 5px 0 0; }
.adh-help { background: #eef7f7; border-left: 3px solid var(--adh-teal); padding: 8px 10px; font-size: 13px; color: #24414a; margin: 6px 0; border-radius: 0 6px 6px 0; }
.adh-help-btn { display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; border: 1.5px solid var(--adh-teal-dark); color: var(--adh-teal-dark); background: #fff; font: 700 12px/1 Arial, sans-serif; cursor: pointer; padding: 0; vertical-align: 1px; margin-left: 4px; position: absolute; right: 8px; top: 0; }
legend .adh-help-btn, .adh-subhead .adh-help-btn { position: static; }
.adh-badge { display: inline-block; margin-top: 5px; font-size: 11px; font-weight: 700; color: var(--adh-teal-dark); background: #e3f6f5; border-radius: 10px; padding: 2px 8px; }
.adh-badge::before { content: "✓ "; }
.adh-sugg { font-size: 13px; margin: 5px 0 0; color: var(--adh-ink); }
.adh-sugg button { color: var(--adh-blue); background: none; border: 0; padding: 0; font: inherit; font-weight: 700; text-decoration: underline; cursor: pointer; }

/* radios en pastilles, cases */
.adh-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.adh-pill { margin: 0 !important; font-weight: 500 !important; }
.adh-pill input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.adh-pill span { display: inline-block; min-width: 64px; text-align: center; padding: 10px 16px; border: 1.5px solid var(--adh-line); border-radius: 999px; cursor: pointer; background: #fff; font-size: 14px; }
.adh-pill input:checked + span { background: var(--adh-blue); border-color: var(--adh-blue); color: #fff; }
.adh-pill input:focus-visible + span { outline: 3px solid rgba(0, 51, 153, .45); outline-offset: 2px; }
.adh-checks { display: grid; grid-template-columns: 1fr; gap: 6px 18px; }
.adh-check { display: flex !important; align-items: flex-start; gap: 10px; font-weight: 500 !important; margin: 0 !important; padding: 8px 10px; border-radius: 7px; cursor: pointer; border: 1px solid transparent; }
.adh-check:hover { background: var(--adh-soft); }
.adh-check input { width: 20px; height: 20px; margin: 1px 0 0; flex: none; accent-color: var(--adh-blue); }
.adh-check-lg { border-color: #e3e8ed; background: var(--adh-soft); }
.adh-consent { margin-top: 10px; }
.adh-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.adh-chip { margin: 0 !important; font-weight: 500 !important; }
.adh-chip input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.adh-chip span { display: inline-block; padding: 6px 11px; border: 1.5px solid var(--adh-line); border-radius: 999px; font-size: 13px; cursor: pointer; background: #fff; }
.adh-chip input:checked + span { background: var(--adh-teal); border-color: var(--adh-teal); color: #fff; }
.adh-chip input:focus-visible + span { outline: 3px solid rgba(0, 51, 153, .45); outline-offset: 2px; }

/* répétables */
.adh-rep-row { border: 1px solid #e3e8ed; border-radius: 9px; padding: 4px 4px 14px; margin: 12px 0 0; background: #fbfcfd; }
.adh-rep-head { display: flex; justify-content: space-between; align-items: center; padding: 8px 8px 0; font-weight: 700; color: var(--adh-blue); font-size: 13px; }
.adh-rep-add { margin-top: 12px; }
.adh-rep-suggest:empty { display: none; }
.adh-rep-suggest { margin-top: 12px; padding: 10px 12px; background: #eef7f7; border-radius: 8px; font-size: 13.5px; }
.adh-rep-suggest ul { list-style: none; margin: 6px 0 0; padding: 0; }
.adh-rep-suggest li { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 5px 0; border-top: 1px solid #d6ecec; }
.adh-rep-suggest li::before { display: none; }

/* boutons */
.adh-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 48px; padding: 12px 22px; border-radius: 8px; border: 2px solid var(--adh-blue); background: var(--adh-blue); color: #fff !important; font: inherit; font-weight: 700; font-size: 15px; cursor: pointer; text-decoration: none !important; }
.adh-btn:hover { background: #0b2e8a; }
.adh-btn[disabled] { opacity: .6; cursor: progress; }
.adh-btn-ghost { background: #fff; color: var(--adh-blue) !important; }
.adh-btn-ghost:hover { background: var(--adh-soft); }
.adh-btn-cta { background: var(--adh-teal-dark); border-color: var(--adh-teal-dark); width: 100%; }
.adh-btn-cta:hover { background: #006a66; }
.adh-btn-sm { min-height: 34px; padding: 5px 12px; font-size: 13px; }
.adh-link { background: none; border: 0; padding: 0; color: var(--adh-blue); text-decoration: underline; font: inherit; font-size: 13.5px; cursor: pointer; }
.adh-nav { display: flex; justify-content: space-between; gap: 12px; margin: 20px 0 8px; flex-wrap: wrap; }
.adh-nav .adh-btn { flex: 1 1 auto; }
.adh-later { text-align: center; margin: 4px 0 0; }

/* alertes */
.adh-alert { padding: 12px 14px; border-radius: 8px; margin: 0 0 16px; font-size: 14px; }
.adh-alert-info { background: #eaf6fb; border: 1px solid #b6deef; }
.adh-alert-warn { background: #fff7e6; border: 1px solid #f6d08a; }
.adh-alert-err { background: #fdf0ef; border: 1px solid #f1b8b2; color: #7a1a12; outline: none; }
.adh-alert-err ul { margin: 6px 0 0 18px; padding: 0; }
.adh-alert-err a { color: #7a1a12; }

/* recherche entreprise */
.adh-search-card { background: linear-gradient(135deg, #f1f8fb, #eefaf9); border-color: #cfe9ea; }
.adh-search-label { font-size: 15px !important; color: var(--adh-blue) !important; }
.adh-combo { position: relative; }
.adh-combo input { padding-left: 40px !important; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' fill='none' stroke='%235b6472' stroke-width='2'%3E%3Ccircle cx='8' cy='8' r='6'/%3E%3Cpath d='m13 13 4 4'/%3E%3C/svg%3E") 13px 50% no-repeat !important; }
.adh-listbox { position: absolute; left: 0; right: 0; top: calc(100% + 4px); z-index: 30; background: #fff; border: 1px solid var(--adh-line); border-radius: 8px; box-shadow: 0 10px 30px rgba(17, 25, 38, .15); list-style: none; margin: 0; padding: 4px; max-height: 340px; overflow: auto; }
.adh-listbox li { padding: 9px 10px; border-radius: 6px; cursor: pointer; font-size: 14px; margin: 0; }
.adh-listbox li::before { display: none; }
.adh-listbox li[aria-selected=true], .adh-listbox li:hover { background: #eaf2ff; }
.adh-listbox small { display: block; color: var(--adh-muted); font-size: 12px; }
.adh-listbox .adh-empty { cursor: default; color: var(--adh-muted); }
.adh-company { margin-top: 12px; padding: 12px 14px; background: #fff; border-radius: 8px; border: 1px solid #cfe9ea; font-size: 14px; }
.adh-company strong { color: var(--adh-blue); }

/* départements */
.adh-depts-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 8px; width: 100%; }
.adh-depts-tools select { width: auto; flex: 1 1 200px; min-height: 38px; font-size: 14px; }
.adh-depts-selected { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
.adh-tag { display: inline-flex; align-items: center; gap: 4px; background: var(--adh-blue); color: #fff; border-radius: 999px; padding: 3px 4px 3px 10px; font-size: 12.5px; }
.adh-tag button { background: rgba(255, 255, 255, .2); color: #fff; border: 0; border-radius: 50%; width: 20px; height: 20px; cursor: pointer; font-size: 13px; line-height: 1; padding: 0; }
.adh-depts-list { max-height: 220px; overflow: auto; border: 1px solid #e3e8ed; border-radius: 8px; padding: 4px; display: grid; grid-template-columns: 1fr; }
.adh-depts-list .adh-check { padding: 5px 8px; font-size: 13.5px; }

/* dépôt de fichiers */
.adh-drop { border: 2px dashed #9fb2c2; border-radius: 10px; padding: 20px 14px; text-align: center; background: var(--adh-soft); cursor: pointer; display: flex; flex-direction: column; gap: 4px; min-height: 120px; justify-content: center; transition: background .15s, border-color .15s; }
.adh-drop:hover, .adh-drop.is-over { border-color: var(--adh-teal); background: #e6f7f6; }
.adh-drop strong { color: var(--adh-blue); }
.adh-drop span { font-size: 13px; color: var(--adh-muted); }
.adh-drop.has-file { border-style: solid; border-color: #7cc7a6; background: #f0faf5; }
.adh-drop-file { font-size: 13.5px; display: flex; gap: 8px; justify-content: center; align-items: center; flex-wrap: wrap; }
.adh-drop-progress { height: 6px; background: #dfe6ec; border-radius: 3px; overflow: hidden; }
.adh-drop-progress span { display: block; height: 100%; width: 0; background: var(--adh-teal); }

/* récapitulatif */
.adh-recap-sec { border-top: 1px solid #eef1f4; padding: 10px 0; }
.adh-recap-sec:first-child { border-top: 0; }
.adh-recap-sec h4 { display: flex; justify-content: space-between; align-items: baseline; margin: 0 0 6px; font-size: 14px; color: var(--adh-blue); }
.adh-recap-sec dl { margin: 0; display: grid; grid-template-columns: 1fr; gap: 2px 14px; font-size: 13.5px; }
.adh-recap-sec dt { color: var(--adh-muted); }
.adh-recap-sec dd { margin: 0 0 6px; word-break: break-word; }
.adh-recap-empty { color: #9aa3ad; }
.adh-rgpd details { margin-top: 8px; font-size: 13px; color: var(--adh-muted); }
.adh-rgpd summary { cursor: pointer; font-weight: 700; color: var(--adh-blue); }
#adh-turnstile { margin-top: 12px; }

.adh-done { text-align: center; padding: 30px 10px; outline: none; }
.adh-done-icon { width: 64px; height: 64px; margin: 0 auto 12px; border-radius: 50%; background: var(--adh-teal); color: #fff; font-size: 34px; display: grid; place-items: center; }
.adh-done h2 { color: var(--adh-blue); }

.adh-hp { position: absolute !important; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

@media (min-width: 640px) {
	.adh { padding-top: 40px; }
	.adh-card { padding: 22px 24px; }
	.adh-w-half { width: 50%; }
	.adh-w-third { width: 33.333%; }
	.adh-w-twothirds { width: 66.666%; }
	.adh-w-quarter { width: 25%; }
	.adh-checks.adh-cols-2 { grid-template-columns: 1fr 1fr; }
	.adh-depts-list { grid-template-columns: 1fr 1fr 1fr; }
	.adh-stepper-btn { font-size: 12px; }
	.adh-stepper-l { display: block; }
	.adh-recap-sec dl { grid-template-columns: minmax(180px, 40%) 1fr; }
	.adh-recap-sec dd { margin: 0; }
	.adh-nav .adh-btn { flex: 0 0 auto; }
	.adh-btn-cta { width: auto; }
	.adh-hero h2 { font-size: 28px; }
}

@media (prefers-reduced-motion: reduce) {
	.adh * { transition: none !important; scroll-behavior: auto !important; }
}
