/* Compact Top Brands Section Styles for Sub Dukan */
.brands-container {
    width: 100%;
    max-width: 1240px;
    margin: 15px auto; /* Reduced vertical margin */
    padding: 0 8px; /* Reduced side padding */
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

.brands-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px; /* Reduced header margin */
}

.brands-title {
    font-size: 18px; /* Slightly smaller title */
    font-weight: 700;
    color: #333;
    text-transform: uppercase;
}

.brands-view-all {
    font-size: 13px;
    font-weight: 600;
    color: #f4a51c;
    text-decoration: none;
    transition: color 0.3s ease;
}

.brands-view-all:hover {
    color: #d38b10;
}

.brands-scroll-wrapper {
    position: relative;
    width: 100%;
}

.brands-grid {
    display: flex;
    gap: 10px; /* Reduced gap between items */
    overflow-x: auto;
    scroll-behavior: smooth;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding: 5px 2px; /* Minimal padding for grid */
}

.brands-grid::-webkit-scrollbar {
    display: none;
}

.brand-item {
    flex: 0 0 auto;
    width: 90px; /* Smaller width on desktop */
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    transition: transform 0.2s ease;
}

.brand-logo-wrapper {
    width: 70px; /* Smaller logo box on desktop */
    height: 70px;
    background: #fff;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 1px 5px rgba(0,0,0,0.05);
    border: 1px solid #eee;
    margin-bottom: 6px;
    transition: all 0.2s ease;
    overflow: hidden;
    padding: 8px;
}

.brand-logo-wrapper img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.brand-name {
    font-size: 12px;
    font-weight: 500;
    color: #555;
    text-align: center;
    transition: color 0.2s ease;
}

/* Hover Effects */
.brand-item:hover .brand-logo-wrapper {
    border-color: #f4a51c;
    box-shadow: 0 3px 10px rgba(244, 165, 28, 0.15);
    transform: translateY(-2px);
}

.brand-item:hover .brand-name {
    color: #f4a51c;
}

/* Mobile Adjustments - Significantly smaller cards */
@media (max-width: 767px) {
    .brands-container {
        margin: 10px auto;
        padding: 0 6px;
    }
    
    .brands-header {
        margin-bottom: 8px;
    }

    .brands-title {
        font-size: 15px;
    }
    
    .brand-item {
        width: 70px; /* Much smaller item on mobile */
    }
    
    .brand-logo-wrapper {
        width: 55px; /* Compact logo box for mobile */
        height: 55px;
        border-radius: 10px;
        padding: 6px;
    }
    
    .brand-name {
        font-size: 10px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: 100%;
    }

    .brands-grid {
        gap: 8px;
    }
}
