Refactor Main Menu and logic