
.navbar {
    position: fixed;
    top: 15px;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 12px 20px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.navbar .container {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 56px;
    padding: 0 12px;
    border-radius: 14px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.navbar.scrolled {
    padding: 8px 20px;
}

.navbar.scrolled .container {
    background: rgba(252, 252, 252, 0.92);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06), 0 8px 24px rgba(0, 0, 0, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.7);
    height: 75px;
    padding: 0 20px;
}


.nav-left {
    flex-shrink: 0;
}

.nav-left .logo {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.nav-left .logo img {
    height: 55px;
    width: auto;
    object-fit: contain;
    transition: opacity 0.2s ease;
}

.nav-left .logo:hover img {
    opacity: 0.8;
}


.nav-center {
    flex: 1;
    display: flex;
    justify-content: center;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 2px;
    list-style: none;
}

.nav-link {
    position: relative;
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 8px 16px;
    font-family: 'Sora', sans-serif;
    font-size: 14.5px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    border-radius: 10px;
    transition: all 0.25s ease;
    white-space: nowrap;
    letter-spacing: -0.01em;
}

.nav-link:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 0;
}

.nav-link.active {
    color: #fff;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 0;
}

.navbar.scrolled .nav-link {
    color: var(--text-dark);
}

.navbar.scrolled .nav-link:hover {
    color: var(--primary-color);
    background: var(--primary-color-low);
    border-radius: 0;
}

.navbar.scrolled .nav-link.active {
    color: #fff;
    background: var(--primary-color);
    border-radius: 0;
}


.has-dropdown {
    position: relative;
}

/* ========== MEGA MENU (Ürünler) ========== */

.has-megamenu {
    position: static;
}

.megamenu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    width: 100%;
    padding-top: 12px;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                visibility 0.3s ease,
                transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    transform: translateY(-6px);
    z-index: 999;
    overscroll-behavior: contain;
}

.megamenu::before {
    content: '';
    position: absolute;
    top: -20px;
    left: 0;
    right: 0;
    height: 32px;
}

.has-megamenu:hover .megamenu {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
}

.megamenu__inner {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08),
                0 2px 8px rgba(0, 0, 0, 0.04);
    border: 1px solid rgba(0, 0, 0, 0.06);
    overflow: hidden;
    overscroll-behavior: contain;
}

/* stretch kaldırıldı: sol sütun içeriği uzayıp grid satırlarını bozuyordu */
.megamenu__body {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 200px;
    min-width: 0;
    align-items: start;
}

/* Üst kategoriler grid; çok satır olunca dış alan da kayar */
.megamenu__cols {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    align-items: start;
    gap: 16px 18px;
    padding: 16px 14px 20px 18px;
    min-width: 0;
    max-height: min(72vh, 640px);
    overflow-x: hidden;
    overflow-y: auto;
    scrollbar-gutter: stable;
    overscroll-behavior: contain;
}

/* Uzun alt kategoriler: sütun içi kaydırma — tüm sütunlar aynı max yükseklikte */
.megamenu__col {
    display: block;
    width: 100%;
    min-width: 0;
    max-height: min(52vh, 400px);
    box-sizing: border-box;
    padding: 0 6px 8px 0;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    scrollbar-color: rgba(0, 0, 0, 0.2) transparent;
}

.megamenu__col::-webkit-scrollbar {
    width: 5px;
}

.megamenu__col::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.18);
    border-radius: 4px;
}

@media (max-width: 480px) {
    .megamenu__cols {
        grid-template-columns: repeat(auto-fill, minmax(168px, 1fr));
        gap: 14px 12px;
    }
}

.megamenu__cat {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 0 4px;
    font-family: 'Sora', sans-serif;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.25;
    color: var(--text-dark-dark);
    text-decoration: none;
    transition: color 0.25s ease;
    flex-shrink: 0;
    min-width: 0;
    overflow-wrap: anywhere;
    word-wrap: break-word;
}

.megamenu__cat:hover {
    color: var(--primary-color);
}

.megamenu__cat i {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    font-size: 12px !important;
    border-radius: 6px;
    background: rgba(2, 119, 189, 0.08);
    color: var(--primary-color);
    flex-shrink: 0;
    transition: background 0.25s ease, color 0.25s ease;
}

.megamenu__cat:hover i {
    background: var(--primary-color);
    color: #fff;
}

.megamenu__all {
    display: inline-block;
    padding: 2px 0 6px;
    font-family: 'Montserrat', sans-serif;
    font-size: 11px;
    font-weight: 500;
    color: var(--text-dark-low);
    opacity: 0.85;
    text-decoration: none;
    transition: color 0.25s ease, opacity 0.25s ease;
    flex-shrink: 0;
}

.megamenu__all:hover {
    color: var(--primary-color);
    opacity: 1;
}

