:root {
    /* =====================================================================
       PALETTE DU SITE
       Toutes les couleurs du site sont définies ici. Pour adapter Vigie
       aux couleurs d'une mairie, il suffit en général de changer
       --brand (couleur principale) et --accent (couleur d'accent),
       ainsi que leurs déclinaisons claires/foncées juste en dessous.
       Les ombres et transparences sont calculées à partir de ces
       couleurs (color-mix), elles suivent donc automatiquement.
       ===================================================================== */

    /* Couleur principale (bandeau, boutons, liens, titres) */
    --brand: #1d4e89;
    --brand-ink: #ffffff;       /* texte posé sur --brand */
    --brand-light: #2a6bb3;     /* dégradés (en-tête de l'aide) */
    --brand-lighter: #3a7fc8;   /* dégradés (en-tête de l'aide) */
    --brand-bg: #e6eef8;        /* fond très clair teinté de --brand */
    --brand-ink-muted: #dbe6f3; /* texte secondaire posé sur --brand */

    /* Couleur d'accent (page d'accueil, appels à l'action) */
    --accent: #ff7643;          /* fonds, formes, boutons (texte foncé dessus) */
    --accent-ink: #b8431a;      /* texte orangé lisible sur fond blanc */
    --accent-bg: #fff1eb;       /* fond très clair teinté d'accent */
    --accent-soft: #ffd2c0;     /* texte clair d'accent posé sur --brand */
    --accent-muted-ink: #5b4a42; /* texte secondaire sur les sections teintées */

    /* Fonds, surfaces, textes et bordures */
    --bg: #f4f6f8;              /* fond de page */
    --surface: #ffffff;         /* cartes, champs, pied de page */
    --ink: #1c2530;             /* texte principal */
    --muted: #5c6b7a;           /* texte secondaire */
    --line: #dde3e9;            /* bordures légères */
    --line-soft: #d9e0e7;       /* séparateur du pied de page */
    --line-strong: #c3ccd5;     /* bordures des champs de formulaire */
    --neutral-bg: #eef1f4;      /* fond neutre */
    --on-color: #ffffff;        /* texte/icône posé sur une couleur vive */
    --logo-bg: #ffffff;         /* fond derrière le logo dans le bandeau */
    --shadow-color: #000000;    /* base des ombres portées */

    /* États : succès, avertissement, critique */
    --good: #1f7a4d;
    --good-bg: #e3f3ea;
    --good-line: #b9dfca;
    --warn: #9a5b00;
    --warn-strong: #8a5100;     /* variante plus foncée (aide) */
    --warn-bg: #fdf0d9;
    --warn-line: #f0d9ac;
    --crit: #b42318;
    --crit-bg: #fde8e6;
    --crit-line: #f4bdb7;

    /* Teintes complémentaires (pages d'aide et mentions légales) */
    --purple: #6b3fa0;
    --purple-bg: #f1eafa;
    --teal: #0f6e78;
    --teal-bg: #e2f4f5;

    /* Couleur de marque externe (bouton d'export Excel) */
    --excel: #107c41;

    /* Divers */
    --radius: 10px;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font: 16px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

a { color: var(--brand); }
h1 { font-size: 1.6rem; margin: 0 0 .5rem; }
h2 { font-size: 1.15rem; margin: 0 0 .75rem; }
h3 { font-size: 1rem; margin: 1.25rem 0 .5rem; }
code { background: var(--neutral-bg); padding: 1px 6px; border-radius: 4px; font-size: .9em; }
.muted { color: var(--muted); }
.late { color: var(--crit); }

/* En-tête */
.topbar { background: var(--brand); color: var(--brand-ink); }
.topbar__inner { max-width: 1200px; margin: 0 auto; padding: .6rem 1.25rem; display: flex; align-items: center; gap: .75rem 1.25rem; }
.brand { color: inherit; text-decoration: none; display: flex; align-items: center; gap: .65rem; flex: none; }
.brand__logo { background: var(--logo-bg); border-radius: 8px; padding: 3px 6px; display: flex; }
.brand__logo img { display: block; height: 40px; width: auto; }
.brand__text { display: flex; flex-direction: column; line-height: 1.15; }
.brand__name { font-weight: 700; font-size: 1.25rem; letter-spacing: .02em; }
.brand__org { font-size: .8rem; opacity: .85; }
.topbar__menu { display: flex; align-items: center; gap: .5rem 1.5rem; flex: 1; min-width: 0; }
.nav { display: flex; justify-content: center; flex-wrap: wrap; gap: .25rem; flex: 1; }
.nav a, .nav__button { color: inherit; text-decoration: none; padding: .4rem .8rem; border-radius: 6px; white-space: nowrap; }
.nav a:hover, .nav a[aria-current="page"], .nav__button:hover, .nav__button[data-current], .nav__group.is-open > .nav__button { background: color-mix(in srgb, var(--brand-ink) 18%, transparent); }
/* Sous-menus déroulants (Référentiel, Administration) */
.nav__group { position: relative; }
.nav__button { display: flex; align-items: center; gap: .4rem; font: inherit; background: none; border: 0; cursor: pointer; }
.nav__button::after {
    content: ""; width: .4rem; height: .4rem; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor;
    transform: translateY(-2px) rotate(45deg); transition: transform .15s;
}
.nav__group.is-open > .nav__button::after { transform: translateY(1px) rotate(-135deg); }
.nav__sub {
    display: none; position: absolute; top: calc(100% + .35rem); left: 0; z-index: 20; min-width: 100%;
    background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-radius: 8px; padding: .3rem;
    box-shadow: 0 8px 24px color-mix(in srgb, var(--ink) 18%, transparent);
}
.nav__group.is-open > .nav__sub,
html:not(.js) .nav__group:hover > .nav__sub,
html:not(.js) .nav__group:focus-within > .nav__sub { display: block; }
.nav__sub a { display: block; }
.nav__sub a:hover { background: var(--neutral-bg); }
.nav__sub a[aria-current="page"] { background: var(--neutral-bg); color: var(--brand); font-weight: 600; }
.nav__sub a:focus-visible { outline-color: var(--brand); }
.session { display: flex; align-items: center; gap: .4rem; font-size: .9rem; white-space: nowrap; min-width: 0; }
.session span { max-width: 14rem; overflow: hidden; text-overflow: ellipsis; }
.session a { color: inherit; }
.session__logout { display: flex; align-items: center; justify-content: center; width: 2.25rem; height: 2.25rem; border-radius: 6px; flex: none; }
.session__logout:hover { background: color-mix(in srgb, var(--brand-ink) 18%, transparent); }
.topbar a:focus-visible, .nav-toggle:focus-visible, .nav__button:focus-visible { outline: 2px solid var(--brand-ink); outline-offset: 2px; }
.nav-toggle {
    display: none; align-items: center; gap: .5rem; margin-left: auto; font: inherit; color: inherit; cursor: pointer;
    background: color-mix(in srgb, var(--brand-ink) 12%, transparent); border: 1px solid color-mix(in srgb, var(--brand-ink) 45%, transparent); border-radius: 8px; padding: .45rem .75rem;
}
.nav-toggle__icon, .nav-toggle__icon::before, .nav-toggle__icon::after {
    display: block; width: 18px; height: 2px; background: currentColor; border-radius: 2px; transition: transform .15s, opacity .15s;
}
.nav-toggle__icon { position: relative; }
.nav-toggle__icon::before, .nav-toggle__icon::after { content: ""; position: absolute; left: 0; }
.nav-toggle__icon::before { top: -6px; }
.nav-toggle__icon::after { top: 6px; }
.topbar.is-open .nav-toggle__icon { background: transparent; }
.topbar.is-open .nav-toggle__icon::before { transform: translateY(6px) rotate(45deg); }
.topbar.is-open .nav-toggle__icon::after { transform: translateY(-6px) rotate(-45deg); }

/* En-tête replié : le menu passe sous la barre, ouvert par le bouton « Menu ». */
@media (max-width: 1199px) {
    .topbar__inner { flex-wrap: wrap; }
    .topbar__menu { flex: 1 0 100%; flex-direction: column; align-items: stretch; gap: .5rem; }
    .nav { flex-direction: column; gap: .15rem; }
    .nav a, .nav__button { padding: .65rem .8rem; }
    /* Dans le menu replié, les sous-menus sont toujours dépliés : le bouton devient un simple intitulé. */
    .nav__button { width: 100%; pointer-events: none; font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; opacity: .8; padding-bottom: .2rem; }
    .nav__button, .nav__button:hover, .nav__button[data-current], .nav__group.is-open > .nav__button { background: none; }
    .nav__button::after { display: none; }
    .nav .nav__sub { display: block; position: static; background: none; color: inherit; border: 0; box-shadow: none; padding: 0 0 0 .8rem; }
    .nav__sub a:hover, .nav__sub a[aria-current="page"] { background: color-mix(in srgb, var(--brand-ink) 18%, transparent); color: inherit; font-weight: 400; }
    .nav__sub a:focus-visible { outline-color: var(--brand-ink); }
    .session span { max-width: none; }
    .session { justify-content: space-between; padding: .65rem .8rem 0; border-top: 1px solid color-mix(in srgb, var(--brand-ink) 25%, transparent); }
    /* Sans JavaScript, le menu reste affiché en entier. */
    .js .nav-toggle { display: flex; }
    .js .topbar:not(.is-open) .topbar__menu { display: none; }
}
@media (max-width: 380px) {
    .brand__logo img { height: 34px; }
}
@media (prefers-reduced-motion: reduce) {
    .nav-toggle__icon, .nav-toggle__icon::before, .nav-toggle__icon::after, .nav__button::after { transition: none; }
}

.banner { text-align: center; padding: .4rem 1rem; font-size: .9rem; }
.banner--demo { background: var(--warn-bg); color: var(--warn); border-bottom: 1px solid var(--warn-line); }

/* Pages */
.page { max-width: 1200px; margin: 0 auto; padding: 1.5rem 1.25rem 3rem; }
.page__head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: 1rem; margin-bottom: 1rem; }
.actions { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.actions form, form.inline { display: inline; margin: 0; }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.25rem; margin-bottom: 1.25rem; }
.card--narrow { max-width: 420px; margin: 3rem auto; }
.login__logo { display: block; height: 120px; width: auto; max-width: 100%; margin: 0 auto 1rem; }
.card__head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: 1rem; }
.two-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr)); gap: 1.25rem; }
.two-cols .card { margin-bottom: 0; }
.two-cols + .card { margin-top: 1.25rem; }
.quote { border-left: 4px solid var(--brand); padding-left: 1rem; margin: 0; }

