.chs-slider-container {
    width: 100%;
    margin: 10px auto 0 auto; /* Very small space */
    padding: 0 15px; /* Added left and right space for mobile */
    overflow: hidden;
    box-sizing: border-box;
}

.chs-swiper {
    width: 100%;
    /* Keep space at bottom for pagination */
    padding-bottom: 40px !important; 
}

.chs-swiper .swiper-slide {
    display: flex;
    justify-content: center;
    align-items: center;
    height: auto;
}

.chs-swiper .swiper-slide img {
    display: block;
    width: 100%;
    height: auto; /* Dynamic height based on width */
    aspect-ratio: 800 / 350; /* perfectly locks the ratio */
    object-fit: cover; /* Ensures fill without stretching */
    border-radius: 16px; /* Matches the rounded corners in the image */
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1); /* Subtle shadow for depth */
}

/* Desktop Sizing */
@media (min-width: 768px) {
    .chs-slider-container {
        padding: 0; /* Remove mobile padding on desktop since there's already space due to the 2.5 view */
    }
}

/* Pagination Styling */
.chs-swiper .chs-pagination {
    bottom: 0px !important;
}

.chs-swiper .swiper-pagination-bullet {
    width: 12px;
    height: 4px;
    background: #ccc;
    opacity: 1;
    border-radius: 4px;
    transition: all 0.3s ease;
    margin: 0 4px !important;
}

.chs-swiper .swiper-pagination-bullet-active {
    width: 32px;
    background: #000; /* Active line is longer and darker */
}

/* Category Icons Bar */
.chs-category-container {
    width: 100%;
    background: #fff;
    padding: 15px 0;
    margin-bottom: 20px;
    border-bottom: 1px solid #eaeaea; /* Subtle separator */
}

.chs-category-list {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    margin: 0;
    padding: 0 15px; /* Mobile padding */
    list-style: none;
    -webkit-overflow-scrolling: touch; /* Smooth scroll on iOS */
    scrollbar-width: none; /* Hide scrollbar Firefox */
}
.chs-category-list::-webkit-scrollbar {
    display: none; /* Hide scrollbar Chrome/Safari */
}

.chs-category-item {
    flex: 0 0 auto;
    margin-right: 10px; /* Smaller margin on mobile */
    text-align: center;
}
.chs-category-item:last-child {
    margin-right: 0;
}

.chs-category-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #333;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    position: relative;
    padding: 8px 4px; /* Smaller padding for mobile */
    border: 1px solid #d1d5db;
    border-radius: 10px;
    background: #fff;
    width: 78px; /* Fixed width to fit 4 on screen */
    transition: all 0.2s ease;
}

.chs-category-icon {
    width: 40px; /* Smaller icon for mobile */
    height: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 6px;
    transition: all 0.2s ease;
}

.chs-category-icon img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.chs-category-title {
    font-size: 11px; /* Smaller font on mobile */
    font-weight: 500;
    line-height: 1.2;
    text-align: center;
    /* Limit to 2 lines with ellipsis */
    white-space: normal; 
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    height: 26px; /* Fixed height for 2 lines */
}

/* Hover and Active states (like the blue highlight in the image) */
.chs-category-link:hover .chs-category-title,
.chs-category-item.active .chs-category-title {
    color: #0066cc;
}

.chs-category-link:hover::after,
.chs-category-item.active .chs-category-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 10%;
    width: 80%;
    height: 3px;
    background-color: #0066cc;
    border-radius: 3px;
}

.chs-category-link:hover {
    border-color: #0066cc;
    background: #f0f7ff; /* Very light blue on hover */
    box-shadow: 0 4px 12px rgba(0, 102, 204, 0.12);
    transform: translateY(-2px);
}

.chs-category-link:hover .chs-category-icon {
    transform: scale(1.05); /* Slight icon scale on hover */
}

@media (min-width: 768px) {
    .chs-category-list {
        padding: 0; /* Remove mobile padding on desktop if container is constrained */
        justify-content: center; /* Center them on desktop if there's space */
    }
    .chs-category-item {
        margin-right: 20px;
    }
    .chs-category-link {
        padding: 12px 16px;
        width: auto;
        min-width: 100px;
        border-radius: 12px;
    }
    .chs-category-icon {
        width: 50px;
        height: 50px;
        margin-bottom: 8px;
    }
    .chs-category-title {
        font-size: 13px;
        white-space: nowrap;
        height: auto;
        display: block;
    }
    .chs-category-container {
        max-width: 1200px;
        margin: 0 auto 20px auto;
    }
}
