/**
 * Styles pour le bouton d'authentification et le menu déroulant
 */

/* Style de base pour le bouton d'authentification */
.auth-button {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.auth-button:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    text-decoration: none;
    color: white;
}

/* Style pour le bouton quand l'utilisateur est connecté */
.auth-button.logged-in {
    background: var(--primary-color);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.auth-button.logged-in:hover {
    background: var(--primary-color-dark, #3a7bc8);
}

/* Style pour l'initiale de l'utilisateur */
.user-initial {
    font-weight: bold;
    font-size: 1rem;
    text-transform: uppercase;
}

/* Style pour le menu déroulant */
.auth-dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    width: 240px;
    background-color: var(--color-surface, white);
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    padding: 12px 0;
    z-index: 1000;
    display: none;
    animation: fadeIn 0.2s ease-in-out;
    border: 1px solid var(--color-border, rgba(0, 0, 0, 0.1));
}

.dropdown-menu.show {
    display: block;
}

/* Ajout d'une flèche vers le haut */
.dropdown-menu::before {
    content: '';
    position: absolute;
    top: -8px;
    right: 16px;
    width: 14px;
    height: 14px;
    background-color: var(--color-surface, white);
    transform: rotate(45deg);
    border-top: 1px solid var(--color-border, rgba(0, 0, 0, 0.1));
    border-left: 1px solid var(--color-border, rgba(0, 0, 0, 0.1));
}

/* Style pour l'email de l'utilisateur */
.user-email {
    display: block;
    padding: 8px 16px;
    margin-bottom: 8px;
    border-bottom: 1px solid var(--color-border, rgba(0, 0, 0, 0.1));
    color: var(--color-text-muted, #666);
    font-size: 0.9rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Style pour les éléments du menu */
.dropdown-item {
    display: flex;
    align-items: center;
    padding: 10px 16px;
    color: var(--color-text, #333);
    text-decoration: none;
    font-size: 0.95rem;
    transition: background-color 0.2s;
    cursor: pointer;
    border: none;
    background: transparent;
    width: 100%;
    text-align: left;
}

.dropdown-item:hover {
    background-color: var(--color-surface-hover, #f5f5f5);
    color: var(--primary-color, #4a90e2);
}

.dropdown-item i {
    margin-right: 10px;
    width: 20px;
    text-align: center;
    color: var(--color-text-muted, #666);
}

.dropdown-item:hover i {
    color: var(--primary-color, #4a90e2);
}

/* Animation pour l'apparition du menu */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Adaptations pour le mode sombre */
[data-theme="dark"] .dropdown-menu {
    background-color: var(--color-surface-dark, #222);
    border-color: var(--color-border-dark, rgba(255, 255, 255, 0.1));
}

[data-theme="dark"] .dropdown-menu::before {
    background-color: var(--color-surface-dark, #222);
    border-color: var(--color-border-dark, rgba(255, 255, 255, 0.1));
}

[data-theme="dark"] .dropdown-item:hover {
    background-color: var(--color-surface-hover-dark, #333);
}

/* Adaptations pour les écrans mobiles */
@media (max-width: 767px) {
    .dropdown-menu {
        width: 200px;
        right: -10px;
    }
} 