/* Messages */
.flash { padding: .75rem 1rem; border-radius: 8px; margin-bottom: 1rem; border: 1px solid; }
.flash--success { background: var(--good-bg); color: var(--good); border-color: var(--good-line); }
.flash--error { background: var(--crit-bg); color: var(--crit); border-color: var(--crit-line); }

/* Boutons */
.btn {
    display: inline-block; font: inherit; cursor: pointer; text-decoration: none;
    padding: .5rem 1rem; border-radius: 8px; border: 1px solid var(--line);
    background: var(--surface); color: var(--ink);
}
.btn:hover { border-color: var(--brand); }
.btn--primary { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.btn--primary:hover { filter: brightness(1.1); }
.btn--small { padding: .2rem .6rem; font-size: .85rem; }

/* Formulaires */
.form label { display: block; font-weight: 600; margin: .9rem 0 .3rem; }
.form input[type="text"], .form input[type="email"], .form input[type="password"], .form input[type="tel"],
.form input[type="number"], .form input[type="date"], .form input[type="time"], .form input[type="file"], .form select, .form textarea,
.filters input, .filters select {
    width: 100%; font: inherit; padding: .5rem .7rem; border: 1px solid var(--line-strong); border-radius: 8px; background: var(--surface);
}
.form input:focus, .form select:focus, .form textarea:focus, .filters input:focus, .filters select:focus {
    outline: 2px solid var(--brand); outline-offset: 1px;
}
.form .btn { margin-top: 1.25rem; }
.form .help-text, .form small { display: block; color: var(--muted); font-size: .85rem; margin-top: .25rem; }
.form div[id$="_mainRole"] { display: grid; grid-template-columns: auto 1fr; gap: .4rem .5rem; align-items: center; }
.form div[id$="_mainRole"] input { margin: 0; }
.form div[id$="_mainRole"] label { font-weight: 400; margin: 0; }
.form__footer { display: flex;justify-content: space-between; align-items: end; }
.table form.inline + form.inline { margin-left: .25rem; }
.form ul { color: var(--crit); padding-left: 1.1rem; margin: .25rem 0; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 0 1.25rem; }
fieldset { border: 1px solid var(--line); border-radius: 8px; margin: 1.25rem 0 0; padding: 1rem; }
legend { font-weight: 600; padding: 0 .4rem; }
.contact { display: flex; gap: .75rem; align-items: flex-end; margin-bottom: .75rem; }
.contact > div { flex: 1; display: grid; grid-template-columns: repeat(3, 1fr); gap: .75rem; }
.contact .btn { margin-top: 0; }
.checklist { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: .15rem 1rem; }
.checklist--scroll { max-height: 22rem; overflow-y: auto; margin-top: .75rem; }
.form .checklist label { display: flex; align-items: center; gap: .5rem; font-weight: 400; margin: .2rem 0; }
.form .checklist label[hidden] { display: none; }
.form .checklist input { margin: 0; flex: none; }
.filters { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1rem; }
.filters input { flex: 2; min-width: 220px; }
.filters select { flex: 1; min-width: 160px; }

/* Tableaux */
.table { width: 100%; border-collapse: collapse; }
.table th { text-align: left; font-size: .85rem; color: var(--muted); font-weight: 600; border-bottom: 2px solid var(--line); padding: .5rem; }
.table td { border-bottom: 1px solid var(--line); padding: .6rem .5rem; vertical-align: middle; }
.row--late { background: var(--crit-bg); }
.row--inactive { color: var(--muted); }

/* Pagination */
.pagination { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .5rem; margin-top: 1rem; }
.pagination__pages { display: flex; flex-wrap: wrap; align-items: center; gap: .25rem; }
.pagination__link { display: inline-block; min-width: 2.25rem; padding: .35rem .7rem; text-align: center; text-decoration: none; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--brand); }
a.pagination__link:hover { border-color: var(--brand); }
.pagination__link--current { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); font-weight: 600; }
.pagination__link--disabled { color: var(--muted); background: var(--neutral-bg); }
.pagination__gap { color: var(--muted); padding: 0 .15rem; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* Pastilles */
.badge { display: inline-block; padding: .1rem .6rem; border-radius: 999px; font-size: .8rem; font-weight: 600; background: var(--neutral-bg); }
.badge--good { background: var(--good-bg); color: var(--good); }
.badge--warn { background: var(--warn-bg); color: var(--warn); }
.badge--crit { background: var(--crit-bg); color: var(--crit); }
.badge--neutral, .badge--status-draft, .badge--status-closed { background: var(--neutral-bg); color: var(--muted); }
.badge--status-running { background: var(--good-bg); color: var(--good); }
.badge--status-paused { background: var(--warn-bg); color: var(--warn); }

/* Compteurs et progression */
.counters { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .75rem; margin-top: 1rem; }
.counter { border-radius: 8px; padding: .75rem 1rem; background: var(--neutral-bg); }
.counter__n { font-size: 1.8rem; font-weight: 700; line-height: 1.1; }
.counter__label { font-size: .85rem; }
.counter--good { background: var(--good-bg); color: var(--good); }
.counter--warn { background: var(--warn-bg); color: var(--warn); }
.counter--crit { background: var(--crit-bg); color: var(--crit); }
.progress { height: 10px; background: var(--neutral-bg); border-radius: 999px; overflow: hidden; margin-top: .75rem; }
.progress__bar { height: 100%; background: var(--brand); }

/* Détails */
.details { display: grid; grid-template-columns: max-content 1fr; gap: .4rem 1rem; margin: 0; }
.details dt { color: var(--muted); }
.details dd { margin: 0; }
.timeline { list-style: none; padding: 0; margin: 0; }
.timeline li { padding: .4rem 0; border-bottom: 1px solid var(--line); }
.timeline time { color: var(--muted); margin-right: .5rem; font-variant-numeric: tabular-nums; }

@media (max-width: 640px) {
    .contact { flex-direction: column; align-items: stretch; }
    .contact > div { grid-template-columns: 1fr; }
    .table { display: block; overflow-x: auto; }
}

/* Menu : pastille (demandes en attente) et lien de connexion de la page d'accueil */
.nav__count { display: inline-block; min-width: 1.4rem; padding: 0 .4rem; margin-left: .2rem; border-radius: 999px; background: var(--surface); color: var(--brand); font-size: .8rem; font-weight: 700; text-align: center; }
.topbar__login { margin-left: auto; color: inherit; text-decoration: none; padding: .4rem .8rem; border: 1px solid color-mix(in srgb, var(--brand-ink) 50%, transparent); border-radius: 6px; white-space: nowrap; }
.topbar__login:hover { background: color-mix(in srgb, var(--brand-ink) 18%, transparent); }

/* Page d'accueil publique */
.btn--large { padding: .7rem 1.4rem; font-size: 1.05rem; font-weight: 600; }
.btn--danger { color: var(--crit); border-color: var(--crit-line); }
.btn--danger:hover { border-color: var(--crit); background: var(--crit-bg); }
.flash--warn { background: var(--warn-bg); color: var(--warn); border-color: var(--warn-line); }
.card--center { text-align: center; }
.page--home { max-width: 1040px; }
.page--home h2 { font-size: 1.4rem; }
.hero { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 2rem; align-items: center; padding: 2rem 0 1rem; }
.hero__kicker { margin: 0 0 .5rem; color: var(--brand); font-weight: 600; text-transform: uppercase; letter-spacing: .06em; font-size: .85rem; }
.hero h1 { font-size: clamp(1.8rem, 4.5vw, 2.6rem); line-height: 1.15; margin-bottom: 1rem; text-wrap: balance; }
.hero__lead { font-size: 1.15rem; max-width: 38rem; margin: 0 0 1.5rem; }
.hero__facts { list-style: none; margin: 0; padding: 1.25rem 1.5rem; background: var(--brand); color: var(--brand-ink); border-radius: var(--radius); display: grid; gap: .9rem; }
.hero__facts li { padding-left: 1.6rem; position: relative; }
.hero__facts li::before { content: ""; position: absolute; left: 0; top: .35rem; width: .9rem; height: .5rem; border-left: 3px solid currentColor; border-bottom: 3px solid currentColor; transform: rotate(-45deg); }
.home-section { margin-top: 2.5rem; scroll-margin-top: 1rem; }
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.25rem; }
.steps__item { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.25rem; }
.steps__item h3 { margin: .75rem 0 .4rem; font-size: 1.1rem; }
.steps__item p { margin: 0; }
.steps__n { display: flex; align-items: center; justify-content: center; width: 2.4rem; height: 2.4rem; border-radius: 50%; background: var(--brand); color: var(--brand-ink); font-weight: 700; font-size: 1.15rem; }
.keys { list-style: none; margin: .75rem 0 0; padding: 0; display: grid; gap: .4rem; }
.keys kbd { display: inline-flex; align-items: center; justify-content: center; width: 1.9rem; height: 1.9rem; margin-right: .5rem; border: 1px solid var(--line-strong); border-bottom-width: 3px; border-radius: 6px; background: var(--neutral-bg); font: inherit; font-weight: 700; }
.ticks { margin: 0 0 1rem; padding-left: 1.2rem; display: grid; gap: .4rem; }
.card--form { padding: 1.5rem; }
.grid--address { grid-template-columns: 2fr 1fr; }
.radios { display: grid; gap: .4rem; }
.form .radios label, .form .consent label { display: flex; align-items: flex-start; gap: .6rem; font-weight: 400; margin: 0; }
.form .radios input, .form .consent input { margin: .3rem 0 0; flex: none; width: 1.1rem; height: 1.1rem; }
.consent { margin-top: 1.25rem; padding: 1rem; background: var(--neutral-bg); border-radius: 8px; }
#requester { margin-top: 1rem; padding-top: .25rem; border-top: 1px solid var(--line); }
#requester[hidden] { display: none; }
/* Champ piège anti-robots : hors écran, ignoré des lecteurs d'écran (aria-hidden) et du clavier. */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.home-footer { margin-top: 2rem; text-align: center; }
@media (max-width: 760px) {
    .hero { grid-template-columns: 1fr; padding-top: 1rem; gap: 1.25rem; }
    .grid--address { grid-template-columns: 1fr; }
    .hero .btn--large { flex: 1 1 auto; text-align: center; }
}

