switched to a horizontal layout for better design, updated .js for increased maintanability