* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    --topbarHeight: 50px;
    --sidebarMinHeight: calc(100vh - var(--topbarHeight));
    --sidebarIconWidth: 65px;
    --sidebarFullMinWidth: 250px;
    --textPaddingRight: 10px;
    --childrenMargin: 15px;

    --menuColor: #fff;
    --contentColor: #f2f4f7;

    --textColorLight: #575454;
    --textColorDark: #000;
}

body {
    display: flex;
    flex-wrap: wrap;
    width: 100%;
    min-height: 100vh;
    font-family: Roboto, sans-serif;
}

.topbar {
    flex-basis: 100%;
    flex-shrink: 0;
    height: calc(var(--topbarHeight)-5);
    background: var(--menuColor);
    box-shadow: 0 2px 15px 0 rgba(0,0,0,.05);
    z-index: 3;
}

.sidebar {
    flex-basis: var(--sidebarIconWidth);
    flex-grow: 0;
    height: var(--sidebarMinHeight);
    overflow-x: hidden;
    overflow-y: auto;
    background: var(--menuColor);
    transition: flex-basis .3s;
    padding-top: 10px;
    box-shadow: 0 1px 30px 1px rgba(0,0,0,.11);
    z-index: 2;

}
.sidebar.sidebar--full {
    flex-basis: var(--sidebarFullMinWidth);
    transition: flex-basis .3s;
}

ul.sidebar__list {
    width: 100%;
}

ul.sidebar__list > li {
    width: 100%;
}

.sidebar li {
    min-height: 35px;
    padding: 0;
}
.sidebar__icontext {
    min-width: var(--sidebarFullMinWidth);
    cursor: pointer;
    color: var(--textColorDark));
}

.list-prim li {
    padding: 5px;
}

.sidebar__icontext > div:first-child {
    width: var(--sidebarIconWidth);
    text-align: center;
}

.sidebar__icontext > div:nth-child(2) {
    padding-right: var(--textPaddingRight);
    width: 150px;
}
.sidebar:not(.sidebar--full) .sidebar__icontext > div:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.sidebar .sidebar__list > li:hover .sidebar__icontext > div:nth-child(2) {
    position: absolute;
    left: var(--sidebarIconWidth);
    /*background-color: #ffffffdb;*/
    background-color: inherit;
    padding-left: 5px;

    transition: opacity .3s, transform .3s;
    transform-origin: center left;
    opacity: 1;
    transform: scaleX(1);
}

.sidebar.sidebar--full .sidebar__list > li:hover .sidebar__icontext > div:nth-child(2) {
    position: initial;
    left: 0;
    padding-left: 0;
}


.sidebar__icontext > * {
    display: inline-block;
}

li.sidebar__group {
    width: 100%;
}

li.sidebar__group .sidebar__icontext {
    font-weight: bold;
}
.sidebar__icontext > * {
    padding: 5px 0;
}
.sidebar .sidebar__list li.sidebar__group a {
    font-weight: normal;
}

li.sidebar__group > ul {
    max-height: 0;
    overflow: hidden;
}

li.sidebar__group.sidebar__group--full > ul {
    max-height: initial;
}

li.sidebar__group li {
    margin-left: calc(var(--sidebarIconWidth) + var(--childrenMargin));
    cursor: pointer;
    padding: 5px;
}

li.sidebar__link {
    width: 100%;
}

.sidebar a, .sidebar a:active {
    text-decoration: none;
    display: block;
}
 
.sidebar a:link,
.sidebar a:visited,
.sidebar a:hover,.sidebar a:active {
    color: initial;
}

.sidebar ul {
    list-style: none;
}

.sidebar__toggle {
    cursor: pointer;
    height: 100%;
    width: var(--sidebarIconWidth);
    line-height: var(--topbarHeight);
    text-align: center;
    font-size: 16px;
    float: left;
}

.content {
    flex-grow: 1;
    flex: 100;
    height: var(--sidebarMinHeight);
    padding: 20px;
    overflow-x: hidden;
    overflow-y: auto;
    background: var(--contentColor);
    /*z-index: 1;*/
}

.sidebar .list-prim {
    position: absolute;
    left: var(--sidebarIconWidth);
    margin-left: 0;
    /*background-color: #ffffff99;*/
    background-color: #ffffff;
    width: 150px;
    padding: 0;
    transition: opacity .3s, transform .3s;
    transition-delay: 0s, .3s;
    transform-origin: center top;
}

.sidebar .list-prim:hover,
.sidebar .sidebar__group:hover .list-prim
 {
    opacity: 1;
    transform: scaleY(1);
}

.list-prim,
.sidebar.sidebar.sidebar--full .sidebar__group:hover .list-prim {
    opacity: 0;
    transform: scaleY(0);
}

.list-prim > * {
    cursor: pointer;
}

.sidebar__group .list-prim > li {
    margin-left: 0;
}

.sidebar .sidebar__list > li, 
.sidebar .sidebar__list .sidebar__link > a, 
.sidebar .sidebar__list .sidebar__group > div{
    background-color: #ffffff;
}
.sidebar__link:hover, 
.sidebar__group--full ul li:hover, 
.list-prim li:hover, 
.sidebar .sidebar__list .sidebar__link > a:hover, 
.sidebar .sidebar__list .sidebar__group > div:hover,
.sidebar__link:focus, 
.sidebar__group--full ul li:focus, 
.list-prim li:focus, 
.sidebar .sidebar__list .sidebar__link > a:focus, 
.sidebar .sidebar__list .sidebar__group > div:focus{
    background-color: #d8d8d8;
}

.sidebar__space-bottom {
    margin-bottom: 1rem;
}

@media (max-width: 320px) {
    .sidebar.sidebar--full {
        flex-basis: 100%;
    }
}
@media (max-width: 576px) {
    .sidebar {
        flex-basis: 1px;
    }
}


/* test */
.section-test {
    width: 150px;
    height: 150px;
    border-radius: 3px;
    display: inline-block;
    margin: 7px;
    padding: 10px;
    background: var(--menuColor);
    box-shadow: 0 1px 30px 1px rgba(0,0,0,.11);
    transform-origin: center;
    transition: transform .1s ease;
    cursor: pointer;
}

.section-test.black {
    background: black;
    color: white;
}
.section-test.bad {
    color: red !important;
}

.section-test:hover {
    transform: scale(1.05);
}

.results {
    position: absolute;
    top: 0;
    right: 0;
    height: var(--topbarHeight);
    padding: 0 10px;
    line-height: var(--topbarHeight);
    z-index: 10;
}

.results > span {
    margin: 10px;
}

.results > span.points {
    color: green;
}

.results > span.errors {
    color: red;
}

.results > span.time {
    font-weight: bold;
}

.notifier {
    position: absolute;
    top: 0;
    left: 0;
    width: 50%;
    margin-left: 25%;
    text-align: center;
    height: var(--topbarHeight);
    line-height: var(--topbarHeight);
    z-index: 9;
    opacity: 1;
    transition: opacity .3s ease; 
}
.notifier.success {
    color: green;
}
.notifier.error {
    color: red;
}
.notifier.hide {
    opacity: 0;
}

.how-many-blacks {
    position: absolute;
    top: 0;
    left: 75px;
    width: 50%;
    height: var(--topbarHeight);
    line-height: var(--topbarHeight);
    z-index: 9;
    font-weight: bold;
    font-family: 'Lucida Sans', 'Lucida Sans Regular', 'Lucida Grande', 'Lucida Sans Unicode', Geneva, Verdana, sans-serif;
    animation: pulse .3s ease;
    transform-origin: center;
}

@keyframes pulse {
    0% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
    }
}