body {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    background-color: #f4f6f9;
    margin: 0;
    padding: 1.5rem;
}

header {
    text-align: center;
    margin-bottom: 2rem;
    color: #1e293b;
}

#product-catalog {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.product-card {
    background-color: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

.product-card .name {
    font-size: 1.25rem;
    font-weight: 600;
    color: #0f172a;
    padding: 1rem 1rem 0.5rem 1rem;
}

.product-card .description {
    font-size: 0.9rem;
    color: #64748b;
    padding: 0 1rem 1rem 1rem;
    flex-grow: 1; /* Makes description take up available space */
}

.product-card .footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    border-top: 1px solid #e2e8f0;
    background-color: #f8fafc;
}

.product-card .price {
    font-size: 1.2rem;
    font-weight: 700;
    color: #3b82f6;
}

.product-card .stock {
    font-size: 0.85rem;
    font-weight: 500;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    background-color: #dcfce7;
    color: #166534;
}

#loader {
    text-align: center;
    font-size: 1.2rem;
    margin-top: 4rem;
    color: #64748b;
}