/* Annuaire du GU : mêmes jetons que les autres outils, accent marine du hub. */
:root { --app: #001a70; --app-soft: #e6eaf6; --app-fort: #001a70; }
.wrap { max-width: 860px; }
.hd, .wrap { padding-left: max(16px, env(safe-area-inset-left)); padding-right: max(16px, env(safe-area-inset-right)); }
.retour-hub { display: inline-block; color: #c8cfd9; font-size: 14px; text-decoration: none; margin-top: 6px; }
.outils { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 12px; }
.outils .in { flex: 1 1 220px; }
.outils .seg { flex: 1 1 320px; }
.compte { font-size: 13px; color: var(--gray-700); margin: 0 2px 8px; }
.liste { background: #fff; border: 1px solid var(--gray-300); border-radius: var(--r-3); overflow: hidden; }
.pers { display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px 14px; border: 0; border-top: 1px solid var(--gray-200);
        background: none; text-align: left; font: inherit; color: inherit; cursor: pointer; min-height: 60px; }
.pers:first-child { border-top: 0; }
.pers:hover { background: var(--gray-100); }
.pers .t { flex: 1; min-width: 0; }
.pers .t b { display: block; font-size: 15px; overflow-wrap: anywhere; }
.pers .t span { display: block; font-size: 13px; color: var(--gray-700); overflow-wrap: anywhere; }
.pers.inactif .t b { color: var(--gray-600); text-decoration: line-through; }
.role { font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 999px; white-space: nowrap; flex: none; }
.role.admin { background: #001a70; color: #fff; }
.role.interne { background: #e6eaf6; color: #001a70; }
.role.externe { background: #fff1df; color: #8a4500; }
.vide { padding: 16px; color: var(--gray-600); }
.seg button[aria-pressed="true"] { background: var(--app); color: #fff; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.row2 > * { min-width: 0; }
.check { display: flex; gap: 10px; align-items: center; margin-top: 14px; font-size: 15px; }
.check input { width: 22px; height: 22px; }
/* Fenêtres (fiche d'une personne…) : hauteur bornée à l'écran, titre fixe, corps qui défile.
   Sur iPhone, faire défiler le <dialog> lui-même est capricieux : c'est le corps (.dlg-b) qui défile. */
dialog { max-height: calc(100vh - 24px); max-height: calc(100dvh - 24px - env(safe-area-inset-top) - env(safe-area-inset-bottom));
         overflow: hidden; }
dialog[open] { display: flex; flex-direction: column; }
dialog .dlg-h { flex: none; padding-bottom: 8px; }
dialog .dlg-b { flex: 1 1 auto; min-height: 0; overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; }
.bas { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 18px; }
@media (max-width: 520px) { .row2 { grid-template-columns: 1fr; } }
.pers .t .habs { font-size: 12px; color: var(--app-fort); margin-top: 2px; }
.sous-t { font-size: 15px; margin: 22px 0 4px; }
.check { display: flex; gap: 10px; align-items: center; margin-top: 10px; font-size: 15px; }
#p-niveau { margin-bottom: 4px; }

/* Accès aux applis : exceptions dans la fiche, règles par appli dans l'onglet. */
.acc-liste { display: grid; gap: 6px; margin-top: 8px; }
.acc-l { display: grid; grid-template-columns: minmax(0, 1fr) 170px; gap: 8px; align-items: center; font-size: 14px; }
.acc-s { padding: 6px 8px; min-height: 38px; font-size: 14px; }
@media (max-width: 420px) { .acc-l { grid-template-columns: 1fr; gap: 2px; } }
.acc-app { margin-bottom: 12px; }
.acc-bloc { margin-top: 10px; }
.acc-bloc .seg { margin-top: 4px; }
.acc-choix { display: flex; flex-wrap: wrap; gap: 0 18px; }
.acc-choix .check { margin-top: 8px; }
.btn.small { min-height: 36px; padding: 0 12px; font-size: 14px; width: auto; }
a.btn { text-decoration: none; text-align: center; }
/* Demandes d'accès des visiteurs */
.pastille { display: inline-block; min-width: 20px; padding: 2px 6px; border-radius: 999px; background: #ff861d; color: #001a70; font-size: 12px; font-weight: 700; line-height: 16px; }
.dem { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; }
.dem-t { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1 1 260px; }
.dem-t b { font-size: 16px; }
.dem-t > span:not(.hint) { font-size: 14px; color: var(--gray-700); overflow-wrap: anywhere; }
.dem-b { display: flex; gap: 8px; flex: none; }
.dem-b .btn { min-width: 110px; }
.dem-h { margin: 22px 2px 8px; font-size: 15px; }

/* Habilitations (titres) — encadrement */
.tih-kpi { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 0 0 10px; }
.tih-kpi > div { background: #fff; border: 1px solid var(--gray-200); border-radius: 14px; padding: 12px 14px; }
.tih-kpi b { display: block; font-size: 26px; line-height: 1.1; color: #001a70; }
.tih-kpi span { font-size: 13px; color: var(--gray-700); }
.tih-kpi .bientot b { color: #b44a06; } .tih-kpi .echu b { color: #a3190f; }
.tih-syms { display: flex !important; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.tih-cat { font-family: "IBM Plex Mono", monospace; font-size: 11.5px; font-weight: 600; padding: 2px 7px; border-radius: 6px; background: #e6eaf6; color: #001a70; }
.tih-cat.tih-1 { background: #eef6f0; color: #0d5c37; } .tih-cat.tih-2 { background: #f3effb; color: #5b3fa8; }
.tih-fin { flex: none; text-align: right; font-size: 13px; color: var(--gray-700); line-height: 1.25; }
.tih-fin b { display: block; font-size: 12px; padding: 3px 9px; border-radius: 999px; background: #e3f5eb; color: #0d6139; margin-bottom: 3px; text-align: center; }
.tih-fin.bientot b { background: #fff3e8; color: #b44a06; } .tih-fin.echu b { background: #fdecea; color: #a3190f; }
.tih-tete { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.tih-tete .tih-fin { text-align: left; }
.tih-l > div { display: flex; gap: 10px; align-items: flex-start; padding: 8px 0; border-top: 1px solid var(--gray-200); }
.tih-l > div:first-child { border-top: 0; }
.tih-l b { font-family: "IBM Plex Mono", monospace; font-size: 13px; min-width: 52px; color: #001a70; }
.tih-l span { flex: 1; font-size: 14px; }
.tih-l small { display: block; color: var(--gray-700); font-size: 12.5px; margin-top: 2px; }
.tih-l i { font-style: normal; font-size: 12.5px; white-space: nowrap; color: var(--gray-700); }
.tih-l i.echu { color: #a3190f; font-weight: 700; } .tih-l i.bientot { color: #b44a06; font-weight: 700; }