/* Demandes d'inscription (backoffice) */
.tabs { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: 1rem; }
.tabs__link { padding: .4rem .9rem; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--ink); text-decoration: none; }
.tabs__link:hover { border-color: var(--brand); }
.tabs__link[aria-current="page"] { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); font-weight: 600; }
.tabs__count { font-variant-numeric: tabular-nums; opacity: .8; margin-left: .2rem; }
.decision { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.25rem; }
.decision__box { border: 1px solid var(--line); border-radius: 8px; padding: 1rem; margin: 0; }
.decision__box h3 { margin-top: 0; }

/* Paramètres : horaires d'ouverture */
.table-wrap { overflow-x: auto; }
.hours-form th[scope="row"] { color: var(--ink); font-size: 1rem; white-space: nowrap; border-bottom: 1px solid var(--line); }
.hours-form__slot { display: inline-flex; align-items: center; gap: .4rem; }
.form .hours-form input[type="time"] { width: auto; min-width: 7rem; }
.hours-form__errors td { border-bottom: 1px solid var(--line); padding-top: 0; }
.form .hours-form__errors ul { margin: 0; }

/* Page d'accueil : contacter la mairie */
.contact__address { font-style: normal; margin: 0 0 1rem; line-height: 1.5; }
.contact__lines { list-style: none; margin: 0; padding: 0; display: grid; gap: .35rem; }
.hours { width: 100%; border-collapse: collapse; }
.hours th, .hours td { text-align: left; padding: .4rem 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.hours th { font-weight: 600; padding-right: 1rem; white-space: nowrap; }
.hours tr.is-today th, .hours tr.is-today td { color: var(--brand); font-weight: 700; }
.hours__closed { color: var(--muted); }

/* Nouvelle campagne : périmètre et message vocal côte à côte */
.campaign-split { display: grid; grid-template-columns: 1fr; gap: 0 1.25rem; }
.campaign-split > fieldset { min-width: 0; }
.campaign-split > fieldset { padding-top: .5rem; }
.campaign-split > fieldset > div:first-of-type > label { margin-top: 0; }
.campaign-split__note { font-size: .85rem; line-height: 1.45; margin: .75rem 0 0; }
.campaign-split__message { display: flex; flex-direction: column; }
.campaign-split__message > div { display: flex; flex-direction: column; flex: 1; }
.campaign-split__message textarea { flex: 1; min-height: 8rem; resize: vertical; }
@media (min-width: 900px) {
    .campaign-split { grid-template-columns: 1fr 1fr; align-items: stretch; }
}

/* Nouvelle campagne : rappel des horaires de la mairie */
.schedule__rule { margin: 0 0 .75rem; color: var(--muted); }
.schedule__week { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: .5rem; margin-bottom: .5rem; }
.schedule__day { display: flex; flex-direction: column; gap: .3rem; padding: .6rem .5rem; border-radius: 10px; border: 2px solid transparent; background: var(--brand-bg); text-align: center; transition: border-color .15s, background .15s; }
.schedule__day.is-closed { background: var(--neutral-bg); color: var(--muted); }
.schedule__day.is-selected { border-color: var(--brand); background: var(--surface); box-shadow: 0 6px 14px color-mix(in srgb, var(--brand) 15%, transparent); }
.schedule__day.is-closed.is-selected { border-color: var(--crit); }
.schedule__name { font-weight: 700; font-size: .9rem; color: var(--brand); }
.schedule__day.is-closed .schedule__name { color: var(--muted); }
.schedule__slot { display: block; padding: .15rem .3rem; border-radius: 6px; background: var(--surface); color: var(--ink); font-size: .82rem; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.schedule__day.is-selected .schedule__slot { background: var(--brand-bg); }
.schedule__closed { font-size: .82rem; font-style: italic; }
.schedule__tag { display: inline-block; margin-left: .3rem; padding: 0 .4rem; border-radius: 999px; background: var(--accent-bg); color: var(--accent-ink); font-size: .7rem; font-weight: 700; vertical-align: 1px; }
.schedule__day .schedule__tag { display: block; width: max-content; margin: .15rem auto 0; }
.schedule__picked { margin-top: .9rem; padding: .9rem 1rem; border-radius: 10px; background: var(--neutral-bg); }
.schedule__picked p { margin: 0 0 .5rem; }
.schedule__picked p:last-child { margin-bottom: 0; }
.schedule__hint { color: var(--muted); font-size: .92rem; }
.schedule__choices { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: .5rem; }
.form .schedule__choice { margin: 0; padding: .45rem 1rem; border-radius: 999px; border: 2px solid var(--brand); background: var(--surface); color: var(--brand); font: inherit; font-weight: 700; font-variant-numeric: tabular-nums; cursor: pointer; }
.form .schedule__choice:hover { background: var(--brand-bg); }
.form .schedule__choice[aria-pressed="true"] { background: var(--brand); color: var(--brand-ink); }
.form .schedule__choice[aria-pressed="true"]::before { content: "✓ "; }
.form .schedule__choice:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.schedule__warn { padding: .5rem .75rem; border-radius: 8px; background: var(--crit-bg); color: var(--crit); font-weight: 600; }
@media (max-width: 760px) {
    .schedule__week { grid-template-columns: repeat(auto-fill, minmax(6.5rem, 1fr)); }
}
@media (prefers-reduced-motion: reduce) { .schedule__day { transition: none; } }

/* Campagne : durée estimée */
.estimate { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1rem; margin-bottom: 1rem; }
.estimate__item { background: var(--neutral-bg); border-radius: 8px; padding: .9rem 1rem; }
.estimate__value { font-size: 1.6rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.estimate__label { font-size: .9rem; }

/* Page d'accueil : situations d'alerte */
.situations { list-style: none; margin: 0 0 1rem; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: .75rem; }
.situations li { background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--brand); border-radius: 8px; padding: .75rem 1rem; }
.situations strong { display: block; margin-bottom: .15rem; }

/* Notifications */
.session__bell { position: relative; display: flex; align-items: center; justify-content: center; width: 2.25rem; height: 2.25rem; border-radius: 6px; flex: none; }
.session__bell:hover, .session__bell[aria-current="page"] { background: color-mix(in srgb, var(--brand-ink) 18%, transparent); }
.session .session__badge { position: absolute; top: -.2rem; right: -.3rem; min-width: 1.15rem; max-width: none; padding: 0 .3rem; border-radius: 999px; background: var(--crit); color: var(--on-color); font-size: .7rem; font-weight: 700; line-height: 1.15rem; text-align: center; overflow: visible; }
.session .session__badge[hidden] { display: none; }
.notif-list { list-style: none; margin: 0 0 1rem; padding: 0; }
.notif { border-bottom: 1px solid var(--line); }
.notif a { display: grid; gap: .15rem; padding: .75rem .5rem .75rem 1rem; color: var(--ink); text-decoration: none; border-left: 4px solid transparent; }
.notif a:hover { background: var(--neutral-bg); }
.notif__title { font-weight: 600; }
.notif__date { font-size: .85rem; }
.notif--unread a { background: var(--neutral-bg); border-left-color: var(--brand); }
.notif--unread .notif__title::after { content: ""; display: inline-block; width: .5rem; height: .5rem; margin-left: .4rem; border-radius: 50%; background: var(--brand); vertical-align: middle; }
.notif--urgent .notif__title { color: var(--crit); }
.notif--urgent.notif--unread a { border-left-color: var(--crit); background: var(--crit-bg); }
.form .checklist--notif label { align-items: flex-start; margin: .5rem 0; }
.form .checklist--notif input { margin-top: .25rem; }

/* Visites à domicile */
.purposes { padding-left: 1.4rem; }
.purposes li { margin: .4rem 0; }
details.purposes { padding-left: 1.25rem; }
details.purposes summary { cursor: pointer; font-weight: 600; }
details.purposes ol { padding-left: 1.4rem; }
details.purposes li { margin: .4rem 0; }
.actions--spaced { margin-top: 1rem; }
.form .consent + div label { margin-top: 1rem; }

/* Lien d'évitement, pied de page, pages d'information */
.skip-link { position: absolute; left: .5rem; top: -4rem; z-index: 100; padding: .6rem 1rem; background: var(--surface); color: var(--brand); border: 2px solid var(--brand); border-radius: 8px; font-weight: 600; }
.skip-link:focus { top: .5rem; }
main:focus { outline: none; }
.site-footer { border-top: 1px solid var(--line-soft); background: var(--surface); width: 100%; position: fixed; bottom: 0; }
.site-footer__inner { max-width: 1200px; margin: 0 auto; padding: 0.45rem; display: flex; justify-content: center; flex-wrap: wrap; gap: .5rem 2rem; align-items: center; font-size: .95rem; }
.site-footer__a11y { display: inline-flex; align-items: center; gap: .5rem; }
.site-footer a[aria-current="page"] { font-weight: 600; }
.site-footer__version { color: var(--muted); font-size: .85em; font-variant-numeric: tabular-nums; white-space: nowrap; }
@media (max-width: 760px) {
    /* Petit écran : le pied de page n'est plus fixé (il masquait le contenu) et reste compact. */
    .site-footer { position: static; }
    .site-footer__inner { padding: .4rem .5rem; gap: .1rem .75rem; font-size: .78rem; line-height: 1.3; }
    .site-footer__inner a { padding: .15rem 0; }
    .site-footer__a11y { gap: .3rem; }
    .site-footer__a11y svg { width: 16px; height: 16px; }
}

/* Menu du haut toujours visible ; pied de page en bas de l'écran même sur une page courte (connexion). */
html { scroll-padding-top: 5.5rem; }
body { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }
.topbar { position: sticky; top: 0; z-index: 50; box-shadow: 0 1px 4px color-mix(in srgb, var(--shadow-color) 18%, transparent); }
.page { width: 100%; flex: 1 0 auto; }
.site-footer { flex: none; }
@media (max-width: 1199px) {
    /* Menu déplié sur petit écran : il défile s'il dépasse la hauteur de l'écran. */
    .topbar.is-open { max-height: 100vh; max-height: 100dvh; overflow-y: auto; }
}
@media print { .topbar { position: static; } }

/* Statistiques */
.table-scroll { overflow-x: auto; position: relative; } /* position : garde les libellés .sr-only dans le cadre */
.table--stats td, .table--stats th { text-align: right; vertical-align: top; white-space: nowrap; }
.table--stats thead th { white-space: normal; min-width: 5.5rem; }
.table--stats th:first-child { text-align: left; }
/* En-tête de tableau toujours visible (statistiques, registre) : sous la barre du haut quand la page défile ;
   sur petit écran, le tableau défile dans son cadre (horizontalement et verticalement), en-tête en haut du cadre. */
.table--sticky-head thead th { position: sticky; top: 4rem; background: var(--surface); z-index: 2; box-shadow: inset 0 -2px 0 var(--line); }
.table-scroll--sticky-head { overflow: visible; }
@media (max-width: 899px) {
    .table-scroll--sticky-head { overflow: auto; max-height: 75vh; max-height: 75dvh; }
    .table.table--sticky-head { display: table; overflow: visible; } /* le cadre défile, pas le tableau */
    .table--sticky-head thead th { top: 0; }
    /* Statistiques : la colonne des mois reste aussi visible. */
    .table--stats th:first-child { position: sticky; left: 0; background: var(--surface); z-index: 1; }
    .table--stats thead th:first-child { z-index: 3; }
}
.table--stats tfoot th, .table--stats tfoot td { font-weight: 700; border-top: 2px solid var(--line); }
.stat-delta, .stat-sub { display: block; font-size: .78rem; font-weight: 400; color: var(--muted); }
.counter .stat-delta, .counter .stat-sub { font-size: .8rem; }

/* Vigilance canicule */
.weather-alert { display: flex; flex-wrap: wrap; gap: .5rem 1rem; align-items: center; justify-content: space-between; }
.weather-status { margin: 0 0 1rem; }

/* Compteur de mots du message vocal */
.word-count { margin: .25rem 0 0; font-size: .85rem; color: var(--muted); }
.word-count--over { color: var(--crit); font-weight: 600; }

/* Icône d'une entrée du menu */
.nav__icon { flex: none; vertical-align: -3px; }

/* ---- Page d'accueil : couleur d'accent, mise en scène et animations ---- */
.btn--accent { background: var(--accent); border-color: var(--accent); color: var(--ink); font-weight: 600; box-shadow: 0 6px 16px color-mix(in srgb, var(--accent) 35%, transparent); }
.btn--accent:hover { border-color: var(--accent); filter: brightness(1.05); transform: translateY(-1px); }
.btn { transition: transform .15s, filter .15s, border-color .15s, box-shadow .15s; }
.accent-mark { background: linear-gradient(transparent 62%, color-mix(in srgb, var(--accent) 55%, transparent) 62%); border-radius: 2px; padding: 0 .1em; }
.eyebrow { margin: 0 0 .35rem; color: var(--brand); font-weight: 700; text-transform: uppercase; letter-spacing: .08em; font-size: .8rem; }
.eyebrow--accent { color: var(--accent-ink); }
.page--home h2 { font-size: clamp(1.35rem, 3vw, 1.75rem); line-height: 1.2; text-wrap: balance; }
.page--home h3 { font-size: 1.15rem; }
.home-section { margin-top: 3.5rem; scroll-margin-top: 5.5rem; }

.hero { padding: 2.5rem 0 1rem; grid-template-columns: minmax(0, 11fr) minmax(0, 9fr); }
.hero__facts { background: none; color: inherit; padding: 0; margin-top: 1.5rem; display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; font-size: .95rem; }
.hero__facts li::before { border-color: var(--accent-ink); }
.hero__art { display: flex; justify-content: center; }
.call { position: relative; width: min(100%, 320px); background: var(--brand); color: var(--brand-ink); border-radius: 28px; padding: 1.75rem 1.5rem 1.5rem; text-align: center; box-shadow: 0 24px 50px color-mix(in srgb, var(--brand) 30%, transparent); animation: float 6s ease-in-out infinite; }
.call::after { content: ""; position: absolute; inset: auto -18px -18px auto; width: 96px; height: 96px; border-radius: 50%; background: var(--accent); z-index: -1; }
.call__ring { position: relative; width: 84px; height: 84px; margin: 0 auto 1rem; border-radius: 50%; background: var(--accent); color: var(--ink); display: grid; place-items: center; }
.call__ring svg { position: relative; animation: ring 2.4s ease-in-out infinite; transform-origin: 50% 50%; }
.call__wave { position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--accent); opacity: 0; animation: wave 2.4s ease-out infinite; }
.call__wave:nth-child(2) { animation-delay: .6s; }
.call__wave:nth-child(3) { animation-delay: 1.2s; }
.call__who { margin: 0; font-weight: 700; font-size: 1.1rem; }
.call__say { margin: .35rem 0 1rem; font-size: .95rem; opacity: .9; }
.call__keys { list-style: none; margin: 0; padding: 0; display: grid; gap: .45rem; text-align: left; }
.call__key { display: flex; align-items: center; gap: .6rem; padding: .45rem .7rem; border-radius: 10px; background: color-mix(in srgb, var(--brand-ink) 12%, transparent); font-size: .95rem; animation: key 9s infinite; }
.call__key b { display: grid; place-items: center; width: 1.7rem; height: 1.7rem; border-radius: 7px; background: var(--surface); color: var(--brand); }
.call__key--2 { animation-delay: 3s; }
.call__key--3 { animation-delay: 6s; }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes wave { 0% { transform: scale(1); opacity: .9; } 100% { transform: scale(1.9); opacity: 0; } }
@keyframes ring { 0%, 60%, 100% { transform: rotate(0); } 10%, 30%, 50% { transform: rotate(-12deg); } 20%, 40% { transform: rotate(12deg); } }
@keyframes key { 0%, 4% { background: color-mix(in srgb, var(--brand-ink) 12%, transparent); color: var(--brand-ink); } 8%, 28% { background: var(--accent); color: var(--ink); } 33%, 100% { background: color-mix(in srgb, var(--brand-ink) 12%, transparent); color: var(--brand-ink); } }

.duo { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.25rem; }
.duo__card { display: block; padding: 1.5rem; border-radius: 16px; background: var(--surface); border: 1px solid var(--line); border-top: 5px solid var(--brand); color: inherit; text-decoration: none; transition: transform .2s, box-shadow .2s; }
.duo__card--visit { border-top-color: var(--accent); }
.duo__card:hover, .duo__card:focus-visible { transform: translateY(-4px); box-shadow: 0 14px 30px color-mix(in srgb, var(--ink) 12%, transparent); }
.duo__card h3 { margin: .9rem 0 .4rem; font-size: 1.25rem; }
.duo__card p { margin: 0 0 .9rem; }
.duo__icon { display: grid; place-items: center; width: 3.2rem; height: 3.2rem; border-radius: 14px; background: var(--brand-bg); color: var(--brand); }
.duo__card--visit .duo__icon { background: var(--accent-bg); color: var(--accent-ink); }
.duo__more { font-weight: 600; color: var(--brand); text-decoration: underline; text-underline-offset: 3px; }
.duo__card--visit .duo__more { color: var(--accent-ink); }

.chips { list-style: none; display: flex; flex-wrap: wrap; gap: .5rem; padding: 0; margin: 1rem 0 1.5rem; }
.chips li { padding: .35rem .85rem; border-radius: 999px; background: var(--brand-bg); color: var(--brand); font-weight: 600; font-size: .92rem; }
.steps__item { transition: transform .2s, box-shadow .2s; }
.steps__item:hover { transform: translateY(-3px); box-shadow: 0 10px 24px color-mix(in srgb, var(--ink) 10%, transparent); }
.keys kbd { background: var(--accent-bg); border-color: var(--accent); color: var(--ink); }

.home-section--tint { background: var(--accent-bg); border-radius: 20px; padding: 2rem 1.5rem; }
.home-section--tint .muted { color: var(--accent-muted-ink); }
.home-section--tint .purposes { background: var(--surface); border-left: 5px solid var(--accent); border-radius: 10px; padding: 1rem 1rem 1rem 2.4rem; margin: 1rem 0 1.75rem; }
.examples { list-style: none; margin: 1rem 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 1rem; }
.examples__item { background: var(--surface); border-radius: 14px; padding: 1.1rem; transition: transform .2s, box-shadow .2s; }
.examples__item:hover { transform: translateY(-3px); box-shadow: 0 10px 24px color-mix(in srgb, var(--accent-ink) 16%, transparent); }
.examples__icon { display: grid; place-items: center; width: 2.8rem; height: 2.8rem; border-radius: 50%; background: var(--accent); color: var(--ink); }
.examples__item h4 { margin: .75rem 0 .3rem; font-size: 1.05rem; }
.examples__item p { margin: 0; font-size: .97rem; }
.visit-how { background: var(--surface); border-radius: 14px; padding: 1.25rem; margin-top: 1.5rem; }
.visit-how h3 { margin-top: 0; }
.visit-how .ticks { margin-bottom: 0; }

/* Formulaire d'inscription simplifié */
.card--form { max-width: 720px; margin-inline: auto; padding: 1.75rem; border-top: 5px solid var(--accent); }
.form--simple .choice-tiles { border: 0; padding: 0; margin: 1rem 0 0; }
.form--simple .choice-tiles legend { font-weight: 600; padding: 0; margin-bottom: .4rem; }
.form--simple .choice-tiles .radios { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: .6rem; }
.form--simple .choice-tiles label { border: 2px solid var(--line); border-radius: 10px; padding: .7rem .9rem; cursor: pointer; align-items: center; }
.form--simple .choice-tiles label:has(input:checked) { border-color: var(--accent); background: var(--accent-bg); font-weight: 600; }
.form--simple .choice-tiles input { margin: 0; }
.form-more { margin-top: 1.25rem; border: 1px dashed var(--line-strong); border-radius: 10px; padding: .75rem 1rem; }
.form-more summary { cursor: pointer; font-weight: 600; color: var(--brand); }
.form-more[open] summary { margin-bottom: .5rem; }
.consent--accent { background: var(--accent-bg); margin-top: .75rem; }
.form__after { margin: 1rem 0 0; font-size: .92rem; }

/* Apparition au défilement : seulement avec JavaScript, et jamais si l'utilisateur réduit les animations. */
html.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; transition-delay: calc(var(--i, 0) * 110ms); }
html.js .reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
    html.js .reveal { opacity: 1; transform: none; transition: none; }
    .call, .call__ring svg, .call__wave, .call__key { animation: none; }
    .btn, .duo__card, .steps__item, .examples__item { transition: none; }
    .btn--accent:hover, .duo__card:hover, .steps__item:hover, .examples__item:hover { transform: none; }
}
@media (max-width: 760px) {
    .hero { grid-template-columns: 1fr; }
    .hero__art { order: -1; }
    .call { width: min(100%, 280px); padding: 1.25rem 1.1rem 1.1rem; }
    .call__say { display: none; }
    .home-section--tint { padding: 1.5rem 1rem; margin-inline: -.5rem; }
}

