no longer loses the first image, maybe this would help trying to get the ratio dynamically