/* ==========================================================================
   Umoja Asso : l'apparence de l'appli.
   Couleurs : vert lagon (Umoja) + sable chaud pour les points importants.
   Clair par défaut, sombre automatique si le téléphone est en sombre,
   ou choisi à la main dans « Plus » (data-theme sur <html>).
   Pas d'animation quand on change d'onglet : l'écran change d'un coup.
   Seuls les panneaux qui s'ouvrent (formulaires, fenêtres) glissent en douceur.
   ========================================================================== */
/* Polices gardées dans l'appli (aucun appel à Google) : Inter (latin) et Noto Naskh (arabe), licence OFL. */
@font-face { font-family: "Inter"; font-style: normal; font-weight: 400 800; font-display: swap; src: url(polices/inter-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 400 800; font-display: swap; src: url(polices/inter-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+1EF2-1EFF, U+20A0-20AB, U+20AD-20C4, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Noto Naskh Arabic"; font-style: normal; font-weight: 400 700; font-display: swap; src: url(polices/noto-naskh-arabic-arabic.woff2) format("woff2");
  unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+200C-200E, U+FB50-FDFF, U+FE70-FEFC; }
:root {
  --fond: #f5f7fb;
  --carte: #ffffff;
  --texte: #141b2d;
  --doux: #5b6478;
  --trait: #e1e6ef;
  --umoja: #2451d6;          /* bleu roi : la couleur d'Umoja */
  --umoja-fort: #1b3fa8;
  --umoja-pale: #e8eefd;
  --sur-umoja: #ffffff;
  --sable: #c77d14;          /* sable chaud : montants, alertes douces */
  --sable-pale: #fbefdc;
  --ok: #1f7a3a; --ok-pale: #e0f2e5;
  --danger: #b3261e; --danger-pale: #fbe4e2;
  --ombre: 0 1px 2px rgba(15, 25, 60, .06), 0 4px 14px rgba(15, 25, 60, .06);
  --r: 14px;
  --police: "Inter", "Noto Naskh Arabic", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: light;
}
/* Sombre : couleurs reprises deux fois (automatique, puis choisi à la main). */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --fond: #0c1220; --carte: #141b2b; --texte: #e8edf7; --doux: #9aa6bd; --trait: #253049;
    --umoja: #7ea4ff; --umoja-fort: #a9c2ff; --umoja-pale: #18264d; --sur-umoja: #0a1838;
    --sable: #f0b357; --sable-pale: #33260f; --ok: #6fd28a; --ok-pale: #12301b; --danger: #ff8a80; --danger-pale: #3a1715;
    --ombre: 0 1px 2px rgba(0, 0, 0, .3); color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --fond: #0c1220; --carte: #141b2b; --texte: #e8edf7; --doux: #9aa6bd; --trait: #253049;
  --umoja: #7ea4ff; --umoja-fort: #a9c2ff; --umoja-pale: #18264d; --sur-umoja: #0a1838;
  --sable: #f0b357; --sable-pale: #33260f; --ok: #6fd28a; --ok-pale: #12301b; --danger: #ff8a80; --danger-pale: #3a1715;
  --ombre: 0 1px 2px rgba(0, 0, 0, .3); color-scheme: dark;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
[hidden] { display: none !important; }
html, body { margin: 0; }
body { background: var(--fond); color: var(--texte); font: 16px/1.5 var(--police); overflow-x: hidden; min-height: 100vh; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--umoja); }
svg.i { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ---------- Boutons et champs ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 10px 18px;
  border-radius: 999px; border: 1px solid var(--trait); background: var(--carte); font-weight: 600; cursor: pointer; text-decoration: none; color: var(--texte); }
.btn:hover { border-color: var(--umoja); }
.btn.plein { background: var(--umoja); border-color: var(--umoja); color: var(--sur-umoja); }
.btn.plein:hover { background: var(--umoja-fort); }
.btn.petit { min-height: 36px; padding: 6px 14px; font-size: .9rem; }
.btn.danger { color: var(--danger); border-color: color-mix(in srgb, var(--danger) 40%, transparent); }
.btn.large { width: 100%; }
.btn:disabled { opacity: .5; cursor: default; }
.btn:focus-visible, .champ input:focus-visible, .champ select:focus-visible, .champ textarea:focus-visible, .onglet:focus-visible, .lien:focus-visible { outline: 2px solid var(--umoja); outline-offset: 2px; }
.lien { background: none; border: 0; padding: 0; color: var(--umoja); font-weight: 600; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.champ { display: grid; gap: 6px; min-width: 0; }
.champ > span { font-size: .85rem; font-weight: 600; color: var(--doux); }
.champ input, .champ select, .champ textarea { width: 100%; min-height: 46px; padding: 10px 14px; border-radius: 12px; border: 1px solid var(--trait); background: var(--carte); }
.champ textarea { min-height: 110px; resize: vertical; }
.champ.erreur input, .champ.erreur select { border-color: var(--danger); background: var(--danger-pale); }
.case { display: flex; gap: 10px; align-items: center; font-weight: 500; cursor: pointer; }
.case input { width: 20px; height: 20px; accent-color: var(--umoja); }
.grille2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 420px) { .grille2 { grid-template-columns: 1fr; } }
.choix { display: flex; gap: 8px; flex-wrap: wrap; }
.choix button { min-height: 40px; padding: 6px 14px; border-radius: 999px; border: 1px solid var(--trait); background: var(--carte); cursor: pointer; font-weight: 600; }
.choix.court { gap: 4px; flex-wrap: nowrap; }
.choix.court button { min-height: 36px; min-width: 40px; padding: 4px 10px; font-size: .88rem; }
/* Langue + bouton clair / sombre côte à côte, en haut des pages sans compte */
.langue-theme { display: flex; align-items: center; gap: 8px; flex: none; }
.bascule-theme { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--umoja); background: var(--umoja-pale); color: var(--umoja-fort); display: grid; place-items: center; cursor: pointer; flex: none; }
.bascule-theme:hover { background: var(--umoja); color: var(--sur-umoja); }
.bascule-theme:focus-visible { outline: 2px solid var(--umoja); outline-offset: 2px; }
.bascule-theme svg { width: 20px; height: 20px; }
.choix button[aria-pressed="true"] { background: var(--umoja-pale); border-color: var(--umoja); color: var(--umoja-fort); }

