/* ========== MENU HAMBÚRGUER UNIFICADO ========== */
/* Hamburger Button */
.hamburger-btn {
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 200;
    width: 44px;
    height: 44px;
    background: rgba(21, 21, 26, 0.85);
    backdrop-filter: blur(16px);
    border: 1px solid var(--border, #2a2a38);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.hamburger-btn:hover {
    border-color: var(--accent, #7c6dfa);
    box-shadow: 0 0 20px rgba(124, 109, 250, 0.2);
    transform: scale(1.02);
}

.hamburger-line {
    width: 20px;
    height: 2px;
    background: var(--text, #e8e8f0);
    border-radius: 2px;
    transition: all 0.3s ease;
    transform-origin: center;
}

/* Estado Aberto do Botão */
.hamburger-btn.open .hamburger-line:nth-child(1),
.hamburger-btn.active .hamburger-line:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.hamburger-btn.open .hamburger-line:nth-child(2),
.hamburger-btn.active .hamburger-line:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.hamburger-btn.open .hamburger-line:nth-child(3),
.hamburger-btn.active .hamburger-line:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* Sidebar Overlay */
.sidebar-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 250;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.sidebar-overlay.show,
.sidebar-overlay.active {
    opacity: 1;
    pointer-events: all;
}

/* Sidebar */
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 280px;
    height: 100vh;
    background: rgba(21, 21, 26, 0.95);
    backdrop-filter: blur(20px);
    border-right: 1px solid var(--border, #2a2a38);
    z-index: 260;
    transform: translateX(-100%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    box-shadow: 5px 0 30px rgba(0, 0, 0, 0.5);
}

.sidebar.open,
.sidebar.active {
    transform: translateX(0);
}

/* Sidebar Header */
.sidebar-header {
    padding: 24px 20px;
    border-bottom: 1px solid var(--border, #2a2a38);
    display: flex;
    align-items: center;
    gap: 12px;
    position: relative;
}

.sidebar-logo {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, #7c6dfa, #6dfabc);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 18px;
    color: #fff;
}

.sidebar-title {
    font-family: 'Syne', sans-serif;
    font-weight: 700;
    font-size: 16px;
    color: var(--text, #e8e8f0);
    flex: 1;
}

/* Botão Fechar (X) */
.sidebar-close {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border, #2a2a38);
    color: var(--muted, #7878a0);
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.sidebar-close:hover {
    background: rgba(124, 109, 250, 0.2);
    color: var(--text, #e8e8f0);
    border-color: var(--accent, #7c6dfa);
}

/* Navegação */
.sidebar-nav {
    flex: 1;
    padding: 16px 12px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    overflow-y: auto;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: 10px;
    color: var(--muted, #7878a0);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s;
    cursor: pointer;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
}

.sidebar-link:hover {
    background: rgba(124, 109, 250, 0.1);
    color: var(--text, #e8e8f0);
}

.sidebar-link.active,
.sidebar-link.active-link {
    background: rgba(124, 109, 250, 0.15);
    border: 1px solid rgba(124, 109, 250, 0.3);
    color: #fff;
}

.sidebar-link .icon {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
    transition: all 0.2s;
}

/* Link Content */
.link-content {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.link-title {
    font-weight: 600;
    font-size: 14px;
}

.link-subtitle {
    font-size: 10px;
    opacity: 0.6;
}

/* Sidebar Footer */
.sidebar-footer {
    padding: 16px 20px;
    border-top: 1px solid var(--border, #2a2a38);
    font-size: 11px;
    color: var(--muted, #7878a0);
    text-align: center;
    font-family: 'Space Mono', monospace;
}

.footer-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

/* Estado do Body quando menu aberto */
body.sidebar-is-open {
    overflow: hidden;
}

/* Responsividade */
@media (max-width: 600px) {
    .hamburger-btn {
        top: 12px;
        left: 12px;
        width: 38px;
        height: 38px;
    }
    
    .sidebar {
        width: 260px;
    }
    
    .sidebar-header {
        padding: 18px 16px;
    }
    
    .sidebar-link {
        padding: 10px 12px;
    }
    
    .link-subtitle {
        display: none; /* Esconde subtítulo em mobile para economizar espaço */
    }
}

/* Animações extras */
@keyframes slideIn {
    from {
        transform: translateX(-100%);
    }
    to {
        transform: translateX(0);
    }
}

.sidebar.open,
.sidebar.active {
    animation: slideIn 0.35s ease-out;
}
