main doc formatting