Authentication system overhaul. (part 1)

- Reorganize files and routes.
- Rewrite registration system.
- Implement email confirmation system.