.navbar {
    position: relative;
    height: 96px;
    background: transparent;
    border-bottom: 1px solid rgba(255, 255, 255, 0.18);
    box-shadow: none;
    transition: height 0.3s ease, background-color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.navbar::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.52) 0%, rgba(0, 0, 0, 0.18) 55%, rgba(0, 0, 0, 0) 100%);
    opacity: 1;
    transition: opacity 0.3s ease;
}

.navbar.scrolled {
    height: 76px;
    background: #ffffff;
    border-bottom-color: rgba(0, 0, 0, 0.08);
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.1);
}

.navbar.scrolled::before {
    opacity: 0;
}

.navbar-wrapper {
    position: relative;
    min-height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    width: 132px;
    height: 72px;
    overflow: visible;
    transition: width 0.3s ease, height 0.3s ease, transform 0.3s ease;
}

.logo img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.navbar.scrolled .logo {
    width: 108px;
    height: 58px;
    transform: scale(0.96);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-item {
    padding: 10px 14px;
    border-radius: var(--border-radius-md);
    font-family: var(--font-heading);
    font-weight: 600;
    color: #000000;
    text-shadow: 0 2px 10px rgba(255, 255, 255, 0.85), 0 3px 14px rgba(0, 0, 0, 0.3);
    transition: color 0.3s ease, background-color 0.3s ease;
}

.nav-item:hover,
.nav-item.active {
    color: var(--primary-color);
}

.navbar.scrolled .nav-item {
    color: var(--black-color);
    text-shadow: none;
}

.navbar.scrolled .nav-item:hover,
.navbar.scrolled .nav-item.active {
    background: rgba(0, 0, 0, 0.06);
    color: var(--secondary-color);
}

.nav-cta {
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav-icon-btn {
    min-width: 42px;
    height: 42px;
    padding: 0 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--border-radius-md);
    color: #ffffff;
    background: rgba(255, 255, 255, 0.12);
    font-size: 1.08rem;
    transition: color 0.3s ease, background-color 0.3s ease;
}

.language-toggle {
    gap: 7px;
    font-family: var(--font-heading);
    font-size: 0.9rem;
    font-weight: 700;
}

.nav-icon-btn:hover {
    background: rgba(255, 255, 255, 0.22);
}

.navbar.scrolled .nav-icon-btn {
    color: var(--black-color);
    background: rgba(0, 0, 0, 0.04);
}

.navbar.scrolled .nav-icon-btn:hover {
    background: rgba(0, 0, 0, 0.08);
}

.mobile-menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border-radius: var(--border-radius-md);
    background: rgba(255, 255, 255, 0.12);
    color: #ffffff;
    font-size: 1.1rem;
    transition: color 0.3s ease, background-color 0.3s ease;
}

.navbar.scrolled .mobile-menu-toggle {
    background: var(--black-color);
    color: var(--primary-color);
}

@media (max-width: 820px) {
    .navbar {
        height: 82px;
        border-bottom-color: transparent;
    }

    .navbar.scrolled {
        height: 68px;
    }

    .navbar-wrapper {
        min-height: 100%;
    }

    .logo {
        width: 128px;
        height: 58px;
    }

    .navbar.scrolled .logo {
        width: 108px;
        height: 48px;
    }

    .nav-links {
        position: fixed;
        left: 0;
        right: 0;
        top: 82px;
        display: none;
        flex-direction: column;
        align-items: stretch;
        padding: 16px 20px 22px;
        background: #ffffff;
        border-bottom: 1px solid rgba(0, 0, 0, 0.08);
        box-shadow: var(--shadow-md);
        transition: top 0.3s ease;
    }

    .navbar.scrolled .nav-links {
        top: 68px;
    }

    .nav-links.open {
        display: flex;
    }

    .nav-item {
        text-align: center;
        color: var(--black-color);
    }

    .nav-icon-btn:not(.language-toggle) {
        display: none;
    }

    .mobile-menu-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }
}
