/* TERRA NOVA — styles des éléments ajoutés par le branchement back (codes à 6 chiffres, notifications) */
.code-input { font-family: ui-monospace, Consolas, Menlo, monospace; font-size: 1.6rem; letter-spacing: .5em; text-align: center; max-width: 16rem }
.np-device { margin: 1rem 0 1.2rem; padding: 1rem 1.1rem; border: 1px solid var(--line, rgba(255,255,255,.12)); }
.np-table th[scope=row] { font-weight: 500; text-align: start }
.np-table td { text-align: center; width: 8rem }
.np-table .check { justify-content: center }
#np-state[data-s=on] { background: rgba(77,255,176,.15); color: #4dffb0 }
#np-state[data-s=off], #np-state[data-s=denied] { background: rgba(255,45,122,.15); color: #ff8db5 }
/* Pagination du journal des actions */
.pager { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin-top: 1.2rem }
.pager .pg-n { display: flex; gap: .3rem; align-items: center }
.pager .pg { min-width: 2.4rem; height: 2.4rem; padding: 0 .5rem; border: 1px solid var(--line, rgba(255,255,255,.18)); background: transparent; color: inherit; font: inherit; cursor: pointer }
.pager .pg:hover, .pager .pg:focus-visible { border-color: var(--neon, #ff2d7a) }
.pager .pg.on { background: var(--neon, #ff2d7a); border-color: var(--neon, #ff2d7a); color: #fff; font-weight: 700 }
.pager .pg-gap { padding: 0 .2rem; opacity: .6 }
.pager .pg-of { margin-inline-start: auto; opacity: .75; font-size: .9rem }

/* Notifications (cloche et « Mon espace ») : lire, sélectionner, supprimer (seulement les notifications lues) */
:is(.pop, .nf-center) .nf-bar { display: flex; flex-wrap: wrap; align-items: center; gap: .45rem .6rem; margin: -.2rem 0 .7rem; padding-bottom: .7rem; border-bottom: 1px solid var(--line) }
:is(.pop, .nf-center) .nf-all { display: inline-flex; align-items: center; gap: .4rem; margin-inline-end: auto; font-size: .82rem; cursor: pointer }
:is(.pop, .nf-center) .nf-all:has(input:disabled) { opacity: .5; cursor: not-allowed }
:is(.pop, .nf-center) .nf-btn { padding: .38rem .7rem; border: 0; cursor: pointer; background: rgba(255, 255, 255, .05); box-shadow: inset 0 0 0 1px var(--line); color: inherit; font: 700 .74rem var(--tech); letter-spacing: .05em; clip-path: var(--cut-s) }
:is(.pop, .nf-center) .nf-btn:hover:not(:disabled) { box-shadow: inset 0 0 0 1px var(--cyan); color: var(--cyan) }
:is(.pop, .nf-center) .nf-btn--del:not(:disabled) { background: rgba(255, 45, 122, .16); box-shadow: inset 0 0 0 1px var(--neon) }
:is(.pop, .nf-center) .nf-btn--del:not(:disabled):hover { color: #fff; background: rgba(255, 45, 122, .32); box-shadow: inset 0 0 0 1px var(--neon) }
:is(.pop, .nf-center) .nf-btn:disabled { opacity: .45; cursor: not-allowed }
:is(.pop, .nf-center) .nf-item { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: .55rem; transition: background .2s }
:is(.pop, .nf-center) .nf-item--sel { background: rgba(63, 214, 255, .07) }
:is(.pop, .nf-center) .nf-item a { min-width: 0; overflow-wrap: anywhere }
:is(.pop, .nf-center) .nf-item--new a { font-weight: 700 }
:is(.pop, .nf-center) .nf-ck { width: 1.05rem; height: 1.05rem; accent-color: var(--neon); cursor: pointer }
:is(.pop, .nf-center) .nf-ck:disabled { opacity: .3; cursor: not-allowed }
:is(.pop, .nf-center) .nf-dot { display: inline-block; width: .5rem; height: .5rem; margin-inline-end: .45rem; border-radius: 50%; background: var(--neon); box-shadow: 0 0 8px var(--neon); vertical-align: middle }
:is(.pop, .nf-center) .nf-x { display: grid; place-items: center; width: 2rem; height: 2rem; border: 0; border-radius: 50%; cursor: pointer; background: transparent; color: var(--mute); font-size: 1.15rem; line-height: 1 }
:is(.pop, .nf-center) .nf-x:hover, :is(.pop, .nf-center) .nf-x:focus-visible { background: rgba(255, 45, 122, .16); color: var(--neon) }
:is(.pop, .nf-center) .nf-x--ok { font-size: .95rem }
:is(.pop, .nf-center) .nf-x--ok:hover, :is(.pop, .nf-center) .nf-x--ok:focus-visible { background: rgba(63, 214, 255, .14); color: var(--cyan) }
:is(.pop, .nf-center) .nf-hint { margin: .5rem 0 .2rem; color: var(--mute); font-size: .76rem }
@media (prefers-reduced-motion: reduce) { :is(.pop, .nf-center) .nf-item { transition: none } }
html[data-theme=light] :is(.pop, .nf-center) .nf-btn { background: var(--ink-soft) }
html[data-theme=light] :is(.pop, .nf-center) .nf-btn--del:not(:disabled):hover { color: var(--ink, #111) }
.nf-center { margin: .4rem 0 1.4rem; padding: .9rem 1rem; background: rgba(255, 255, 255, .03); box-shadow: inset 0 0 0 1px var(--line); clip-path: var(--cut-s) }
.nf-center .nf-bar { margin-top: 0 }
.nf-center .nf-list { list-style: none; margin: 0; padding: 0; max-height: 26rem; overflow: auto }
.nf-center .nf-list li + li { border-top: 1px solid var(--line) }
.nf-center .nf-item a { display: block; padding: .7rem .2rem; text-decoration: none }
.nf-center .nf-item a:hover { color: var(--cyan) }
.nf-center .nf-item small { display: block; color: var(--mute); font-size: .8rem; font-weight: 400 }
.nf-center:focus { outline: none }
html[data-theme=light] .nf-center { background: var(--ink-soft) }

/* « Par où commencer ? » — bouton flottant des visiteurs non connectés (sous le logo), vers /bienvenue */
@property --tn-a { syntax: "<angle>"; inherits: false; initial-value: 0deg }
.tn-start { position: fixed; z-index: 55; top: calc(var(--hh, 76px) + .8rem); inset-inline-start: max(1rem, env(safe-area-inset-left)); display: inline-flex; align-items: center; gap: .65rem; padding: .62rem 1rem .62rem .7rem; border-radius: 999px; color: #fff; text-decoration: none; isolation: isolate; background: rgba(8, 10, 22, .82); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); box-shadow: 0 10px 34px -8px rgba(255, 45, 122, .55), 0 0 26px -6px rgba(63, 214, 255, .45); opacity: 0; transform: translateX(-120%) scale(.9); transition: opacity .6s var(--e, ease), transform .7s cubic-bezier(.2, 1.4, .4, 1), box-shadow .3s }
.tn-start.is-in { opacity: 1; transform: none }
/* Bordure néon tournante */
.tn-start::before { content: ""; position: absolute; inset: -2px; z-index: -1; border-radius: inherit; padding: 2px; background: conic-gradient(from var(--tn-a), #ff2d7a, #3fd6ff, #b46bff, #ff2d7a); -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; animation: tn-spin 3.2s linear infinite }
/* Reflet qui balaie le bouton */
.tn-start::after { content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, .22) 48%, transparent 64%) -150% 0 / 220% 100% no-repeat; animation: tn-shine 3.6s ease-in-out 1.2s infinite }
.tn-start-ico { display: grid; place-items: center; width: 2.1rem; height: 2.1rem; border-radius: 50%; color: #05060c; background: radial-gradient(circle at 30% 30%, #fff, #3fd6ff 55%, #1d8fd8); box-shadow: 0 0 0 0 rgba(63, 214, 255, .6); animation: tn-pulse 2.4s ease-out infinite }
.tn-start-ico svg { animation: tn-needle 4s ease-in-out infinite }
.tn-start-txt { display: grid; line-height: 1.15 }
.tn-start-txt b { font: 700 .92rem var(--tech, inherit); letter-spacing: .03em; background: linear-gradient(90deg, #fff, #ffd1e3, #bdf3ff, #fff) 0 0 / 200% 100%; -webkit-background-clip: text; background-clip: text; color: transparent; animation: tn-text 5s linear infinite }
.tn-start-txt small { font-size: .72rem; color: #b8bbd2; letter-spacing: .04em }
.tn-start-go { font-weight: 700; color: #ff7aa8; transition: transform .25s }
.tn-start:hover, .tn-start:focus-visible { transform: translateY(-2px) scale(1.04); box-shadow: 0 16px 44px -8px rgba(255, 45, 122, .75), 0 0 34px -4px rgba(63, 214, 255, .65) }
.tn-start:hover .tn-start-go, .tn-start:focus-visible .tn-start-go { transform: translateX(4px) }
.tn-start:focus-visible { outline: 2px solid #3fd6ff; outline-offset: 4px }
@keyframes tn-spin { to { --tn-a: 360deg } }
@keyframes tn-shine { 0%, 55% { background-position: -150% 0 } 100% { background-position: 250% 0 } }
@keyframes tn-pulse { 0% { box-shadow: 0 0 0 0 rgba(63, 214, 255, .6) } 70%, 100% { box-shadow: 0 0 0 12px rgba(63, 214, 255, 0) } }
@keyframes tn-needle { 0%, 100% { transform: rotate(0) } 20% { transform: rotate(-25deg) } 40% { transform: rotate(18deg) } 55% { transform: rotate(0) } }
@keyframes tn-text { to { background-position: -200% 0 } }
html[dir=rtl] .tn-start { transform: translateX(120%) scale(.9) } html[dir=rtl] .tn-start.is-in { transform: none } html[dir=rtl] .tn-start-go { transform: scaleX(-1) }
html[data-theme=light] .tn-start { background: rgba(255, 255, 255, .9); color: var(--ink, #1d1b2c) }
html[data-theme=light] .tn-start-txt b { background-image: linear-gradient(90deg, #c00f55, #1d6fd8, #7a3bd8, #c00f55) }
html[data-theme=light] .tn-start-txt small { color: var(--mute, #535569) }
@media (max-width: 640px) { .tn-start { padding: .5rem .8rem .5rem .55rem; gap: .5rem } .tn-start-txt small, .tn-start-go { display: none } .tn-start-ico { width: 1.8rem; height: 1.8rem } }
@media print { .tn-start { display: none } }
@media (prefers-reduced-motion: reduce) { .tn-start, .tn-start::before, .tn-start::after, .tn-start-ico, .tn-start-ico svg, .tn-start-txt b { animation: none !important; transition: none !important } .tn-start { opacity: 1; transform: none } }
html.lite .tn-start::before, html.lite .tn-start::after, html.lite .tn-start-ico, html.lite .tn-start-ico svg, html.lite .tn-start-txt b { animation: none }
.tn-start .tn-start-txt, .tn-start .tn-start-go { transition: max-width .35s ease, opacity .25s ease; max-width: 16rem; overflow: hidden; white-space: nowrap }
.tn-start.is-mini { gap: 0; padding: .45rem }
.tn-start.is-mini .tn-start-txt, .tn-start.is-mini .tn-start-go { max-width: 0; opacity: 0 }
.tn-start.is-mini:hover, .tn-start.is-mini:focus-visible { gap: .65rem; padding: .62rem 1rem .62rem .7rem }
.tn-start.is-mini:hover .tn-start-txt, .tn-start.is-mini:focus-visible .tn-start-txt, .tn-start.is-mini:hover .tn-start-go, .tn-start.is-mini:focus-visible .tn-start-go { max-width: 16rem; opacity: 1 }

/* Visiteur non connecté (classe posée dans <head> par _backend.html.twig) : pas de recherche ni de notifications */
html.tn-guest .tools [data-tool=search], html.tn-guest .tools [data-tool=notif] { display: none !important }
/* Pages de connexion (connexion, inscription, codes, mot de passe oublié) : en-tête réduit au logo, à la langue, à l'affichage
   (police, contraste…) et au thème clair/sombre ; pas de menu, de bouton de compte ni d'assistant IA */
html.tn-bare #nav, html.tn-bare .tools .burger, html.tn-bare .tools #account, html.tn-bare .ai-fab, html.tn-bare .ai-panel, html.tn-bare .ex-btn, html.tn-bare .ex-pop { display: none !important }
html.tn-bare .top .bar { justify-content: space-between }

/* Flèche de défilement (haut / bas) avec anneau de progression */
.tn-scroll { position: fixed; z-index: 84; inset: auto max(1.45rem, env(safe-area-inset-right)) 1.3rem auto; width: 3.1rem; height: 3.1rem; padding: 0; border: 0; border-radius: 50%; cursor: pointer; display: grid; place-items: center; color: #fff; background: radial-gradient(circle at 35% 30%, rgba(63, 214, 255, .35), rgba(8, 10, 22, .9) 70%); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); box-shadow: 0 10px 28px -8px rgba(63, 214, 255, .55), inset 0 0 0 1px rgba(255, 255, 255, .14); opacity: 0; visibility: hidden; transform: translateY(14px) scale(.85); transition: opacity .3s, transform .35s cubic-bezier(.2, 1.4, .4, 1), visibility .3s, bottom .3s, box-shadow .25s }
.tn-scroll.is-on { opacity: 1; visibility: visible; transform: none }
.tn-scroll--fab { bottom: 6.1rem }
.tn-scroll--hide { opacity: 0 !important; visibility: hidden !important }
.tn-scroll-ring { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg) }
.tn-scroll-ring circle { fill: none; stroke: #ff2d7a; stroke-width: 2.6; stroke-linecap: round; stroke-dasharray: 100; stroke-dashoffset: 100; transition: stroke-dashoffset .2s linear; filter: drop-shadow(0 0 4px rgba(255, 45, 122, .8)) }
.tn-scroll-arrow { position: relative; transition: transform .45s cubic-bezier(.3, 1.4, .5, 1); animation: tn-bob 1.8s ease-in-out infinite }
.tn-scroll.is-up .tn-scroll-arrow { transform: rotate(180deg) }
.tn-scroll:hover, .tn-scroll:focus-visible { transform: translateY(-3px) scale(1.06); box-shadow: 0 16px 36px -8px rgba(255, 45, 122, .7), 0 0 22px -4px rgba(63, 214, 255, .7), inset 0 0 0 1px rgba(255, 255, 255, .25) }
.tn-scroll:focus-visible { outline: 2px solid #3fd6ff; outline-offset: 3px }
.tn-scroll.is-pop { animation: tn-pop .45s ease }
@keyframes tn-bob { 0%, 100% { translate: 0 -1px } 50% { translate: 0 2px } }
@keyframes tn-pop { 40% { transform: scale(.86) } 100% { transform: none } }
html[dir=rtl] .tn-scroll { inset: auto auto 1.3rem max(1.45rem, env(safe-area-inset-left)) }
html[dir=rtl] .tn-scroll--fab { bottom: 6.1rem }
html[data-theme=light] .tn-scroll { color: var(--ink, #1d1b2c); background: radial-gradient(circle at 35% 30%, rgba(63, 214, 255, .3), rgba(255, 255, 255, .95) 70%); box-shadow: 0 10px 26px -8px rgba(29, 27, 44, .35), inset 0 0 0 1px rgba(29, 27, 44, .12) }
@media print { .tn-scroll { display: none } }
@media (prefers-reduced-motion: reduce) { .tn-scroll, .tn-scroll-arrow, .tn-scroll-ring circle { transition: none; animation: none } }
html.lite .tn-scroll-arrow { animation: none }

/* Annonces : pagination (5 par page) */
#alist .ann-item.pg-off { display: none !important }
.ann-pager { margin-top: 1.2rem }

/* =========================================================
   Barre d'alerte « salle de contrôle » (contenu : terra.js ; décor : backend.js)
   Visiteur : titre seulement (consignes réservées) et bouton « Se connecter » ajouté par gate.js.
   ========================================================= */
#alertbar.alertbar { --ab: #3fd6ff; --ab-ink: #05060c; position: relative; display: flex; align-items: center; gap: .8rem; padding: .5rem var(--pad); overflow: hidden; isolation: isolate; font-size: .9rem; color: #eef1ff;
   background: rgba(6, 9, 20, .95); border-bottom: 1px solid rgba(255, 255, 255, .14); /* navigateurs sans color-mix() */
   background: linear-gradient(90deg, color-mix(in srgb, var(--ab) 26%, #060914) 0, rgba(6, 9, 20, .95) 34%, rgba(6, 9, 20, .95) 100%);
   border-bottom: 1px solid color-mix(in srgb, var(--ab) 40%, transparent);
   box-shadow: inset 3px 0 0 var(--ab), 0 10px 26px -16px var(--ab); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px) }
#alertbar.alertbar[data-level=crit] { --ab: #ff3b5c; --ab-ink: #fff }
#alertbar.alertbar[data-level=warn] { --ab: #ffb020; --ab-ink: #1b1100 }
/* Bandes de danger discrètes (alerte critique) */
#alertbar.alertbar[data-level=crit]::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 34%; z-index: -1; opacity: .1; background: repeating-linear-gradient(135deg, var(--ab) 0 9px, transparent 9px 18px); -webkit-mask: linear-gradient(90deg, #000, transparent); mask: linear-gradient(90deg, #000, transparent) }
/* Balise de signal : radar */
#alertbar .ab-sig { position: relative; flex: none; display: grid; place-items: center; width: 2.05rem; height: 2.05rem; border-radius: 50%; color: var(--ab); background: color-mix(in srgb, var(--ab) 16%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ab) 55%, transparent), 0 0 18px -4px var(--ab) }
#alertbar .ab-sig i { position: absolute; inset: 0; border-radius: 50%; border: 1.5px solid var(--ab); opacity: 0; animation: ab-radar 2.4s cubic-bezier(.2, .6, .3, 1) infinite }
#alertbar .ab-sig i + i { animation-delay: 1.2s }
#alertbar .ab-sig svg { position: relative }
#alertbar[data-level=crit] .ab-sig svg { animation: ab-blink 1.2s steps(2, jump-none) infinite }
/* Niveau : pastille */
#alertbar.alertbar strong { flex: none; padding: .2rem .62rem; border-radius: 999px; font: 700 .7rem/1.2 var(--tech, inherit); letter-spacing: .16em; text-transform: uppercase; color: var(--ab); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ab) 60%, transparent); background: color-mix(in srgb, var(--ab) 10%, transparent) }
#alertbar.alertbar strong::before { content: none }
#alertbar .ab-live { flex: none; display: inline-flex; align-items: center; gap: .35rem; font: 700 .66rem var(--tech, inherit); letter-spacing: .14em; text-transform: uppercase; color: #ff7a93 }
#alertbar .ab-live::before { content: ""; width: .45rem; height: .45rem; border-radius: 50%; background: #ff3b5c; box-shadow: 0 0 0 0 rgba(255, 59, 92, .7); animation: ab-live 1.6s ease-out infinite }
#alertbar .ab-time { flex: none; font-size: .74rem; color: #9aa1bf; font-variant-numeric: tabular-nums; padding-inline-start: .7rem; border-inline-start: 1px solid rgba(255, 255, 255, .14) }
#alertbar .you { flex: none }
/* Message */
#alertbar.alertbar p { flex: 1; min-width: 0; margin: 0; color: #c9cee6; white-space: nowrap; overflow: hidden; text-overflow: ellipsis }
#alertbar.alertbar p b { color: #fff; font-weight: 700 }
/* Action principale */
#alertbar.alertbar a:not(.gate-bar) { flex: none; display: inline-flex; align-items: center; gap: .4rem; padding: .36rem .85rem; border-radius: 999px; font-weight: 700; font-size: .8rem; text-decoration: none; color: var(--ab-ink); background: var(--ab); box-shadow: 0 6px 18px -8px var(--ab); transition: transform .2s, box-shadow .2s }
#alertbar.alertbar a:not(.gate-bar)::after { content: "→"; transition: transform .2s }
#alertbar.alertbar a:not(.gate-bar):hover, #alertbar.alertbar a:not(.gate-bar):focus-visible { transform: translateY(-1px); box-shadow: 0 10px 24px -8px var(--ab) }
#alertbar.alertbar a:not(.gate-bar):hover::after { transform: translateX(3px) }
[dir=rtl] #alertbar.alertbar a:not(.gate-bar)::after { content: "←" }
#alertbar.alertbar a:focus-visible, #alertbar.alertbar button:focus-visible { outline: 2px solid #fff; outline-offset: 2px }
/* Fermer */
#alertbar.alertbar button { flex: none; display: grid; place-items: center; width: 1.9rem; height: 1.9rem; padding: 0; border-radius: 50%; border: 0; cursor: pointer; color: #cfd3ea; background: rgba(255, 255, 255, .06); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .16); font-size: 1rem; transition: background .2s, color .2s }
#alertbar.alertbar button:hover { color: #fff; background: rgba(255, 255, 255, .14) }
/* Ligne de balayage */
#alertbar .ab-scan { position: absolute; left: 0; bottom: 0; height: 2px; width: 32%; background: linear-gradient(90deg, transparent, var(--ab), transparent); animation: ab-scan 3.4s linear infinite; pointer-events: none }
@keyframes ab-radar { 0% { transform: scale(1); opacity: .75 } 100% { transform: scale(2.1); opacity: 0 } }
@keyframes ab-blink { 50% { opacity: .35 } }
@keyframes ab-live { 0% { box-shadow: 0 0 0 0 rgba(255, 59, 92, .7) } 70%, 100% { box-shadow: 0 0 0 7px rgba(255, 59, 92, 0) } }
@keyframes ab-scan { from { transform: translateX(-100%) } to { transform: translateX(420%) } }
[dir=rtl] #alertbar .ab-scan { animation-direction: reverse }
/* Téléphone : deux lignes lisibles */
@media (max-width: 760px) {
   #alertbar.alertbar { display: flex; flex-wrap: wrap; gap: .45rem .55rem; padding-block: .55rem; font-size: .84rem }
   #alertbar .ab-sig { width: 1.8rem; height: 1.8rem }
   #alertbar .ab-time { display: none }
   #alertbar.alertbar button { margin-inline-start: auto }
   #alertbar.alertbar p { order: 5; flex-basis: 100%; white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical }
   #alertbar.alertbar a:not(.gate-bar) { order: 6 }
}
/* Thème clair */
html[data-theme=light] #alertbar.alertbar { color: #1d1b2c; background: linear-gradient(90deg, color-mix(in srgb, var(--ab) 22%, #fff) 0, rgba(255, 255, 255, .96) 36%); box-shadow: inset 3px 0 0 var(--ab), 0 8px 22px -16px rgba(29, 27, 44, .5) }
html[data-theme=light] #alertbar[data-level=warn] { --ab: #c77700 } html[data-theme=light] #alertbar[data-level=info] { --ab: #0b84b5 } html[data-theme=light] #alertbar[data-level=crit] { --ab: #d4143b }
html[data-theme=light] #alertbar.alertbar p { color: #4a4c60 } html[data-theme=light] #alertbar.alertbar p b { color: #1d1b2c }
html[data-theme=light] #alertbar .ab-time { color: #6a6c80; border-color: rgba(29, 27, 44, .15) }
html[data-theme=light] #alertbar.alertbar button { color: #4a4c60; background: rgba(29, 27, 44, .05); box-shadow: inset 0 0 0 1px rgba(29, 27, 44, .14) }
/* Contraste élevé, animations réduites, impression */
html.hc #alertbar.alertbar { background: #000 !important; box-shadow: inset 4px 0 0 #fff; border-bottom: 2px solid #fff }
html.hc #alertbar.alertbar a:not(.gate-bar) { background: #ffe14d; color: #000 }
@media (prefers-reduced-motion: reduce) { #alertbar .ab-sig i, #alertbar .ab-sig svg, #alertbar .ab-live::before, #alertbar .ab-scan { animation: none } #alertbar .ab-scan { display: none } }
html.rm #alertbar .ab-sig i, html.rm #alertbar .ab-sig svg, html.rm #alertbar .ab-live::before, html.rm #alertbar .ab-scan, html.lite #alertbar .ab-scan, html.lite #alertbar .ab-sig i { animation: none }
@media print { #alertbar .ab-scan, #alertbar .ab-sig i { display: none } }
/* Visiteur : bouton « Se connecter » de la barre d'alerte (ajouté par gate.js), dans le même style */
#alertbar.alertbar .gate-bar { flex: none; margin: 0; padding: .36rem .85rem; border-radius: 999px; clip-path: none; font: 700 .76rem/1 var(--tech, inherit); letter-spacing: .06em; text-decoration: none; color: #fff; background: linear-gradient(135deg, #ff2d7a, #c0156a); box-shadow: 0 6px 18px -8px #ff2d7a }
#alertbar.alertbar .gate-bar:hover, #alertbar.alertbar .gate-bar:focus-visible { filter: none; transform: translateY(-1px); box-shadow: 0 10px 24px -8px #ff2d7a }
@media (max-width: 760px) { #alertbar.alertbar .gate-bar { order: 7 } }

/* Pagination générique des listes (annonces, historiques des espaces) */
[data-pg-on] > .pg-off { display: none !important }
.tn-pager { margin-top: 1rem }

/* Espace habitant : partenaires de la ville */
.pt-list { list-style: none; margin: .8rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr)); gap: .6rem }
.pt-list a { display: grid; gap: .2rem; height: 100%; padding: .8rem .9rem; border-radius: 12px; text-decoration: none; background: rgba(255, 255, 255, .03); box-shadow: inset 0 0 0 1px var(--line); transition: box-shadow .2s, transform .2s }
.pt-list a:hover, .pt-list a:focus-visible { box-shadow: inset 0 0 0 1px var(--cyan); transform: translateY(-2px) }
.pt-list b { font-weight: 700 }
.pt-list span { font-size: .82rem; color: var(--mute) }
.pt-list .pt-more a { place-content: center; text-align: center; font-weight: 700; color: var(--cyan) }
html[data-theme=light] .pt-list a { background: var(--ink-soft) }

/* Défilement vers une ancre : jamais caché sous l'en-tête (qui grandit avec la barre d'alerte) */
:is(#inc-site, .ln-banner, .slow-bar, .emg-bar, .of-bar, .st-board) { scroll-margin-top: calc(var(--hh, 76px) + 1rem) }

/* F103 — bouton « Rapport d'activité » (administration) */
.head-acts { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; justify-content: flex-end }
.rp-btn { white-space: nowrap }

/* F104 — Coupure des communications annoncée */
.cc-box { position: relative; margin: 0 0 1.2rem; overflow: hidden; box-shadow: inset 0 0 0 1px rgba(255, 176, 32, .4), 0 18px 40px -24px rgba(255, 176, 32, .55) }
.cc-box::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 4px; background: linear-gradient(#ffb020, #ff3b5c) }
.cc-head { display: flex; gap: .9rem; align-items: flex-start }
.cc-head h2 { margin: 0 0 .2rem }
.cc-ico { flex: none; display: grid; place-items: center; width: 2.6rem; height: 2.6rem; border-radius: 12px; font-size: 1.3rem; background: rgba(255, 176, 32, .15); box-shadow: inset 0 0 0 1px rgba(255, 176, 32, .45) }
.cc-form { margin-top: 1rem; display: grid; gap: .9rem }
.cc-form[hidden] { display: none }
.cc-fields { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .7rem }
.cc-go { justify-self: start; background: linear-gradient(135deg, #ffb020, #ff3b5c); color: #1b0b00; font-weight: 800 }
.cc-auto { margin: 0; padding-inline-start: 1.2rem; display: grid; gap: .3rem; font-size: .86rem; color: var(--mute) }
.cc-auto b { color: var(--ink) }
.cc-live { margin-top: 1rem; display: grid; grid-template-columns: minmax(12rem, auto) 1fr; gap: .8rem 1.4rem; align-items: center; padding: 1rem 1.1rem; border-radius: 14px; background: rgba(255, 176, 32, .08); box-shadow: inset 0 0 0 1px rgba(255, 176, 32, .35) }
.cc-live--imm { background: rgba(255, 59, 92, .1); box-shadow: inset 0 0 0 1px rgba(255, 59, 92, .55); animation: cc-pulse 1.6s ease-in-out infinite }
.cc-live--cut { background: rgba(255, 59, 92, .08); box-shadow: inset 0 0 0 1px rgba(255, 59, 92, .4) }
.cc-count small { display: block; font-size: .78rem; color: var(--mute); text-transform: uppercase; letter-spacing: .08em }
.cc-count b { display: block; font: 800 2.2rem/1.1 var(--tech, inherit); font-variant-numeric: tabular-nums; color: #ffb020 }
.cc-live--imm .cc-count b, .cc-live--cut .cc-count b { color: #ff5c7a }
.cc-count span { font-size: .82rem; color: var(--mute) }
.cc-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: .35rem; font-size: .88rem }
.cc-steps li { display: flex; gap: .5rem; align-items: baseline }
.cc-steps li::before { flex: none; content: "○"; color: var(--mute) }
.cc-steps li.ok::before { content: "✓"; color: #34d399; font-weight: 800 }
.cc-live .actions { grid-column: 1 / -1; margin: 0 }
.cc-done { margin: .8rem 0 0; color: #34d399; font-weight: 600 }
@keyframes cc-pulse { 50% { box-shadow: inset 0 0 0 2px rgba(255, 59, 92, .8) } }
@media (max-width: 760px) { .cc-fields, .cc-live { grid-template-columns: 1fr } }
@media (prefers-reduced-motion: reduce) { .cc-live--imm { animation: none } }
html[data-theme=light] .cc-go { color: #fff }
.cc-fields--2 { grid-template-columns: repeat(2, minmax(0, 1fr)) }
.cc-form textarea { resize: vertical; min-height: 7rem }
.cc-preview { padding: .9rem 1rem; border-radius: 12px; background: rgba(255, 59, 92, .07); box-shadow: inset 0 0 0 1px rgba(255, 59, 92, .35) }
.cc-preview > small { display: block; margin-bottom: .4rem; font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: var(--mute) }
.cc-preview b { display: block; color: #ff7a93 }
.cc-preview p { margin: .35rem 0 }
.cc-preview ul { margin: .3rem 0; padding-inline-start: 1.2rem; display: grid; gap: .2rem; font-size: .9rem }
@media (max-width: 760px) { .cc-fields--2 { grid-template-columns: 1fr } }
html[data-theme=light] .cc-preview b { color: #c0103c }
