Fixing menu hiding behavior when switching from mobile width to desktop width

If the viewport is narrow enough to show the "mobile" view, and the menu is opened and then closed, and then the viewport is widened to show the "desktop" view, the menu will be `display:none;`. This shouldn't happen, and this PR fixes this behavior.