Use canonical tags! By adding a canonical tag to each variant page that points to the main product page, you tell search engines that these are variations of the same product, not duplicate content.