Fixed logic in header and the layout widths