fix #409, fix #410

Note: there are some CSS issues that need to be addressed but I will
make a separate issue for them.
fix #412
fix HTML validation issues