/* ==================== МОБИЛЬНОЕ МЕНЮ ==================== */

/* Кнопка бургер-меню */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 28px;
    cursor: pointer;
    padding: 10px;
    color: #333;
    transition: color 0.3s;
}

.mobile-menu-btn:hover {
    color: #007bff;
}

.mobile-menu-btn.active {
    color: #007bff;
}

/* Overlay (затемнение фона) */
.mobile-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 998;
    opacity: 0;
    transition: opacity 0.3s;
}

.mobile-overlay.active {
    display: block;
    opacity: 1;
}

/* Мобильная навигация */
.mobile-nav {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: white;
    transform: translateX(-100%);
    transition: transform 0.3s;
    overflow-y: auto;
    z-index: 999;
    padding: 80px 0 20px 0;
}

.mobile-nav.active {
    transform: translateX(0);
}

/* Пункты меню */
.mobile-nav .nav-item {
    border-bottom: 1px solid #f0f0f0;
}

.mobile-nav .nav-link {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    color: #333;
    text-decoration: none;
    font-weight: 500;
    transition: background 0.2s;
}

.mobile-nav .nav-link:hover {
    background: #f8f9fa;
}

/* Стрелки для пунктов с подменю */
.mobile-nav .nav-link.has-dropdown::after {
    content: '▼';
    font-size: 12px;
    transition: transform 0.3s;
}

.mobile-nav .nav-item.active > .nav-link.has-dropdown::after {
    transform: rotate(180deg);
}

/* Dropdown - первый уровень */
.mobile-nav .dropdown {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s;
    background: #f8f9fa;
}

.mobile-nav .nav-item.active > .dropdown {
    max-height: 1000px;
}

/* Ссылки в dropdown */
.mobile-nav .dropdown-link {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 30px;
    color: #333;
    text-decoration: none;
    transition: background 0.2s;
}

.mobile-nav .dropdown-link:hover {
    background: #e9ecef;
}

/* Стрелки для брендов с коллекциями */
.mobile-nav .dropdown-link.has-submenu::after {
    content: '▼';
    font-size: 12px;
    transition: transform 0.3s;
}

.mobile-nav .dropdown-item.active > .dropdown-link.has-submenu::after {
    transform: rotate(180deg);
}

/* Submenu - второй уровень */
.mobile-nav .submenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s;
    background: #e9ecef;
}

.mobile-nav .dropdown-item.active > .submenu {
    max-height: 500px;
}

/* Ссылки в submenu */
.mobile-nav .submenu-link {
    display: block;
    padding: 10px 40px;
    color: #333;
    text-decoration: none;
    transition: background 0.2s;
}

.mobile-nav .submenu-link:hover {
    background: #dee2e6;
}

/* Показываем мобильное меню на маленьких экранах */
@media (max-width: 768px) {
    /* Скрываем десктопное меню */
    .desktop-nav {
        display: none !important;
    }
    
    /* Показываем кнопку бургера */
    .mobile-menu-btn {
        display: block;
    }
    
    /* Показываем мобильное меню */
    .mobile-nav {
        display: block;
    }
}

/* Десктопная версия */
@media (min-width: 769px) {
    .mobile-menu-btn {
        display: none !important;
    }
    
    .mobile-nav {
        display: none !important;
    }
    
    .mobile-overlay {
        display: none !important;
    }
}