function updateUploadBoxes(){uploadBoxes=[];$(".x-control.x-upload-box").each(function(index,ub){var $ub=$(ub),uploadForm,typ;$ub.id=ub.id;uploadForm=$("*[data-form]",$($ub));$ub.supportedTypes=[];typ=$ub.data("file-types");$ub.supportedTypes=typ.length>0?typ.split(","):[];$ub.serviceUrl=$ub.data("serviceurl");$ub.initCallback=function(){};$ub.successCallback=function(){};$ub.failureCallback=function(){};$ub.cancelCallback=function(){};$ub.progressCallback=function(){};$ub.input=$("*[data-input]",$($ub));$ub.remove=$("*[data-remove-button]",$($ub));$ub.isFileSelected=function(){return $ub.input.val().length<1?!1:!0};$ub.isValid=function(){var input,type,found,i;if(!this.isFileSelected())return!0;if(input=$("*[data-input]",$($ub)),type=input.val().substr((~-input.val().lastIndexOf(".")>>>0)+2).toLowerCase(),this.supportedTypes.length>0){for(found=!1,i=0;i>>0)+2).toLowerCase(),this.supportedTypes.length>0){for(found=!1,i=0;i-1&&(mask+="abcdefghijklmnopqrstuvwxyz"),chars.indexOf("A")>-1&&(mask+="ABCDEFGHIJKLMNOPQRSTUVWXYZ"),chars.indexOf("#")>-1&&(mask+="0123456789"),chars.indexOf("!")>-1&&(mask+="~`!@#$%^&*()_+-={}[]:\";'<>?,./|\\"),result="",i=length;i>0;--i)result+=mask[Math.round(Math.random()*(mask.length-1))];return result}function toggleMainMenu(){if($(".no-open-menu").length>0||$(".main-menu .nav-1 > li.selected").siblings().addClass("blurred"),$(".main-menu .nav-1 > li .btn-box").mouseenter(function(){$(this).addClass("hovered");$(this).parent().removeClass("blurred");$(this).parent().siblings().addClass("blurred");$(this).parent().siblings().children(".submenu-wrapper").hide();$(this).parent().siblings().children(".btn-box").removeClass("no-text");$(this).siblings(".submenu-wrapper").is(":visible")||$(this).siblings(".submenu-wrapper").show();$(this).addClass("no-text")}),$(".main-menu .nav-1 > li").mouseleave(function(){$(this).children(".btn-box").removeClass("hovered");$(this).siblings().removeClass("blurred");$(this).children(".submenu-wrapper").hide();$(this).children(".btn-box").removeClass("no-text")}),!($(".no-open-menu").length>0)){var selected=$(".main-menu .nav-1 > li.selected");selected.length>0&&(selected.children(".btn-box").addClass("no-text"),selected.children(".submenu-wrapper").show());$(".main-menu .nav-1").mouseleave(function(){selected.siblings().addClass("blurred");selected.length>0&&(selected.children(".btn-box").addClass("no-text"),selected.children(".submenu-wrapper").show())})}}function initDefaultPhotoGallery(){var indexNum,thumb,owlSmall,owl;$(".default-photo-gallery .thumbs-container > ul").owlCarousel({items:5,navigation:!0,pagination:!1,slideSpeed:600,rewindSpeed:1e3,addClassActive:!1,navigationText:!1,rewindNav:!0,autoPlay:!1,itemsDesktop:[1280,4],itemsDesktopSmall:!1,itemsTablet:!1,itemsMobile:!1});thumb=$(".default-photo-gallery .thumbs-container > ul .owl-item > li");owlSmall=$(".default-photo-gallery .thumbs-container > ul.owl-carousel").data("owlCarousel");$(".default-photo-gallery .slider-container > ul").owlCarousel({navigation:!0,transitionStyle:"fade",paginationSpeed:1e3,navigationText:!1,stopOnHover:!0,rewindNav:!0,singleItem:!0,pagination:!0,addClassActive:!0,autoHeight:!0,beforeMove:function(){indexNum=$(".default-photo-gallery .slider-container > ul .owl-item.active").index()},afterMove:function(){indexNum=$(".default-photo-gallery .slider-container > ul .owl-item.active").index();owlSmall.goTo(indexNum);var thumbInst=thumb.parent().eq(indexNum);thumbInst.children("li").addClass("selected");thumbInst.siblings().children("li").removeClass("selected")}});owl=$(".slider-container .owl-carousel").data("owlCarousel");thumb.first().addClass("selected");thumb.click(function(){$(this).addClass("selected").parent().siblings().children("li").removeClass("selected");indexNum=$(this).parent().index();$(".default-photo-gallery .slider-container > ul .owl-item").eq(indexNum).hasClass("active")||owl.goTo(indexNum)});$(".default-photo-gallery .slider-container ul li a").fancybox({padding:0,margin:[10,40,10,40],fitToView:!0,helpers:{title:{type:"over"}}})}function oldAndroid(){var start=navigator.userAgent.indexOf("Android "),majorversion=navigator.userAgent.substr(start+8,1);majorversion<3&&$("html").addClass("old-android")}function initPhotoGalleryHomeTouch(){$(".home-page .home-gallery-container ul").owlCarousel({paginationSpeed:1e3,slideSpeed:1e3,rewindSpeed:3e3,rewindNav:!0,autoPlay:!1,singleItem:!0,pagination:!0,navigation:!1,mouseDrag:!0,addClassActive:!0})}function toggleMainMenuTouch(){var mainMenu=$(".main-menu > ul"),menuItemSelected=$(".main-menu > ul > li.opened"),$menuItemSub=$(".main-menu > ul > li .btn-box > a");$menuItemSub.click(function(e){e.preventDefault();$(".main-menu > ul > li.opened").children(".submenu-wrapper").hide();$(".main-menu > ul > li.opened").children(".btn-box").removeClass("no-text hovered");$(".main-menu > ul > li.opened").removeClass("opened");$(this).parent().siblings(".submenu-wrapper").is(":visible")||($(this).parent().parent().addClass("opened"),$(this).parent().addClass("no-text hovered").siblings(".submenu-wrapper").show())});$(".no-open-menu").length>0||($(".shadow-left").addClass("visible").velocity({translateX:"0",translateZ:0},{duration:0,easing:"linear"}),$(".shadow-right").addClass("visible").velocity({translateX:"0",translateZ:0},{duration:0,easing:"linear"}))}function mobileSelectMenu(){$(".select-menu .title").text($(".select-menu .x-menu").val());$(".select-menu select").on("change",function(){var url=$(this).children("[selected]").attr("data-href");window.location.href=url})}function initDefaultPhotoGalleryTouch(){var indexNum,thumb,owlSmall,owl;$(".default-photo-gallery .thumbs-container > ul").owlCarousel({items:5,navigation:!0,pagination:!1,slideSpeed:600,rewindSpeed:1e3,addClassActive:!1,navigationText:!1,rewindNav:!0,autoPlay:!1,itemsDesktop:[1280,4],itemsDesktopSmall:[650,3],itemsTablet:!1,itemsMobile:[480,2]});thumb=$(".default-photo-gallery .thumbs-container > ul .owl-item > li");owlSmall=$(".default-photo-gallery .thumbs-container > ul.owl-carousel").data("owlCarousel");$(".default-photo-gallery .slider-container > ul").owlCarousel({navigation:!0,paginationSpeed:1e3,slideSpeed:1e3,rewindSpeed:3e3,navigationText:!1,stopOnHover:!0,rewindNav:!0,singleItem:!0,pagination:!0,addClassActive:!0,beforeMove:function(){indexNum=$(".default-photo-gallery .slider-container > ul .owl-item.active").index()},afterMove:function(){indexNum=$(".default-photo-gallery .slider-container > ul .owl-item.active").index();owlSmall.goTo(indexNum);var thumbInst=thumb.parent().eq(indexNum);thumbInst.children("li").addClass("selected");thumbInst.siblings().children("li").removeClass("selected")}});owl=$(".slider-container .owl-carousel").data("owlCarousel");thumb.first().addClass("selected");thumb.click(function(){$(this).addClass("selected").parent().siblings().children("li").removeClass("selected");indexNum=$(this).parent().index();$(".default-photo-gallery .slider-container > ul .owl-item").eq(indexNum).hasClass("active")||owl.goTo(indexNum)});$(".default-photo-gallery .slider-container ul li a").fancybox({padding:0,helpers:{title:{type:"over"}}})}function toggleFooterTouch(){var footer=$(".footer-region"),footerbigCont=$(".footer-region .region-area-two");$(".footer-region .expand-button").click(function(){footer.hasClass("opened")?(footer.removeClass("opened"),footerbigCont.velocity("slideUp",{duration:300,easing:"linear"})):(footer.addClass("opened"),footerbigCont.velocity("slideDown",{duration:300,easing:"linear"}),$("html,body").animate({scrollTop:$(".expand-button").offset().top-50},600,"linear"))})}function openMobileMenu(){var menuContainer=$(".header-region .region-area-one"),windowHeight,menuHeight,siteContainer;$("html").hasClass("touch")&&!$("html").hasClass("old-android")&&(windowHeight=$(window).height(),menuHeight=$(".main-menu").height(),menuContainer.css("height",windowHeight-50),$(".menu-overlay").css("min-height",menuHeight),$(window).resize(function(){var windowHeight=$(window).height();menuContainer.css("height",windowHeight-50)}));$("html").hasClass("old-android")&&(menuContainer.css("height",$(".site-container").height()-50),$(window).resize(function(){menuContainer.css("height",$(".site-container").height()-50)}));siteContainer=$(".site-container");$(".mobile-menu-button").click(function(){siteContainer.hasClass("mobile-menu-open")?($(".header-region .region-area-one").velocity("stop").velocity({left:"-100%"},{duration:600,delay:0}),siteContainer.removeClass("mobile-menu-open"),$("body").removeClass("no-x-scroll")):(siteContainer.addClass("mobile-menu-open"),$("body").addClass("no-x-scroll"),$(".header-region").velocity({top:"0"},{duration:300,delay:0}),$(".header-region .region-area-one").velocity("stop").velocity({left:"0"},{duration:600,delay:0}))});$(".overlay").on("click",function(){siteContainer.hasClass("mobile-menu-open")&&$(".mobile-menu-button").trigger("click")});$(".open-mobile-submenu").click(function(){$(this).parent().siblings(".submenu-wrapper").velocity("fadeIn",{duration:0}).velocity({left:"0"},{duration:400});$(".menu-overlay").velocity("fadeIn",{duration:400})});$(".back-to-main").click(function(){$(this).parent(".submenu-wrapper").velocity({left:"101%"},{duration:400}).velocity("fadeOut",{delay:400,duration:0});$(".menu-overlay").velocity("fadeOut",{duration:400})})}function InitContentHeight(){var content=$(".content-container"),windowHeight=$(window).height(),headerHeight=$(".header-region .region-area-two").height(),footerHeight=$(".footer-region").height();content.css("min-height",windowHeight-headerHeight-footerHeight);$(window).resize(function(){content.css("min-height",windowHeight-headerHeight-footerHeight)})}function photoMediaPopUpMobile(){$(".mobile-fancy-box").fancybox({padding:0,margin:[10,40,10,40],fitToView:!0,nextEffect:"none",prevEffect:"none",helpers:{title:{type:"over"}}});$(".photo-grid-container ul li .image-container .img-link").click(function(){$(".mobile-fancy-box").trigger("click")})}function InitStoresMoreFilters(){$(".more-filters").click(function(){$(this).hasClass("opened")?($(this).removeClass("opened"),$(this).text($(this).data("close")),$(".sl-filter.type, .sl-filter.service").hide()):($(this).addClass("opened"),$(this).text($(this).data("open")),$(".sl-filter.type, .sl-filter.service").show(),$(".store-locator-page .services-container .nano").nanoScroller())})}function fullscreenTrigger(){$(".full-screen-option a").click(function(){(!document.fullScreenElement||document.fullScreenElement===null)&&(document.mozFullScreen||document.webkitIsFullScreen)?document.exitFullscreen?document.exitFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.webkitExitFullscreen&&document.webkitExitFullscreen():document.documentElement.requestFullscreen?document.documentElement.requestFullscreen():document.documentElement.mozRequestFullScreen?document.documentElement.mozRequestFullScreen():document.documentElement.webkitRequestFullscreen?document.documentElement.webkitRequestFullscreen():document.documentElement.msRequestFullscreen&&document.documentElement.msRequestFullscreen()})}function chronologicalSelect(){$("select.stylish-select").on("change",function(){var url=$(this).children("[selected]").attr("data-href");url&&(window.location.href=url)})}function initVideoMedia(){var delay=0;$(".video-grid-container > ul > li").each(function(){$(this).delay(delay).velocity({opacity:1},{duration:500});delay+=200})}function initProgramVideoMedia(){$(".fancy-program-video-gallery").fancybox({padding:0,margin:0,width:$(window).width(),height:$(window).height(),fitToView:!0,autoSize:!1,helpers:{overlay:null},beforeLoad:function(){$("body").css("overflow","hidden")},afterClose:function(){$("body").css("overflow","visible")},tpl:{wrap:'
<\/div><\/div><\/div><\/div>',closeBtn:'<\/a>'}})}function toggleBgShadow(){$.Velocity.hook($(".shadow-left"),"translateX","-100%");$.Velocity.hook($(".shadow-right"),"translateX","100%");!$(".main-menu .nav-1").children(".selected").length>0||$(".no-open-menu").length>0?$(".header-region .inner-area-one").hover(function(){$(".shadow-left").addClass("visible").velocity({translateX:"0",translateZ:0},{duration:400,easing:"linear"})},function(){$(".shadow-left").removeClass("visible").velocity("stop",!0).velocity({translateX:"-100%",translateZ:0},{duration:400,easing:"linear"})}):$(".shadow-left").addClass("visible").velocity({translateX:"0",translateZ:0},{duration:500,easing:"linear"});$(".header-region .region-area-two").hover(function(){$(".shadow-right").addClass("visible").velocity({translateX:"0",translateZ:0},{duration:400,easing:"linear"})},function(){$(".shadow-right").removeClass("visible").velocity("stop",!0).velocity({translateX:"100%",translateZ:0},{duration:400,easing:"linear"})})}function initRelatedArticleSlider(){$(".related-article-list ul").owlCarousel({paginationSpeed:1e3,rewindNav:!1,pagination:!0,navigation:!0,addClassActive:!0,items:3,itemsDesktop:[1750,2],itemsDesktopSmall:!1,itemsTablet:[767,1],itemsMobile:[479,1]})}function toggleFooter(){var footer=$(".footer-region"),footerbigCont=$(".footer-region .region-area-two");$(".footer-region .expand-button").click(function(){footer.hasClass("opened")?(footer.removeClass("opened"),footerbigCont.velocity("slideUp",{duration:300,easing:"linear"})):(footer.addClass("opened"),footerbigCont.velocity("slideDown",{duration:300,easing:"linear"}))})}function InitStepsAnimation(){$(".program-document-page .check-type-container").click(function(){var indx=$(this).parent().index();$(".program-document-page .box-one").velocity("fadeOut",{duration:300,easing:"linear"});$(".program-document-page .box-two .x-tab-panel .tabs-title ul .tab-title").eq(indx).trigger("click")})}function InitStepsSlider(){$(".program-document-page .box-two .tabs-content ul li").each(function(){$(this).children(".x-article-list").children("ul").owlCarousel({slideSpeed:1500,paginationSpeed:1e3,stopOnHover:!0,rewindNav:!1,autoPlay:!1,singleItem:!0,lazyLoad:!0,pagination:!0,navigation:!0,navigationText:[prevNext[0],prevNext[1]],mouseDrag:!0,addClassActive:!0,transitionStyle:"fade",afterMove:function(){EventManager.trigger("lazyload")}})})}function InitVideoFancyBox(){$(".fancy-video-gallery").fancybox({padding:0,margin:0,width:$(window).width(),height:$(window).height(),fitToView:!0,autoSize:!1,nextEffect:"none",prevEffect:"none",helpers:{overlay:null},beforeLoad:function(){$("body").css("overflow","hidden")},afterClose:function(){$("body").css("overflow","visible")},tpl:{wrap:'
<\/div><\/div><\/div><\/div>',closeBtn:'<\/a>',next:'<\/span><\/a>',prev:'<\/span><\/a>'}})}function InitScrollToBtn(){$(".scroll-to-btn").click(function(){var cont=$(this).closest(".nano-content");cont.animate({scrollTop:$(this).closest(".nano-content").find(".text-container").offset().top-cont.offset().top+cont.scrollTop()},1e3,"easeInOutExpo")})}function toggleInfoBox(){var visBtn=$(".info-phone-option .info-phone-btn"),closeBtn=$(".info-phone-option .box-container .close"),infoBox=localStorage.getItem("infoBox");infoBox||(visBtn.parent().addClass("opened"),visBtn.siblings().show().css("right","50px"),localStorage.setItem("infoBox",!0));visBtn.click(function(){$(this).parent().hasClass("opened")?($(this).parent().removeClass("opened"),$(this).siblings().animate({right:"-445px"},700,"easeInBack")):($(this).parent().addClass("opened"),$(this).siblings().show().animate({right:"50px"},700,"easeOutBack"),localStorage.setItem("infoBox",!0))});closeBtn.click(function(){visBtn.trigger("click")})}function toggleFaq(){$(".x-faq-box .question").click(function(){$(this).parent().hasClass("opened")?($(this).parent().removeClass("opened"),$(this).siblings(".answer").velocity("slideUp",{duration:400})):($(".x-faq-box.opened").removeClass("opened").children(".answer").velocity("slideUp",{duration:400}),$(this).parent().addClass("opened"),$(this).siblings(".answer").velocity("slideDown",{duration:400}));setTimeout(function(){$(".nano").nanoScroller()},500)})}function initWaterInputs(){$(".waterInput").length<1||$(".waterInput").each(function(){var val=$(this).attr("data-name");$(this).watermark(val)})}function initClickableBackground(){$(".site-background .x-htmlarea ul li a").length<1||$(".site-container").click(function(e){$(e.target)[0]==$(".site-container")[0]&&(window.location=$(".site-background .x-htmlarea ul li a").attr("href"))})}function UpdateQueryString(key,value,url){var re,separator,hash;return url||(url=window.location.href),re=new RegExp("([?|&])"+key+"=.*?(&|#|$)","gi"),url.match(re)?value?url.replace(re,"$1"+key+"="+value+"$2"):url.replace(re,"$2"):value?(separator=url.indexOf("?")!==-1?"&":"?",hash=url.split("#"),url=hash[0]+separator+key+"="+value,hash[1]&&(url+="#"+hash[1]),url):url}function getQueryStringValueByName(name){name=name.replace(/[\[]/,"\\[").replace(/[\]]/,"\\]");var regexS="[\\?&]"+name+"=([^&#]*)",regex=new RegExp(regexS),results=regex.exec(window.location.search);return results==null?"":decodeURIComponent(results[1].replace(/\+/g," "))}function removeValueFromCommaSeparatedString(list,value,separator){var values,i;for(separator=separator||",",values=list.split(separator),i=0;i57)&&event.preventDefault():(event.keyCode<96||event.keyCode>105)&&event.preventDefault())}function preventSpecialCharacter(e){var shiftPressed=e.shiftKey,keyCode=e.keyCode;shiftPressed?(keyCode==188||keyCode==190||keyCode==51||keyCode==55||keyCode==53||keyCode==219||keyCode==221)&&e.preventDefault():(keyCode==191||keyCode==219||keyCode==221||keyCode==111)&&e.preventDefault()}function phoneGROnly(event){numbersOnly(event);$(event.currentTarget).val().length>9&&(event.keyCode==46||event.keyCode==8||event.keyCode==36||event.keyCode==35||event.keyCode==37||event.keyCode==39||event.keyCode==9||event.preventDefault())}var uploadBoxes;jQuery.easing.jswing=jQuery.easing.swing;jQuery.extend(jQuery.easing,{def:"easeOutQuad",swing:function(x,t,b,c,d){return jQuery.easing[jQuery.easing.def](x,t,b,c,d)},easeInQuad:function(x,t,b,c,d){return c*(t/=d)*t+b},easeOutQuad:function(x,t,b,c,d){return-c*(t/=d)*(t-2)+b},easeInOutQuad:function(x,t,b,c,d){return(t/=d/2)<1?c/2*t*t+b:-c/2*(--t*(t-2)-1)+b},easeInCubic:function(x,t,b,c,d){return c*(t/=d)*t*t+b},easeOutCubic:function(x,t,b,c,d){return c*((t=t/d-1)*t*t+1)+b},easeInOutCubic:function(x,t,b,c,d){return(t/=d/2)<1?c/2*t*t*t+b:c/2*((t-=2)*t*t+2)+b},easeInQuart:function(x,t,b,c,d){return c*(t/=d)*t*t*t+b},easeOutQuart:function(x,t,b,c,d){return-c*((t=t/d-1)*t*t*t-1)+b},easeInOutQuart:function(x,t,b,c,d){return(t/=d/2)<1?c/2*t*t*t*t+b:-c/2*((t-=2)*t*t*t-2)+b},easeInQuint:function(x,t,b,c,d){return c*(t/=d)*t*t*t*t+b},easeOutQuint:function(x,t,b,c,d){return c*((t=t/d-1)*t*t*t*t+1)+b},easeInOutQuint:function(x,t,b,c,d){return(t/=d/2)<1?c/2*t*t*t*t*t+b:c/2*((t-=2)*t*t*t*t+2)+b},easeInSine:function(x,t,b,c,d){return-c*Math.cos(t/d*(Math.PI/2))+c+b},easeOutSine:function(x,t,b,c,d){return c*Math.sin(t/d*(Math.PI/2))+b},easeInOutSine:function(x,t,b,c,d){return-c/2*(Math.cos(Math.PI*t/d)-1)+b},easeInExpo:function(x,t,b,c,d){return t==0?b:c*Math.pow(2,10*(t/d-1))+b},easeOutExpo:function(x,t,b,c,d){return t==d?b+c:c*(-Math.pow(2,-10*t/d)+1)+b},easeInOutExpo:function(x,t,b,c,d){return t==0?b:t==d?b+c:(t/=d/2)<1?c/2*Math.pow(2,10*(t-1))+b:c/2*(-Math.pow(2,-10*--t)+2)+b},easeInCirc:function(x,t,b,c,d){return-c*(Math.sqrt(1-(t/=d)*t)-1)+b},easeOutCirc:function(x,t,b,c,d){return c*Math.sqrt(1-(t=t/d-1)*t)+b},easeInOutCirc:function(x,t,b,c,d){return(t/=d/2)<1?-c/2*(Math.sqrt(1-t*t)-1)+b:c/2*(Math.sqrt(1-(t-=2)*t)+1)+b},easeInElastic:function(x,t,b,c,d){var s=1.70158,p=0,a=c;return t==0?b:(t/=d)==1?b+c:(p||(p=d*.3),a0&&(fieldValue=row.getValue(),isMatchValid=!0,groupedFields.each(function(gi,gItem){$(gItem).is(":text")||$(gItem).is(":password")?$(gItem).val()!=fieldValue&&(isMatchValid=!1):$(gItem).is(":checkbox")&&$(gItem).is(":checked")!=fieldValue&&(isMatchValid=!1)}),!isMatchValid))?!1:!0};row.validate=function(){var checked,s,$validator,group,groupedFields,fieldValue,isMatchValid;if($valField.length==0)return!0;if($(row).removeClass("x-invalid"),$valField.data("validaterequired"))if($validator=$("*["+$valField.data("validaterequired")+"]",$(form)),$validator.siblings().hide(),$validator.hide(),$valField.is(":text")||$valField.is(":password")||$valField.get(0).tagName.toLowerCase()=="textarea"||$valField.get(0).tagName.toLowerCase()=="select"){if($valField.val().trim()===""){$(row).addClass("x-invalid");$validator.show();return}}else if($valField.is(":checkbox")){if(checked=$valField.is(":checked"),!checked){$(row).addClass("x-invalid");$validator.show();return}}else $($valField.get(0)).data("uploads")&&(s=0,$("*[data-upload-box]",$(row)).each(function(ii,ubi){var ub=form.formUploadBoxesIds[ubi.id];ub.isFileSelected()&&s++;ub.validate()||s--}),s<$form.data("required-files")&&$("*[data-upload-box]",$(row)).each(function(ii,ubi){var ub=form.formUploadBoxesIds[ubi.id];ub.validateSelected()}),row.isValid()||($(row).addClass("x-invalid"),$validator.show()));if($valField.data("validateemail")&&($validator=$("*["+$valField.data("validateemail")+"]",$(form)),$validator.siblings().hide(),$validator.hide(),$valField.is(":text")&&!LhApp.Function.String.isEmail($valField.val()))){$(row).addClass("x-invalid");$validator.show();return}if($valField.data("validatematch")&&($validator=$("*["+$valField.data("validatematch")+"]",$(form)),$validator.siblings().hide(),$validator.hide(),group=$valField.data("validatematchgroup"),groupedFields=$('*[data-member][data-validatematchgroup="'+group+'"]',$(form)),groupedFields.length>0&&(fieldValue=row.getValue(),isMatchValid=!0,groupedFields.each(function(gi,gItem){$(gItem).is(":text")||$(gItem).is(":password")||$valField.get(0).tagName.toLowerCase()=="textarea"?$(gItem).val()!=fieldValue&&(isMatchValid=!1):$(gItem).is(":checkbox")&&$(gItem).is(":checked")!=fieldValue&&(isMatchValid=!1)}),!isMatchValid))){$(row).addClass("x-invalid");$validator.show();return}}});form.fields=[];form.showLoader=function(){$("*[data-member]",$(form)).each(function(i,item){$(item).is(":disabled")||(form.fields.push($(item).data("member")),$(item).prop("disabled",!0))});$("*[data-click]",$(form)).each(function(i,item){$(item).is(":disabled")||$(item).prop("disabled",!0)});$form.find(".button-wrapper").addClass("x-disabled");$form.addClass("x-disabled");$form.addClass("x-loading")};form.hideLoader=function(){$("*[data-member]",$(form)).each(function(i,item){$(item).is(":disabled")&&form.fields.indexOf($(item).data("member"))!=-1&&$(item).prop("disabled",!1)});$("*[data-click]",$(form)).each(function(i,item){$(item).is(":disabled")&&$(item).prop("disabled",!1)});$form.find(".button-wrapper").removeClass("x-disabled");$form.removeClass("x-disabled");$form.removeClass("x-loading")};form.isLoading=function(){return $form.hasClass("x-disabled")};form.validate=function(){$rows.each(function(r,row){row.validate()});validateOnKeyup=!0};form.isValid=function(){var valid=!0;return $rows.each(function(r,row){row.isValid()||(valid=!1)}),valid};form.reset=function(){$('*[data-section="success"]',$(form)).hide();$('*[data-section="failure"]',$(form)).hide();$('*[data-section="content"]',$(form)).show();$('input[type="file"][data-member]',$(form)).val("");$('input[type="text"][data-member]',$(form)).val("");$('input[type="password"][data-member]',$(form)).val("");$('input[type="textarea"][data-member]',$(form)).val("");$('input[type="checkbox"][data-member]',$(form)).prop("checked",!1);$("*[data-validator]",$(form)).hide();$("*[data-validationmsg]",$(form)).hide()};$("*[data-member]",$(form)).keyup(function(){if($(this).data("member")=="message"&&$(this).keydown(preventSpecialCharacter),validateOnKeyup){var $row=$(this).parents(".form-row:first");$row.get(0).validate()}});$("select[data-member]",$(form)).change(function(){if(validateOnKeyup){var $row=$(this).parents(".form-row:first");$row.get(0).validate()}});$("*[data-input]",$("*[data-uploads]",$(form))).change(function(){if($("*[data-upload-box]",$(form)).each(function(i,ub){var ub=form.formUploadBoxesIds[ub.id];ub.update();validateOnKeyup||ub.validate()}),validateOnKeyup){var $row=$(this).parents(".form-row:first");$row.get(0).validate()}});$("*[data-trigger]",$(form)).keyup(function(e){if(e.keyCode==13){if(e.stopPropagation(),e.preventDefault(),!form.isValid()){form.validate();return}if(form.isLoading())return;var configData=form.getConfig();form.submit(configData)}});$('*[data-click="submit"]',$(form)).click(function(e){var isDisabled,configData;if(e.preventDefault(),!form.isValid()){form.validate();return}(isDisabled=form.isLoading()||LhApp.Function.isButtonDisabled(this),isDisabled)||(configData=form.getConfig(),form.submit(configData))});$('*[data-click="generic-submit"]',$(form)).click(function(e){var code=$(form).data("code"),isDisabled;(e.preventDefault(),form.validate(),form.isValid())&&((isDisabled=form.isLoading()||LhApp.Function.isButtonDisabled(this),isDisabled)||(form.token=generateVisitorToken(),$(form.formUploadBoxes).each(function(index,fub){fub.box.input.val().length<1?fub.uploaded=!0:(fub.uploaded=!1,fub.box.initCallback=function(box){$(form.formUploadBoxes).each(function(ii,bb){bb.box.id==box.id&&$("*[data-progress-bar-box]",$(bb.box)).show()})},fub.box.successCallback=function(box){$(form.formUploadBoxes).each(function(ii,bb){bb.box.id==box.id&&(bb.uploaded=!0,$("*[data-progress-bar-box]",$(bb.box)).hide())});form.checkUploadsAndSubmit()},fub.box.submit(form.token))}),form.checkUploadsAndSubmit()))});form.checkUploadsAndSubmit=function(){var done=!0,t=[],code,reqData;$(this.formUploadBoxes).each(function(index,fub){t.push(fub.uploaded);fub.uploaded||(done=!1)});done&&(code=$(this).data("code"),reqData={code:code,data:JSON.stringify(this.getConfig()),token:this.token},this.submit(reqData))}})},hookAjaxFormsFn=function($ajaxForms){$ajaxForms.each(function(i,form){var $form=$(form),$rows;form.methodType=$form.data("method");form.submitUrl=$form.data("action");$form.removeAttr("data-action");$rows=$("*.form-row.text, *.form-row.textarea, *.form-row.checkbox, *.form-row.select",$form);form.back=function(){$("*[data-section]",$(form)).hide();$('*[data-section="content"]',$(form)).show()};form.getConfig=function(){var config={};return $rows.each(function(r,row){var $valField=$("*[data-member]:first",$(row));$valField.length>0&&(config[$valField.data("member")]=row.getValue())}),$("*[data-hidden-member]",$(form)).each(function(i,item){config[$(item).data("hidden-member")]=$(item).val()}),form.methodType==="control"?[config]:config};form.onSuccess=function(request,response){var redirectUrl=$(this).data("redirect"),$successSection,$sections,successMsgVal;redirectUrl===undefined?($("*[data-validator]",$(form)).hide(),$("*[data-validationmsg]",$(form)).hide(),$(".file-uploader",$(form)).hide(),$successSection=$('*[data-section="success"]',$(form)),$successSection.length>0?($sections=$("*[data-section]",$(form)),$sections.hide(),successMsgVal=$('*[data-validationmsg="success"]',$successSection),successMsgVal.html(LhApp.Resource.getText("Validation:"+response.code)),successMsgVal.show(),$successSection.show()):(successMsgVal=$('*[data-section="content"] *[data-validationmsg="success"]',$(form)),successMsgVal.html(LhApp.Resource.getText("Validation:"+response.code)),successMsgVal.show())):redirectUrl!=""&&(document.location=redirectUrl)};form.onFailure=function(request,response){var validationMessage=LhApp.Resource.getText("Validation:"+response.code),$failureSection,$sections,$validator;$("*[data-validator]",$(form)).hide();$("*[data-validationmsg]",$(form)).hide();$failureSection=$('*[data-section="failure"]',$(form));$failureSection.length>0?($sections=$("*[data-section]",$(form)),$sections.hide(),$failureSection.show(),$validator=$('*[data-validationmsg="failure"]',$failureSection),$validator.html(validationMessage),$validator.show()):($validator=$('*[data-section="content"] *[data-validationmsg="failure"]',$(form)),$validator.length>0?($validator.html(validationMessage),$validator.show()):($validator=$("*[data-validationmsg]",$(form)),$validator.html(validationMessage),$validator.show()))};form.submit=function(config){var me=this,successFn,failureFn;form.isLoading()||(me.showLoader(),successFn=function(response){me.hideLoader();var responseData=form.methodType=="control"?jQuery.parseJSON(response):response.d;if(responseData.Success&&(responseData.success=responseData.Success),responseData.Code&&(responseData.code=responseData.Code),responseData.data&&(responseData.data=responseData.Data),responseData.time&&(responseData.time=responseData.Time),!responseData.success&&responseData.code=="GenericError"&&typeof responseData.Data=="string")try{responseData.Data=jQuery.parseJSON(responseData.Data)}catch(e){}if(responseData.success&&typeof me.onSuccess=="function")me.onSuccess(config,responseData);else if(!responseData.success&&typeof me.onFailure=="function")me.onFailure(config,responseData)},failureFn=function(ex){me.hideLoader();var response={code:"GenericError",success:!1,time:0};if(response.data=ex.responseText?jQuery.parseJSON(ex.responseText):ex,typeof me.onFailure=="function")me.onFailure(config,response)},form.methodType==="control"?form.invoke(form.config,form.submitUrl,form.methodType=="control"?config:JSON.stringify(config),successFn,failureFn):$.ajax({async:!0,type:"POST",dataType:"json",contentType:"application/json; charset=UTF-8",ContentType:"application/json; charset=UTF-8",url:LhApp.Function.Url.getServiceEndpoint(me.submitUrl),data:JSON.stringify(config),success:successFn,error:failureFn,failure:failureFn}))};$('*[data-section="failure"] *[data-click="reset"]',$(form)).click(function(e){e.preventDefault();var isDisabled=form.isLoading()||LhApp.Function.isButtonDisabled(this);isDisabled||(form.reset(),form.back())})})};Scripts.load(function(){var $forms=$('.x-control.x-form[data-control="form"]'),$ajaxForms=$('.x-control.x-form[data-control="form"][data-ajax="true"]');hookFormsFn($forms);hookAjaxFormsFn($ajaxForms)});Scripts.load(function(){updateUploadBoxes()}),function(a,h,y){var w="function",v="password",j="maxLength",n="type",b="",c=!0,u="placeholder",i=!1,t="watermark",g=t,f="watermarkClass",q="watermarkFocus",l="watermarkSubmit",o="watermarkMaxLength",e="watermarkPassword",d="watermarkText",k=/\r/g,s="input:data("+g+"),textarea:data("+g+")",m="input:text,input:password,input[type=search],input:not([type]),textarea",p=["Page_ClientValidate"],r=i,x=u in document.createElement("input");a.watermark=a.watermark||{version:"3.1.3",runOnce:c,options:{className:t,useNative:c,hideBeforeUnload:c},hide:function(b){a(b).filter(s).each(function(){a.watermark._hide(a(this))})},_hide:function(a,r){var p=a[0],q=(p.value||b).replace(k,b),l=a.data(d)||b,m=a.data(o)||0,i=a.data(f),g,c;l.length&&q==l&&(p.value=b,a.data(e)&&(a.attr(n)||b)==="text"&&(g=a.data(e)||[],c=a.parent()||[],g.length&&c.length&&(c[0].removeChild(a[0]),c[0].appendChild(g[0]),a=g)),m&&(a.attr(j,m),a.removeData(o)),r&&(a.attr("autocomplete","off"),h.setTimeout(function(){a.select()},1)));i&&a.removeClass(i)},show:function(b){a(b).filter(s).each(function(){a.watermark._show(a(this))})},_show:function(g){var p=g[0],u=(p.value||b).replace(k,b),h=g.data(d)||b,s=g.attr(n)||b,t=g.data(f),m,l,i;u.length!=0&&u!=h||g.data(q)?a.watermark._hide(g):(r=c,g.data(e)&&s===v&&(m=g.data(e)||[],l=g.parent()||[],m.length&&l.length&&(l[0].removeChild(g[0]),l[0].appendChild(m[0]),g=m,g.attr(j,h.length),p=g[0])),(s==="text"||s==="search")&&(i=g.attr(j)||0,i>0&&h.length>i&&(g.data(o,i),g.attr(j,h.length))),t&&g.addClass(t),p.value=h)},hideAll:function(){r&&(a.watermark.hide(m),r=i)},showAll:function(){a.watermark.show(m)}};a.fn.watermark=a.fn.watermark||function(p,o){var t="string",s,r;return this.length?(s=i,r=typeof p===t,r&&(p=p.replace(k,b)),typeof o=="object"?(s=typeof o.className===t,o=a.extend({},a.watermark.options,o)):typeof o===t?(s=c,o=a.extend({},a.watermark.options,{className:o})):o=a.watermark.options,typeof o.useNative!==w&&(o.useNative=o.useNative?function(){return c}:function(){return i}),this.each(function(){var B="dragleave",A="dragenter",z=this,i=a(z),C,t,w,y;if(i.is(m)){if(i.data(g))(r||s)&&(a.watermark._hide(i),r&&i.data(d,p),s&&i.data(f,o.className));else{if(x&&o.useNative.call(z,i)&&(i.attr("tagName")||b)!=="TEXTAREA"){r&&i.attr(u,p);return}i.data(d,r?p:b);i.data(f,o.className);i.data(g,1);(i.attr(n)||b)===v?(C=i.wrap("").parent(),t=a(C.html().replace(/type=["']?password["']?/i,'type="text"')),t.data(d,i.data(d)),t.data(f,i.data(f)),t.data(g,1),t.attr(j,p.length),t.focus(function(){a.watermark._hide(t,c)}).bind(A,function(){a.watermark._hide(t)}).bind("dragend",function(){h.setTimeout(function(){t.blur()},1)}),i.blur(function(){a.watermark._show(i)}).bind(B,function(){a.watermark._show(i)}),t.data(e,i),i.data(e,t)):i.focus(function(){i.data(q,1);a.watermark._hide(i,c)}).blur(function(){i.data(q,0);a.watermark._show(i)}).bind(A,function(){a.watermark._hide(i)}).bind(B,function(){a.watermark._show(i)}).bind("dragend",function(){h.setTimeout(function(){a.watermark._show(i)},1)}).bind("drop",function(e){var c=i[0],a=e.originalEvent.dataTransfer.getData("Text");(c.value||b).replace(k,b).replace(a,b)===i.data(d)&&(c.value=a);i.focus()});z.form&&(w=z.form,y=a(w),y.data(l)||(y.submit(a.watermark.hideAll),w.submit?(y.data(l,w.submit),w.submit=function(c,b){return function(){var d=b.data(l);a.watermark.hideAll();d.apply?d.apply(c,Array.prototype.slice.call(arguments)):d()}}(w,y)):(y.data(l,1),w.submit=function(b){return function(){a.watermark.hideAll();delete b.submit;b.submit()}}(w))))}a.watermark._show(i)}})):this};a.watermark.runOnce&&(a.watermark.runOnce=i,a.extend(a.expr[":"],{data:function(c,d,b){return!!a.data(c,b[3])}}),function(c){a.fn.val=function(){var e=this,f;return e.length?arguments.length?(c.apply(e,arguments),a.watermark.show(e),e):e.data(g)?(f=(e[0].value||b).replace(k,b),f===(e.data(d)||b)?b:f):c.apply(e,arguments):arguments.length?e:y}}(a.fn.val),p.length&&a(function(){for(var b,c,d=p.length-1;d>=0;d--)b=p[d],c=h[b],typeof c===w&&(h[b]=function(b){return function(){return a.watermark.hideAll(),b.apply(null,Array.prototype.slice.call(arguments))}}(c))}),a(h).bind("beforeunload",function(){a.watermark.options.hideBeforeUnload&&a.watermark.hideAll()}))}(jQuery,window),function($){$.fn.hoverIntent=function(f,g){var cfg={sensitivity:7,interval:100,timeout:0};cfg=$.extend(cfg,g?{over:f,out:g}:f);var cX,cY,pX,pY,track=function(ev){cX=ev.pageX;cY=ev.pageY},compare=function(ev,ob){if(ob.hoverIntent_t=clearTimeout(ob.hoverIntent_t),Math.abs(pX-cX)+Math.abs(pY-cY)settings.failure_limit)return!1}else $this.trigger("appear"),counter=0})}var elements=this,$container,settings={threshold:0,failure_limit:0,event:"scroll",effect:"show",container:window,data_attribute:"original",skip_invisible:!0,appear:null,load:null,placeholder:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB/AAffA0nNPuCLAAAAAElFTkSuQmCC"};return options&&(undefined!==options.failurelimit&&(options.failure_limit=options.failurelimit,delete options.failurelimit),undefined!==options.effectspeed&&(options.effect_speed=options.effectspeed,delete options.effectspeed),$.extend(settings,options)),$container=settings.container===undefined||settings.container===window?$window:$(settings.container),0===settings.event.indexOf("scroll")&&$container.bind(settings.event,function(){return update()}),$container.bind("lazyload",function(){return update()}),this.each(function(){var self=this,$self=$(self);self.loaded=!1;($self.attr("src")===undefined||$self.attr("src")===!1)&&$self.is("img")&&$self.attr("src",settings.placeholder);$self.one("appear",function(){if(!this.loaded){if(settings.appear){var elements_left=elements.length;settings.appear.call(self,elements_left,settings)}$("").bind("load",function(){var original=$self.attr("data-"+settings.data_attribute),temp,elements_left;$self.hide();$self.is("img")?$self.attr("src",original):$self.css("background-image","url('"+original+"')");$self[settings.effect](settings.effect_speed);self.loaded=!0;temp=$.grep(elements,function(element){return!element.loaded});elements=$(temp);settings.load&&(elements_left=elements.length,settings.load.call(self,elements_left,settings))}).attr("src",$self.attr("data-"+settings.data_attribute))}});0!==settings.event.indexOf("scroll")&&$self.bind(settings.event,function(){self.loaded||$self.trigger("appear")})}),$window.bind("resize",function(){update()}),/(?:iphone|ipod|ipad).*os 5/gi.test(navigator.appVersion)&&$window.bind("pageshow",function(event){event.originalEvent&&event.originalEvent.persisted&&elements.each(function(){$(this).trigger("appear")})}),$(document).ready(function(){update()}),this};$.belowthefold=function(element,settings){var fold;return fold=settings.container===undefined||settings.container===window?(window.innerHeight?window.innerHeight:$window.height())+$window.scrollTop():$(settings.container).offset().top+$(settings.container).height(),fold<=$(element).offset().top-settings.threshold};$.rightoffold=function(element,settings){var fold;return fold=settings.container===undefined||settings.container===window?$window.width()+$window.scrollLeft():$(settings.container).offset().left+$(settings.container).width(),fold<=$(element).offset().left-settings.threshold};$.abovethetop=function(element,settings){var fold;return fold=settings.container===undefined||settings.container===window?$window.scrollTop():$(settings.container).offset().top,fold>=$(element).offset().top+settings.threshold+$(element).height()};$.leftofbegin=function(element,settings){var fold;return fold=settings.container===undefined||settings.container===window?$window.scrollLeft():$(settings.container).offset().left,fold>=$(element).offset().left+settings.threshold+$(element).width()};$.inviewport=function(element,settings){return!$.rightoffold(element,settings)&&!$.leftofbegin(element,settings)&&!$.belowthefold(element,settings)&&!$.abovethetop(element,settings)};$.extend($.expr[":"],{"below-the-fold":function(a){return $.belowthefold(a,{threshold:0})},"above-the-top":function(a){return!$.belowthefold(a,{threshold:0})},"right-of-screen":function(a){return $.rightoffold(a,{threshold:0})},"left-of-screen":function(a){return!$.rightoffold(a,{threshold:0})},"in-viewport":function(a){return $.inviewport(a,{threshold:0})},"above-the-fold":function(a){return!$.belowthefold(a,{threshold:0})},"right-of-fold":function(a){return $.rightoffold(a,{threshold:0})},"left-of-fold":function(a){return!$.rightoffold(a,{threshold:0})}})}(jQuery,window,document); /*! VelocityJS.org (1.2.1). (C) 2014 Julian Shapiro. MIT @license: en.wikipedia.org/wiki/MIT_License */ /*! VelocityJS.org jQuery Shim (1.0.1). (C) 2014 The jQuery Foundation. MIT @license: en.wikipedia.org/wiki/MIT_License. */ !function(e){function t(e){var t=e.length,r=$.type(e);return"function"===r||$.isWindow(e)?!1:1===e.nodeType&&t?!0:"array"===r||0===t||"number"==typeof t&&t>0&&t-1 in e}var $,r;if(!e.jQuery){$=function(e,t){return new $.fn.init(e,t)};$.isWindow=function(e){return null!=e&&e==e.window};$.type=function(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?a[o.call(e)]||"object":typeof e};$.isArray=Array.isArray||function(e){return"array"===$.type(e)};$.isPlainObject=function(e){var t;if(!e||"object"!==$.type(e)||e.nodeType||$.isWindow(e))return!1;try{if(e.constructor&&!n.call(e,"constructor")&&!n.call(e.constructor.prototype,"isPrototypeOf"))return!1}catch(r){return!1}for(t in e);return void 0===t||n.call(e,t)};$.each=function(e,r,a){var n,o=0,i=e.length,s=t(e);if(a){if(s)for(;i>o&&(n=r.apply(e[o],a),n!==!1);o++);else for(o in e)if(n=r.apply(e[o],a),n===!1)break}else if(s)for(;i>o&&(n=r.call(e[o],o,e[o]),n!==!1);o++);else for(o in e)if(n=r.call(e[o],o,e[o]),n===!1)break;return e};$.data=function(e,t,a){var o,n;if(void 0===a){if(n=e[$.expando],o=n&&r[n],void 0===t)return o;if(o&&t in o)return o[t]}else if(void 0!==t)return n=e[$.expando]||(e[$.expando]=++$.uuid),r[n]=r[n]||{},r[n][t]=a,a};$.removeData=function(e,t){var a=e[$.expando],n=a&&r[a];n&&$.each(t,function(e,t){delete n[t]})};$.extend=function(){var e,t,r,a,n,o,i=arguments[0]||{},s=1,l=arguments.length,u=!1;for("boolean"==typeof i&&(u=i,i=arguments[s]||{},s++),"object"!=typeof i&&"function"!==$.type(i)&&(i={}),s===l&&(i=this,s--);l>s;s++)if(null!=(n=arguments[s]))for(a in n)e=i[a],r=n[a],i!==r&&(u&&r&&($.isPlainObject(r)||(t=$.isArray(r)))?(t?(t=!1,o=e&&$.isArray(e)?e:[]):o=e&&$.isPlainObject(e)?e:{},i[a]=$.extend(u,o,r)):void 0!==r&&(i[a]=r));return i};$.queue=function(e,r,a){function n(e,r){var a=r||[];return null!=e&&(t(Object(e))?!function(e,t){for(var r=+t.length,a=0,n=e.length;r>a;)e[n++]=t[a++];if(r!==r)for(;void 0!==t[a];)e[n++]=t[a++];return e.length=n,e}(a,"string"==typeof e?[e]:e):[].push.call(a,e)),a}if(e){r=(r||"fx")+"queue";var o=$.data(e,r);return a?(!o||$.isArray(a)?o=$.data(e,r,n(a)):o.push(a),o):o||[]}};$.dequeue=function(e,t){$.each(e.nodeType?[e]:e,function(e,r){t=t||"fx";var a=$.queue(r,t),n=a.shift();"inprogress"===n&&(n=a.shift());n&&("fx"===t&&a.unshift("inprogress"),n.call(r,function(){$.dequeue(r,t)}))})};$.fn=$.prototype={init:function(e){if(e.nodeType)return this[0]=e,this;throw new Error("Not a DOM node.");},offset:function(){var t=this[0].getBoundingClientRect?this[0].getBoundingClientRect():{top:0,left:0};return{top:t.top+(e.pageYOffset||document.scrollTop||0)-(document.clientTop||0),left:t.left+(e.pageXOffset||document.scrollLeft||0)-(document.clientLeft||0)}},position:function(){function e(){for(var e=this.offsetParent||document;e&&!1&&"static"===e.style.position;)e=e.offsetParent;return e||document}var t=this[0],e=e.apply(t),r=this.offset(),a=/^(?:body|html)$/i.test(e.nodeName)?{top:0,left:0}:$(e).offset();return r.top-=parseFloat(t.style.marginTop)||0,r.left-=parseFloat(t.style.marginLeft)||0,e.style&&(a.top+=parseFloat(e.style.borderTopWidth)||0,a.left+=parseFloat(e.style.borderLeftWidth)||0),{top:r.top-a.top,left:r.left-a.left}}};r={};$.expando="velocity"+(new Date).getTime();$.uuid=0;for(var a={},n=a.hasOwnProperty,o=a.toString,i="Boolean Number String Function Array Date RegExp Object Error".split(" "),s=0;sn;++n){if(o=u(r,e,a),0===o)return r;i=l(r,e,a)-t;r-=i/o}return r}function p(){for(var t=0;b>t;++t)w[t]=l(t*x,e,a)}function f(t,r,n){var o,i,s=0;do i=r+(n-r)/2,o=l(i,e,a)-t,o>0?n=i:r=i;while(Math.abs(o)>h&&++s=y?c(t,s):0==l?s:f(t,r,r+x)}function g(){V=!0;(e!=r||a!=n)&&p()}var m=4,y=.001,h=1e-7,v=10,b=11,x=1/(b-1),S="Float32Array"in t,P,T;if(4!==arguments.length)return!1;for(P=0;4>P;++P)if("number"!=typeof arguments[P]||isNaN(arguments[P])||!isFinite(arguments[P]))return!1;e=Math.min(e,1);a=Math.min(a,1);e=Math.max(e,0);a=Math.max(a,0);var w=S?new Float32Array(b):new Array(b),V=!1,C=function(t){return V||g(),e===r&&a===n?t:0===t?0:1===t?1:l(d(t),r,n)};return C.getControlPoints=function(){return[{x:e,y:r},{x:a,y:n}]},T="generateBezier("+[e,r,a,n]+")",C.toString=function(){return T},C}function u(e,t){var r=e;return g.isString(e)?v.Easings[e]||(r=!1):r=g.isArray(e)&&1===e.length?s.apply(null,e):g.isArray(e)&&2===e.length?b.apply(null,e.concat([t])):g.isArray(e)&&4===e.length?l.apply(null,e):!1,r===!1&&(r=v.Easings[v.defaults.easing]?v.defaults.easing:h),r}function c(e){var t,r,o,S,w,V,C,T,k,A,F,E,j,H,N;if(e)for(t=(new Date).getTime(),r=v.State.calls.length,r>1e4&&(v.State.calls=n(v.State.calls)),o=0;r>o;o++)if(v.State.calls[o]){var s=v.State.calls[o],l=s[0],u=s[2],f=s[3],d=!!f,m=null;f||(f=v.State.calls[o][3]=t-16);for(var y=Math.min((t-f)/u.duration,1),h=0,b=l.length;b>h;h++)if(S=l[h],w=S.element,i(w)){V=!1;u.display!==a&&null!==u.display&&"none"!==u.display&&("flex"===u.display&&(C=["-webkit-box","-moz-box","-ms-flexbox","-webkit-flex"],$.each(C,function(e,t){x.setPropertyValue(w,"display",t)})),x.setPropertyValue(w,"display",u.display));u.visibility!==a&&"hidden"!==u.visibility&&x.setPropertyValue(w,"visibility",u.visibility);for(T in S)if("element"!==T){if(k=S[T],F=g.isString(k.easing)?v.Easings[k.easing]:k.easing,1===y)A=k.endValue;else if(E=k.endValue-k.startValue,A=k.startValue+E*F(y,u,E),!d&&A===k.currentValue)continue;(k.currentValue=A,"tween"===T)?m=A:(x.Hooks.registered[T]&&(j=x.Hooks.getRoot(T),H=i(w).rootPropertyValueCache[j],H&&(k.rootPropertyValue=H)),N=x.setPropertyValue(w,T,k.currentValue+(0===parseFloat(A)?"":k.unitType),k.rootPropertyValue,k.scrollData),x.Hooks.registered[T]&&(i(w).rootPropertyValueCache[j]=x.Normalizations.registered[j]?x.Normalizations.registered[j]("extract",null,N[1]):N[1]),"transform"===N[0]&&(V=!0))}u.mobileHA&&i(w).transformCache.translate3d===a&&(i(w).transformCache.translate3d="(0px, 0px, 0px)",V=!0);V&&x.flushTransformCache(w)}u.display!==a&&"none"!==u.display&&(v.State.calls[o][2].display=!1);u.visibility!==a&&"hidden"!==u.visibility&&(v.State.calls[o][2].visibility=!1);u.progress&&u.progress.call(s[1],s[1],y,Math.max(0,f+u.duration-t),f,m);1===y&&p(o)}v.State.isTicking&&P(c)}function p(e,t){var p,f,g,m;if(!v.State.calls[e])return!1;for(var r=v.State.calls[e][0],n=v.State.calls[e][1],o=v.State.calls[e][2],s=v.State.calls[e][4],l=!1,u=0,c=r.length;c>u;u++){if(p=r[u].element,(t||o.loop||("none"===o.display&&x.setPropertyValue(p,"display",o.display),"hidden"===o.visibility&&x.setPropertyValue(p,"visibility",o.visibility)),o.loop!==!0&&($.queue(p)[1]===a||!/\.velocityQueueEntryFlag/i.test($.queue(p)[1]))&&i(p))&&(i(p).isAnimating=!1,i(p).rootPropertyValueCache={},f=!1,$.each(x.Lists.transforms3D,function(e,t){var r=/^scale/.test(t)?1:0,n=i(p).transformCache[t];i(p).transformCache[t]!==a&&new RegExp("^\\("+r+"[^.]").test(n)&&(f=!0,delete i(p).transformCache[t])}),o.mobileHA&&(f=!0,delete i(p).transformCache.translate3d),f&&x.flushTransformCache(p),x.Values.removeClass(p,"velocity-animating")),!t&&o.complete&&!o.loop&&u===c-1)try{o.complete.call(n,n)}catch(d){setTimeout(function(){throw d;},1)}s&&o.loop!==!0&&s(n);o.loop!==!0||t||($.each(i(p).tweensContainer,function(e,t){/^rotate/.test(e)&&360===parseFloat(t.endValue)&&(t.endValue=0,t.startValue=360);/^backgroundPosition/.test(e)&&100===parseFloat(t.endValue)&&"%"===t.unitType&&(t.endValue=0,t.startValue=100)}),v(p,"reverse",{loop:!0,delay:o.delay}));o.queue!==!1&&$.dequeue(p,o.queue)}for(v.State.calls[e]=!1,g=0,m=v.State.calls.length;m>g;g++)if(v.State.calls[g]!==!1){l=!0;break}l===!1&&(v.State.isTicking=!1,delete v.State.calls,v.State.calls=[])}var f=function(){var e,t;if(r.documentMode)return r.documentMode;for(e=7;e>4;e--)if(t=r.createElement("div"),t.innerHTML="",t.getElementsByTagName("span").length)return t=null,e;return a}(),d=function(){var e=0;return t.webkitRequestAnimationFrame||t.mozRequestAnimationFrame||function(t){var r=(new Date).getTime(),a;return a=Math.max(0,16-(r-e)),e=r+a,setTimeout(function(){t(r+a)},a)}}(),g={isString:function(e){return"string"==typeof e},isArray:Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)},isFunction:function(e){return"[object Function]"===Object.prototype.toString.call(e)},isNode:function(e){return e&&e.nodeType},isNodeList:function(e){return"object"==typeof e&&/^\[object (HTMLCollection|NodeList|Object)\]$/.test(Object.prototype.toString.call(e))&&e.length!==a&&(0===e.length||"object"==typeof e[0]&&e[0].nodeType>0)},isWrapped:function(e){return e&&(e.jquery||t.Zepto&&t.Zepto.zepto.isZ(e))},isSVG:function(e){return t.SVGElement&&e instanceof t.SVGElement},isEmptyObject:function(e){for(var t in e)return!1;return!0}},$,m=!1,b,x,S,P;if(e.fn&&e.fn.jquery?($=e,m=!0):$=t.Velocity.Utilities,8>=f&&!m)throw new Error("Velocity: IE8 and below require jQuery to be loaded before Velocity.");if(7>=f)return void(jQuery.fn.velocity=jQuery.fn.animate);var y=400,h="swing",v={State:{isMobile:/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent),isAndroid:/Android/i.test(navigator.userAgent),isGingerbread:/Android 2\.3\.[3-7]/i.test(navigator.userAgent),isChrome:t.chrome,isFirefox:/Firefox/i.test(navigator.userAgent),prefixElement:r.createElement("div"),prefixMatches:{},scrollAnchor:null,scrollPropertyLeft:null,scrollPropertyTop:null,isTicking:!1,calls:[]},CSS:{},Utilities:$,Redirects:{},Easings:{},Promise:t.Promise,defaults:{queue:"",duration:y,easing:h,begin:a,complete:a,progress:a,display:a,visibility:a,loop:!1,delay:!1,mobileHA:!0,_cacheValues:!0},init:function(e){$.data(e,"velocity",{isSVG:g.isSVG(e),isAnimating:!1,computedStyle:null,tweensContainer:null,rootPropertyValueCache:{},transformCache:{}})},hook:null,mock:!1,version:{major:1,minor:2,patch:1},debug:!1};return t.pageYOffset!==a?(v.State.scrollAnchor=t,v.State.scrollPropertyLeft="pageXOffset",v.State.scrollPropertyTop="pageYOffset"):(v.State.scrollAnchor=r.documentElement||r.body.parentNode||r.body,v.State.scrollPropertyLeft="scrollLeft",v.State.scrollPropertyTop="scrollTop"),b=function(){function e(e){return-e.tension*e.x-e.friction*e.v}function t(t,r,a){var n={x:t.x+a.dx*r,v:t.v+a.dv*r,tension:t.tension,friction:t.friction};return{dx:n.v,dv:e(n)}}function r(r,a){var n={dx:r.v,dv:e(r)},o=t(r,.5*a,n),i=t(r,.5*a,o),s=t(r,a,i),l=1/6*(n.dx+2*(o.dx+i.dx)+s.dx),u=1/6*(n.dv+2*(o.dv+i.dv)+s.dv);return r.x=r.x+l*a,r.v=r.v+u*a,r}return function a(e,t,n){var o={x:-1,v:0,tension:null,friction:null},i=[0],s=0,l=.0001,u=.016,c,p,f;for(e=parseFloat(e)||500,t=parseFloat(t)||20,n=n||null,o.tension=e,o.friction=t,c=null!==n,c?(s=a(e,t),p=s/n*u):p=u;;)if(f=r(f||o,p),i.push(1+f.x),s+=16,!(Math.abs(f.x)>l&&Math.abs(f.v)>l))break;return c?function(e){return i[e*(i.length-1)|0]}:s}}(),v.Easings={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},spring:function(e){return 1-Math.cos(4.5*e*Math.PI)*Math.exp(6*-e)}},$.each([["ease",[.25,.1,.25,1]],["ease-in",[.42,0,1,1]],["ease-out",[0,0,.58,1]],["ease-in-out",[.42,0,.58,1]],["easeInSine",[.47,0,.745,.715]],["easeOutSine",[.39,.575,.565,1]],["easeInOutSine",[.445,.05,.55,.95]],["easeInQuad",[.55,.085,.68,.53]],["easeOutQuad",[.25,.46,.45,.94]],["easeInOutQuad",[.455,.03,.515,.955]],["easeInCubic",[.55,.055,.675,.19]],["easeOutCubic",[.215,.61,.355,1]],["easeInOutCubic",[.645,.045,.355,1]],["easeInQuart",[.895,.03,.685,.22]],["easeOutQuart",[.165,.84,.44,1]],["easeInOutQuart",[.77,0,.175,1]],["easeInQuint",[.755,.05,.855,.06]],["easeOutQuint",[.23,1,.32,1]],["easeInOutQuint",[.86,0,.07,1]],["easeInExpo",[.95,.05,.795,.035]],["easeOutExpo",[.19,1,.22,1]],["easeInOutExpo",[1,0,0,1]],["easeInCirc",[.6,.04,.98,.335]],["easeOutCirc",[.075,.82,.165,1]],["easeInOutCirc",[.785,.135,.15,.86]]],function(e,t){v.Easings[t[0]]=l.apply(null,t[1])}),x=v.CSS={RegEx:{isHex:/^#([A-f\d]{3}){1,2}$/i,valueUnwrap:/^[A-z]+\((.*)\)$/i,wrappedValueAlreadyExtracted:/[0-9.]+ [0-9.]+ [0-9.]+( [0-9.]+)?/,valueSplit:/([A-z]+\(.+\))|(([A-z0-9#-.]+?)(?=\s|$))/gi},Lists:{colors:["fill","stroke","stopColor","color","backgroundColor","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor","outlineColor"],transformsBase:["translateX","translateY","scale","scaleX","scaleY","skewX","skewY","rotateZ"],transforms3D:["transformPerspective","translateZ","scaleZ","rotateX","rotateY"]},Hooks:{templates:{textShadow:["Color X Y Blur","black 0px 0px 0px"],boxShadow:["Color X Y Blur Spread","black 0px 0px 0px 0px"],clip:["Top Right Bottom Left","0px 0px 0px 0px"],backgroundPosition:["X Y","0% 0%"],transformOrigin:["X Y Z","50% 50% 0px"],perspectiveOrigin:["X Y","50% 50%"]},registered:{},register:function(){for(var t,r,a,n,o,i,s,e=0;e=f)switch(e){case"name":return"filter";case"extract":var a=r.toString().match(/alpha\(opacity=(.*)\)/i);return a?a[1]/100:1;case"inject":return t.style.zoom=1,parseFloat(r)>=1?"":"alpha(opacity="+parseInt(100*parseFloat(r),10)+")"}else switch(e){case"name":return"opacity";case"extract":return r;case"inject":return r}}},register:function(){var e;for(9>=f||v.State.isGingerbread||(x.Lists.transformsBase=x.Lists.transformsBase.concat(x.Lists.transforms3D)),e=0;en&&(n=1);o=!/(\d)$/i.test(n);break;case"skew":o=!/(deg|\d)$/i.test(n);break;case"rotate":o=!/(deg|\d)$/i.test(n)}return o||(i(r).transformCache[t]="("+n+")"),i(r).transformCache[t]}}}();for(e=0;e=f||3!==o.split(" ").length||(o+=" 1"),o;case"inject":return 8>=f?4===n.split(" ").length&&(n=n.split(/\s+/).slice(0,3).join(" ")):3===n.split(" ").length&&(n+=" 1"),(8>=f?"rgb":"rgba")+"("+n.replace(/\s+/g,",").replace(/\.(\d)+(?=,)/g,"")+")"}}}()}},Names:{camelCase:function(e){return e.replace(/-(\w)/g,function(e,t){return t.toUpperCase()})},SVGAttribute:function(e){var t="width|height|x|y|cx|cy|r|rx|ry|x1|x2|y1|y2";return(f||v.State.isAndroid&&!v.State.isChrome)&&(t+="|transform"),new RegExp("^("+t+")$","i").test(e)},prefixCheck:function(e){var n;if(v.State.prefixMatches[e])return[v.State.prefixMatches[e],!0];for(var t=["","Webkit","Moz","ms","O"],r=0,a=t.length;a>r;r++)if(n=0===r?e:t[r]+e.replace(/^\w/,function(e){return e.toUpperCase()}),g.isString(v.State.prefixElement.style[n]))return v.State.prefixMatches[e]=n,[n,!0];return[e,!1]}},Values:{hexToRgb:function(e){var a;return e=e.replace(/^#?([a-f\d])([a-f\d])([a-f\d])$/i,function(e,t,r,a){return t+t+r+r+a+a}),a=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e),a?[parseInt(a[1],16),parseInt(a[2],16),parseInt(a[3],16)]:[0,0,0]},isCSSNullValue:function(e){return 0==e||/^(none|auto|transparent|(rgba\(0, ?0, ?0, ?0\)))$/i.test(e)},getUnitType:function(e){return/^(rotate|skew)/i.test(e)?"deg":/(^(scale|scaleX|scaleY|scaleZ|alpha|flexGrow|flexHeight|zIndex|fontWeight)$)|((opacity|red|green|blue|alpha)$)/i.test(e)?"":"px"},getDisplayType:function(e){var t=e&&e.tagName.toString().toLowerCase();return/^(b|big|i|small|tt|abbr|acronym|cite|code|dfn|em|kbd|strong|samp|var|a|bdo|br|img|map|object|q|script|span|sub|sup|button|input|label|select|textarea)$/i.test(t)?"inline":/^(li)$/i.test(t)?"list-item":/^(tr)$/i.test(t)?"table-row":/^(table)$/i.test(t)?"table":/^(tbody)$/i.test(t)?"table-row-group":"block"},addClass:function(e,t){e.classList?e.classList.add(t):e.className+=(e.className.length?" ":"")+t},removeClass:function(e,t){e.classList?e.classList.remove(t):e.className=e.className.toString().replace(new RegExp("(^|\\s)"+t.split(" ").join("|")+"(\\s|$)","gi")," ")}},getPropertyValue:function(e,r,n,o){function s(e,r){function n(){u&&x.setPropertyValue(e,"display","none")}var l=0,u,c,p,d,g;if(8>=f)l=$.css(e,r);else{if(u=!1,/^(width|height)$/.test(r)&&0===x.getPropertyValue(e,"display")&&(u=!0,x.setPropertyValue(e,"display",x.Values.getDisplayType(e))),!o){if("height"===r&&"border-box"!==x.getPropertyValue(e,"boxSizing").toString().toLowerCase())return c=e.offsetHeight-(parseFloat(x.getPropertyValue(e,"borderTopWidth"))||0)-(parseFloat(x.getPropertyValue(e,"borderBottomWidth"))||0)-(parseFloat(x.getPropertyValue(e,"paddingTop"))||0)-(parseFloat(x.getPropertyValue(e,"paddingBottom"))||0),n(),c;if("width"===r&&"border-box"!==x.getPropertyValue(e,"boxSizing").toString().toLowerCase())return p=e.offsetWidth-(parseFloat(x.getPropertyValue(e,"borderLeftWidth"))||0)-(parseFloat(x.getPropertyValue(e,"borderRightWidth"))||0)-(parseFloat(x.getPropertyValue(e,"paddingLeft"))||0)-(parseFloat(x.getPropertyValue(e,"paddingRight"))||0),n(),p}d=i(e)===a?t.getComputedStyle(e,null):i(e).computedStyle?i(e).computedStyle:i(e).computedStyle=t.getComputedStyle(e,null);"borderColor"===r&&(r="borderTopColor");l=9===f&&"filter"===r?d.getPropertyValue(r):d[r];(""===l||null===l)&&(l=e.style[r]);n()}return"auto"===l&&/^(top|right|bottom|left)$/i.test(r)&&(g=s(e,"position"),("fixed"===g||"absolute"===g&&/top|left/i.test(r))&&(l=$(e).position()[r]+"px")),l}var l,u,c,p,d;if(x.Hooks.registered[r]?(u=r,c=x.Hooks.getRoot(u),n===a&&(n=x.getPropertyValue(e,x.Names.prefixCheck(c)[0])),x.Normalizations.registered[c]&&(n=x.Normalizations.registered[c]("extract",e,n)),l=x.Hooks.extractValue(u,n)):x.Normalizations.registered[r]&&(p=x.Normalizations.registered[r]("name",e),"transform"!==p&&(d=s(e,x.Names.prefixCheck(p)[0]),x.Values.isCSSNullValue(d)&&x.Hooks.templates[r]&&(d=x.Hooks.templates[r][1])),l=x.Normalizations.registered[r]("extract",e,d)),!/^[\d-]/.test(l))if(i(e)&&i(e).isSVG&&x.Names.SVGAttribute(r))if(/^(height|width)$/i.test(r))try{l=e.getBBox()[r]}catch(g){l=0}else l=e.getAttribute(r);else l=s(e,x.Names.prefixCheck(r)[0]);return x.Values.isCSSNullValue(l)&&(l=0),v.debug>=2&&console.log("Get "+r+": "+l),l},setPropertyValue:function(e,r,a,n,o){var s=r,l,u;if("scroll"===r)o.container?o.container["scroll"+o.direction]=a:"Left"===o.direction?t.scrollTo(a,o.alternateValue):t.scrollTo(o.alternateValue,a);else if(x.Normalizations.registered[r]&&"transform"===x.Normalizations.registered[r]("name",e))x.Normalizations.registered[r]("inject",e,a),s="transform",a=i(e).transformCache[r];else{if(x.Hooks.registered[r]&&(l=r,u=x.Hooks.getRoot(r),n=n||x.getPropertyValue(e,u),a=x.Hooks.injectValue(l,a,n),r=u),x.Normalizations.registered[r]&&(a=x.Normalizations.registered[r]("inject",e,a),r=x.Normalizations.registered[r]("name",e)),s=x.Names.prefixCheck(r)[0],8>=f)try{e.style[s]=a}catch(c){v.debug&&console.log("Browser does not support ["+a+"] for ["+s+"]")}else i(e)&&i(e).isSVG&&x.Names.SVGAttribute(r)?e.setAttribute(r,a):e.style[s]=a;v.debug>=2&&console.log("Set "+r+" ("+s+"): "+a)}return[s,a]},flushTransformCache:function(e){function t(t){return parseFloat(x.getPropertyValue(e,t))}var r="",a,n,o;(f||v.State.isAndroid&&!v.State.isChrome)&&i(e).isSVG?(a={translate:[t("translateX"),t("translateY")],skewX:[t("skewX")],skewY:[t("skewY")],scale:1!==t("scale")?[t("scale"),t("scale")]:[t("scaleX"),t("scaleY")],rotate:[t("rotateZ"),0,0]},$.each(i(e).transformCache,function(e){/^translate/i.test(e)?e="translate":/^scale/i.test(e)?e="scale":/^rotate/i.test(e)&&(e="rotate");a[e]&&(r+=e+"("+a[e].join(" ")+") ",delete a[e])})):($.each(i(e).transformCache,function(t){return n=i(e).transformCache[t],"transformPerspective"===t?(o=n,!0):(9===f&&"rotateZ"===t&&(t="rotate"),void(r+=t+n+" "))}),o&&(r="perspective"+o+" "+r));x.setPropertyValue(e,"transform",r)}},x.Hooks.register(),x.Normalizations.register(),v.hook=function(e,t,r){var n=a;return e=o(e),$.each(e,function(e,o){if(i(o)===a&&v.init(o),r===a)n===a&&(n=v.CSS.getPropertyValue(o,t));else{var s=v.CSS.setPropertyValue(o,t,r);"transform"===s[0]&&v.CSS.flushTransformCache(o);n=s}}),n},S=function(){function e(){return l?T.promise||null:f}function n(){function e(){function p(e,t){var r=a,i=a,s=a;return g.isArray(e)?(r=e[0],!g.isArray(e[1])&&/^[\d-]/.test(e[1])||g.isFunction(e[1])||x.RegEx.isHex.test(e[1])?s=e[1]:(g.isString(e[1])&&!x.RegEx.isHex.test(e[1])||g.isArray(e[1]))&&(i=t?e[1]:u(e[1],o.duration),e[2]!==a&&(s=e[2]))):r=e,t||(i=i||o.easing),g.isFunction(r)&&(r=r.call(n,w,P)),g.isFunction(s)&&(s=s.call(n,w,P)),[r||0,i,s]}function f(e,t){var r,a;return a=(t||"0").toString().toLowerCase().replace(/[%A-z]+$/,function(e){return r=e,""}),r||(r=x.Values.getUnitType(e)),[a,r]}function d(){var e={myParent:n.parentNode||r.body,position:x.getPropertyValue(n,"position"),fontSize:x.getPropertyValue(n,"fontSize")},a=e.position===N.lastPosition&&e.myParent===N.lastParent,o=e.fontSize===N.lastFontSize,s,l,u;return N.lastParent=e.myParent,N.lastPosition=e.position,N.lastFontSize=e.fontSize,s=100,l={},o&&a?(l.emToPx=N.lastEmToPx,l.percentToPxWidth=N.lastPercentToPxWidth,l.percentToPxHeight=N.lastPercentToPxHeight):(u=i(n).isSVG?r.createElementNS("http://www.w3.org/2000/svg","rect"):r.createElement("div"),v.init(u),e.myParent.appendChild(u),$.each(["overflow","overflowX","overflowY"],function(e,t){v.CSS.setPropertyValue(u,t,"hidden")}),v.CSS.setPropertyValue(u,"position",e.position),v.CSS.setPropertyValue(u,"fontSize",e.fontSize),v.CSS.setPropertyValue(u,"boxSizing","content-box"),$.each(["minWidth","maxWidth","width","minHeight","maxHeight","height"],function(e,t){v.CSS.setPropertyValue(u,t,s+"%")}),v.CSS.setPropertyValue(u,"paddingLeft",s+"em"),l.percentToPxWidth=N.lastPercentToPxWidth=(parseFloat(x.getPropertyValue(u,"width",null,!0))||1)/s,l.percentToPxHeight=N.lastPercentToPxHeight=(parseFloat(x.getPropertyValue(u,"height",null,!0))||1)/s,l.emToPx=N.lastEmToPx=(parseFloat(x.getPropertyValue(u,"paddingLeft"))||1)/s,e.myParent.removeChild(u)),null===N.remToPx&&(N.remToPx=parseFloat(x.getPropertyValue(r.body,"fontSize"))||16),null===N.vwToPx&&(N.vwToPx=parseFloat(t.innerWidth)/100,N.vhToPx=parseFloat(t.innerHeight)/100),l.remToPx=N.remToPx,l.vwToPx=N.vwToPx,l.vhToPx=N.vhToPx,v.debug>=1&&console.log("Unit ratios: "+JSON.stringify(l),n),l}var S,V,C,A,F,j,H,E,R,I,B,W,G,D,X,Y;if(o.begin&&0===w)try{o.begin.call(m,m)}catch(y){setTimeout(function(){throw y;},1)}if("scroll"===k)S=/^x$/i.test(o.axis)?"Left":"Top",V=parseFloat(o.offset)||0,o.container?g.isWrapped(o.container)||g.isNode(o.container)?(o.container=o.container[0]||o.container,C=o.container["scroll"+S],F=C+$(n).position()[S.toLowerCase()]+V):o.container=null:(C=v.State.scrollAnchor[v.State["scrollProperty"+S]],A=v.State.scrollAnchor[v.State["scrollProperty"+("Left"===S?"Top":"Left")]],F=$(n).offset()[S.toLowerCase()]+V),s={scroll:{rootPropertyValue:!1,startValue:C,currentValue:C,endValue:F,unitType:"",easing:o.easing,scrollData:{container:o.container,direction:S,alternateValue:A}},element:n},v.debug&&console.log("tweensContainer (scroll): ",s.scroll,n);else if("reverse"===k){if(!i(n).tweensContainer)return void $.dequeue(n,o.queue);"none"===i(n).opts.display&&(i(n).opts.display="auto");"hidden"===i(n).opts.visibility&&(i(n).opts.visibility="visible");i(n).opts.loop=!1;i(n).opts.begin=null;i(n).opts.complete=null;b.easing||delete o.easing;b.duration||delete o.duration;o=$.extend({},i(n).opts,o);E=$.extend(!0,{},i(n).tweensContainer);for(j in E)"element"!==j&&(H=E[j].startValue,E[j].startValue=E[j].currentValue=E[j].endValue,E[j].endValue=H,g.isEmptyObject(b)||(E[j].easing=o.easing),v.debug&&console.log("reverse tweensContainer ("+j+"): "+JSON.stringify(E[j]),n));s=E}else if("start"===k){i(n).tweensContainer&&i(n).isAnimating===!0&&(E=i(n).tweensContainer);$.each(h,function(e,t){var f;if(RegExp("^"+x.Lists.colors.join("$|^")+"$").test(e)){var r=p(t,!0),n=r[0],o=r[1],i=r[2];if(x.RegEx.isHex.test(n)){for(var s=["Red","Green","Blue"],l=x.Values.hexToRgb(n),u=i?x.Values.hexToRgb(i):a,c=0;cO;O++)z={delay:F.delay,progress:F.progress},O===R-1&&(z.display=F.display,z.visibility=F.visibility,z.complete=F.complete),S(m,"reverse",z);return e()}},v=$.extend(S,v),v.animate=S,P=t.requestAnimationFrame||d,v.State.isMobile||r.hidden===a||r.addEventListener("visibilitychange",function(){r.hidden?(P=function(e){return setTimeout(function(){e(!0)},16)},c()):P=t.requestAnimationFrame||d}),e.Velocity=v,e!==t&&(e.fn.velocity=S,e.fn.velocity.defaults=v.defaults),$.each(["Down","Up"],function(e,t){v.Redirects["slide"+t]=function(e,r,n,o,i,s){var l=$.extend({},r),u=l.begin,c=l.complete,p={height:"",marginTop:"",marginBottom:"",paddingTop:"",paddingBottom:""},f={};l.display===a&&(l.display="Down"===t?"inline"===v.CSS.Values.getDisplayType(e)?"inline-block":"block":"none");l.begin=function(){var r,a;u&&u.call(i,i);for(r in p)f[r]=e.style[r],a=v.CSS.getPropertyValue(e,r),p[r]="Down"===t?[a,0]:[0,a];f.overflow=e.style.overflow;e.style.overflow="hidden"};l.complete=function(){for(var t in f)e.style[t]=f[t];c&&c.call(i,i);s&&s.resolver(i)};v(e,p,l)}}),$.each(["In","Out"],function(e,t){v.Redirects["fade"+t]=function(e,r,n,o,i,s){var l=$.extend({},r),u={opacity:"In"===t?1:0},c=l.complete;l.complete=n!==o-1?l.begin=null:function(){c&&c.call(i,i);s&&s.resolver(i)};l.display===a&&(l.display="In"===t?"auto":"none");v(this,u,l)}}),v}(window.jQuery||window.Zepto||window,window,document)});typeof Object.create!="function"&&(Object.create=function(obj){function F(){}return F.prototype=obj,new F}),function($,window,document){var Carousel={init:function(options,el){var base=this;base.$elem=$(el);base.options=$.extend({},$.fn.owlCarousel.options,base.$elem.data(),options);base.userOptions=options;base.loadContent()},loadContent:function(){function getData(data){var i,content="";if(typeof base.options.jsonSuccess=="function")base.options.jsonSuccess.apply(this,[data]);else{for(i in data.owl)data.owl.hasOwnProperty(i)&&(content+=data.owl[i].item);base.$elem.html(content)}base.logIn()}var base=this,url;typeof base.options.beforeInit=="function"&&base.options.beforeInit.apply(this,[base.$elem]);typeof base.options.jsonPath=="string"?(url=base.options.jsonPath,$.getJSON(url,getData)):base.logIn()},logIn:function(){var base=this;base.$elem.data({"owl-originalStyles":base.$elem.attr("style"),"owl-originalClasses":base.$elem.attr("class")});base.$elem.css({opacity:0});base.orignalItems=base.options.items;base.checkBrowser();base.wrapperWidth=0;base.checkVisible=null;base.setVars()},setVars:function(){var base=this;if(base.$elem.children().length===0)return!1;base.baseClass();base.eventTypes();base.$userItems=base.$elem.children();base.itemsAmount=base.$userItems.length;base.wrapItems();base.$owlItems=base.$elem.find(".owl-item");base.$owlWrapper=base.$elem.find(".owl-wrapper");base.playDirection="next";base.prevItem=0;base.prevArr=[0];base.currentItem=0;base.customEvents();base.onStartup()},onStartup:function(){var base=this;base.updateItems();base.calculateAll();base.buildControls();base.updateControls();base.response();base.moveEvents();base.stopOnHover();base.owlStatus();base.options.transitionStyle!==!1&&base.transitionTypes(base.options.transitionStyle);base.options.autoPlay===!0&&(base.options.autoPlay=5e3);base.play();base.$elem.find(".owl-wrapper").css("display","block");base.$elem.is(":visible")?base.$elem.css("opacity",1):base.watchVisibility();base.onstartup=!1;base.eachMoveUpdate();typeof base.options.afterInit=="function"&&base.options.afterInit.apply(this,[base.$elem])},eachMoveUpdate:function(){var base=this;base.options.lazyLoad===!0&&base.lazyLoad();base.options.autoHeight===!0&&base.autoHeight();base.onVisibleItems();typeof base.options.afterAction=="function"&&base.options.afterAction.apply(this,[base.$elem])},updateVars:function(){var base=this;typeof base.options.beforeUpdate=="function"&&base.options.beforeUpdate.apply(this,[base.$elem]);base.watchVisibility();base.updateItems();base.calculateAll();base.updatePosition();base.updateControls();base.eachMoveUpdate();typeof base.options.afterUpdate=="function"&&base.options.afterUpdate.apply(this,[base.$elem])},reload:function(){var base=this;window.setTimeout(function(){base.updateVars()},0)},watchVisibility:function(){var base=this;if(base.$elem.is(":visible")===!1)base.$elem.css({opacity:0}),window.clearInterval(base.autoPlayInterval),window.clearInterval(base.checkVisible);else return!1;base.checkVisible=window.setInterval(function(){base.$elem.is(":visible")&&(base.reload(),base.$elem.animate({opacity:1},200),window.clearInterval(base.checkVisible))},500)},wrapItems:function(){var base=this;base.$userItems.wrapAll('
').wrap('
<\/div>');base.$elem.find(".owl-wrapper").wrap('
');base.wrapperOuter=base.$elem.find(".owl-wrapper-outer");base.$elem.css("display","block")},baseClass:function(){var base=this,hasBaseClass=base.$elem.hasClass(base.options.baseClass),hasThemeClass=base.$elem.hasClass(base.options.theme);hasBaseClass||base.$elem.addClass(base.options.baseClass);hasThemeClass||base.$elem.addClass(base.options.theme)},updateItems:function(){var base=this,width,i;if(base.options.responsive===!1)return!1;if(base.options.singleItem===!0)return base.options.items=base.orignalItems=1,base.options.itemsCustom=!1,base.options.itemsDesktop=!1,base.options.itemsDesktopSmall=!1,base.options.itemsTablet=!1,base.options.itemsTabletSmall=!1,base.options.itemsMobile=!1,!1;if(width=$(base.options.responsiveBaseWidth).width(),width>(base.options.itemsDesktop[0]||base.orignalItems)&&(base.options.items=base.orignalItems),base.options.itemsCustom!==!1)for(base.options.itemsCustom.sort(function(a,b){return a[0]-b[0]}),i=0;ibase.itemsAmount&&base.options.itemsScaleUp===!0&&(base.options.items=base.itemsAmount)},response:function(){var base=this,smallDelay,lastWindowWidth;if(base.options.responsive!==!0)return!1;lastWindowWidth=$(window).width();base.resizer=function(){$(window).width()!==lastWindowWidth&&(base.options.autoPlay!==!1&&window.clearInterval(base.autoPlayInterval),window.clearTimeout(smallDelay),smallDelay=window.setTimeout(function(){lastWindowWidth=$(window).width();base.updateVars()},base.options.responsiveRefreshRate))};$(window).resize(base.resizer)},updatePosition:function(){var base=this;base.jumpTo(base.currentItem);base.options.autoPlay!==!1&&base.checkAp()},appendItemsSizes:function(){var base=this,roundPages=0,lastItem=base.itemsAmount-base.options.items;base.$owlItems.each(function(index){var $this=$(this);$this.css({width:base.itemWidth}).data("owl-item",Number(index));(index%base.options.items==0||index===lastItem)&&(index>lastItem||(roundPages+=1));$this.data("owl-roundPages",roundPages)})},appendWrapperSizes:function(){var base=this,width=base.$owlItems.length*base.itemWidth;base.$owlWrapper.css({width:width*2,left:0});base.appendItemsSizes()},calculateAll:function(){var base=this;base.calculateWidth();base.appendWrapperSizes();base.loops();base.max()},calculateWidth:function(){var base=this;base.itemWidth=Math.round(base.$elem.width()/base.options.items)},max:function(){var base=this,maximum=(base.itemsAmount*base.itemWidth-base.options.items*base.itemWidth)*-1;return base.options.items>base.itemsAmount?(base.maximumItem=0,maximum=0,base.maximumPixels=0):(base.maximumItem=base.itemsAmount-base.options.items,base.maximumPixels=maximum),maximum},min:function(){return 0},loops:function(){var base=this,prev=0,elWidth=0,i,item,roundPageNum;for(base.positionsInArray=[0],base.pagesInArray=[],i=0;i').toggleClass("clickable",!base.browser.isTouch).appendTo(base.$elem));base.options.pagination===!0&&base.buildPagination();base.options.navigation===!0&&base.buildButtons()},buildButtons:function(){var base=this,buttonsWrapper=$('
');base.owlControls.append(buttonsWrapper);base.buttonPrev=$("
",{"class":"owl-prev",html:base.options.navigationText[0]||""});base.buttonNext=$("
",{"class":"owl-next",html:base.options.navigationText[1]||""});buttonsWrapper.append(base.buttonPrev).append(base.buttonNext);buttonsWrapper.on("touchstart.owlControls mousedown.owlControls",'div[class^="owl"]',function(event){event.preventDefault()});buttonsWrapper.on("touchend.owlControls mouseup.owlControls",'div[class^="owl"]',function(event){event.preventDefault();$(this).hasClass("owl-next")?base.next():base.prev()})},buildPagination:function(){var base=this;base.paginationWrapper=$('
');base.owlControls.append(base.paginationWrapper);base.paginationWrapper.on("touchend.owlControls mouseup.owlControls",".owl-page",function(event){event.preventDefault();Number($(this).data("owl-page"))!==base.currentItem&&base.goTo(Number($(this).data("owl-page")),!0)})},updatePagination:function(){var base=this,counter,lastPage,lastItem,i,paginationButton,paginationButtonInner;if(base.options.pagination===!1)return!1;for(base.paginationWrapper.html(""),counter=0,lastPage=base.itemsAmount-base.itemsAmount%base.options.items,i=0;i",{"class":"owl-page"}),paginationButtonInner=$("<\/span>",{text:base.options.paginationNumbers===!0?counter:"","class":base.options.paginationNumbers===!0?"owl-numbers":""}),paginationButton.append(paginationButtonInner),paginationButton.data("owl-page",lastPage===i?lastItem:i),paginationButton.data("owl-roundPages",counter),base.paginationWrapper.append(paginationButton));base.checkPagination()},checkPagination:function(){var base=this;if(base.options.pagination===!1)return!1;base.paginationWrapper.find(".owl-page").each(function(){$(this).data("owl-roundPages")===$(base.$owlItems[base.currentItem]).data("owl-roundPages")&&(base.paginationWrapper.find(".owl-page").removeClass("active"),$(this).addClass("active"))})},checkNavigation:function(){var base=this;if(base.options.navigation===!1)return!1;base.options.rewindNav===!1&&(base.currentItem===0&&base.maximumItem===0?(base.buttonPrev.addClass("disabled"),base.buttonNext.addClass("disabled")):base.currentItem===0&&base.maximumItem!==0?(base.buttonPrev.addClass("disabled"),base.buttonNext.removeClass("disabled")):base.currentItem===base.maximumItem?(base.buttonPrev.removeClass("disabled"),base.buttonNext.addClass("disabled")):base.currentItem!==0&&base.currentItem!==base.maximumItem&&(base.buttonPrev.removeClass("disabled"),base.buttonNext.removeClass("disabled")))},updateControls:function(){var base=this;base.updatePagination();base.checkNavigation();base.owlControls&&(base.options.items>=base.itemsAmount?base.owlControls.hide():base.owlControls.show())},destroyControls:function(){var base=this;base.owlControls&&base.owlControls.remove()},next:function(speed){var base=this;if(base.isTransition)return!1;if(base.currentItem+=base.options.scrollPerPage===!0?base.options.items:1,base.currentItem>base.maximumItem+(base.options.scrollPerPage===!0?base.options.items-1:0))if(base.options.rewindNav===!0)base.currentItem=0,speed="rewind";else return base.currentItem=base.maximumItem,!1;base.goTo(base.currentItem,speed)},prev:function(speed){var base=this;if(base.isTransition)return!1;if(base.options.scrollPerPage===!0&&base.currentItem>0&&base.currentItem=base.maximumItem?position=base.maximumItem:position<=0&&(position=0),base.currentItem=base.owl.currentItem=position,base.options.transitionStyle!==!1&&drag!=="drag"&&base.options.items===1&&base.browser.support3d===!0)return base.swapSpeed(0),base.browser.support3d===!0?base.transition3d(base.positionsInArray[position]):base.css2slide(base.positionsInArray[position],1),base.afterGo(),base.singleItemTransition(),!1;goToPixel=base.positionsInArray[position];base.browser.support3d===!0?(base.isCss3Finish=!1,speed===!0?(base.swapSpeed("paginationSpeed"),window.setTimeout(function(){base.isCss3Finish=!0},base.options.paginationSpeed)):speed==="rewind"?(base.swapSpeed(base.options.rewindSpeed),window.setTimeout(function(){base.isCss3Finish=!0},base.options.rewindSpeed)):(base.swapSpeed("slideSpeed"),window.setTimeout(function(){base.isCss3Finish=!0},base.options.slideSpeed)),base.transition3d(goToPixel)):speed===!0?base.css2slide(goToPixel,base.options.paginationSpeed):speed==="rewind"?base.css2slide(goToPixel,base.options.rewindSpeed):base.css2slide(goToPixel,base.options.slideSpeed);base.afterGo()},jumpTo:function(position){var base=this;typeof base.options.beforeMove=="function"&&base.options.beforeMove.apply(this,[base.$elem]);position>=base.maximumItem||position===-1?position=base.maximumItem:position<=0&&(position=0);base.swapSpeed(0);base.browser.support3d===!0?base.transition3d(base.positionsInArray[position]):base.css2slide(base.positionsInArray[position],1);base.currentItem=base.owl.currentItem=position;base.afterGo()},afterGo:function(){var base=this;base.prevArr.push(base.currentItem);base.prevItem=base.owl.prevItem=base.prevArr[base.prevArr.length-2];base.prevArr.shift(0);base.prevItem!==base.currentItem&&(base.checkPagination(),base.checkNavigation(),base.eachMoveUpdate(),base.options.autoPlay!==!1&&base.checkAp());typeof base.options.afterMove=="function"&&base.prevItem!==base.currentItem&&base.options.afterMove.apply(this,[base.$elem])},stop:function(){var base=this;base.apStatus="stop";window.clearInterval(base.autoPlayInterval)},checkAp:function(){var base=this;base.apStatus!=="stop"&&base.play()},play:function(){var base=this;if(base.apStatus="play",base.options.autoPlay===!1)return!1;window.clearInterval(base.autoPlayInterval);base.autoPlayInterval=window.setInterval(function(){base.next(!0)},base.options.autoPlay)},swapSpeed:function(action){var base=this;action==="slideSpeed"?base.$owlWrapper.css(base.addCssSpeed(base.options.slideSpeed)):action==="paginationSpeed"?base.$owlWrapper.css(base.addCssSpeed(base.options.paginationSpeed)):typeof action!="string"&&base.$owlWrapper.css(base.addCssSpeed(action))},addCssSpeed:function(speed){return{"-webkit-transition":"all "+speed+"ms ease","-moz-transition":"all "+speed+"ms ease","-o-transition":"all "+speed+"ms ease",transition:"all "+speed+"ms ease"}},removeTransition:function(){return{"-webkit-transition":"","-moz-transition":"","-o-transition":"",transition:""}},doTranslate:function(pixels){return{"-webkit-transform":"translate3d("+pixels+"px, 0px, 0px)","-moz-transform":"translate3d("+pixels+"px, 0px, 0px)","-o-transform":"translate3d("+pixels+"px, 0px, 0px)","-ms-transform":"translate3d("+pixels+"px, 0px, 0px)",transform:"translate3d("+pixels+"px, 0px,0px)"}},transition3d:function(value){var base=this;base.$owlWrapper.css(base.doTranslate(value))},css2move:function(value){var base=this;base.$owlWrapper.css({left:value})},css2slide:function(value,speed){var base=this;base.isCssFinish=!1;base.$owlWrapper.stop(!0,!0).animate({left:value},{duration:speed||base.options.slideSpeed,complete:function(){base.isCssFinish=!0}})},checkBrowser:function(){var base=this,translate3D="translate3d(0px, 0px, 0px)",tempElem=document.createElement("div"),regex,asSupport,support3d,isTouch,style;tempElem.style.cssText=" -moz-transform:"+translate3D+"; -ms-transform:"+translate3D+"; -o-transform:"+translate3D+"; -webkit-transform:"+translate3D+"; transform:"+translate3D;regex=/translate3d\(0px, 0px, 0px\)/g;asSupport=tempElem.style.cssText.match(regex);style=document.documentElement.style;support3d=style.webkitTransition!==undefined||style.MozTransition!==undefined||style.OTransition!==undefined||style.transition!==undefined;isTouch="ontouchstart"in window||window.navigator.msMaxTouchPoints;base.browser={support3d:support3d,isTouch:isTouch}},moveEvents:function(){var base=this;(base.options.mouseDrag!==!1||base.options.touchDrag!==!1)&&(base.gestures(),base.disabledEvents())},eventTypes:function(){var base=this,types=["s","e","x"];base.ev_types={};base.options.mouseDrag===!0&&base.options.touchDrag===!0?types=["touchstart.owl mousedown.owl","touchmove.owl mousemove.owl","touchend.owl touchcancel.owl mouseup.owl"]:base.options.mouseDrag===!1&&base.options.touchDrag===!0?types=["touchstart.owl","touchmove.owl","touchend.owl touchcancel.owl"]:base.options.mouseDrag===!0&&base.options.touchDrag===!1&&(types=["mousedown.owl","mousemove.owl","mouseup.owl"]);base.ev_types.start=types[0];base.ev_types.move=types[1];base.ev_types.end=types[2]},disabledEvents:function(){var base=this;base.$elem.on("dragstart.owl",function(event){event.preventDefault()});base.$elem.on("mousedown.disableTextSelect",function(e){return $(e.target).is("input, textarea, select, option")})},gestures:function(){function getTouches(event){if(event.touches!==undefined)return{x:event.touches[0].pageX,y:event.touches[0].pageY};if(event.touches===undefined){if(event.pageX!==undefined)return{x:event.pageX,y:event.pageY};if(event.pageX===undefined)return{x:event.clientX,y:event.clientY}}}function swapEvents(type){if(type==="on"){$(document).on(base.ev_types.move,dragMove);$(document).on(base.ev_types.end,dragEnd)}else type==="off"&&($(document).off(base.ev_types.move),$(document).off(base.ev_types.end))}function dragStart(event){var ev=event.originalEvent||event||window.event,position;if(ev.which===3)return!1;if(!(base.itemsAmount<=base.options.items)){if(base.isCssFinish===!1&&!base.options.dragBeforeAnimFinish||base.isCss3Finish===!1&&!base.options.dragBeforeAnimFinish)return!1;base.options.autoPlay!==!1&&window.clearInterval(base.autoPlayInterval);base.browser.isTouch===!0||base.$owlWrapper.hasClass("grabbing")||base.$owlWrapper.addClass("grabbing");base.newPosX=0;base.newRelativeX=0;$(this).css(base.removeTransition());position=$(this).position();locals.relativePos=position.left;locals.offsetX=getTouches(ev).x-position.left;locals.offsetY=getTouches(ev).y-position.top;swapEvents("on");locals.sliding=!1;locals.targetElement=ev.target||ev.srcElement}}function dragMove(event){var ev=event.originalEvent||event||window.event,minSwipe,maxSwipe;base.newPosX=getTouches(ev).x-locals.offsetX;base.newPosY=getTouches(ev).y-locals.offsetY;base.newRelativeX=base.newPosX-locals.relativePos;typeof base.options.startDragging=="function"&&locals.dragging!==!0&&base.newRelativeX!==0&&(locals.dragging=!0,base.options.startDragging.apply(base,[base.$elem]));(base.newRelativeX>8||base.newRelativeX<-8)&&base.browser.isTouch===!0&&(ev.preventDefault!==undefined?ev.preventDefault():ev.returnValue=!1,locals.sliding=!0);(base.newPosY>10||base.newPosY<-10)&&locals.sliding===!1&&$(document).off("touchmove.owl");minSwipe=function(){return base.newRelativeX/5};maxSwipe=function(){return base.maximumPixels+base.newRelativeX/5};base.newPosX=Math.max(Math.min(base.newPosX,minSwipe()),maxSwipe());base.browser.support3d===!0?base.transition3d(base.newPosX):base.css2move(base.newPosX)}function dragEnd(event){var ev=event.originalEvent||event||window.event,newPosition,handlers,owlStopEvent;if(ev.target=ev.target||ev.srcElement,locals.dragging=!1,base.browser.isTouch!==!0&&base.$owlWrapper.removeClass("grabbing"),base.dragDirection=base.newRelativeX<0?base.owl.dragDirection="left":base.owl.dragDirection="right",base.newRelativeX!==0&&(newPosition=base.getNewPosition(),base.goTo(newPosition,!1,"drag"),locals.targetElement===ev.target&&base.browser.isTouch!==!0)){$(ev.target).on("click.disable",function(ev){ev.stopImmediatePropagation();ev.stopPropagation();ev.preventDefault();$(ev.target).off("click.disable")});handlers=$._data(ev.target,"events").click;owlStopEvent=handlers.pop();handlers.splice(0,0,owlStopEvent)}swapEvents("off")}var base=this,locals={offsetX:0,offsetY:0,baseElWidth:0,relativePos:0,position:null,minSwipe:null,maxSwipe:null,sliding:null,dargging:null,targetElement:null};base.isCssFinish=!0;base.$elem.on(base.ev_types.start,".owl-wrapper",dragStart)},getNewPosition:function(){var base=this,newPosition=base.closestItem();return newPosition>base.maximumItem?(base.currentItem=base.maximumItem,newPosition=base.maximumItem):base.newPosX>=0&&(newPosition=0,base.currentItem=0),newPosition},closestItem:function(){var base=this,array=base.options.scrollPerPage===!0?base.pagesInArray:base.positionsInArray,goal=base.newPosX,closest=null;return $.each(array,function(i,v){goal-base.itemWidth/20>array[i+1]&&goal-base.itemWidth/20(array[i+1]||array[i]-base.itemWidth)&&base.moveDirection()==="right"&&(base.options.scrollPerPage===!0?(closest=array[i+1]||array[array.length-1],base.currentItem=$.inArray(closest,base.positionsInArray)):(closest=array[i+1],base.currentItem=i+1))}),base.currentItem},moveDirection:function(){var base=this,direction;return base.newRelativeX<0?(direction="right",base.playDirection="next"):(direction="left",base.playDirection="prev"),direction},customEvents:function(){var base=this;base.$elem.on("owl.next",function(){base.next()});base.$elem.on("owl.prev",function(){base.prev()});base.$elem.on("owl.play",function(event,speed){base.options.autoPlay=speed;base.play();base.hoverStatus="play"});base.$elem.on("owl.stop",function(){base.stop();base.hoverStatus="stop"});base.$elem.on("owl.goTo",function(event,item){base.goTo(item)});base.$elem.on("owl.jumpTo",function(event,item){base.jumpTo(item)})},stopOnHover:function(){var base=this;if(base.options.stopOnHover===!0&&base.browser.isTouch!==!0&&base.options.autoPlay!==!1){base.$elem.on("mouseover",function(){base.stop()});base.$elem.on("mouseout",function(){base.hoverStatus!=="stop"&&base.play()})}},lazyLoad:function(){var base=this,i,$item,itemNumber,$lazyImg,follow;if(base.options.lazyLoad===!1)return!1;for(i=0;i=base.currentItem:!0;follow&&itemNumber=base.$userItems.length||position===-1?base.$userItems.eq(-1).after(htmlString):base.$userItems.eq(position).before(htmlString);base.setVars()},removeItem:function(targetPosition){var base=this,position;if(base.$elem.children().length===0)return!1;position=targetPosition===undefined||targetPosition===-1?-1:targetPosition;base.unWrap();base.$userItems.eq(position).remove();base.setVars()}};$.fn.owlCarousel=function(options){return this.each(function(){if($(this).data("owl-init")===!0)return!1;$(this).data("owl-init",!0);var carousel=Object.create(Carousel);carousel.init(options,this);$.data(this,"owlCarousel",carousel)})};$.fn.owlCarousel.options={items:5,itemsCustom:!1,itemsDesktop:[1199,4],itemsDesktopSmall:[979,3],itemsTablet:[768,2],itemsTabletSmall:!1,itemsMobile:[479,1],singleItem:!1,itemsScaleUp:!1,slideSpeed:200,paginationSpeed:800,rewindSpeed:1e3,autoPlay:!1,stopOnHover:!1,navigation:!1,navigationText:["prev","next"],rewindNav:!0,scrollPerPage:!1,pagination:!0,paginationNumbers:!1,responsive:!0,responsiveRefreshRate:200,responsiveBaseWidth:window,baseClass:"owl-carousel",theme:"owl-theme",lazyLoad:!1,lazyFollow:!0,lazyEffect:"fade",autoHeight:!1,jsonPath:!1,jsonSuccess:!1,dragBeforeAnimFinish:!0,mouseDrag:!0,touchDrag:!0,addClassActive:!1,transitionStyle:!1,beforeUpdate:!1,afterUpdate:!1,beforeInit:!1,afterInit:!1,beforeMove:!1,afterMove:!1,afterAction:!1,startDragging:!1,afterLazyLoad:!1}}(jQuery,window,document); /*! * fancyBox - jQuery Plugin * version: 2.1.4 (Thu, 10 Jan 2013) * @requires jQuery v1.6 or later * * Examples at http://fancyapps.com/fancybox/ * License: www.fancyapps.com/fancybox/#license * * Copyright 2012 Janis Skarnelis - janis@fancyapps.com * */ (function(window,document,$,undefined){"use strict";var W=$(window),D=$(document),F=$.fancybox=function(){F.open.apply(this,arguments)},IE=navigator.userAgent.match(/msie/),didUpdate=null,isTouch=document.createTouch!==undefined,isQuery=function(obj){return obj&&obj.hasOwnProperty&&obj instanceof $},isString=function(str){return str&&$.type(str)==="string"},isPercentage=function(str){return isString(str)&&str.indexOf("%")>0},isScrollable=function(el){return el&&!(el.style.overflow&&el.style.overflow==="hidden")&&(el.clientWidth&&el.scrollWidth>el.clientWidth||el.clientHeight&&el.scrollHeight>el.clientHeight)},getScalar=function(orig,dim){var value=parseInt(orig,10)||0;return dim&&isPercentage(orig)&&(value=F.getViewport()[dim]/100*value),Math.ceil(value)},getValue=function(value,dim){return getScalar(value,dim)+"px"};$.extend(F,{version:"2.1.4",defaults:{padding:15,margin:20,width:800,height:600,minWidth:100,minHeight:100,maxWidth:9999,maxHeight:9999,autoSize:!0,autoHeight:!1,autoWidth:!1,autoResize:!0,autoCenter:!isTouch,fitToView:!0,aspectRatio:!1,topRatio:.5,leftRatio:.5,scrolling:"auto",wrapCSS:"",arrows:!0,closeBtn:!0,closeClick:!1,nextClick:!1,mouseWheel:!0,autoPlay:!1,playSpeed:3e3,preload:3,modal:!1,loop:!0,ajax:{dataType:"html",headers:{"X-fancyBox":!0}},iframe:{scrolling:"auto",preload:!0},swf:{wmode:"transparent",allowfullscreen:"true",allowscriptaccess:"always"},keys:{next:{13:"left",34:"up",39:"left",40:"up"},prev:{8:"right",33:"down",37:"right",38:"down"},close:[27],play:[32],toggle:[70]},direction:{next:"left",prev:"right"},scrollOutside:!0,index:0,type:null,href:null,content:null,title:null,tpl:{wrap:'
<\/div><\/div><\/div><\/div>',image:'',iframe:'