adds margin to thumbnail grid