/*------------------------------------------------------------------
[6 - Layout]
*/
.dashboard {
    &-sidebar {
        @media (min-width: $breakpoint-x-large) {
            border-right: 1px solid var(--color-4);
            bottom: 0;
            margin-top: 0;
            position: fixed;
            top: 0;
            left: 0;

            &:not(.sm) {
                width: 260px;
            }
        }

        > div.nav[data-overlayscrollbars="host"] {
            height: calc(100vh - calc(4.5rem + 1px));
        }

        #side-menu {
            border: none;
            max-width: 80%;
        }

        .submenu {
            padding-left: 2rem;

            > div {
                margin: .125rem 0;
            }

            &.dropdown-menu {
                border-color: rgba(var(--color-4-rgb),.5);
                padding: 0;

                div {
                    margin: .25rem;

                    &:hover > a {
                        color: var(--color-1);

                    }
                }
            }
        }

        .sidebar-t {
            display: flex;
            width: 100%;
        }

        .sidebar-badge {
            color: white;
            background: var(--color-1);
            border-radius: .25rem;
            font-size: .75rem;
            min-width: 1.125rem;
            text-align: center;
        }

        .nav-item {
            width: 100%;
            padding: .75rem .75rem 0 .75rem;
        }

        .nav-link {
            display: flex;
            align-items: center;
            padding: .5rem;
            width: 100%;
            color: var(--color-3);
            font-size: 1.125rem;
            border-radius: .75rem;
            @include transition(all .3s ease);

            &.active {
                background: var(--color-4);
                color: var(--color-1);

                > .sidebar-i,
                > .sidebar-t {
                    color: var(--color-1);
                }
            }

            &:not(.active):hover {
                background: rgba(var(--color-4-rgb),.5);
            }
        }

        &.sm {
            width: 4.25rem;
            position: absolute;
            box-shadow: none;
            z-index: 1001;

            .sidebar-logo {
                padding: 0;

                > img {
                    display: none;
                }
            }

            .action-button,
            .sidebar-i {
                margin: auto;
            }

            .sidebar-t,
            .dropdown-toggle::after {
                display: none;
            }
        }

        .notification-icon {
            font-size: .875rem;
            margin: auto 0 auto .25rem;
            font-weight: 500;
            background: var(--color-1);
            padding: 0 .25rem;
            border-radius: .25rem;
            color: white;
        }
    }

    &-content {
        width: 100%;
        min-height: 100vh;
        background-color: var(--color-4);

        @media (min-width: $breakpoint-x-large) {
           &:not(.lg) {
                margin-left: 260px;
            }

            &.lg {
                margin-left: 4.25rem;
            }
        }

        > .content {
            padding: 2rem;
        }
    }
}

.animate {
    @include transition(all .2s ease);
}

.sidebar-logo {
    padding: 0 1.5rem;
    height: calc(4.5rem + 1px);
    border-bottom: 1px solid var(--color-4);

    > img {
        max-height: 1.875rem;
        margin: auto auto auto 0;
    }
}

.topbar {
    background: white;
    padding: 1rem 2rem;
    border-bottom: 1px solid var(--color-4);

    .page-name {
        > p {
            color: var(--color-2);
            font-size: 1.25rem;
            margin: auto 0;
        }
    }
}

.avatar {
    border-radius: 50%;
    width: 2.5rem;
    height: 2.5rem;
    outline: 1px solid var(--color-4);
}

.pagination {
    .page-item {
        .page-link {
            color: var(--color-3);
            background: white;
            font-weight: 600;
            padding: .75rem 1.25rem;
            border: 1px solid #f1f1f1;
            border-right: none;
            outline: none;
            margin-left: 0;

            &.disabled {
                color: var(--color-3);
                background: white;
            }

            &:focus {
                box-shadow: none;
            }

            &:hover {
                background-color: #f7f7f7;
                outline: none;
            }
        }

        &:first-child .page-link {
            border-bottom-left-radius: 1rem;
            border-top-left-radius: 1rem;
        }

        &:last-child .page-link {
            border-bottom-right-radius: 1rem;
            border-top-right-radius: 1rem;
            border-right: 1px solid #f1f1f1;

            &:focus {
                margin-right: 0;
            }
        }

        &.active {
            > .page-link {
                color: var(--color-1) !important;
            }
        }
    }
}