/* En-tête des visiteurs : demande d'inscription et espace agents */
.topbar__public { margin-left: auto; display: flex; align-items: center; gap: .5rem; }
.topbar__public .topbar__login { margin-left: 0; }
.topbar__cta { color: var(--ink); background: var(--accent); border: 1px solid var(--accent); text-decoration: none; font-weight: 600; padding: .4rem .9rem; border-radius: 6px; white-space: nowrap; }
.topbar__cta:hover { filter: brightness(1.06); }
.topbar__cta[aria-current="page"] { box-shadow: inset 0 0 0 2px var(--ink); }
@media (max-width: 520px) {
    .topbar__long { display: none; }
    .topbar__cta { text-transform: capitalize; }
    .topbar__cta, .topbar__public .topbar__login { padding: .35rem .6rem; font-size: .92rem; }
}

/* Appel à s'inscrire en bas de l'accueil */
.cta { display: flex; flex-wrap: wrap; gap: 1.25rem 2rem; align-items: center; justify-content: space-between; background: var(--brand); color: var(--brand-ink); border-radius: 20px; padding: 1.75rem; }
.cta h2 { margin: .2rem 0 .5rem; }
.cta p { margin: 0; max-width: 34rem; }
.cta .eyebrow--accent { color: var(--accent); }
.cta__actions { display: grid; gap: .5rem; justify-items: start; }
.cta__actions .muted { color: var(--brand-ink-muted); }
.cta__actions a:not(.btn) { color: var(--brand-ink); }

