html,
body {
    overflow: hidden;
    font-family: 'Signika', sans-serif;
    font-weight: 300;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
}

#renderCanvas {
    width: 100%;
    height: 100%;
    touch-action: none;
}

h1,
h2,
h3,
h4 {
    letter-spacing: 1px;
}

button {
    background: none;
    transition: .3s;
    cursor: pointer;
    outline: none;
    border: none;
}

header {
    flex-direction: column;
    height: 100%;
    position: absolute;
    display: flex;
    justify-content: space-between;
    gap: 2em;
    -webkit-box-sizing: border-box;
    /* Safari/Chrome, other WebKit */
    -moz-box-sizing: border-box;
    /* Firefox, other Gecko */
    box-sizing: border-box;
    /* Opera/IE 8+ */
    padding: 1em 2em;
    transform: none;
    transition: .3s;
}

header.flexend {
    justify-content: end;
}

.logo {
    overflow-y: visible;
    position: absolute;
    right: 2em;
    border-radius: 0 0 25px 25px;
    padding: 1em 2em;
    background: rgba(17, 17, 17, 0.85);
    backdrop-filter: blur(25px);
    z-index: 10;
}

.logo h1 {
    /* position: absolute; */
    pointer-events: none;
    font-size: 3em;
    color: white;
    line-height: 0.5em;
    transition: .3s;
    text-shadow: 0 0 6px rgba(0, 0, 0, 0.4);
}

.logo:hover h1,
button:hover {
    color: rgb(98, 224, 255) !important;
}

.socials {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    width: 216px;
    justify-items: center;
    align-items: center;
    gap: 1em 1.25em;
    background: rgba(17, 17, 17, 0.85);
    backdrop-filter: blur(20px);
    padding: 1.2em;
    border-radius: 25px 25px 0 0;
}

.bar {
    width: 100%;
    position: absolute;
    height: 1em;
    background: rgba(17, 17, 17, 0.85);
    backdrop-filter: blur(20px);
}

.bar.bottom {
    bottom: 0;
}

.bar.top {
    top: 0;
}

.socials a {
    font-size: 2em;
    height: 32px;
    width: 32px;
    line-height: 0;
    background: rgb(39, 39, 39);
    box-shadow: 0px 0px 4px #222;
    color: #FFF;
    padding: 8px;
    border-radius: 50%;
    transition: .25s;
}

.socials a:hover {
    background-color: rgb(29, 29, 29);
}

a:hover .las,
a:hover .lab {
    color: rgb(98, 224, 255);
}

.menuitems,
.help {
    display: flex;
    flex-direction: column;
    gap: 1em;
    transition: .25s;
    margin-bottom: .5em;
    background: rgba(17, 17, 17, 0.85);
    backdrop-filter: blur(20px);
    padding: 2em 1.5em 1em;
    border-radius: 40px;
    color: #fff;
}

.menuitems {
    border-radius: 0 0 25px 25px;
}

.help {
    padding: 1em;
    box-shadow: 0 0 8px #222;
    margin-bottom: 12em;
    flex-direction: row;
    gap: 0em;
    height: auto;
}


.help>p {
    height: auto;
    margin: 0;
    display: flex;
    align-items: center;
    padding: 1em
}

.help h1 {
    width: 100%;

}

.menuitems button {
    width: 100%;
    font-size: 1.7em;
    text-align: start;
    color: #FFF;
    transition: .25s;
    -webkit-box-sizing: border-box;
    /* Safari/Chrome, other WebKit */
    -moz-box-sizing: border-box;
    /* Firefox, other Gecko */
    box-sizing: border-box;
    padding-bottom: .5em;
    text-decoration: none;
}

.menuitems.collapsed {
    transform: translateY(100%);
    opacity: 0;
    height: 0;
}

.menuitems button i {
    margin-right: 1em;
}

.minimap {
    border-radius: 25px 25px 0 0;
    overflow: hidden;
    transform-origin: bottom right;
    line-height: 0;
}

.minimapcontainer {
    position: absolute;
    right: 0;
    bottom: 0;
    margin: 1em 2em;
    background: rgba(17, 17, 17, 0.85);
    backdrop-filter: blur(20px);
    border-radius: 25px 25px 0 0;
    overflow: hidden;
    transition: .3s;
    transform: none;
}

body.pageopened .content>header {
    transform: translateX(-100vw);
}

