﻿:root {
    --header-height: 80px;
    --sidebar-width: 285px;
    --sidebar-collapsed: 0px;
}

html {
    scrollbar-width: thin;
    scrollbar-color: #112933 #e5e5e5;
}

html::-webkit-scrollbar {
    width: 12px;
}

html::-webkit-scrollbar-track {
    background: #e5e5e5;
}

html::-webkit-scrollbar-thumb {
    background-color: #112933;
    border-radius: 8px;
}

.main-header {
    height: var(--header-height);
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1100;
}

    .main-header .btnMenu {
        display: none;
    }

    .main-header .txt-usuario {
        font-size: 16px;
        margin-right: 50px;
    }

.layout-wrapper {
    display: flex;
    margin-top: var(--header-height);
}

.sidebar {
    width: var(--sidebar-width);
    min-height: calc(100vh - var(--header-height));
    height: auto;
    background-color: #0085d3;
    transition: width 0.3s ease, transform 0.3s ease;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

    .sidebar.collapsed {
        width: var(--sidebar-collapsed);
    }

.sidebar-top {
    flex: 1;
    overflow-y: auto;
}

.menu-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 12px;
    border-radius: 8px;
    color: white;
    text-decoration: none;
    margin-top: 8px;
    transition: background 0.2s;
}

    .menu-item:hover {
        background-color: white;
        color: #0085d3;
    }

.content {
    flex: 1;
    transition: margin-left 0.3s ease;
}

.sidebar-footer {
    padding: 20px;
}

.btnSair {
    width: 100%;
    background-color: white;
    color: #0085d3;
    border-color: white;
}

    .btnSair:hover {
        background-color: #0085d3;
        color: white;
        border-color: white;
    }

@media (max-width: 768px) {
    .main-header .btnMenu{
        display: block;
        margin-right: 10px;
    }

    .main-header .txt-usuario {
        font-size: 14px;
        margin-right: 0;
    }

    .sidebar {
        position: fixed;
        left: 0;
        top: var(--header-height);
        transform: translateX(-100%);
        z-index: 1200;
    }

        .sidebar.show {
            transform: translateX(0);
        }

    .overlay {
        display: none;
        position: fixed;
        inset: 0;
        background: rgba(0,0,0,0.4);
        z-index: 1150;
    }

        body.sidebar-open .overlay{
            display: block;
        }
}