/* Page de demande d'inscription */
.breadcrumb { font-size: .92rem; margin: .5rem 0 1rem; color: var(--muted); }
.registration { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 1.5rem; align-items: start; }
.registration .card--form { margin: 0; max-width: none; }
.registration h1 { margin: .2rem 0 .5rem; font-size: clamp(1.6rem, 4vw, 2.1rem); }
.registration__aside { position: sticky; top: 6rem; background: var(--accent-bg); border-radius: 14px; padding: 1.25rem; }
.registration__aside h2 { margin-top: 0; font-size: 1.15rem; }
.next-steps { margin: 0 0 1rem; padding-left: 1.2rem; display: grid; gap: .5rem; }
.error-summary { border: 2px solid var(--crit); border-radius: 10px; padding: 1rem 1.25rem; margin: 1rem 0; background: var(--crit-bg); }
.error-summary:focus { outline: 3px solid var(--crit); outline-offset: 2px; }
.error-summary h2 { margin: 0 0 .5rem; font-size: 1.1rem; color: var(--crit); }
.error-summary ul { margin: 0; padding-left: 1.2rem; color: var(--ink); }
.error-summary a { color: var(--crit); font-weight: 600; }
@media (max-width: 860px) {
    .registration { grid-template-columns: 1fr; }
    .registration__aside { position: static; }
}

