Refactoring party!

Refactored CSS and JS code for better readability and efficiency. Used
CSSLint and JSLint for code analysis.
CSSLint's only issues were warnings that using margins, padding, and
borders will changes the box size (duh).
JSLint gave me lots of "Unexpected 'typeof'. Use '===' to compare
directly with undefined.", "Unexpected '++'.", "Missing 'use strict'
statement.", and "Expected '===' and instead saw '=='." errors, but
overall nothing major.