/*
 * MyBase - cadre de l'application (bandeau, menu latéral, zone de contenu)
 * Version : 1.0 - 06/10/2026
 *
 * Source unique de la mise en page commune à toutes les pages (commun/shell.php).
 * Le contenu propre à chaque page reste dans styles.css / mobile-*.css.
 * La version téléphone du cadre est dans layout-mobile.css (chargée sous le seuil
 * mobile défini dans commun/config_affichage.php).
 * Toutes les classes du cadre commencent par « mb- » : aucune collision avec le contenu.
 */

:root {
    --mb-topbar-h: 112px;
    --mb-sidebar-w: 236px;
    --mb-bg: #f4f6f8;
    --mb-surface: #ffffff;
    --mb-line: #e2e6ea;
    --mb-text: #1f2328;
    --mb-muted: #66707a;
    --mb-accent: #0a6ebd;
    --mb-accent-soft: #e8f2fb;
    --mb-side-bg: #1f2329;
    --mb-side-text: #d9dde2;
    --mb-side-muted: #8b949e;
    --mb-side-hover: #2c323a;
    --mb-radius: 8px;
}

body.mb-app {
    margin: 0;
    min-height: 100vh;
    height: auto;
    background: var(--mb-bg);
    color: var(--mb-text);
    font-family: Arial, Helvetica, sans-serif;
}

/* ===================== BANDEAU ===================== */

.mb-topbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: var(--mb-surface);
    border-bottom: 1px solid var(--mb-line);
    box-shadow: 0 2px 10px rgba(0, 0, 0, .05);
}

.mb-topbar-row {
    display: flex;
    align-items: center;
    gap: 18px;
    box-sizing: border-box;
    padding: 10px 20px;
}

.mb-burger {
    display: none;
}

.mb-brand {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    width: calc(var(--mb-sidebar-w) - 38px);
}

.mb-brand img {
    display: block;
    width: 92px;
    height: auto;
}

/* Recherche + filtres */
.mb-search {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 0;
}

.mb-search-field {
    display: flex;
    align-items: center;
    gap: 8px;
}

.mb-search-field input[type="search"] {
    flex: 1 1 auto;
    min-width: 0;
    height: 40px;
    box-sizing: border-box;
    padding: 0 14px;
    border: 1px solid #cfd6dc;
    border-radius: var(--mb-radius);
    background: #fff;
    font-size: 15px;
}

.mb-search-field input[type="search"]:focus {
    outline: 2px solid var(--mb-accent);
    outline-offset: 0;
    border-color: var(--mb-accent);
}

.mb-search-button {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 40px;
    padding: 0;
    border: 0;
    border-radius: var(--mb-radius);
    background: var(--mb-accent);
    color: #fff;
    cursor: pointer;
}

.mb-search-button svg {
    display: block;
}

.mb-filters-toggle {
    display: none;
}

.mb-filters {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 16px;
}

.mb-filters label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: var(--mb-muted);
}

.mb-filters select {
    height: 30px;
    max-width: 170px;
    padding: 0 6px;
    border: 1px solid #cfd6dc;
    border-radius: 6px;
    background: #fff;
    font-size: 13px;
    color: var(--mb-text);
}

.mb-filters-apply {
    display: none;
}

/* Accès rapides */
.mb-tools {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    gap: 6px;
}

.mb-tool {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    width: 58px;
    padding: 4px 0;
    border: 0;
    border-radius: var(--mb-radius);
    background: none;
    color: var(--mb-muted);
    font: inherit;
    font-size: 11px;
    text-decoration: none;
    cursor: pointer;
}

.mb-tool:hover,
.mb-tool:focus-visible {
    background: var(--mb-accent-soft);
    color: var(--mb-accent);
}

.mb-tool img {
    width: 40px;
    height: 40px;
    object-fit: contain;
}

/* Pastille (compteurs) */
.mb-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    box-sizing: border-box;
    border-radius: 10px;
    background: #d93025;
    color: #fff;
    font-size: 11px;
    font-weight: bold;
    font-style: normal;
}

/* ===================== CADRE : MENU + CONTENU ===================== */

.mb-shell {
    display: grid;
    grid-template-columns: var(--mb-sidebar-w) minmax(0, 1fr);
    align-items: start;
    min-height: calc(100vh - var(--mb-topbar-h));
}

.mb-shell--sans-menu {
    grid-template-columns: minmax(0, 1fr);
}

