Reorder html and styles