﻿.page {
    position: relative;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    height: calc(100vh - 40px);
    background: #eee;
}

main {
    flex: 1;
    overflow-y: auto;
}

.sidebar {
    background: var(--jmBlue);
    background: linear-gradient(225deg, var(--jmPrimary) 0%, var(--jmPrimaryDark) 100%);
    box-shadow: 0px 0px 5px 1px var(--black-25);    
}


@media (min-width: 641px) {
    .page {
        flex-direction: row;
    }

    .sidebar {
        width: 80px;
        height: calc(100vh - 40px);
        position: sticky;
        top: 0;
    }
}

.jmBrandContainer {
    background-color: white;
    height: 80px;
    width: 100%;
    padding: 10px;
}

.jmNavBrand {       

}

.jmNavBrandLogoImage {
    width: 60px;
}

@media (min-width: 641px) {
    .jmNavBrand {
        width: 100%;
    }
}

.jmNavLogoImage {
    width: 100%;
    height: 3rem;
    object-fit: contain;
}

.navbar-toggler {
    appearance: none;
    cursor: pointer;
    width: 3.5rem;
    height: 3.5rem;
    color: white;
    position: absolute;
    top: 0.5rem;
    right: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.55%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") no-repeat center/1.75rem rgba(255, 255, 255, 0.1);
}

    .navbar-toggler:checked {
        background-color: rgba(255, 255, 255, 0.5);
    }

.top-row {
    min-height: 3.5rem;
    background-color: rgba(0,0,0,0.4);
}


/* Nav Items */

.nav-item {
    font-size: 0.9rem;
    padding-bottom: 0.5rem;
    transition: 0.5s;
}

.nav-item:first-of-type {
    padding-top: 1rem;
}

.nav-item:last-of-type {
    padding-bottom: 1rem;
}


.nav-item a.active  {
    background-color: rgba(0,0,0,0.5);
    color: white;
}


.nav-link {    
    font-size: 10px;
    font-weight: 300;
    height: 90px;
    width: 60px;
    display: flex;
    margin-left: 10px;
    margin-right: 10px;   
    margin-bottom:10px;
    align-items: center; 
    padding: 0;
    position: relative;
}

.jmNavItemIcon {
    color: var(--white-75);
    background: var(--white-25);
    width: 60px;
    height: 60px;
    position: absolute;
    border-radius: 10px;
    top: 0;
    transition: 0.5s;
    text-align: center;
    font-size: 30px;
    line-height: 60px;
}

.jmNavItemIcon:hover {
    color: var(--jmPrimary);
    background: white;
    transition: 0.2s;
    box-shadow: 0px 0px 5px 5px var(--black-25);
}

.jmNavItemText {
    color: white;
    position: absolute;
    top: 70px;
    text-align: center;
    width: 60px;
    height:20px;
    line-height:15px;
}


.jmNavBottom {
    bottom: 0;
    position: absolute;
    width: 100%;
}

.nav-scrollable {
    display: none;
}

.navbar-toggler:checked ~ .nav-scrollable {
    display: block;
}

@media (min-width: 641px) {
    .navbar-toggler {
        display: none;
    }

    .nav-scrollable {
        /* Never collapse the sidebar for wide screens */
        display: block;
        /* Allow sidebar to scroll for tall menus */
        height: calc(100vh - 3.5rem);
        overflow-y: auto;
    }
}
/* Notification badge on nav bell icon */
.jmNotifBadge {
    position: absolute;
    top: 0px;
    left: -5px;
    background: #dc3545;
    color: #fff;
    font-size: 0.6rem;
    font-weight: 700;
    min-width: 16px;
    height: 16px;
    line-height: 16px;
    text-align: center;
    border-radius: 50%;
    padding: 0 4px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

/* ====== SubMenu ====== */

.submenu {
    width: 0;
    min-width: 0;
    height: calc(100vh - 40px);
    position: sticky;
    top: 0;
    background: #fff;
    overflow-x: hidden;
    overflow-y: auto;
    transition: width 0.3s ease, min-width 0.3s ease;
    white-space: nowrap;
    box-shadow: 5px 0px 5px -5px var(--black-25);  
}

.submenu-open .submenu {
    width: 210px;
    min-width: 210px;
}

.submenu-title {
    padding: 20px 15px 20px 15px;
    margin: 0;
    font-size: 18px;
    font-weight: 700;   
    letter-spacing: 0.5px;
    color: black;
}

.submenu-link {
    display: block;
    padding: 10px 15px;
    font-size: 16px;
    color: black;
    text-decoration: none;
    transition: background 0.2s, color 0.2s;
    border-radius: 5px;
    margin: 5px 10px;
}

.submenu-link:hover {
    background: var(--jmPrimary);
    color: white;
    transition: 0.2s;
}

.submenu-link.active {
    background: var(--jmPrimary);
    color: white;
}

.submenu-separator {
    margin: 4px 12px;
    border: 0;
    border-top: 1px solid var(--black-25);
}

#structureToggle .jmNavItemIcon {
    transition: 0.5s;
}

.submenu-open #structureToggle .jmNavItemIcon {
    color: var(--jmPrimary);
    background: white;
}


