header {
    text-align: center;
    width: 100%;
    height: 100vh;
    overflow: hidden;
}

header .container {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

#nav {
    position: fixed;
    width: 100%;
    height: 110px;
    z-index: 3;
    transition: height 0.3s, 0.5s background ease;
}

#nav.active {
    height: 80px;
    background-color: var(--color-primary);
    box-shadow: 0px 2px 3px -1px rgba(30,30,30,0.1);
}

.navlink.active {
    color: var(--navlink-color);
}

.navlink.active:hover {
    color: var(--navlink-color);
}

nav img {
    width: 90px;
}

.navlink {
    text-decoration: none;
    padding: 15px;
    color: #FFF;
    font-size: 0.9em;
    transition: 0.5s ease;
}

.navlink:hover {
    text-decoration: none;
    color: #DBDBDB;
}

.navlink:before {
    content: "";
    position: absolute;
    width: 100%;
    height: 2px;
    bottom: -14px;
    left: 0;
    background-color: var(--link-color);
    visibility: hidden;
    transform: scaleX(0);
    transition: all 0.3s ease-in-out 0s;
}

.navlink:hover:before {
    visibility: visible;
    transform: scaleX(1);
}

.navlink2 {
    color: var(--navlink-color);
    padding: 16px 16px;
    text-decoration: none;
    display: block;
    transition: background-color 0.3s, 0.5s ease;
}

.navlink2:hover {
    background-color: var(--dropdown-color);
    color: var(--navlink-color);
}

.navli:hover .dropdown {
    visibility: visible;
    opacity: 1;
    transition: visibility 0.3s, opacity 0.3s;
    transition-delay: 0s;
}

#menutoggle {
    display: block;
    position: relative;
    top: 50px;
    left: 50px;
    z-index: 1;
}

#menutoggle input {
    display: block;
    width: 40px;
    height: 32px;
    position: absolute;
    top: -7px;
    left: -5px;
    cursor: pointer;
    opacity: 0;
    z-index: 2;
}

#menutoggle span:first-child {
    transform-origin: 0% 0%;
}

#menutoggle span:nth-last-child(2) {
    transform-origin: 0% 100%;
}

#menutoggle input:checked ~ span {
    opacity: 1;
    transform: rotate(45deg) translate(-2px, -1px);
    background: var(--hamburger);
}

#menutoggle input:checked ~ span:nth-last-child(3) {
    opacity: 0;
    transform: rotate(0deg) scale(0.2, 0.2);
}

#menutoggle input:checked ~ span:nth-last-child(2) {
    transform: rotate(-45deg) translate(0, -1px);
}

#menutoggle input:checked ~ ul {
    transform: none;
}

.hamburger {
    display: block;
    width: 33px;
    height: 4px;
    margin-bottom: 5px;
    position: relative;
    background: #cdcdcd;
    border-radius: 3px;
    z-index: 1;
    transform-origin: 4px 0px;
    transition: transform 0.5s cubic-bezier(0.77,0.2,0.05,1.0), background 0.5s cubic-bezier(0.77,0.2,0.05,1.0), opacity 0.55s ease;
}

#mobilenavlist {
    position: fixed;
    top: -70px;
    left: 45px;
    width: 200px;
    height: 100%;
    margin: -100px 0 0 -50px;
    padding: 50px;
    padding-top: 125px;
    background: var(--color-primary);
    list-style-type: none;
    transform-origin: 0% 0%;
    transform: translate(-100%, 0);
    transition: transform 0.5s cubic-bezier(0.77,0.2,0.05,1.0);
}

#mobilenavlist li {
    padding: 10px 0;
    font-size: 1.2em;
    font-family: 'opensans-bold',sans-serif;
    text-align: left;
}

#mobilenavlist li a {
    color: var(--navlink-color);
}

#mobilenavlist li a:hover, #mobilenavlist li span:hover {
    color: var(--navlink-color);
    border-bottom: 2px solid var(--navlink-color);
}

