add some template and css magic