!function(e){"use strict";e(window).on("load",function(){e("#preloader").length&&e("#preloader").delay(100).fadeOut("slow",function(){e(this).remove()})});var o=e("#header").outerHeight()-1;e(document).on("click",".nav-menu a, .mobile-nav a, .scrollto",function(a){if(location.pathname.replace(/^\//,"")==this.pathname.replace(/^\//,"")&&location.hostname==this.hostname){var t=e(this.hash);if(t.length){a.preventDefault();var l=t.offset().top-o;return"#header"==e(this).attr("href")&&(l=0),e("html, body").animate({scrollTop:l},1500,"easeInOutExpo"),e(this).parents(".nav-menu, .mobile-nav").length&&(e(".nav-menu .active, .mobile-nav .active").removeClass("active"),e(this).closest("li").addClass("active")),e("body").hasClass("mobile-nav-active")&&(e("body").removeClass("mobile-nav-active"),e(".mobile-nav-toggle i").toggleClass("icofont-navigation-menu icofont-close"),e(".mobile-nav-overly").fadeOut()),!1}}}),e(document).ready(function(){if(window.location.hash){var a=window.location.hash;if(e(a).length){var t=e(a).offset().top-o;e("html, body").animate({scrollTop:t},1500,"easeInOutExpo")}}});var a=e("section"),t=e(".nav-menu, .mobile-nav");if(e(window).on("scroll",function(){var o=e(this).scrollTop()+200;a.each(function(){var a=e(this).offset().top,l=a+e(this).outerHeight();o>=a&&o<=l&&(o<=l&&t.find("li").removeClass("active"),t.find('a[href="#'+e(this).attr("id")+'"]').parent("li").addClass("active")),o<300&&e(".nav-menu ul:first li:first, .mobile-nav ul:first li:first").addClass("active")})}),e(".nav-menu").length){var l=e(".nav-menu").clone().prop({class:"mobile-nav d-lg-none"});e("body").append(l),e("body").prepend('<button type="button" class="mobile-nav-toggle d-lg-none"><i class="icofont-navigation-menu"></i></button>'),e("body").append('<div class="mobile-nav-overly"></div>'),e(document).on("click",".mobile-nav-toggle",function(o){e("body").toggleClass("mobile-nav-active"),e(".mobile-nav-toggle i").toggleClass("icofont-navigation-menu icofont-close"),e(".mobile-nav-overly").toggle()}),e(document).on("click",".mobile-nav .drop-down > a",function(o){o.preventDefault(),e(this).next().slideToggle(300),e(this).parent().toggleClass("active")}),e(document).click(function(o){var a=e(".mobile-nav, .mobile-nav-toggle");!a.is(o.target)&&0===a.has(o.target).length&&e("body").hasClass("mobile-nav-active")&&(e("body").removeClass("mobile-nav-active"),e(".mobile-nav-toggle i").toggleClass("icofont-navigation-menu icofont-close"),e(".mobile-nav-overly").fadeOut())})}else e(".mobile-nav, .mobile-nav-toggle").length&&e(".mobile-nav, .mobile-nav-toggle").hide();e(window).scroll(function(){e(this).scrollTop()>100?(e("#header").addClass("header-scrolled"),e("#topbar").addClass("topbar-scrolled")):(e("#header").removeClass("header-scrolled"),e("#topbar").removeClass("topbar-scrolled"))}),e(window).scrollTop()>100&&(e("#header").addClass("header-scrolled"),e("#topbar").addClass("topbar-scrolled")),e(window).scroll(function(){e(this).scrollTop()>100?e(".back-to-top").fadeIn("slow"):e(".back-to-top").fadeOut("slow")}),e(".back-to-top").click(function(){return e("html, body").animate({scrollTop:0},1500,"easeInOutExpo"),!1}),e('[data-toggle="counter-up"]').counterUp({delay:10,time:1e3}),e(".testimonials-carousel").owlCarousel({autoplay:!0,dots:!0,loop:!0,responsive:{0:{items:1},768:{items:1},900:{items:2}}}),e(document).ready(function(){e(".venobox").venobox()}),e(document).ready(function(){e(".datepicker").datepicker({autoclose:!0})})}(jQuery);