var cssua=function(e,o,i){"use strict";var s=" ua-",r=/\s*([\-\w ]+)[\s\/\:]([\d_]+\b(?:[\-\._\/]\w+)*)/,n=/([\w\-\.]+[\s\/][v]?[\d_]+\b(?:[\-\._\/]\w+)*)/g,a=/\b(?:(blackberry\w*|bb10)|(rim tablet os))(?:\/(\d+\.\d+(?:\.\w+)*))?/,b=/\bsilk-accelerated=true\b/,t=/\bfluidapp\b/,l=/(\bwindows\b|\bmacintosh\b|\blinux\b|\bunix\b)/,p=/(\bandroid\b|\bipad\b|\bipod\b|\bwindows phone\b|\bwpdesktop\b|\bxblwp7\b|\bzunewp7\b|\bwindows ce\b|\bblackberry\w*|\bbb10\b|\brim tablet os\b|\bmeego|\bwebos\b|\bpalm|\bsymbian|\bj2me\b|\bdocomo\b|\bpda\b|\bchtml\b|\bmidp\b|\bcldc\b|\w*?mobile\w*?|\w*?phone\w*?)/,c=/(\bxbox\b|\bplaystation\b|\bnintendo\s+\w+)/,d={parse:function(e,o){var i={};if(o&&(i.standalone=o),!(e=(""+e).toLowerCase()))return i;for(var s,d,m=e.split(/[()]/),w=0,_=m.length;w<_;w++)if(w%2){var u=m[w].split(";");for(s=0,d=u.length;s0;)i+=s+e+"-"+o.substring(0,r),r=o.indexOf("-",r+1);i+=s+e+"-"+o}return i}var i="";for(var r in e)r&&e.hasOwnProperty(r)&&(i+=o(r,e[r]));return i},encode:function(e){var o="";for(var i in e)i&&e.hasOwnProperty(i)&&(o&&(o+="&"),o+=encodeURIComponent(i)+"="+encodeURIComponent(e[i]));return o}};d.userAgent=d.ua=d.parse(o,i);var m=d.format(d.ua)+" js";return e.className?e.className=e.className.replace(/\bno-js\b/g,"")+m:e.className=m.substr(1),d}(document.documentElement,navigator.userAgent,navigator.standalone); !function(e,t,n){var r=[],o=[],a={_version:"3.5.0",_config:{classPrefix:"",enableClasses:!0,enableJSClass:!0,usePrefixes:!0},_q:[],on:function(e,t){var n=this;setTimeout(function(){t(n[e])},0)},addTest:function(e,t,n){o.push({name:e,fn:t,options:n})},addAsyncTest:function(e){o.push({name:null,fn:e})}},i=function(){};i.prototype=a,(i=new i).addTest("applicationcache","applicationCache"in e),i.addTest("geolocation","geolocation"in navigator),i.addTest("history",function(){var t=navigator.userAgent;return(-1===t.indexOf("Android 2.")&&-1===t.indexOf("Android 4.0")||-1===t.indexOf("Mobile Safari")||-1!==t.indexOf("Chrome")||-1!==t.indexOf("Windows Phone")||"file:"===location.protocol)&&(e.history&&"pushState"in e.history)}),i.addTest("postmessage","postMessage"in e);var s=!1;try{s="WebSocket"in e&&2===e.WebSocket.CLOSING}catch(e){}i.addTest("websockets",s),i.addTest("localstorage",function(){var e="modernizr";try{return localStorage.setItem(e,e),localStorage.removeItem(e),!0}catch(e){return!1}}),i.addTest("sessionstorage",function(){var e="modernizr";try{return sessionStorage.setItem(e,e),sessionStorage.removeItem(e),!0}catch(e){return!1}}),i.addTest("websqldatabase","openDatabase"in e),i.addTest("webworkers","Worker"in e);var l=a._config.usePrefixes?" -webkit- -moz- -o- -ms- ".split(" "):["",""];function c(e,t){return typeof e===t}a._prefixes=l;var d=t.documentElement,u="svg"===d.nodeName.toLowerCase();function f(e){var t=d.className,n=i._config.classPrefix||"";if(u&&(t=t.baseVal),i._config.enableJSClass){var r=new RegExp("(^|\\s)"+n+"no-js(\\s|$)");t=t.replace(r,"$1"+n+"js$2")}i._config.enableClasses&&(t+=" "+n+e.join(" "+n),u?d.className.baseVal=t:d.className=t)}var p,g,m=a._config.usePrefixes?"Moz O ms Webkit".toLowerCase().split(" "):[];function h(e,t){if("object"==typeof e)for(var n in e)p(e,n)&&h(n,e[n]);else{var r=(e=e.toLowerCase()).split("."),o=i[r[0]];if(2==r.length&&(o=o[r[1]]),void 0!==o)return i;t="function"==typeof t?t():t,1==r.length?i[r[0]]=t:(!i[r[0]]||i[r[0]]instanceof Boolean||(i[r[0]]=new Boolean(i[r[0]])),i[r[0]][r[1]]=t),f([(t&&0!=t?"":"no-")+r.join("-")]),i._trigger(e,t)}return i}function v(){return"function"!=typeof t.createElement?t.createElement(arguments[0]):u?t.createElementNS.call(t,"http://www.w3.org/2000/svg",arguments[0]):t.createElement.apply(t,arguments)}a._domPrefixes=m,p=c(g={}.hasOwnProperty,"undefined")||c(g.call,"undefined")?function(e,t){return t in e&&c(e.constructor.prototype[t],"undefined")}:function(e,t){return g.call(e,t)},a._l={},a.on=function(e,t){this._l[e]||(this._l[e]=[]),this._l[e].push(t),i.hasOwnProperty(e)&&setTimeout(function(){i._trigger(e,i[e])},0)},a._trigger=function(e,t){if(this._l[e]){var n=this._l[e];setTimeout(function(){var e;for(e=0;e7)}),i.addTest("audio",function(){var e=v("audio"),t=!1;try{(t=!!e.canPlayType)&&((t=new Boolean(t)).ogg=e.canPlayType('audio/ogg; codecs="vorbis"').replace(/^no$/,""),t.mp3=e.canPlayType('audio/mpeg; codecs="mp3"').replace(/^no$/,""),t.opus=e.canPlayType('audio/ogg; codecs="opus"')||e.canPlayType('audio/webm; codecs="opus"').replace(/^no$/,""),t.wav=e.canPlayType('audio/wav; codecs="1"').replace(/^no$/,""),t.m4a=(e.canPlayType("audio/x-m4a;")||e.canPlayType("audio/aac;")).replace(/^no$/,""))}catch(e){}return t}),i.addTest("canvas",function(){var e=v("canvas");return!(!e.getContext||!e.getContext("2d"))}),i.addTest("canvastext",function(){return!1!==i.canvas&&"function"==typeof v("canvas").getContext("2d").fillText}),i.addTest("video",function(){var e=v("video"),t=!1;try{(t=!!e.canPlayType)&&((t=new Boolean(t)).ogg=e.canPlayType('video/ogg; codecs="theora"').replace(/^no$/,""),t.h264=e.canPlayType('video/mp4; codecs="avc1.42E01E"').replace(/^no$/,""),t.webm=e.canPlayType('video/webm; codecs="vp8, vorbis"').replace(/^no$/,""),t.vp9=e.canPlayType('video/webm; codecs="vp9"').replace(/^no$/,""),t.hls=e.canPlayType('application/x-mpegURL; codecs="avc1.42E01E"').replace(/^no$/,""))}catch(e){}return t}),i.addTest("webgl",function(){var t=v("canvas"),n="probablySupportsContext"in t?"probablySupportsContext":"supportsContext";return n in t?t[n]("webgl")||t[n]("experimental-webgl"):"WebGLRenderingContext"in e}),i.addTest("cssgradients",function(){for(var e,t="background-image:",n="",r=0,o=l.length-1;r-1}),i.addTest("multiplebgs",function(){var e=v("a").style;return e.cssText="background:url(https://),url(https://),red url(https://)",/(url\s*\(.*?){3}/.test(e.background)}),i.addTest("opacity",function(){var e=v("a").style;return e.cssText=l.join("opacity:.55;"),/^0.55$/.test(e.opacity)}),i.addTest("rgba",function(){var e=v("a").style;return e.cssText="background-color:rgba(150,255,150,.5)",(""+e.backgroundColor).indexOf("rgba")>-1}),i.addTest("inlinesvg",function(){var e=v("div");return e.innerHTML="","http://www.w3.org/2000/svg"==("undefined"!=typeof SVGRect&&e.firstChild&&e.firstChild.namespaceURI)});var T=v("input"),x="autocomplete autofocus list placeholder max min multiple pattern required step".split(" "),w={};i.input=function(t){for(var n=0,r=t.length;n=9,R||L)?i.addTest("fontface",!1):N('@font-face {font-family:"font";src:url("https://")}',function(e,n){var r=t.getElementById("smodernizr"),o=r.sheet||r.styleSheet,a=o?o.cssRules&&o.cssRules[0]?o.cssRules[0].cssText:o.cssText||"":"",s=/src/i.test(a)&&0===a.indexOf(n.split(" ")[0]);i.addTest("fontface",s)}),N('#modernizr{font:0/0 a}#modernizr:after{content:":)";visibility:hidden;font:7px/1 a}',function(e){i.addTest("generatedcontent",e.offsetHeight>=6)});var j=a._config.usePrefixes?"Moz O ms Webkit".split(" "):[];a._cssomPrefixes=j;var M=function(t){var r,o=l.length,a=e.CSSRule;if(void 0===a)return n;if(!t)return!1;if((r=(t=t.replace(/^@/,"")).replace(/-/g,"_").toUpperCase()+"_RULE")in a)return"@"+t;for(var i=0;i1&&(r=window.devicePixelRatio,n.style.width=n.style.height=[t.size,"px"].join(""),n.width=n.height=t.size*r,i.scale(r,r)),i.translate(t.size/2,t.size/2),i.rotate((t.rotate/180-.5)*Math.PI);var o=(t.size-t.lineWidth)/2;t.scaleColor&&t.scaleLength&&(o-=t.scaleLength+2),Date.now=Date.now||function(){return+new Date};var s=function(e,t,a){var n=(a=Math.min(Math.max(-1,a||0),1))<=0;i.beginPath(),i.arc(0,0,o,0,2*Math.PI*a,n),i.strokeStyle=e,i.lineWidth=t,i.stroke()},d=window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||function(e){window.setTimeout(e,1e3/60)},h=function(){t.scaleColor&&function(){var e,a;i.lineWidth=1,i.fillStyle=t.scaleColor,i.save();for(var n=24;n>0;--n)n%6==0?(a=t.scaleLength,e=0):(a=.6*t.scaleLength,e=t.scaleLength-a),i.fillRect(-t.size/2+e,0,a,1),i.rotate(Math.PI/12);i.restore()}(),t.trackColor&&s(t.trackColor,t.trackWidth||t.lineWidth,1)};this.getCanvas=function(){return n},this.getCtx=function(){return i},this.clear=function(){i.clearRect(t.size/-2,t.size/-2,t.size,t.size)},this.draw=function(e){var n;t.scaleColor||t.trackColor?i.getImageData&&i.putImageData?a?i.putImageData(a,0,0):(h(),a=i.getImageData(0,0,t.size*r,t.size*r)):(this.clear(),h()):this.clear(),i.lineCap=t.lineCap,n="function"==typeof t.barColor?t.barColor(e):t.barColor,s(n,t.lineWidth,e/100)}.bind(this),this.animate=function(e,a){var n=Date.now();t.onStart(e,a);var i=function(){var r=Math.min(Date.now()-n,t.animate.duration),o=t.easing(this,r,e,a-e,t.animate.duration);this.draw(o),t.onStep(e,a,o),r>=t.animate.duration?t.onStop(e,a):d(i)}.bind(this);d(i)}.bind(this)};e.fn.easyPieChart=function(a){return this.each(function(){var n;e.data(this,"easyPieChart")||(n=e.extend({},a,e(this).data()),e.data(this,"easyPieChart",new function(e,a){var n={barColor:"#ef1e25",trackColor:"#f9f9f9",scaleColor:"#dfe0e0",scaleLength:5,lineCap:"round",lineWidth:3,trackWidth:void 0,size:110,rotate:0,animate:{duration:1e3,enabled:!0},easing:function(e,t,a,n,i){return(t/=i/2)<1?n/2*t*t+a:-n/2*(--t*(t-2)-1)+a},onStart:function(e,t){},onStep:function(e,t,a){},onStop:function(e,t){}};n.renderer=t;var i={},r=0,o=function(){for(var t in this.el=e,this.options=i,n)n.hasOwnProperty(t)&&(i[t]=a&&void 0!==a[t]?a[t]:n[t],"function"==typeof i[t]&&(i[t]=i[t].bind(this)));"string"==typeof i.easing&&"undefined"!=typeof jQuery&&jQuery.isFunction(jQuery.easing[i.easing])?i.easing=jQuery.easing[i.easing]:i.easing=n.easing,"number"==typeof i.animate&&(i.animate={duration:i.animate,enabled:!0}),"boolean"!=typeof i.animate||i.animate||(i.animate={duration:1e3,enabled:i.animate}),this.renderer=new i.renderer(e,i),this.renderer.draw(r),e.dataset&&e.dataset.percent?this.update(parseFloat(e.dataset.percent)):e.getAttribute&&e.getAttribute("data-percent")&&this.update(parseFloat(e.getAttribute("data-percent")))}.bind(this);this.update=function(e){return e=parseFloat(e),i.animate.enabled?this.renderer.animate(r,e):this.renderer.draw(e),r=e,this}.bind(this),this.disableAnimation=function(){return i.animate.enabled=!1,this},this.enableAnimation=function(){return i.animate.enabled=!0,this},o()}(this,n)))})}}); var fusionRecentPostsVars={"infinite_loading_text":"Loading the next set of posts...<\/em>","infinite_finished_msg":"All items displayed.<\/em>"};jQuery(window).on("load",function(){jQuery(".fusion-recent-posts-infinite .fusion-columns").each(function(){var i,n=jQuery(this),e=n.parent(),o="."+e.attr("class").replace(/\ /g,".")+" ",t=jQuery(this).find(".fusion-column");jQuery(n).infinitescroll({navSelector:o+".fusion-infinite-scroll-trigger",nextSelector:o+"a.pagination-next",itemSelector:o+"div.pagination .current, "+o+"article.post",loading:{finishedMsg:fusionRecentPostsVars.infinite_finished_msg,msg:jQuery('
'+fusionRecentPostsVars.infinite_loading_text+"
")},maxPage:e.data("pages")?e.data("pages"):void 0,errorCallback:function(){}},function(o){jQuery(o).hide(),imagesLoaded(o,function(){jQuery(o).fadeIn()}),fusionInitPostFlexSlider(),jQuery(o).each(function(){jQuery(this).find(".full-video, .video-shortcode, .wooslider .slide-content").fitVids()}),i=e.find(".current").html(),e.find(".current").remove(),e.data("pages")==i&&(e.find(".fusion-loading-container").hide(),e.find(".fusion-load-more-button").hide()),"individual"!==fusionRecentPostsVars.lightbox_behavior&&t.find(".fusion-post-slideshow").length||(window.avadaLightBox.activate_lightbox(jQuery(o)),t=n.find(".post")),window.avadaLightBox.refresh_lightbox(),setTimeout(function(){jQuery(window).trigger("resize",[!1])},500),jQuery.isFunction(jQuery.fn.initWaypoint)&&jQuery(window).initWaypoint(),"undefined"!=typeof niceScrollReInit&&niceScrollReInit()}),jQuery(e).hasClass("fusion-recent-posts-load-more")&&(jQuery(n).infinitescroll("unbind"),jQuery(e).find(".fusion-load-more-button").on("click",function(i){i.preventDefault(),jQuery(n).infinitescroll("retrieve")})),1===parseInt(e.data("pages"),10)&&(e.find(".fusion-loading-container").hide(),e.find(".fusion-load-more-button").hide())})}); !function(t){function e(e,n,i,s){var a=e.text().split(n),l="";a.length&&(t(a).each(function(t,e){l+=''+e+""+s}),e.empty().append(l))}var n={init:function(){return this.each(function(){e(t(this),"","char","")})},words:function(){return this.each(function(){e(t(this)," ","word"," ")})},lines:function(){return this.each(function(){var n="eefec303079ad17405c889e092e105b0";e(t(this).children("br").replaceWith(n).end(),n,"line","")})}};t.fn.lettering=function(e){return e&&n[e]?n[e].apply(this,[].slice.call(arguments,1)):"letters"!==e&&e?(t.error("Method "+e+" does not exist on jQuery.lettering"),this):n.init.apply(this,[].slice.call(arguments,0))}}(jQuery),function(t){"use strict";function e(e){return/In/.test(e)||t.inArray(e,t.fn.textillate.defaults.inEffects)>=0}function n(e){return/Out/.test(e)||t.inArray(e,t.fn.textillate.defaults.outEffects)>=0}function i(t){return"true"!==t&&"false"!==t?t:"true"===t}function s(e){var n=e.attributes||[],s={};return n.length?(t.each(n,function(t,e){var n=e.nodeName.replace(/delayscale/,"delayScale");/^data-in-*/.test(n)?(s.in=s.in||{},s.in[n.replace(/data-in-/,"")]=i(e.nodeValue)):/^data-out-*/.test(n)?(s.out=s.out||{},s.out[n.replace(/data-out-/,"")]=i(e.nodeValue)):/^data-*/.test(n)&&(s[n.replace(/data-/,"")]=i(e.nodeValue))}),s):s}function a(i,s,a){var l=i.length;l?(s.shuffle&&(i=function(t){for(var e,n,i=t.length;i;e=parseInt(Math.random()*i),n=t[--i],t[i]=t[e],t[e]=n);return t}(i)),s.reverse&&(i=i.toArray().reverse()),t.each(i,function(i,o){var c=t(o);function r(){e(s.effect)?"typeOut"===s.effect?c.css("display","inline-block"):c.css("visibility","visible"):n(s.effect)&&("typeOut"===s.effect?c.css("display","none"):c.css("visibility","hidden")),!(l-=1)&&a&&a()}var u=s.sync?s.delay:s.delay*i*s.delayScale;c.text()?setTimeout(function(){var t,e,n,i;t=c,e=s.effect,n=r,i=0,"clipIn"===e?(t.css("width","auto"),i=t.width(),t.css("overflow","hidden"),t.css("width","0"),t.css("visibility","visible"),t.animate({width:i+.3*parseFloat(t.css("font-size"))},1200,function(){setTimeout(function(){n&&n()},100)})):"clipOut"===e?t.animate({width:"2px"},1200,function(){setTimeout(function(){n&&n()},100)}):"typeIn"===e?t.addClass("fusion-title-animated "+e).show():t.addClass("fusion-title-animated "+e).css("visibility","visible").show(),"typeIn"!==e&&"typeOut"!==e||!jQuery("html").hasClass("ua-edge")&&!jQuery("html").hasClass("ua-ie")||(t.removeClass("fusion-title-animated "+e).css("visibility","visible"),n&&n()),t.one("webkitAnimationEnd mozAnimationEnd MSAnimationEnd oAnimationEnd AnimationEnd",function(){t.removeClass("fusion-title-animated "+e),n&&n()})},u):r()})):a&&a()}t.fn.textillate=function(i,l){return this.each(function(){var o=t(this),c=o.data("textillate"),r=t.extend(!0,{},t.fn.textillate.defaults,s(this),"object"==typeof i&&i);c?"string"==typeof i?c[i].apply(c,[].concat(l)):c.setOptions.call(c,r):o.data("textillate",c=new function(i,l){var o=this,c=t(i);o.init=function(){o.$texts=c.find(l.selector),o.$texts.length||(o.$texts=t('
  • '+c.html()+"
"),c.html(o.$texts)),o.$texts.hide(),o.$current=t('').html(o.$texts.find(":first-child").html()).prependTo(c),e(l.in.effect)?o.$current.css("visibility","hidden"):n(l.out.effect)&&o.$current.css("visibility","visible"),o.setOptions(l),o.timeoutRun=null,setTimeout(function(){o.options.autoStart&&o.start()},o.options.initialDelay)},o.setOptions=function(t){o.options=t},o.triggerEvent=function(e){var n=t.Event(e+".tlt");return c.trigger(n,o),n},o.in=function(i,l){i=i||0;var r,u=o.$texts.find(":nth-child("+((i||0)+1)+")"),f=t.extend(!0,{},o.options,u.length?s(u[0]):{}),d=o.$current.closest(".fusion-animated-texts-wrapper");u.addClass("current"),o.triggerEvent("inAnimationBegin"),c.attr("data-active",u.data("id")),"line"==o.options.length?o.$current.html(u.html()).lettering("lines"):o.$current.html(u.html()).lettering("words"),"char"==o.options.length&&o.$current.find('[class^="word"]').css({display:"inline-block","-webkit-transform":"translate3d(0,0,0)","-moz-transform":"translate3d(0,0,0)","-o-transform":"translate3d(0,0,0)",transform:"translate3d(0,0,0)"}).each(function(){t(this).lettering()}),r=o.$current.find('[class^="'+o.options.length+'"]').css("display","inline-block"),e(f.in.effect)?"typeIn"===f.in.effect?r.css("display","none"):r.css("visibility","hidden"):n(f.in.effect)&&r.css("visibility","visible"),"typeIn"!==f.in.effect&&"clipIn"!==f.in.effect||void 0!==d.attr("style")&&-1!==d.attr("style").indexOf("width")||o.$current.closest(".fusion-animated-texts-wrapper").css("width","auto"),o.currentIndex=i,a(r,f.in,function(){o.triggerEvent("inAnimationEnd"),f.in.callback&&f.in.callback(),l&&l(o)})},o.out=function(e){var n=o.$texts.find(":nth-child("+((o.currentIndex||0)+1)+")"),i=o.$current.find('[class^="'+o.options.length+'"]'),l=t.extend(!0,{},o.options,n.length?s(n[0]):{});o.triggerEvent("outAnimationBegin"),a(i,l.out,function(){n.removeClass("current"),o.triggerEvent("outAnimationEnd"),c.removeAttr("data-active"),l.out.callback&&l.out.callback(),e&&e(o)})},o.start=function(t){setTimeout(function(){o.triggerEvent("start"),function t(e){o.in(e,function(){var n=o.$texts.children().length;e+=1,!o.options.loop&&e>=n?(o.options.callback&&o.options.callback(),o.triggerEvent("end")):(e%=n,o.timeoutRun=setTimeout(function(){o.out(function(){t(e)})},o.options.minDisplayTime))})}(t||0)},o.options.initialDelay)},o.stop=function(){o.timeoutRun&&(clearInterval(o.timeoutRun),o.timeoutRun=null)},o.init()}(this,r))})},t.fn.textillate.defaults={selector:".texts",loop:!0,minDisplayTime:1200,initialDelay:0,in:{effect:"fadeIn",delayScale:1.5,delay:100,sync:!1,reverse:!1,shuffle:!1,callback:function(){}},out:{effect:"fadeOut",delayScale:1.5,delay:100,sync:!1,reverse:!1,shuffle:!1,callback:function(){}},autoStart:!0,inEffects:[],outEffects:["hinge"],callback:function(){},type:"word"}}(jQuery); !function(t){"use strict";t.fn.fusion_responsive_title_element=function(){t(this).each(function(){var i=t(this),e=i.find("h1, h2, h3, h4, h5, h6, .title-heading-tag"),n=e.data("min-width")?e.data("min-width"):e.outerWidth(),o=i.parent(),a=i.parents(".slide-content").length||o.hasClass("fusion-column-wrapper")?o.width():o.outerWidth(),s=i.find(".fusion-animated-texts-wrapper");(0!==n&&!1!==n&&"0"!==n||0!==a&&!1!==a&&"0"!==a)&&n+100>=a?(i.addClass("fusion-border-below-title"),e.data("min-width",n)):i.removeClass("fusion-border-below-title"),t(i).hasClass("fusion-title-rotating")&&!t(i).is(".fusion-title-typeIn,.fusion-title-clipIn")&&s.fusion_animated_title_element_rotation_width()})},t.fn.fusion_animated_title_element=function(){t(this).each(function(){var i=t(this),e=i.find(".fusion-animated-texts-wrapper"),n=i.hasClass("fusion-loop-on"),o="",a="",s="",f="",l=0,d="";t(i).hasClass("fusion-title-rotating")&&(f=getWaypointOffset(t(i).find(".fusion-animated-texts-wrapper")),d=t(i).closest("[data-animationduration]").data("animationduration"),t(i).find(".fusion-animated-texts-wrapper").removeData("textillate"),t(i).find(".fusion-textillate").remove(),t(i).is(".fusion-title-typeIn,.fusion-title-clipIn")||e.fusion_animated_title_element_rotation_width(),void 0!==d&&(l=200*parseFloat(d)),t(i).find(".fusion-animated-texts-wrapper").waypoint(function(){t(i).find(".fusion-animated-texts-wrapper").textillate({selector:".fusion-animated-texts",type:e.attr("data-length"),minDisplayTime:e.attr("data-minDisplayTime"),loop:n,initialDelay:l}),this.destroy()},{offset:f})),t(i).hasClass("fusion-title-highlight")&&(f=getWaypointOffset(t(i).find(".fusion-highlighted-text")),o={circle:["M344.6,40.1c0,0-293-3.4-330.7,40.3c-5.2,6-3.5,15.3,3.3,19.4c65.8,39,315.8,42.3,451.2-3 c6.3-2.1,12-6.1,16-11.4C527.9,27,242,16.1,242,16.1"],underline_zigzag:["M6.1,133.6c0,0,173.4-20.6,328.3-14.5c154.8,6.1,162.2,8.7,162.2,8.7s-262.6-4.9-339.2,13.9 c0,0,113.8-6.1,162.9,6.9"],x:["M25.8,37.1c0,0,321.2,56.7,435.5,82.3","M55.8,108.7c0,0,374-78.3,423.6-76.3"],strikethrough:["M22.2,93.2c0,0,222.1-11.3,298.8-15.8c84.2-4.9,159.1-4.7,159.1-4.7"],curly:["M9.4,146.9c0,0,54.4-60.2,102.1-11.6c42.3,43.1,84.3-65.7,147.3,0.9c37.6,39.7,79.8-52.6,123.8-14.4 c68.6,59.4,107.2-7,107.2-7"],diagonal_bottom_left:["M6.5,127.1C10.6,126.2,316.9,24.8,497,23.9"],diagonal_top_left:["M7.2,28.5c0,0,376.7,64.4,485.2,93.4"],double:["M21.7,145.7c0,0,192.2-33.7,456.3-14.6","M13.6,28.2c0,0,296.2-22.5,474.9-5.4"],double_underline:["M10.3,130.6c0,0,193.9-24.3,475.2-11.2","M38.9,148.9c0,0,173.8-35.3,423.3-11.8"],underline:["M8.1,146.2c0,0,240.6-55.6,479-13.8"]}[t(i).data("highlight")],a=t(),"object"==typeof o&&o.forEach(function(i){a=a.add(t("",{d:i}))}),s=t("",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 500 150",preserveAspectRatio:"none"}).html(a),t(i).find(".fusion-highlighted-text").waypoint(function(){t(i).find(".fusion-highlighted-text-wrapper svg").remove(),t(i).find(".fusion-highlighted-text").after(s[0].outerHTML),this.destroy()},{offset:f}))})},t.fn.fusion_animated_title_element_rotation_width=function(){var i=t(this),e=i.find(".fusion-animated-texts"),n=0,o=0,a=!1;n=parseInt(i.find(".fusion-animated-text").css("font-size")),n*=.6,e.is(":visible")||(a=!0,e.show()),t(i).find(".fusion-animated-text").each(function(){var i=t(this).width();i>o&&(o=i)}),a&&e.hide(),i.css("width",o+n)}}(jQuery),jQuery(document).ready(function(){jQuery(".fusion-title").fusion_responsive_title_element(),jQuery(window).on("resize",function(){jQuery(".fusion-title").fusion_responsive_title_element()}),jQuery(".fusion-title").fusion_animated_title_element()}),jQuery(window).on("fusion-column-resized fusion-element-render-fusion_title",function(t,i){var e=jQuery('div[data-cid="'+i+'"]').find(".fusion-title");e.length&&(e.fusion_responsive_title_element(),e.fusion_animated_title_element())}); var fusionAnimationsVars={"status_css_animations":"desktop"};function fusionSetMobileAnimationData(){cssua.ua.mobile&&(jQuery("body").removeClass("dont-animate do-animate"),"desktop_and_mobile"===fusionAnimationsVars.status_css_animations?jQuery("body").addClass("do-animate"):jQuery("body").addClass("dont-animate"))}function fusionSetAnimationData(i){jQuery("body").removeClass("dont-animate do-animate"),"off"===fusionAnimationsVars.status_css_animations?jQuery("body").addClass("dont-animate"):(jQuery("body").addClass("do-animate"),void 0!==i&&void 0!==i.data.custom&&jQuery(window).initWaypoint())}!function(i){"use strict";i.fn.initWaypoint=function(){i().waypoint&&i(".fusion-animated").each(function(){var n=i(this),a=getWaypointOffset(n);"top-out-of-view"===a&&(a=getAdminbarHeight()+("function"==typeof getStickyHeaderHeight?getStickyHeaderHeight():"0")),n.waypoint(function(){var i,a,t;n.parents(".fusion-delayed-animation").length||(n.css("visibility","visible"),i=n.data("animationtype"),a=n.data("animationduration"),n.addClass(i),a&&(n.css("-moz-animation-duration",a+"s"),n.css("-webkit-animation-duration",a+"s"),n.css("-ms-animation-duration",a+"s"),n.css("-o-animation-duration",a+"s"),n.css("animation-duration",a+"s"),t=n,setTimeout(function(){t.removeClass(i)},1e3*a))),this.destroy()},{offset:a})})}}(jQuery),jQuery(document).ready(function(){fusionSetAnimationData(),fusionSetMobileAnimationData()}),jQuery(window).on("load",function(){jQuery("body").hasClass("fusion-builder-live")||setTimeout(function(){jQuery(window).initWaypoint()},300)}),jQuery(window).on("CSSAnimations",{custom:!0},fusionSetAnimationData),jQuery(window).on("CSSAnimations",fusionSetMobileAnimationData); !function(t){t.fn.countTo=function(e){return e=t.extend({},t.fn.countTo.defaults,e||{}),t(this).each(function(){var a=t.extend({},e,{from:parseFloat(t(this).attr("data-from")||e.from),to:parseFloat(t(this).attr("data-to")||e.to),speed:parseInt(t(this).attr("data-speed")||e.speed,10),refreshInterval:parseInt(t(this).attr("data-refresh-interval")||e.refreshInterval,10),decimals:parseInt(t(this).attr("data-decimals")||e.decimals,10)}),r=Math.ceil(a.speed/a.refreshInterval),n=(a.to-a.from)/r,o=this,l=0,s=a.from,f=setInterval(function(){l++,d(s+=n),"function"==typeof a.onUpdate&&a.onUpdate.call(o,s);l>=r&&(clearInterval(f),s=a.to,"function"==typeof a.onComplete&&a.onComplete.call(o,s))},a.refreshInterval);function d(e){var r=a.formatter.call(o,e,a);t(o).html(r)}d(s)})},t.fn.countTo.defaults={from:0,to:0,speed:1e3,refreshInterval:100,decimals:0,formatter:function(t,e){return t.toFixed(e.decimals)},onUpdate:null,onComplete:null}}(jQuery); !function(s){s.fn.countDown=function(t){return config={},s.extend(config,t),diffSecs=this.setCountDown(config),config.onComplete&&s.data(s(this)[0],"callback",config.onComplete),config.omitWeeks&&s.data(s(this)[0],"omitWeeks",config.omitWeeks),s("#"+s(this).attr("id")+" .fusion-digit").html('
'),s(this).doCountDown(s(this).attr("id"),diffSecs,500),this},s.fn.stopCountDown=function(){clearTimeout(s.data(this[0],"timer"))},s.fn.startCountDown=function(){this.doCountDown(s(this).attr("id"),s.data(this[0],"diffSecs"),500)},s.fn.setCountDown=function(t){var e=new Date;t.targetDate?e=new Date(t.targetDate.month+"/"+t.targetDate.day+"/"+t.targetDate.year+" "+t.targetDate.hour+":"+t.targetDate.min+":"+t.targetDate.sec+(t.targetDate.utc?" UTC":"")):t.targetOffset&&(e.setFullYear(t.targetOffset.year+e.getFullYear()),e.setMonth(t.targetOffset.month+e.getMonth()),e.setDate(t.targetOffset.day+e.getDate()),e.setHours(t.targetOffset.hour+e.getHours()),e.setMinutes(t.targetOffset.min+e.getMinutes()),e.setSeconds(t.targetOffset.sec+e.getSeconds()));var i=new Date;if(t.gmtOffset){var a=60*t.gmtOffset*6e4,n=6e4*i.getTimezoneOffset();i=new Date(i.getTime()+a+n)}return diffSecs=Math.floor((e.valueOf()-i.valueOf())/1e3),s.data(this[0],"diffSecs",diffSecs),diffSecs},s.fn.doCountDown=function(i,a,n){$this=s("#"+i),a<=0&&(a=0,$this.data("timer")&&clearTimeout($this.data("timer"))),secs=a%60,mins=Math.floor(a/60)%60,hours=Math.floor(a/60/60)%24,1==$this.data("omitWeeks")?(days=Math.floor(a/60/60/24),weeks=Math.floor(a/60/60/24/7)):(days=Math.floor(a/60/60/24)%7,weeks=Math.floor(a/60/60/24/7)),days>99&&$this.find(".fusion-dash-days").find(".fusion-hundred-digit").css("display","inline-block"),days>999&&$this.find(".fusion-dash-days").find(".fusion-thousand-digit").css("display","inline-block"),weeks>99&&$this.find(".fusion-dash-weeks").find(".fusion-hundred-digit").css("display","inline-block"),$this.dashChangeTo(i,"fusion-dash-seconds",secs,n||800),$this.dashChangeTo(i,"fusion-dash-minutes",mins,n||1200),$this.dashChangeTo(i,"fusion-dash-hours",hours,n||1200),$this.dashChangeTo(i,"fusion-dash-days",days,n||1200),$this.dashChangeTo(i,"fusion-dash-weeks",weeks,n||1200),s.data($this[0],"diffSecs",a),a>0?(e=$this,t=setTimeout(function(){e.doCountDown(i,a-1)},1e3),s.data(e[0],"timer",t)):(cb=s.data($this[0],"callback"))&&s.data($this[0],"callback")()},s.fn.dashChangeTo=function(t,e,i,a){$this=s("#"+t);for(var n=$this.find("."+e+" .fusion-digit").length-1;n>=0;n--){var o=i%10;i=(i-o)/10,$this.digitChangeTo("#"+$this.attr("id")+" ."+e+" .fusion-digit:eq("+n+")",o,a)}},s.fn.digitChangeTo=function(t,e,i){var a=s(t+" div.top"),n=s(t+" div.bottom");i||(i=800),a.html()!=e+""&&a.not(":animated").length&&(a.css({display:"none"}),a.html(e||"0").fadeOut(i,function(){n.html(a.html()),n.css({display:"block",height:"auto"}),a.css({display:"none"})}))}}(jQuery); var fusionVideoVars={"status_vimeo":"1"};jQuery(document).ready(function(){jQuery(".fusion-video").each(function(){!jQuery(this).parents(".fusion-modal").length&&1==jQuery(this).data("autoplay")&&jQuery(this).is(":visible")&&jQuery(this).find("iframe").each(function(){jQuery(this).attr("src",jQuery(this).attr("src").replace("autoplay=0","autoplay=1"))})}),jQuery(window).on("resize",function(){var e,i=document.querySelectorAll("iframe"),o=i.length;if(jQuery(".fusion-youtube").each(function(){jQuery(this).is(":visible")||jQuery(this).parents(".fusion-modal").length&&!jQuery(this).parents(".fusion-modal").is(":visible")||jQuery(this).find("iframe").each(function(){this.contentWindow.postMessage('{"event":"command","func":"pauseVideo","args":""}',"*")})}),"undefined"!=typeof Vimeo)for(e=0;e
'),loader:$('
'),toolbar:$('
'),innerToolbar:$('
'),title:$('
'),closeButton:$(''),fullScreenButton:$(''),innerPlayButton:$(''),innerNextButton:$(''),innerPrevButton:$(''),holder:$('
'),nextPhoto:$('
'),prevPhoto:$('
'),nextButton:$(''),prevButton:$(''),thumbnails:$('
'),thumbs:!1,nextLock:!1,prevLock:!1,hashLock:!1,isMobile:!1,mobileMaxWidth:980,isInFullScreen:!1,isSwipe:!1,mouseID:0,cycleID:0,isPaused:0},n.vars.hideableElements=n.vars.nextButton.add(n.vars.prevButton),n.normalizeItems(),n.availPlugins(),n.options.startFrom=n.options.startFrom>0&&n.options.startFrom>=n.vars.total?n.vars.total-1:n.options.startFrom,n.options.startFrom=n.options.randomStart?floor(random()*n.vars.total):n.options.startFrom,n.vars.start=n.options.startFrom,o?n.instantCall():n.patchItemsEvents(),n.options.linkId&&(n.hashChangeHandler(),$win.iLightBoxHashChange(function(){n.hashChangeHandler()})),supportTouch){var a=/(click|mouseenter|mouseleave|mouseover|mouseout)/gi;n.options.caption.show=n.options.caption.show.replace(a,"itap"),n.options.caption.hide=n.options.caption.hide.replace(a,"itap"),n.options.social.show=n.options.social.show.replace(a,"itap"),n.options.social.hide=n.options.social.hide.replace(a,"itap")}n.options.controls.arrows&&$.extend(n.options.styles,{nextOffsetX:0,prevOffsetX:0,nextOpacity:0,prevOpacity:0})};function getPixel(e,t){return parseInt(e.css(t),10)||0}function within(e,t,i){return ei?i:e}function getViewport(){var e=window,t="inner";return"innerWidth"in window||(t="client",e=document.documentElement||document.body),{width:e[t+"Width"],height:e[t+"Height"]}}function removeHash(){history&&history.pushState&&history.pushState("",document.title,window.location.pathname+window.location.search)}function doAjax(e,t){e="//ilightbox.net/getSource/jsonp.php?url="+encodeURIComponent(e).replace(/!/g,"%21").replace(/'/g,"%27").replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/\*/g,"%2A");$.ajax({url:e,dataType:"jsonp"}),iLCallback=function(e){t.call(this,e)}}function findImageInElement(e){var t=$("*",e),i=new Array;return t.each(function(){var e="";if("none"!=$(this).css("background-image")?e=$(this).css("background-image"):void 0!==$(this).attr("src")&&"img"==this.nodeName.toLowerCase()&&(e=$(this).attr("src")),-1==e.indexOf("gradient"))for(var t=(e=(e=(e=(e=e.replace(/url\(\"/g,"")).replace(/url\(/g,"")).replace(/\"\)/g,"")).replace(/\)/g,"")).split(","),o=0;o0&&-1==$.inArray(t[o],i)){var n="";browser.msie&&browser.version<9&&(n="?"+floor(3e3*random())),i.push(t[o]+n)}}),i}function getExtension(e){var t=e.split(".").pop().toLowerCase(),i=-1!==t.indexOf("?")?"?"+t.split("?").pop():"";return t.replace(i,"")}function getTypeByExtension(e){var t=getExtension(e);return-1!==extensions.image.indexOf(t)?"image":-1!==extensions.flash.indexOf(t)?"flash":-1!==extensions.video.indexOf(t)?"video":"iframe"}function percentToValue(e,t){return parseInt(t/100*e)}function parseURI(e){var t=String(e).replace(/^\s+|\s+$/g,"").match(/^([^:\/?#]+:)?(\/\/(?:[^:@]*(?::[^:@]*)?@)?(([^:\/?#]*)(?::(\d*))?))?([^?#]*)(\?[^#]*)?(#[\s\S]*)?/);return t?{href:t[0]||"",protocol:t[1]||"",authority:t[2]||"",host:t[3]||"",hostname:t[4]||"",port:t[5]||"",pathname:t[6]||"",search:t[7]||"",hash:t[8]||""}:null}function absolutizeURI(e,t){var i,o;return t=parseURI(t||""),e=parseURI(e||""),t&&e?(t.protocol||e.protocol)+(t.protocol||t.authority?t.authority:e.authority)+(i=t.protocol||t.authority||"/"===t.pathname.charAt(0)?t.pathname:t.pathname?(e.authority&&!e.pathname?"/":"")+e.pathname.slice(0,e.pathname.lastIndexOf("/")+1)+t.pathname:e.pathname,o=[],i.replace(/^(\.\.?(\/|$))+/,"").replace(/\/(\.(\/|$))+/g,"/").replace(/\/\.\.$/,"/../").replace(/\/?[^\/]*/g,function(e){"/.."===e?o.pop():o.push(e)}),o.join("").replace(/^\//,"/"===i.charAt(0)?"/":""))+(t.protocol||t.authority||t.pathname?t.search:t.search||e.search)+t.hash:null}function version_compare(e,t,i){this.php_js=this.php_js||{},this.php_js.ENV=this.php_js.ENV||{};var o,n=0,a=0,r={dev:-6,alpha:-5,a:-5,beta:-4,b:-4,RC:-3,rc:-3,"#":-2,p:1,pl:1},s=function(e){return(e=(e=(""+e).replace(/[_\-+]/g,".")).replace(/([^.\d]+)/g,".$1.").replace(/\.{2,}/g,".")).length?e.split("."):[-8]},l=function(e){return e?isNaN(e)?r[e]||-7:parseInt(e,10):0};for(e=s(e),t=s(t),o=max(e.length,t.length),n=0;nt[n]){a=1;break}}if(!i)return a;switch(i){case">":case"gt":return a>0;case">=":case"ge":return a>=0;case"<=":case"le":return a<=0;case"==":case"=":case"eq":return 0===a;case"<>":case"!=":case"ne":return 0!==a;case"":case"<":case"lt":return a<0;default:return null}}function getScrollXY(){var e=0,t=0;return"number"==typeof window.pageYOffset?(t=window.pageYOffset,e=window.pageXOffset):document.body&&(document.body.scrollLeft||document.body.scrollTop)?(t=document.body.scrollTop,e=document.body.scrollLeft):document.documentElement&&(document.documentElement.scrollLeft||document.documentElement.scrollTop)&&(t=document.documentElement.scrollTop,e=document.documentElement.scrollLeft),{x:e,y:t}}iLightBox.prototype={showLoader:function(){var e=this;e.vars.loadRequests+=1,"horizontal"==e.options.path.toLowerCase()?e.vars.loader.addClass("ilightbox-show").stop().animate({top:"-30px"},e.options.show.speed,"easeOutCirc"):e.vars.loader.addClass("ilightbox-show").stop().animate({left:"-30px"},e.options.show.speed,"easeOutCirc")},hideLoader:function(){var e=this;e.vars.loadRequests-=1,e.vars.loadRequests=e.vars.loadRequests<0?0:e.vars.loadRequests,"horizontal"==e.options.path.toLowerCase()?e.vars.loadRequests<=0&&e.vars.loader.removeClass("ilightbox-show").stop().animate({top:"-192px"},e.options.show.speed,"easeInCirc"):e.vars.loadRequests<=0&&e.vars.loader.removeClass("ilightbox-show").stop().animate({left:"-192px"},e.options.show.speed,"easeInCirc")},createUI:function(){var e=this;e.ui={currentElement:e.vars.holder,nextElement:e.vars.nextPhoto,prevElement:e.vars.prevPhoto,currentItem:e.vars.current,nextItem:e.vars.next,prevItem:e.vars.prev,hide:function(){e.closeAction()},refresh:function(){arguments.length>0?e.repositionPhoto(!0):e.repositionPhoto()},fullscreen:function(){e.fullScreenAction()}}},attachItems:function(){var iL=this,itemsObject=new Array,items=new Array;$(iL.selector,iL.context).each(function(){var t=$(this),URL=t.attr(iL.options.attr)||null,options=t.data("options")&&eval("({"+t.data("options")+"})")||{},caption=t.data("caption"),title=t.data("title"),type=t.data("type")||getTypeByExtension(URL);items.push({URL:URL,caption:caption,title:title,type:type,options:options}),iL.instant||itemsObject.push(t)}),iL.items=items,iL.itemsObject=itemsObject,iL.vars&&(iL.vars.total=items.length)},normalizeItems:function(){var e=this,t=new Array;$.each(e.items,function(i,o){"string"==typeof o&&(o={url:o});var n=o.url||o.URL||null,a=o.options||{},r=o.caption||null,s=o.title||null,l=o.type?o.type.toLowerCase():getTypeByExtension(n),c="object"!=typeof n?getExtension(n):"";if(a.thumbnail=a.thumbnail||("image"==l?n:null),a.videoType=a.videoType||null,a.skin=a.skin||e.options.skin,a.width=a.width||null,a.height=a.height||null,a.mousewheel=void 0===a.mousewheel||a.mousewheel,a.swipe=void 0===a.swipe||a.swipe,a.social=void 0!==a.social?a.social:e.options.social.buttons&&$.extend({},{},e.options.social.buttons),"video"==l&&(a.html5video=void 0!==a.html5video?a.html5video:{},a.html5video.webm=a.html5video.webm||a.html5video.WEBM||null,a.html5video.controls=void 0!==a.html5video.controls?a.html5video.controls:"controls",a.html5video.preload=a.html5video.preload||"metadata",a.html5video.autoplay=void 0!==a.html5video.autoplay&&a.html5video.autoplay),"iframe"===l)if(-1!==n.indexOf("youtube.com")){var u=n.match(/^.*((youtu.be\/)|(v\/)|(\/u\/\w\/)|(embed\/)|(watch\?))\??v?=?([^#\&\?]*).*/);u&&11===u[7].length&&(a.thumbnail="//img.youtube.com/vi/"+u[7]+"/mqdefault.jpg")}else-1!==n.indexOf("vimeo.com")&&($videoID=n.split(/[?#]/)[0].replace(/[^\d]/g,""),$.getJSON("https://www.vimeo.com/api/v2/video/"+$videoID+".json?callback=?",{format:"json"},function(e){a.thumbnail=e[0].thumbnail_medium}));a.width&&a.height||"video"!==l&&"iframe"!==l&&"flash"!==l||(a.width=parseInt(fusionLightboxVideoVars.lightbox_video_width),a.height=parseInt(fusionLightboxVideoVars.lightbox_video_height)),delete o.url,o.index=i,o.URL=n,o.caption=r,o.title=s,o.type=l,o.options=a,o.ext=c,t.push(o)}),e.items=t},instantCall:function(){var e=this,t=e.vars.start;e.vars.current=t,e.vars.next=e.items[t+1]?t+1:null,e.vars.prev=e.items[t-1]?t-1:null,e.addContents(),e.patchEvents()},addContents:function(){var e=this,t=e.vars,i=e.options,o=getViewport(),n=i.path.toLowerCase(),a=t.total>0&&e.items.filter(function(e,t,o){return-1===["image","flash","video"].indexOf(e.type)&&void 0===e.recognized&&(i.smartRecognition||e.options.smartRecognition)}),r=a.length>0;i.mobileOptimizer&&!i.innerToolbar&&(t.isMobile=o.width<=t.mobileMaxWidth),t.overlay.addClass(i.skin).hide().css("opacity",i.overlay.opacity),i.linkId&&t.overlay[0].setAttribute("linkid",i.linkId),i.controls.toolbar&&(t.toolbar.addClass(i.skin).append(t.closeButton),i.controls.fullscreen&&t.toolbar.append(t.fullScreenButton),i.controls.slideshow&&t.toolbar.append(t.innerPlayButton),t.total>1&&t.toolbar.append(t.innerPrevButton).append(t.innerNextButton)),t.BODY.addClass("ilightbox-noscroll").append(t.overlay).append(t.loader).append(t.holder).append(t.nextPhoto).append(t.prevPhoto),i.innerToolbar||t.BODY.append(t.toolbar),i.controls.arrows&&t.BODY.append(t.nextButton).append(t.prevButton),i.controls.thumbnail&&t.total>1&&(t.BODY.append(t.thumbnails),t.thumbnails.addClass(i.skin).addClass("ilightbox-"+n),$("div.ilightbox-thumbnails-grid",t.thumbnails).empty(),t.thumbs=!0);var s="horizontal"==i.path.toLowerCase()?{left:parseInt(o.width/2-t.loader.outerWidth()/2)}:{top:parseInt(o.height/2-t.loader.outerHeight()/2)};t.loader.addClass(i.skin).css(s),t.nextButton.add(t.prevButton).addClass(i.skin),"horizontal"==n&&t.loader.add(t.nextButton).add(t.prevButton).addClass("horizontal"),t.BODY[t.isMobile?"addClass":"removeClass"]("isMobile"),i.infinite||(t.prevButton.add(t.prevButton).add(t.innerPrevButton).add(t.innerNextButton).removeClass("disabled"),0==t.current&&t.prevButton.add(t.innerPrevButton).addClass("disabled"),t.current>=t.total-1&&t.nextButton.add(t.innerNextButton).addClass("disabled")),i.show.effect?(t.overlay.stop().fadeIn(i.show.speed),t.toolbar.stop().fadeIn(i.show.speed)):(t.overlay.show(),t.toolbar.show());var l=a.length;r?(e.showLoader(),$.each(a,function(o,n){e.ogpRecognition(this,function(o){var n=-1,a=(e.items.filter(function(e,t,i){return e.URL==o.url&&(n=t),e.URL==o.url}),e.items[n]);o&&$.extend(!0,a,{URL:o.source,type:o.type,recognized:!0,options:{html5video:o.html5video,width:"image"==o.type?0:o.width||a.width,height:"image"==o.type?0:o.height||a.height,thumbnail:a.options.thumbnail||o.thumbnail}}),0==--l&&(e.hideLoader(),t.dontGenerateThumbs=!1,e.generateThumbnails(),i.show.effect?setTimeout(function(){e.generateBoxes()},i.show.speed):e.generateBoxes())})})):i.show.effect?setTimeout(function(){e.generateBoxes()},i.show.speed):e.generateBoxes(),e.createUI(),window.iLightBox={close:function(){e.closeAction()},fullscreen:function(){e.fullScreenAction()},moveNext:function(){e.moveTo("next")},movePrev:function(){e.moveTo("prev")},goTo:function(t){e.goTo(t)},refresh:function(){e.refresh()},reposition:function(){arguments.length>0?e.repositionPhoto(!0):e.repositionPhoto()},setOption:function(t){e.setOption(t)},destroy:function(){e.closeAction(),e.dispatchItemsEvents()}},i.linkId&&(t.hashLock=!0,window.location.hash=i.linkId+"/"+t.current,setTimeout(function(){t.hashLock=!1},55)),i.slideshow.startPaused||(e.resume(),t.innerPlayButton.removeClass("ilightbox-play").addClass("ilightbox-pause")),"function"==typeof e.options.callback.onOpen&&e.options.callback.onOpen.call(e)},loadContent:function(e,t,i){var o,n,a=this;switch(a.createUI(),e.speed=i||a.options.effects.loadedFadeSpeed,"current"==t&&(e.options.mousewheel?a.vars.lockWheel=!1:a.vars.lockWheel=!0,e.options.swipe?a.vars.lockSwipe=!1:a.vars.lockSwipe=!0),t){case"current":o=a.vars.holder,n=a.vars.current;break;case"next":o=a.vars.nextPhoto,n=a.vars.next;break;case"prev":o=a.vars.prevPhoto,n=a.vars.prev}if(o.removeAttr("style class").addClass("ilightbox-holder"+(supportTouch?" supportTouch":"")).addClass(e.options.skin),$("div.ilightbox-inner-toolbar",o).remove(),e.title||a.options.innerToolbar){var r=a.vars.innerToolbar.clone();if(e.title&&a.options.show.title){var s=a.vars.title.clone();s.empty().html(e.title),r.append(s)}a.options.innerToolbar&&r.append(a.vars.total>1?a.vars.toolbar.clone():a.vars.toolbar),o.prepend(r)}a.loadSwitcher(e,o,n,t)},loadSwitcher:function(e,t,i,o){var n=this,a=n.options,r={element:t,position:i};switch(e.type){case"image":"function"==typeof a.callback.onBeforeLoad&&a.callback.onBeforeLoad.call(n,n.ui,i),"function"==typeof e.options.onBeforeLoad&&e.options.onBeforeLoad.call(n,r),n.loadImage(e.URL,function(s){"function"==typeof a.callback.onAfterLoad&&a.callback.onAfterLoad.call(n,n.ui,i),"function"==typeof e.options.onAfterLoad&&e.options.onAfterLoad.call(n,r);var l=s?s.width:400,c=s?s.height:200;t.data({naturalWidth:l,naturalHeight:c}),$("div.ilightbox-container",t).empty().append(s?'':''+a.errors.loadImage+""),"function"==typeof a.callback.onRender&&a.callback.onRender.call(n,n.ui,i),"function"==typeof e.options.onRender&&e.options.onRender.call(n,r),n.configureHolder(e,o,t)});break;case"video":t.data({naturalWidth:e.options.width,naturalHeight:e.options.height}),n.addContent(t,e),"function"==typeof a.callback.onRender&&a.callback.onRender.call(n,n.ui,i),"function"==typeof e.options.onRender&&e.options.onRender.call(n,r),n.configureHolder(e,o,t);break;case"iframe":for(var s=e.URL.substring(e.URL.indexOf("?")+1).split("&"),l={},c=0;c').css(m).html(u)),t.show().data({naturalWidth:d||h.outerWidth(),naturalHeight:p||h.outerHeight()}).hide(),"function"==typeof a.callback.onRender&&a.callback.onRender.call(n,n.ui,i),"function"==typeof e.options.onRender&&e.options.onRender.call(n,r);var g=findImageInElement(t);n.loadImage(g,function(){"function"==typeof a.callback.onAfterLoad&&a.callback.onAfterLoad.call(n,n.ui,i),"function"==typeof e.options.onAfterLoad&&e.options.onAfterLoad.call(n,r),n.configureHolder(e,o,t)}),a.ajaxSetup.success(s,l,c),"function"==typeof f.success&&f.success(s,l,c)}).fail(function(s,l,c){"function"==typeof a.callback.onAfterLoad&&a.callback.onAfterLoad.call(n,n.ui,i),"function"==typeof e.options.onAfterLoad&&e.options.onAfterLoad.call(n,r),n.hideLoader(),$("div.ilightbox-container",t).empty().append(''+a.errors.loadContents+""),n.configureHolder(e,o,t),a.ajaxSetup.error(s,l,c),"function"==typeof f.error&&f.error(s,l,c)});break;case"html":var m=e.URL;if(container=$("div.ilightbox-container",t),m[0].nodeName)h=m.clone();else{var g=$(m);h=g.selector?$("
"+g+"
"):g}var v=n.items[i].options.width||parseInt(h.attr("width")),b=n.items[i].options.height||parseInt(h.attr("height"));n.addContent(t,e),h.appendTo(document.documentElement).hide(),"function"==typeof a.callback.onRender&&a.callback.onRender.call(n,n.ui,i),"function"==typeof e.options.onRender&&e.options.onRender.call(n,r);p=findImageInElement(t);"function"==typeof a.callback.onBeforeLoad&&a.callback.onBeforeLoad.call(n,n.ui,i),"function"==typeof e.options.onBeforeLoad&&e.options.onBeforeLoad.call(n,r),n.loadImage(p,function(){"function"==typeof a.callback.onAfterLoad&&a.callback.onAfterLoad.call(n,n.ui,i),"function"==typeof e.options.onAfterLoad&&e.options.onAfterLoad.call(n,r),t.show().data({naturalWidth:v||container.outerWidth(),naturalHeight:b||container.outerHeight()}).hide(),h.remove(),n.configureHolder(e,o,t)})}},configureHolder:function(e,t,i){var o=this,n=o.vars,a=o.options;if("current"!=t&&("next"==t?i.addClass("ilightbox-next"):i.addClass("ilightbox-prev")),"current"==t)var r=n.current;else if("next"==t){var s=a.styles.nextOpacity;r=n.next}else s=a.styles.prevOpacity,r=n.prev;var l={element:i,position:r};o.items[r].options.width=o.items[r].options.width||0,o.items[r].options.height=o.items[r].options.height||0,"current"==t?a.show.effect?i.css(transform,gpuAcceleration).fadeIn(e.speed,function(){if(i.css(transform,""),e.caption){o.setCaption(e,i);var t=$("div.ilightbox-caption",i),n=parseInt(t.outerHeight()/i.outerHeight()*100);a.caption.start&n<=50&&t.fadeIn(a.effects.fadeSpeed)}var s=e.options.social;s&&(o.setSocial(s,e.URL,i),a.social.start&&$("div.ilightbox-social",i).fadeIn(a.effects.fadeSpeed)),o.generateThumbnails(),"function"==typeof a.callback.onShow&&a.callback.onShow.call(o,o.ui,r),"function"==typeof e.options.onShow&&e.options.onShow.call(o,l)}):(i.show(),o.generateThumbnails(),"function"==typeof a.callback.onShow&&a.callback.onShow.call(o,o.ui,r),"function"==typeof e.options.onShow&&e.options.onShow.call(o,l)):a.show.effect?i.fadeTo(e.speed,s,function(){"next"==t?n.nextLock=!1:n.prevLock=!1,o.generateThumbnails(),"function"==typeof a.callback.onShow&&a.callback.onShow.call(o,o.ui,r),"function"==typeof e.options.onShow&&e.options.onShow.call(o,l)}):(i.css({opacity:s}).show(),"next"==t?n.nextLock=!1:n.prevLock=!1,o.generateThumbnails(),"function"==typeof a.callback.onShow&&a.callback.onShow.call(o,o.ui,r),"function"==typeof e.options.onShow&&e.options.onShow.call(o,l)),setTimeout(function(){o.repositionPhoto()},0)},generateBoxes:function(){var e=this,t=e.vars,i=e.options;i.infinite&&t.total>=3?(t.current==t.total-1&&(t.next=0),0==t.current&&(t.prev=t.total-1)):i.infinite=!1,e.loadContent(e.items[t.current],"current",i.show.speed),e.items[t.next]&&e.loadContent(e.items[t.next],"next",i.show.speed),e.items[t.prev]&&e.loadContent(e.items[t.prev],"prev",i.show.speed)},generateThumbnails:function(){var e=this,t=e.vars,i=e.options,o=null;if(t.thumbs&&!e.vars.dontGenerateThumbs){var n=t.thumbnails,a=$("div.ilightbox-thumbnails-container",n),r=$("div.ilightbox-thumbnails-grid",a),s=0;r.removeAttr("style").empty(),$.each(e.items,function(l,c){var u=t.current==l?"ilightbox-active":"",h=t.current==l?i.thumbnails.activeOpacity:i.thumbnails.normalOpacity,d=c.options.thumbnail,p=$('
'),f=$('
');p.css({opacity:0}).addClass(u),"video"!=c.type&&"flash"!=c.type||void 0!==c.options.icon?c.options.icon&&(f.addClass("ilightbox-thumbnail-"+c.options.icon),p.append(f)):(f.addClass("ilightbox-thumbnail-video"),p.append(f)),d&&e.loadImage(d,function(t){s++,t?p.data({naturalWidth:t.width,naturalHeight:t.height}).append(''):p.data({naturalWidth:i.thumbnails.maxWidth,naturalHeight:i.thumbnails.maxHeight}),clearTimeout(o),o=setTimeout(function(){e.positionThumbnails(n,a,r)},20),setTimeout(function(){p.fadeTo(i.effects.loadedFadeSpeed,h)},20*s)}),r.append(p)}),e.vars.dontGenerateThumbs=!0}},positionThumbnails:function(e,t,i){var o=this,n=o.vars,a=o.options,r=getViewport(),s=a.path.toLowerCase();e||(e=n.thumbnails),t||(t=$("div.ilightbox-thumbnails-container",e)),i||(i=$("div.ilightbox-thumbnails-grid",t));var l=$(".ilightbox-thumbnail",i),c="horizontal"==s?r.width-a.styles.pageOffsetX:l.eq(0).outerWidth()-a.styles.pageOffsetX,u="horizontal"==s?l.eq(0).outerHeight()-a.styles.pageOffsetY:r.height-a.styles.pageOffsetY,h="horizontal"==s?0:c,d="horizontal"==s?u:0,p=$(".ilightbox-active",i),f={};arguments.length<3&&(l.css({opacity:a.thumbnails.normalOpacity}),p.css({opacity:a.thumbnails.activeOpacity})),l.each(function(e){var t=$(this),i=t.data(),n="horizontal"==s?0:a.thumbnails.maxWidth;height="horizontal"==s?a.thumbnails.maxHeight:0,dims=o.getNewDimenstions(n,height,i.naturalWidth,i.naturalHeight,!0),t.css({width:dims.width,height:dims.height}),"horizontal"==s&&t.css({float:"left"}),"horizontal"==s?h+=t.outerWidth(!0):d+=t.outerHeight()}),f={width:h,height:d},i.css(f),f={};var m=i.offset(),g=p.length?p.offset():{top:parseInt(u/2),left:parseInt(c/2)};m.top=m.top-$doc.scrollTop(),m.left=m.left-$doc.scrollLeft(),g.top=g.top-m.top-$doc.scrollTop(),g.left=g.left-m.left-$doc.scrollLeft(),"horizontal"==s?(f.top=0,f.left=parseInt(c/2-g.left-p.outerWidth()/2)):(f.top=parseInt(u/2-g.top-p.outerHeight()/2),f.left=0),arguments.length<3?i.stop().animate(f,a.effects.repositionSpeed,"easeOutCirc"):i.css(f)},loadImage:function(e,t){$.isArray(e)||(e=[e]);var i=this,o=e.length;o>0?(i.showLoader(),$.each(e,function(n,a){var r=new Image;r.onload=function(){0==(o-=1)&&(i.hideLoader(),t(r))},r.onerror=r.onabort=function(){0==(o-=1)&&(i.hideLoader(),t(!1))},r.src=e[n]})):t(!1)},patchItemsEvents:function(){var e=this,t=e.vars,i=supportTouch?"click.iL itap.iL":"click.iL",o=supportTouch?"click.iL itap.iL":"itap.iL";if(e.context&&e.selector){var n=$(e.selector,e.context);$(e.context).on(i,e.selector,function(){var i=$(this),o=n.index(i);return t.current=o,t.next=e.items[o+1]?o+1:null,t.prev=e.items[o-1]?o-1:null,e.addContents(),e.patchEvents(),!1}).on(o,e.selector,function(){return!1})}else $.each(e.itemsObject,function(n,a){a.on(i,function(){return t.current=n,t.next=e.items[n+1]?n+1:null,t.prev=e.items[n-1]?n-1:null,e.addContents(),e.patchEvents(),!1}).on(o,function(){return!1})})},dispatchItemsEvents:function(){var e=this;e.vars,e.options;e.context&&e.selector?$(e.context).off(".iL",e.selector):$.each(e.itemsObject,function(e,t){t.off(".iL")})},refresh:function(){this.dispatchItemsEvents(),this.attachItems(),this.normalizeItems(),this.patchItemsEvents()},patchEvents:function(){var e=this,t=e.vars,i=e.options,o=i.path.toLowerCase(),n=$(".ilightbox-holder"),a=fullScreenApi.fullScreenEventName+".iLightBox",r=verticalDistanceThreshold=100,s=[t.nextButton[0],t.prevButton[0],t.nextButton[0].firstChild,t.prevButton[0].firstChild];$win.bind("resize.iLightBox",function(){var o=getViewport();i.mobileOptimizer&&!i.innerToolbar&&(t.isMobile=o.width<=t.mobileMaxWidth),t.BODY[t.isMobile?"addClass":"removeClass"]("isMobile"),t.nextLock||t.prevLock||e.repositionPhoto(null),supportTouch&&(clearTimeout(t.setTime),t.setTime=setTimeout(function(){var e=getScrollXY().y;window.scrollTo(0,e-30),window.scrollTo(0,e+30),window.scrollTo(0,e)},2e3)),t.thumbs&&e.positionThumbnails()}).bind("keydown.iLightBox",function(o){if(i.controls.keyboard)switch(o.keyCode){case 13:o.shiftKey&&i.keyboard.shift_enter&&e.fullScreenAction();break;case 27:i.keyboard.esc&&e.closeAction();break;case 37:i.keyboard.left&&!t.lockKey&&e.moveTo("prev");break;case 38:i.keyboard.up&&!t.lockKey&&e.moveTo("prev");break;case 39:i.keyboard.right&&!t.lockKey&&e.moveTo("next");break;case 40:i.keyboard.down&&!t.lockKey&&e.moveTo("next")}}),fullScreenApi.supportsFullScreen&&$win.bind(a,function(){e.doFullscreen()});var l=[i.caption.show+".iLightBox",i.caption.hide+".iLightBox",i.social.show+".iLightBox",i.social.hide+".iLightBox"].filter(function(e,t,i){return i.lastIndexOf(e)===t}),c="";$.each(l,function(e,t){0!=e&&(c+=" "),c+=t}),$doc.on(clickEvent,".ilightbox-overlay",function(){i.overlay.blur&&e.closeAction()}).on(clickEvent,".ilightbox-next, .ilightbox-next-button",function(){e.moveTo("next")}).on(clickEvent,".ilightbox-prev, .ilightbox-prev-button",function(){e.moveTo("prev")}).on(clickEvent,".ilightbox-thumbnail",function(){var i=$(this),o=$(".ilightbox-thumbnail",t.thumbnails).index(i);o!=t.current&&e.goTo(o)}).on(c,".ilightbox-holder:not(.ilightbox-next, .ilightbox-prev)",function(e){var o=$("div.ilightbox-caption",t.holder),n=$("div.ilightbox-social",t.holder),a=i.effects.fadeSpeed;t.nextLock||t.prevLock?(e.type!=i.caption.show||o.is(":visible")?e.type==i.caption.hide&&o.is(":visible")&&o.fadeOut(a):o.fadeIn(a),e.type!=i.social.show||n.is(":visible")?e.type==i.social.hide&&n.is(":visible")&&n.fadeOut(a):n.fadeIn(a)):(e.type!=i.caption.show||o.is(":visible")?e.type==i.caption.hide&&o.is(":visible")&&o.stop().fadeOut(a):o.stop().fadeIn(a),e.type!=i.social.show||n.is(":visible")?e.type==i.social.hide&&n.is(":visible")&&n.stop().fadeOut(a):n.stop().fadeIn(a))}).on("mouseenter.iLightBox mouseleave.iLightBox",".ilightbox-wrapper",function(e){"mouseenter"==e.type?t.lockWheel=!0:t.lockWheel=!1}).on(clickEvent,".ilightbox-toolbar a.ilightbox-close, .ilightbox-toolbar a.ilightbox-fullscreen, .ilightbox-toolbar a.ilightbox-play, .ilightbox-toolbar a.ilightbox-pause",function(){var t=$(this);t.hasClass("fusion-updated")||(t.hasClass("ilightbox-fullscreen")?e.fullScreenAction():t.hasClass("ilightbox-play")?(e.resume(),t.addClass("ilightbox-pause").removeClass("ilightbox-play")):t.hasClass("ilightbox-pause")?(e.pause(),t.addClass("ilightbox-play").removeClass("ilightbox-pause")):e.closeAction(),t.addClass("fusion-updated"),setTimeout(function(){t.removeClass("fusion-updated")},100))}).on(touchMoveEvent,".ilightbox-overlay, .ilightbox-thumbnails-container",function(e){e.preventDefault()}),i.controls.arrows&&!supportTouch&&$doc.on("mousemove.iLightBox",function(e){t.isMobile||(t.mouseID||t.hideableElements.show(),t.mouseID=clearTimeout(t.mouseID),-1===s.indexOf(e.target)&&(t.mouseID=setTimeout(function(){t.hideableElements.hide(),t.mouseID=clearTimeout(t.mouseID)},3e3)))}),i.controls.slideshow&&i.slideshow.pauseOnHover&&$doc.on("mouseenter.iLightBox mouseleave.iLightBox",".ilightbox-holder:not(.ilightbox-next, .ilightbox-prev)",function(i){"mouseenter"==i.type&&t.cycleID?e.pause():"mouseleave"==i.type&&t.isPaused&&e.resume()});var u=$(".ilightbox-overlay, .ilightbox-holder, .ilightbox-thumbnails");i.controls.mousewheel&&u.on("mousewheel.iLightBox",function(i,o){t.lockWheel||(i.preventDefault(),o<0?e.moveTo("next"):o>0&&e.moveTo("prev"))}),i.controls.swipe&&n.on(touchStartEvent,function(a){if(!(t.nextLock||t.prevLock||1==t.total||t.lockSwipe)){t.BODY.addClass("ilightbox-closedhand");var s,l=a.originalEvent.touches?a.originalEvent.touches[0]:a,c=$doc.scrollTop(),u=$doc.scrollLeft(),h=[n.eq(0).offset(),n.eq(1).offset(),n.eq(2).offset()],d=[{top:h[0].top-c,left:h[0].left-u},{top:h[1].top-c,left:h[1].left-u},{top:h[2].top-c,left:h[2].left-u}],p={time:(new Date).getTime(),coords:[l.pageX-u,l.pageY-c]};n.bind(touchMoveEvent,m),$doc.one(touchStopEvent,function(a){n.unbind(touchMoveEvent,m),t.BODY.removeClass("ilightbox-closedhand"),p&&s&&("horizontal"==o&&s.time-p.time<1e3&&abs(p.coords[0]-s.coords[0])>r&&abs(p.coords[1]-s.coords[1])s.coords[0]?t.current!=t.total-1||i.infinite?(t.isSwipe=!0,e.moveTo("next")):g():0!=t.current||i.infinite?(t.isSwipe=!0,e.moveTo("prev")):g():"vertical"==o&&s.time-p.time<1e3&&abs(p.coords[1]-s.coords[1])>r&&abs(p.coords[0]-s.coords[0])s.coords[1]?t.current!=t.total-1||i.infinite?(t.isSwipe=!0,e.moveTo("next")):g():0!=t.current||i.infinite?(t.isSwipe=!0,e.moveTo("prev")):g():g()),p=s=undefined})}function f(e){var t=$(this),i=d[e],n=[p.coords[0]-s.coords[0],p.coords[1]-s.coords[1]];t[0].style["horizontal"==o?"left":"top"]=("horizontal"==o?i.left-n[0]:i.top-n[1])+"px"}function m(e){if(p){var t=e.originalEvent.touches?e.originalEvent.touches[0]:e;s={time:(new Date).getTime(),coords:[t.pageX-u,t.pageY-c]},n.each(f),e.preventDefault()}}function g(){n.each(function(){var e=$(this),t=e.data("offset")||{top:e.offset().top-c,left:e.offset().left-u},i=t.top,o=t.left;e.css(transform,gpuAcceleration).stop().animate({top:i,left:o},500,"easeOutCirc",function(){e.css(transform,"")})})}})},goTo:function(e){var t=this,i=t.vars,o=t.options,n=e-i.current;if(o.infinite&&(e==i.total-1&&0==i.current&&(n=-1),i.current==i.total-1&&0==e&&(n=1)),1==n)t.moveTo("next");else if(-1==n)t.moveTo("prev");else{if(i.nextLock||i.prevLock)return!1;"function"==typeof o.callback.onBeforeChange&&o.callback.onBeforeChange.call(t,t.ui),o.linkId&&(i.hashLock=!0,window.location.hash=o.linkId+"/"+e),t.items[e]&&(t.items[e].options.mousewheel?t.vars.lockWheel=!1:i.lockWheel=!0,t.items[e].options.swipe?i.lockSwipe=!1:i.lockSwipe=!0),$.each([i.holder,i.nextPhoto,i.prevPhoto],function(e,t){t.css(transform,gpuAcceleration).fadeOut(o.effects.loadedFadeSpeed)}),i.current=e,i.next=e+1,i.prev=e-1,t.createUI(),setTimeout(function(){t.generateBoxes()},o.effects.loadedFadeSpeed+50),$(".ilightbox-thumbnail",i.thumbnails).removeClass("ilightbox-active").eq(e).addClass("ilightbox-active"),t.positionThumbnails(),o.linkId&&setTimeout(function(){i.hashLock=!1},55),o.infinite||(i.nextButton.add(i.prevButton).add(i.innerPrevButton).add(i.innerNextButton).removeClass("disabled"),0==i.current&&i.prevButton.add(i.innerPrevButton).addClass("disabled"),i.current>=i.total-1&&i.nextButton.add(i.innerNextButton).addClass("disabled")),t.resetCycle(),"function"==typeof o.callback.onAfterChange&&o.callback.onAfterChange.call(t,t.ui)}},moveTo:function(e){var t=this,i=t.vars,o=t.options,n=o.path.toLowerCase(),a=getViewport(),r=o.effects.switchSpeed,s=t.vars.holder,l=s.find("iframe").length?s.find("iframe").attr("src"):"";if(l&&-1!==l.indexOf("vimeo.com")&&s.find("iframe").attr("src",l),i.nextLock||i.prevLock)return!1;var c="next"==e?i.next:i.prev;if(o.linkId&&c&&(i.hashLock=!0,window.location.hash=o.linkId+"/"+c),"next"==e){if(!t.items[c])return!1;var u=i.nextPhoto,h=i.holder,d=i.prevPhoto,p="ilightbox-prev",f="ilightbox-next"}else if("prev"==e){if(!t.items[c])return!1;u=i.prevPhoto,h=i.holder,d=i.nextPhoto,p="ilightbox-next",f="ilightbox-prev"}"function"==typeof o.callback.onBeforeChange&&o.callback.onBeforeChange.call(t,t.ui),"next"==e?i.nextLock=!0:i.prevLock=!0;var m=$("div.ilightbox-caption",h),g=$("div.ilightbox-social",h);if(m.length&&m.stop().fadeOut(r,function(){$(this).remove()}),g.length&&g.stop().fadeOut(r,function(){$(this).remove()}),t.items[c].caption){t.setCaption(t.items[c],u);var v=$("div.ilightbox-caption",u),b=parseInt(v.outerHeight()/u.outerHeight()*100);o.caption.start&&b<=50&&v.fadeIn(r)}var x=t.items[c].options.social;x&&(t.setSocial(x,t.items[c].URL,u),o.social.start&&$("div.ilightbox-social",u).fadeIn(o.effects.fadeSpeed)),$.each([u,h,d],function(e,t){t.removeClass("ilightbox-next ilightbox-prev")});var w=u.data("offset"),y=a.width-o.styles.pageOffsetX,k=a.height-o.styles.pageOffsetY,S=w.newDims.width,L=w.newDims.height,T=w.thumbsOffset,A=w.diff,I=parseInt(k/2-L/2-A.H-T.H/2),C=parseInt(y/2-S/2-A.W-T.W/2);u.css(transform,gpuAcceleration).animate({top:I,left:C,opacity:1},r,i.isSwipe?"easeOutCirc":"easeInOutCirc",function(){u.css(transform,"")}),$("div.ilightbox-container",u).animate({width:S,height:L},r,i.isSwipe?"easeOutCirc":"easeInOutCirc");var O=h.data("offset"),B=O.object;A=O.diff,S=O.newDims.width,L=O.newDims.height,S=parseInt(S*o.styles["next"==e?"prevScale":"nextScale"]),L=parseInt(L*o.styles["next"==e?"prevScale":"nextScale"]),I="horizontal"==n?parseInt(k/2-B.offsetY-L/2-A.H-T.H/2):parseInt(k-B.offsetX-A.H-T.H/2),"prev"==e?C="horizontal"==n?parseInt(y-B.offsetX-A.W-T.W/2):parseInt(y/2-S/2-A.W-B.offsetY-T.W/2):(I="horizontal"==n?I:parseInt(B.offsetX-A.H-L-T.H/2),C="horizontal"==n?parseInt(B.offsetX-A.W-S-T.W/2):parseInt(y/2-B.offsetY-S/2-A.W-T.W/2)),$("div.ilightbox-container",h).animate({width:S,height:L},r,i.isSwipe?"easeOutCirc":"easeInOutCirc"),h.addClass(p).css(transform,gpuAcceleration).animate({top:I,left:C,opacity:o.styles.prevOpacity},r,i.isSwipe?"easeOutCirc":"easeInOutCirc",function(){h.css(transform,""),$(".ilightbox-thumbnail",i.thumbnails).removeClass("ilightbox-active").eq(c).addClass("ilightbox-active"),t.positionThumbnails(),t.items[c]&&(t.items[c].options.mousewheel?i.lockWheel=!1:i.lockWheel=!0,t.items[c].options.swipe?i.lockSwipe=!1:i.lockSwipe=!0),i.isSwipe=!1,"next"==e?(i.nextPhoto=d,i.prevPhoto=h,i.holder=u,i.nextPhoto.hide(),i.next=i.next+1,i.prev=i.current,i.current=i.current+1,o.infinite&&(i.current>i.total-1&&(i.current=0),i.current==i.total-1&&(i.next=0),0==i.current&&(i.prev=i.total-1)),t.createUI(),t.items[i.next]?t.loadContent(t.items[i.next],"next"):i.nextLock=!1):(i.prevPhoto=d,i.nextPhoto=h,i.holder=u,i.prevPhoto.hide(),i.next=i.current,i.current=i.prev,i.prev=i.current-1,o.infinite&&(i.current==i.total-1&&(i.next=0),0==i.current&&(i.prev=i.total-1)),t.createUI(),t.items[i.prev]?t.loadContent(t.items[i.prev],"prev"):i.prevLock=!1),o.linkId&&setTimeout(function(){i.hashLock=!1},55),o.infinite||(i.nextButton.add(i.prevButton).add(i.innerPrevButton).add(i.innerNextButton).removeClass("disabled"),0==i.current&&i.prevButton.add(i.innerPrevButton).addClass("disabled"),i.current>=i.total-1&&i.nextButton.add(i.innerNextButton).addClass("disabled")),t.repositionPhoto(),t.resetCycle(),"function"==typeof o.callback.onAfterChange&&o.callback.onAfterChange.call(t,t.ui)}),I="horizontal"==n?getPixel(d,"top"):"next"==e?parseInt(-k/2-d.outerHeight()):parseInt(2*I),C="horizontal"==n?"next"==e?parseInt(-y/2-d.outerWidth()):parseInt(2*C):getPixel(d,"left"),d.css(transform,gpuAcceleration).animate({top:I,left:C,opacity:o.styles.nextOpacity},r,i.isSwipe?"easeOutCirc":"easeInOutCirc",function(){d.css(transform,"")}).addClass(f)},setCaption:function(e,t){var i=$('
');e.caption&&(i.html(e.caption),$("div.ilightbox-container",t).append(i))},normalizeSocial:function(e,t){this.vars;var i=this.options,o=window.location.href;return $.each(e,function(n,a){if(!a)return!0;var r,s;switch(n.toLowerCase()){case"facebook":r="http://www.facebook.com/share.php?v=4&src=bm&u={URL}",s="Share on Facebook";break;case"twitter":r="http://twitter.com/home?status={URL}",s="Share on Twitter";break;case"delicious":r="http://delicious.com/post?url={URL}",s="Share on Delicious";break;case"digg":r="http://digg.com/submit?phase=2&url={URL}",s="Share on Digg";break;case"reddit":r="http://reddit.com/submit?url={URL}",s="Share on reddit"}e[n]={URL:a.URL&&absolutizeURI(o,a.URL)||i.linkId&&window.location.href||"string"!=typeof t&&o||t&&absolutizeURI(o,t)||o,source:a.source||r||a.URL&&absolutizeURI(o,a.URL)||t&&absolutizeURI(o,t),text:a.text||s||"Share on "+n,width:void 0===a.width||isNaN(a.width)?640:parseInt(a.width),height:a.height||360}}),e},setSocial:function(e,t,i){var o=$('
'),n="
    ";e=this.normalizeSocial(e,t),$.each(e,function(e,t){e.toLowerCase();var i=t.source.replace(/\{URL\}/g,encodeURIComponent(t.URL).replace(/!/g,"%21").replace(/'/g,"%27").replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/\*/g,"%2A").replace(/%20/g,"+"));n+='
  • '}),n+="
",o.html(n),$("div.ilightbox-container",i).append(o)},fullScreenAction:function(){this.vars;fullScreenApi.supportsFullScreen?fullScreenApi.isFullScreen()?fullScreenApi.cancelFullScreen(document.documentElement):fullScreenApi.requestFullScreen(document.documentElement):this.doFullscreen()},doFullscreen:function(){var e=this,t=e.vars,i=getViewport(),o=e.options;if(o.fullAlone){var n=t.holder,a=e.items[t.current],r=i.width,s=i.height,l=[n,t.nextPhoto,t.prevPhoto,t.nextButton,t.prevButton,t.overlay,t.toolbar,t.thumbnails,t.loader],c=[t.loader,t.thumbnails];if(t.isInFullScreen)t.isInFullScreen=t.lockKey=t.lockWheel=t.lockSwipe=!1,t.overlay.css({opacity:e.options.overlay.opacity}),$.each(c,function(e,t){t.show()}),t.fullScreenButton.attr("title",o.text.enterFullscreen),n.data({naturalWidth:n.data("naturalWidthOld"),naturalHeight:n.data("naturalHeightOld"),naturalWidthOld:null,naturalHeightOld:null}),$.each(l,function(e,t){t.removeClass("ilightbox-fullscreen")}),"function"==typeof o.callback.onExitFullScreen&&o.callback.onExitFullScreen.call(e,e.ui);else{if(t.isInFullScreen=t.lockKey=t.lockWheel=t.lockSwipe=!0,t.overlay.css({opacity:1}),$.each(c,function(e,t){t.hide()}),t.fullScreenButton.attr("title",o.text.exitFullscreen),-1!=o.fullStretchTypes.indexOf(a.type))n.data({naturalWidthOld:n.data("naturalWidth"),naturalHeightOld:n.data("naturalHeight"),naturalWidth:r,naturalHeight:s});else{i=a.options.fullViewPort||o.fullViewPort||"";var u=r,h=s,d=n.data("naturalWidth"),p=n.data("naturalHeight");if("fill"==i.toLowerCase())(h=u/d*p)u||p>h;u=(f=e.getNewDimenstions(u,h,d,p,m)).width,h=f.height}n.data({naturalWidthOld:n.data("naturalWidth"),naturalHeightOld:n.data("naturalHeight"),naturalWidth:u,naturalHeight:h})}$.each(l,function(e,t){t.addClass("ilightbox-fullscreen")}),"function"==typeof o.callback.onEnterFullScreen&&o.callback.onEnterFullScreen.call(e,e.ui)}}else t.isInFullScreen?t.isInFullScreen=!1:t.isInFullScreen=!0;e.repositionPhoto(!0)},closeAction:function(){var e=this.vars,t=this.options;$win.unbind(".iLightBox"),$doc.off(".iLightBox"),$doc.off(clickEvent,".ilightbox-overlay"),$doc.off(clickEvent,".ilightbox-next, .ilightbox-next-button"),$doc.off(clickEvent,".ilightbox-prev, .ilightbox-prev-button"),$doc.off(clickEvent,".ilightbox-thumbnail"),$doc.off(clickEvent,".ilightbox-toolbar a.ilightbox-close, .ilightbox-toolbar a.ilightbox-fullscreen, .ilightbox-toolbar a.ilightbox-play, .ilightbox-toolbar a.ilightbox-pause"),e.isInFullScreen&&fullScreenApi.cancelFullScreen(document.documentElement),$(".ilightbox-overlay, .ilightbox-holder, .ilightbox-thumbnails").off(".iLightBox"),t.hide.effect?e.overlay.stop().fadeOut(t.hide.speed,function(){e.overlay.remove(),e.BODY.removeClass("ilightbox-noscroll").off(".iLightBox")}):(e.overlay.remove(),e.BODY.removeClass("ilightbox-noscroll").off(".iLightBox"));var i=[e.toolbar,e.holder,e.nextPhoto,e.prevPhoto,e.nextButton,e.prevButton,e.loader,e.thumbnails];$.each(i,function(e,t){t.removeAttr("style").remove()}),e.prevButton.removeClass("disabled"),e.nextButton.removeClass("disabled"),e.dontGenerateThumbs=e.isInFullScreen=!1,window.iLightBox=null,t.linkId&&(e.hashLock=!0,removeHash(),setTimeout(function(){e.hashLock=!1},55)),"function"==typeof t.callback.onHide&&t.callback.onHide.call(this,this.ui)},repositionPhoto:function(){var e=this,t=e.vars,i=e.options,o=i.path.toLowerCase(),n=getViewport(),a=n.width,r=n.height,s=t.isInFullScreen&&i.fullAlone||t.isMobile?0:"horizontal"==o?0:t.thumbnails.outerWidth(),l=t.isMobile?t.toolbar.outerHeight():t.isInFullScreen&&i.fullAlone?0:"horizontal"==o?t.thumbnails.outerHeight():0,c=t.isInFullScreen&&i.fullAlone?a:a-i.styles.pageOffsetX,u=t.isInFullScreen&&i.fullAlone?r:r-i.styles.pageOffsetY,h="horizontal"==o?parseInt(e.items[t.next]||e.items[t.prev]?2*(i.styles.nextOffsetX+i.styles.prevOffsetX):c/10<=30?30:c/10):parseInt(c/10<=30?30:c/10)+s,d="horizontal"==o?parseInt(u/10<=30?30:u/10)+l:parseInt(e.items[t.next]||e.items[t.prev]?2*(i.styles.nextOffsetX+i.styles.prevOffsetX):u/10<=30?30:u/10),p={type:"current",width:c,height:u,item:e.items[t.current],offsetW:h,offsetH:d,thumbsOffsetW:s,thumbsOffsetH:l,animate:arguments.length,holder:t.holder};e.repositionEl(p),e.items[t.next]&&(p=$.extend(p,{type:"next",item:e.items[t.next],offsetX:i.styles.nextOffsetX,offsetY:i.styles.nextOffsetY,holder:t.nextPhoto}),e.repositionEl(p)),e.items[t.prev]&&(p=$.extend(p,{type:"prev",item:e.items[t.prev],offsetX:i.styles.prevOffsetX,offsetY:i.styles.prevOffsetY,holder:t.prevPhoto}),e.repositionEl(p));var f="horizontal"==o?{left:parseInt(c/2-t.loader.outerWidth()/2)}:{top:parseInt(u/2-t.loader.outerHeight()/2)};t.loader.css(f)},repositionEl:function(e){var t=this.vars,i=this.options,o=i.path.toLowerCase(),n="current"==e.type&&t.isInFullScreen&&i.fullAlone?e.width:e.width-e.offsetW,a="current"==e.type&&t.isInFullScreen&&i.fullAlone?e.height:e.height-e.offsetH,r=e.item,s=e.item.options,l=e.holder,c=e.offsetX||0,u=e.offsetY||0,h=e.thumbsOffsetW,d=e.thumbsOffsetH;"current"==e.type?("number"==typeof s.width&&s.width&&(n=t.isInFullScreen&&i.fullAlone&&(-1!=i.fullStretchTypes.indexOf(r.type)||s.fullViewPort||i.fullViewPort)?n:s.width>n?n:s.width),"number"==typeof s.height&&s.height&&(a=t.isInFullScreen&&i.fullAlone&&(-1!=i.fullStretchTypes.indexOf(r.type)||s.fullViewPort||i.fullViewPort)?a:s.height>a?a:s.height)):("number"==typeof s.width&&s.width&&(n=s.width>n?n:s.width),"number"==typeof s.height&&s.height&&(a=s.height>a?a:s.height)),a=parseInt(a-$(".ilightbox-inner-toolbar",l).outerHeight());var p="string"==typeof s.width&&-1!=s.width.indexOf("%")?percentToValue(parseInt(s.width.replace("%","")),e.width):l.data("naturalWidth"),f="string"==typeof s.height&&-1!=s.height.indexOf("%")?percentToValue(parseInt(s.height.replace("%","")),e.height):l.data("naturalHeight"),m="string"==typeof s.width&&-1!=s.width.indexOf("%")||"string"==typeof s.height&&-1!=s.height.indexOf("%")?{width:p,height:f}:this.getNewDimenstions(n,a,p,f),g=$.extend({},m,{});"prev"==e.type||"next"==e.type?(p=parseInt(m.width*("next"==e.type?i.styles.nextScale:i.styles.prevScale)),f=parseInt(m.height*("next"==e.type?i.styles.nextScale:i.styles.prevScale))):(p=m.width,f=m.height);var v=parseInt((getPixel(l,"padding-left")+getPixel(l,"padding-right")+getPixel(l,"border-left-width")+getPixel(l,"border-right-width"))/2),b=parseInt((getPixel(l,"padding-top")+getPixel(l,"padding-bottom")+getPixel(l,"border-top-width")+getPixel(l,"border-bottom-width")+($(".ilightbox-inner-toolbar",l).outerHeight()||0))/2);switch(e.type){case"current":var x=parseInt(e.height/2-f/2-b-d/2),w=parseInt(e.width/2-p/2-v-h/2);break;case"next":x="horizontal"==o?parseInt(e.height/2-u-f/2-b-d/2):parseInt(e.height-c-b-d/2),w="horizontal"==o?parseInt(e.width-c-v-h/2):parseInt(e.width/2-p/2-v-u-h/2);break;case"prev":x="horizontal"==o?parseInt(e.height/2-u-f/2-b-d/2):parseInt(c-b-f-d/2),w="horizontal"==o?parseInt(c-v-p-h/2):parseInt(e.width/2-u-p/2-v-h/2)}l.data("offset",{top:x,left:w,newDims:g,diff:{W:v,H:b},thumbsOffset:{W:h,H:d},object:e}),e.animate>0&&i.effects.reposition?(l.css(transform,gpuAcceleration).stop().animate({top:x,left:w},i.effects.repositionSpeed,"easeOutCirc",function(){l.css(transform,"")}),$("div.ilightbox-container",l).stop().animate({width:p,height:f},i.effects.repositionSpeed,"easeOutCirc"),$("div.ilightbox-inner-toolbar",l).stop().animate({width:p},i.effects.repositionSpeed,"easeOutCirc",function(){$(this).css("overflow","visible")})):(l.css({top:x,left:w}),$("div.ilightbox-container",l).css({width:p,height:f}),$("div.ilightbox-inner-toolbar",l).css({width:p}))},resume:function(e){var t=this,i=t.vars,o=t.options;!o.slideshow.pauseTime||o.controls.slideshow&&i.total<=1||ea.options.maxScale?factor=a.options.maxScale:factor=0,html5H264:!(!e.canPlayType||!e.canPlayType("video/mp4").replace(/no/,"")),html5WebM:!(!e.canPlayType||!e.canPlayType("video/webm").replace(/no/,"")),html5Vorbis:!(!e.canPlayType||!e.canPlayType("video/ogg").replace(/no/,"")),html5QuickTime:!(!e.canPlayType||!e.canPlayType("video/quicktime").replace(/no/,""))}},addContent:function(e,t){var i=this;switch(t.type){case"video":var o=!1,n=t.videoType,a=t.options.html5video;("video/mp4"==n||"mp4"==t.ext||"m4v"==t.ext||a.h264)&&i.plugins.html5H264?(t.ext="mp4",t.URL=a.h264||t.URL):a.webm&&i.plugins.html5WebM?(t.ext="webm",t.URL=a.webm||t.URL):a.ogg&&i.plugins.html5Vorbis&&(t.ext="ogv",t.URL=a.ogg||t.URL),!i.plugins.html5H264||"video/mp4"!=n&&"mp4"!=t.ext&&"m4v"!=t.ext?!i.plugins.html5WebM||"video/webm"!=n&&"webm"!=t.ext?!i.plugins.html5Vorbis||"video/ogg"!=n&&"ogv"!=t.ext?!i.plugins.html5QuickTime||"video/quicktime"!=n&&"mov"!=t.ext&&"qt"!=t.ext||(o=!0,n="video/quicktime"):(o=!0,n="video/ogg"):(o=!0,n="video/webm"):(o=!0,n="video/mp4"),o?g=$("