/* ===== HEADER ===== */
.header {
    background: var(--bg-header);
    padding: 15px 30px;
    border-bottom: 2px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: all 0.3s ease;
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

/* Logo/Título */
.header-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.header-brand h1 {
    font-size: 1.4rem;
    color: var(--text-primary);
    margin: 0;
    font-weight: 600;
}

.header-brand .logo {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--accent-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 1.2rem;
}

/* Navegação direita */
.header-nav {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Botão Dark Mode */
.dark-mode-toggle {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    font-size: 1.2rem;
}

.dark-mode-toggle:hover {
    background: var(--accent-color);
    color: white;
    transform: rotate(20deg);
}

/* Perfil Dropdown */
.profile-dropdown {
    position: relative;
}

.profile-trigger {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 14px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.2s ease;
}

.profile-trigger:hover {
    background: var(--accent-color);
    color: white;
    border-color: var(--accent-color);
}

.profile-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--accent-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.9rem;
}

.profile-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.profile-name {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-primary);
}

.profile-role {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.profile-trigger .arrow {
    margin-left: 5px;
    font-size: 0.7rem;
    transition: transform 0.2s ease;
}

.profile-dropdown.active .arrow {
    transform: rotate(180deg);
}

/* Dropdown Menu */
.dropdown-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    min-width: 220px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1001;
}

.profile-dropdown.active .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu::before {
    content: '';
    position: absolute;
    top: -6px;
    right: 20px;
    width: 12px;
    height: 12px;
    background: var(--bg-secondary);
    border-left: 1px solid var(--border-color);
    border-top: 1px solid var(--border-color);
    transform: rotate(45deg);
}

.dropdown-header {
    padding: 15px 18px;
    border-bottom: 1px solid var(--border-light);
}

.dropdown-header .user-name {
    font-weight: 600;
    font-size: 1rem;
    color: var(--text-primary);
    margin-bottom: 3px;
}

.dropdown-header .user-email {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 18px;
    color: var(--text-primary);
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
    font-size: 0.95rem;
}

.dropdown-item:hover {
    background: var(--bg-primary);
}

.dropdown-item .icon {
    font-size: 1.1rem;
    width: 20px;
    text-align: center;
}

.dropdown-divider {
    height: 1px;
    background: var(--border-light);
    margin: 5px 0;
}

.dropdown-item.logout {
    color: #d32f2f;
    font-weight: 500;
}

.dropdown-item.logout:hover {
    background: #ffebee;
}

body.dark-mode .dropdown-item.logout:hover {
    background: #4a1f1f;
}

/* Responsive */
@media (max-width: 768px) {
    .header {
        padding: 12px 16px;
    }
    
    .header-brand h1 {
        font-size: 1.1rem;
    }
    
    .profile-info {
        display: none;
    }
    
    .dropdown-menu {
        right: -10px;
    }
}
/* Botão Home estilo grande, igual ao dark mode toggle */
.btn-header {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;       /* mesmo tamanho do botão da lua */
    height: 42px;      /* mesmo tamanho do botão da lua */
    border-radius: 50%; /* círculo perfeito */
    background: #888;   /* cinza */
    color: #fff;
    font-size: 1.9rem;
    text-decoration: none;
    cursor: pointer;
    transition: 0.2s;
}

.btn-header:hover {
    background: #666;  /* cinza mais escuro no hover */
}