
nav {
    position: fixed;
    bottom: 10px;
    /* right: 5%; */
    z-index: 999;
    transition: .3s;
    right: 0;
}
.navbar ul.links {
    display: flex;
    gap: 20px;
}
.navbar ul.links li {
    display: flex;
    flex-direction: column;
    gap: 10px;
    color: var(--white-color);
    font-size: 16px;
    width: 65px;
    cursor: pointer;
    transition: .3s;
}
.navbar ul.links li.active {
    width: 100px;
    color: var(--main-color);
}
.navbar ul.links li.active a span {
    border-bottom-color:  var(--main-color);
}
.navbar ul.links li a {
    display: flex;
    flex-direction: column;
    font-weight: 500;
    gap: 5px;
}
.navbar ul.links li a span {
    border-bottom: 1px solid var(--white-color);
    padding-bottom: 10px;
}

/* ==================== Responsive ====================*/
.nav-responsive {
    position: fixed;
    right: 40px;
    bottom: 40px;
    width: 60px;
    height: 60px;
    z-index: 999;
    transition: .3s;
    display: none;
}


.nav-responsive .menu-btn,
.nav-responsive .menu-item {
    position: absolute;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
}
.nav-responsive .menu-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    border: none;
    border-radius: 50%;
    background: var(--main-color);
    color: var(--white-color);
    font-size: 28px;
    cursor: pointer;
    box-shadow:0 10px 30px rgba(0,0,0,.3);
    z-index: 999;
}
.nav-responsive .menu-item {
    background-color: var(--white-color);
    color: var(--main-color);
    text-decoration: none;
    opacity: 0;
    pointer-events: none;
    transition: .4s;
    /* border: 1px solid var(--main-color); */
    box-shadow: 0 0 05px var(--main-color);
}

.nav-responsive .menu-item img {
    width: 30px;
    height: 30px;
}

.nav-responsive.active .item1 {
    transform: translate(-90px,-20px);
}
.nav-responsive.active .item2 {
    transform: translate(-70px,-90px);
}
.nav-responsive.active .item3 {
    transform: translate(0,-120px);
}
.nav-responsive.active .item4 {
    transform: translate(70px,-90px);
}
.nav-responsive.active .item5 {
    transform: translate(90px,-20px);
}
.nav-responsive.active .item6 {
    transform: translate(55px, 70px);
}
.nav-responsive.active .item7 {
    transform: translate(-40px, 70px);
}
.nav-responsive.active .menu-item {
    pointer-events: auto;
    opacity: 1;
    z-index: 999;
}

body.scrolled .nav-desktop {
    display: none;
}

body.scrolled .nav-responsive {
    display: block;
}

body.bg .nav-desktop {
    background-image: linear-gradient(to right, #0A192F, #4a5871c7, #0A192F);
    padding: 10px 20px;
    border-radius: 10px 0 0 10px;
    display: block;
    opacity: 1;
}
.nav-desktop{
    opacity: 0;
    transition: .3s;
}


.nav-responsive.active {
    right: 110px;
    bottom: 100px;
}

.nav-responsive .menu-item::after {
    content: attr(data-label);
    position: absolute;
    bottom: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%) translateY(6px);
    background: var(--second-color);
    color: var(--white-color);
    font-family: "font_main", sans-serif;
    font-size: 0.72rem;
    white-space: nowrap;
    padding: 4px 10px;
    border-radius: 4px;
    opacity: 0;
    z-index: 999;
    pointer-events: none;
    transition: opacity 0.25s, transform 0.25s;
}

.nav-responsive .menu-item:hover::after {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

@media (max-width: 992px) {
    .nav-desktop {
        display: none !important;
    }
    .nav-responsive {
        display: block;
    }
}

@media (max-width: 767px) {
    .nav-responsive.active {
        right: 80px;
        bottom: 85px;
    }
}

@media (max-width: 575px) {
    .nav-responsive .menu-btn,
    .nav-responsive .menu-item {
        width: 45px;
        height: 45px;
    }
    .nav-responsive {
        right: 0;
        bottom: 4%;
    }

    .nav-responsive.active .item3 {
        transform: translate(0, -95px);
    }

    .nav-responsive.active .item2 {
        transform: translate(-50px, -65px);
        }

    .nav-responsive.active .item1 {
        transform: translate(-65px, 0px);
        }

    .nav-responsive.active .item4 {
        transform: translate(55px, -70px);
        }

    .nav-responsive.active .item5 {
        transform: translate(70px, -10px);
        }
}

@media (max-width: 400px) {
    .nav-responsive .menu-btn {
        font-size: 17px;
        }

    .nav-responsive .menu-btn,
    .nav-responsive .menu-item {
        width: 35px;
        height: 35px;
        }

    .nav-responsive .menu-item img {
        width: 25px;
        height: 25px;
        }

    .nav-responsive.active .item4 {
        transform: translate(65px, -40px);
        }

    .nav-responsive.active .item5 {
        transform: translate(70px, 15px);
        }

    .nav-responsive.active .item7 {
        transform: translate(-20px, 60px);
        }

    .nav-responsive.active .item1 {
        transform: translate(-65px, -5px);
        }

    .nav-responsive.active .item3 {
        transform: translate(15px, -75px);
        }

    .nav-responsive.active .item2 {
        transform: translate(-50px, -65px);
        }

    .nav-responsive.active .item6 {
        transform: translate(40px, 55px);
        }
}
