Writing the JavaScript effects
Finally, we arrive at the fun stuff. Let's do some JavaScript. And by the fun stuff, I mean just JavaScript, not jQuery or any heavy libraries—only what we need. The script will go at the bottom of the page, before the close of your body tag. We want everything to load before the script runs.