.megamenu__group {
    display: block;
    margin-top: 10px;
    padding: 8px 0 10px;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
    min-width: 0;
}

.megamenu__group:first-of-type {
    margin-top: 4px;
    border-top: none;
    padding-top: 0;
}

.megamenu__mid {
    display: block;
    padding: 4px 0 5px;
    font-family: 'Montserrat', sans-serif;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-dark-low);
    opacity: 0.75;
    text-decoration: none;
    transition: color 0.2s ease, opacity 0.2s ease;
    min-width: 0;
    overflow-wrap: anywhere;
    word-wrap: break-word;
    line-height: 1.4;
}

.megamenu__mid:hover {
    color: var(--primary-color);
    opacity: 1;
}

.megamenu__mid--label {
    cursor: default;
    pointer-events: none;
}

.megamenu__mid--label:hover {
    color: inherit;
    opacity: 0.75;
}

.megamenu-mobile__ust a {
    font-weight: 600;
}

.megamenu-mobile__mid {
    padding: 0.5rem 0 0.15rem;
    font-size: 0.85rem;
    font-weight: 600;
    opacity: 0.85;
}

.megamenu-mobile__alt {
    display: block;
    padding: 0.25rem 0 0.25rem 0.75rem;
    font-size: 0.9rem;
}

.megamenu__link {
    display: block;
    padding: 4px 0;
    font-family: 'Montserrat', sans-serif;
    font-size: 12px;
    line-height: 1.4;
    font-weight: 500;
    color: var(--text-dark-low);
    text-decoration: none;
    transition: color 0.25s ease, padding-left 0.25s ease;
    min-width: 0;
    overflow-wrap: anywhere;
    word-wrap: break-word;
}

.megamenu__link:hover {
    color: var(--primary-color);
    padding-left: 3px;
}

/* Mega menü linkleri: yalnızca normal akış */
.megamenu__inner a.megamenu__cat,
.megamenu__inner a.megamenu__all,
.megamenu__inner a.megamenu__mid,
.megamenu__inner a.megamenu__link {
    position: static;
    float: none;
}

/* ---- asset / promotional ---- */
.megamenu__asset {
    position: relative;
    padding: 14px 14px 120px 14px;
    background: linear-gradient(180deg, #f8f9fa 0%, #f0f2f5 100%);
    border-left: 1px solid rgba(0, 0, 0, 0.06);
    align-self: start;
}

.megamenu__badge {
    display: inline-block;
    padding: 3px 8px;
    font-family: 'Sora', sans-serif;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.06em;
    color: #fff;
    background: var(--secondary-color);
    border-radius: 4px;
    margin-bottom: 8px;
}

.megamenu__asset-title {
    font-family: 'Sora', sans-serif;
    font-size: 14px;
    font-weight: 700;
    color: var(--text-dark-dark);
    margin: 0 0 6px;
    line-height: 1.25;
}

.megamenu__asset-desc {
    font-family: 'Montserrat', sans-serif;
    font-size: 12px;
    font-weight: 400;
    line-height: 1.45;
    color: var(--text-dark-low);
    margin: 0 0 10px;
}

.megamenu__asset-cta {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: 'Sora', sans-serif;
    font-size: 12px;
    font-weight: 600;
    color: var(--primary-color);
    text-decoration: none;
    transition: gap 0.25s ease, color 0.25s ease;
}

.megamenu__asset-cta:hover {
    color: var(--primary-color-dark);
    gap: 10px;
}

.megamenu__asset-img {
    position: absolute;
    right: 12px;
    bottom: 12px;
    left: 12px;
    top: auto;
    width: calc(100% - 24px);
    height: 96px;
    border-radius: 8px;
    overflow: hidden;
}

.megamenu__asset-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.megamenu__footer {
    padding: 8px 16px 10px;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
    background: #fafbfc;
}

.megamenu__cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: 'Sora', sans-serif;
    font-size: 12px;
    font-weight: 600;
    color: var(--primary-color);
    text-decoration: none;
    transition: gap 0.25s ease, color 0.25s ease;
}

.megamenu__cta:hover {
    color: var(--primary-color-dark);
    gap: 12px;
}

/* megamenu: navbar container'a hizalı, tam genişlik */
.navbar .container {
    position: relative;
}

.has-megamenu .megamenu {
    left: 0;
    right: 0;
    transform: translateY(-6px);
}

.has-megamenu:hover .megamenu {
    transform: translateY(0);
}

.has-dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: calc(100% + 5px);
    left: 50%;
    transform: translateX(-50%) translateY(15px);
    min-width: 280px;
    background: rgba(252, 252, 252, 0.97);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-radius: 16px;
    padding: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.04), 0 20px 40px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(0, 0, 0, 0.06);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.dropdown-menu::before {
    content: '';
    position: absolute;
    top: -25px;
    left: 0;
    right: 0;
    height: 30px;
}

