refactored to accommodate changing product image based on the color swatch.