/* =====================================================================
   Démarches en ligne — styles personnalisés
   Surcharge Bootstrap 5 avec l'identité visuelle de la commune.

   Les noms (--mairie-*, section-card, tuile, empty-state…) sont ceux de la
   réservation et du Parc : le balisage repris fonctionne sans retouche.
   ===================================================================== */

:root {
  /* Palette officielle de la commune d'Ancy-Dornot (deux couleurs) */
  --mairie-primary:   #312783;   /* bleu foncé officiel */
  --mairie-primary-2: #63b9e9;   /* bleu clair officiel */
  --mairie-accent:    #63b9e9;
  --mairie-accent-2:  #82c8ed;
  --mairie-bg:        #f8f9fb;
  --mairie-surface:   #ffffff;
  --mairie-text:      #1a202c;
  --mairie-muted:     #6c757d;
  --mairie-pale:      #f1f0fa;

  --shadow-sm: 0 1px 2px 0 rgba(0,0,0,0.05);
  --shadow:    0 1px 3px 0 rgba(0,0,0,0.08), 0 1px 2px -1px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.08), 0 2px 4px -2px rgba(0,0,0,0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.08), 0 4px 6px -4px rgba(0,0,0,0.05);
}

/* ----- Base ----- */
html, body { height: 100%; }
body {
  background-color: var(--mairie-bg);
  color: var(--mairie-text);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
main.main-container { flex: 1 0 auto; padding-top: 84px; padding-bottom: 3rem; }
a { color: var(--mairie-primary); }

/* ----- Barre du haut ----- */
.navbar-mairie { background-color: var(--mairie-primary); box-shadow: var(--shadow-md); }
.navbar-mairie .navbar-brand { font-weight: 700; color: #fff; }
.navbar-mairie .navbar-brand .brand-logo-horizontal { height: 34px; width: auto; }
.navbar-mairie .navbar-brand .brand-titre { display: flex; flex-direction: column; line-height: 1.2; }
.navbar-mairie .navbar-brand .brand-titre-1 { font-size: 0.98rem; font-weight: 700; }
.navbar-mairie .navbar-brand .brand-titre-2 { font-size: 0.8rem; font-weight: 400; color: #b8c8ee; }
/* v1.0.1 : le trait fin passe avant le petit logo de l'appli (document), qui
   fait partie de son nom — comme la boussole de Cap. */
.navbar-mairie .navbar-brand .brand-appli {
  display: flex; align-items: center; gap: 0.6rem;
  margin-left: 0.9rem; padding-left: 0.9rem;
  border-left: 1px solid rgba(255,255,255,0.45);
}
.navbar-mairie .navbar-brand .brand-appli-seul { margin-left: 0; padding-left: 0; border-left: 0; }
.navbar-mairie .navbar-brand .brand-picto { width: 30px; height: 30px; flex-shrink: 0; }
@media (max-width: 380px) {
  .navbar-mairie .navbar-brand .brand-logo-horizontal { height: 28px; }
  .navbar-mairie .navbar-brand .brand-appli { margin-left: 0.6rem; padding-left: 0.6rem; }
  .navbar-mairie .navbar-brand .brand-appli-seul { margin-left: 0; padding-left: 0; }
  .navbar-mairie .navbar-brand .brand-picto { width: 26px; height: 26px; }
}
.navbar-mairie .nav-link { color: rgba(255,255,255,0.85) !important; font-weight: 500; position: relative; white-space: nowrap; }
/* Barre dépliée mais étroite (petit portable, 992 à 1199 px) : le titre
   « Démarches en ligne » laisse la place aux menus du back-office. */
@media (min-width: 992px) and (max-width: 1199px) {
  .navbar-mairie .navbar-brand .brand-titre { display: none !important; }
  .navbar-mairie .navbar-nav .nav-link { padding-left: 0.45rem; padding-right: 0.45rem; }
}
.navbar-mairie .nav-link:hover,
.navbar-mairie .nav-link.active { color: #fff !important; }
.navbar-mairie .nav-link.active::after {
  content: ''; position: absolute; bottom: -2px; left: 0.5rem; right: 0.5rem;
  height: 2px; background: var(--mairie-accent); border-radius: 2px;
}
.navbar-mairie .dropdown-menu { border: none; box-shadow: var(--shadow-lg); border-radius: 0.5rem; }
.navbar-role-badge {
  display: inline-block; font-size: 0.7rem; padding: 0.18rem 0.5rem;
  border-radius: 999px; background: var(--mairie-accent); color: var(--mairie-primary);
  font-weight: 600; margin-left: 0.2rem;
}
.nav-taches-badge {
  display: inline-block; background: #dc2626; color: #fff;
  font-weight: 700; font-size: 0.7rem; line-height: 1;
  padding: 3px 6px; border-radius: 999px; margin-left: 0.3rem; vertical-align: middle;
}
.navbar-mairie .btn-inscription { font-weight: 600; }
.bandeau-apercu {
  background: #fef3c7; color: #92400e; border-bottom: 1px solid #fcd34d;
  font-size: 0.9rem; padding: 0.5rem 0; margin-top: -1.25rem; margin-bottom: 1.25rem;
}

/* ----- Cartes et sections ----- */
.section-card {
  background: var(--mairie-surface); border-radius: 0.75rem;
  box-shadow: var(--shadow); padding: 1.5rem; margin-bottom: 1.5rem;
}
.section-card h1, .section-card h2, .section-card h3 { margin-top: 0; }
.section-title { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 0.25rem; }
.section-title .icon-bubble {
  width: 48px; height: 48px; border-radius: 12px;
  display: inline-flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--mairie-primary), var(--mairie-primary-2));
  color: #fff; font-size: 1.4rem; flex-shrink: 0;
}
.section-subtitle { color: var(--mairie-muted); font-size: 0.95rem; margin-bottom: 1rem; }
.titre-carte { font-size: 1.05rem; font-weight: 700; margin-bottom: 0.9rem; }

/* ----- Boutons ----- */
.btn-mairie { background-color: var(--mairie-primary); border-color: var(--mairie-primary); color: #fff; }
.btn-mairie:hover, .btn-mairie:focus {
  background-color: #251d66; border-color: #251d66; color: #fff;
}
.btn-accent {
  background-color: var(--mairie-accent); border-color: var(--mairie-accent);
  color: var(--mairie-primary); font-weight: 600;
}
.btn-accent:hover, .btn-accent:focus {
  background-color: var(--mairie-accent-2); border-color: var(--mairie-accent-2); color: var(--mairie-primary);
}

/* ----- Accueil public ----- */
.accueil-hero {
  background: linear-gradient(135deg, var(--mairie-primary) 0%, #4a3fb0 55%, var(--mairie-primary-2) 100%);
  color: #fff; border-radius: 1rem; padding: 2.25rem 2rem; margin-bottom: 2rem;
  box-shadow: var(--shadow-md);
}
.accueil-hero h1 { font-weight: 800; font-size: 2rem; margin-bottom: 0.5rem; }
.accueil-hero p { color: rgba(255,255,255,0.88); max-width: 60ch; margin-bottom: 1.25rem; }
.accueil-hero .form-control { border: none; padding: 0.75rem 1rem; }
.accueil-hero .btn { padding-left: 1.25rem; padding-right: 1.25rem; }
.accueil-raccourcis a { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 575px) {
  .accueil-hero { padding: 1.5rem 1.1rem; }
  .accueil-hero h1 { font-size: 1.5rem; }
}
.categorie-titre {
  display: flex; align-items: center; gap: 0.6rem;
  font-size: 1.15rem; font-weight: 700; margin: 1.75rem 0 0.9rem;
}
.categorie-titre i {
  width: 36px; height: 36px; border-radius: 10px; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--mairie-pale); color: var(--mairie-primary); font-size: 1.1rem;
}
.carte-demarche {
  display: flex; gap: 0.9rem; align-items: flex-start; height: 100%;
  background: var(--mairie-surface); border-radius: 0.75rem; box-shadow: var(--shadow);
  padding: 1.1rem 1.2rem; color: inherit; text-decoration: none;
  border: 1px solid transparent; transition: border-color .12s, box-shadow .12s, transform .12s;
}
.carte-demarche:hover, .carte-demarche:focus {
  border-color: var(--mairie-primary-2); box-shadow: var(--shadow-lg); color: inherit; transform: translateY(-1px);
}
.carte-demarche .carte-icone {
  width: 44px; height: 44px; border-radius: 12px; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--mairie-primary), var(--mairie-primary-2)); color: #fff; font-size: 1.25rem;
}
.carte-demarche .carte-titre { font-weight: 700; color: var(--mairie-primary); margin-bottom: 0.2rem; line-height: 1.3; }
.carte-demarche .carte-resume { color: var(--mairie-muted); font-size: 0.9rem; margin-bottom: 0.35rem; }
.carte-demarche .carte-meta { font-size: 0.78rem; color: var(--mairie-muted); display: flex; gap: 0.75rem; flex-wrap: wrap; }

/* ----- Fiche d'une démarche ----- */
.fiche-demarche .description { font-size: 1.02rem; line-height: 1.65; }
.encart-infos { background: var(--mairie-pale); border-radius: 0.75rem; padding: 1.1rem 1.25rem; }
.encart-infos dt { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--mairie-muted); font-weight: 700; }
.encart-infos dd { margin-bottom: 0.8rem; }
.encart-infos dd:last-child { margin-bottom: 0; }
.liste-pieces { padding-left: 1.2rem; margin-bottom: 0; }
.liste-pieces li { margin-bottom: 0.25rem; }

