/* KALE ÇELİK KAPI - HEADER GLOBAL CSS */

:root {
    --primary-color: #4f264bff;
    --primary-hover: #4e075fb7;
    --shadow-light: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-medium: 0 8px 20px rgba(0, 0, 0, 0.12);
    --shadow-heavy: 0 12px 40px rgba(0, 0, 0, 0.15);
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: #f8f9fa;
}

/* MODERN NAVBAR STİLLERİ */
.navbar {
    background: #fef7ed !important;
    backdrop-filter: blur(20px);
    box-shadow: inset 0 0 0 1px rgba(196, 30, 58, 0.08),
        0 2px 8px rgba(196, 30, 58, 0.08);
    padding: 0 !important;
    position: fixed;
    top: 2px;
    left: 0;
    right: 0;
    width: 100%;
    height: 70px !important;
    min-height: 70px;
    max-height: 70px;
    z-index: 1050;
    transition: box-shadow 0.3s ease, transform 0.3s ease;
    overflow: visible !important;
}

/* Scroll sırasında gölge artışı */
.navbar.scrolled {
    box-shadow: inset 0 0 0 1px rgba(196, 30, 58, 0.1),
        0 3px 15px rgba(196, 30, 58, 0.12);
}

/* Body için padding ekle (navbar + borders yüksekliği kadar) */
body {
    padding-top: 72px;
}

/* Navbar'ı relative yap ki absolute çocuklar çalışsın */
.navbar .container {
    position: relative;
    height: 70px;
    padding-left: 0 !important;
    padding-right: 0 !important;
    max-width: 100% !important;
    overflow: visible !important;
}

/* Navbar için overflow ayarı */
.navbar {
    overflow: visible !important;
}

.navbar-brand {
    font-weight: 700;
    font-size: 1.8rem;
    color: white !important;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    padding-left: 15px;
}

.navbar-brand img {
    height: 50px;
    width: auto;
    object-fit: contain;
}

.navbar-brand:hover {
    transform: translateY(-50%) scale(1.05);
    text-shadow: 0 4px 8px rgba(0, 0, 0, 0.4);
}

.navbar-nav .nav-link {
    font-weight: 500;
    color: #2d3748 !important;
    border-radius: 25px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    background: rgba(196, 30, 58, 0.05);
}

/* Tüm nav-item'ları absolute yap ve dikey ortala */
.navbar-nav .nav-item {
    position: absolute !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
}

/* Ürünler - Logo sonrası */
.nav-products {
    left: 450px !important;
}

/* Sayfalar - Ürünler sonrası */
.nav-home {
    left: 620px !important;
}

/* İletişim - Ürünler sonrası */
.nav-contact {
    left: 790px !important;
}

/* Ürün Ara - İletişim sonrası */
.nav-search {
    right: 260px !important;
}

/* Favorilerim - En sağda */
.nav-favorites {
    right: 60px !important;
}

/* TÜM BUTONLAR İÇİN GENİŞLİK AYARLAMA */
.navbar-nav .nav-link {
    min-width: 120px !important;
    padding: 0.5rem 1.5rem !important;
    text-align: center;
    white-space: nowrap;
    display: inline-block;
    line-height: 1.2 !important;
    vertical-align: middle;
}

/* Özel butonlar için farklı genişlikler */
.nav-home .nav-link {
    min-width: 120px !important;
}

.nav-products .nav-link {
    min-width: 120px !important;
}

.nav-contact .nav-link {
    min-width: 110px !important;
}

.nav-favorites .nav-link {
    min-width: 140px !important;
}

.navbar-nav .nav-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(196, 30, 58, 0.2),
        transparent
    );
    transition: left 0.5s;
}

.navbar-nav .nav-link:hover::before {
    left: 100%;
}

