/* Carousel Layout */
.carousel-container {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
    margin-top: 2rem;
}

.product-track {
    display: flex;
    overflow-x: auto;
    gap: 2rem;
    scroll-behavior: smooth;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE */
    width: 100%;
    padding: 20px 5px; /* Padding for shadow clearance */
    padding-right: 20px; /* Ensure last item isn't flush */
    
    /* RESTORING SWIPE: Removed restrictive touch-action */
    -webkit-overflow-scrolling: touch;
}

.product-track::-webkit-scrollbar {
    display: none; /* Chrome/Safari */
}

/* 
   STRICT CARD SIZING 
   Locked to allow ~3 cards on standard desktop
*/
.product-card {
    flex: 0 0 32%; /* Fits 3 items with gap */
    min-width: 300px; /* Safety floor */
    max-width: 400px;
    height: auto;
    /* Ensure flex properties don't get overridden */
    box-sizing: border-box;
}

/* Navigation Arrows */
.nav-arrow {
    background: rgba(255,255,255,0.8);
    border: 1px solid #ccc;
    color: #000;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 1.2rem;
    font-family: 'Courier New', monospace;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    flex-shrink: 0;
    z-index: 10;
    position: absolute;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.nav-arrow:hover {
    background: #000;
    color: #fff;
    border-color: #000;
}

.nav-arrow.prev { left: -20px; }
.nav-arrow.next { right: -20px; }

.nav-arrow.hidden {
    opacity: 0;
    pointer-events: none;
}

/* Tablet/Mobile Adjustments */
@media (max-width: 1024px) {
    .product-card {
        flex: 0 0 45%; /* 2 items on tablet */
    }
}

@media (max-width: 768px) {
    .product-card {
        flex: 0 0 80%; /* 80% width allows the NEXT card to peek by 20% - gap */
    }
    .nav-arrow {
        display: none; /* Hide arrows on mobile, rely on swipe */
    }
    .carousel-container {
        padding: 0 0; /* Remove side padding so card hits edge */
    }
    .product-track {
        padding-left: 0; /* First card flush left? Or maybe small padding */
        padding-left: 20px; /* Small inset for first card */
    }
}