Refactoring html, js and css