/* ----- Formulaire de dépôt ----- */
.form-section-titre { margin: 1.75rem 0 1rem; padding-bottom: 0.4rem; border-bottom: 2px solid var(--mairie-pale); }
.form-section-titre:first-child { margin-top: 0; }
.form-section-titre h2 { color: var(--mairie-primary); font-weight: 700; }
.form-info { font-size: 0.95rem; }
.form-consentement { background: var(--mairie-pale); border-radius: 0.5rem; padding: 0.75rem 0.75rem 0.75rem 2.25rem; }
.bloc-identite { background: #fafafe; border: 1px solid #e7e5f5; border-radius: 0.75rem; padding: 1.1rem 1.25rem 0.3rem; margin-bottom: 1.5rem; }
.mention-rgpd { font-size: 0.8rem; color: var(--mairie-muted); }
.champ-piege { position: absolute !important; left: -10000px !important; width: 1px; height: 1px; overflow: hidden; }

/* ----- Statuts ----- */
.badge-statut {
  display: inline-flex; align-items: center; gap: 0.3rem;
  font-size: 0.75rem; padding: 0.32em 0.7em; border-radius: 999px; font-weight: 600; white-space: nowrap;
  background: #f1f5f9; color: #334155;
}
.statut-depose     { background: #e0e7ff; color: #3730a3; }
.statut-en_cours   { background: #dbeafe; color: #1e40af; }
.statut-complement { background: #fef3c7; color: #92400e; }
.statut-accepte    { background: #d1fae5; color: #065f46; }
.statut-refuse     { background: #fee2e2; color: #991b1b; }
.statut-traite     { background: #e0f2f1; color: #115e59; }
.statut-annule     { background: #e5e7eb; color: #374151; }
.pastille-nouveau {
  display: inline-block; width: 8px; height: 8px; border-radius: 50%;
  background: #dc2626; margin-right: 0.35rem; vertical-align: middle;
}

/* ----- v1.3.0 : le contact (champ « Sujet », urgence, transfert) ----- */
.badge-urgent {
  display: inline-flex; align-items: center; gap: 0.3rem;
  font-size: 0.75rem; padding: 0.32em 0.7em; border-radius: 999px; font-weight: 700; white-space: nowrap;
  background: #dc2626; color: #fff;
}
.bandeau-urgence { margin: 0.75rem 0 0; }
.info-sujet { margin-top: 0.6rem; font-size: 0.88rem; }
.info-sujet .conseil-sujet { background: var(--mairie-pale, #f1f8fd); border-radius: 0.5rem; padding: 0.5rem 0.75rem; margin-bottom: 0.4rem; }
.info-sujet .lu-par { color: var(--mairie-muted, #6c757d); }
/* Ce qui apparaît avec le sujet choisi arrive en douceur, plutôt que d'un coup */
.champ-sujet .bloc-elu:not([hidden]), .champ-sujet .bandeau-urgence:not([hidden]), .champ-sujet .info-sujet:not([hidden]) {
  animation: sujet-apparait 0.22s ease-out;
}
@keyframes sujet-apparait { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
  .champ-sujet .bloc-elu, .champ-sujet .bandeau-urgence, .champ-sujet .info-sujet { animation: none !important; }
}
.liste-choix-dest { max-height: 16rem; overflow-y: auto; border: 1px solid #e7e5f5; border-radius: 0.5rem; padding: 0.4rem 0.6rem; background: #fafafe; }
.liste-envois li + li { border-top: 1px solid #eef0f4; margin-top: 0.5rem; padding-top: 0.5rem; }

/* ----- Étapes d'un dossier (côté habitant) ----- */
.etapes { display: flex; gap: 0; margin: 1.25rem 0 0.25rem; list-style: none; padding: 0; counter-reset: etape; }
.etapes li {
  flex: 1; text-align: center; position: relative; font-size: 0.82rem; color: var(--mairie-muted);
  padding-top: 2.2rem;
}
.etapes li::before {
  counter-increment: etape; content: counter(etape);
  position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  width: 1.8rem; height: 1.8rem; border-radius: 50%; line-height: 1.8rem;
  background: #e5e7eb; color: #6b7280; font-weight: 700; z-index: 1;
}
.etapes li:not(:first-child)::after {
  content: ''; position: absolute; top: 0.85rem; right: 50%; width: 100%; height: 3px; background: #e5e7eb;
}
.etapes li.faite, .etapes li.courante { color: var(--mairie-text); font-weight: 600; }
.etapes li.faite::before { content: '✓'; background: var(--mairie-primary-2); color: #fff; }
.etapes li.courante::before { background: var(--mairie-primary); color: #fff; }
.etapes li.faite::after, .etapes li.courante::after { background: var(--mairie-primary-2); }

/* ----- Réponses d'un dossier ----- */
dl.reponses { display: grid; grid-template-columns: minmax(150px, 34%) 1fr; gap: 0.55rem 1.25rem; margin-bottom: 0.5rem; }
dl.reponses dt { color: var(--mairie-muted); font-weight: 600; font-size: 0.9rem; }
dl.reponses dd { margin: 0; overflow-wrap: anywhere; }
.reponses-titre { font-size: 0.95rem; font-weight: 700; color: var(--mairie-primary); margin: 1.25rem 0 0.6rem; padding-bottom: 0.3rem; border-bottom: 1px solid #eceaf7; }
@media (max-width: 575px) { dl.reponses { grid-template-columns: 1fr; gap: 0.15rem; } dl.reponses dd { margin-bottom: 0.6rem; } }
.lien-piece { text-decoration: none; font-weight: 500; overflow-wrap: anywhere; }
.lien-piece:hover { text-decoration: underline; }

/* ----- Fil des échanges ----- */
.fil { list-style: none; padding: 0; margin: 0; }
.fil-message { display: flex; gap: 0.75rem; margin-bottom: 1rem; }
.fil-avatar {
  flex: 0 0 38px; width: 38px; height: 38px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 0.85rem; font-weight: 700; background: var(--mairie-pale); color: var(--mairie-primary);
}
.fil-message.agent .fil-avatar { background: var(--mairie-primary); color: #fff; }
.fil-message.systeme .fil-avatar { background: #e5e7eb; color: #4b5563; }
.fil-bulle { flex: 1; min-width: 0; background: #f7f7fb; border-radius: 0.2rem 0.75rem 0.75rem 0.75rem; padding: 0.7rem 0.95rem; }
.fil-message.agent .fil-bulle { background: #eef6fc; }
.fil-message.interne .fil-bulle { background: #fff8e1; border: 1px dashed #f0c36d; }
.fil-entete { font-size: 0.8rem; color: var(--mairie-muted); margin-bottom: 0.3rem; display: flex; gap: 0.5rem; flex-wrap: wrap; align-items: center; }
.fil-entete strong { color: var(--mairie-text); }
.fil-texte { overflow-wrap: anywhere; }
.fil-pieces { margin-top: 0.4rem; font-size: 0.9rem; }

/* ----- Back-office ----- */
.tuile {
  display: block; background: var(--mairie-surface); border-radius: 0.75rem;
  box-shadow: var(--shadow); padding: 1.1rem 1.25rem; height: 100%;
  text-decoration: none; color: inherit; border-left: 4px solid var(--mairie-primary);
  transition: transform .12s ease, box-shadow .12s ease;
}
a.tuile:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); color: inherit; }
.tuile-label { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--mairie-muted); font-weight: 700; display: block; margin-bottom: 0.35rem; }
.tuile-valeur { font-size: 1.9rem; font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums; }
.tuile-sub { font-size: 0.78rem; color: var(--mairie-muted); display: block; margin-top: 0.35rem; }
.tuile-danger  { border-left-color: #dc2626; } .tuile-danger .tuile-valeur { color: #dc2626; }
.tuile-warning { border-left-color: #f59e0b; } .tuile-warning .tuile-valeur { color: #b45309; }
.tuile-accent  { border-left-color: var(--mairie-primary-2); }

.table-dossiers { font-size: 0.92rem; }
.table-dossiers thead th {
  font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.05em;
  color: var(--mairie-muted); font-weight: 700; border-bottom-width: 1px; white-space: nowrap;
}
.table-dossiers td { vertical-align: middle; }
.table-dossiers tbody tr:hover { background: #f6f5fc; }
.table-dossiers tr.non-lu td { font-weight: 600; }
.table-dossiers .numero { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 0.88rem; white-space: nowrap; }
.retard { color: #dc2626; font-weight: 600; }

.filtres { background: var(--mairie-surface); border-radius: 0.75rem; box-shadow: var(--shadow-sm); padding: 0.9rem 1rem; margin-bottom: 1rem; }
.filtres .form-label { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--mairie-muted); font-weight: 700; margin-bottom: 0.25rem; }
.onglets-vues .nav-link { color: var(--mairie-muted); font-weight: 500; }
.onglets-vues .nav-link.active { color: var(--mairie-primary); font-weight: 700; }

.carte-laterale { position: sticky; top: 84px; }
@media (max-width: 991px) { .carte-laterale { position: static; } }
.infos-demandeur dt { font-size: 0.75rem; color: var(--mairie-muted); font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; }
.infos-demandeur dd { margin-bottom: 0.6rem; overflow-wrap: anywhere; }

/* Constructeur de formulaire */
.champ-ligne { border: 1px solid #e7e5f5; border-radius: 0.6rem; margin-bottom: 0.6rem; background: #fff; }
.champ-ligne .champ-entete { display: flex; align-items: center; gap: 0.6rem; padding: 0.6rem 0.8rem; }
.champ-ligne .champ-type { width: 32px; height: 32px; flex-shrink: 0; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; background: var(--mairie-pale); color: var(--mairie-primary); }
.champ-ligne .champ-libelle { flex: 1; min-width: 0; font-weight: 600; }
.champ-ligne .champ-libelle small { font-weight: 400; color: var(--mairie-muted); display: block; }
.champ-ligne.mise-en-page { background: #fbfbfe; border-style: dashed; }
.champ-ligne .champ-edition { border-top: 1px solid #eceaf7; padding: 0.9rem; background: #fcfcff; border-radius: 0 0 0.6rem 0.6rem; }
.btn-ordre { padding: 0.1rem 0.4rem; line-height: 1.2; }

/* ----- Historique (repris de la réservation) ----- */
.timeline-historique { margin: 0.5rem 0 0; padding-left: 0; list-style: none; }
.timeline-historique li { display: flex; gap: 0.7rem; padding-bottom: 0.85rem; position: relative; }
.timeline-historique li:not(:last-child)::before {
  content: ""; position: absolute; left: 13px; top: 28px; bottom: 0; width: 2px; background: #e5e7eb;
}
.timeline-historique .hist-icon {
  flex: 0 0 28px; width: 28px; height: 28px; border-radius: 50%;
  background: var(--mairie-primary); color: #fff;
  display: inline-flex; align-items: center; justify-content: center; font-size: 0.8rem; z-index: 1;
}
.timeline-historique .hist-corps { padding-top: 3px; font-size: 0.86rem; }

/* ----- Toasts et états vides (repris) ----- */
.toast-container-fixed { position: fixed; bottom: 1.5rem; right: 1.5rem; z-index: 1080; max-width: calc(100vw - 2rem); }
.empty-state-v2 { text-align: center; padding: 2.5rem 1rem; }
.empty-state-illu {
  width: 78px; height: 78px; border-radius: 50%; margin: 0 auto 1rem;
  display: flex; align-items: center; justify-content: center; font-size: 2.2rem;
}
.empty-state-illu-primary   { background: #ede9fe; color: var(--mairie-primary); }
.empty-state-illu-success   { background: #d1fae5; color: #065f46; }
.empty-state-illu-warning   { background: #fef3c7; color: #92400e; }
.empty-state-illu-danger    { background: #fee2e2; color: #991b1b; }
.empty-state-illu-info      { background: #dbeafe; color: #1e40af; }
.empty-state-illu-secondary { background: #f1f5f9; color: #475569; }
.empty-state-title { font-size: 1.15rem; font-weight: 600; margin-bottom: 0.4rem; }
.empty-state-desc { color: var(--mairie-muted); max-width: 48ch; margin: 0 auto 1.25rem; }
.empty-state-actions { display: flex; gap: 0.5rem; justify-content: center; flex-wrap: wrap; }

/* ----- Pied de page ----- */
footer.footer {
  flex-shrink: 0; background-color: var(--mairie-primary);
  color: rgba(255,255,255,0.8); padding: 1.5rem 0; margin-top: 3rem;
  text-align: center; font-size: 0.9rem;
}
footer.footer a { color: var(--mairie-accent); }
/* v1.1.0 : comme la réservation — les blasons au-dessus du texte, le badge
   BETA qui pulse doucement */
.footer-blasons { margin-bottom: 0.9rem; }
.footer-blasons img { height: 52px; width: auto; }
footer.footer .badge { vertical-align: middle; animation: pulse-beta 2s ease-in-out infinite; }
@keyframes pulse-beta { 0%, 100% { opacity: 1; } 50% { opacity: 0.7; } }
footer.footer .coordonnees { font-size: 0.85rem; color: rgba(255,255,255,0.7); margin-bottom: 0.6rem; }

/* ----- Impression (un dossier s'imprime proprement) ----- */
@media print {
  .navbar-mairie, footer.footer, .no-print, .toast-container-fixed { display: none !important; }
  main.main-container { padding-top: 0; }
  .section-card { box-shadow: none; border: 1px solid #d1d5db; break-inside: avoid; }
  .carte-laterale { position: static; }
  a[href]::after { content: ""; }
  body { background: #fff; }
}

/* ============================================================
   Page de connexion — LA MÊME dans les quatre applis de la mairie
   (réservation v2.115.7, Cap v0.6.4, Vigie v1.7.2, démarches v1.2.2) :
   celle de la réservation, choisie par Loric le 10/11/2026. Le logo de la
   commune au-dessus de la carte, juste dessous le picto et le nom de
   l'appli (proposition B : le picto au trait blanc dans un rond bleu
   foncé, le nom sur deux lignes comme dans la barre) ; dans la carte, la
   bulle « Connexion » (.section-title et .icon-bubble, déjà les mêmes
   partout), les champs, « Mot de passe oublié ? » à droite, les boutons,
   une note.
   Bloc identique dans les quatre style.css : le recopier s'il change.
   ============================================================ */
.connexion-logo { text-align: center; margin-bottom: 0.75rem; }
.connexion-logo img { width: auto; height: auto; max-width: 200px; max-height: 150px; }
.connexion-appli { display: flex; align-items: center; justify-content: center; gap: 0.75rem; margin-bottom: 1.25rem; }
.connexion-appli-rond {
  display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0;
  width: 50px; height: 50px; border-radius: 50%; background: var(--mairie-primary);
}
.connexion-appli-rond img { width: 32px; height: 32px; }
.connexion-appli-nom { font-size: 1.3rem; font-weight: 800; line-height: 1.15; color: var(--mairie-primary); }
.connexion-appli-ligne2 { font-size: 0.9rem; line-height: 1.25; color: var(--mairie-muted, #6c757d); }
.connexion-oubli { text-align: right; margin-bottom: 1rem; font-size: 0.875rem; }
.connexion-oubli a { color: var(--bs-link-color, #0d6efd); text-decoration: none; }
.connexion-oubli a:hover, .connexion-oubli a:focus { text-decoration: underline; }
.connexion-note { margin: 1rem 0 0; text-align: center; font-size: 0.875rem; color: var(--mairie-muted, #6c757d); }
/* Edge ajoute son propre œil dans les champs de mot de passe : masqué là où
   l'appli a déjà le sien (bouton bi-eye dans le même .input-group), sinon il y
   en a deux côte à côte. Ailleurs, celui d'Edge reste. */
.input-group:has(.bi-eye, .bi-eye-slash) input::-ms-reveal { display: none; }

/* ---------- MyAD ---------- */
/* Mes applications : les cartes reprennent .carte-demarche */
.carte-appli { display: flex; gap: 0.9rem; align-items: flex-start; text-decoration: none; }
.carte-appli-inactive { cursor: default; background: #fafafc; }
.carte-appli-inactive:hover { transform: none; box-shadow: var(--shadow-sm); }
/* Comptes et accès : le rôle d'une personne dans une application */
.badge-acces { background: #ede9fe; color: var(--mairie-primary); font-weight: 600; }
.table-acces td:first-child { white-space: nowrap; }
.table-acces select { min-width: 14rem; }

/* ----- Pages légales (inc/ui/page_legale.php) et leurs liens du pied de page.
   Bloc identique dans les cinq applis de la mairie. ----- */
.footer-legal {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 0.3rem 1.4rem;
  margin-top: 0.9rem; font-size: 0.85rem;
}
footer.footer .footer-legal a { color: rgba(255,255,255,0.85); }
footer.footer .footer-legal a:hover { color: #fff; }
.page-legale { max-width: 48rem; margin: 0 auto; padding: 1rem 0 2rem; }
.page-legale-rubrique {
  margin: 0 0 0.3rem; font-size: 0.85rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.05em; color: #5b6478;
}
.page-legale h1 { font-size: 1.9rem; font-weight: 700; color: var(--mairie-primary); margin-bottom: 1rem; }
.page-legale h2 { font-size: 1.2rem; font-weight: 700; color: var(--mairie-primary); margin: 2rem 0 0.5rem; }
.page-legale .lead { font-size: 1.1rem; }
.page-legale a { color: var(--mairie-primary); }
.page-legale-tableau { font-size: 0.92rem; }
.page-legale-tableau th { font-weight: 600; }
.page-legale-tableau tbody th { width: 36%; }
.page-legale-tableau td:last-child { width: 28%; }
.page-legale-voir { margin-top: 2.5rem; padding-top: 1rem; border-top: 1px solid #dde3ee; }
