/* --- ANA MENÜ (MEGA MENÜ) STİLLERİ --- */
.main-nav-wrapper {
    background-color: var(--nav-bg);
    width: 100%;
    font-family: 'Gilroy', 'Inter', sans-serif;
    position: relative;
    z-index: 100;
    /* 🎯 YENİ: Menü altına modern, hafif ve şık bir gölge ekledik */
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.06);
}

.main-nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.mobile-menu-header { display: none; } 

.main-menu {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 35px;
    width: 100%; /* İçindeki elemanların sağa yaslanabilmesi için genişliği tam yaptık */
}

.menu-item { position: static; }

.menu-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 18px 0;
    text-decoration: none;
    color: var(--nav-text);
    font-weight: 700;
    font-size: 0.95rem;
    text-transform: uppercase;
    transition: color 0.3s ease;
    position: relative;
}

.menu-link::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0;
    width: 0; height: 3px;
    background-color: var(--nav-hover);
    transition: width 0.3s ease;
}

.menu-item:hover .menu-link { color: var(--nav-hover); }
.menu-item:hover .menu-link::after { width: 100%; }

.dropdown-icon { font-size: 0.7rem; transition: transform 0.3s ease; }
.menu-item:hover .dropdown-icon { transform: rotate(180deg); }

/* --- 🎯 YENİ: SAĞ İKONLU BUTONLAR --- */
.right-buttons-wrapper {
    margin-left: auto; /* Bu kod grubu en sağa iter */
    display: flex;
    align-items: center;
    gap: 30px;
}

.header-right-btn {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--nav-text);
    transition: opacity 0.3s ease;
}

.header-right-btn:hover {
    opacity: 0.8;
}

.header-right-btn i {
    font-size: 1.8rem;
    color: var(--nav-hover, #111827);
}

.right-btn-text {
    display: flex;
    flex-direction: column;
}

.btn-top-text {
    font-size: 0.75rem;
    color: #6b7280;
    text-transform: capitalize;
}

.btn-bottom-text {
    font-size: 1rem;
    font-weight: 800;
    color: #111827;
}

/* --- MEGA MENÜ MASAÜSTÜ --- */
.mega-menu {
    position: absolute;
    top: 100%; left: 0; width: 100%;
    background-color: var(--mega-bg);
    border-top: 1px solid rgba(0,0,0,0.05);
    box-shadow: 0 15px 30px rgba(0,0,0,0.08);
    opacity: 0; visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    z-index: -1;
}

.menu-item:hover .mega-menu {
    opacity: 1; visibility: visible;
    transform: translateY(0);
    z-index: 101;
}

.mega-menu-inner {
    max-width: 1500px;
    margin: 0 auto;
    padding: 30px 20px;
    display: flex;
    gap: 50px;
}

.mega-menu-list { flex: 1; }
.mega-menu-list ul {
    list-style: none; padding: 0; margin: 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 15px 30px;
}

.mega-link {
    text-decoration: none;
    color: var(--mega-text);
    font-size: 0.95rem;
    font-weight: 500;
    transition: color 0.2s ease, padding-left 0.2s ease;
    display: block;
}
.mega-link:hover { color: var(--nav-hover); padding-left: 5px; }

.mega-menu-banner { flex-shrink: 0; width: 350px; }
.mega-menu-banner img {
    width: 100%; height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: transform 0.4s ease;
}
.mega-menu-banner img:hover { transform: scale(1.02); }

/* =========================================
   MOBİL UYUMLULUK
   ========================================= */
@media (max-width: 1024px) {
    .main-menu {
        position: fixed;
        top: 0; 
        left: -100%; 
        width: 100%; 
        max-width: 100%;
        height: 100%; 
        background-color: #ffffff !important; 
        flex-direction: column;
        align-items: flex-start;
        gap: 0;
        padding: 0;
        margin: 0;
        z-index: 1000; 
        transition: left 0.4s cubic-bezier(0.175, 0.885, 0.32, 1); 
        overflow-y: auto;
        overflow-x: hidden; 
        box-sizing: border-box;
    }

    .main-menu.mobile-active { left: 0; }

    .mobile-menu-header {
        display: flex;
        width: 100%;
        justify-content: space-between;
        align-items: center;
        padding: 20px 20px;
        background-color: #ffffff;
        border-bottom: 1px solid rgba(0,0,0,0.05); 
        position: sticky;
        top: 0;
        z-index: 10;
        box-sizing: border-box;
    }
    .mobile-menu-title { font-weight: 500; font-size: 1rem; color: #4b5563; letter-spacing: 1px; }
    .close-menu-btn { background: transparent; border: none; font-size: 1.8rem; color: #111827; cursor: pointer; padding:0; outline:none;}

    .menu-item { width: 100%; position: relative; box-sizing: border-box; }

    .menu-link {
        width: 100%;
        padding: 16px 20px;
        display: flex;
        justify-content: space-between;
        align-items: center;
        border-bottom: 1px solid rgba(0,0,0,0.04); 
        color: #374151 !important; 
        font-size: 1rem;
        font-weight: 500; 
        box-sizing: border-box;
    }
    .menu-link::after { display: none; }

    .dropdown-icon { 
        background: transparent;
        width: 24px;
        height: 24px;
        display: flex !important; 
        align-items: center;
        justify-content: center;
        border-radius: 50%;
        font-size: 0.7rem; 
        color: #6b7280; 
        border: 1px solid #9ca3af; 
        transition: all 0.3s ease; 
    }
    
    .dropdown-icon.rotate-icon { 
        transform: rotate(45deg); 
        color: #111827;
        border-color: #111827;
    }

    .mega-menu {
        position: static;
        width: 100%;
        border-top: none;
        opacity: 1;
        visibility: visible;
        transform: none;
        display: none; 
        background-color: #fcfcfc; 
        box-sizing: border-box;
    }

    .mega-menu.mobile-mega-active { display: block; }

    .mega-menu-inner { flex-direction: column; padding: 0; gap: 0; }
    .mega-menu-list ul { grid-template-columns: 1fr; gap: 0; }
    
    .mega-link { 
        padding: 14px 20px 14px 40px; 
        font-size: 0.95rem; 
        color: #6b7280 !important; 
        position: relative;
        font-weight: 400;
        border-bottom: 1px solid rgba(0,0,0,0.03); 
        display: block;
        box-sizing: border-box;
    }
    
    .mega-link::before {
        content: ''; position: absolute; left: 20px; top: 50%; transform: translateY(-50%);
        width: 8px; height: 1px; background: #cbd5e1;
    }
    
    .mega-menu-banner { display: none; } 

    /* 🎯 YENİ: SAĞ BUTONLARIN MOBİL DÜZENİ */
    .right-buttons-wrapper {
        margin-left: 0;
        margin-top: auto; /* Mobilde açılır menünün en altına iter */
        width: 100%;
        flex-direction: column;
        align-items: flex-start;
        padding: 20px;
        background-color: #f8fafc;
        border-top: 1px solid #e2e8f0;
        gap: 15px;
        box-sizing: border-box;
    }

    .header-right-btn {
        width: 100%;
    }
}