.navbarBox {
    position: fixed;
    left: 0;
    top: 0;
    width: calc(100% - 80px);
    padding: 20px 40px 20px 40px;
    display: flex;
    justify-content: space-between;
    background-color: var(--navy-transparent);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    transition: all 0.25s cubic-bezier(0.645,0.045,0.355,1);
    z-index: 5;
}

.navbarBox.scrollingDown {
    top: -100%;
}

.logoBox, .topLogo {
    width: 40px;
    height: 40px;
    animation: logoanimation 0.4s ease-in-out;
    -webkit-animation: logoanimation 0.4s ease-in-out;
    -moz-animation: logoanimation 0.4s ease-in-out;
}

.logoBox {
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.645,0.045,0.355,1);
}

.logoBox:hover {
    background-color: var(--green-tint);
}

.listBox {
    list-style: none;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 16px;
}

.listItem {
    height: 100%;
    padding-inline: 4px;
    display: flex;
    align-items: center;
    transition: all 0.2s linear;
}

.about {
    animation: listItemsanimation 0.6s;
    -webkit-animation: listItemsanimation 0.6s;
    -moz-animation: listItemsanimation 0.6s;
}

.experience {
    animation: listItemsanimation 0.7s;
    -webkit-animation: listItemsanimation 0.7s;
    -moz-animation: listItemsanimation 0.7s;
}

.work {
    animation: listItemsanimation 0.8s;
    -webkit-animation: listItemsanimation 0.8s;
    -moz-animation: listItemsanimation 0.8s;
}

.contact {
    animation: listItemsanimation 0.9s;
    -moz-animation: listItemsanimation 0.9s;
    -moz-animation: listItemsanimation 0.9s;
}

.mode {
    animation: listItemsanimation 1s;
    -webkit-animation: listItemsanimation 1s;
    -moz-animation: listItemsanimation 1s;
}

.listItem:last-child {
    animation: listItemsanimation 1.1s;
    -webkit-animation: listItemsanimation 1.1s;
    -moz-animation: listItemsanimation 1.1s;
}

.listItem:last-child {
    border: 1px solid var(--green);
    border-radius: 6px;
    cursor: pointer;
}

.anchorNav {
    text-decoration: none;
    color: var(--white);
    transition: all 0.2s linear;
    font-family: var(--font-mono);
    font-size: 0.8rem;
}

.mode {
    width: 20px;
    height: 20px;
    cursor: pointer;
    background-image: url("../images/light-mode.svg");
    background-position: center;
    background-size: contain;
    transition: all 0.25s cubic-bezier(0.645,0.045,0.355,1);
}

.listItem:last-child .anchorNav {
    color: var(--green);
    width: 100%;
    height: 100%;
    padding-inline: 16px;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 5;
}

.listItem:last-child:hover {
    background-color: var(--green-tint);
}

.listItem .anchorNav:hover {
    color: var(--green);
}

.itemNum {
    margin-right: 6px;
    color: var(--green);
}

.hamburgerMenu {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-end;
    gap: 6px;
    padding: 4px;
    cursor: pointer;
    display: none;
    animation: listItemsanimation 0.6s;
    -webkit-animation: listItemsanimation 0.6s;
    -moz-animation: listItemsanimation 0.6s;
}

.hamburgerLine {
    width: 16px;
    height: 3px;
    background-color: var(--green);
    border-radius: 12px;
}

.top {
    width: 32px;
}

.mid {
    width: 24px;
}

@media screen and (max-width: 770px) {
    .navbarBox {
        padding: 20px;
        width: calc(100% - 40px);
        z-index: 5;
    }

    .listBox {
        position: fixed;
        background-color: var(--light-navy);
        flex-direction: column;
        top: 0;
        right: -110%;
        height: 100vh;
        width: max(50vw, 150px);
        transition: all 0.2s linear;
        z-index: 5;
    }

    .listBox.active {
        right: 0px;
    }

    .listItem {
        height: fit-content;
        padding: 4px;
    }

    .anchorNav {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 4px;
    }

    .itemNum {
        display: block;
        margin: 0px;
    }

    .listItem:last-child {
        width: 72px;
        height: 40px;
        padding: 0;
        display: flex;
        justify-content: center;
    }
    
    .hamburgerMenu {
        display: flex;
        z-index: 5;
    }

    .hamburgerMenu .hamburgerLine {
        transition: all 0.3s linear;
    }

    .hamburgerMenu.active .top {
        width: 32px;
        transform: rotate(45deg) translateY(12px);
    }

    .hamburgerMenu.active .mid {
        width: 0px;
    }

    .hamburgerMenu.active .bottom {
        width: 32px;
        transform: rotate(-45deg) translateY(-12px);
    }
}

@media screen and (max-height: 400px) {
    .listBox {
        gap: 8px;
    }

    .anchorNav {
        flex-direction: row;
    }

    .itemNum {
        display: inline;
    }

    .listItem {
        font-size: 0.8rem;
    }

    .listItem:last-child {
        height: 30px;
    }
}

@keyframes logoanimation {
    0% {
        transform: translateY(-16px);
        opacity: 0;
    }
    100% {
        transform: translateY(0px);
        opacity: 1;
    }
}

@keyframes listItemsanimation {
    0% {
        transform: translateY(-20px);
        opacity: 0;
    }
    50% {
        transform: translateY(-20px);
        opacity: 0;
    }
    100% {
        transform: translateY(0px);
        opacity: 1;
    }
}