Few layout changes, cleaner code, small fix