body { background-color: #f8f9fa; }

/* =========================================
   ESTILOS DO MENU LATERAL (SIDEBAR)
   ========================================= */

/* Botão Hamburger (Gatilho) */
.btn-sidebar-toggle {
    background: transparent;
    border: none;
    color: white; /* Contraste com o bg-primary do header */
    font-size: 1.5rem;
    padding: 0;
    margin-right: 15px;
    cursor: pointer;
    transition: transform 0.2s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-sidebar-toggle:hover {
    color: rgba(255, 255, 255, 0.8);
    transform: scale(1.1);
}

/* Container da Sidebar */
.sidebar {
    height: 100vh;
    width: 280px;
    position: fixed;
    top: 0;
    left: -280px; /* Escondido inicialmente */
    background-color: #fff;
    z-index: 2000; /* Acima do Bootstrap Navbar (que geralmente é 1030) */
    overflow-y: auto;
    transition: left 0.3s ease-in-out;
    box-shadow: 4px 0 15px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
}

/* Classe ativa para mostrar a sidebar */
.sidebar.active {
    left: 0;
}

/* Cabeçalho da Sidebar */
.sidebar-header {
    background-color: #0d6efd; /* bg-primary do Bootstrap */
    color: white;
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.btn-close-sidebar {
    background: transparent;
    border: none;
    color: white;
    font-size: 1.5rem;
}

/* Conteúdo/Links da Sidebar */
.sidebar-body {
    padding: 1rem 0;
    flex-grow: 1;
}

.sidebar-link {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    color: #333;
    text-decoration: none;
    transition: background 0.2s, color 0.2s;
    border-left: 4px solid transparent;
}

.sidebar-link i {
    margin-right: 12px;
    font-size: 1.1rem;
    width: 24px;
    text-align: center;
}

.sidebar-link:hover {
    background-color: #f8f9fa;
    color: #0d6efd;
    border-left-color: #0d6efd;
}

/* Rodapé da Sidebar (Opcional) */
.sidebar-footer {
    padding: 1rem;
    border-top: 1px solid #eee;
    background-color: #f8f9fa;
    text-align: center;
    font-size: 0.85rem;
    color: #6c757d;
}

/* Overlay (Fundo Escuro) */
.sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1999; /* Logo abaixo da sidebar */
    display: none; /* Escondido por padrão */
    opacity: 0;
    transition: opacity 0.3s ease;
}

.sidebar-overlay.active {
    display: block;
    opacity: 1;
}

/* Destaque para o link da página atual no menu */
.sidebar-link.active-link {
    background-color: #e8f0fe; /* Fundo azul claro */
    color: #0d6efd; /* Texto azul primário */
    border-left: 4px solid #0d6efd; /* Borda esquerda azul */
    font-weight: 600;
}