Major cleanup and rewrite of theme