updated js for new html/css implementation