/* ========================================
   CABEÇALHO INSTITUCIONAL - FLUTUANTE
   ======================================== */
.cabecalho-institucional {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: #ffffff;
    border-bottom: 1px solid #e9edf4;
    padding: 0 40px;
    height: 72px;
    display: flex;
    align-items: center;
    transition: box-shadow 0.3s ease, background 0.3s ease;
}

.cabecalho-institucional.scrolled {
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.08);
    background: #ffffff;
}

.cabecalho-container {
    max-width: 1280px;
    width: 100%;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* ========================================
   LOGO
   ======================================== */
.logo-link {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    flex-shrink: 0;
}

.logo-img {
    height: 38px;
    width: auto;
    display: block;
    border-radius: 5px;
}

.logo-text {
    font-family: 'Inter', 'Segoe UI', sans-serif;
    font-size: 22px;
    font-weight: 800;
    color: #0f172a;
    letter-spacing: -0.5px;
}

.logo-text span {
    color: #2563eb;
}

/* ========================================
   MENU PRINCIPAL (Desktop)
   ======================================== */
.nav-principal {
    display: flex;
    align-items: center;
}

.nav-lista {
    display: flex;
    list-style: none;
    gap: 8px;
    margin: 0;
    padding: 0;
}

.nav-item .nav-link {
    display: block;
    padding: 8px 20px;
    color: #475569;
    font-family: 'Inter', 'Segoe UI', sans-serif;
    font-size: 15px;
    font-weight: 500;
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.nav-item .nav-link:hover {
    background: #f1f5f9;
    color: #0f172a;
}

/* ========================================
   BOTÃO ACESSAR PLATAFORMA
   ======================================== */
.cabecalho-acao {
    flex-shrink: 0;
}

.btn-acessar {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 24px;
    background: #2563eb;
    color: #ffffff;
    font-family: 'Inter', 'Segoe UI', sans-serif;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    border-radius: 30px;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.btn-acessar:hover {
    background: #1d4ed8;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.4);
}

.btn-acessar i {
    font-size: 14px;
    transition: transform 0.3s ease;
}

.btn-acessar:hover i {
    transform: translateX(4px);
}

/* ========================================
   MENU MOBILE (oculto por padrão) - CORRIGIDO
   ======================================== */
.menu-mobile-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 28px;
    color: #0f172a;
    cursor: pointer;
    padding: 12px;
    border-radius: 8px;
    transition: background 0.2s;
}

.menu-mobile-toggle:hover {
    background: #f1f5f9;
}

.menu-mobile {
    display: none;
    position: fixed;
    top: 0;
    right: -100%;
    width: 85%;
    max-width: 400px;
    height: 100vh;
    background: #ffffff;
    z-index: 1002;
    padding: 32px 32px 32px 24px;
    box-shadow: -10px 0 40px rgba(0, 0, 0, 0.15);
    transition: right 0.3s ease;
    overflow-y: auto;
}

.menu-mobile.aberto {
    right: 0;
    display: block;
}

.menu-mobile-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 40px;
    padding-bottom: 20px;
    border-bottom: 1px solid #e9edf4;
}

.menu-mobile-header .logo-link {
    gap: 10px;
}

.menu-mobile-header .logo-img {
    height: 38px;
}

.menu-mobile-header .logo-text {
    font-size: 22px;
}

.menu-mobile-fechar {
    background: none;
    border: none;
    font-size: 28px;
    color: #475569;
    cursor: pointer;
    padding: 10px;
    border-radius: 8px;
    transition: background 0.2s;
}

.menu-mobile-fechar:hover {
    background: #f1f5f9;
}

.menu-mobile-lista {
    list-style: none;
    padding: 0;
    margin: 0;
}

.menu-mobile-lista li {
    margin-bottom: 8px;
}

.menu-mobile-lista li a {
    display: block;
    padding: 16px 20px;
    color: #0f172a;
    font-family: 'Inter', 'Segoe UI', sans-serif;
    font-size: 18px;
    font-weight: 600;
    text-decoration: none;
    border-radius: 12px;
    transition: background 0.2s;
}

.menu-mobile-lista li a:hover {
    background: #f1f5f9;
}

.menu-mobile-lista .menu-mobile-destaque a {
    margin-top: 20px;
    background: #2563eb;
    color: #ffffff;
    text-align: center;
    border-radius: 30px;
    padding: 18px 24px;
    font-weight: 700;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.menu-mobile-lista .menu-mobile-destaque a:hover {
    background: #1d4ed8;
}

/* ========================================
   OVERLAY PARA MENU MOBILE
   ======================================== */
.overlay-mobile {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1001;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.overlay-mobile.ativo {
    display: block;
    opacity: 1;
}

/* ========================================
   RESPONSIVIDADE
   ======================================== */
@media (max-width: 992px) {
    .cabecalho-institucional {
        padding: 0 24px;
        height: 64px;
    }
    
    .nav-principal {
        display: none;
    }
    
    .menu-mobile-toggle {
        display: block;
    }
    
    .btn-acessar {
        display: none;
    }
}

@media (max-width: 768px) {
    .cabecalho-institucional {
        padding: 0 16px;
        height: 64px;
    }
    
    .logo-img {
        height: 36px;
    }
    
    .logo-text {
        font-size: 20px;
    }
    
    .menu-mobile {
        width: 85%;
        max-width: 380px;
        right: -100%;
        padding: 28px 28px 28px 20px;
    }
}

@media (max-width: 480px) {
    .cabecalho-institucional {
        padding: 0 12px;
        height: 60px;
    }
    
    .logo-img {
        height: 32px;
    }
    
    .logo-text {
        font-size: 18px;
    }
    
    .menu-mobile {
        width: 88%;
        max-width: 340px;
        right: -100%;
        padding: 24px 24px 24px 16px;
    }
    
    .menu-mobile-lista li a {
        font-size: 17px;
        padding: 14px 18px;
    }
    
    .menu-mobile-lista .menu-mobile-destaque a {
        font-size: 17px;
        padding: 16px 20px;
    }
}