/* 导航栏样式 */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    /* height: 80px; */
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 40px;
    background: transparent;
    z-index: 1002;
    /* mix-blend-mode: difference; 移除混合模式 */
}

.logo {
    display: flex;
    align-items: center;
}

.logo a {
    color: #fff;
    text-decoration: none;
    font-size: 1.5rem;
    font-weight: 300;
    letter-spacing: 3px;
    top: 8vw;
    left: 10vw;
}

.logo-image {
    height: 30px;
    width: auto;
    transition: opacity 0.3s ease;
}

.logo-image:hover {
    opacity: 0.8;
}

.logo:hover {
  transform: scale(1.02);
  transition: all 0.3s ease;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 30px;
   
}

.projects-link {
    top: 8vw;
    right: 15vw;
    color: #fff;

    text-decoration: none;
    font-size: 1.2rem;
    /* letter-spacing: 2px; */
    padding: 8px 20px;
    /* border: 1px solid rgba(255, 255, 255, 0.3); */
    /* border-radius: 20px; */
    transition: all 0.3s ease;


}

.projects-link:hover {
    /* background: rgba(255, 255, 255, 0.1); */
    /* border-color: rgba(255, 255, 255, 0.5); */
    transform: scale(1.2);
    transition: all 0.3s ease;
}

.menu-button {
    width: 30px;
    height: 24px;
    background: none;
    border: none;
    padding: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    cursor: pointer;
    position:fixed ;
    right: 2%;
    top: 50%;
    margin-top: -30px;
    transform: all 0.3s ease;
    z-index: 1001;
    /* mix-blend-mode: difference; 移除混合模式 */
}

.menu-button:hover {
    
    transform: scale(1.2);
    transition: all 0.3s ease;
    
}

.menu-line {
    width: 100%;
    height: 2px;
    background-color: #fff;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.menu-button.active .menu-line:nth-child(1) {
    transform: translateY(11px) rotate(45deg);
}

.menu-button.active .menu-line:nth-child(2) {
    opacity: 0;
}

.menu-button.active .menu-line:nth-child(3) {
    transform: translateY(-11px) rotate(-45deg);
}

/* 导航栏响应式 */
@media (max-width: 1200px) {
    .navbar {
        height: 70px;
        padding: 0 30px;
    }

    .logo-image {
        height: 28px;
    }

    .projects-link {
        font-size: 1.1rem;
        padding: 6px 16px;
    }

    .menu-button {
        width: 28px;
        height: 22px;
        margin-top: -25px;
    }

    .menu-line {
        height: 1.8px;
    }
}

@media (max-width: 768px) {
    .navbar {
        height: 60px;
        padding: 0 20px;
    }

    .logo-image {
        height: 24px;
    }

    .nav-right {
        gap: 20px;
    }

    .projects-link {
        font-size: 1rem;
        padding: 5px 14px;
    }

    .menu-button {
        width: 25px;
        height: 20px;
        margin-top: -22px;
    }

    .menu-line {
        height: 1.5px;
    }

    .menu-button.active .menu-line:nth-child(1) {
        transform: translateY(9px) rotate(45deg);
    }

    .menu-button.active .menu-line:nth-child(3) {
        transform: translateY(-9px) rotate(-45deg);
    }
}

@media (max-width: 480px) {
    .navbar {
        height: 50px;
        padding: 0 15px;
    }

    .logo-image {
        height: 20px;
    }

    .nav-right {
        gap: 15px;
    }

    .projects-link {
        font-size: 0.9rem;
        padding: 4px 12px;
    }

    .menu-button {
        width: 22px;
        height: 18px;
        margin-top: -20px;
    }

    .menu-line {
        height: 1.2px;
    }

    .menu-button.active .menu-line:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .menu-button.active .menu-line:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }
}