/* ---------- Accueil sans compte : bienvenue, créer, rejoindre, se connecter ---------- */
.porte { min-height: 100vh; display: grid; align-content: start; }
.porte-in { width: 100%; max-width: 1040px; margin: 0 auto; padding: 24px 16px 40px; display: grid; gap: 24px; }
.porte-haut { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.marque { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.25rem; }
.marque img { width: 40px; height: 40px; border-radius: 11px; }
.porte-hero { display: grid; gap: 18px; }
.porte-hero h1 { margin: 0; font-size: clamp(1.9rem, 6vw, 3rem); line-height: 1.1; letter-spacing: -.02em; }
.porte-hero p { margin: 0; color: var(--doux); font-size: 1.08rem; max-width: 46ch; }
.porte-actions { display: grid; gap: 10px; max-width: 420px; }
.atouts { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.atout { background: var(--carte); border: 1px solid var(--trait); border-radius: var(--r); padding: 14px; display: grid; gap: 6px; }
.atout svg { color: var(--umoja); }
.atout b { font-size: .98rem; }
.atout small { color: var(--doux); line-height: 1.35; }
.prix { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.prix div { background: var(--carte); border: 1px solid var(--trait); border-radius: var(--r); padding: 14px; display: grid; gap: 2px; }
.prix span { color: var(--umoja); font-weight: 700; font-size: .85rem; }
.prix b { font-size: 1.3rem; }
.prix small { color: var(--doux); }
.porte h2 { margin: 6px 0 0; font-size: 1.2rem; }
@media (max-width: 640px) { .prix { grid-template-columns: 1fr; } }
@media (min-width: 900px) {
  .porte-in { padding-top: 32px; gap: 36px; }
  .porte-hero { grid-template-columns: 1.1fr .9fr; align-items: center; gap: 40px; }
  .atouts { grid-template-columns: repeat(4, 1fr); }
}
/* Page publique « vitrine » : bandes pleine largeur, contenu dans un cadre de 1200 px */
.porte.vitrine { display: block; }
.vitrine .bande { width: 100%; }
.vitrine .cadre { max-width: 1200px; margin: 0 auto; padding: 0 16px; }
.vitrine .bande-haut { position: sticky; top: 0; z-index: 5; background: color-mix(in srgb, var(--fond) 88%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--trait); }
.vitrine .bande-haut .cadre { padding-top: 12px; padding-bottom: 12px; }
.vitrine .bande-hero { color: #fff; background: radial-gradient(900px 500px at 85% 10%, #4b74ec 0%, transparent 60%), linear-gradient(135deg, #142f86 0%, #2451d6 100%); }
.vitrine .bande-hero .cadre { padding-top: 40px; padding-bottom: 40px; }
.vitrine .porte-hero { display: grid; gap: 32px; align-items: center; }
.vitrine .hero-texte { display: grid; gap: 18px; }
.vitrine .porte-hero p { color: rgba(255,255,255,.85); }
.vitrine .porte-hero .btn.plein { background: #fff; color: #1b3fa8; }
.vitrine .porte-hero .btn:not(.plein) { background: transparent; color: #fff; border-color: rgba(255,255,255,.5); }
.vitrine .porte-hero .deja { text-align: center; margin: 4px 0 0; }
.vitrine .porte-hero .lien { color: #fff; }
/* Vitrine : un ordinateur, et un téléphone posé devant à droite ; les écrans défilent ensemble */
.vitrine-ecrans { position: relative; justify-self: center; width: 100%; min-width: 0; max-width: 560px; padding-bottom: 18%; }
.vitrine-ecrans .ordi { width: 88%; }
.vitrine-ecrans .ordi-ecran { isolation: isolate; aspect-ratio: 16 / 10; border: 8px solid #0a1020; border-bottom-width: 12px; border-radius: 14px 14px 4px 4px; overflow: hidden; background: var(--fond); box-shadow: 0 30px 70px rgba(0,0,0,.35); }
.vitrine-ecrans .ordi-socle { height: 12px; width: 112%; margin-inline-start: -6%; background: linear-gradient(#2a3040, #0d111c); border-radius: 0 0 16px 16px; }
.vitrine .vitrine-ecrans .telephone { position: absolute; inset-inline-end: 0; bottom: 0; width: 34%; aspect-ratio: 400 / 774; padding: 3.2%; border-radius: 15% / 7.5%; background: #05070d; box-shadow: 0 24px 60px rgba(0,0,0,.45), inset 0 0 0 1.5px #2a3142; transform: none; justify-self: auto; }
.vitrine-ecrans .tel-ecran { position: relative; width: 100%; height: 100%; border-radius: 12% / 5.8%; overflow: hidden; isolation: isolate; -webkit-mask-image: -webkit-radial-gradient(white, black); background: var(--fond); }
.vitrine-ecrans .piste { display: flex; width: 100%; height: 100%; transition: transform .7s cubic-bezier(.65, 0, .35, 1); }
.vitrine-ecrans .piste img { flex: none; width: 100%; height: 100%; object-fit: cover; object-position: top; display: block; background: var(--fond); }
@media (prefers-reduced-motion: reduce) { .vitrine-ecrans .piste { transition: none; } }
/* Logo animé (les trois têtes tournent) */
.logo-anime { display: block; flex: none; border-radius: 22%; }
.raffine-titre .logo-anime { margin: 0 auto; }
/* Choix de la langue : un seul bouton, la liste s'ouvre dessous */
.menu-langue { position: relative; }
.menu-langue summary { list-style: none; display: flex; align-items: center; gap: 6px; height: 40px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--trait); background: var(--carte); color: var(--texte); font-weight: 600; font-size: .9rem; cursor: pointer; user-select: none; }
.menu-langue summary::-webkit-details-marker { display: none; }
.menu-langue summary svg { width: 18px; height: 18px; }
.menu-langue[open] summary { border-color: var(--umoja); }
.menu-langue-liste { position: absolute; inset-inline-end: 0; top: calc(100% + 6px); z-index: 30; min-width: 160px; display: grid; padding: 6px; background: var(--carte); border: 1px solid var(--trait); border-radius: 12px; box-shadow: 0 12px 30px rgba(0,0,0,.18); }
.menu-langue-liste button { text-align: start; padding: 10px 12px; border: 0; border-radius: 8px; background: none; color: var(--texte); font: inherit; font-weight: 500; cursor: pointer; }
.menu-langue-liste button:hover { background: var(--fond); }
.menu-langue-liste button[aria-pressed="true"] { background: var(--umoja-pale); color: var(--umoja-fort); font-weight: 600; }
.vitrine .ap-sombre { display: none !important; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .vitrine .ap-clair { display: none !important; } :root:not([data-theme="light"]) .vitrine .ap-sombre { display: block !important; } }
:root[data-theme="dark"] .vitrine .ap-clair { display: none !important; }
:root[data-theme="dark"] .vitrine .ap-sombre { display: block !important; }
.vitrine .bande > .cadre { padding-top: 28px; padding-bottom: 28px; }
.vitrine .bande-hero > .cadre { padding-top: 40px; padding-bottom: 40px; }
.vitrine .bande-haut > .cadre { padding-top: 12px; padding-bottom: 12px; }
.vitrine .bande-prix { background: var(--carte); border-top: 1px solid var(--trait); border-bottom: 1px solid var(--trait); }
.vitrine .bande-prix h2 { margin: 0 0 16px; font-size: 1.5rem; letter-spacing: -.01em; }
.vitrine .prix div { background: var(--fond); padding: 20px; gap: 4px; }
.vitrine .prix .mise-en-avant { border: 2px solid var(--umoja); }
.vitrine .prix b { font-size: 1.6rem; letter-spacing: -.01em; }
.vitrine .essai { color: var(--doux); margin: 14px 0 0; }
.vitrine .atout { padding: 20px; gap: 8px; align-content: start; }
.vitrine .atout svg { width: 26px; height: 26px; }
@media (min-width: 900px) {
  .vitrine .bande-hero > .cadre { padding-top: 72px; padding-bottom: 72px; }
  .vitrine .porte-hero { grid-template-columns: 1.2fr .8fr; gap: 60px; }
  .vitrine .porte-hero h1 { font-size: 3.4rem; }
  .vitrine .porte-hero p { font-size: 1.2rem; }
  .vitrine .vitrine-ecrans { max-width: 600px; }
  .vitrine .bande > .cadre { padding-top: 48px; padding-bottom: 48px; }
  .vitrine .bande-haut > .cadre { padding-top: 14px; padding-bottom: 14px; }
}
.illus { background: var(--umoja-pale); border-radius: 24px; padding: 22px; display: grid; gap: 10px; }
.illus .ligne { background: var(--carte); border-radius: 12px; padding: 12px 14px; display: flex; align-items: center; gap: 12px; box-shadow: var(--ombre); }
.illus .ligne b { flex: 1; font-size: .95rem; }
.illus .pastille { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: var(--umoja); color: var(--sur-umoja); font-weight: 700; font-size: .85rem; }
.illus .etat-ok { color: var(--ok); font-weight: 700; font-size: .85rem; }
.illus .etat-att { color: var(--sable); font-weight: 700; font-size: .85rem; }

/* Formulaire de la porte (créer / rejoindre / connexion) */
.formulaire { background: var(--carte); border: 1px solid var(--trait); border-radius: 20px; padding: 22px 18px; display: grid; gap: 14px; max-width: 560px; width: 100%; margin: 0 auto; box-shadow: var(--ombre); }
.formulaire h2 { margin: 0; font-size: 1.45rem; }
.formulaire p { margin: 0; color: var(--doux); }
.etapes { display: flex; gap: 6px; }
.etapes i { height: 5px; flex: 1; border-radius: 9px; background: var(--trait); }
.etapes i.fait { background: var(--umoja); }
.message-erreur { margin: 0; padding: 10px 14px; border-radius: 12px; background: var(--danger-pale); color: var(--danger); font-weight: 600; }
.retour { display: inline-flex; align-items: center; gap: 6px; background: none; border: 0; color: var(--doux); font-weight: 600; cursor: pointer; padding: 6px 0; justify-self: start; }
[dir="rtl"] .retour svg, [dir="rtl"] .fleche-sens { transform: scaleX(-1); }

/* ---------- L'appli une fois connecté ---------- */
.appli { min-height: 100vh; }
.entete { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--fond) 92%, transparent); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--trait); padding-top: env(safe-area-inset-top, 0px); }
.entete-in { max-width: 1100px; margin: 0 auto; padding: 10px 16px; display: flex; align-items: center; gap: 12px; min-height: 60px; }
.entete .asso { display: flex; align-items: center; gap: 10px; min-width: 0; flex: 1; }
.entete .asso b { display: block; font-size: 1.1rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.entete .asso small { display: block; color: var(--doux); font-size: .8rem; }
.avatar { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--umoja-pale); color: var(--umoja-fort); font-weight: 700; flex: none; font-size: .9rem; }
.avatar.grand { width: 56px; height: 56px; font-size: 1.2rem; }
.monogramme { width: 40px; height: 40px; border-radius: 12px; background: var(--umoja); color: var(--sur-umoja); display: grid; place-items: center; font-weight: 800; flex: none; }
/* Photo de profil et logo : l'image couvre le rond ; sans image (ou si elle ne charge pas), les initiales restent. */
.avatar, .monogramme { position: relative; overflow: hidden; }
.avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.avatar img + .ini { visibility: hidden; }
button.avatar { border: 0; padding: 0; cursor: pointer; font: inherit; font-weight: 700; }
.avatar.tres-grand { width: 84px; height: 84px; font-size: 1.6rem; }
.monogramme.avec-logo { background: #fff; box-shadow: inset 0 0 0 1px var(--trait); }
.monogramme img { position: absolute; inset: 3px; width: calc(100% - 6px); height: calc(100% - 6px); object-fit: contain; }
.monogramme.avec-logo .ini { visibility: hidden; }
.monogramme.grand { width: 56px; height: 56px; border-radius: 16px; font-size: 1.3rem; }
.monogramme.tres-grand { width: 84px; height: 84px; border-radius: 20px; font-size: 1.8rem; }
.bloc-photo { display: flex; gap: 16px; align-items: center; }
/* Membres en mosaïque */
.outils-membres { display: flex; gap: 10px; align-items: center; }
.outils-membres .recherche { flex: 1; min-width: 0; }
.choix.icones { flex-wrap: nowrap; gap: 4px; }
.choix.icones button { width: 46px; min-height: 46px; padding: 0; display: grid; place-items: center; }
.mosaique { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.carte-membre { background: var(--carte); border: 1px solid var(--trait); border-radius: var(--r); padding: 18px 10px 14px; display: grid; justify-items: center; gap: 8px; text-align: center; cursor: pointer; min-width: 0; }
.carte-membre:hover { border-color: var(--umoja); }
.carte-membre:focus-visible { outline: 2px solid var(--umoja); outline-offset: 2px; }
.carte-membre b { overflow-wrap: anywhere; line-height: 1.25; }
.carte-membre .etiquettes { display: flex; gap: 4px; flex-wrap: wrap; justify-content: center; min-height: 22px; }
@media (max-width: 380px) { .mosaique { grid-template-columns: 1fr 1fr; gap: 10px; } .carte-membre .avatar.tres-grand { width: 68px; height: 68px; } }
/* Case « J'accepte » et petits titres des formulaires */
.case.accord { align-items: flex-start; font-weight: 400; font-size: .92rem; }
.case.accord input { margin-top: 2px; flex: none; }
.case.erreur { color: var(--danger); }
.case.erreur input { outline: 2px solid var(--danger); outline-offset: 1px; }
.intertitre { margin: 6px 0 0; font-size: 1rem; }
.coordonnees { display: grid; gap: 8px; }
.coordonnees > span { display: flex; gap: 10px; align-items: flex-start; color: var(--texte); overflow-wrap: anywhere; }
.coordonnees svg { color: var(--umoja); flex: none; }
.rond { width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--trait); background: var(--carte); display: grid; place-items: center; cursor: pointer; flex: none; }

/* Menu : en bas sur téléphone, à gauche sur ordinateur */
.menu { position: fixed; z-index: 25; inset: auto 0 0 0; background: var(--carte); border-top: 1px solid var(--trait);
  display: grid; grid-template-columns: repeat(5, 1fr); padding-bottom: env(safe-area-inset-bottom, 0px); }
.onglet { background: none; border: 0; display: grid; justify-items: center; gap: 2px; padding: 8px 2px 10px; color: var(--doux); font-size: .72rem; font-weight: 600; cursor: pointer; position: relative; }
.onglet[aria-current="page"] { color: var(--umoja-fort); }
.onglet[aria-current="page"] svg { background: var(--umoja-pale); border-radius: 999px; width: 52px; padding: 3px 0; height: 28px; }
.onglet .bulle { position: absolute; top: 4px; inset-inline-start: calc(50% + 8px); background: var(--sable); color: #fff; border-radius: 99px; font-size: .68rem; min-width: 18px; padding: 0 5px; line-height: 18px; }
main.contenu { max-width: 1100px; margin: 0 auto; padding: 18px 16px 110px; display: grid; gap: 16px; align-content: start; }
@media (min-width: 900px) {
  .appli { display: grid; grid-template-columns: 240px 1fr; grid-template-rows: auto 1fr; }
  .entete { grid-column: 1 / -1; }
  .entete-in { max-width: none; padding: 10px 24px; }
  .menu { position: sticky; top: 61px; align-self: start; height: calc(100vh - 61px); inset: auto; display: flex; flex-direction: column; gap: 4px;
    padding: 18px 12px; border-top: 0; border-inline-end: 1px solid var(--trait); background: transparent; }
  .onglet { grid-template-columns: auto 1fr auto; justify-items: start; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 12px; font-size: .98rem; text-align: start; }
  .onglet[aria-current="page"] { background: var(--umoja-pale); }
  .onglet[aria-current="page"] svg { background: none; width: 22px; height: 22px; padding: 0; }
  .onglet .bulle { position: static; }
  main.contenu { padding: 26px 40px 60px; margin: 0 auto; max-width: 1280px; width: 100%; }
}

/* ---------- Blocs d'écran ---------- */
.titre { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.titre h1 { margin: 0; font-size: 1.6rem; letter-spacing: -.01em; }
.titre p { margin: 2px 0 0; color: var(--doux); }
.bloc { background: var(--carte); border: 1px solid var(--trait); border-radius: var(--r); padding: 16px; display: grid; gap: 10px; min-width: 0; }
.bloc h2 { margin: 0; font-size: 1.08rem; display: flex; align-items: center; gap: 8px; }
.bloc h2 .lien { margin-inline-start: auto; font-size: .9rem; }
.vide { color: var(--doux); text-align: center; padding: 22px 10px; display: grid; gap: 8px; justify-items: center; }
.vide svg { width: 40px; height: 40px; color: var(--umoja); opacity: .7; }
.chiffres { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.chiffre { background: var(--carte); border: 1px solid var(--trait); border-radius: var(--r); padding: 14px; display: grid; gap: 2px; text-align: start; cursor: pointer; color: var(--texte); font: inherit;
  transition: border-color .15s, box-shadow .15s; }
.chiffre:hover { border-color: var(--umoja); box-shadow: 0 4px 18px rgba(36, 81, 214, .10); }
.chiffre small { color: var(--doux); font-weight: 600; font-size: .82rem; }
.chiffre b { font-size: 1.5rem; font-variant-numeric: tabular-nums; letter-spacing: -.01em; }
.chiffre .ch-ic { width: 34px; height: 34px; border-radius: 10px; background: var(--umoja-pale); color: var(--umoja-fort); display: grid; place-items: center; margin-bottom: 8px; }
.chiffre .ch-ic svg { width: 19px; height: 19px; }
.chiffre .ch-bas { color: var(--doux); font-size: .8rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chiffre.alerte .ch-ic { background: var(--sable); color: #fff; }

/* Accueil : haut de page en bleu, actions rapides, tableau de bord en deux colonnes sur grand écran */
.hero { border-radius: calc(var(--r) + 4px); padding: 20px; color: #fff; display: grid; gap: 18px;
  background: radial-gradient(120% 140% at 100% 0%, #4b74ec 0%, transparent 55%), linear-gradient(135deg, #1b3fa8 0%, #2451d6 100%); }
.hero-g { display: flex; align-items: center; gap: 14px; min-width: 0; }
.hero .hero-photo { width: 60px; height: 60px; font-size: 1.3rem; background: rgba(255,255,255,.18); color: #fff; box-shadow: 0 0 0 3px rgba(255,255,255,.35); }
.hero h1 { margin: 2px 0 0; font-size: 1.5rem; letter-spacing: -.01em; line-height: 1.2; }
.hero p { margin: 2px 0 0; opacity: .85; }
.hero-date { display: block; opacity: .8; font-weight: 600; font-size: .82rem; }
.hero-date::first-letter { text-transform: uppercase; }
.apercu-cotis .mini-barre { width: 100%; max-width: none; }
.actions-rapides { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.actions-rapides button { border: 0; border-radius: 14px; background: rgba(255,255,255,.14); color: #fff; font: inherit; font-size: .78rem; font-weight: 600; cursor: pointer;
  display: grid; justify-items: center; gap: 6px; padding: 12px 4px; text-align: center; line-height: 1.2; transition: background .15s; }
.actions-rapides button:hover { background: rgba(255,255,255,.24); }
.actions-rapides svg { width: 22px; height: 22px; }
.tableau-bord { display: grid; gap: 16px; }
.tb-principal, .tb-cote { display: grid; gap: 16px; align-content: start; min-width: 0; }
.doux-p { margin: 0; color: var(--doux); }
.suivants { margin-top: 2px; }
.suivants .ligne, .apercu-cotis .ligne { width: 100%; background: none; border-left: 0; border-right: 0; border-bottom: 0; font: inherit; color: inherit; text-align: start; cursor: pointer; }
.date-mini { min-width: 64px; font-weight: 700; color: var(--umoja-fort); font-size: .85rem; }
.visages { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px 6px; }
.visage { background: none; border: 0; font: inherit; color: var(--texte); display: grid; justify-items: center; gap: 6px; cursor: pointer; min-width: 0; padding: 4px 0; border-radius: 12px; }
.visage:hover { background: var(--umoja-pale); }
.visage .avatar { width: 48px; height: 48px; }
.visage span:last-child { font-size: .8rem; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (min-width: 700px) {
  .hero { padding: 26px 28px; }
  .hero h1 { font-size: 1.9rem; }
  .hero .hero-photo { width: 72px; height: 72px; font-size: 1.5rem; }
}
@media (min-width: 1200px) {
  .hero { grid-template-columns: 1fr auto; align-items: center; }
  .actions-rapides { grid-template-columns: repeat(4, 104px); }
}
@media (min-width: 1100px) {
  .tableau-bord { grid-template-columns: minmax(0, 1.75fr) minmax(300px, 1fr); align-items: start; }
}
.chiffre.alerte { border-color: var(--sable); background: var(--sable-pale); }
@media (min-width: 700px) { .chiffres { grid-template-columns: repeat(4, 1fr); } }
.colonnes { display: grid; gap: 16px; }
@media (min-width: 1000px) { .colonnes { grid-template-columns: 1fr 1fr; align-items: start; } }

.bandeau { padding: 12px 14px; border-radius: 12px; background: var(--sable-pale); color: var(--texte); display: flex; gap: 10px; align-items: flex-start; }
.bandeau svg { color: var(--sable); }
.bandeau.info { background: var(--umoja-pale); }
.bandeau.info svg { color: var(--umoja); }

/* Listes (membres, paiements, opérations…) */
.liste { display: grid; }
.ligne { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-top: 1px solid var(--trait); min-width: 0; }
.liste > .ligne:first-child { border-top: 0; }
.ligne .milieu { flex: 1; min-width: 0; }
.ligne .milieu b { display: block; overflow-wrap: anywhere; }
.ligne .milieu small { color: var(--doux); display: block; }
.ligne .droite { text-align: end; flex: none; display: grid; gap: 4px; justify-items: end; }
.ligne.cliquable { cursor: pointer; }
/* Ligne avec boutons : sur téléphone, les boutons passent dessous, à pleine largeur */
@media (max-width: 560px) {
  .ligne.empile { flex-wrap: wrap; }
  .ligne.empile .droite { width: 100%; display: flex !important; flex-direction: row; justify-content: space-between; align-items: center; gap: 8px; }
  .ligne.empile .droite > span:last-child { display: flex; gap: 8px; }
}
.montant { font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.montant.plus { color: var(--ok); }
.montant.moins { color: var(--danger); }
.badge { display: inline-block; font-size: .74rem; font-weight: 700; padding: 2px 9px; border-radius: 99px; background: var(--umoja-pale); color: var(--umoja-fort); white-space: nowrap; }
.badge.sable { background: var(--sable-pale); color: var(--sable); }
.badge.ok { background: var(--ok-pale); color: var(--ok); }
.badge.gris { background: var(--trait); color: var(--doux); }
.recherche { position: relative; }
.recherche svg { position: absolute; inset-inline-start: 14px; top: 12px; color: var(--doux); }
.recherche input { width: 100%; min-height: 46px; border-radius: 999px; border: 1px solid var(--trait); background: var(--carte); padding-inline: 44px 16px; }

/* Sous-onglets (Cotisations | Caisse, Événements | Votes) */
.sous { display: flex; gap: 6px; background: var(--carte); border: 1px solid var(--trait); padding: 4px; border-radius: 999px; width: fit-content; max-width: 100%; overflow-x: auto; }
.sous button { border: 0; background: none; padding: 8px 16px; border-radius: 999px; font-weight: 600; color: var(--doux); cursor: pointer; white-space: nowrap; }
.sous button[aria-pressed="true"] { background: var(--umoja); color: var(--sur-umoja); }
@media (max-width: 699px) { .sous { width: 100%; display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; } .sous button { padding: 8px 6px; font-size: .9rem; } }

/* Campagne (cotisation ou collecte) avec la barre qui monte */
.campagne { display: grid; gap: 10px; }
.campagne .haut { display: flex; gap: 10px; align-items: flex-start; justify-content: space-between; }
.campagne h3 { margin: 0; font-size: 1.05rem; }
.campagne .haut small { color: var(--doux); display: block; }
.barre { height: 10px; border-radius: 9px; background: var(--trait); overflow: hidden; }
.barre i { display: block; height: 100%; background: var(--umoja); border-radius: 9px; }
.campagne .bas { display: flex; justify-content: space-between; gap: 8px; color: var(--doux); font-size: .9rem; flex-wrap: wrap; }
.solde { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.solde div { background: var(--carte); border: 1px solid var(--trait); border-radius: var(--r); padding: 12px; display: grid; gap: 2px; }
.solde small { color: var(--doux); font-weight: 600; font-size: .8rem; }
.solde b { font-size: 1.15rem; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.solde .total { background: var(--umoja); border-color: var(--umoja); color: var(--sur-umoja); }
.solde .total small { color: inherit; opacity: .85; }
@media (max-width: 560px) { .solde { grid-template-columns: 1fr 1fr; } .solde .total { grid-column: 1 / -1; grid-row: 1; } .solde .total b { font-size: 1.5rem; } }

/* Événement */
.evt { display: flex; gap: 14px; align-items: flex-start; }
.jour { width: 58px; flex: none; border-radius: 12px; background: var(--umoja-pale); color: var(--umoja-fort); text-align: center; padding: 6px 0; line-height: 1.1; }
.jour b { display: block; font-size: 1.45rem; }
.jour small { font-size: .74rem; font-weight: 700; text-transform: uppercase; }
.evt .milieu { flex: 1; min-width: 0; display: grid; gap: 4px; }
.evt h3 { margin: 0; font-size: 1.02rem; }
.evt .meta { color: var(--doux); font-size: .9rem; display: flex; gap: 12px; flex-wrap: wrap; }
.evt .meta span { display: inline-flex; gap: 4px; align-items: center; }
.evt .meta svg { width: 16px; height: 16px; }
.passe { opacity: .6; }

/* Vote */
.option { display: grid; gap: 6px; width: 100%; text-align: start; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--trait); background: var(--carte); cursor: pointer; }
.option[aria-pressed="true"] { border-color: var(--umoja); background: var(--umoja-pale); }
.option .l { display: flex; justify-content: space-between; gap: 8px; font-weight: 600; }
.option:disabled { cursor: default; }

/* Annonce */
.annonce { display: grid; gap: 4px; padding: 12px 0; border-top: 1px solid var(--trait); }
.liste > .annonce:first-child { border-top: 0; }
.annonce b { font-size: 1.02rem; }
.annonce p { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.annonce small { color: var(--doux); }

/* Code d'accès bien visible */
.code { font: 800 1.7rem/1 ui-monospace, "SF Mono", Menlo, monospace; letter-spacing: .12em; color: var(--umoja-fort); background: var(--umoja-pale); padding: 14px; border-radius: 12px; text-align: center; direction: ltr; }

/* Menu « Plus » : grandes lignes cliquables */
.reglage { display: flex; align-items: center; gap: 14px; width: 100%; padding: 14px 4px; background: none; border: 0; border-top: 1px solid var(--trait); cursor: pointer; text-align: start; color: var(--texte); text-decoration: none; }
.liste > .reglage:first-child { border-top: 0; }
.reglage .ic { width: 40px; height: 40px; border-radius: 12px; background: var(--umoja-pale); color: var(--umoja-fort); display: grid; place-items: center; flex: none; }
.reglage .milieu { flex: 1; min-width: 0; }
.reglage .milieu b { display: block; }
.reglage .milieu small { color: var(--doux); }
.reglage .fleche-sens { color: var(--doux); }

/* ---------- Panneau (formulaire) : glisse du bas sur téléphone, fenêtre au centre sur ordinateur ---------- */
.voile { position: fixed; inset: 0; z-index: 50; background: rgba(5, 15, 12, .45); opacity: 0; transition: opacity .22s ease; }
.voile.ouvert { opacity: 1; }
.panneau { position: fixed; z-index: 51; inset: auto 0 0 0; max-height: 92vh; overflow: auto; background: var(--fond); border-radius: 22px 22px 0 0;
  padding: 10px 16px calc(20px + env(safe-area-inset-bottom, 0px)); transform: translateY(100%); transition: transform .26s cubic-bezier(.2, .8, .2, 1); display: grid; gap: 14px; overscroll-behavior: contain; }
.panneau.ouvert { transform: none; }
.panneau .poignee { width: 42px; height: 5px; border-radius: 9px; background: var(--trait); justify-self: center; }
.panneau .haut { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.panneau h2 { margin: 0; font-size: 1.25rem; }
@media (min-width: 700px) {
  .panneau { inset: 50% auto auto 50%; width: min(560px, 92vw); border-radius: 22px; transform: translate(-50%, -46%); opacity: 0; transition: transform .22s ease, opacity .22s ease; padding: 22px; }
  .panneau.ouvert { transform: translate(-50%, -50%); opacity: 1; }
  .panneau .poignee { display: none; }
}
@media (prefers-reduced-motion: reduce) { .voile, .panneau { transition: none; } }

/* Petit message en bas de l'écran */
.toast { position: fixed; z-index: 60; inset-inline: 16px; bottom: calc(86px + env(safe-area-inset-bottom, 0px)); margin: 0 auto; max-width: 420px; background: var(--texte); color: var(--fond);
  padding: 12px 16px; border-radius: 14px; font-weight: 600; text-align: center; opacity: 0; transform: translateY(8px); transition: opacity .2s, transform .2s; pointer-events: none; }
.toast.vu { opacity: 1; transform: none; }
@media (min-width: 900px) { .toast { bottom: 24px; } }

.horsligne { background: var(--sable-pale); color: var(--texte); text-align: center; font-size: .85rem; font-weight: 600; padding: 4px 10px; }
.chargement { display: grid; place-items: center; min-height: 60vh; color: var(--doux); }
.pied-zone { margin-top: 10px; }
.pied-zone .pm { --pm-accent: var(--umoja); --pm-sur-accent: var(--sur-umoja); --pm-texte: var(--texte); --pm-doux: var(--doux); --pm-bord: var(--trait); --pm-fond: transparent; }

/* Impression d'un reçu ou du bilan : seulement la feuille */
@media print {
  body > *:not(#impression) { display: none !important; }
  #impression { display: block !important; color: #000; background: #fff; }
}
#impression { display: none; }
.recu { max-width: 640px; margin: 0 auto; padding: 30px; font-size: 14px; }
.recu h1 { font-size: 22px; margin: 0 0 4px; }
.recu table { width: 100%; border-collapse: collapse; margin-top: 14px; }
.recu td, .recu th { border-bottom: 1px solid #ccc; padding: 8px 4px; text-align: start; }
.recu .signe { margin-top: 30px; color: #555; font-size: 12px; }
.entete-doc { display: flex; gap: 14px; align-items: center; padding-bottom: 14px; margin-bottom: 18px; border-bottom: 2px solid #2451d6; }
.entete-doc img { width: 64px; height: 64px; object-fit: contain; }
.entete-doc b { font-size: 17px; }
.entete-doc small { color: #444; font-size: 12px; }
/* Carte de membre (format carte bancaire, 85,6 x 54 mm) */
.carte-pro { width: 85.6mm; height: 54mm; border-radius: 4mm; border: 1px solid #bbb; overflow: hidden; display: grid; grid-template-rows: auto 1fr auto; margin: 10mm auto; font-size: 10px; color: #111; background: #fff;
  -webkit-print-color-adjust: exact; print-color-adjust: exact; }
.carte-haut { background: var(--carte-c, #2451d6); color: #fff; display: flex; gap: 3mm; align-items: center; padding: 2.5mm 4mm; }
.carte-haut b { display: block; font-size: 12px; line-height: 1.2; }
.carte-haut small { color: #d5efe7; font-size: 9px; }
.carte-logo { width: 9mm; height: 9mm; object-fit: contain; background: #fff; border-radius: 2mm; padding: .6mm; }
.carte-corps { display: flex; gap: 4mm; align-items: center; padding: 3mm 4mm; }
.carte-corps > div { display: grid; gap: .6mm; }
.carte-photo { width: 20mm; height: 20mm; border-radius: 50%; object-fit: cover; flex: none; }
span.carte-photo { display: grid; place-items: center; background: #e8eefd; color: #1b3fa8; font-weight: 800; font-size: 18px; }
.carte-nom { font-size: 13px; }
.carte-corps small { color: #555; font-size: 8.5px; }
.carte-bas { background: #f5f7fb; color: #444; padding: 1.6mm 4mm; font-size: 8.5px; border-top: 1px solid #ddd; }

/* Fichiers joints et import Excel */
.rond.petit { width: 34px; height: 34px; }
.rond.petit svg { width: 18px; height: 18px; }
.pieces h2 { display: flex; gap: 8px; align-items: center; }
.type-fichier { width: 40px; height: 40px; border-radius: 10px; background: var(--umoja-pale); color: var(--umoja-fort); display: grid; place-items: center; font-size: .68rem; font-weight: 800; flex: none; letter-spacing: .02em; }
.exemple-tableau { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid var(--trait); border-radius: 10px; overflow: hidden; font-size: .8rem; font-weight: 600; }
.exemple-tableau span { padding: 8px 6px; background: var(--umoja-pale); color: var(--umoja-fort); border-inline-end: 1px solid var(--trait); overflow-wrap: anywhere; }
.exemple-tableau span:last-child { border-inline-end: 0; }
.actions-ligne { display: flex; gap: 8px; align-items: center; justify-content: flex-end; flex-wrap: wrap; }
.actions-ligne:empty { display: none; }

/* ---------- Champs obligatoires : astérisque rouge partout ---------- */
.champ:has(> input[required], > select[required], > textarea[required], .tel-pays input[required]) > span:first-child::after { content: " *"; color: var(--danger); font-weight: 700; }
.case:has(input[required]) > span::after { content: " *"; color: var(--danger); font-weight: 700; }
.note-requis { font-size: .85rem !important; }
.note-requis::before { content: "* "; color: var(--danger); font-weight: 700; }

/* ---------- Pages d'inscription soignées (une seule page, champs arrondis) ---------- */
.porte.raffinee { background: radial-gradient(1200px 500px at 50% -120px, color-mix(in srgb, var(--umoja) 14%, transparent), transparent 70%), var(--fond); }
.porte.raffinee .porte-in { padding-top: 28px; }
.formulaire.raffine { max-width: 640px; padding: 28px 22px 30px; gap: 16px; border-radius: 26px; }
.raffine-haut { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.raffine-titre { display: grid; justify-items: center; text-align: center; gap: 10px; padding: 4px 0 2px; }
.raffine-titre img { border-radius: 16px; box-shadow: var(--ombre); }
.raffine-titre h1 { margin: 0; font-size: clamp(1.55rem, 5.2vw, 2.25rem); line-height: 1.15; letter-spacing: -.02em; color: var(--umoja); max-width: 22ch; }
.raffine-titre p { margin: 0; color: var(--doux); max-width: 46ch; }
.formulaire.raffine .intertitre { margin: 8px 0 -4px; font-size: .78rem; letter-spacing: .08em; text-transform: uppercase; color: var(--doux); }
.formulaire.raffine .champ > span { color: var(--texte); font-size: .88rem; }
.formulaire.raffine .champ input, .formulaire.raffine .champ select { border-radius: 999px; min-height: 50px; padding: 12px 20px; border-color: color-mix(in srgb, var(--trait) 70%, transparent);
  box-shadow: 0 2px 10px rgba(15, 25, 60, .07); transition: border-color .15s, box-shadow .15s; }
.formulaire.raffine .champ input:focus, .formulaire.raffine .champ select:focus { outline: none; border-color: var(--umoja); box-shadow: 0 0 0 4px color-mix(in srgb, var(--umoja) 18%, transparent); }
.formulaire.raffine .champ.erreur input, .formulaire.raffine .champ.erreur select { border-color: var(--danger); }
.formulaire.raffine .btn.large { min-height: 54px; border-radius: 999px; font-size: 1.05rem; margin-top: 4px; }
.tel-pays { display: grid; grid-template-columns: minmax(100px, 118px) 1fr; gap: 8px; direction: ltr; }
.tel-pays select { padding-inline: 14px !important; font-variant-numeric: tabular-nums; }
.rassurer { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 18px; color: var(--doux); font-size: .85rem; }
.rassurer li { display: flex; align-items: center; gap: 6px; }
.rassurer svg { width: 16px; height: 16px; color: var(--umoja); }
@media (max-width: 420px) { .formulaire.raffine { padding: 22px 16px 24px; border-radius: 22px; } }

/* ---------- Accueil : « Vos premiers pas » ---------- */
.premiers-pas { gap: 12px; border-color: color-mix(in srgb, var(--umoja) 35%, var(--trait)); }
.pp-haut { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.pp-haut h2 { margin: 0; }
.pp-haut small { color: var(--doux); }
.pp-pc { font-weight: 800; font-size: 1.3rem; color: var(--umoja); font-variant-numeric: tabular-nums; white-space: nowrap; }
.pp-barre { height: 8px; border-radius: 99px; background: var(--umoja-pale); overflow: hidden; }
.pp-barre i { display: block; height: 100%; border-radius: inherit; background: var(--umoja); }
.pp-liste { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.pp-liste li > button, .pp-liste li.fait { width: 100%; display: flex; align-items: center; gap: 12px; padding: 10px 8px; border: 0; background: none; color: inherit; font: inherit; text-align: start; border-radius: 12px; }
.pp-liste li > button { cursor: pointer; }
.pp-liste li > button:hover { background: var(--umoja-pale); }
.pp-liste li.fait .pp-txt { color: var(--doux); text-decoration: line-through; }
.pp-txt { flex: 1; font-weight: 600; }
.pp-rond { width: 26px; height: 26px; flex: none; border-radius: 50%; border: 2px solid var(--trait); display: grid; place-items: center; }
.pp-rond svg { width: 15px; height: 15px; }
.fait .pp-rond { background: var(--umoja); border-color: var(--umoja); color: var(--sur-umoja); }
.lien-discret { justify-self: end; background: none; border: 0; color: var(--doux); font: inherit; font-size: .85rem; cursor: pointer; text-decoration: underline; padding: 4px; }
.evt .meta .lieu-lien { display: inline-flex; gap: 4px; align-items: center; color: var(--umoja); text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Votes : sorte de vote, candidats ---------- */
.genres-vote { display: grid; gap: 8px; }
.genre-vote { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border: 1px solid var(--trait); border-radius: 14px; background: var(--carte); cursor: pointer; }
.genre-vote input { margin-top: 4px; accent-color: var(--umoja); width: 18px; height: 18px; flex: none; }
.genre-vote span { display: grid; gap: 2px; }
.genre-vote small { color: var(--doux); }
.genre-vote:has(input:checked) { border-color: var(--umoja); background: var(--umoja-pale); }
.apercu-ouinon { display: flex; gap: 8px; }
.option-apercu { flex: 1; text-align: center; padding: 10px; border: 1px dashed var(--trait); border-radius: 12px; color: var(--doux); font-weight: 600; }
.petite-recherche { width: 100%; min-height: 42px; padding: 8px 14px; border-radius: 12px; border: 1px solid var(--trait); background: var(--carte); color: inherit; font: inherit; }
.liste-candidats { display: grid; gap: 4px; max-height: 300px; overflow: auto; border: 1px solid var(--trait); border-radius: 14px; padding: 6px; background: var(--carte); }
.candidat { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 10px; cursor: pointer; }
.candidat[hidden] { display: none; }
.candidat input { width: 18px; height: 18px; accent-color: var(--umoja); flex: none; }
.candidat:has(input:checked) { background: var(--umoja-pale); font-weight: 600; }
.option .o-nom { display: inline-flex; align-items: center; gap: 10px; min-width: 0; }
.option .o-nom .avatar { width: 34px; height: 34px; font-size: .8rem; flex: none; }
.btn.danger-doux { color: var(--danger); }
.btn.danger-doux svg { width: 16px; height: 16px; }
.zone-genre { display: grid; gap: 10px; } .zone-genre[hidden], .apercu-ouinon[hidden] { display: none; }

/* ---------- Calques plein écran : recadrer, voir en grand ---------- */
.panneau .avatar.tres-grand img, .panneau .monogramme.grand img, .panneau .monogramme.tres-grand img { cursor: zoom-in; }
.calque { position: fixed; inset: 0; z-index: 70; opacity: 0; transition: opacity .2s ease; }
.calque.ouvert { opacity: 1; }
.recadreur { background: var(--fond); display: grid; grid-template-rows: auto 1fr auto auto auto; gap: 12px; padding: 12px 16px calc(16px + env(safe-area-inset-bottom, 0px)); justify-items: center; align-items: center; }
.rc-haut { width: 100%; max-width: 480px; display: flex; align-items: center; justify-content: space-between; }
.rc-scene { position: relative; width: min(100%, 420px, 58vh); aspect-ratio: 1; overflow: hidden; touch-action: none; background: #111; border-radius: 18px; cursor: grab; user-select: none; }
.rc-scene.carre { background: repeating-conic-gradient(#d9d9d9 0 25%, #f4f4f4 0 50%) 0 0 / 22px 22px; }
.rc-scene img { position: absolute; left: 50%; top: 50%; transform-origin: center; max-width: none; pointer-events: none; }
.rc-masque { position: absolute; inset: 0; pointer-events: none; border-radius: 50%; box-shadow: 0 0 0 999px rgba(0, 0, 0, .5); outline: 2px solid rgba(255, 255, 255, .9); outline-offset: -2px; }
.rc-scene.carre .rc-masque { border-radius: 14px; box-shadow: none; outline-color: var(--umoja); }
.rc-aide { margin: 0; color: var(--doux); font-size: .9rem; text-align: center; max-width: 40ch; }
.rc-zoom { width: min(100%, 420px); display: flex; gap: 12px; align-items: center; font-weight: 600; }
.rc-zoom input { flex: 1; accent-color: var(--umoja); }
.rc-bas { width: min(100%, 420px); display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.visionneuse { background: rgba(0, 0, 0, .94); }
.vs-scene { position: absolute; inset: 0; overflow: hidden; touch-action: none; }
.vs-scene img { position: absolute; left: 50%; top: 50%; transform-origin: center; max-width: none; user-select: none; pointer-events: none; border-radius: 6px; }
.vs-fermer { position: absolute; z-index: 2; top: calc(14px + env(safe-area-inset-top, 0px)); inset-inline-end: 14px; background: rgba(255, 255, 255, .16) !important; color: #fff !important; border-color: transparent !important; }

/* ---------- Carte de membre : aperçu et réglages ---------- */
.apercu-carte { display: grid; justify-items: center; padding: 6px 0 4px; }
.apercu-carte-in { position: relative; }
.apercu-carte-in .carte-pro { margin: 0; transform-origin: top left; position: absolute; top: 0; left: 0; box-shadow: 0 6px 22px rgba(0, 0, 0, .18); }
[dir="rtl"] .apercu-carte-in .carte-pro { left: auto; right: 0; transform-origin: top right; }
.carte-valide { color: var(--carte-c, #2451d6) !important; font-weight: 700; }
.pastilles { display: flex; gap: 10px; flex-wrap: wrap; }
.pastille { width: 40px; height: 40px; border-radius: 50%; background: var(--p); display: grid; place-items: center; cursor: pointer; box-shadow: 0 0 0 2px var(--carte), 0 0 0 3px var(--trait); }
.pastille input { appearance: none; width: 14px; height: 14px; border-radius: 50%; margin: 0; cursor: pointer; }
.pastille input:checked { background: #fff; }
.pastille:has(input:checked) { box-shadow: 0 0 0 2px var(--carte), 0 0 0 4px var(--p); }
.pastille:has(input:focus-visible) { outline: 2px solid var(--umoja); outline-offset: 4px; }
/* Aperçu d'un document (reçu, bilan) : une feuille blanche, même en mode sombre */
.papier { background: #fff; color: #111; border-radius: 12px; box-shadow: 0 4px 18px rgba(0, 0, 0, .15); overflow: hidden; }
.papier .recu { padding: 18px 16px; font-size: 13.5px; }
.papier .recu td, .papier .recu th { border-color: #ddd; }
.papier .entete-doc img { width: 48px; height: 48px; }
.boutons-doc { display: grid; gap: 10px; }
.champ .pastille input { width: 14px; height: 14px; min-height: 0; padding: 0; border: 0; border-radius: 50%; background: transparent; box-shadow: none; }
.champ .pastille input:checked { background: #fff; }

/* ---------- Cotisations : liste et tableau « qui a payé » ---------- */
.intitule-vue { flex: 1; font-weight: 700; color: var(--doux); font-size: .9rem; }
.ligne-campagne { cursor: default; align-items: center; }
.ligne-campagne[data-campagne] { cursor: pointer; }
.ligne-campagne.passe { opacity: .7; }
.ligne-campagne .milieu { display: grid; gap: 3px; }
.pastille-type { width: 40px; height: 40px; border-radius: 12px; flex: none; display: grid; place-items: center; background: var(--umoja-pale); color: var(--umoja-fort); }
.pastille-type.collecte { background: var(--sable-pale); color: var(--sable); }
.pastille-type svg { width: 20px; height: 20px; }
.mini-barre { display: block; height: 5px; border-radius: 99px; background: var(--trait); overflow: hidden; margin-top: 3px; max-width: 220px; }
.mini-barre i { display: block; height: 100%; background: var(--umoja); border-radius: inherit; }
.ligne-campagne .droite { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.defile-tableau { overflow-x: auto; margin: 0 -4px; padding: 0 4px; }
.tableau-cotis { border-collapse: separate; border-spacing: 0; width: 100%; font-size: .88rem; }
.tableau-cotis th, .tableau-cotis td { padding: 8px 10px; border-bottom: 1px solid var(--trait); text-align: center; white-space: nowrap; }
.tableau-cotis thead th { font-size: .8rem; color: var(--doux); vertical-align: bottom; }
.tableau-cotis thead th small { display: block; font-weight: 500; }
.tableau-cotis th:first-child { text-align: start; position: sticky; inset-inline-start: 0; background: var(--carte); z-index: 1; }
.cellule-nom { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; }
.cellule-nom .avatar { width: 28px; height: 28px; font-size: .7rem; }
.tableau-cotis td.paye { color: var(--ok); }
.tableau-cotis td.paye svg { width: 18px; height: 18px; vertical-align: middle; }
.tableau-cotis td.partiel { color: var(--sable); font-weight: 700; }
.tableau-cotis td.rien { color: var(--doux); }
.tableau-cotis tfoot th, .tableau-cotis tfoot td { font-weight: 700; border-bottom: 0; }
.legende-tableau { display: flex; gap: 14px; flex-wrap: wrap; font-size: .82rem; color: var(--doux); }
.legende-tableau span { display: inline-flex; align-items: center; gap: 6px; }
.legende-tableau i { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.legende-tableau i.paye { background: var(--ok); } .legende-tableau i.partiel { background: var(--sable); } .legende-tableau i.rien { background: var(--trait); }

/* ---------- Membres : sélection de plusieurs ---------- */
.barre-selection { position: sticky; top: 64px; z-index: 5; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding: 10px 12px; border-radius: 14px; background: var(--umoja-pale); border: 1px solid color-mix(in srgb, var(--umoja) 35%, var(--trait)); }
.barre-selection b { flex: 1; min-width: 120px; }
.barre-selection .btn svg { width: 16px; height: 16px; }
.ligne.choisir { cursor: pointer; }
.ligne.choisir input { width: 20px; height: 20px; accent-color: var(--umoja); flex: none; }
.ligne.choisir:has(input:checked) { background: var(--umoja-pale); }
.ligne.choisir.bloque { opacity: .55; cursor: default; }
.ligne.cliquable, .carte-membre { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }

/* Boutons de paiement par carte de l'abonnement */
.abo-cartes { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.abo-cartes .btn { min-height: 56px; padding: 8px 12px; justify-content: flex-start; border-radius: 16px; }
.abo-txt { display: grid; text-align: start; line-height: 1.2; }
.abo-txt b { font-size: .95rem; }
.abo-txt small { font-size: .85rem; opacity: .85; font-weight: 600; }
@media (max-width: 360px) { .abo-cartes { grid-template-columns: 1fr; } }

/* Formulaire de création : informations officielles facultatives, repliées */
details.officiel { border: 1px solid var(--trait); border-radius: 14px; padding: 12px 14px; background: var(--fond); }
details.officiel summary { cursor: pointer; font-weight: 700; color: var(--umoja-fort); display: flex; align-items: center; gap: 8px; list-style: none; }
details.officiel summary::-webkit-details-marker { display: none; }
details.officiel summary::after { content: "+"; margin-inline-start: auto; font-size: 1.3rem; line-height: 1; }
details.officiel[open] summary::after { content: "\2212"; }
details.officiel[open] { display: grid; gap: 12px; }
details.officiel[open] summary { margin-bottom: 2px; }
.officiel-aide { margin: 0; color: var(--doux); font-size: .88rem; }
/* Ligne SIREN + bouton « Remplir » (répertoire Sirene) */
.sirene { display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: end; }
.officiel-aide.erreur { color: var(--danger); }
.reseaux-asso { display: flex; flex-wrap: wrap; gap: 8px; }
.import-raccourci .btn { margin-top: 8px; }

/* Import : bilan nouveaux / ignorés avant l'ajout */
.import-bilan { display: grid; gap: 6px; }
.import-bilan span { display: flex; gap: 8px; align-items: center; font-weight: 600; }
.import-bilan svg { width: 18px; height: 18px; flex: none; }
.import-bilan .ok { color: var(--ok, #1f8a4c); }
.import-bilan .ignores { color: var(--doux); font-weight: 500; }
details.import-ignores summary { cursor: pointer; color: var(--umoja); font-weight: 600; padding: 4px 0; }
details.import-ignores .liste { opacity: .75; margin-top: 6px; }
.import-rien { margin: 0; padding: 12px 14px; border-radius: 12px; background: var(--fond2, rgba(127,127,127,.1)); }

/* Remonter : le nom de l'asso en haut est cliquable, et une flèche flottante apparaît en descendant */
.entete .asso[data-haut] { cursor: pointer; border-radius: 12px; }
.remonter { position: fixed; z-index: 24; inset-inline-end: 16px; bottom: calc(84px + env(safe-area-inset-bottom, 0px));
  width: 48px; height: 48px; border-radius: 50%; border: 1px solid var(--trait); background: var(--carte); color: var(--umoja);
  display: grid; place-items: center; cursor: pointer; box-shadow: 0 6px 18px rgba(10, 20, 40, .16);
  opacity: 0; transform: translateY(12px); pointer-events: none; transition: opacity .2s ease, transform .2s ease; }
.remonter.visible { opacity: 1; transform: none; pointer-events: auto; }
.remonter svg { width: 22px; height: 22px; }
@media (min-width: 900px) { .remonter { bottom: 28px; inset-inline-end: 28px; } }

/* En-tête de l'appli : langue, clair / sombre et déconnexion, discrets à droite de la photo */
.entete-outils { display: flex; align-items: center; gap: 4px; flex: none; }
.entete-outils .menu-langue summary { height: 34px; padding: 0 9px; gap: 4px; font-size: .8rem; color: var(--doux); border-color: transparent; background: transparent; }
.entete-outils .menu-langue summary:hover, .entete-outils .menu-langue[open] summary { border-color: var(--trait); background: var(--carte); color: var(--texte); }
.entete-outils .menu-langue summary svg { width: 17px; height: 17px; }
.entete-outils .bascule-theme { width: 34px; height: 34px; border-color: transparent; background: transparent; color: var(--doux); }
.entete-outils .bascule-theme:hover { background: var(--carte); color: var(--texte); border-color: var(--trait); }
.entete-outils .bascule-theme svg { width: 17px; height: 17px; }
.entete-outils .menu-sortie summary { width: 34px; padding: 0; justify-content: center; }
.menu-sortie .menu-langue-liste { min-width: 230px; }
.menu-sortie .menu-langue-liste button { display: grid; gap: 2px; }
.menu-sortie .menu-langue-liste button b { color: var(--danger); font-weight: 600; }
.menu-sortie .menu-langue-liste button small { color: var(--doux); font-size: .78rem; }
@media (max-width: 380px) { .entete-outils .menu-langue:not(.menu-sortie) summary span { display: none; } }
