Add css, remove some code duplication.... still more work to do