/* Navbar Layout */
nav {
    height: 70px;
    background-color: #fff;
    backdrop-filter: blur(10px);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 5%;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1005;
    box-shadow: var(--shadow-md);
}

/* logo */
.logo {
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: 2px;
    color: var(--primary-blue);
    cursor: pointer;
}

/* chack-box hidden */
#menu-toggle {
    display: none;
}

/* menu icon (Hamburge)*/
.menu-icon {
    /* display: none; */
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
    z-index: 1001;
}

.menu-icon span {
    width: 25px;
    height: 3px;
    background-color: black;
    border-radius: 5px;
    transition: 0.5s;
}

/* Dasktop nav link */
.nav-link {
    list-style: none;
    display: flex;
    gap: 30px;
}

.nav-link li a {
    text-decoration: none;
    color: rgb(58, 58, 58);
    font-weight: 500;
    transition: color 0.3s;
    position: relative;
}

.nav-link li a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: var(--primary-blue);
    transition: 0.3s;
}

.nav-link li a:hover {
    color: var(--primary-blue);
}

.nav-link li a:hover::after {
    width: 100%;
}

/* mobile view (media query0) */
@media (max-width: 768px) {
    .menu-icon {
        display: flex;
    }
    .nav-link {
        position: fixed;
        top: 0;
        right: -100%;
        height: 100vh;
        width: 70%;
        background-color: #fff;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        transition: right 0.5s ease-in-out;
        box-shadow: -10px 0px 30px rgba(108, 108, 108, 0.5);
    }
    .nav-link li {
        margin: 20px 0;
    }

    /* chack box logic */
    #menu-toggle:checked ~ .nav-link {
        right: 0;
    }

    /* Hamburger animetion */
    #menu-toggle:checked ~ .menu-icon span:nth-child(1) {
        transform: rotate(45deg) translate(5px , 6px);
    }
    #menu-toggle:checked ~ .menu-icon span:nth-child(2) {
        opacity: 0;
    }
    #menu-toggle:checked ~ .menu-icon span:nth-child(3) {
        transform: rotate(-45deg) translate(5px , -6px);
    }
}