.mb-sidebar {
    position: sticky;
    top: var(--mb-topbar-h);
    height: calc(100vh - var(--mb-topbar-h));
    box-sizing: border-box;
    overflow-y: auto;
    padding: 14px 0 24px;
    background: var(--mb-side-bg);
    color: var(--mb-side-text);
}

.mb-sidebar-account {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 12px 10px;
    padding: 8px 6px 14px;
    border-bottom: 1px solid rgba(255, 255, 255, .1);
}

.mb-sidebar-avatar {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: var(--mb-accent);
    color: #fff;
    font-weight: bold;
}

.mb-sidebar-who {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.mb-sidebar-who strong {
    font-size: 14px;
    color: #fff;
}

.mb-sidebar-who small {
    overflow: hidden;
    color: var(--mb-side-muted);
    font-size: 12px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mb-sidebar-close {
    display: none;
}

.mb-sidebar-section {
    margin-top: 6px;
}

/* « Installer l'application » : 1re entrée du menu (affichée par scripts/ui.js) */
.mb-installer {
    margin: 4px 8px 8px;
}

.mb-installer[hidden] {
    display: none;
}

.mb-installer-bouton {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 10px 12px;
    border: 0;
    border-radius: 6px;
    background: #d32f2f;
    color: #fff;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 0 0 0 rgba(211, 47, 47, .6);
    animation: mb-installer-pulse 2s ease-out 3;
}

.mb-installer-bouton:hover,
.mb-installer-bouton:focus-visible {
    background: #b71c1c;
}

@keyframes mb-installer-pulse {
    to { box-shadow: 0 0 0 10px rgba(211, 47, 47, 0); }
}

/* Pastille rouge sur le bouton ☰ (téléphone) tant que l'application n'est pas installée */
.mb-pastille-installer {
    position: relative;
}

.mb-pastille-installer::after {
    content: "";
    position: absolute;
    top: 4px;
    right: 4px;
    width: 10px;
    height: 10px;
    border: 2px solid #fff;
    border-radius: 50%;
    background: #d32f2f;
}

.mb-installer-aide {
    max-width: 420px;
    width: calc(100% - 32px);
    padding: 20px 22px;
    border: 0;
    border-radius: 12px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, .25);
    color: var(--mb-text);
    line-height: 1.45;
}

.mb-installer-aide::backdrop {
    background: rgba(0, 0, 0, .45);
}

.mb-installer-aide h2 {
    margin: 0 0 10px;
    font-size: 19px;
}

.mb-installer-aide ol {
    margin: 0 0 12px;
    padding-left: 20px;
}

.mb-installer-aide li {
    margin-bottom: 6px;
}

.mb-installer-note {
    margin: 0 0 14px;
    color: var(--mb-muted);
    font-size: 13px;
}

.mb-sidebar-title {
    margin: 12px 18px 4px;
    color: var(--mb-side-muted);
    font-size: 11px;
    font-weight: bold;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.mb-sidebar ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.mb-sidebar-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin: 1px 8px;
    padding: 8px 10px;
    border-left: 3px solid transparent;
    border-radius: 6px;
    color: var(--mb-side-text);
    font-size: 14px;
    line-height: 1.3;
    text-decoration: none;
}

.mb-sidebar-link:hover,
.mb-sidebar-link:focus-visible {
    background: var(--mb-side-hover);
    color: #fff;
}

.mb-sidebar-link.is-active {
    border-left-color: #4aa3e8;
    background: var(--mb-side-hover);
    color: #fff;
    font-weight: bold;
}

.mb-backdrop {
    display: none;
}

.mb-main {
    min-width: 0;
    box-sizing: border-box;
    padding: 20px 24px 32px;
}

/* ===================== ANIMATION « ACTION DU MOMENT » ===================== */

.action-moment-overlay {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0);
    opacity: 0;
    pointer-events: all;
    transition: background .25s ease, opacity .2s ease;
}

.action-moment-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 105px;
}

.action-moment-overlay img {
    width: 56px;
    height: 56px;
    object-fit: contain;
    opacity: 0;
    transform: scale(.2) rotate(-5deg);
    transition: transform .55s cubic-bezier(.17, .67, .25, 1.35), opacity .18s ease;
}

.action-moment-overlay.action-moment-show {
    background: rgba(0, 0, 0, .45);
    opacity: 1;
}

.action-moment-overlay.action-moment-show img {
    opacity: 1;
    transform: scale(4.45) rotate(0deg);
    animation: actionMomentPulse .35s .5s ease-in-out;
}

