change centering header and footer function for readability