Move styles to stylesheet, clean up basic js func