.action-moment-message {
    margin: 0;
    color: #fff;
    font-size: clamp(18px, 2vw, 28px);
    font-weight: 600;
    line-height: 1.25;
    text-align: center;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity .25s ease .3s, transform .25s ease .3s;
    text-shadow: 0 2px 8px rgba(0, 0, 0, .45);
}

.action-moment-overlay.action-moment-show .action-moment-message {
    opacity: 1;
    transform: translateY(0);
}

@keyframes actionMomentPulse {
    0% { transform: scale(4.45); }
    50% { transform: scale(4.9); }
    100% { transform: scale(4.45); }
}

/* Écrans PC étroits : on resserre avant de passer en version mobile. */
@media (max-width: 1100px) {
    .mb-tool span {
        display: none;
    }

    .mb-tool {
        width: 46px;
    }

    .mb-brand {
        width: auto;
    }
}

/* ===================== EN-TÊTE DE PAGE (titre + actions) ===================== */
/* Utilisation : <div class="mb-page-head"><h1>Titre</h1><div class="mb-page-actions">…</div></div> */

.mb-page-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px 16px;
    margin: 0 0 16px;
}

.mb-page-head h1 {
    margin: 0;
    font-size: 24px;
    line-height: 1.25;
}

.mb-page-sub {
    color: var(--mb-muted);
    font-weight: normal;
}

.mb-page-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.mb-message {
    max-width: 720px;
    padding: 16px 18px;
    border: 1px solid var(--mb-line);
    border-left: 4px solid var(--mb-accent);
    border-radius: var(--mb-radius);
    background: var(--mb-surface);
    line-height: 1.5;
}

/* ===================== PAGES PUBLIQUES (connexion, compte, mot de passe) ===================== */

.mb-public {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    min-height: 100vh;
    box-sizing: border-box;
    padding: 6vh 16px 32px;
}

.mb-public-card {
    width: 100%;
    max-width: 420px;
    box-sizing: border-box;
    padding: 28px 28px 24px;
    border: 1px solid var(--mb-line);
    border-radius: 12px;
    background: var(--mb-surface);
    box-shadow: 0 6px 24px rgba(0, 0, 0, .06);
}

.mb-public-logo {
    display: block;
    margin: 0 auto 12px;
    text-align: center;
}

.mb-public-logo img {
    width: 140px;
    height: auto;
}

.mb-public-card h1 {
    margin: 0 0 18px;
    font-size: 22px;
    text-align: center;
}

.mb-public-liens {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    margin-top: 18px;
    font-size: 14px;
}

.mb-public-liens a:not(.mb-bouton) {
    color: var(--mb-accent);
}

/* Connexion Microsoft (SSO) */
.mb-sso-ou {
    margin: 14px 0 8px;
    text-align: center;
    color: var(--mb-muted);
    font-size: 14px;
}

.mb-bouton-microsoft {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 10px 16px;
    border: 1px solid #8c8c8c;
    border-radius: 4px;
    background: #fff;
    color: #5e5e5e;
    font-weight: 600;
    text-decoration: none;
}

.mb-bouton-microsoft:hover {
    background: #f3f3f3;
}

/* Connexion avec l'e-mail : formulaire replié sous le bouton Microsoft */
.mb-connexion-email {
    margin-top: 18px;
    padding-top: 12px;
    border-top: 1px solid var(--mb-line);
}

.mb-connexion-email > summary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 6px 0;
    color: var(--mb-text);
    font-weight: 600;
    cursor: pointer;
    list-style: none;
}

.mb-connexion-email > summary::-webkit-details-marker {
    display: none;
}

.mb-connexion-email > summary::after {
    content: "⬇";
}

.mb-connexion-email[open] > summary::after {
    content: "⬆";
}

.mb-connexion-email > .mb-form {
    margin-top: 12px;
}

.mb-connexion-note {
    margin: 0;
    color: var(--mb-muted);
    font-size: 13px;
}

/* ===================== FORMULAIRES SIMPLES ===================== */

.mb-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.mb-form label {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 14px;
    font-weight: bold;
}

.mb-form small {
    color: var(--mb-muted);
    font-weight: normal;
}

.mb-form input[type="email"],
.mb-form input[type="password"],
.mb-form input[type="text"] {
    height: 42px;
    box-sizing: border-box;
    padding: 0 12px;
    border: 1px solid #cfd6dc;
    border-radius: var(--mb-radius);
    font-size: 16px;
}

.mb-form input:focus {
    outline: 2px solid var(--mb-accent);
    border-color: var(--mb-accent);
}

.mb-bouton {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 18px;
    border: 0;
    border-radius: var(--mb-radius);
    background: var(--mb-accent);
    color: #fff;
    font-size: 15px;
    font-weight: bold;
    text-decoration: none;
    cursor: pointer;
}

