add responsive design, refactor code