Walk me through the app lifecycle and how you preserve state when the app goes into the background in a BayOne mobile app.