Big refactor of the code.

- Make JS and CSS more modular