JS - click outside of modal to close it