/* Product styles */
#product-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(180px, 100%), 1fr));
    gap: 20px;
    padding: 1rem;
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
    box-sizing: border-box;
}

.product-item {
    background-color: #fff; 
    border-radius: 8px; 
    overflow: hidden; 
    transition: transform 0.3s ease, box-shadow 0.3s ease; 
    cursor: pointer; 
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 300px;
}

.product-item:hover {
    transform: translateY(-5px); 
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15); 
}

.product-item-image img {
    width: 100%; 
    height: 150px; 
    object-fit: contain; 
}

.product-item-info {
    padding: 10px; 
    text-align: center; 
    overflow: hidden; 
}

.product-item-info h2 {
    font-size: 16px;
    color: #1a1a1a;
    font-weight: 500;
    margin: 0 0 8px 0;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    line-height: 1.4;
}

.product-item-price {
    font-size: 15px;
    color: #4e4e4e;
    font-weight: 500;
    margin-bottom: 12px;
}

.add-item-to-cart-button {
    background-color: #000;
    color: #fff;
    padding: 10px 16px;
    text-align: center;
    border-radius: 6px;
    text-transform: none;
    font-size: 14px;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s ease;
    width: 90%;
    margin: 0 auto 10px;
}

.add-item-to-cart-button:hover {
    background-color: #333;
}

@media (max-width: 768px) {
    #product-list {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 15px;
        padding: 0.75rem;
    }
    
    .product-item {
        height: 280px;
    }
    
    .product-item-image img {
        height: 130px;
    }
    
    .product-item-info h2 {
        font-size: 14px;
    }
    
    .product-item-price {
        font-size: 13px;
    }
    
    .add-item-to-cart-button {
        font-size: 12px;
        padding: 8px 12px;
    }
}

@media (max-width: 480px) {
    #product-list {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
        padding: 0.5rem;
    }
    
    .product-item {
        height: 260px;
    }
    
    .product-item-image img {
        height: 120px;
    }
}
/* Existing product.css styles */



.out-of-stock-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: #d9534f; /* Red */
    color: white;
    padding: 4px 8px;
    font-size: 10px;
    font-weight: bold;
    text-transform: uppercase;
    border-radius: 4px;
    z-index: 1;
    display: none; /* Hide by default */
}

.product-item:hover .out-of-stock-badge {
    display: block; /* Show on hover */
}

/* Category button styles for accessibility */
.category {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    transition: transform 0.3s ease;
}

.category:hover {
    transform: scale(1.05);
}

.category:focus-visible {
    outline: 2px solid #000;
    outline-offset: 4px;
    border-radius: 50%;
}