/* Détail d'une campagne : avancement compact, compteurs-filtres, liste en premier */
.campaign-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(360px, 100%), 1fr)); gap: 0 1.25rem; }
.campaign-grid > .card { margin-bottom: 1.25rem; }
.campaign-progress .card__head { align-items: baseline; }
.campaign-progress h2, .campaign-progress .progress-summary { margin: 0; }
.counters--compact { list-style: none; padding: 0; margin: 1rem 0 0; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: .5rem; }
.counters--compact .counter { display: flex; align-items: baseline; gap: .5rem; padding: .45rem .7rem; color: inherit; text-decoration: none; border: 2px solid transparent; height: 100%; }
.counters--compact .counter__n { font-size: 1.25rem; }
.counters--compact .counter__label { font-size: .82rem; line-height: 1.2; }
.counters--compact .counter--good { color: var(--good); }
.counters--compact .counter--warn { color: var(--warn); }
.counters--compact .counter--crit { color: var(--crit); }
.counters--compact .counter--all { background: var(--brand-bg); color: var(--brand); }
.counters--compact .counter--zero { opacity: .55; }
.counters--compact .counter:hover { border-color: currentColor; }
.counters--compact .counter[aria-current="true"] { border-color: currentColor; opacity: 1; box-shadow: 0 2px 8px color-mix(in srgb, var(--ink) 12%, transparent); }
.people-tools { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.people-search { padding: .4rem .7rem; border: 1px solid var(--line-strong); border-radius: 8px; font: inherit; min-width: 14rem; }
.table--sticky thead th { position: sticky; top: 4.1rem; background: var(--surface); z-index: 2; }
#personnes tbody tr { scroll-margin-top: 8rem; }
#personnes tbody tr:target { background: var(--accent-bg); }
#personnes { scroll-margin-top: 5rem; }
.campaign-details summary { cursor: pointer; font-weight: 600; color: var(--brand); }
.campaign-details[open] summary { margin-bottom: 1rem; }
.campaign-details h2 { font-size: 1.1rem; }
/* L'en-tête du tableau ne reste visible que si son conteneur ne défile pas : le défilement horizontal est réservé aux petits écrans. */
@media (min-width: 900px) { #personnes .table-wrap { overflow: visible; } }
/* Compteurs en pastilles sur une ou deux lignes ; ceux à zéro en gris (contraste suffisant, pas d'opacité). */
.counters--compact { display: flex; flex-wrap: wrap; }
.counters--compact li { flex: 0 1 auto; }
.counters--compact .counter { padding: .3rem .7rem; border-radius: 999px; align-items: center; white-space: nowrap; }
.counters--compact .counter__n { font-size: 1.05rem; }
.counters--compact .counter__label { font-size: .85rem; }
.counters--compact .counter--zero { opacity: 1; background: var(--neutral-bg); color: var(--muted); }

/* Page d'une campagne : lien vers la fiche d'une personne, fenêtre (popup), mise à jour automatique. */
.person-link { font-weight: 600; text-decoration: none; }
.person-link:hover, .person-link:focus-visible { text-decoration: underline; }
.modal { width: min(720px, calc(100vw - 2rem)); max-height: calc(100vh - 2rem); padding: 0; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); color: var(--ink); box-shadow: 0 20px 50px color-mix(in srgb, var(--ink) 25%, transparent); }
.modal::backdrop { background: color-mix(in srgb, var(--ink) 45%, transparent); }
.modal__bar { position: sticky; top: 0; display: flex; justify-content: flex-end; padding: .6rem .75rem; background: var(--surface); border-bottom: 1px solid var(--line); }
.modal__body { padding: 1rem 1.25rem 1.25rem; }
.target-sheet__head { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem; margin-bottom: .75rem; }
.target-sheet__head h2 { margin: 0; }
.facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: .5rem 1.25rem; margin: 0; }
.facts dt { font-size: .8rem; color: var(--muted); font-weight: 600; }
.facts dd { margin: 0; }
.target-sheet__notes { margin: 0; white-space: normal; }
.target-sheet__contacts { margin: 0; padding-left: 1.25rem; }
.target-sheet__actions { margin: 1rem 0 0; }
.live-status { display: flex; align-items: center; gap: .5rem; margin: 0 0 .5rem; font-size: .85rem; }
.live-status__dot { width: .55rem; height: .55rem; border-radius: 50%; background: var(--good); animation: live-pulse 2s ease-in-out infinite; }
@keyframes live-pulse { 50% { opacity: .3; } }
@media (prefers-reduced-motion: reduce) { .live-status__dot { animation: none; } }

/* Page d'aide : une couleur par section (variables --tone / --tone-bg), contrastes AA sur fond blanc. */
.help-tone--blue   { --tone: var(--brand); --tone-bg: var(--brand-bg); }
.help-tone--orange { --tone: var(--accent-ink); --tone-bg: var(--accent-bg); }
.help-tone--purple { --tone: var(--purple); --tone-bg: var(--purple-bg); }
.help-tone--teal   { --tone: var(--teal); --tone-bg: var(--teal-bg); }
.help-tone--green  { --tone: var(--good); --tone-bg: var(--good-bg); }
.help-tone--red    { --tone: var(--crit); --tone-bg: var(--crit-bg); }
.help-tone--amber  { --tone: var(--warn-strong); --tone-bg: var(--warn-bg); }

.help-hero {
    position: relative; overflow: hidden; display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 1.5rem; align-items: center;
    padding: 2rem; margin-bottom: 1.5rem; border-radius: 18px; color: var(--brand-ink);
    background: radial-gradient(circle at 92% 12%, color-mix(in srgb, var(--accent) 55%, transparent) 0 18%, transparent 19%),
                radial-gradient(circle at 78% 110%, color-mix(in srgb, var(--brand-ink) 12%, transparent) 0 30%, transparent 31%),
                linear-gradient(135deg, var(--brand) 0%, var(--brand-light) 60%, var(--brand-lighter) 100%);
    box-shadow: 0 18px 40px color-mix(in srgb, var(--brand) 25%, transparent);
}
.help-hero h1 { font-size: clamp(1.6rem, 4vw, 2.2rem); margin: 0 0 .4rem; line-height: 1.15; }
.help-hero__eyebrow { margin: 0 0 .3rem; font-size: .8rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--accent-soft); }
.help-hero__lead { margin: 0 0 1rem; font-size: 1.05rem; opacity: .95; max-width: 34rem; }
.help-hero__who { display: flex; align-items: center; gap: .6rem; margin: 0; font-size: .95rem; }
.help-hero__avatar { display: grid; place-items: center; width: 2.2rem; height: 2.2rem; border-radius: 50%; background: var(--accent); color: var(--ink); font-weight: 700; flex: none; }
.help-hero__chip { display: inline-block; padding: .05rem .6rem; border-radius: 999px; background: color-mix(in srgb, var(--brand-ink) 20%, transparent); font-weight: 600; font-size: .85rem; }
.help-hero__shortcuts { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.help-hero__shortcuts a {
    display: flex; align-items: center; gap: .6rem; padding: .65rem .9rem; border-radius: 12px; text-decoration: none; font-weight: 600;
    color: var(--ink); background: var(--surface); box-shadow: 0 4px 12px color-mix(in srgb, var(--shadow-color) 12%, transparent); transition: transform .15s, box-shadow .15s;
}
.help-hero__shortcuts a:hover { transform: translateX(3px); box-shadow: 0 6px 16px color-mix(in srgb, var(--shadow-color) 18%, transparent); }
.help-hero__shortcuts a:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.help-hero__shortcuts .help-icon { color: var(--accent-ink); }

.help-layout { display: grid; grid-template-columns: 15.5rem minmax(0, 1fr); gap: 1.5rem; align-items: start; }
.help-toc { position: sticky; top: 5rem; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 1rem; max-height: calc(100vh - 6rem); overflow-y: auto; }
.help-toc h2 { margin: 0 0 .6rem; font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.help-toc ol { list-style: none; margin: 0; padding: 0; }
.help-toc li { margin: 0; }
.help-toc a { display: flex; align-items: center; gap: .6rem; padding: .35rem .4rem; border-radius: 8px; color: var(--ink); text-decoration: none; font-size: .93rem; }
.help-toc a:hover { background: var(--tone-bg); color: var(--tone); }
.help-toc__n { display: grid; place-items: center; flex: none; width: 1.55rem; height: 1.55rem; border-radius: 50%; background: var(--tone-bg); color: var(--tone); font-size: .78rem; font-weight: 700; }

.help { min-width: 0; }
.help-sec {
    background: var(--surface); border: 1px solid var(--line); border-top: 5px solid var(--tone); border-radius: 14px;
    padding: 1.4rem 1.5rem; margin-bottom: 1.25rem; scroll-margin-top: 5rem;
}
.help-sec h2 { display: flex; align-items: center; gap: .7rem; font-size: 1.3rem; margin: 0 0 1rem; color: var(--tone); }
.help-sec h3 { margin: 1.4rem 0 .5rem; font-size: 1.05rem; color: var(--tone); }
.help-sec__icon { display: grid; place-items: center; flex: none; width: 2.6rem; height: 2.6rem; border-radius: 12px; background: var(--tone-bg); color: var(--tone); }
.help-icon { flex: none; }
.help code { overflow-wrap: anywhere; }

.help-path { display: flex; flex-wrap: wrap; align-items: center; gap: .35rem; margin: 0 0 .8rem; font-size: .88rem; color: var(--muted); }
.help-path span { padding: .1rem .55rem; border-radius: 6px; background: var(--tone-bg); color: var(--tone); font-weight: 600; }
.help-path span + span { position: relative; margin-left: .9rem; }
.help-path span + span::before { content: "›"; position: absolute; left: -.85rem; color: var(--muted); font-weight: 400; }

.help-role { display: inline-block; margin-left: .3rem; padding: .05rem .5rem; border-radius: 999px; font-size: .75rem; font-weight: 700; vertical-align: 1px; white-space: nowrap; }
.help-role--manager { background: var(--warn-bg); color: var(--warn-strong); }
.help-role--admin { background: var(--crit-bg); color: var(--crit); }

/* Touches 1, 2, 3 */
.help-keys { list-style: none; margin: 1rem 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(17rem, 100%), 1fr)); gap: .75rem; }
.help-key { display: flex; gap: .8rem; align-items: flex-start; margin: 0; padding: .9rem; border-radius: 12px; background: var(--k-bg); border: 1px solid color-mix(in srgb, var(--k) 25%, transparent); }
.help-key strong { display: block; color: var(--k); }
.help-key span:not(.help-key__digit):not(.sr-only) { font-size: .9rem; }
.help-key__digit { display: grid; place-items: center; flex: none; width: 2.6rem; height: 2.6rem; border-radius: 12px; background: var(--k); color: var(--on-color); font-size: 1.35rem; font-weight: 800; box-shadow: 0 4px 0 color-mix(in srgb, var(--k) 70%, var(--shadow-color)); }
.help-key--good { --k: var(--good); --k-bg: var(--good-bg); }
.help-key--crit { --k: var(--crit); --k-bg: var(--crit-bg); }
.help-key--warn { --k: var(--warn-strong); --k-bg: var(--warn-bg); }
.help-key--neutral { --k: var(--muted); --k-bg: var(--neutral-bg); }