.has-dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateX(-50%) translateY(10px);
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border-radius: 10px;
    text-decoration: none;
    transition: all 0.2s ease;
}

.dropdown-item:hover {
    background: var(--primary-color-low);
}

.dropdown-item i {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: var(--primary-color-low);
    color: var(--primary-color);
    flex-shrink: 0;
    transition: all 0.2s ease;
}

.dropdown-item:hover i {
    background: var(--primary-color);
    color: #fff;
}

.dropdown-title {
    display: block;
    font-family: 'Sora', sans-serif;
    font-size: 13.5px;
    font-weight: 600;
    color: var(--text-dark);
    letter-spacing: -0.01em;
    line-height: 1.3;
}

.dropdown-desc {
    display: block;
    font-family: 'Sora', sans-serif;
    font-size: 12px;
    font-weight: 400;
    color: var(--text-dark-low);
    margin-top: 1px;
    line-height: 1.3;
}


.nav-right {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

/* Ürün arama (navbar) — beyaz arka plan */
.nav-search {
    display: flex;
    align-items: stretch;
    gap: 0;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.1);
    background: #fff;
    min-width: 0;
    max-width: 220px;
}

.navbar.scrolled .nav-search {
    border-color: rgba(2, 119, 189, 0.22);
    background: #fff;
}

.nav-search__input {
    width: 100%;
    min-width: 0;
    padding: 8px 10px;
    border: none;
    background: #fff;
    font-family: 'Sora', sans-serif;
    font-size: 13px;
    color: var(--text-dark, #1a1a1a);
    outline: none;
}

.navbar.scrolled .nav-search__input {
    color: var(--text-dark);
}

.nav-search__input::placeholder {
    color: var(--text-dark-low, rgba(26, 26, 26, 0.45));
}

.navbar.scrolled .nav-search__input::placeholder {
    color: var(--text-dark-low);
}

.nav-search__btn {
    flex-shrink: 0;
    width: 40px;
    border: none;
    background: rgba(2, 119, 189, 0.08);
    color: var(--primary-color, #0277bd);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
}

.navbar.scrolled .nav-search__btn {
    background: rgba(2, 119, 189, 0.1);
    color: var(--primary-color);
}

.nav-search__btn:hover {
    background: rgba(2, 119, 189, 0.16);
}

.navbar.scrolled .nav-search__btn:hover {
    background: rgba(2, 119, 189, 0.18);
}

/* Mobil menü üstü arama */
.nav-mobile-search {
    display: none;
    gap: 0;
    margin: 0 20px 16px;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid rgba(2, 119, 189, 0.15);
    background: var(--card-bg, #fff);
}

.nav-mobile-search__input {
    flex: 1;
    min-width: 0;
    padding: 12px 14px;
    border: none;
    font-family: 'Sora', sans-serif;
    font-size: 14px;
    outline: none;
}

.nav-mobile-search__btn {
    flex-shrink: 0;
    width: 48px;
    border: none;
    background: var(--primary-color-low);
    color: var(--primary-color);
    cursor: pointer;
}

.nav-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 9px 20px;
    font-family: 'Sora', sans-serif;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    border-radius: 10px;
    transition: all 0.25s ease;
    white-space: nowrap;
    letter-spacing: -0.01em;
}

.nav-btn-ghost {
    color: rgba(255, 255, 255, 0.9);
    background: transparent;
}

.nav-btn-ghost:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
}

.navbar.scrolled .nav-btn-ghost {
    color: var(--text-dark);
}

.navbar.scrolled .nav-btn-ghost:hover {
    color: var(--primary-color);
    background: var(--primary-color-low);
}

.nav-btn-primary {
    color: #fff;
    background: var(--primary-color);
    box-shadow: 0 2px 8px rgba(2, 119, 189, 0.3);
}

.nav-btn-primary:hover {
    background: var(--primary-color-dark);
    box-shadow: 0 4px 16px rgba(2, 119, 189, 0.4);
    transform: translateY(-1px);
}


.nav-hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    border-radius: 8px;
    transition: background 0.2s ease;
}

.nav-hamburger:hover {
    background: rgba(255, 255, 255, 0.1);
}

.navbar.scrolled .nav-hamburger:hover {
    background: var(--primary-color-low);
}

.nav-hamburger span {
    display: block;
    width: 20px;
    height: 2px;
    background: #fff;
    border-radius: 2px;
    transition: all 0.3s ease;
}

.navbar.scrolled .nav-hamburger span {
    background: var(--text-dark);
}

.nav-hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.nav-hamburger.active span:nth-child(2) {
    opacity: 0;
}

