/* =====================================================================
   JOSPIA 2026 - Formulaires d'inscription (design premium)
   Chargé après theme.css
   ===================================================================== */
.form-page { position: relative; overflow: hidden; padding-top: 34px; padding-bottom: 70px;
    background:
        radial-gradient(520px 320px at 8% 4%, rgba(247,127,0,.13), transparent 70%),
        radial-gradient(560px 360px at 96% 30%, rgba(11,138,78,.13), transparent 70%),
        radial-gradient(420px 300px at 30% 100%, rgba(247,127,0,.09), transparent 70%),
        linear-gradient(180deg, #fffaf3 0%, #fff 45%, #f3fbf6 100%); }
.form-page::before, .form-page::after { content: ""; position: absolute; border-radius: 50%; pointer-events: none; filter: blur(2px); z-index: 0; }
.form-page::before { width: 280px; height: 280px; top: -90px; right: 12%; border: 34px solid rgba(247,127,0,.10); animation: fpFlotte 14s ease-in-out infinite; }
.form-page::after { width: 200px; height: 200px; bottom: 40px; left: -60px; border: 26px solid rgba(11,138,78,.10); animation: fpFlotte 17s ease-in-out infinite reverse; }
@keyframes fpFlotte { 50% { transform: translate(18px, 26px) scale(1.06); } }
.form-page .container { position: relative; z-index: 1; }

.form-layout { display: grid; grid-template-columns: 340px minmax(0, 1fr); gap: 34px; align-items: start; max-width: 1140px; margin: 0 auto; }

/* ---------- Panneau latéral ---------- */
.form-aside { position: sticky; top: 92px; animation: fpEntree .7s var(--ease, ease) both; }
.fa-card { position: relative; border-radius: 26px; padding: 30px 26px 24px; color: #fff; overflow: hidden;
    background: radial-gradient(130% 90% at 100% 0%, rgba(255,157,51,.55), transparent 55%),
                linear-gradient(160deg, #0B8A4E 0%, #06532F 75%);
    box-shadow: 0 28px 60px -22px rgba(6,83,47,.65), 0 2px 0 rgba(255,255,255,.25) inset; }
.fa-card::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 6px; background: var(--tricolore); }
.fa-card::after { content: ""; position: absolute; width: 240px; height: 240px; right: -90px; bottom: -90px; border-radius: 50%;
    border: 38px solid rgba(255,255,255,.07); }
.fa-arche { width: 74px; height: 88px; border-radius: 37px 37px 14px 14px; margin-bottom: 18px; display: grid; place-items: center;
    background: linear-gradient(180deg, #fff, #ffe9cf); box-shadow: 0 14px 30px -10px rgba(0,0,0,.4), 0 0 0 5px rgba(255,255,255,.18); animation: fpBob 4s ease-in-out infinite; }
.fa-arche span { font-size: 2rem; }
@keyframes fpBob { 50% { transform: translateY(-6px); } }
.fa-tag { display: inline-block; font-size: .7rem; font-weight: 700; letter-spacing: .16em; background: rgba(255,255,255,.16); padding: 5px 12px; border-radius: 99px; margin-bottom: 10px; }
.fa-card h3 { color: #fff; font-size: 1.45rem; line-height: 1.15; margin: 0 0 6px; }
.fa-sous { color: rgba(255,255,255,.85); font-size: .9rem; margin: 0 0 20px; }
.fa-progress { background: rgba(255,255,255,.12); border-radius: 16px; padding: 12px 14px; margin-bottom: 20px; backdrop-filter: blur(4px); }
.fa-progress__top { display: flex; justify-content: space-between; align-items: baseline; font-size: .8rem; margin-bottom: 8px; }
.fa-progress__top b { font-family: var(--police-titre); font-size: 1.25rem; color: #FFD9A3; font-variant-numeric: tabular-nums; }
.fa-progress__bar { height: 9px; border-radius: 9px; background: rgba(0,0,0,.25); overflow: hidden; }
.fa-progress__bar i { display: block; height: 100%; width: 0; border-radius: 9px; transition: width .6s cubic-bezier(.22,1,.36,1);
    background: linear-gradient(90deg, var(--orange), #FFC56B); background-size: 200% 100%; animation: fpBrille 2.4s linear infinite; }
@keyframes fpBrille { to { background-position: -200% 0; } }
.fa-etapes { list-style: none; margin: 0 0 18px; padding: 0; position: relative; }
.fa-etapes::before { content: ""; position: absolute; left: 15px; top: 18px; bottom: 18px; width: 2px; background: rgba(255,255,255,.22); }
.fa-etapes li { display: flex; gap: 14px; align-items: flex-start; padding: 9px 0; position: relative; opacity: .8; }
.fa-etapes li > span { flex: none; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: .88rem;
    background: #0a6a3c; border: 2px solid rgba(255,255,255,.4); z-index: 1; }
.fa-etapes li.en-cours { opacity: 1; }
.fa-etapes li.en-cours > span { background: var(--orange); border-color: #fff; box-shadow: 0 0 0 0 rgba(247,127,0,.7); animation: fpPouls 2s infinite; }
@keyframes fpPouls { 70% { box-shadow: 0 0 0 11px rgba(247,127,0,0); } 100% { box-shadow: 0 0 0 0 rgba(247,127,0,0); } }
.fa-etapes b { display: block; font-size: .95rem; line-height: 1.2; }
.fa-etapes small { color: rgba(255,255,255,.75); font-size: .78rem; }
.fa-secu { font-size: .8rem; color: rgba(255,255,255,.85); padding-top: 14px; border-top: 1px dashed rgba(255,255,255,.3); position: relative; z-index: 1; }

/* ---------- Titre ---------- */
.form-main { min-width: 0; }
.form-titre { text-align: left; margin-bottom: 22px; animation: fpEntree .6s .05s var(--ease, ease) both; }
.form-titre h2 { font-size: clamp(1.7rem, 3.4vw, 2.4rem); margin: 6px 0 6px; position: relative; display: inline-block; }
.form-titre h2::after { content: ""; display: block; height: 5px; width: 64%; margin-top: 8px; border-radius: 5px; background: linear-gradient(90deg, var(--orange), var(--vert)); }
.form-intro { color: var(--texte-doux); margin: 10px 0 0; font-size: .95rem; }
.form-intro .req { color: var(--orange-fonce); font-weight: 700; }

/* ---------- Formulaire ---------- */
.form-pro { counter-reset: etape; }
.form-pro fieldset { position: relative; border: 1px solid rgba(11,138,78,.14); border-radius: 22px; background: rgba(255,255,255,.92);
    padding: 26px 28px 12px; margin: 0 0 22px; min-width: 0;
    box-shadow: 0 1px 0 #fff inset, 0 18px 44px -24px rgba(6,83,47,.35), 0 4px 10px -6px rgba(6,83,47,.12);
    overflow: hidden; }
.form-pro fieldset::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 5px; background: linear-gradient(180deg, var(--orange), var(--vert)); }
.form-pro fieldset:focus-within { border-color: rgba(247,127,0,.5); transform: translateY(-2px);
    box-shadow: 0 1px 0 #fff inset, 0 26px 54px -24px rgba(247,127,0,.4), 0 4px 10px -6px rgba(6,83,47,.12); }
.form-pro legend { background: none !important; box-shadow: none !important; float: left; width: 100%; padding: 0; margin: 0 0 20px; display: flex; align-items: center; gap: 12px;
    font-size: 1.18rem; color: var(--vert-fonce); counter-increment: etape; }
.form-pro legend + * { clear: both; }
.form-pro legend::before { content: counter(etape); flex: none; width: 36px; height: 36px; border-radius: 12px; display: grid; place-items: center;
    font-family: var(--police-titre); font-size: 1rem; font-weight: 800; color: #fff; transform: rotate(-6deg);
    background: linear-gradient(135deg, var(--orange-clair), var(--orange-fonce)); box-shadow: 0 8px 16px -6px rgba(247,127,0,.6); transition: all .4s; }
.form-pro fieldset.ok legend::before { content: "✓"; background: linear-gradient(135deg, var(--vert-vif), var(--vert-fonce)); transform: rotate(0) scale(1.05); box-shadow: 0 8px 16px -6px rgba(11,138,78,.6); }
.form-pro .form-row { gap: 18px; }
.form-pro .form-group { margin-bottom: 18px; }
.form-pro label { font-size: .84rem; font-weight: 700; letter-spacing: .01em; color: var(--vert-fonce); margin-bottom: 7px; }
.form-pro label .req { color: var(--orange-fonce); }

/* champs */
.form-pro input[type=text], .form-pro input[type=tel], .form-pro input[type=number], .form-pro select {
    height: 52px; padding: 0 16px; border: 2px solid #E4ECE7; border-radius: 14px; background-color: #FAFCFB; font-size: 1rem; color: #16261d;
    transition: border-color .2s, box-shadow .25s, background-color .2s, transform .2s; }
.form-pro input[type=text], .form-pro input[type=tel], .form-pro input[type=number] {
    padding-left: 46px; background-repeat: no-repeat; background-position: 15px center; background-size: 20px; }
.form-pro input::placeholder { color: #A3B2A9; }
.form-pro input:hover, .form-pro select:hover { border-color: #BFD8C9; background-color: #fff; }
.form-pro input:focus, .form-pro select:focus { border-color: var(--orange); background-color: #fff; box-shadow: 0 0 0 5px rgba(247,127,0,.15), 0 10px 22px -12px rgba(247,127,0,.55); }
.form-pro input:user-valid:not(:placeholder-shown):not(:focus) { border-color: rgba(18,168,98,.7); }
.form-pro input:user-invalid:not(:focus), .form-pro select:user-invalid:not(:focus) { border-color: #e5484d; background-color: #fff7f7; }
.form-pro input[type=number] { -moz-appearance: textfield; } .form-pro input[type=number]::-webkit-inner-spin-button { opacity: .4; }
.form-pro select { appearance: none; -webkit-appearance: none; cursor: pointer; padding-right: 46px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23F77F00' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 16px center; background-size: 18px; }

/* genre : cartes sélectionnables */
.form-pro .radio-group { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding: 0; }
.form-pro .radio-group label { position: relative; margin: 0; height: 52px; justify-content: center; border: 2px solid #E4ECE7; border-radius: 14px; background: #FAFCFB;
    cursor: pointer; font-weight: 600; color: #3b4d43; transition: all .25s; gap: 8px; }
.form-pro .radio-group label:hover { border-color: var(--orange-clair); background: #fff; transform: translateY(-2px); }
.form-pro .radio-group input { position: absolute; opacity: 0; pointer-events: none; }
.form-pro .radio-group label:has(input:checked) { border-color: var(--vert); color: #fff; background: linear-gradient(135deg, var(--vert-vif), var(--vert-fonce)); box-shadow: 0 12px 22px -12px rgba(11,138,78,.8); }
.form-pro .radio-group label:has(input:checked)::before { content: "✓"; font-weight: 800; }
.form-pro .radio-group label:has(input:focus-visible) { outline: 3px solid var(--orange); outline-offset: 2px; }

/* photo */
.form-pro input[type=file] { height: auto; padding: 26px 16px; border: 2px dashed #9ED2B6; border-radius: 18px; cursor: pointer; text-align: center;
    background: repeating-linear-gradient(135deg, #F4FBF7 0 12px, #EDF8F2 12px 24px); color: var(--vert-fonce); font-weight: 600; font-size: .92rem; }
.form-pro input[type=file]:hover { border-color: var(--orange); background: var(--orange-teinte); }
.form-pro input[type=file]::file-selector-button { margin-right: 14px; border: 0; padding: 11px 20px; border-radius: 99px; cursor: pointer; font-weight: 700; color: #fff; font-family: inherit;
    background: linear-gradient(135deg, var(--orange-clair), var(--orange-fonce)); box-shadow: 0 10px 18px -8px rgba(247,127,0,.7); transition: transform .2s; }
.form-pro input[type=file]::file-selector-button:hover { transform: translateY(-2px) scale(1.04); }
.form-pro .photo-actions { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 12px; }
.form-pro .photo-actions .photo-ou { color: var(--texte-doux); font-size: .85rem; }
.form-pro .photo-actions .btn { border-radius: 99px; border-color: var(--vert); color: var(--vert-fonce); font-weight: 700; }
#apercu-photo { width: 120px; height: 120px; object-fit: cover; margin: 16px auto 4px; border-radius: 50%; border: 4px solid #fff;
    box-shadow: 0 0 0 4px var(--orange), 0 18px 30px -12px rgba(0,0,0,.4); animation: fpPop .5s cubic-bezier(.34,1.56,.64,1); }
.form-page #apercu-photo[style*="block"] { display: block; }
@keyframes fpPop { from { transform: scale(.4); opacity: 0; } }

.form-pro .help-text { font-size: .8rem; color: #5d7266; background: var(--vert-teinte); border-left: 3px solid var(--vert); padding: 9px 12px; border-radius: 0 10px 10px 0; margin: 10px 0 14px; line-height: 1.45; }
.form-pro .form-group > .help-text { margin-top: 10px; }

/* bouton d'envoi */
.form-pro .btn-envoi { position: relative; overflow: hidden; display: flex; align-items: center; justify-content: center; gap: 14px; height: 62px; border: 0; border-radius: 18px;
    font-size: 1.08rem; font-weight: 700; color: #fff; cursor: pointer; letter-spacing: .01em;
    background: linear-gradient(120deg, var(--orange) 0%, var(--orange-fonce) 50%, var(--orange) 100%); background-size: 200% 100%;
    box-shadow: 0 22px 36px -16px rgba(247,127,0,.85), 0 2px 0 rgba(255,255,255,.35) inset; transition: transform .25s, box-shadow .25s, background-position .6s; }
.form-pro .btn-envoi::before { content: ""; position: absolute; top: 0; bottom: 0; width: 60px; left: -90px; transform: skewX(-20deg); background: rgba(255,255,255,.35); animation: fpReflet 3.4s infinite; }
@keyframes fpReflet { 0%, 55% { left: -90px; } 100% { left: 120%; } }
.form-pro .btn-envoi i { font-style: normal; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: #fff; color: var(--orange-fonce); font-weight: 800; transition: transform .3s; }
.form-pro .btn-envoi:hover { transform: translateY(-3px); background-position: 100% 0; box-shadow: 0 28px 40px -16px rgba(247,127,0,.95); }
.form-pro .btn-envoi:hover i { transform: translateX(6px); }
.form-pro .btn-envoi:active { transform: translateY(0) scale(.99); }
.form-note { text-align: center; color: var(--texte-doux); font-size: .84rem; margin: 14px 0 0; }

@keyframes fpEntree { from { opacity: 0; transform: translateY(22px); } }

/* ---------- Tablette / mobile ---------- */
@media (max-width: 960px) {
    .form-layout { grid-template-columns: 1fr; gap: 22px; }
    .form-aside { position: static; }
    .fa-card { padding: 22px 20px 18px; }
    .fa-arche, .fa-sous, .fa-etapes, .fa-secu { display: none; }
    .fa-card h3 { font-size: 1.2rem; }
    .fa-progress { margin: 10px 0 0; }
    .form-titre { text-align: center; }
}
@media (max-width: 600px) {
    .form-page { padding-top: 18px; }
    .form-pro fieldset { padding: 22px 16px 6px; border-radius: 18px; }
    .form-pro .form-row { grid-template-columns: 1fr; gap: 0; }
    .form-pro legend { font-size: 1.05rem; }
    .form-pro .btn-envoi { height: 58px; font-size: 1rem; padding: 0 14px; }
    .form-pro .btn-envoi span { text-align: left; line-height: 1.15; }
    .form-pro input[type=file]::file-selector-button { display: block; margin: 0 auto 10px; }
}
@media (prefers-reduced-motion: reduce) {
    .form-page *, .form-page::before, .form-page::after { animation: none !important; transition: none !important; }
}

/* icônes des champs */
.form-pro input[name=nom_prenoms] { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230B8A4E' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='8' r='4'/%3E%3Cpath d='M4 21c0-4.4 3.6-7 8-7s8 2.6 8 7'/%3E%3C/svg%3E"); }
.form-pro input[name=parent_nom] { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230B8A4E' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='8' r='4'/%3E%3Cpath d='M4 21c0-4.4 3.6-7 8-7s8 2.6 8 7'/%3E%3C/svg%3E"); }
.form-pro input[name=contact] { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230B8A4E' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 4h4l2 5-2.5 1.5a11 11 0 0 0 5 5L15 13l5 2v4a2 2 0 0 1-2 2A16 16 0 0 1 3 6a2 2 0 0 1 2-2z'/%3E%3C/svg%3E"); }
.form-pro input[name=parent_contact] { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230B8A4E' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 4h4l2 5-2.5 1.5a11 11 0 0 0 5 5L15 13l5 2v4a2 2 0 0 1-2 2A16 16 0 0 1 3 6a2 2 0 0 1 2-2z'/%3E%3C/svg%3E"); }
.form-pro input[name=reference_transaction] { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230B8A4E' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 4h4l2 5-2.5 1.5a11 11 0 0 0 5 5L15 13l5 2v4a2 2 0 0 1-2 2A16 16 0 0 1 3 6a2 2 0 0 1 2-2z'/%3E%3C/svg%3E"); }
.form-pro input[name=niveau_etude] { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230B8A4E' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2 9l10-5 10 5-10 5z'/%3E%3Cpath d='M6 11.5V16c3 2.5 9 2.5 12 0v-4.5'/%3E%3C/svg%3E"); }
.form-pro input[name=lieu_residence] { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230B8A4E' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 21s-7-6.2-7-11a7 7 0 0 1 14 0c0 4.8-7 11-7 11z'/%3E%3Ccircle cx='12' cy='10' r='2.5'/%3E%3C/svg%3E"); }
.form-pro input[name=age] { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230B8A4E' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3.5' y='5' width='17' height='15' rx='2.5'/%3E%3Cpath d='M8 3v4M16 3v4M3.5 10h17'/%3E%3C/svg%3E"); }
.form-pro input[name=parent_lien] { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230B8A4E' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='9' cy='8' r='3.5'/%3E%3Cpath d='M2.5 20c0-3.6 2.9-6 6.5-6s6.5 2.4 6.5 6'/%3E%3Cpath d='M16 4.6a3.5 3.5 0 0 1 0 6.8M18 14.4c2 .7 3.5 2.6 3.5 5.6'/%3E%3C/svg%3E"); }
.form-pro input[name=section_autre] { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230B8A4E' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 21V4M5 4h11l-2 4 2 4H5'/%3E%3C/svg%3E"); }
.form-pro input[name=maladie_autre] { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230B8A4E' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 20s-8-4.8-8-11a4.5 4.5 0 0 1 8-2.8A4.5 4.5 0 0 1 20 9c0 6.2-8 11-8 11z'/%3E%3C/svg%3E"); }
.form-pro select[name=commission], .form-pro select[name=anyama], .form-pro select[name=section], .form-pro select[name=maladie] { }

.form-pro input[name=identifiant] { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230B8A4E' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='8' r='4'/%3E%3Cpath d='M4 21c0-4.4 3.6-7 8-7s8 2.6 8 7'/%3E%3C/svg%3E"); }
.form-pro input[name=mot_de_passe] { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230B8A4E' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='4' y='10.5' width='16' height='10' rx='2.5'/%3E%3Cpath d='M8 10.5V8a4 4 0 0 1 8 0v2.5'/%3E%3C/svg%3E"); }
.form-pro input[name=matricule], .form-pro input[name=reference_transaction] { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230B8A4E' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 3L7 21M17 3l-2 18M4 9h17M3 15h17'/%3E%3C/svg%3E"); }
.form-pro input[type=password] { height: 52px; padding: 0 16px 0 46px; border: 2px solid #E4ECE7; border-radius: 14px; background-color: #FAFCFB; background-repeat: no-repeat; background-position: 15px center; background-size: 20px; font-size: 1rem; transition: border-color .2s, box-shadow .25s; }
.form-pro input[type=password]:focus { border-color: var(--orange); box-shadow: 0 0 0 5px rgba(247,127,0,.15); outline: 0; }
.login-page { padding: 40px 0 70px; min-height: 70vh; display: flex; align-items: center; }
.login-page .container { width: 100%; }
.login-page .login-box, .form-page .carte.form-pro { background: rgba(255,255,255,.95); box-shadow: 0 30px 60px -28px rgba(6,83,47,.5); }

.form-pro input[type=datetime-local], .form-pro input[type=date] { width: 100%; height: 52px; padding: 0 16px; border: 2px solid #E4ECE7; border-radius: 14px; background-color: #FAFCFB; font-size: 1rem; font-family: inherit; color: #16261d; }
.form-pro input[type=datetime-local]:focus { border-color: var(--orange); box-shadow: 0 0 0 5px rgba(247,127,0,.15); outline: 0; }
.form-pro input[name=heure_arrivee], .form-pro input[name=heure_sortie] { padding-left: 16px; }
.form-pro legend[data-ico]::before { content: attr(data-ico); font-size: 1.2rem; transform: none; }
.form-pro input[name=motif] { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230B8A4E' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 21V4M5 4h11l-2 4 2 4H5'/%3E%3C/svg%3E"); }

.liste-sortie { max-height: 340px; overflow-y: auto; border: 2px solid #E4ECE7; border-radius: 14px; background: #FAFCFB; }
.ligne-sortie { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 11px 14px; border-bottom: 1px solid #E4ECE7; }
.ligne-sortie:last-child { border-bottom: 0; }
.ligne-sortie small { display: block; color: var(--texte-doux); font-size: .78rem; margin-top: 2px; }
.ligne-sortie .btn { white-space: nowrap; }
@media (max-width: 480px) { .ligne-sortie { flex-direction: column; align-items: stretch; text-align: left; } }
.form-pro #filtre-visiteurs { padding-left: 16px; }

/* Message flottant (opérations sans rechargement) */
.jos-toast { position: fixed; top: 84px; right: 18px; z-index: 9999; max-width: min(380px, calc(100vw - 36px)); padding: 14px 18px; border-radius: 14px; color: #fff; font-weight: 600; font-size: .92rem;
    background: linear-gradient(135deg, var(--vert-vif), var(--vert-fonce)); box-shadow: 0 18px 40px -14px rgba(6,83,47,.7); transform: translateX(120%); opacity: 0; transition: transform .4s cubic-bezier(.22,1,.36,1), opacity .4s; }
.jos-toast.erreur { background: linear-gradient(135deg, #e5484d, #b3262b); }
.jos-toast.visible { transform: none; opacity: 1; }

.form-pro textarea { width: 100%; padding: 13px 16px; border: 2px solid #E4ECE7; border-radius: 14px; background: #FAFCFB; font-size: 1rem; font-family: inherit; color: #16261d; resize: vertical; min-height: 90px; transition: border-color .2s, box-shadow .25s; }
.form-pro textarea:focus { border-color: var(--orange); box-shadow: 0 0 0 5px rgba(247,127,0,.15); outline: 0; background: #fff; }

/* Rapport journalier : présentation en lettre */
.lettre{position:relative;background:#fff;max-width:820px;margin:0 auto 26px;padding:34px 46px 28px;border:1px solid #dfe9e2;border-radius:6px;box-shadow:0 10px 30px rgba(6,83,47,.12);font-family:"Tinos","Times New Roman",serif;font-size:1.06rem;line-height:1.7;color:#1e2621;overflow:hidden}
.lettre-bande{position:absolute;top:0;left:0;right:0;height:6px;background:linear-gradient(90deg,#f77f00 0 50%,#0b8a4e 50% 100%)}
.lettre-tete{display:flex;justify-content:space-between;gap:12px;flex-wrap:wrap;margin-bottom:18px;color:#06532f}
.lettre-tete small{color:#64706a}
.lettre-lieu{text-align:right;color:#1e2621}
.lettre-dest{margin:0 0 20px auto;width:min(300px,100%);color:#1e2621}
.lettre-dest small{color:#64706a}
.lettre-objet{border-left:5px solid #f77f00;background:#ebf7f0;padding:8px 14px;font-weight:700;color:#06532f;margin:0 0 18px}
.lettre-titre{margin:18px 0 4px;color:#06532f;font-size:1.08rem}
.lettre-p{margin:0 0 10px;overflow-wrap:anywhere;word-break:normal}
.lettre-j{text-align:justify;hyphens:auto;text-indent:2.2em}
.lettre-sign{text-align:right;margin:20px 0 6px}
.lettre-sign strong{display:inline-block;border-bottom:3px solid #f77f00;padding-bottom:2px;color:#1e2621}
.lettre-meta{font-size:.82rem;color:#64706a;border-top:1px solid #dfe9e2;margin-top:14px;padding-top:8px;font-family:inherit}
.lettre-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:12px;padding-top:12px;border-top:1px dashed #dfe9e2}
@media(max-width:600px){.lettre{padding:26px 18px 20px;font-size:1rem}.lettre-j{text-indent:1.2em}}
.lettre-entete{text-align:center;margin:0 0 20px;padding-bottom:14px;border-bottom:3px solid transparent;border-image:linear-gradient(90deg,#f77f00 0 50%,#0b8a4e 50% 100%) 1}.lettre-entete img{max-width:100%;width:520px;height:auto}

/* ===== Back-office : adaptation à tous les écrans ===== */
html, body { max-width: 100%; } body { overflow-x: clip; }
img, video, canvas, svg { max-width: 100%; height: auto; }
.container { width: 100%; }
.carte, .table-wrap, fieldset { min-width: 0; }
pre, code { white-space: pre-wrap; word-break: break-word; }
.btn { max-width: 100%; }
@media (max-width: 1100px) {
    .container > .carte[style*="flex-wrap"] { gap: 6px !important; }
}
@media (max-width: 900px) {
    .grid-4 { grid-template-columns: 1fr 1fr; }
    .section-titre h2 { font-size: 1.55rem; }
}
@media (max-width: 760px) {
    .table-wrap { overflow: visible; background: transparent; border: 0; box-shadow: none; }
    table.rwd { min-width: 0 !important; display: block; width: 100%; background: transparent; }
    table.rwd thead { display: none; }
    table.rwd tbody, table.rwd tfoot { display: block; width: 100%; }
    table.rwd tr { display: block; width: 100%; margin: 0 0 12px; padding: 6px 14px; background: #fff; border: 1px solid var(--bordure); border-left: 4px solid var(--vert); border-radius: 14px; box-shadow: 0 4px 14px rgba(6,83,47,.07); }
    table.rwd td { display: flex; align-items: center; justify-content: space-between; gap: 14px; width: 100%; padding: 8px 0; border: 0; border-bottom: 1px dashed var(--bordure); text-align: right; overflow-wrap: anywhere; min-width: 0; }
    table.rwd td:last-child { border-bottom: 0; }
    table.rwd td::before { content: attr(data-label); flex: 0 0 36%; max-width: 36%; text-align: left; font-weight: 700; font-size: .78rem; color: var(--vert-fonce); }
    table.rwd td[data-label=""]::before { display: none; }
    table.rwd td[data-label=""] { justify-content: flex-start; flex-wrap: wrap; text-align: left; }
    table.rwd td form, table.rwd td .btn { margin: 2px 0; }
    table.rwd td img { max-width: 64px; }
    .section-titre[style*="display:flex"], .toolbar, .barre-outils { flex-direction: column; align-items: stretch !important; }
    form[style*="display:flex"] > * { max-width: 100%; }
    form[style*="display:flex"] input, form[style*="display:flex"] select { max-width: 100% !important; flex: 1 1 100%; }
    .container > .carte[style*="flex-wrap"] .btn { flex: 1 1 calc(50% - 8px); }
}
@media (max-width: 420px) {
    .container { padding: 0 12px; }
    .carte, fieldset { padding: 14px; }
    .container > .carte[style*="flex-wrap"] .btn { flex: 1 1 100%; }
    .btn-sm { padding: 9px 12px; }
    .section-titre h2 { font-size: 1.35rem; }
    table.rwd td::before { flex-basis: 40%; max-width: 40%; }
}
@media (min-width: 1500px) { .container { max-width: 1320px; } }
@media print { table.rwd { display: table !important; } table.rwd thead { display: table-header-group !important; } table.rwd tr { display: table-row !important; border: 0 !important; box-shadow: none !important; padding: 0 !important; } table.rwd td { display: table-cell !important; text-align: left !important; } table.rwd td::before { display: none !important; } }
table.rwd td { flex-wrap: wrap; }
table.rwd td .btn { white-space: nowrap; flex: none; }
@media (max-width: 1400px) and (min-width: 1001px) {
    .navbar .container { gap: 8px; }
    .nav-links a { padding: 8px 8px; font-size: .8rem; }
    .brand-text .titre { font-size: 1.05rem; }
}

/* Sorties du camp */
.pastille-menu { display: inline-block; min-width: 18px; padding: 1px 6px; margin-left: 4px; border-radius: 999px; background: #c81e1e; color: #fff; font-size: .72rem; font-weight: 800; line-height: 1.4; text-align: center; }
.alerte-sortie { position: sticky; top: 0; z-index: 60; display: flex; gap: 14px; align-items: center; justify-content: center; flex-wrap: wrap; padding: 12px 16px; background: #c81e1e; color: #fff; text-align: center; box-shadow: 0 6px 20px rgba(200,30,30,.35); animation: alerte-pulse 1.6s ease-in-out infinite; }
.alerte-sortie[hidden] { display: none; }
.alerte-sortie form { margin: 0; } .alerte-sortie .btn { background: #fff; color: #c81e1e; border: 0; }
@keyframes alerte-pulse { 50% { background: #a31515; } }
.alerte-ok { background: #0a8f3c; box-shadow: 0 6px 20px rgba(10,143,60,.3); animation: none; }

/* ---- Bandeau AEEMCI (gauche) · JOSPIA (droite) ---- */
.brand-aeemci { display: flex; align-items: center; margin-right: 12px; padding-right: 12px; border-right: 1px solid rgba(6,83,47,.18); flex: 0 0 auto; }
.brand-aeemci img { height: 46px; width: 46px; object-fit: contain; border-radius: 50%; background: #fff; transition: transform .5s ease; }
.brand-aeemci:hover img { transform: scale(1.08) rotate(6deg); }
.navbar .container { gap: 0; }
@media (max-width: 520px) { .brand-aeemci { margin-right: 8px; padding-right: 8px; } .brand-aeemci img { height: 38px; width: 38px; } }

.lien-aeemci { position: relative; overflow: hidden; background: linear-gradient(100deg, #fff 0%, #f1faf5 50%, #fff 100%); border-bottom: 1px solid #dcebe2; padding: 22px 0; }
.lien-aeemci .la-fond { position: absolute; inset: 0; background: radial-gradient(circle at 12% 50%, rgba(11,138,78,.10), transparent 45%), radial-gradient(circle at 88% 50%, rgba(247,127,0,.12), transparent 45%); pointer-events: none; }
.la-grille { position: relative; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 20px; }
.la-bloc { display: flex; align-items: center; gap: 14px; }
.la-droite { justify-content: flex-end; text-align: right; }
.la-medaillon { flex: 0 0 auto; width: 86px; height: 86px; border-radius: 50%; background: #fff; padding: 5px; box-shadow: 0 8px 22px rgba(6,83,47,.18), 0 0 0 3px #fff, 0 0 0 5px rgba(11,138,78,.35); display: grid; place-items: center; }
.la-droite .la-medaillon { box-shadow: 0 8px 22px rgba(247,127,0,.22), 0 0 0 3px #fff, 0 0 0 5px rgba(247,127,0,.45); }
.la-medaillon img { width: 100%; height: 100%; object-fit: contain; border-radius: 50%; }
.la-nom strong { display: block; font-size: 1.35rem; letter-spacing: .04em; color: var(--vert-fonce, #06532f); line-height: 1.1; }
.la-droite .la-nom strong { color: #d96a00; }
.la-nom small { display: block; margin-top: 3px; font-size: .78rem; line-height: 1.3; color: var(--texte-doux, #5b6b62); max-width: 22em; }
.la-droite .la-nom small { margin-left: auto; }
.la-centre { display: flex; align-items: center; gap: 12px; text-align: center; }
.la-centre p { margin: 0; font-size: .95rem; color: #2f4a3b; max-width: 15em; line-height: 1.35; }
.la-centre strong { color: var(--vert-fonce, #06532f); }
.la-trait { width: 54px; height: 3px; border-radius: 3px; background: linear-gradient(90deg, #f77f00, #0b8a4e); background-size: 200% 100%; animation: laFlux 3s linear infinite; }
.la-trait:first-child { background: linear-gradient(90deg, #0b8a4e, #f77f00); background-size: 200% 100%; }

/* animations d'entrée + flottement */
.la-gauche { animation: laGauche .9s cubic-bezier(.2,.8,.2,1) both; }
.la-droite { animation: laDroite .9s cubic-bezier(.2,.8,.2,1) .15s both; }
.la-centre { animation: laCentre 1s ease .5s both; }
.la-medaillon { animation: laFlotte 5s ease-in-out 1.2s infinite; }
.la-droite .la-medaillon { animation-delay: 1.8s; }
@keyframes laGauche { from { opacity: 0; transform: translateX(-60px); } to { opacity: 1; transform: none; } }
@keyframes laDroite { from { opacity: 0; transform: translateX(60px); } to { opacity: 1; transform: none; } }
@keyframes laCentre { from { opacity: 0; transform: scale(.85); } to { opacity: 1; transform: none; } }
@keyframes laFlotte { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }
@keyframes laFlux { from { background-position: 0 0; } to { background-position: 200% 0; } }
@media (prefers-reduced-motion: reduce) { .la-gauche, .la-droite, .la-centre, .la-medaillon, .la-trait { animation: none !important; } }

@media (max-width: 820px) {
    .la-grille { grid-template-columns: 1fr 1fr; gap: 14px; }
    .la-centre { grid-column: 1 / -1; order: 3; justify-content: center; }
    .la-centre p { max-width: none; }
    .la-bloc { flex-direction: column; text-align: center; gap: 8px; }
    .la-droite { flex-direction: column-reverse; justify-content: center; text-align: center; }
    .la-droite .la-nom small { margin: 3px auto 0; }
    .la-nom small { margin-left: auto; margin-right: auto; font-size: .72rem; }
    .la-medaillon { width: 74px; height: 74px; }
    .la-nom strong { font-size: 1.1rem; }
    .la-trait { width: 30px; }
}
.navbar .container { justify-content: flex-start; }
.navbar .nav-links, .navbar .nav-toggle { margin-left: auto; }
@media (max-width: 820px) { .la-trait { display: none; } }
.la-medaillon img { width: 80%; height: 80%; border-radius: 0; }
.la-droite .la-medaillon img { width: 100%; height: 100%; border-radius: 50%; }
.brand-aeemci img { padding: 5px; }

.programme-bandeau{display:flex;align-items:center;gap:12px;flex-wrap:wrap;background:#fff8e6;border:1px solid #e0b64a;border-left:6px solid #c9971c;border-radius:12px;padding:12px 16px;margin-bottom:16px}
.programme-bandeau>div{flex:1;min-width:160px}.programme-bandeau .pb-ico{font-size:1.8rem}

.btn-pwa{position:fixed;right:14px;bottom:14px;z-index:900;display:flex;align-items:center;gap:8px;background:linear-gradient(135deg,#0B8A4E,#0a6b3c);color:#fff;border:0;border-radius:999px;padding:12px 18px;font:600 .95rem inherit;font-family:inherit;box-shadow:0 6px 20px rgba(0,0,0,.28);cursor:pointer;animation:pwa-pulse 2.4s ease-in-out infinite}
.btn-pwa span{font-size:1.2rem}
@keyframes pwa-pulse{0%,100%{box-shadow:0 6px 20px rgba(0,0,0,.28)}50%{box-shadow:0 6px 28px rgba(11,138,78,.65)}}
.pwa-modal{position:fixed;inset:0;background:rgba(0,0,0,.55);z-index:1000;display:flex;align-items:center;justify-content:center;padding:20px}
.pwa-boite{background:#fff;border-radius:16px;padding:22px;max-width:380px;width:100%}
.pwa-boite h3{margin:0 0 10px}.pwa-boite ol{padding-left:20px;line-height:1.7}.pwa-boite button{margin-top:10px;width:100%}
@media print{.btn-pwa{display:none}}
.tel-wrap{display:flex;align-items:stretch;width:100%}
.tel-wrap>input{flex:1;min-width:0;border-top-left-radius:0!important;border-bottom-left-radius:0!important}
.tel-pref{display:flex;align-items:center;padding:0 12px;font-weight:700;background:#eef5f0;border:1px solid #cfe0d4;border-right:0;border-radius:10px 0 0 10px;color:#0b6b3c;white-space:nowrap}
