.container {
    max-width: 900px;
    margin: auto;
    text-align: center;
    padding: 0 15px; /* Added padding for small screens */
}

.preview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.preview-card {
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 10px;
    background: #fff;
    transition: transform 0.2s; /* Added hover effect */
}

.preview-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.preview-card img {
    width: 100%;
    height: auto;
    max-height: 200px; /* Limit image height */
    object-fit: contain; /* Maintain aspect ratio */
    border-radius: 5px;
}

button {
    margin-top: 20px;
    padding: 10px 20px;
    background: #3498db;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
}

button:hover {
    background: #3498db;
}

/* Small screen adjustments (mobile devices) */
@media (max-width: 768px) {
    .container {
        padding: 0 10px;
    }
    
    .preview-grid {
        grid-template-columns: 1fr; /* Single column on small screens */
        gap: 10px;
    }
    
    .preview-card {
        padding: 8px;
    }
    
    .preview-card img {
        max-height: 150px; /* Smaller images on mobile */
    }
    
    button {
        padding: 12px 24px; /* Larger tap target */
        width: 100%; /* Full width button */
        margin: 20px 0;
    }
}

/* Very small screens (e.g., iPhone SE) */
@media (max-width: 375px) {
    .preview-card img {
        max-height: 120px;
    }
    
    .preview-card {
        padding: 6px;
    }
}