header nesting improved