.catalog-sidebar {
    position: fixed;
    top: 0;
    left: -800px;
    width: 800px;
    height: 100vh;
    background: white;
    box-shadow: 2px 0 20px rgba(0,0,0,0.15);
    z-index: 1001;
    transition: left 0.3s ease;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.catalog-sidebar.active {
    left: 0;
}

.catalog-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid #e5e7eb;
    background: #f8f9fa;
    flex-shrink: 0;
}

.catalog-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #1f2937;
}

.catalog-close {
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    border-radius: 6px;
    color: #6b7280;
    font-size: 18px;
    transition: all 0.2s ease;
}

.catalog-close:hover {
    background: #e5e7eb;
    color: #374151;
}

.catalog-columns {
    display: flex;
    flex: 1;
    height: calc(100vh - 80px);
    min-height: 0;
}

.catalog-main-column {
    width: 300px;
    border-right: 1px solid #e5e7eb;
    overflow-y: auto;
    background: #fafafa;
    flex-shrink: 0;
}

.catalog-sub-column {
    flex: 1;
    padding: 24px;
    overflow-y: auto;
    background: white;
    min-width: 0;
}

.main-category-item {
    padding: 14px 20px;
    cursor: pointer;
    border-bottom: 1px solid #f3f4f6;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s ease;
    color: #374151;
    font-size: 14px;
    font-weight: 500;
}

.main-category-item:hover {
    background: #f3f4f6;
}

.main-category-item.active {
    background: #2563eb;
    color: white;
    font-weight: 600;
}

.category-arrow {
    font-size: 12px;
    color: #9ca3af;
    transition: transform 0.2s ease;
}

.main-category-item:hover .category-arrow {
    transform: translateX(2px);
}

.main-category-item.active .category-arrow {
    color: white;
    transform: translateX(2px);
}

.catalog-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 1000;
    backdrop-filter: blur(2px);
}

/* Стили для подкатегорий */
.subcategory-placeholder {
    text-align: center;
    padding: 60px 20px;
    color: #6b7280;
    font-size: 14px;
}

.subcategory-loading {
    text-align: center;
    padding: 40px 20px;
    color: #6b7280;
}

.loader-spinner {
    border: 3px solid #f3f3f3;
    border-top: 3px solid #2563eb;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    animation: spin 1s linear infinite;
    margin: 0 auto 15px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.no-categories {
    padding: 20px;
    text-align: center;
    color: #6b7280;
    font-size: 14px;
}

/* 🔥 НОВЫЕ СТИЛИ ДЛЯ ПОДКАТЕГОРИЙ */
.subcategories-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.subcategory-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    color: #374151;
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.subcategory-item:hover {
    background: #f8f9fa;
    text-decoration: none;
    color: #2563eb;
    border-color: #e5e7eb;
}

.subcategory-name {
    flex: 1;
    font-size: 14px;
    font-weight: 500;
}

.subcategory-arrow {
    color: #9ca3af;
    font-size: 12px;
    transition: transform 0.2s ease;
}

.subcategory-item:hover .subcategory-arrow {
    transform: translateX(2px);
    color: #2563eb;
}

.no-subcategories,
.subcategory-error {
    text-align: center;
    padding: 40px 20px;
    color: #6b7280;
    font-size: 14px;
}

/* 🔥 АДАПТИВНОСТЬ ДЛЯ МОБИЛЬНЫХ */
@media (max-width: 768px) {
    .catalog-sidebar {
        width: 100vw;
        left: -100vw;
    }
    
    .catalog-columns {
        flex-direction: column;
        height: calc(100vh - 70px);
    }
    
    .catalog-main-column {
        width: 100%;
        height: 40%;
        border-right: none;
        border-bottom: 1px solid #e5e7eb;
    }
    
    .catalog-sub-column {
        height: 60%;
        padding: 16px;
    }
    
    .catalog-header {
        padding: 16px 20px;
    }
    
    .catalog-header h3 {
        font-size: 16px;
    }
}

/* 🔥 СКРОЛЛБАР */
.catalog-main-column::-webkit-scrollbar,
.catalog-sub-column::-webkit-scrollbar {
    width: 6px;
}

.catalog-main-column::-webkit-scrollbar-track,
.catalog-sub-column::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.catalog-main-column::-webkit-scrollbar-thumb,
.catalog-sub-column::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

.catalog-main-column::-webkit-scrollbar-thumb:hover,
.catalog-sub-column::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}