/* Ortak yüzen üst menü */
nav {
    position: fixed;
    inset: 0 0 auto;
    z-index: 100;
    isolation: isolate;
    padding: 18px 0;
    background: transparent;
    box-shadow: none;
    backdrop-filter: none;
    transition: padding .25s ease, background-color .25s ease, box-shadow .25s ease;
}

nav::before {
    position: absolute;
    inset: 0 0 -34px;
    z-index: 0;
    background: rgba(255,255,255,.035);
    content: '';
    opacity: 0;
    pointer-events: none;
    backdrop-filter: blur(18px) saturate(1.15);
    -webkit-backdrop-filter: blur(18px) saturate(1.15);
    mask-image: linear-gradient(to bottom, #000 0%, #000 48%, rgba(0,0,0,.78) 66%, transparent 100%);
    -webkit-mask-image: linear-gradient(to bottom, #000 0%, #000 48%, rgba(0,0,0,.78) 66%, transparent 100%);
    transition: opacity .25s ease;
}

nav.is-scrolled,
nav.nav-open {
    padding: 10px 0;
    background: transparent;
    box-shadow: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
}

nav.is-scrolled::before,
nav.nav-open::before {
    opacity: 1;
}

nav.is-scrolled .logo,
nav.is-scrolled .nav-menu,
nav.is-scrolled .nav-phone,
nav.is-scrolled .nav-toggle,
nav.nav-open .logo,
nav.nav-open .nav-menu,
nav.nav-open .nav-phone,
nav.nav-open .nav-toggle {
    box-shadow: 0 14px 34px rgba(15,18,33,.32);
}

nav .nav-container {
    position: relative;
    z-index: 1;
    display: flex;
    width: calc(100% - 24px);
    max-width: 1380px;
    margin: 0 auto;
    padding: 0;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

nav .logo,
nav .nav-menu,
nav .nav-phone {
    height: 64px;
    min-height: 64px;
    border: 1px solid rgba(255,255,255,.72);
    border-radius: 32px;
    background: rgba(255,255,255,.97);
    box-shadow: 0 12px 34px rgba(31,20,12,.18);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

nav .logo {
    display: flex;
    width: 226px;
    padding: 7px 15px;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    transition: transform .25s ease, box-shadow .25s ease;
}

nav .logo:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 38px rgba(31,20,12,.24);
}

nav .logo:focus-visible,
nav .nav-phone:focus-visible,
nav .nav-menu a:focus-visible {
    outline: 3px solid rgba(255,171,92,.78);
    outline-offset: 3px;
}

nav .logo img {
    display: block;
    width: 100%;
    max-width: 194px;
    max-height: 48px;
    height: auto;
    object-fit: contain;
}

nav .nav-menu {
    display: flex;
    min-width: 0;
    padding: 7px 18px;
    align-items: center;
    justify-content: center;
    flex: 1 1 auto;
    gap: 8px;
}

nav .nav-menu a {
    position: relative;
    display: inline-flex;
    height: 48px;
    padding: 0 22px;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-radius: 24px;
    color: #2f241f;
    font-size: .95rem;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    transition: color .25s ease, background-color .25s ease, transform .25s ease;
}

nav .nav-menu a::after {
    position: absolute;
    right: 22px;
    bottom: 8px;
    left: 22px;
    width: auto;
    height: 2px;
    border-radius: 2px;
    background: var(--secondary-color);
    content: '';
    transform: scaleX(0);
    transform-origin: center;
    transition: transform .25s ease;
}

nav .nav-menu a:hover {
    color: var(--primary-color);
    background: #fff4ea;
    transform: translateY(-1px);
}

nav .nav-menu a:hover::after,
nav .nav-menu a:focus-visible::after {
    width: auto;
    transform: scaleX(1);
}

nav .nav-phone {
    display: inline-flex;
    padding: 0 25px;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    gap: 9px;
    border-color: rgba(255,149,58,.78);
    background: linear-gradient(135deg,#e86f1b,#a94c16);
    color: #fff;
    font-size: .92rem;
    font-weight: 700;
    text-decoration: none;
    transition: transform .25s ease, box-shadow .25s ease, filter .25s ease;
}

nav .nav-phone:hover {
    background: linear-gradient(135deg,#f47c25,#b75518);
    box-shadow: 0 16px 38px rgba(109,47,12,.34);
    color: #fff;
    filter: saturate(1.08);
    transform: translateY(-2px);
}

nav .phone-icon {
    width: 18px;
    height: 18px;
    fill: currentColor;
}

nav .nav-toggle {
    display: none;
    width: 56px;
    height: 56px;
    padding: 0;
    align-items: center;
    justify-content: center;
    flex: 0 0 56px;
    border: 6px solid #fff;
    border-radius: 50%;
    background: #ff7526;
    box-shadow: 0 4px 14px rgba(15,18,33,.3);
    color: #fff;
    cursor: pointer;
    transition: transform .25s ease, background-color .25s ease, box-shadow .25s ease;
}

nav .nav-toggle:hover,
nav .nav-toggle:focus-visible {
    background: #e96318;
    box-shadow: 0 7px 18px rgba(15,18,33,.38);
    transform: translateY(-1px);
}

nav .nav-toggle:focus-visible {
    outline: 3px solid rgba(255,171,92,.8);
    outline-offset: 3px;
}

nav .nav-toggle-lines,
nav .nav-toggle-lines::before,
nav .nav-toggle-lines::after {
    display: block;
    width: 17px;
    height: 2px;
    border-radius: 2px;
    background: currentColor;
    content: '';
    transition: transform .25s ease, opacity .25s ease;
}

nav .nav-toggle-lines {
    position: relative;
}

nav .nav-toggle-lines::before {
    position: absolute;
    top: -6px;
    left: 0;
}

nav .nav-toggle-lines::after {
    position: absolute;
    top: 6px;
    left: 0;
}

nav.nav-open .nav-toggle-lines {
    background: transparent;
}

nav.nav-open .nav-toggle-lines::before {
    top: 0;
    transform: rotate(45deg);
}

nav.nav-open .nav-toggle-lines::after {
    top: 0;
    transform: rotate(-45deg);
}

header {
    position: relative;
    margin-top: 0;
    padding-top: 220px;
    overflow: hidden;
}

@media (max-width: 1040px) {
    nav .nav-container { gap: 10px; }
    nav .logo { width: 190px; }
    nav .logo img { max-width: 160px; }
    nav .nav-menu { padding-inline: 10px; gap: 2px; }
    nav .nav-menu a { padding-inline: 14px; font-size: .88rem; }
    nav .nav-phone { padding-inline: 18px; font-size: .86rem; }
}

@media (max-width: 768px) {
    nav {
        padding: 12px 0;
        background: transparent;
        box-shadow: none;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }
    nav .nav-container {
        width: calc(100% - 24px);
        padding: 0;
        flex-wrap: wrap;
        justify-content: space-between;
        gap: 10px;
    }
    nav .logo {
        width: min(230px,calc(100% - 68px));
        height: 56px;
        min-height: 56px;
        border-radius: 28px;
    }
    nav .logo { padding: 6px 14px; }
    nav .logo img { width: 100%; max-width: 170px; max-height: 42px; }
    nav .nav-toggle { display: inline-flex; order: 2; }
    nav .nav-menu {
        display: none;
        order: 3;
        width: 100%;
        height: auto;
        min-height: 0;
        padding: 10px;
        border-radius: 24px;
        flex-direction: column;
        flex-wrap: nowrap;
        gap: 4px;
    }
    nav .nav-menu a {
        height: 44px;
        width: 100%;
        padding: 0 16px;
        flex: 0 0 44px;
        border-radius: 22px;
        font-size: .9rem;
        white-space: nowrap;
        text-align: center;
        line-height: 1.2;
    }
    nav .nav-menu a::after { right: 14px; bottom: 6px; left: 14px; }
    nav .nav-phone {
        display: none;
        order: 4;
        width: 100%;
        height: 54px;
        min-height: 54px;
        padding: 0 18px;
        border-radius: 27px;
        font-size: .9rem;
    }
    nav.nav-open .nav-menu,
    nav.nav-open .nav-phone { display: flex; }
    header { margin-top: 0; padding-top: 210px; }
}

@media (max-width: 420px) {
    nav .nav-container { width: calc(100% - 16px); gap: 8px; }
    nav .logo img { max-width: 145px; }
    nav .phone-icon { width: 16px; height: 16px; }
    nav .nav-menu a { padding-inline: 10px; font-size: .84rem; }
}
