/* Horizontal slider styles */
.product-slider { 
    position: relative; 
    margin: 24px auto;
    max-width: 1400px; /* Adjust based on your layout needs */
}

.ps-viewport { 
    overflow: hidden;
    margin: 0 50px; /* Space for arrows */
}

.ps-track { 
    display: flex;
    transition: transform 0.5s ease;
    will-change: transform;
}

.ps-slide { 
    flex: 0 0 calc(100% / 6); /* Always show 6 images */
    box-sizing: border-box;
    padding: 0 6px;
}

.ps-slide img { 
    width: 100%;
    height: 160px; /* Adjusted for better proportions */
    object-fit: cover;
    border-radius: 8px;
    display: block;
}

.ps-arrow { 
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(20,52,114,0.85);
    color: #fff;
    border: none;
    padding: 12px 16px;
    border-radius: 6px;
    cursor: pointer;
    z-index: 5;
}

.ps-prev { left: 0; }
.ps-next { right: 0; }

.ps-dots {
    text-align: center;
    margin-top: 12px;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

.ps-dots-track {
    display: flex;
    transition: transform 0.3s ease;
    gap: 8px;
    padding: 4px 0;
}

.ps-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    background: #ddd;
    border-radius: 50%;
    cursor: pointer;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.ps-dot.active {
    background: #143472;
    transform: scale(1.3);
}

/* Mobile: Show only 3 dots visible at a time */
@media (max-width: 768px) {
    .ps-dots {
        width: 100%;
        display: flex;
        justify-content: center;
        overflow: hidden;
    }

    .ps-dots-track {
        display: flex;
        justify-content: center;
        min-width: 70px;
    }
}

/* Responsive adjustments */
@media (max-width: 1200px) {
    .ps-slide { flex: 0 0 calc(100% / 4); } /* 4 slides on medium screens */
}

@media (max-width: 768px) {
    .ps-slide { flex: 0 0 calc(100% / 2); } /* 2 slides on mobile */
    .ps-viewport { margin: 0 40px; }
}

/* small adjustments */
#product-slider { max-width: 100%; }
#product-slider .ps-arrow { opacity: 0.95; }
#product-slider .ps-viewport { border-radius: 8px; }
#product-slider .ps-slide { padding: 8px; }
