adds flip mode, and game mode. extracts toggle switch into its own module