.nav-hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}


/* ========== MOBİL SIDEBAR ========== */

.nav-mobile {
    position: fixed;
    inset: 0;
    z-index: 9999;
    pointer-events: none;
    visibility: hidden;
    transition: visibility 0.3s ease;
}

.nav-mobile.is-open {
    pointer-events: auto;
    visibility: visible;
}

.nav-mobile__overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    opacity: 0;
    transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-mobile.is-open .nav-mobile__overlay {
    opacity: 1;
}

.nav-mobile__panel {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: min(320px, 88vw);
    max-width: 100%;
    background: #fff;
    box-shadow: -4px 0 24px rgba(0, 0, 0, 0.12);
    display: flex;
    flex-direction: column;
    padding: 72px 24px 32px;
    transform: translateX(100%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
}

.nav-mobile.is-open .nav-mobile__panel {
    transform: translateX(0);
}

.nav-mobile__close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    border-radius: 10px;
    color: var(--text-dark);
    cursor: pointer;
    font-size: 18px;
    transition: background 0.2s ease, color 0.2s ease;
}

.nav-mobile__close:hover {
    background: var(--primary-color-low);
    color: var(--primary-color);
}

.nav-mobile__nav {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 24px;
}

.nav-mobile__link {
    display: block;
    padding: 14px 16px;
    font-family: 'Sora', sans-serif;
    font-size: 15px;
    font-weight: 500;
    color: var(--text-dark);
    text-decoration: none;
    border-radius: 10px;
    transition: background 0.2s ease, color 0.2s ease;
}

.nav-mobile__link:hover {
    background: var(--primary-color-low);
    color: var(--primary-color);
}

.nav-mobile__group {
    border-radius: 10px;
    overflow: hidden;
}

.nav-mobile__toggle {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    font-family: 'Sora', sans-serif;
    font-size: 15px;
    font-weight: 500;
    color: var(--text-dark);
    background: transparent;
    border: none;
    cursor: pointer;
    text-align: left;
    transition: background 0.2s ease, color 0.2s ease;
}

.nav-mobile__toggle::after {
    content: '\f078';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 11px;
    color: var(--text-dark-low);
    transition: transform 0.25s ease;
}

.nav-mobile__group.is-open .nav-mobile__toggle::after {
    transform: rotate(180deg);
}

.nav-mobile__toggle:hover {
    background: var(--primary-color-low);
    color: var(--primary-color);
}

.nav-mobile__sub {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.3s ease;
}

.nav-mobile__group.is-open .nav-mobile__sub {
    grid-template-rows: 1fr;
}

.nav-mobile__sub > div {
    overflow: hidden;
    min-height: 0;
}

.nav-mobile__sub a {
    display: block;
    padding: 12px 16px 12px 28px;
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-dark-low);
    text-decoration: none;
    border-left: 2px solid transparent;
    transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.nav-mobile__sub a:hover {
    color: var(--primary-color);
    border-left-color: var(--primary-color);
    background: rgba(2, 119, 189, 0.05);
}

.nav-mobile__sub a {
    padding: 10px 16px 10px 28px;
}

.nav-mobile__actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: auto;
    padding-top: 20px;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
}

.nav-mobile__btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px 20px;
    font-family: 'Sora', sans-serif;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    border-radius: 10px;
    transition: all 0.2s ease;
}

.nav-mobile__btn--ghost {
    color: var(--primary-color);
    background: var(--primary-color-low);
}

.nav-mobile__btn--ghost:hover {
    background: rgba(2, 119, 189, 0.15);
}

.nav-mobile__btn--primary {
    color: #fff;
    background: var(--primary-color);
}

.nav-mobile__btn--primary:hover {
    background: var(--primary-color-dark);
}

@media (max-width: 1024px) {
    .nav-center {
        display: none;
    }

    .nav-right {
        display: none;
    }

    .nav-mobile-search {
        display: flex;
        align-items: stretch;
    }

    .nav-hamburger {
        display: flex;
    }

    .megamenu {
        display: none;
    }
}

@media (max-width: 480px) {
    .navbar {
        padding: 10px 16px;
        top: 10px;
    }

    .navbar .container {
        padding: 0 10px;
        height: 50px;
    }

    .nav-left .logo img {
        height: 44px;
    }

    .nav-mobile__panel {
        width: 100%;
        padding: 64px 20px 28px;
    }

    .nav-mobile__close {
        top: 16px;
        right: 16px;
        width: 40px;
        height: 40px;
    }
}

@media (max-width: 1300px) {
    .megamenu__body {
        grid-template-columns: minmax(0, 1fr) minmax(180px, 220px);
        min-width: 0;
    }

    .megamenu__cols {
        padding: 20px 14px 20px 16px;
    }
}
