Fixed the layout to correspond to grid