fixed various layout issues