.navbar-nav .nav-link:hover {
    color: white !important;
    background: linear-gradient(135deg, #c41e3a 0%, #e53e3e 100%) !important;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(196, 30, 58, 0.3) !important;
}

.navbar-nav .nav-link.active {
    background: linear-gradient(135deg, #c41e3a 0%, #e53e3e 100%);
    color: white !important;
    box-shadow: 0 3px 10px rgba(196, 30, 58, 0.3);
}

.navbar-toggler {
    border: 2px solid rgba(196, 30, 58, 0.3);
    padding: 0.5rem 0.75rem;
    background: rgba(196, 30, 58, 0.05);
    border-radius: 8px;
    transition: all 0.3s ease;
}

.navbar-toggler:hover {
    background: rgba(196, 30, 58, 0.1);
    border-color: rgba(196, 30, 58, 0.5);
}

.navbar-toggler:focus {
    box-shadow: 0 0 0 0.2rem rgba(196, 30, 58, 0.25);
    outline: none;
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28196, 30, 58, 1%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2.5' d='m4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
    width: 24px;
    height: 24px;
}

/* Mobile Header Actions */
.mobile-header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 1100;
    pointer-events: all;
}

/* Mobile Search Button - KALDIRILDI, artık sidebar içinde arama var */
/*
.mobile-search-btn {
    background: linear-gradient(135deg, #c41e3a 0%, #e53e3e 100%);
    border: none;
    border-radius: 8px;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(196, 30, 58, 0.3);
}

.mobile-search-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(196, 30, 58, 0.4);
}

.mobile-search-btn:active {
    transform: scale(0.95);
}
*/

/* Dropdown Styles */
.dropdown-menu {
    border: none;
    box-shadow: 0 15px 35px rgba(196, 30, 58, 0.15);
    border-radius: 15px;
    padding: 0.5rem 0;
    margin-top: 0;
    background: white;
    min-width: 260px;
    max-width: 320px;
    z-index: 1060;
    position: absolute;
    left: 0;
}

/* Navbar dropdown özel stilleri */
.navbar-nav .dropdown-menu {
    background: white;
    border: 2px solid rgba(196, 30, 58, 0.1);
    display: none;
}

/* Click ile dropdown açma */
.navbar-nav .dropdown-menu.show {
    display: block !important;
}

/* Hover ile dropdown açma - KALDIRILDI, sadece click ile açılsın */
/* .navbar-nav .dropdown:hover > .dropdown-menu {
    display: block;
} */

/* Dropdown'un görünür olduğunda animasyon */
.navbar-nav .dropdown-menu {
    animation: fadeIn 0.2s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Sayfalar Dropdown - Özel Genişlik (Konfiguratör kutusu için) */
.dropdown-menu-sayfalar {
    min-width: 250px !important;
    max-width: 300px !important;
}

/* 2 Kolonlu Dropdown için özel stil */
.dropdown-menu-two-columns {
    min-width: 500px !important;
    padding: 1rem !important;
}

.dropdown-menu-two-columns .row {
    margin: 0;
}

.dropdown-menu-two-columns .col-6 {
    padding: 0 0.5rem;
}

.dropdown-menu-two-columns h6 {
    font-size: 0.85rem;
    font-weight: 600;
    color: #c41e3a;
    margin-bottom: 0.5rem;
    padding-left: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* 3 Kolonlu Dropdown için özel stil */
.dropdown-menu-three-columns {
    min-width: 650px !important;
    padding: 1rem !important;
}

.dropdown-menu-three-columns .row {
    margin: 0;
}

.dropdown-menu-three-columns .col-4 {
    padding: 0 0.5rem;
}

.dropdown-menu-three-columns h6 {
    font-size: 0.85rem;
    font-weight: 600;
    color: #c41e3a;
    margin-bottom: 0.5rem;
    padding-left: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.dropdown-item {
    padding: 0.75rem 1.5rem;
    font-weight: 500;
    color: #495057;
    transition: all 0.3s ease;
    border-radius: 8px;
    margin: 0 0.5rem;
    display: flex;
    align-items: center;
    white-space: nowrap;
    max-width: calc(100% - 1rem);
    overflow: hidden;
}

.dropdown-item i {
    color: #c41e3a;
    width: 20px;
}

.dropdown-item:hover {
    background: linear-gradient(135deg, #fef7ed 0%, #fff5f0 100%);
    color: #c41e3a;
    transform: translateX(4px);
}

/* ÖZEL: Ürün Konfiguratör Stili - Üst-Alt Çizgi ile Vurgulu */
.dropdown-item.konfigurator-special {
    border: 3px solid #c41e3a;
    background: linear-gradient(135deg, #fff9f0 0%, #fff5eb 100%);
    font-weight: 600;
    color: #c41e3a;
    margin: 0.5rem 1.2rem;
    padding: 0.6rem 1rem;
    box-shadow: 0 2px 8px rgba(196, 30, 58, 0.1);
    max-width: calc(100% - 2.4rem);
    box-sizing: border-box;
    position: relative;
    z-index: 10;
}

.dropdown-item.konfigurator-special:hover {
    background: linear-gradient(135deg, #e85d73 0%, #d4425a 100%);
    border-color: #000;
    color: white;
    transform: translateX(6px) scale(1.01);
    box-shadow: 0 4px 12px rgba(196, 30, 58, 0.3);
    margin: 0.5rem 1.2rem;
}

.dropdown-item.konfigurator-special:hover i {
    color: white;
}

.dropdown-item.konfigurator-special i {
    color: #c41e3a;
}

/* ÖZEL: Butik & Dinamik Farkı Stili - Konfiguratör ile aynı stil */
.dropdown-item.butik-dinamik-special {
    border: 3px solid #c41e3a;
    background: linear-gradient(135deg, #fff9f0 0%, #fff5eb 100%);
    font-weight: 600;
    color: #c41e3a;
    margin: 0.5rem 1.2rem;
    padding: 0.6rem 1rem;
    box-shadow: 0 2px 8px rgba(196, 30, 58, 0.1);
    max-width: calc(100% - 2.4rem);
    box-sizing: border-box;
    position: relative;
    z-index: 10;
}

.dropdown-item.butik-dinamik-special:hover {
    background: linear-gradient(135deg, #e85d73 0%, #d4425a 100%);
    border-color: #000;
    color: white;
    transform: translateX(6px) scale(1.01);
    box-shadow: 0 4px 12px rgba(196, 30, 58, 0.3);
    margin: 0.5rem 1.2rem;
}

.dropdown-item.butik-dinamik-special:hover i {
    color: white;
}

.dropdown-item.butik-dinamik-special i {
    color: #c41e3a;
}

/* Tablet/Medium Desktop optimizasyonu (992px - 1200px) */
@media (min-width: 992px) and (max-width: 1199.98px) {
    /* Logo küçült */
    .navbar-brand {
        font-size: 1.5rem !important;
    }

    .navbar-brand img {
        height: 45px !important;
    }

    /* Menü pozisyonlarını ayarla */
    .nav-home {
        left: 400px !important;
    }

    .nav-products {
        left: 510px !important;
    }

    /* Buton boyutlarını küçült */
    .navbar-nav .nav-link {
        min-width: 100px !important;
        padding: 0.5rem 1.2rem !important;
        font-size: 0.9rem;
    }

    .nav-home .nav-link {
        min-width: 100px !important;
    }

    .nav-products .nav-link {
        min-width: 100px !important;
    }
}

/* ====================================
   RESPONSIVE - MOBIL (991.98px ve altı)
   ==================================== */
@media (max-width: 991.98px) {
    .navbar {
        height: 60px !important;
        min-height: 60px !important;
        max-height: 60px !important;
        top: 2px !important;
    }

    .navbar .container {
        position: relative !important;
        height: 60px !important;
        flex-wrap: nowrap !important;
        display: flex !important;
        align-items: center !important;
    }

    /* Logo mobilde sol üstte */
    .navbar-brand {
        position: relative !important;
        left: 0 !important;
        top: 0 !important;
        transform: none !important;
        padding: 0 0 0 15px !important;
        margin: 0 !important;
        flex-shrink: 0 !important;
    }

    .navbar-brand img {
        height: 40px !important;
    }

    .mobile-header-actions {
        display: flex;
        align-items: center;
        gap: 8px;
    }

    .navbar-toggler {
        position: relative !important;
        right: auto !important;
        top: auto !important;
        transform: none !important;
        margin: 0 !important;
        padding: 0.4rem 0.6rem !important;
    }

    /* Mobile header actions grup olarak - ABSOLUTE pozisyon (parent relative) */
    .mobile-header-actions {
        position: absolute !important;
        right: 15px !important;
        top: 50% !important;
        transform: translateY(-50%) !important;
        gap: 8px !important;
        z-index: 1100 !important;
    }

    /* Mobil buton boyutları */
    .navbar-toggler {
        width: 36px !important;
        height: 36px !important;
        padding: 0.35rem 0.5rem !important;
    }

    .navbar-toggler-icon {
        width: 20px !important;
        height: 20px !important;
    }

    /* Desktop menüyü gizle */
    .desktop-menu {
        display: none !important;
    }

    /* Body padding */
    body {
        padding-top: 62px !important;
    }
}

.navbar-nav .nav-link {
    padding: 12px 16px;
    border-radius: 8px;
    margin: 2px 0;
    transition: all 0.2s ease;
    color: #333 !important;
}

.navbar-nav .nav-link:hover {
    background: linear-gradient(135deg, #c41e3a 0%, #e53e3e 100%);
    color: #c41e3a !important;
    transform: translateX(4px);
}

/* Desktop için hover beyaz */
@media (min-width: 992px) {
    .navbar-nav .nav-link:hover {
        color: white !important;
    }
}

.navbar-nav .nav-link.active {
    background: linear-gradient(135deg, #c41e3a 0%, #a01628 100%);
    color: white !important;
}

/* Ekstra küçük telefonlar */
@media (max-width: 480px) {
    .navbar {
        height: 56px !important;
        min-height: 56px !important;
        max-height: 56px !important;
        top: 2px !important;
    }

    .navbar .container {
        height: 56px !important;
    }

    .navbar-brand {
        padding: 0 0 0 12px !important;
    }

    .navbar-brand img {
        height: 35px !important;
    }

    .mobile-header-actions {
        right: 12px !important;
        top: 50% !important;
        transform: translateY(-50%) !important;
        gap: 6px !important;
        z-index: 1100 !important;
    }

    .navbar-toggler {
        width: 32px !important;
        height: 32px !important;
        padding: 0.3rem 0.4rem !important;
    }

    .navbar-toggler-icon {
        width: 18px !important;
        height: 18px !important;
    }

    body {
        padding-top: 60px !important;
    }
}

/* Dropdown açılma animasyonu */
.dropdown-menu {
    animation: dropdownFadeIn 0.3s ease-out;
}

@keyframes dropdownFadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.dropdown-item:hover {
    color: #495057;
    transform: translateX(5px);
}

.dropdown-item i {
    width: 20px;
    text-align: center;
}

/* =================================================================
   ÜRÜN ARAMA DROPDOWN KUTUSU
   ================================================================= */
.search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(3px);
    z-index: 1040;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.search-overlay.active {
    opacity: 1;
    visibility: visible;
}

.search-dropdown {
    position: fixed;
    top: 72px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 1200px;
    background: white;
    box-shadow: 0 15px 40px rgba(196, 30, 58, 0.2);
    border-radius: 0 0 15px 15px;
    z-index: 1041;
    max-height: 0;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.search-dropdown.active {
    max-height: 500px;
}

.search-dropdown-container {
    width: 100%;
}

.search-dropdown-content {
    padding: 25px 30px;
    position: relative;
}

.search-close-btn {
    position: absolute;
    top: 15px;
    right: 20px;
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, #c41e3a 0%, #e53e3e 100%);
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10;
}

.search-close-btn:hover {
    transform: rotate(90deg) scale(1.1);
    box-shadow: 0 5px 15px rgba(196, 30, 58, 0.4);
}

.search-input-container {
    position: relative;
    margin-bottom: 15px;
}

.search-icon {
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: #c41e3a;
    font-size: 18px;
}

.search-box-input {
    width: 100%;
    padding: 15px 50px;
    font-size: 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    outline: none;
    transition: all 0.3s ease;
    background: #f8f9fa;
}

.search-box-input:focus {
    border-color: #c41e3a;
    background: white;
    box-shadow: 0 0 0 4px rgba(196, 30, 58, 0.1);
}

.search-loading {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: #c41e3a;
    font-size: 18px;
}

.search-results-box {
    max-height: 280px;
    overflow-y: auto;
}

.search-results-box::-webkit-scrollbar {
    width: 8px;
}

.search-results-box::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.search-results-box::-webkit-scrollbar-thumb {
    background: #c41e3a;
    border-radius: 10px;
}

.search-placeholder,
.search-no-results {
    text-align: center;
    padding: 30px 20px;
    color: #4a5568;
}

.search-placeholder i,
.search-no-results i {
    font-size: 40px;
    color: #cbd5e0;
    margin-bottom: 12px;
    display: block;
}

.search-placeholder p,
.search-no-results p {
    font-size: 0.95rem;
    margin: 0;
}

.search-results-grid {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.search-result-item {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 15px;
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.search-result-item:hover {
    background: white;
    border-color: #c41e3a;
    transform: translateX(5px);
    box-shadow: 0 5px 20px rgba(196, 30, 58, 0.15);
}

.search-result-image {
    flex-shrink: 0;
    width: 80px;
    height: 80px;
    border-radius: 12px;
    overflow: hidden;
    background: white;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
}

.search-result-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.search-result-info {
    flex: 1;
}

.search-result-info h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 5px;
}

.search-result-code {
    font-size: 0.9rem;
    color: #c41e3a;
    font-weight: 600;
    margin-bottom: 5px;
}

.search-result-type {
    font-size: 0.85rem;
    color: #718096;
    margin-bottom: 8px;
}

.search-result-price {
    font-size: 1rem;
    font-weight: 700;
    color: #c41e3a;
}

.search-result-arrow {
    flex-shrink: 0;
    color: #c41e3a;
    font-size: 20px;
    transition: all 0.3s ease;
}

.search-result-item:hover .search-result-arrow {
    transform: translateX(5px);
}

@keyframes pulse {
    0%,
    100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

/* Responsive */
@media (max-width: 768px) {
    .search-dropdown.active {
        max-height: 450px;
    }

    .search-dropdown {
        width: 95%;
    }

    .search-dropdown-content {
        padding: 20px 15px;
    }

    .search-close-btn {
        top: 15px;
        right: 15px;
    }

    .search-results-box {
        max-height: 250px;
    }

    .search-result-item {
        flex-direction: column;
        text-align: center;
    }

    .search-result-arrow {
        display: none;
    }
}

/* Favoriler Badge */
.favorite-badge {
    position: absolute;
    top: -5px;
    right: -10px;
    background: #c41e3a;
    color: white;
    font-size: 0.7rem;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(196, 30, 58, 0.3);
}

/* Favoriler link'i flex yap - yan yana dursun */
.nav-favorites .nav-link {
    display: inline-flex !important;
    align-items: center;
    gap: 6px;
    flex-wrap: nowrap;
}

/* Favoriler icon boşluğu */
.nav-favorites .nav-link i {
    margin-right: 0;
}

/* Favoriler sayısı metni */
.favorite-count-text {
    color: #c41e3a;
    font-weight: 700;
    margin-left: 0;
    white-space: nowrap;
}

/* Active sayfa ise sayı beyaz olsun */
.nav-favorites .nav-link.active .favorite-count-text {
    color: white;
}

.nav-favorites .nav-link:hover .favorite-badge {
    transform: scale(1.1);
    transition: transform 0.2s ease;
}

/* RESPONSIVE MEDIA QUERIES */

/* Orta boyutlu ekranlar (1400px - 1200px) */
@media (max-width: 1400px) {
    .nav-home {
        left: 420px !important;
    }

    .nav-products {
        left: 580px !important;
    }

    .nav-contact {
        left: 740px !important;
    }

    .nav-search {
        left: 870px !important;
    }

    .nav-favorites {
        left: 1010px !important;
    }

    .navbar-nav .nav-link {
        min-width: 100px !important;
        padding: 0.5rem 1rem !important;
        font-size: 0.95rem;
    }
}

/* Küçük ekranlar (1200px ve altı) */
@media (max-width: 1200px) {
    .nav-home {
        left: 380px !important;
    }

    .nav-products {
        left: 520px !important;
    }

    .nav-contact {
        left: 660px !important;
    }

    .nav-search {
        left: 770px !important;
    }

    .nav-favorites {
        left: 890px !important;
    }

    .navbar-nav .nav-link {
        min-width: 90px !important;
        padding: 0.5rem 0.8rem !important;
        font-size: 0.9rem;
    }
}

/* ====================================
   TEMİZ KOD - ESKİ HAMBURGER MENÜ KALDIRILDI
   Artık sadece modern sidebar kullanılıyor
   ==================================== */
