/* =========================================================
   Aubert AI — gestion utilisateur commune
   ========================================================= */

.user-management-profile {
    display: flex;
    align-items: center;
    gap: 10px;

    width: 280px;
    min-height: 66px;
    padding: 10px 12px;
    box-sizing: border-box;

    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.07);
}

.user-management-avatar {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 34px;
    height: 34px;
    min-width: 34px;

    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(135deg, #2563eb, #22d3ee);

    font-size: 13px;
    font-weight: 900;
}

.user-management-identity {
    min-width: 0;
    flex: 1;
}

.user-management-name,
.user-management-meta,
.user-management-role {
    display: block;
    margin: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 1.15;
}

.user-management-name {
    margin-bottom: 1px;
    color: #ffffff;
    font-size: 14px;
    font-weight: 800;
}

.user-management-meta {
    margin-bottom: 1px;
    color: #dbeafe;
    font-size: 12px;
    font-weight: 600;
}

.user-management-role {
    color: #dbeafe;
    font-size: 11px;
    font-weight: 700;
}

/* Les trois actions restent visibles */
.user-management-actions {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 7px;

    width: 280px;
    flex: 0 0 280px;
}

.user-management-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 210px;
    min-height: 42px;
    padding: 0 18px;
    box-sizing: border-box;

    border: 1px solid rgba(96, 165, 250, 0.55);
    border-radius: 10px;

    color: #ffffff;
    background: linear-gradient(135deg, #3b82f6, #2563eb);

    font-weight: 800;
    text-align: center;
    text-decoration: none;

    transition:
        transform 0.2s ease,
        border-color 0.2s ease,
        filter 0.2s ease;
}

.user-management-button:hover {
    transform: translateY(-1px);
    border-color: rgba(147, 197, 253, 0.9);
    filter: brightness(1.08);
}

@media (max-width: 920px) {
    .user-management-profile,
    .user-management-actions {
        width: 100%;
        max-width: 420px;
        flex-basis: auto;
    }

    .user-management-actions {
        align-items: center;
    }

    .user-management-button {
        width: 100%;
        max-width: 420px;
    }
}

/* Respecter l'attribut HTML hidden malgré display:inline-flex */
.user-management-button[hidden] {
    display: none !important;
}

/* =========================================================
   Aubert AI — états liens boutons gestion utilisateur
   Empêche les règles globales a / a:visited de surcharger
   l'apparence des boutons applicatifs.
   ========================================================= */

.user-management-button,
.user-management-button:link,
.user-management-button:visited {
    color: #ffffff;
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    border-color: rgba(96, 165, 250, 0.55);
    text-decoration: none;
}

.user-management-button:hover,
.user-management-button:focus-visible {
    color: #ffffff;
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    border-color: rgba(147, 197, 253, 0.9);
    filter: brightness(1.08);
}


/* =========================================================
   Aubert AI — bouton Déconnexion
   Alignement visuel strict sur les boutons applicatifs
   ========================================================= */

#appLogoutButton,
#appLogoutButton:link,
#appLogoutButton:visited,
#appLogoutButton:hover,
#appLogoutButton:focus,
#appLogoutButton:focus-visible,
#appLogoutButton:active {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    opacity: 1 !important;

    background: linear-gradient(135deg, #3b82f6, #2563eb);
    border-color: rgba(96, 165, 250, 0.55);

    font-weight: 800;
    text-decoration: none;
}

#appLogoutButton:hover,
#appLogoutButton:focus-visible {
    border-color: rgba(147, 197, 253, 0.9);
    filter: brightness(1.08);
}
