New structure

Restructure all the files AND make all files use consistent indentation.