Extra whitespace here also margin-right might be better as margin: 0 10px 10px 0; otherwise the images on second row get stuck to the ones above.