/* Fonctionnalités */
.help-features { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(14rem, 100%), 1fr)); gap: .75rem; }
.help-feature { display: flex; flex-direction: column; gap: .2rem; margin: 0; padding: 1rem; border-radius: 12px; border: 1px solid var(--line); background: linear-gradient(180deg, var(--tone-bg) 0, var(--surface) 70%); transition: transform .15s, box-shadow .15s; }
.help-feature:hover { transform: translateY(-2px); box-shadow: 0 8px 18px color-mix(in srgb, var(--ink) 8%, transparent); }
.help-feature strong { color: var(--tone); }
.help-feature > span:last-child { font-size: .9rem; color: var(--ink); }
.help-feature__icon { display: grid; place-items: center; width: 2.4rem; height: 2.4rem; margin-bottom: .35rem; border-radius: 10px; background: var(--tone); color: var(--on-color); }

/* Rôles */
.help-roles { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(14rem, 100%), 1fr)); gap: .75rem; margin-bottom: .75rem; }
.help-roles__card { padding: 1rem 1.1rem; border-radius: 12px; background: var(--tone-bg); border: 2px solid transparent; }
.help-roles__card.is-you { border-color: var(--tone); }
.help-roles__card h3 { margin: 0 0 .4rem; display: flex; align-items: center; gap: .5rem; }
.help-roles__card ul { margin: 0; padding-left: 1.1rem; font-size: .92rem; }
.help-roles__card li { margin: .25rem 0; }
.help-roles__plus { margin: 0 0 .3rem; font-size: .85rem; color: var(--muted); }
.help-you { padding: 0 .5rem; border-radius: 999px; background: var(--tone); color: var(--on-color); font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }

/* Étapes numérotées */
.help-steps { list-style: none; counter-reset: step; margin: 0; padding: 0; }
.help-steps > li { counter-increment: step; position: relative; margin: 0; padding: .55rem 0 .55rem 2.9rem; min-height: 2.6rem; }
.help-steps > li::before {
    content: counter(step); position: absolute; left: 0; top: .45rem; display: grid; place-items: center;
    width: 2rem; height: 2rem; border-radius: 50%; background: var(--tone); color: var(--on-color); font-weight: 700; font-size: .9rem;
}
.help-steps > li:not(:last-child)::after { content: ""; position: absolute; left: calc(1rem - 1px); top: 2.6rem; bottom: -.35rem; width: 2px; background: var(--tone-bg); }

/* Encadrés */
.help-callout { display: flex; gap: .8rem; align-items: flex-start; margin: 1rem 0 0; padding: .9rem 1rem; border-radius: 12px; border-left: 5px solid var(--c); background: var(--c-bg); }
.help-callout p { margin: 0; }
.help-callout__icon { color: var(--c); padding-top: .1rem; }
.help-callout--info { --c: var(--brand); --c-bg: var(--brand-bg); }
.help-callout--warn { --c: var(--crit); --c-bg: var(--crit-bg); }
.help-callout--sun { --c: var(--accent-ink); --c-bg: var(--accent-bg); }

/* Cycle d'une campagne */
.help-flow { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; margin: .5rem 0 0; padding: .8rem; border-radius: 12px; background: var(--neutral-bg); }
.help-flow__step { padding: .3rem .8rem; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); font-weight: 600; font-size: .9rem; }
.help-flow__step:first-child { background: var(--neutral-bg); }
.help-flow__step:nth-child(3) { background: var(--good-bg); color: var(--good); border-color: transparent; }
.help-flow__step:nth-child(5) { background: var(--warn-bg); color: var(--warn); border-color: transparent; }
.help-flow__step:last-child { background: var(--brand); color: var(--brand-ink); border-color: transparent; }
.help-flow__arrow { color: var(--muted); font-weight: 700; }

.help-chips { list-style: none; display: flex; flex-wrap: wrap; gap: .4rem; margin: .8rem 0 0; padding: 0; }
.help-chip { margin: 0; padding: .2rem .7rem; border-radius: 999px; font-size: .85rem; font-weight: 600; }
.help-chip--good { background: var(--good-bg); color: var(--good); }
.help-chip--warn { background: var(--warn-bg); color: var(--warn); }
.help-chip--neutral { background: var(--neutral-bg); color: var(--muted); }
.help-chip--crit { background: var(--crit-bg); color: var(--crit); }

.help-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(13rem, 100%), 1fr)); gap: .75rem; }
.help-mini { padding: .9rem 1rem; border-radius: 12px; background: var(--tone-bg); }
.help-mini h3 { margin: 0 0 .3rem; font-size: 1rem; }
.help-mini p { margin: 0; font-size: .92rem; }
.help-list { margin: 0; padding-left: 1.2rem; }
.help-list li { margin: .5rem 0; }

