making the grid css more robust