fixed up templates and stylesheets