Updated index.html

Completely changed code. Now much easier to understand and read.