.product-card {
    width: 220px;
    min-height: 350px;       /* allows small cards but grows with content */
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* pushes button to bottom */
    padding: 1.5rem;
    box-sizing: border-box;

    /* Animation + hover */
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.6s ease forwards;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Staggered fade-in delays */
.product-card:nth-child(1) { animation-delay: 0.1s; }
.product-card:nth-child(2) { animation-delay: 0.2s; }
.product-card:nth-child(3) { animation-delay: 0.3s; }
.product-card:nth-child(4) { animation-delay: 0.4s; }
/* Add more if needed */

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.details img{
    height: 450px;
}

.product-card img {
    width: 100%;
    height: 200px;
    object-fit: contain;
    border-radius: 4px;
    margin-bottom: 0.5rem;
}

.product-card .btn {
    align-self: flex-start;
    margin-top: auto;
    padding: 0.375rem 0.75rem;
}

/* Hover effect */
.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

/* Responsive */
@media (max-width: 768px) {
    .product-card {
        width: 45%;
        min-height: auto;  /* let it shrink on smaller screens */
    }

    .product-card img {
        height: 180px;
    }
}

@media (max-width: 480px) {
    .product-card {
        width: 100%;
    }

    .product-card img {
        height: 150px;
    }
}