/* Questions fréquentes */
.help-faq { display: grid; gap: .5rem; }
.help-faq details { border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.help-faq details[open] { border-color: var(--tone); background: var(--tone-bg); }
.help-faq summary { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .8rem 1rem; cursor: pointer; font-weight: 600; list-style: none; }
.help-faq summary::-webkit-details-marker { display: none; }
.help-faq summary::after { content: "+"; flex: none; display: grid; place-items: center; width: 1.6rem; height: 1.6rem; border-radius: 50%; background: var(--tone-bg); color: var(--tone); font-size: 1.1rem; font-weight: 700; }
.help-faq details[open] summary::after { content: "−"; background: var(--tone); color: var(--on-color); }
.help-faq summary:focus-visible { outline: 3px solid var(--tone); outline-offset: 2px; border-radius: 12px; }
.help-faq details p { margin: 0; padding: 0 1rem 1rem; }

.help-top { text-align: center; font-size: .9rem; }

@media (max-width: 899px) {
    .help-hero { grid-template-columns: 1fr; padding: 1.5rem 1.25rem; }
    .help-layout { grid-template-columns: 1fr; }
    .help-toc { position: static; max-height: none; }
    .help-toc ol { columns: 2 12rem; column-gap: 1rem; }
    .help-toc li { break-inside: avoid; }
    .help-sec { padding: 1.2rem 1rem; }
}
@media (prefers-reduced-motion: reduce) {
    .help-feature, .help-hero__shortcuts a { transition: none; }
    .help-feature:hover, .help-hero__shortcuts a:hover { transform: none; }
}

/* Bouton « Export Excel » */
.btn--excel { display: inline-flex; align-items: center; gap: .45rem; }
.btn--excel:hover { border-color: var(--excel); }
.btn__icon { flex: none; }
.filters--compact select { flex: 0 1 16rem; }

/* Ancres des listes paginées sous la barre du haut fixe. */
#a-traiter, #cloturees { scroll-margin-top: 5rem; }

/* Pages d'information (accessibilité, données personnelles) : mêmes briques que la page d'aide. */
.legal-hero { margin-top: .5rem; }
.legal p { max-width: 46rem; }
.legal-badge {
    justify-self: end; display: grid; justify-items: center; gap: .15rem; width: min(100%, 17rem); padding: 1.25rem 1rem;
    border-radius: 16px; background: var(--surface); color: var(--ink); text-align: center; box-shadow: 0 10px 28px color-mix(in srgb, var(--shadow-color) 18%, transparent);
    border-top: 5px solid var(--tone);
}
.legal-badge__icon { display: grid; place-items: center; width: 3.4rem; height: 3.4rem; margin-bottom: .35rem; border-radius: 50%; background: var(--tone-bg); color: var(--tone); }
.legal-badge__label { font-size: .9rem; color: var(--muted); }
.legal-badge__value { font-size: 1.3rem; line-height: 1.2; color: var(--tone); }
.legal-badge__note { margin-top: .35rem; padding: .15rem .65rem; border-radius: 999px; background: var(--neutral-bg); font-size: .8rem; color: var(--muted); }

.legal-promises { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.legal-promises li { display: flex; align-items: center; gap: .65rem; margin: 0; padding: .65rem .9rem; border-radius: 12px; background: var(--surface); color: var(--ink); font-weight: 600; box-shadow: 0 4px 12px color-mix(in srgb, var(--shadow-color) 12%, transparent); }
.legal-promises .help-icon { color: var(--accent-ink); }

.legal-tag { display: inline-block; margin-left: .25rem; padding: 0 .5rem; border-radius: 999px; background: var(--surface); color: var(--tone); font-size: .72rem; font-weight: 700; vertical-align: 2px; white-space: nowrap; }
ul.legal-purposes { list-style: none; margin: 0; padding: 0; }
.legal-purposes .help-mini { margin: 0; border-top: 4px solid var(--tone); }
.legal-purposes h3 { color: var(--tone); }
.legal-purposes .legal-tag { display: table; margin: .3rem 0 0; }

.legal-table { margin: 0; }
.legal-table tbody th { width: 38%; color: var(--ink); font-size: .95rem; border-bottom: 1px solid var(--line); padding: .7rem .5rem; vertical-align: top; }
.legal-table tbody td { vertical-align: top; }
.legal-table tbody tr:nth-child(odd) { background: color-mix(in srgb, var(--tone-bg) 55%, transparent); }
.legal-table thead th { color: var(--tone); }
.legal-note { margin: 1rem 0 0; font-size: .93rem; color: var(--muted); }
.legal-features--wide .help-feature:first-child { grid-column: 1 / -1; }

.legal-who { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.legal-who li { display: flex; gap: .8rem; align-items: flex-start; margin: 0; padding: .75rem .9rem; border-radius: 12px; border: 1px solid var(--line); }
.legal-who strong { color: var(--tone); }
.legal-who__icon, .legal-options__icon, .legal-contact__icon {
    display: grid; place-items: center; flex: none; width: 2.3rem; height: 2.3rem; border-radius: 10px; background: var(--tone-bg); color: var(--tone);
}

.legal-rights { list-style: none; margin: 0 0 1rem; padding: 0; display: flex; flex-wrap: wrap; gap: .5rem; }
.legal-rights li { display: inline-flex; align-items: center; gap: .45rem; margin: 0; padding: .4rem .85rem; border-radius: 999px; background: var(--tone-bg); color: var(--tone); font-weight: 600; font-size: .93rem; }

.legal-contact { list-style: none; margin: 0 0 .5rem; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(15rem, 100%), 1fr)); gap: .6rem; }
.legal-contact__item, .legal-contact--empty { display: flex; gap: .75rem; align-items: center; margin: 0; padding: .85rem 1rem; border-radius: 12px; background: var(--tone-bg); }
.legal-contact__item > span:last-child { min-width: 0; overflow-wrap: anywhere; }
.legal-contact__label { display: block; font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--tone); }
.legal-contact__icon { background: var(--tone); color: var(--on-color); }
.legal-contact a { font-weight: 600; }

.legal-options { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(14rem, 100%), 1fr)); gap: .75rem; }
.legal-options__item { display: flex; flex-direction: column; gap: .6rem; margin: 0; padding: 1rem; border-radius: 12px; border: 1px solid var(--line); background: linear-gradient(180deg, var(--tone-bg) 0, var(--surface) 70%); }
.legal-address { display: block; margin-top: .4rem; font-weight: 600; }

@media (max-width: 899px) {
    .legal-badge { justify-self: stretch; width: auto; }
}
@media print {
    .help-toc { display: none; }
    .help-layout { display: block; }
    .help-hero { color: var(--ink); background: none; box-shadow: none; border: 1px solid var(--line); }
}

/* Tableau de bord : bandeau d'accueil et chiffres du jour (même style que les pages d'information). */
.dash-hero__facts li { padding: 0; }
.dash-hero__facts a, .dash-hero__static { display: flex; align-items: center; gap: .65rem; width: 100%; padding: .65rem .9rem; border-radius: 12px; color: var(--ink); text-decoration: none; }
.dash-hero__facts a { transition: transform .15s, box-shadow .15s; }
.dash-hero__facts a:hover { transform: translateX(3px); box-shadow: 0 6px 16px color-mix(in srgb, var(--shadow-color) 18%, transparent); }
.dash-hero__facts a:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.dash-hero__facts strong { color: var(--brand); }
.dash-hero__static { font-weight: 600; color: var(--muted); }
.dash-hero__late { margin-left: auto; padding: .05rem .55rem; border-radius: 999px; background: var(--crit-bg); color: var(--crit); font-size: .8rem; font-weight: 700; white-space: nowrap; }
@media (prefers-reduced-motion: reduce) {
    .dash-hero__facts a { transition: none; }
    .dash-hero__facts a:hover { transform: none; }
}

/* Mode maintenance : bandeau des administrateurs et page vue par les visiteurs */
.banner--maintenance { background: var(--crit-bg); color: var(--crit); border-bottom: 1px solid var(--crit-line); font-weight: 600; }
.banner--maintenance a { color: inherit; margin-left: .5rem; }
.maintenance { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 1.5rem 1rem; }
.maintenance__box { max-width: 560px; width: 100%; background: var(--surface); border: 1px solid var(--line); border-top: 5px solid var(--accent); border-radius: var(--radius); padding: 2rem 1.5rem; text-align: center; }
.maintenance__logo { display: block; margin: 0 auto 1rem; height: auto; max-width: 120px; }
.maintenance__org { color: var(--muted); margin: 0 0 .25rem; font-size: .95rem; }
.maintenance__message { font-size: 1.05rem; margin: 1rem 0; }
.maintenance__contact, .maintenance__session { color: var(--muted); margin: .5rem 0 0; }

/* Pages d'erreur (400, 500) : même boîte que la maintenance, avec le code en grand. */
.error-page--server .error-page__box { border-top-color: var(--crit); }
.error-page__code { font-size: clamp(3.5rem, 14vw, 5.5rem); font-weight: 800; line-height: 1; letter-spacing: -.02em; margin: .75rem 0 .25rem; color: var(--accent-ink); }
.error-page--server .error-page__code { color: var(--crit); }
.error-page__box h1 { margin-top: 0; }
.error-page__box .maintenance__message p { margin: .5rem 0; }
.error-page__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: .75rem; margin: 1.5rem 0 1rem; }
.error-page__ref { color: var(--muted); font-size: .85rem; margin: 1.25rem 0 0; padding-top: .75rem; border-top: 1px solid var(--line); }

/* Contact du support (lien du pied de page, fenêtre modale et page /support). */
.modal--support { width: min(560px, calc(100vw - 2rem)); }
.support__title { margin-top: 0; }
.support-page { max-width: 640px; margin: 2rem auto; }
.support-form textarea { resize: vertical; min-height: 8rem; }
.support-form__trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

/* Vidéo intégrée (page d'accueil, agents connectés) : format 16:9 sur toute la largeur. */
.video-embed { position: relative; aspect-ratio: 16 / 9; width: 100%; border-radius: 14px; overflow: hidden; background: #000; margin-top: 1rem; }
.video-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
