fix formatting and text wrapping