A CodePen by Art Pai. Fluid Gallery - Use padding to to maintain a photo cell's ratio.