/* Mega Menu - Markalar ve Kategoriler */

/* Mega Menu Base */
.nav-dropdown {
    position: relative;
    display: inline-block;
}

.nav-dropdown > .nav-link {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
}

.nav-dropdown > .nav-link::after {
    content: '▼';
    font-size: 10px;
    transition: transform 0.2s;
}

.nav-dropdown:hover > .nav-link::after {
    transform: rotate(180deg);
}

/* Mega Menu Container */
.mega-menu {
    display: none;
    position: fixed;
    top: 240px;
    left: 50%;
    transform: translateX(-50%);
    background: #FFFFFF;
    border: 1px solid #e5e5e5;
    border-radius: 0;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    z-index: 9999;
    width: 95vw;
    max-width: 1500px;
    animation: fadeInDown 0.2s ease-out;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

.nav-dropdown:hover .mega-menu {
    display: block;
}

.mega-menu-content {
    padding: 40px;
    max-height: 600px;
    overflow-y: scroll;
    scrollbar-gutter: stable;
}

/* Scroll bar stilleri - Görünür ve kalın */
.mega-menu-content::-webkit-scrollbar {
    width: 12px;
}

.mega-menu-content::-webkit-scrollbar-track {
    background: #e0e0e0;
    border-radius: 6px;
    border: 1px solid #d0d0d0;
}

.mega-menu-content::-webkit-scrollbar-thumb {
    background: #3B6BA8;
    border-radius: 6px;
    border: 2px solid #f5f5f5;
    box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.3);
}

.mega-menu-content::-webkit-scrollbar-thumb:hover {
    background: #2E5C8E;
    box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.5);
}

/* Markalar Mega Menu */
.brands-mega-menu {
    width: 100%;
}

.brands-mega-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 32px;
}

.brands-mega-grid-3col {
    grid-template-columns: repeat(3, 1fr);
}

.brands-mega-grid-4col {
    grid-template-columns: repeat(4, 1fr);
}

.brand-column h4 {
    font-size: 13px;
    font-weight: 700;
    color: var(--bunte-gray, #666666);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 0 0 16px 0;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--bunte-light-gray, #CCCCCC);
}

.brand-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.brand-list li {
    margin-bottom: 8px;
}

.brand-list a {
    color: #333333;
    text-decoration: none;
    font-size: 14px;
    display: block;
    padding: 8px 12px;
    border-radius: 0;
    transition: all 0.2s;
    font-weight: 500;
}

.brand-list a:hover {
    background: #333333;
    color: #FFFFFF;
    transform: translateX(4px);
}

.view-all-brands {
    display: block;
    text-align: center;
    margin-top: 24px;
    padding: 12px 24px;
    background: var(--bunte-orange, #3B6BA8);
    color: var(--bunte-white, #FFFFFF);
    text-decoration: none;
    border-radius: 6px;
    font-weight: 600;
    transition: all 0.2s;
}

.view-all-brands:hover {
    background: #2E5C8E;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 107, 168, 0.3);
}

/* Kategoriler Mega Menu */
.categories-mega-menu {
    width: 850px;
    max-width: calc(100vw - 40px);
}

.categories-mega-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 32px;
}

.category-column h4 {
    font-size: 13px;
    font-weight: 700;
    color: var(--bunte-gray, #666666);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 0 0 16px 0;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--bunte-light-gray, #CCCCCC);
}

.category-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.category-list li {
    margin-bottom: 8px;
}

.category-list a {
    color: #333333;
    text-decoration: none;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    border-radius: 0;
    transition: all 0.2s;
    font-weight: 500;
}

.category-list a:hover {
    background: #333333;
    color: #FFFFFF;
}

.category-count {
    font-size: 12px;
    color: #666666;
    background: #E5E5E5;
    padding: 2px 8px;
    border-radius: 12px;
    font-weight: 600;
}

.category-list a:hover .category-count {
    background: #FFFFFF;
    color: #333333;
}

.view-all-categories {
    display: block;
    text-align: center;
    margin-top: 24px;
    padding: 12px 24px;
    background: var(--bunte-orange, #3B6BA8);
    color: var(--bunte-white, #FFFFFF);
    text-decoration: none;
    border-radius: 6px;
    font-weight: 600;
    transition: all 0.2s;
}

.view-all-categories:hover {
    background: #2E5C8E;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 107, 168, 0.3);
}

/* Alt kategoriler */
.subcategory-list {
    list-style: none;
    padding: 0 0 0 20px;
    margin: 8px 0 0 0;
}

.subcategory-list li {
    margin-bottom: 6px;
}

.subcategory-list a {
    font-size: 13px;
    color: var(--bunte-gray, #666666);
    padding: 6px 12px;
}

.subcategory-list a:hover {
    color: var(--bunte-orange, #3B6BA8);
}

/* Mobile Responsive */
@media (max-width: 1024px) {
    .mega-menu {
        min-width: 600px;
    }
    
    .brands-mega-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
    }
    
    .categories-mega-grid {
        grid-template-columns: 1fr 1fr;
        gap: 24px;
    }
}

@media (max-width: 768px) {
    .mega-menu {
        position: fixed;
        top: auto;
        left: 0;
        right: 0;
        bottom: 0;
        transform: none;
        min-width: 100%;
        max-height: 80vh;
        overflow-y: auto;
        border-radius: 16px 16px 0 0;
        animation: slideUp 0.3s ease-out;
    }
    
    @keyframes slideUp {
        from {
            transform: translateY(100%);
        }
        to {
            transform: translateY(0);
        }
    }
    
    .mega-menu-content {
        padding: 24px;
    }
    
    .brands-mega-grid,
    .categories-mega-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    
    .nav-dropdown:hover .mega-menu {
        display: none;
    }
    
    .nav-dropdown.active .mega-menu {
        display: block;
    }
}

/* Hover efektleri */
.mega-menu::before {
    content: '';
    position: absolute;
    top: -8px;
    left: 0;
    right: 0;
    height: 8px;
    background: transparent;
}

/* Loading state */
.mega-menu.loading {
    min-height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mega-menu.loading::after {
    content: 'Yükleniyor...';
    font-size: 14px;
    color: var(--bunte-gray, #666666);
}