.mb-bouton:hover {
    filter: brightness(1.08);
}

.mb-alerte {
    margin: 0;
    padding: 10px 12px;
    border-radius: var(--mb-radius);
    font-size: 14px;
    line-height: 1.4;
}

.mb-alerte--erreur {
    border: 1px solid #f1b0ab;
    background: #fdecea;
    color: #8a1c13;
}

.mb-alerte--succes {
    border: 1px solid #a8d5b2;
    background: #e9f6ec;
    color: #1d5b2b;
}

.mb-alerte--info {
    border: 1px solid #b6d4f0;
    background: var(--mb-accent-soft);
    color: #0b4a7d;
}

.mb-bouton--danger {
    background: #c5221f;
}

.mb-bouton--secondaire {
    border: 1px solid #cfd6dc;
    background: #fff;
    color: var(--mb-text);
}

.mb-bouton--petit {
    min-height: 30px;
    padding: 0 12px;
    font-size: 13px;
}

/* Page « Alertes mail » */
.mb-alerte-equipe {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 4px 16px;
    margin: 8px 0;
    font-size: 13px;
}

.mb-alerte-equipe label {
    display: flex;
    align-items: center;
    gap: 6px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mb-alerte-autres {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin: 8px 0;
    font-size: 13px;
}

.mb-alerte-sous-titre {
    margin: 12px 0 6px;
    font-size: 14px;
}

.mb-alerte-marques td,
.mb-alerte-marques th {
    text-align: center;
}

.mb-alerte-marques td:first-child,
.mb-alerte-marques th:first-child {
    text-align: left;
}

.mb-alerte-marque-autres {
    width: 220px;
    height: 22px;
    padding: 0 4px;
    border: 1px solid #cfd6dc;
    border-radius: 4px;
    font-size: 10px;
}

.mb-alerte-autres input {
    height: 32px;
    padding: 0 8px;
    border: 1px solid #cfd6dc;
    border-radius: 6px;
}

.mb-confirmation p {
    margin: 0 0 14px;
}

/* ===================== PAGES DE SUIVI (utilisateurs, SSO) ===================== */
/* Cartes, compteurs cliquables, filtres et tableau compact, communs aux pages
   « Gérer les utilisateurs » et « Connexion Microsoft (SSO) ». */

.mb-carte {
    margin-bottom: 12px;
    padding: 12px 14px;
    border: 1px solid var(--mb-line);
    border-radius: var(--mb-radius);
    background: var(--mb-surface);
}

.mb-carte h2 {
    margin: 0 0 8px;
    font-size: 16px;
}

.mb-carte p {
    margin: 4px 0;
}

.mb-chiffres {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
    gap: 8px;
}

.mb-chiffre {
    display: block;
    padding: 6px 8px;
    border: 1px solid var(--mb-line);
    border-radius: var(--mb-radius);
    color: var(--mb-text);
    font-size: 12px;
    text-align: center;
    text-decoration: none;
}

.mb-chiffre strong {
    display: block;
    font-size: 20px;
}

a.mb-chiffre:hover {
    border-color: var(--mb-accent);
}

.mb-chiffre.actif {
    border-color: var(--mb-accent);
    background: var(--mb-accent-soft);
}

.mb-barre {
    height: 8px;
    margin-top: 10px;
    overflow: hidden;
    border-radius: 4px;
    background: #e9ecef;
}

.mb-barre span {
    display: block;
    height: 100%;
    background: #1d7a3a;
}

.mb-ok { color: #1d7a3a; font-weight: 600; }
.mb-ko { color: #a32121; font-weight: 600; }
.mb-attention { color: #9a6700; font-weight: 600; }
.mb-discret { color: var(--mb-muted); }

.mb-onglets a {
    display: inline-block;
    margin: 0 6px 8px 0;
    padding: 4px 10px;
    border: 1px solid #ccc;
    border-radius: 6px;
    color: inherit;
    text-decoration: none;
}

.mb-onglets a.actif {
    border-color: var(--mb-accent);
    background: var(--mb-accent);
    color: #fff;
}

.mb-filtres {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 6px 10px;
    font-size: 12px;
}

.mb-filtres label {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.mb-filtres input,
.mb-filtres select {
    height: 28px;
    padding: 0 6px;
    border: 1px solid #cfd6dc;
    border-radius: 6px;
    font-size: 12px;
}

.mb-filtres label.mb-filtre-case {
    flex-direction: row;
    align-items: center;
    gap: 4px;
    height: 28px;
    white-space: nowrap;
}

.mb-filtres label.mb-filtre-case input {
    height: auto;
}

.mb-filtres .mb-bouton {
    min-height: 28px;
    padding: 0 12px;
    font-size: 12px;
}

.mb-table-zone {
    overflow-x: auto;
}

/* Tableau compact : vue globale (police 10 px, lignes serrées). */
.mb-table-compacte {
    width: 100%;
    border-collapse: collapse;
    font-size: 10px;
    line-height: 1.3;
}

.mb-table-compacte th,
.mb-table-compacte td {
    padding: 2px 6px;
    border-bottom: 1px solid #eef0f2;
    text-align: left;
    white-space: nowrap;
}

.mb-table-compacte th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: #f1f3f5;
    font-weight: 700;
}

.mb-table-compacte th a {
    color: inherit;
    text-decoration: none;
}

.mb-table-compacte th a:hover {
    color: var(--mb-accent);
}

.mb-table-compacte tbody tr:nth-child(even) {
    background: #fafbfc;
}

.mb-table-compacte tbody tr.mb-ligne-lien {
    cursor: pointer;
}

.mb-table-compacte tbody tr.mb-ligne-lien:hover {
    background: var(--mb-accent-soft);
}

.mb-table-compacte td a {
    color: inherit;
    text-decoration: none;
}

/* ------------------------------------------------------------------ */
/* Tuiles des applications (Mes applications, Superviseur) — 1.3.0     */
/* Affichage : mybase_applications_tuiles() (commun/shell.php)         */
/* ------------------------------------------------------------------ */
.mb-applis {
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
    margin-top: 20px;
}

.mb-appli {
    width: 170px;
    min-height: 180px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 18px;
    box-sizing: border-box;
    border: 1px solid #ddd;
    border-radius: 10px;
    background: #fff;
    color: inherit;
    text-decoration: none;
    text-align: center;
    font-weight: 600;
    transition: transform .15s ease, box-shadow .15s ease;
}

.mb-appli:hover,
.mb-appli:focus-visible {
    transform: translateY(-2px);
    box-shadow: 0 4px 14px rgba(0, 0, 0, .12);
}

.mb-appli img,
.mb-appli-lettre {
    width: 110px;
    height: 110px;
    object-fit: contain;
}

.mb-appli-lettre {
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 18px;
    background: var(--mb-accent, #1e5aa8);
    color: #fff;
    font-size: 44px;
}

@media (max-width: 700px) {
    .mb-applis {
        justify-content: center;
    }
}

/* Page Applications : formulaire « Personnaliser » (nom, lien, icône) */
.mb-applications-perso summary {
    cursor: pointer;
    color: var(--mb-accent, #1e5aa8);
    font-size: 12px;
    margin-top: 4px;
}

.mb-applications-perso form {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 6px;
    min-width: 240px;
}

.mb-applications-perso label {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 12px;
}

.mb-applications-perso input[type=text] {
    width: 100%;
    box-sizing: border-box;
}

/* Gérer droits App : barre d'enregistrement / réglage de masse et cellules de droits (1.4.0) */
.mb-droits-barre {
    position: sticky;
    top: 0;
    z-index: 3;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 14px;
    padding: 8px 10px;
    margin: 10px 0 6px;
    background: var(--mb-accent-soft, #eef4fb);
    border: 1px solid #d8e0ea;
    border-radius: 8px;
    font-size: 13px;
}

.mb-droits-masse {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    margin-left: auto;
}

select.mb-droit {
    font-size: 11px;
    padding: 1px 2px;
    border-radius: 4px;
    border: 1px solid #c9d2dc;
}

select.mb-droit--aucun { color: #8a94a0; }
select.mb-droit--acces { color: #1b7a3a; }
select.mb-droit--admin { color: #1e5aa8; font-weight: 700; }
select.mb-droit-defaut { font-style: italic; }
select.mb-droit-modifie { background: #fff4d6; border-color: #e0a800; }

.mb-table-compacte tbody tr.mb-ligne-choisie { background: var(--mb-accent-soft, #eef4fb); }

.mb-application-apercu img {
    width: 32px;
    height: 32px;
    object-fit: contain;
    vertical-align: middle;
}

@media (max-width: 700px) {
    .mb-droits-masse { margin-left: 0; }
}

/* Accueil sans recherche : « Bonjour Prénom, » (1.6.0, prénom lu dans MySecto) */
.mb-bonjour {
    margin: 4px 0 14px;
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--mb-texte, #1f2937);
}