#mobilenavlist .mobiledd {
    display: none;
    margin: 8px 0 -5px 20px;
}

#mobilenavlist .mobiledd2 {
    display: none;
    margin: 8px 0 -5px 20px;
}

#mobilenavlist .mobiledd li {
    font-size: 1em;
    list-style: none;
}

#mobilenavlist li:hover .mobiledd {
    display: block;
}

#mobilenavlist .mobiledd li:hover .mobiledd2 {
    display: block;
}

.navli {
    display: inline;
    font-family: 'minecraft-title',sans-serif;
    color: #333333;
    position: relative;
}

#currentpage {
    text-decoration: none;
    color: var(--white);
    background: var(--link-color);
    border-radius: 5px;
}

.fakelink {
    cursor: pointer;
}

.dropdown {
    position: absolute;
    left: 0px;
    top: 28px;
    background-color: var(--color-primary);
    visibility: hidden;
    opacity: 0;
    border-radius: 5px;
    transition: visibility 0.3s, opacity 0.3s;
    transition-delay: 0.1s;
    font-size: 0.9em;
    min-width: 160px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
    z-index: 1;
    text-align: left;
    width: 200px;
}

#subdrop {
    display: none;
}

/* darkmode switch start */

/* The switch - the box around the slider */
.switch {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 25px;
}

.switch-div{
    position: absolute;
    right: 40px;
}

/* Hide default HTML checkbox */
.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

/* The slider */
.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    -webkit-transition: 0.4s;
    transition: 0.4s;
}

.slider:before {
    position: absolute;
    content: "";
    height: 37px;
    width: 37px;
    left: 0px;
    bottom: 4px;
    top: 0;
    bottom: 0;
    margin: auto 0;
    -webkit-transition: 0.4s;
    transition: 0.4s;
    box-shadow: 0 0px 15px #2020203d;
    background: var(--switch) url('https://i.ibb.co/7JfqXxB/sunny.png');
    background-repeat: no-repeat;
    background-position: center;
}

input:checked + .slider {
    background-color: var(--link-color);
}

input:focus + .slider {
    box-shadow: 0 0 1px var(--link-color);
}

input:checked + .slider:before {
    -webkit-transform: translateX(24px);
    -ms-transform: translateX(24px);
    transform: translateX(24px);
    background: var(--switch) url('https://i.ibb.co/FxzBYR9/night.png');
    background-repeat: no-repeat;
    background-position: center;
}

/* Rounded sliders */
.slider.round {
    border-radius: 34px;
}

.slider.round:before {
    border-radius: 50%;
}

/* darkmode switch end */

@-moz-document url-prefix() {
  .dropdown2{
    top: 12px;
  }
}

@supports (-ms-ime-align:auto) {
  .dropdown2{
    top: 0px;
  }
}

@media (max-width: 1150px) {
    .dropdown {
        top: -10px;
        font-size: 0.9em;
    }

    #nav {
        height: 150px;
        position: relative;
    }

    #nav.active {
        height: 150px;
    }

    #navlist {
        font-size: 0.8em;
    }

    #nav img, #nav ul {
        margin-top: 30px;
    }

    header .container {
        justify-content: center;
        display: block;
        width: 100%;
    }

    .switch-div {
        top: 65px;
    }
}

@media (max-width: 690px) {
    #navlist {
        display: none;
    }

    #nav {
        height: 90px;
        position: fixed;
    }

    #nav.active {
        height: 90px;
    }

    #nav img {
        margin-top: 18px;
    }

    #mobilenav {
        display: block;
        position: fixed;
        left: 0;
        top: -15px;
    }

    #currentpage {
        background: none;
        border-bottom: 3px solid var(--pureblack);
    }

    .switch-div {
        top: 33px;
    }
}

@media (min-width: 690px) {
    #mobilenav {
        display: none;
    }
}
