Used https://www.w3schools.com/howto/tryit.asp?filename=tryhow_css_dropdown_navbar_click as my base code and then edited it.