Changes to fix some css and some bugs I found in the functionality.