/* =========================================
   Enhanced Product Card Styling
   ========================================= */
.product-card {
    border: none;
    border-radius: 12px;
    background: #ffffff;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    /* Soft ambient shadow */
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    height: 100%;
    /* Make card fill the column height */
    overflow: hidden;
    display: flex;
    flex-direction: column;
    margin-bottom: 20px;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

/* Image Container */
.product-card .card-img-top {
    height: 150px !important;
    /* Reduced fixed height for all images */
    width: 100%;
    object-fit: contain;
    /* Ensures whole product is visible */
    background-color: #f8f9fa;
    /* Light gray bg for transparent images */
    padding: 10px;
    /* Reduced breathing room */
    transition: transform 0.5s ease;
}

.product-card:hover .card-img-top {
    transform: scale(1.05);
    /* Subtle zoom on hover */
}

/* Card Body */
.product-card .card-body {
    padding: 12px;
    display: flex;
    flex-direction: column;
    /* justify-content: space-between; Removed to reduce gap */
    /* Pushes content apart */
    flex-grow: 1;
    /* Fills remaining space */
    border-top: 1px solid #f0f0f0;
}

/* Title Styling */
.product-card .card-text {
    font-size: 15px;
    /* Slightly smaller font */
    font-weight: 700;
    color: var(--title-color);
    margin-bottom: 10px;
    line-height: 1.4;
    text-align: center;
    min-height: 42px;
    /* Enforces 2-line minimum to align buttons better */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    /* Added standard property */
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Button Container to ensure bottom alignment */
.product-btn-container {
    text-align: center;
    margin-top: 10px;
    /* Fixed small gap instead of auto */
    /* Pushes to bottom if flex container */
}

/* Button Styling */
.productBtn {
    background-color: var(--theme-color);
    color: #fff !important;
    padding: 8px 20px;
    /* Reduced padding */
    border-radius: 50px;
    font-weight: 600;
    font-size: 13px;
    /* Slightly smaller font */
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-align: center;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(0, 173, 181, 0.3);
    text-decoration: none;
    display: inline-block;
    border: 2px solid transparent;
}

.productBtn:hover {
    background-color: transparent;
    color: var(--theme-color) !important;
    border-color: var(--theme-color);
    transform: translateY(-2px);
    box-shadow: 0 5px 12px rgba(0, 173, 181, 0.2);
}

/* =========================================
   Native CSS Carousel (No jQuery)
   ========================================= */
.product-scroll-wrapper {
    position: relative;
    padding: 0;
}

.product-scroll-container {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    /* smooth scrolling iOS */
    gap: 20px;
    padding: 10px 5px 20px 5px;
    /* Bottom padding for shadow/scrollbar */
}

/* Hide scrollbar for cleaner look */
.product-scroll-container::-webkit-scrollbar {
    display: none;
}

.product-scroll-container {
    -ms-overflow-style: none;
    /* IE and Edge */
    scrollbar-width: none;
    /* Firefox */
    overflow-y: hidden;
    /* Prevent vertical scrollbar */
    padding-bottom: 50px;
    /* INCREASED: Ensure shadow and hover effect are visible */
}

.product-scroll-container .item {
    flex: 0 0 auto;
    width: 250px;
    /* Default Card Width */
    scroll-snap-align: start;
    padding: 5px;
    /* Add breathing room inside item */
}

/* Responsive Widths */
@media (min-width: 576px) {
    .product-scroll-container .item {
        width: 280px;
    }
}

@media (min-width: 992px) {
    .product-scroll-container .item {
        width: 300px;
    }
}

/* Native Nav Buttons */
.scroll-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #fff;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    border: 1px solid #eee;
    /* Visible border */
    z-index: 100;
    /* INCREASED: Ensure clickable */
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--theme-color, #333);
    transition: all 0.3s ease;
}

.scroll-nav-btn:hover {
    background-color: var(--theme-color, #00ADB5);
    color: #fff;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.scroll-nav-btn.prev-btn {
    left: 0;
}

.scroll-nav-btn.next-btn {
    right: 0;
}

/* Ensure Tab Content Visibility Logic persists */
.tab-content>.tab-pane {
    display: none;
}

.tab-content>.active {
    display: block;
    animation: fadeIn 0.5s;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}