/**
 * Estilos para cabeçalho Ella
 * Elementos do carrinho e perfil do usuário
 */

/* Container das ações do cabeçalho */
.ella-header-actions {
    gap: 1rem;
}

/* Ícone do carrinho */
.ella-cart-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px;
    border-radius: 8px;
    transition: all 0.3s ease;
    text-decoration: none;
    position: relative;
}

.ella-cart-icon:hover {
    background-color: #f8f9fa;
    transform: translateY(-1px);
}

.ella-cart-icon svg {
    transition: fill 0.3s ease;
}

.ella-cart-icon:hover svg path {
    fill: #FDB813;
}

/* Badge do carrinho */
.ella-cart-badge {
    font-size: 0.75rem;
    font-weight: 600;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    background-color: #dc3545 !important;
    color: white;
    border: 2px solid white;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Botão do perfil do usuário */
.ella-user-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px;
    border: none;
    background: none;
    border-radius: 8px;
    transition: all 0.3s ease;
    cursor: pointer;
    text-decoration: none;
}

.ella-user-btn:hover {
    background-color: #f8f9fa;
    transform: translateY(-1px);
}

.ella-user-btn svg {
    transition: fill 0.3s ease;
}

.ella-user-btn:hover svg path {
    fill: #FDB813;
}

/* Avatar do usuário */
.ella-user-avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #022A60;
    transition: all 0.3s ease;
}

.ella-user-btn:hover .ella-user-avatar {
    border-color: #FDB813;
    transform: scale(1.05);
}

/* Dropdown do usuário */
.ella-user-dropdown {
    min-width: 200px;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    padding: 0.5rem 0;
    margin-top: 0.5rem;
}

.ella-user-dropdown .dropdown-header {
    padding: 0.5rem 1rem;
    color: #022A60;
    font-size: 0.9rem;
    border-bottom: 1px solid #e9ecef;
    margin-bottom: 0.25rem;
}

.ella-user-dropdown .dropdown-item {
    padding: 0.5rem 1rem;
    color: #022A60;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
}

.ella-user-dropdown .dropdown-item:hover {
    background-color: #FDB813;
    color: #022A60;
}

.ella-user-dropdown .dropdown-item i {
    width: 16px;
    text-align: center;
}

.ella-user-dropdown .dropdown-divider {
    margin: 0.5rem 0;
    border-color: #e9ecef;
}

/* Responsividade */
@media (max-width: 767px) {
    .ella-header-actions {
        gap: 0.75rem;
    }
    
    .ella-cart-icon,
    .ella-user-btn {
        padding: 6px;
    }
    
    .ella-cart-icon svg,
    .ella-user-btn svg {
        width: 20px;
        height: 20px;
    }
    
    .ella-cart-badge {
        font-size: 0.7rem;
        min-width: 16px;
        height: 16px;
    }
    
    .ella-user-dropdown {
        min-width: 180px;
    }
}

/* Animações */
@keyframes cartPulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

.ella-cart-icon.has-items {
    animation: cartPulse 0.6s ease-in-out;
}

/* Estados de foco para acessibilidade */
.ella-cart-icon:focus,
.ella-user-btn:focus {
    outline: 2px solid #FDB813;
    outline-offset: 2px;
}

.ella-user-dropdown .dropdown-item:focus {
    outline: none;
    background-color: #FDB813;
    color: #022A60;
}
