#nav {
    position: fixed;
    right: 1.6em;
    bottom: 1.6em;
    display: flex;
    flex-direction: column-reverse;
    transition: flex-grow 1000ms linear;
    height: 50vh;
    justify-content: flex-start;
    align-items: center;
    
    z-index: 30;
}

#nav>div {
    height: 0;
    width: 0;
    margin: 0;
    padding: 0;
    font-size: 0;

    background: var(--hl-text);
    border-radius: 50%;
    cursor: pointer;

    visibility: hidden;
    transition: all 0.6s;
    transform: scale(0);
    transform-style: preserve-3d;
}

#nav>div:hover {
    color: var(--text-hover);
    box-shadow: rgba(50, 50, 93, 0.25) 0px 30px 60px -12px, rgba(0, 0, 0, 0.3) 0px 18px 36px -18px;
}

#nav>.show {
    height: 1.4em;
    width: 1.4em;
    margin: 0.2em;
    padding: 0.6em;
    font-size: 1.2rem;

    visibility: visible;
    transform: scale(1);
}

#nav>div>.front {
    position: absolute;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

#nav>div>.behind {
    position: absolute;
    transform: rotateY(180deg);
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

@media screen and (max-width: 650px) {
    #nav {
        height: 2.4em;

        bottom: 0;
        right: 0;
        left: 0;

        flex-direction: row;
        justify-content: center;
        font-size: 1.1em;

        background: var(--sub-bg);
        min-width: 360px;
    }

    #nav>.show {
        margin: 0 .6em;
    }
}

@media screen and (max-width: 300px) {
    #nav>.show {
        margin: 0 .2em;
    }
}

@media screen and (max-width: 650px) {
    #nav{
        box-shadow: rgba(0, 0, 0, 0.4) 0px 30px 90px;
    }
}