").appendTo("body"); scrollbarWidth=scrollbarParent.children().innerWidth()-scrollbarParent.children().height(99).innerWidth(); if (userAgent.match(/(edge\/\d+|Edge\/\d+)/)) {scrollbarWidth=scrollbarWidth+4;} scrollbarParent.remove();} $(document).on("shown.bs.modal",function(){if (!isMobile) {$("body, #chat, .intercom-messenger-frame, .modal").css("margin-right",scrollbarWidth+"px"); $("#bodyheader, #intercom-container iframe").css("padding-right",scrollbarWidth+"px"); if (!$("#proxyscroll").length) {$("
").appendTo("body");}} $("body").css({"overflow-x":"hidden","overflow-y":"hidden"});}); $(document).on("hidden.bs.modal",function(){if (!$(".modal").is(":visible")) {if (!isMobile) {$("body, #chat, .intercom-messenger-frame, .modal").css("margin-right","0"); $("#bodyheader, #intercom-container iframe").css("padding-right","0"); $("#proxyscroll").remove();} $("body").css({"overflow-x":"visible","overflow-y":"scroll"});}}); if (isFF) {$("#bodyheader .badge").css("padding-bottom","5px");} if (isMobile) {$("head").append("");} if (userAgent.match(/(iphone|ipad|ipod)/)) {$("head").append("");} $(".navcontact").click(function(){$("#contactmodal").modal({backdrop:"static", keyboard:false, show:true});}); $("#contactsubmit").click(function(){$("#contactform").submit();}); $(".results, .modalresults").each(function(){$(this).attr("src","about:blank");}); $(".modalresults").parents(".modal").on("hidden.bs.modal",function(){$(".modalresults",this).css({"height":"0","margin-bottom":"0"}).attr("src","about:blank");}); $(".modal").on("hidden.bs.modal",function(){$(".modal-footer",this).addClass("modalbtnhide");}); $(window).on("shown.bs.modal",function(){$(".modal:visible").each(function(){var shownModal=$(this), checkFooter=setInterval(function(){var shownFooter=shownModal.find(".modal-footer").first(); if (shownFooter.length) {clearInterval(checkFooter); modalButtons(shownFooter);}},0);});}); $("#browsemodal, #setupprojectmodal, #paymentmodal").on("hidden.bs.modal",function(){$(this).find(".modal-content").empty(); $(this).removeData();}); resizeNav(true); setupHeader(); targetForm(""); modalScroll(""); modalPopover($("body")); $("a[data-toggle='popover']").on("shown.bs.popover",function(){modalPopover($(this).next());}); if (isMobile) {$(".modal-content").css("margin-bottom","30px");} else {$(".modal-scroll").scroll(function(){$("[data-toggle=popover]").popover("hide");});} $(".navsigninclient").click(function(){signinModal(true,false,"");}); $(".navsigninpro").click(function(){signinModal(false,false,"");}); $(".navsigninbusiness").click(function(){signinModal(false,true,"");}); $("#signinretrieve").click(function(){$("#signinretrieveform").toggle();}); $("#signinsubmit").click(function(){$("#signinform").submit();}); localDate(); var swiperPitch=new Swiper("#pitch", {slidesPerView: 1, centeredSlides: true, grabCursor: true, spaceBetween: 31, loop: true, breakpoints: {470: {slidesPerView: 1.25,}, 768: {slidesPerView: 1.5,}, 992: {slidesPerView: 2,}, 1600: {slidesPerView: 2.5,}, 2000: {slidesPerView: 3,}}, on: {transitionEnd: function(){$("#pitch .pitchfadein").removeClass("pitchfadein").addClass("pitchfadeout"); $(this.slides[this.activeIndex]).find(".swiper-button-prev").css("visibility","visible"); $(this.slides[this.activeIndex]).find(".swiper-button-next").css("visibility","visible"); $(this.slides[this.activeIndex]).removeClass("pitchfadeout").addClass("pitchfadein");}}, navigation: {nextEl: "#pitch .swiper-button-next", prevEl: "#pitch .swiper-button-prev",},}); $("#pitch .swiper-button-next, #pitch .swiper-button-prev").on("click",function(){$("#pitch .swiper-button-next, #pitch .swiper-button-prev").css("visibility","hidden");}); var swiperSocialProof=new Swiper("#socialproof .swiper", {slidesPerView: "auto", grabCursor: true, spaceBetween: 15, loop: true, breakpoints: {470: {spaceBetween: 30,}, 1300: {spaceBetween: 50,}}, autoplay: {delay: 5000, disableOnInteraction: false,},}); if (isMobile) {$("#trusted").addClass("trustedmobile");} var swiperOptions=new Swiper("#options", {slidesPerView: 1.25, freeMode: true, spaceBetween: 20, grabCursor: true, breakpoints: {450: {slidesPerView: 1.5,}, 640: {slidesPerView: 2, freeMode: false, spaceBetween: 50,}, 1300: {slidesPerView: 3, freeMode: false, spaceBetween: 50,}, 2100: {slidesPerView: 4, freeMode: false, spaceBetween: 50,}}, pagination: {el: "#options .swiper-pagination", clickable: true,}, navigation: {nextEl: "#options .swiper-button-next", prevEl: "#options .swiper-button-prev",},}); var swiperProfessionals=new Swiper("#professionals .swiper", {effect: "creative", creativeEffect: {prev: {translate: ["100%", 0, 0],}, next: {shadow: true, translate: [0, 0, -400],},}, autoplay: {delay: 5000, disableOnInteraction: false,},}); swiperProfessionals.allowTouchMove=false; setTimeout(function(){$(document).trigger("afterready");},1);}); $(document).bind("afterready",function(){$("html").css("opacity","1"); if ($("#bodyheader").length) {$("#bodyheader").css("opacity","1");}}); $(function(){$("[data-toggle=popover]").popover();}); $("body").on("click",function(e){$("[data-toggle=popover]").each(function(){if (!$(this).is(e.target) && $(this).has(e.target).length===0 && $(".popover").has(e.target).length===0) {$(this).popover("hide");}});}); $(window).resize(function(){$("[data-toggle=popover]").popover("hide");}); $(window).resize(function(){resizeNav(false); modalScroll(""); modalButtons($(".modal-footer:visible")); if ($.isFunction(window.froalaHeight)) {froalaHeight();} $(".results, .modalresults, .message").each(function(){if ($(this).contents().has("title").length && !($(this).hasClass("message") && $(this).prev().hasClass("msginitial"))) {iframeSize($(this));}});}); $(function(){$("[href^='#']").not("[href~='#']").click(function(e){e.preventDefault(); $(window).scrollTop($("[id*='"+$(this).attr("href").split("#")[1]+"']").offset().top-68);});});