body.pageopened .content>.minimapcontainer {
    transform: translateX(100vw)
}

.minimap img {
    width: 252px;
    opacity: 0.9;
    z-index: 5;
}

.minimap span {
    position: absolute;
    z-index: 10;
    color: white;
    font-size: 1.3em;
}

.minimap-projects {
    transform: translate(45px, 126px);
}

.minimap-about {
    transform: translate(190px, 65px);
}

.minimap-story {
    transform: translate(225px, 155px);
}

.minimap-store {
    transform: translate(70px, 53px);
}

#minimapplayer {
    padding: 4px;
    background-color: #fff;
    border-radius: 50%;
    left: 16px;
    top: 12px;
}

a,
a:visited {
    text-decoration: none;
    color: #fff;
}

button:hover {
    color: rgb(207, 207, 207);
}

#loadingScreen {
    position: absolute;
    width: 100%;
    height: 100%;
    z-index: 1000;
    background: linear-gradient(to top, rgb(22, 22, 22) 50%, rgba(1, 1, 1, 0) 50%);
    background-size: 100% 300%;
    background-position: bottom;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    gap: 2em;
    font-weight: 600;
    transition: .8s;
    font-size: 1.5em;
    color: #555;
}

#loadingScreen * {
    transition: .8s
}

#loadingScreen.hidden {
    background-position: top;
    pointer-events: none;
}

#loadingScreen.hidden img,
#loadingScreen.hidden p {
    transform: translateY(-100vh)
}

.contentfull {
    position: absolute;
    display: flex;
    justify-content: center;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    backdrop-filter: blur(15px);
    padding: 6em 2em 2em;
    box-sizing: border-box;
}

.contentcontainer {
    background: rgba(17, 17, 17, 0.85);
    min-height: calc(100%-8em);
    height: 100%;
    padding: 32px 64px 64px;
    color: white;
    border-radius: 45px;
    box-sizing: border-box;
    box-shadow: 0 0 8px #111;
    max-width: 1680px;
    overflow-y: scroll;
}

.contentcontainer button,
.contentcontainer a,
.popupcontainer button,
.popupcontainer a,
.help button {
    background-color: #333;
    color: white;
    padding: 1em 2em;
    border-radius: 25px;
    font-weight: 600;
    border: solid 2px #333;
}

.contentcontainer button:hover,
.contentcontainer a:hover,
.popupcontainer button:hover,
.popupcontainer a:hover,
.help button:hover {
    border: solid 2px rgb(25, 104, 124);
    background-color: rgb(39, 39, 39);
}

.contentcontainer a {
    padding: 0.5em 2em;
    line-height: 5em;
}

.contentcontainer button.active {
    border: solid 2px #fff;
    background: #444;
}

.projectsheader {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1em;
}

.projectsheader h1,
.projectsheader button {
    margin: 16px 0;
}

button * {
    pointer-events: none;
}

.contentcontainer nav {
    display: flex;
    margin: 1.5em 0;
    gap: 1.5em;
    justify-content: flex-start;
}

::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: rgba(17, 17, 17, 0.85);
    border-radius: 5px;
    overflow: hidden;
}

::-webkit-scrollbar-thumb {
    background: #555;
    border-radius: 10px;
}

.grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3em;
    width: 100%;
}

.projectsitem {
    background: rgba(0, 0, 0, 0.6);
    width: auto;
    height: auto;
    border-radius: 25px;
    overflow: hidden;
    color: #fff;
    box-shadow: 0 0 8px #111;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.projectsitem * {
    margin: 8px 16px;
}

.projectsitem button {
    margin: 1em 16px;
    margin-top: auto;
}

.projectsitem img,
img.projectsitem {
    object-fit: cover;
    margin: 0;
    width: 100%;
    max-height: 100%;
}

.projectdescription {
    font-size: 18px;
    font-weight: 300;
}

.projectdescription .grid {
    margin-bottom: 2em;
}

