moved all functions into a class and added some desktop styles