/* Storage Catalog Site - Shared Styles */

:root {
    --bg-color: #0a0a0a;
    --text-color: #ffffff;
    --transition-speed: 200ms;
    --supplier-size: 120px;
    --company-size: 100px;
    --product-size: 80px;
    --indent-size: 24px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    min-height: 100vh;
    padding: 20px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

/* Supplier Styles */
/* Header Section */
.catalog-header {
    text-align: center;
    margin-bottom: 48px;
    padding: 32px 0;
}

.catalog-header h1 {
    font-size: 42px;
    font-weight: 700;
    margin-bottom: 12px;
    background: linear-gradient(135deg, #ffffff 0%, #cccccc 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.catalog-subtitle {
    font-size: 18px;
    opacity: 0.7;
    font-weight: 400;
}

/* Modern Catalog Container */
.modern-catalog {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Supplier Card - Big Rectangle */
.supplier-card {
    background: linear-gradient(135deg, #1a1a1a 0%, #2a2a2a 100%);
    border: 1px solid #333;
    border-radius: 16px;
    margin-bottom: 24px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.supplier-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
    border-color: #555;
}

.supplier-header-modern {
    display: flex;
    align-items: center;
    padding: 32px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.supplier-logo-modern {
    width: 120px;
    height: 120px;
    object-fit: contain;
    margin-right: 32px;
    background: #0a0a0a;
    border-radius: 12px;
    padding: 16px;
    border: 2px solid #333;
}

.supplier-info-modern {
    flex: 1;
}

.supplier-name-modern {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 8px;
    color: #ffffff;
}

.supplier-count-modern {
    font-size: 16px;
    opacity: 0.7;
    font-weight: 400;
}

.supplier-arrow-modern {
    font-size: 24px;
    margin-left: 16px;
    transition: transform 0.3s ease;
    color: #aaa;
}

.supplier-card.expanded .supplier-arrow-modern {
    transform: rotate(180deg);
    color: #fff;
}

/* Company Section - Full Width Dropdown */
.supplier-companies-modern {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    background: #151515;
    border-top: 1px solid #333;
}

.supplier-card.expanded .supplier-companies-modern {
    max-height: 2000px;
}

.company-card-modern {
    display: flex;
    align-items: center;
    padding: 24px 32px;
    cursor: pointer;
    transition: all 0.3s ease;
    border-bottom: 1px solid #252525;
    position: relative;
}

.company-card-modern:hover {
    background: #1f1f1f;
    padding-left: 40px;
}

.company-logo-modern {
    width: 80px;
    height: 80px;
    object-fit: contain;
    margin-right: 24px;
    background: #0a0a0a;
    border-radius: 8px;
    padding: 12px;
    border: 1px solid #333;
}

.company-info-modern {
    flex: 1;
}

.company-name-modern {
    font-size: 22px;
    font-weight: 600;
    margin-bottom: 6px;
    color: #ffffff;
}

.company-product-count-modern {
    font-size: 14px;
    opacity: 0.7;
}

.company-arrow-modern {
    font-size: 20px;
    margin-left: 16px;
    transition: transform 0.3s ease;
    color: #aaa;
}

.company-card-modern.expanded .company-arrow-modern {
    transform: rotate(90deg);
    color: #fff;
}

/* FIXED: Vertical Product List Instead of Grid */
.products-list-modern {
    display: block;
    padding: 0;
}

/* New List Item Style */
.product-list-item-modern {
    display: flex;
    align-items: center;
    padding: 16px 24px;
    margin-bottom: 8px;
    background: #1a1a1a;
    border: 1px solid #333;
    border-radius: 8px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.product-list-item-modern:hover {
    background: #252525;
    border-color: #555;
    transform: translateX(4px);
}

.product-list-item-modern:last-child {
    margin-bottom: 0;
}

/* Product Image - Smaller for List */
.product-list-image-modern {
    width: 60px;
    height: 60px;
    object-fit: contain;
    margin-right: 20px;
    background: #0a0a0a;
    border-radius: 6px;
    padding: 8px;
    border: 1px solid #333;
    flex-shrink: 0;
}

/* Product Info - Flexible Width */
.product-list-info-modern {
    flex: 1;
    min-width: 0;
}

.product-list-name-modern {
    font-size: 17px;
    font-weight: 600;
    margin-bottom: 4px;
    color: #ffffff;
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.product-list-volume-modern {
    font-size: 14px;
    opacity: 0.8;
    color: #ccc;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Price - Right Aligned */
.product-list-price-modern {
    font-size: 18px;
    font-weight: 700;
    color: #ffffff;
    margin-left: 16px;
    white-space: nowrap;
    flex-shrink: 0;
}

/* Fixed: Company Products Container */
/* Replace the existing company-products-modern styles */
.company-products-modern {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    background: #0f0f0f;
    border-left: 3px solid #333;
    margin-left: 40px;
    overflow: hidden;
}

.company-wrapper-modern.expanded .company-products-modern {
    grid-template-rows: 1fr;
}

.products-list-modern {
    min-height: 0;
    overflow: hidden;
}

/* Fixed: Company Wrapper for Expansion */
.company-wrapper-modern {
    position: relative;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.company-wrapper-modern.expanded .company-card-modern {
    background: #252525;
}

.company-wrapper-modern.expanded .company-arrow-modern {
    transform: rotate(90deg);
    color: #fff;
}

/* Mobile Responsive for List */
@media (max-width: 768px) {
    .product-list-item-modern {
        padding: 14px 18px;
    }
    
    .product-list-image-modern {
        width: 50px;
        height: 50px;
        margin-right: 16px;
    }
    
    .product-list-name-modern {
        font-size: 16px;
    }
    
    .product-list-volume-modern {
        font-size: 13px;
    }
    
    .product-list-price-modern {
        font-size: 17px;
    }
}