.popupcontainer {
    display: flex;
    justify-content: center;
    align-items: center;
    position: absolute;
    z-index: 100;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

@keyframes popupani {
    0% {
        transform: scale(0) translateY(8em);
    }

    100% {
        transform: none;
    }
}

.popupcontainer>div {
    transform-origin: bottom center;
    display: flex;
    pointer-events: all;
    justify-content: center;
    flex-direction: column;
    width: 16em;
    padding: 2em;
    margin-bottom: 20em;
    background: rgba(17, 17, 17, 0.85);
    backdrop-filter: blur(20px);
    border-radius: 25px;
    overflow: hidden;
    color: #fff;
    box-shadow: 0 0 8px #111;
    animation: popupani 0.1s ease-in-out;
    transition: 0.1s;
}

.popupcontainer div.help {
    margin-bottom: 12em !important;
    flex-direction: row !important;
    width: auto !important;
}

.popupcontainer.closepopup div {
    transform: scale(0) translateY(8em) !important;
}

.popupcontainer h1 {
    margin: 0;
}

.about {
    display: grid;
    grid-template-columns: 2fr;
    width: 100%;
    font-size: 20px;
    gap: 2em;
    justify-items: center;
}

.about img {
    max-height: 256px;
    width: auto;
    border-radius: 25px;
}

.overig {
    display: flex;
    gap: 2em;
    flex-wrap: wrap;
    justify-content: center;
}

.overig div {
    position: relative;
    background: #222;
    flex-grow: 1;
    max-width: 30em;
    border-radius: 25px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.overig div div {
    position: relative;
    margin: 1em 2em;
    display: flex;
    flex-direction: column;
    flex-wrap: wrap;
    height: 100%;
    box-sizing: border-box;
}

.overig div div a {
    padding: 0 1em;
    margin-bottom: 1em;
    line-height: 3em;
    box-sizing: border-box;
    width: 100%;
}

.overig div div * {
    width: 100%;
}

.overig div div span {
    margin-top: auto !important;
    display: block !important;
    height: auto;
    border-bottom: #333 solid 2px;
    margin: 1.5em 0;
    flex-grow: 5;
}

.overig div img {
    width: 100%;
    box-shadow: 0 0 8px #111;
}

.kb-buttons div {
    display: flex;
    justify-content: center;
    padding: 0;
}

.kb-buttons div p {
    background: rgb(54, 54, 54);
    font-size: 10px;
    padding: 1em;
    border-radius: 15px;
    margin: 0.2em;
}

@media only screen and (max-width: 768px){
    .logo {
        position: absolute;
        width: min-content;
        padding: 0 1em .5em;
        right: 0;
        top: 1em;
        left: 16em;
        margin: auto;
        display: flex;
        justify-content: center;
        /* border-radius: 0; */
    }
    header {
        padding: 1em 0em 1em;
        margin: 1em 0;
        height: calc(100% - 2em);
        width: 16em;
        background: rgba(17, 17, 17, 0.85);
        backdrop-filter: blur(20px);
    }
    .logo h1{
        line-height: 0em;
    }
    .menuitems, .socials {
        background: none;
        backdrop-filter: none;
    }
    .socials a {
        background: rgba(0, 0, 0, 0.4);
        box-shadow: none;
    }
    .grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .about img{
        max-width: calc(100% -2em);
        width: 100%;
    }
}

@media only screen and (max-width: 596px){
    .bar.bottom {
        display: none;
    }
    .bar.top {
        z-index: 100;
    }
    .logo {
        left: 0;
    }
    header {
        width: 100%;
        height: 100%;
        bottom: 0;
        margin: 0;
        padding: 0;
        gap: 0;
        background: rgba(0, 0, 0, 0.6);
        backdrop-filter: blur(1px);
        align-items: center;
    }
    header div {
        box-sizing: border-box;
    }
    .socials{
        padding: 2em 0;
    }
    .socials a {
        background: rgba(0, 0, 0, 0.6);
        box-shadow: none;
    }
    .menuitems {
        margin-top: 8em;
    }
    .menuitems button {
        background: rgba(0, 0, 0, 0.6);
        padding: .5em 1em;
        border-radius: 25px;
    }
    .grid {
        display: flex;
        flex-direction: column;
    }
    .contentfull {
        padding: 0;
        backdrop-filter: blur(2px);
    }
    .contentcontainer {
        border-radius: 0;
        padding: 1em;
    }
    body.pageopened .logo {
        display: none;
    }
    body.pageopened .bar {
        display: none;
    }
}

@media only screen and (max-width: 320px){
    .logo h1 {
        font-size: 26px;
    }
    .loadingimg{ 
        width: 100%;
        margin: 0 1em;
    }
}