/*!
 * Start Bootstrap - Grayscale Bootstrap Theme (http://startbootstrap.com)
 * Code licensed under the Apache License v2.0.
 * For details, see http://www.apache.org/licenses/LICENSE-2.0.
 */

// jQuery to collapse the navbar on scroll
$(window).scroll(() => {
  if ($('.navbar').offset().top > 50) {
    $('.fixed-top').addClass('top-nav-collapse');
  } else {
    $('.fixed-top').removeClass('top-nav-collapse');
  }
});

// Closes the Responsive Menu on Menu Item Click
$('.navbar-collapse ul li a').on('click', () => {
  $('.navbar-toggle:visible').click();
});
