@import url('https://fonts.googleapis.com/css2?family=Fleur+De+Leah&display=swap');

.jz-topbar {
    display: flex;
    justify-content: end;
    align-items: center;
    position: relative;
    background-color: transparent;
    padding: 10px;
    font-size: 20px;
    height: 3.2em;
    box-shadow: 0px 2px 5px rgba(0, 0, 0, 0.4);
}

.jz-topbar-title {
    text-decoration: none;
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    display: inline-flex;

    h2 {
        margin-left: 10px;
        font-family: 'Fleur De Leah', cursive;
        user-select: none;
        font-size: 2em;
    }

    .jz-logo {
        margin: auto 0;
    }
}

.jz-topbar-sm-title {
    display: none;
}

.jz-topbar-nav {
    list-style: none;
    margin-right: 1em;
    display: inline-flex;
}

.jz-menu-item {
    display: inline-flex;
    padding: 0 1em;
}

.jz-menu-link {
    color: #000;
    text-decoration: none;
    margin-top: auto;
}

.jz-topbar-toggle {
    display: none;
    position: absolute;
    top: 50%;
    right: 10px;
    transform: translateY(-50%);
    user-select: none;
    font-size: 24px;
    cursor: pointer;
    border: none;
    background-color: transparent;
    outline: none;
    z-index: 1000;
}

.jz-hamburger {
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    align-items: center;
    height: 24px;
    width: 24px;
    transition: transform 0.3s ease-in-out;
}

.jz-hamburger div {
    width: 100%;
    height: 3px;
    background-color: #008080;
    transition: transform 0.4s ease-in-out;

    &:nth-child(1) {
        transition-delay: 0.1s;
    }

    &:nth-child(2) {
        transition-delay: 0.2s;
        width: 80%;
    }

    &:nth-child(3) {
        transition-delay: 0s;
    }
}

.jz-hamburger.opening {
    div:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
        transition-delay: 0.2s;
    }

    div:nth-child(2) {
        transform: scaleX(0);
        transition-delay: 0s !important;
    }

    div:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
        transition-delay: 0.1s;
    }
}

.jz-hamburger.opening div {
    transform: translateY(0) rotate(0) scaleX(1);
}

.jz-hamburger.active div {
    &:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    &:nth-child(2) {
        transform: scaleX(0);
    }

    &:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }
}

@media screen and (max-width: 991.98px) {
    .jz-topbar-nav {
        position: fixed;
        display: flex;
        flex-direction: column;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        padding: 0;
        margin: 0;
        background-color: #fff;
        transform: translateX(-100%);
        transition: transform 0.3s ease;
        z-index: 999;
    }

    .jz-topbar-sm-title {
        margin-left: 10px;
        font-family: 'Fleur De Leah', cursive;
        user-select: none;
        font-size: 2em;
        margin-top: 20px;
        display: flex;
    }

    .jz-topbar-nav.sm-active {
        transform: translateX(0);
        transition: transform 0.3s ease;
    }

    .jz-topbar-menu {
        display: flex;
        flex-direction: column;
        width: 100%;
        height: fit-content;
        padding: 0;
        margin: 0;
    }

    .jz-topbar-menu .jz-menu-item {
        padding: 0;
        text-align: left;
        width: 100%;
        height: 100%;
        display: flex;
    }

    .jz-menu-link {
        padding: 10px 15px;
        color: #333;
        text-decoration: none;
        font-size: 18px;
        transition: background-color 0.3s ease-in-out;
        transition-delay: 0.3s;
        width: 100%;
    }

    .jz-menu-link.active {
        background-color: #008080;
        color: #fff;
    }

    .jz-topbar-toggle {
        display: flex;
    }
}

@media (min-width: 992px) {

    .jz-menu-link:hover::after,
    .jz-menu-link.active::after {
        transform: scaleX(1);
    }

    .jz-menu-link::after {
        content: "";
        display: block;
        width: 100%;
        height: 3px;
        transform: scaleX(0);
        background-color: #008080;
        transition: transform 0.3s ease-in-out;
    }
}