LocalCDN-Firefox-Chrome-Brave/resources/slider-pro/1.6.0/jquery.sliderPro.min.jsm

8 lines
95 KiB
JavaScript

/*!
* - v1.6.0
* Homepage: http://bqworks.net/slider-pro/
* Author: bqworks
* Author URL: http://bqworks.net/
*/
!function(c,p){"use strict";p.SliderPro={modules:[],addModule:function(t,i){this.modules.push(t),p.extend(n.prototype,i)}};var m=p.SliderPro.namespace="SliderPro",n=function(t,i){this.instance=t,this.$slider=p(this.instance),this.$slides=null,this.$slidesMask=null,this.$slidesContainer=null,this.slides=[],this.slidesOrder=[],this.options=i,this.settings={},this.originalSettings={},this.originalGotoSlide=null,this.selectedSlideIndex=0,this.previousSlideIndex=0,this.middleSlidePosition=0,this.supportedAnimation=null,this.vendorPrefix=null,this.transitionEvent=null,this.positionProperty=null,this.sizeProperty=null,this.isIE=null,this.slidesPosition=0,this.slidesSize=0,this.averageSlideSize=0,this.slideWidth=0,this.slideHeight=0,this.previousSlideWidth=0,this.previousSlideHeight=0,this.previousWindowWidth=0,this.previousWindowHeight=0,this.allowResize=!0,this.uniqueId=(new Date).valueOf(),this.breakpoints=[],this.currentBreakpoint=-1,this.shuffledIndexes=[],this._init()};n.prototype={_init:function(){var e=this;this.supportedAnimation=g.getSupportedAnimation(),this.vendorPrefix=g.getVendorPrefix(),this.transitionEvent=g.getTransitionEvent(),this.isIE=g.checkIE(),this.$slider.removeClass("sp-no-js"),c.navigator.userAgent.match(/(iPad|iPhone|iPod)/g)&&this.$slider.addClass("ios");var t=/(msie) ([\w.]+)/.exec(c.navigator.userAgent.toLowerCase());this.isIE&&this.$slider.addClass("ie"),null!==t&&this.$slider.addClass("ie"+parseInt(t[2],10)),this.$slidesContainer=p('<div class="sp-slides-container"></div>').appendTo(this.$slider),this.$slidesMask=p('<div class="sp-mask"></div>').appendTo(this.$slidesContainer),this.$slides=this.$slider.find(".sp-slides").appendTo(this.$slidesMask),this.$slider.find(".sp-slide").appendTo(this.$slides);var i=p.SliderPro.modules;if(void 0!==i)for(var s=0;s<i.length;s++){var n=i[s].substring(0,1).toLowerCase()+i[s].substring(1)+"Defaults";void 0!==this[n]&&p.extend(this.defaults,this[n])}if(this.settings=p.extend({},this.defaults,this.options),void 0!==i)for(var o=0;o<i.length;o++)void 0!==this["init"+i[o]]&&this["init"+i[o]]();if(this.originalSettings=p.extend({},this.settings),this.originalGotoSlide=this.gotoSlide,null!==this.settings.breakpoints){for(var a in this.settings.breakpoints)this.breakpoints.push({size:parseInt(a,10),properties:this.settings.breakpoints[a]});this.breakpoints=this.breakpoints.sort(function(t,i){return t.size>=i.size?1:-1})}if(this.selectedSlideIndex=this.settings.startSlide,!0===this.settings.shuffle){var h=this.$slides.find(".sp-slide"),r=[];h.each(function(t){e.shuffledIndexes.push(t)});for(var l=this.shuffledIndexes.length-1;0<l;l--){var d=Math.floor(Math.random()*(l+1)),u=this.shuffledIndexes[l];this.shuffledIndexes[l]=this.shuffledIndexes[d],this.shuffledIndexes[d]=u}p.each(this.shuffledIndexes,function(t,i){r.push(h[i])}),this.$slides.empty().append(r)}p(c).on("resize."+this.uniqueId+"."+m,function(){var t=p(c).width(),i=p(c).height();!1===e.allowResize||e.previousWindowWidth===t&&e.previousWindowHeight===i||(e.previousWindowWidth=t,e.previousWindowHeight=i,e.allowResize=!1,setTimeout(function(){e.resize(),e.allowResize=!0},200))}),this.on("update."+m,function(){e.previousSlideWidth=0,e.resize()}),this.update(),this.$slides.find(".sp-slide").eq(this.selectedSlideIndex).addClass("sp-selected"),this.trigger({type:"init"}),p.isFunction(this.settings.init)&&this.settings.init.call(this,{type:"init"})},update:function(){var e=this;"horizontal"===this.settings.orientation?(this.$slider.removeClass("sp-vertical").addClass("sp-horizontal"),this.$slider.css({height:"","max-height":""}),this.$slides.find(".sp-slide").css("top","")):"vertical"===this.settings.orientation&&(this.$slider.removeClass("sp-horizontal").addClass("sp-vertical"),this.$slides.find(".sp-slide").css("left","")),!0===this.settings.rightToLeft?this.$slider.addClass("sp-rtl"):this.$slider.removeClass("sp-rtl"),this.positionProperty="horizontal"===this.settings.orientation?"left":"top",this.sizeProperty="horizontal"===this.settings.orientation?"width":"height",this.gotoSlide=this.originalGotoSlide;for(var t,i=this.slides.length-1;0<=i;i--)0===this.$slider.find('.sp-slide[data-index="'+i+'"]').length&&((t=this.slides[i]).off("imagesLoaded."+m),t.destroy(),this.slides.splice(i,1));this.slidesOrder.length=0,this.$slider.find(".sp-slide").each(function(t){var i=p(this);void 0===i.attr("data-init")?e._createSlide(t,i):e.slides[t].setIndex(t),e.slidesOrder.push(t)}),this.middleSlidePosition=parseInt((e.slidesOrder.length-1)/2,10),!0===this.settings.loop&&this._updateSlidesOrder(),this.trigger({type:"update"}),p.isFunction(this.settings.update)&&this.settings.update.call(this,{type:"update"})},_createSlide:function(t,i){var e=this,s=new o(p(i),t,this.settings);this.slides.splice(t,0,s),s.on("imagesLoaded."+m,function(t){!0===e.settings.autoSlideSize&&(!1===e.$slides.hasClass("sp-animated")&&e._resetSlidesPosition(),e._calculateSlidesSize()),!0===e.settings.autoHeight&&t.index===e.selectedSlideIndex&&e._resizeHeightTo(s.getSize().height)})},_updateSlidesOrder:function(){var t,i,e=p.inArray(this.selectedSlideIndex,this.slidesOrder)-this.middleSlidePosition;if(e<0)for(i=(t=this.slidesOrder.splice(e,Math.abs(e))).length-1;0<=i;i--)this.slidesOrder.unshift(t[i]);else if(0<e)for(t=this.slidesOrder.splice(0,e),i=0;i<=t.length-1;i++)this.slidesOrder.push(t[i])},_updateSlidesPosition:function(){var t,i,e,s,n,o=parseInt(this.$slides.find(".sp-slide").eq(this.selectedSlideIndex).css(this.positionProperty),10),a=o;if(!0===this.settings.autoSlideSize)if(!0===this.settings.rightToLeft&&"horizontal"===this.settings.orientation){for(e=this.middleSlidePosition;0<=e;e--)(i=(t=this.getSlideAt(this.slidesOrder[e])).$slide).css(this.positionProperty,a),a=parseInt(i.css(this.positionProperty),10)+t.getSize()[this.sizeProperty]+this.settings.slideDistance;for(a=o,e=this.middleSlidePosition+1;e<this.slidesOrder.length;e++)(i=(t=this.getSlideAt(this.slidesOrder[e])).$slide).css(this.positionProperty,a-(t.getSize()[this.sizeProperty]+this.settings.slideDistance)),a=parseInt(i.css(this.positionProperty),10)}else{for(e=this.middleSlidePosition-1;0<=e;e--)(i=(t=this.getSlideAt(this.slidesOrder[e])).$slide).css(this.positionProperty,a-(t.getSize()[this.sizeProperty]+this.settings.slideDistance)),a=parseInt(i.css(this.positionProperty),10);for(a=o,e=this.middleSlidePosition;e<this.slidesOrder.length;e++)(i=(t=this.getSlideAt(this.slidesOrder[e])).$slide).css(this.positionProperty,a),a=parseInt(i.css(this.positionProperty),10)+t.getSize()[this.sizeProperty]+this.settings.slideDistance}else for(s=!0===this.settings.rightToLeft&&"horizontal"===this.settings.orientation?-1:1,n="horizontal"===this.settings.orientation?this.slideWidth:this.slideHeight,e=0;e<this.slidesOrder.length;e++)(i=this.$slides.find(".sp-slide").eq(this.slidesOrder[e])).css(this.positionProperty,o+s*(e-this.middleSlidePosition)*(n+this.settings.slideDistance))},_resetSlidesPosition:function(){var t,i,e,s,n,o=0;if(!0===this.settings.autoSlideSize){if(!0===this.settings.rightToLeft&&"horizontal"===this.settings.orientation)for(e=0;e<this.slidesOrder.length;e++)(i=(t=this.getSlideAt(this.slidesOrder[e])).$slide).css(this.positionProperty,o-(t.getSize()[this.sizeProperty]+this.settings.slideDistance)),o=parseInt(i.css(this.positionProperty),10);else for(e=0;e<this.slidesOrder.length;e++)(i=(t=this.getSlideAt(this.slidesOrder[e])).$slide).css(this.positionProperty,o),o=parseInt(i.css(this.positionProperty),10)+t.getSize()[this.sizeProperty]+this.settings.slideDistance;a=this.getSlideAt(this.selectedSlideIndex).getSize()[this.sizeProperty]}else{for(s=!0==(!0===this.settings.rightToLeft&&"horizontal"===this.settings.orientation)?-1:1,n="horizontal"===this.settings.orientation?this.slideWidth:this.slideHeight,e=0;e<this.slidesOrder.length;e++)(i=this.$slides.find(".sp-slide").eq(this.slidesOrder[e])).css(this.positionProperty,s*e*(n+this.settings.slideDistance));a=n}var a=!0===this.settings.centerSelectedSlide&&"auto"!==this.settings.visibleSize?Math.round((parseInt(this.$slidesMask.css(this.sizeProperty),10)-a)/2):0,a=-parseInt(this.$slides.find(".sp-slide").eq(this.selectedSlideIndex).css(this.positionProperty),10)+a;this._moveTo(a,!0)},_calculateSlidesSize:function(){var t,i;!0===this.settings.autoSlideSize?(i=this.$slides.find(".sp-slide").eq(this.slidesOrder[0]),t=parseInt(i.css(this.positionProperty),10),i=this.$slides.find(".sp-slide").eq(this.slidesOrder[this.slidesOrder.length-1]),i=parseInt(i.css(this.positionProperty),10)+(!0===this.settings.rightToLeft&&"horizontal"===this.settings.orientation?-1:1)*parseInt(i.css(this.sizeProperty),10),this.slidesSize=Math.abs(i-t),this.averageSlideSize=Math.round(this.slidesSize/this.slides.length)):(this.slidesSize=(("horizontal"===this.settings.orientation?this.slideWidth:this.slideHeight)+this.settings.slideDistance)*this.slides.length-this.settings.slideDistance,this.averageSlideSize="horizontal"===this.settings.orientation?this.slideWidth:this.slideHeight)},resize:function(){var t=this;if(null!==this.settings.breakpoints&&0<this.breakpoints.length)if(p(c).width()>this.breakpoints[this.breakpoints.length-1].size&&-1!==this.currentBreakpoint)this.currentBreakpoint=-1,this._setProperties(this.originalSettings,!1);else for(var i=0,e=this.breakpoints.length;i<e;i++)if(p(c).width()<=this.breakpoints[i].size){if(this.currentBreakpoint===this.breakpoints[i].size)break;var s={type:"breakpointReach",size:this.breakpoints[i].size,settings:this.breakpoints[i].properties};this.trigger(s),p.isFunction(this.settings.breakpointReach)&&this.settings.breakpointReach.call(this,s),this.currentBreakpoint=this.breakpoints[i].size;s=p.extend({},this.originalSettings,this.breakpoints[i].properties);return void this._setProperties(s,!1)}!0===this.settings.responsive?"fullWidth"!==this.settings.forceSize&&"fullWindow"!==this.settings.forceSize||"auto"!==this.settings.visibleSize&&("auto"===this.settings.visibleSize||"vertical"!==this.settings.orientation)?this.$slider.css({width:"100%","max-width":this.settings.width,marginLeft:""}):(this.$slider.css("margin",0),this.$slider.css({width:p(c).width(),"max-width":"",marginLeft:-this.$slider.offset().left})):this.$slider.css({width:this.settings.width}),-1===this.settings.aspectRatio&&(this.settings.aspectRatio=this.settings.width/this.settings.height),this.slideWidth=this.$slider.width(),"fullWindow"===this.settings.forceSize?this.slideHeight=p(c).height():this.slideHeight=isNaN(this.settings.aspectRatio)?this.settings.height:this.slideWidth/this.settings.aspectRatio,(this.previousSlideWidth!==this.slideWidth||this.previousSlideHeight!==this.slideHeight||"auto"!==this.settings.visibleSize||this.$slider.outerWidth()>this.$slider.parent().width()||this.$slider.width()!==this.$slidesMask.width())&&(this.previousSlideWidth=this.slideWidth,this.previousSlideHeight=this.slideHeight,this._resizeSlides(),this.$slidesMask.css({width:this.slideWidth,height:this.slideHeight}),!0===this.settings.autoHeight?setTimeout(function(){t._resizeHeight()},1):this.$slidesMask.css(this.vendorPrefix+"transition",""),"auto"!==this.settings.visibleSize&&("horizontal"===this.settings.orientation?("fullWidth"===this.settings.forceSize||"fullWindow"===this.settings.forceSize?(this.$slider.css("margin",0),this.$slider.css({width:p(c).width(),"max-width":"",marginLeft:-this.$slider.offset().left})):this.$slider.css({width:this.settings.visibleSize,"max-width":"100%",marginLeft:0}),this.$slidesMask.css("width",this.$slider.width())):("fullWindow"===this.settings.forceSize?this.$slider.css({height:p(c).height(),"max-height":""}):this.$slider.css({height:this.settings.visibleSize,"max-height":"100%"}),this.$slidesMask.css("height",this.$slider.height()))),this._resetSlidesPosition(),this._calculateSlidesSize(),this.trigger({type:"sliderResize"}),p.isFunction(this.settings.sliderResize)&&this.settings.sliderResize.call(this,{type:"sliderResize"}))},_resizeSlides:function(){var e=this.slideWidth,s=this.slideHeight;!0===this.settings.autoSlideSize?"horizontal"===this.settings.orientation?e="auto":"vertical"===this.settings.orientation&&(s="auto"):!0===this.settings.autoHeight&&(s="auto"),p.each(this.slides,function(t,i){i.setSize(e,s)})},_resizeHeight:function(){var t=this.getSlideAt(this.selectedSlideIndex);this._resizeHeightTo(t.getSize().height)},gotoSlide:function(t){var i,e;t!==this.selectedSlideIndex&&void 0!==this.slides[t]&&((i=this).previousSlideIndex=this.selectedSlideIndex,this.selectedSlideIndex=t,this.$slides.find(".sp-selected").removeClass("sp-selected"),this.$slides.find(".sp-slide").eq(this.selectedSlideIndex).addClass("sp-selected"),!0===this.settings.loop&&(this._updateSlidesOrder(),this._updateSlidesPosition()),!0===this.settings.autoHeight&&this._resizeHeight(),e=!0===this.settings.centerSelectedSlide&&"auto"!==this.settings.visibleSize?Math.round((parseInt(this.$slidesMask.css(this.sizeProperty),10)-this.getSlideAt(this.selectedSlideIndex).getSize()[this.sizeProperty])/2):0,e=-parseInt(this.$slides.find(".sp-slide").eq(this.selectedSlideIndex).css(this.positionProperty),10)+e,this._moveTo(e,!1,function(){i._resetSlidesPosition(),i.trigger({type:"gotoSlideComplete",index:t,previousIndex:i.previousSlideIndex}),p.isFunction(i.settings.gotoSlideComplete)&&i.settings.gotoSlideComplete.call(i,{type:"gotoSlideComplete",index:t,previousIndex:i.previousSlideIndex})}),this.trigger({type:"gotoSlide",index:t,previousIndex:this.previousSlideIndex}),p.isFunction(this.settings.gotoSlide)&&this.settings.gotoSlide.call(this,{type:"gotoSlide",index:t,previousIndex:this.previousSlideIndex}))},nextSlide:function(){var t=this.selectedSlideIndex>=this.getTotalSlides()-1?0:this.selectedSlideIndex+1;this.gotoSlide(t)},previousSlide:function(){var t=this.selectedSlideIndex<=0?this.getTotalSlides()-1:this.selectedSlideIndex-1;this.gotoSlide(t)},_moveTo:function(t,i,e){var s,n,o=this,a={};t!==this.slidesPosition&&(this.slidesPosition=t,"css-3d"!==this.supportedAnimation&&"css-2d"!==this.supportedAnimation||!1!==this.isIE?(a["margin-"+this.positionProperty]=t,void 0!==i&&!0===i?this.$slides.css(a):(this.$slides.addClass("sp-animated"),this.$slides.animate(a,this.settings.slideAnimationDuration,function(){o.$slides.removeClass("sp-animated"),"function"==typeof e&&e()}))):(n="horizontal"===this.settings.orientation?t:0,t="horizontal"===this.settings.orientation?0:t,"css-3d"===this.supportedAnimation?a[this.vendorPrefix+"transform"]="translate3d("+n+"px, "+t+"px, 0)":a[this.vendorPrefix+"transform"]="translate("+n+"px, "+t+"px)",void 0!==i&&!0===i?s="":(this.$slides.addClass("sp-animated"),s=this.vendorPrefix+"transform "+this.settings.slideAnimationDuration/1e3+"s",this.$slides.on(this.transitionEvent,function(t){t.target===t.currentTarget&&(o.$slides.off(o.transitionEvent),o.$slides.removeClass("sp-animated"),"function"==typeof e&&e())})),a[this.vendorPrefix+"transition"]=s,this.$slides.css(a)))},_stopMovement:function(){var t,i,e,s={};"css-3d"!==this.supportedAnimation&&"css-2d"!==this.supportedAnimation||!1!==this.isIE?(this.$slides.stop(),this.slidesPosition=parseInt(this.$slides.css("margin-"+this.positionProperty),10)):(t=-1!==(i=this.$slides.css(this.vendorPrefix+"transform")).indexOf("matrix3d")?"matrix3d":"matrix",e=i.replace(t,"").match(/-?[0-9\.]+/g),i="matrix3d"==t?parseInt(e[12],10):parseInt(e[4],10),e="matrix3d"==t?parseInt(e[13],10):parseInt(e[5],10),"css-3d"===this.supportedAnimation?s[this.vendorPrefix+"transform"]="translate3d("+i+"px, "+e+"px, 0)":s[this.vendorPrefix+"transform"]="translate("+i+"px, "+e+"px)",s[this.vendorPrefix+"transition"]="",this.$slides.css(s),this.$slides.off(this.transitionEvent),this.slidesPosition="horizontal"===this.settings.orientation?i:e),this.$slides.removeClass("sp-animated")},_resizeHeightTo:function(t){var i=this,t={height:t};"css-3d"===this.supportedAnimation||"css-2d"===this.supportedAnimation?(t[this.vendorPrefix+"transition"]="height "+this.settings.heightAnimationDuration/1e3+"s",this.$slidesMask.off(this.transitionEvent),this.$slidesMask.on(this.transitionEvent,function(t){t.target===t.currentTarget&&(i.$slidesMask.off(i.transitionEvent),i.trigger({type:"resizeHeightComplete"}),p.isFunction(i.settings.resizeHeightComplete)&&i.settings.resizeHeightComplete.call(i,{type:"resizeHeightComplete"}))}),this.$slidesMask.css(t)):this.$slidesMask.stop().animate(t,this.settings.heightAnimationDuration,function(t){i.trigger({type:"resizeHeightComplete"}),p.isFunction(i.settings.resizeHeightComplete)&&i.settings.resizeHeightComplete.call(i,{type:"resizeHeightComplete"})})},destroy:function(){this.$slider.removeData("sliderPro"),this.$slider.removeAttr("style"),this.$slides.removeAttr("style"),this.off("update."+m),p(c).off("resize."+this.uniqueId+"."+m);var t=p.SliderPro.modules;if(void 0!==t)for(var i=0;i<t.length;i++)void 0!==this["destroy"+t[i]]&&this["destroy"+t[i]]();p.each(this.slides,function(t,i){i.destroy()}),this.slides.length=0,this.$slides.prependTo(this.$slider),this.$slidesContainer.remove()},_setProperties:function(t,i){for(var e in t)this.settings[e]=t[e],!1!==i&&(this.originalSettings[e]=t[e]);this.update()},on:function(t,i){return this.$slider.on(t,i)},off:function(t){return this.$slider.off(t)},trigger:function(t){return this.$slider.triggerHandler(t)},getSlideAt:function(t){return this.slides[t]},getSelectedSlide:function(){return this.selectedSlideIndex},getTotalSlides:function(){return this.slides.length},defaults:{width:500,height:300,responsive:!0,aspectRatio:-1,imageScaleMode:"cover",centerImage:!0,allowScaleUp:!0,autoHeight:!1,autoSlideSize:!1,startSlide:0,shuffle:!1,orientation:"horizontal",forceSize:"none",loop:!0,slideDistance:10,slideAnimationDuration:700,heightAnimationDuration:700,visibleSize:"auto",centerSelectedSlide:!0,rightToLeft:!1,breakpoints:null,init:function(){},update:function(){},sliderResize:function(){},gotoSlide:function(){},gotoSlideComplete:function(){},resizeHeightComplete:function(){},breakpointReach:function(){}}};var o=function(t,i,e){this.$slide=t,this.$mainImage=null,this.$imageContainer=null,this.hasMainImage=!1,this.isMainImageLoaded=!1,this.isMainImageLoading=!1,this.hasImages=!1,this.areImagesLoaded=!1,this.areImagesLoading=!1,this.width=0,this.height=0,this.settings=e,this.setIndex(i),this._init()};o.prototype={_init:function(){this.$slide.attr("data-init",!0),this.$mainImage=0!==this.$slide.find(".sp-image").length?this.$slide.find(".sp-image"):null,null!==this.$mainImage&&(this.hasMainImage=!0,this.$imageContainer=p('<div class="sp-image-container"></div>').prependTo(this.$slide),(0!==this.$mainImage.parent("a").length?this.$mainImage.parent("a"):this.$mainImage).appendTo(this.$imageContainer)),this.hasImages=0!==this.$slide.find("img").length},setSize:function(t,i){this.width=t,this.height=i,this.$slide.css({width:this.width,height:this.height}),!0===this.hasMainImage&&(this.$imageContainer.css({width:this.settings.width,height:this.settings.height}),void 0===this.$mainImage.attr("data-src")&&this.resizeMainImage())},getSize:function(){var t,i=this;if(!0===this.hasImages&&!1===this.areImagesLoaded&&!1===this.areImagesLoading&&(this.areImagesLoading=!0,"complete"!==g.checkImagesStatus(this.$slide)))return g.checkImagesComplete(this.$slide,function(){i.areImagesLoaded=!0,i.areImagesLoading=!1,i.trigger({type:"imagesLoaded."+m,index:i.index})}),{width:this.settings.width,height:this.settings.height};return{width:(t=this.calculateSize()).width,height:t.height}},calculateSize:function(){var n=this.$slide.width(),o=this.$slide.height();return this.$slide.children().each(function(t,i){var e,s=p(i);!0!==s.is(":hidden")&&(e=i.getBoundingClientRect(),i=s.position().top+(e.bottom-e.top),e=s.position().left+(e.right-e.left),o<i&&(o=i),n<e&&(n=e))}),{width:n,height:o}},resizeMainImage:function(t){var i=this;if(!0===t&&(this.isMainImageLoaded=!1,this.isMainImageLoading=!1),!1===this.isMainImageLoaded&&!1===this.isMainImageLoading)return this.isMainImageLoading=!0,void g.checkImagesComplete(this.$mainImage,function(){i.isMainImageLoaded=!0,i.isMainImageLoading=!1,i.resizeMainImage(),i.trigger({type:"imagesLoaded."+m,index:i.index})});this.$imageContainer.css({width:this.width,height:this.height}),!1===this.settings.allowScaleUp&&(this.$mainImage.css({width:"",height:"",maxWidth:"",maxHeight:""}),this.$mainImage.css({maxWidth:this.$mainImage.width(),maxHeight:this.$mainImage.height()})),!0===this.settings.autoSlideSize?"horizontal"===this.settings.orientation?(this.$mainImage.css({width:"auto",height:"100%"}),this.$slide.css("width",this.$mainImage.width())):"vertical"===this.settings.orientation&&(this.$mainImage.css({width:"100%",height:"auto"}),this.$slide.css("height",this.$mainImage.height())):!0===this.settings.autoHeight?(this.$mainImage.css({width:"100%",height:"auto"}),!0===this.settings.centerImage&&this.$mainImage.css({marginLeft:.5*(this.$imageContainer.width()-this.$mainImage.width())})):("cover"===this.settings.imageScaleMode?this.$mainImage.width()/this.$mainImage.height()<=this.$slide.width()/this.$slide.height()?this.$mainImage.css({width:"100%",height:"auto"}):this.$mainImage.css({width:"auto",height:"100%"}):"contain"===this.settings.imageScaleMode?this.$mainImage.width()/this.$mainImage.height()>=this.$slide.width()/this.$slide.height()?this.$mainImage.css({width:"100%",height:"auto"}):this.$mainImage.css({width:"auto",height:"100%"}):"exact"===this.settings.imageScaleMode&&this.$mainImage.css({width:"100%",height:"100%"}),!0===this.settings.centerImage&&this.$mainImage.css({marginLeft:.5*(this.$imageContainer.width()-this.$mainImage.width()),marginTop:.5*(this.$imageContainer.height()-this.$mainImage.height())}))},destroy:function(){this.$slide.removeAttr("style"),this.$slide.removeAttr("data-init"),this.$slide.removeAttr("data-index"),this.$slide.removeAttr("data-loaded"),!0===this.hasMainImage&&(this.$slide.find(".sp-image").removeAttr("style").appendTo(this.$slide),this.$slide.find(".sp-image-container").remove())},getIndex:function(){return this.index},setIndex:function(t){this.index=t,this.$slide.attr("data-index",this.index)},on:function(t,i){return this.$slide.on(t,i)},off:function(t){return this.$slide.off(t)},trigger:function(t){return this.$slide.triggerHandler(t)}},c.SliderPro=n,c.SliderProSlide=o,p.fn.sliderPro=function(e){var s=Array.prototype.slice.call(arguments,1);return this.each(function(){var t,i;void 0===p(this).data("sliderPro")?(i=new n(this,e),p(this).data("sliderPro",i)):void 0!==e&&("function"==typeof(t=p(this).data("sliderPro"))[e]?t[e].apply(t,s):void 0!==t.settings[e]?((i={})[e]=s[0],t._setProperties(i)):"object"==typeof e?t._setProperties(e):p.error(e+" does not exist in sliderPro."))})};var g={supportedAnimation:null,vendorPrefix:null,transitionEvent:null,isIE:null,getSupportedAnimation:function(){if(null!==this.supportedAnimation)return this.supportedAnimation;var t,i=(document.body||document.documentElement).style;return!0==(void 0!==i.transition||void 0!==i.WebkitTransition||void 0!==i.MozTransition||void 0!==i.OTransition)?(void 0===(t=document.createElement("div")).style.WebkitPerspective&&void 0===t.style.perspective||(this.supportedAnimation="css-3d"),"css-3d"===this.supportedAnimation&&void 0!==t.styleWebkitPerspective&&((i=document.createElement("style")).textContent="@media (transform-3d),(-webkit-transform-3d){#test-3d{left:9px;position:absolute;height:5px;margin:0;padding:0;border:0;}}",document.getElementsByTagName("head")[0].appendChild(i),t.id="test-3d",document.body.appendChild(t),9===t.offsetLeft&&5===t.offsetHeight||(this.supportedAnimation=null),i.parentNode.removeChild(i),t.parentNode.removeChild(t)),null!==this.supportedAnimation||void 0===t.style["-webkit-transform"]&&void 0===t.style.transform||(this.supportedAnimation="css-2d")):this.supportedAnimation="javascript",this.supportedAnimation},getVendorPrefix:function(){if(null!==this.vendorPrefix)return this.vendorPrefix;var t=document.createElement("div"),i=["Webkit","Moz","ms","O"];if("transform"in t.style)return this.vendorPrefix="",this.vendorPrefix;for(var e=0;e<i.length;e++)if(i[e]+"Transform"in t.style){this.vendorPrefix="-"+i[e].toLowerCase()+"-";break}return this.vendorPrefix},getTransitionEvent:function(){if(null!==this.transitionEvent)return this.transitionEvent;var t,i=document.createElement("div"),e={transition:"transitionend",WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd"};for(t in e)if(t in i.style){this.transitionEvent=e[t];break}return this.transitionEvent},checkImagesComplete:function(t,i){var e,s=this,n=this.checkImagesStatus(t);return"loading"===n?e=setInterval(function(){"complete"===(n=s.checkImagesStatus(t))&&(clearInterval(e),"function"==typeof i&&i())},100):"function"==typeof i&&i(),n},checkImagesStatus:function(t){var i="complete";return t.is("img")&&!1===t[0].complete?i="loading":t.find("img").each(function(t){!1===p(this)[0].complete&&(i="loading")}),i},checkIE:function(){if(null!==this.isIE)return this.isIE;var t=c.navigator.userAgent;t.indexOf("MSIE");return-1!==t.indexOf("MSIE")||t.match(/Trident.*rv\:11\./)?this.isIE=!0:this.isIE=!1,this.isIE}};c.SliderProUtils=g}(window,jQuery),function(e,r){"use strict";var s="Thumbnails."+r.SliderPro.namespace,t={$thumbnails:null,$thumbnailsContainer:null,thumbnails:null,selectedThumbnailIndex:0,thumbnailsSize:0,thumbnailsContainerSize:0,thumbnailsPosition:0,thumbnailsOrientation:null,thumbnailsPositionProperty:null,isThumbnailScroller:!1,initThumbnails:function(){var i=this;this.thumbnails=[],this.on("update."+s,r.proxy(this._thumbnailsOnUpdate,this)),this.on("sliderResize."+s,r.proxy(this._thumbnailsOnResize,this)),this.on("gotoSlide."+s,function(t){i._gotoThumbnail(t.index)})},_thumbnailsOnUpdate:function(){var e,s,n=this;if(0!==this.$slider.find(".sp-thumbnail").length||0!==this.thumbnails.length){this.isThumbnailScroller=!0,null===this.$thumbnailsContainer&&(this.$thumbnailsContainer=r('<div class="sp-thumbnails-container"></div>').insertAfter(this.$slidesContainer)),null===this.$thumbnails&&(0!==this.$slider.find(".sp-thumbnails").length?(this.$thumbnails=this.$slider.find(".sp-thumbnails").appendTo(this.$thumbnailsContainer),!0===this.settings.shuffle&&(e=this.$thumbnails.find(".sp-thumbnail"),s=[],r.each(this.shuffledIndexes,function(t,i){i=r(e[i]);0!==i.parent("a").length&&(i=i.parent("a")),s.push(i)}),this.$thumbnails.empty().append(s))):this.$thumbnails=r('<div class="sp-thumbnails"></div>').appendTo(this.$thumbnailsContainer)),this.$slides.find(".sp-thumbnail").each(function(t){var i=r(this),e=i.parents(".sp-slide").index(),s=n.$thumbnails.find(".sp-thumbnail").length-1;0!==i.parent("a").length&&(i=i.parent("a")),s<e?i.appendTo(n.$thumbnails):i.insertBefore(n.$thumbnails.find(".sp-thumbnail").eq(e))});for(var t=this.thumbnails.length-1;0<=t;t--)0===this.$thumbnails.find('.sp-thumbnail[data-index="'+t+'"]').length&&(this.thumbnails[t].destroy(),this.thumbnails.splice(t,1));this.$thumbnails.find(".sp-thumbnail").each(function(t){var i=r(this);void 0===i.attr("data-init")?n._createThumbnail(i,t):n.thumbnails[t].setIndex(t)}),this.$thumbnailsContainer.removeClass("sp-top-thumbnails sp-bottom-thumbnails sp-left-thumbnails sp-right-thumbnails"),"top"===this.settings.thumbnailsPosition?(this.$thumbnailsContainer.addClass("sp-top-thumbnails"),this.thumbnailsOrientation="horizontal"):"bottom"===this.settings.thumbnailsPosition?(this.$thumbnailsContainer.addClass("sp-bottom-thumbnails"),this.thumbnailsOrientation="horizontal"):"left"===this.settings.thumbnailsPosition?(this.$thumbnailsContainer.addClass("sp-left-thumbnails"),this.thumbnailsOrientation="vertical"):"right"===this.settings.thumbnailsPosition&&(this.$thumbnailsContainer.addClass("sp-right-thumbnails"),this.thumbnailsOrientation="vertical"),!0===this.settings.thumbnailPointer?this.$thumbnailsContainer.addClass("sp-has-pointer"):this.$thumbnailsContainer.removeClass("sp-has-pointer"),this.selectedThumbnailIndex=this.selectedSlideIndex,this.$thumbnails.find(".sp-thumbnail-container").eq(this.selectedThumbnailIndex).addClass("sp-selected-thumbnail"),this.thumbnailsSize=0,r.each(this.thumbnails,function(t,i){i.setSize(n.settings.thumbnailWidth,n.settings.thumbnailHeight),n.thumbnailsSize+="horizontal"===n.thumbnailsOrientation?i.getSize().width:i.getSize().height}),"horizontal"===this.thumbnailsOrientation?(this.$thumbnails.css({width:this.thumbnailsSize,height:this.settings.thumbnailHeight}),this.$thumbnailsContainer.css("height",""),this.thumbnailsPositionProperty="left"):(this.$thumbnails.css({width:this.settings.thumbnailWidth,height:this.thumbnailsSize}),this.$thumbnailsContainer.css("width",""),this.thumbnailsPositionProperty="top"),this.trigger({type:"thumbnailsUpdate"}),r.isFunction(this.settings.thumbnailsUpdate)&&this.settings.thumbnailsUpdate.call(this,{type:"thumbnailsUpdate"})}else this.isThumbnailScroller=!1},_createThumbnail:function(t,i){var e=this,t=new n(t,this.$thumbnails,i);t.on("thumbnailClick."+s,function(t){e.gotoSlide(t.index)}),this.thumbnails.splice(i,0,t)},_thumbnailsOnResize:function(){var t;!1!==this.isThumbnailScroller&&("horizontal"===this.thumbnailsOrientation?(this.thumbnailsContainerSize=Math.min(this.$slidesMask.width(),this.thumbnailsSize),this.$thumbnailsContainer.css("width",this.thumbnailsContainerSize),"fullWindow"===this.settings.forceSize&&(this.$slidesMask.css("height",this.$slidesMask.height()-this.$thumbnailsContainer.outerHeight(!0)),this.slideHeight=this.$slidesMask.height(),this._resizeSlides(),this._resetSlidesPosition())):"vertical"===this.thumbnailsOrientation&&(this.$slidesMask.width()+this.$thumbnailsContainer.outerWidth(!0)>this.$slider.parent().width()&&("fullWidth"===this.settings.forceSize||"fullWindow"===this.settings.forceSize?this.$slider.css("max-width",r(e).width()-this.$thumbnailsContainer.outerWidth(!0)):this.$slider.css("max-width",this.$slider.parent().width()-this.$thumbnailsContainer.outerWidth(!0)),this.$slidesMask.css("width",this.$slider.width()),"vertical"===this.settings.orientation&&(this.slideWidth=this.$slider.width(),this._resizeSlides()),this._resetSlidesPosition()),this.thumbnailsContainerSize=Math.min(this.$slidesMask.height(),this.thumbnailsSize),this.$thumbnailsContainer.css("height",this.thumbnailsContainerSize)),t=this.thumbnailsSize<=this.thumbnailsContainerSize||0===this.$thumbnails.find(".sp-selected-thumbnail").length?0:Math.max(-this.thumbnails[this.selectedThumbnailIndex].getPosition()[this.thumbnailsPositionProperty],this.thumbnailsContainerSize-this.thumbnailsSize),"top"===this.settings.thumbnailsPosition?this.$slider.css({paddingTop:this.$thumbnailsContainer.outerHeight(!0),paddingLeft:"",paddingRight:""}):"bottom"===this.settings.thumbnailsPosition?this.$slider.css({paddingTop:"",paddingLeft:"",paddingRight:""}):"left"===this.settings.thumbnailsPosition?this.$slider.css({paddingTop:"",paddingLeft:this.$thumbnailsContainer.outerWidth(!0),paddingRight:""}):"right"===this.settings.thumbnailsPosition&&this.$slider.css({paddingTop:"",paddingLeft:"",paddingRight:this.$thumbnailsContainer.outerWidth(!0)}),this._moveThumbnailsTo(t,!0))},_gotoThumbnail:function(t){var i,e,s,n;!1!==this.isThumbnailScroller&&void 0!==this.thumbnails[t]&&(n=this.selectedThumbnailIndex,i=this.thumbnailsPosition,this.selectedThumbnailIndex=t,this.$thumbnails.find(".sp-selected-thumbnail").removeClass("sp-selected-thumbnail"),this.$thumbnails.find(".sp-thumbnail-container").eq(this.selectedThumbnailIndex).addClass("sp-selected-thumbnail"),!0===this.settings.rightToLeft&&"horizontal"===this.thumbnailsOrientation?this.selectedThumbnailIndex>=n?(t=this.selectedThumbnailIndex===this.thumbnails.length-1?this.selectedThumbnailIndex:this.selectedThumbnailIndex+1,(t=this.thumbnails[t]).getPosition().left<-this.thumbnailsPosition&&(i=-t.getPosition().left)):this.selectedThumbnailIndex<n&&(s=0===this.selectedThumbnailIndex?this.selectedThumbnailIndex:this.selectedThumbnailIndex-1,e=this.thumbnails[s],s=-this.thumbnailsPosition+this.thumbnailsContainerSize,e.getPosition().right>s&&(i=this.thumbnailsPosition-(e.getPosition().right-s))):this.selectedThumbnailIndex>=n?(e=this.selectedThumbnailIndex===this.thumbnails.length-1?this.selectedThumbnailIndex:this.selectedThumbnailIndex+1,s=this.thumbnails[e],e="horizontal"===this.thumbnailsOrientation?s.getPosition().right:s.getPosition().bottom,(s=-this.thumbnailsPosition+this.thumbnailsContainerSize)<e&&(i=this.thumbnailsPosition-(e-s))):this.selectedThumbnailIndex<n&&(n=0===this.selectedThumbnailIndex?this.selectedThumbnailIndex:this.selectedThumbnailIndex-1,n=this.thumbnails[n],(n="horizontal"===this.thumbnailsOrientation?n.getPosition().left:n.getPosition().top)<-this.thumbnailsPosition&&(i=-n)),this._moveThumbnailsTo(i),this.trigger({type:"gotoThumbnail"}),r.isFunction(this.settings.gotoThumbnail)&&this.settings.gotoThumbnail.call(this,{type:"gotoThumbnail"}))},_moveThumbnailsTo:function(t,i,e){var s,n,o,a=this,h={};t!==this.thumbnailsPosition&&(this.thumbnailsPosition=t,"css-3d"===this.supportedAnimation||"css-2d"===this.supportedAnimation?(n="horizontal"===this.thumbnailsOrientation?t:0,o="horizontal"===this.thumbnailsOrientation?0:t,"css-3d"===this.supportedAnimation?h[this.vendorPrefix+"transform"]="translate3d("+n+"px, "+o+"px, 0)":h[this.vendorPrefix+"transform"]="translate("+n+"px, "+o+"px)",void 0!==i&&!0===i?s="":(this.$thumbnails.addClass("sp-animated"),s=this.vendorPrefix+"transform 0.7s",this.$thumbnails.on(this.transitionEvent,function(t){t.target===t.currentTarget&&(a.$thumbnails.off(a.transitionEvent),a.$thumbnails.removeClass("sp-animated"),"function"==typeof e&&e(),a.trigger({type:"thumbnailsMoveComplete"}),r.isFunction(a.settings.thumbnailsMoveComplete)&&a.settings.thumbnailsMoveComplete.call(a,{type:"thumbnailsMoveComplete"}))})),h[this.vendorPrefix+"transition"]=s,this.$thumbnails.css(h)):(h["margin-"+this.thumbnailsPositionProperty]=t,void 0!==i&&!0===i?this.$thumbnails.css(h):this.$thumbnails.addClass("sp-animated").animate(h,700,function(){a.$thumbnails.removeClass("sp-animated"),"function"==typeof e&&e(),a.trigger({type:"thumbnailsMoveComplete"}),r.isFunction(a.settings.thumbnailsMoveComplete)&&a.settings.thumbnailsMoveComplete.call(a,{type:"thumbnailsMoveComplete"})})))},_stopThumbnailsMovement:function(){var t,i,e,s={};"css-3d"===this.supportedAnimation||"css-2d"===this.supportedAnimation?(e=-1!==(i=this.$thumbnails.css(this.vendorPrefix+"transform")).indexOf("matrix3d")?"matrix3d":"matrix",t=i.replace(e,"").match(/-?[0-9\.]+/g),i="matrix3d"==e?parseInt(t[12],10):parseInt(t[4],10),e="matrix3d"==e?parseInt(t[13],10):parseInt(t[5],10),"css-3d"===this.supportedAnimation?s[this.vendorPrefix+"transform"]="translate3d("+i+"px, "+e+"px, 0)":s[this.vendorPrefix+"transform"]="translate("+i+"px, "+e+"px)",s[this.vendorPrefix+"transition"]="",this.$thumbnails.css(s),this.$thumbnails.off(this.transitionEvent),this.thumbnailsPosition="horizontal"===this.thumbnailsOrientation?parseInt(t[4],10):parseInt(t[5],10)):(this.$thumbnails.stop(),this.thumbnailsPosition=parseInt(this.$thumbnails.css("margin-"+this.thumbnailsPositionProperty),10)),this.$thumbnails.removeClass("sp-animated")},destroyThumbnails:function(){var i=this;this.off("update."+s),!1!==this.isThumbnailScroller&&(this.off("sliderResize."+s),this.off("gotoSlide."+s),r(e).off("resize."+this.uniqueId+"."+s),this.$thumbnails.find(".sp-thumbnail").each(function(){var t=r(this),t=parseInt(t.attr("data-index"),10),t=i.thumbnails[t];t.off("thumbnailClick."+s),t.destroy()}),this.thumbnails.length=0,this.$thumbnails.appendTo(this.$slider),this.$thumbnailsContainer.remove(),this.$slider.css({paddingTop:"",paddingLeft:"",paddingRight:""}))},thumbnailsDefaults:{thumbnailWidth:100,thumbnailHeight:80,thumbnailsPosition:"bottom",thumbnailPointer:!1,thumbnailsUpdate:function(){},gotoThumbnail:function(){},thumbnailsMoveComplete:function(){}}},n=function(t,i,e){this.$thumbnail=t,this.$thumbnails=i,this.$thumbnailContainer=null,this.width=0,this.height=0,this.isImageLoaded=!1,this.setIndex(e),this._init()};n.prototype={_init:function(){var t=this;this.$thumbnail.attr("data-init",!0),this.$thumbnailContainer=r('<div class="sp-thumbnail-container"></div>').appendTo(this.$thumbnails),(0!==this.$thumbnail.parent("a").length?this.$thumbnail.parent("a"):this.$thumbnail).appendTo(this.$thumbnailContainer),this.$thumbnailContainer.on("click."+s,function(){t.trigger({type:"thumbnailClick."+s,index:t.index})})},setSize:function(t,i){this.width=t,this.height=i,this.$thumbnailContainer.css({width:this.width,height:this.height}),this.$thumbnail.is("img")&&void 0===this.$thumbnail.attr("data-src")&&this.resizeImage()},getSize:function(){return{width:this.$thumbnailContainer.outerWidth(!0),height:this.$thumbnailContainer.outerHeight(!0)}},getPosition:function(){return{left:this.$thumbnailContainer.position().left+parseInt(this.$thumbnailContainer.css("marginLeft"),10),right:this.$thumbnailContainer.position().left+parseInt(this.$thumbnailContainer.css("marginLeft"),10)+this.$thumbnailContainer.outerWidth(),top:this.$thumbnailContainer.position().top+parseInt(this.$thumbnailContainer.css("marginTop"),10),bottom:this.$thumbnailContainer.position().top+parseInt(this.$thumbnailContainer.css("marginTop"),10)+this.$thumbnailContainer.outerHeight()}},setIndex:function(t){this.index=t,this.$thumbnail.attr("data-index",this.index)},resizeImage:function(){var t=this;!1!==this.isImageLoaded?(this.$thumbnail=this.$thumbnailContainer.find(".sp-thumbnail"),this.$thumbnail.width()/this.$thumbnail.height()<=this.width/this.height?this.$thumbnail.css({width:"100%",height:"auto"}):this.$thumbnail.css({width:"auto",height:"100%"}),this.$thumbnail.css({marginLeft:.5*(this.$thumbnailContainer.width()-this.$thumbnail.width()),marginTop:.5*(this.$thumbnailContainer.height()-this.$thumbnail.height())})):SliderProUtils.checkImagesComplete(this.$thumbnailContainer,function(){t.isImageLoaded=!0,t.resizeImage()})},destroy:function(){this.$thumbnailContainer.off("click."+s),this.$thumbnail.removeAttr("data-init"),this.$thumbnail.removeAttr("data-index"),(0!==this.$thumbnail.parent("a").length?this.$thumbnail.parent("a"):this.$thumbnail).insertBefore(this.$thumbnailContainer),this.$thumbnailContainer.remove()},on:function(t,i){return this.$thumbnailContainer.on(t,i)},off:function(t){return this.$thumbnailContainer.off(t)},trigger:function(t){return this.$thumbnailContainer.triggerHandler(t)}},r.SliderPro.addModule("Thumbnails",t)}(window,jQuery),function(n){"use strict";var t="ConditionalImages."+n.SliderPro.namespace,i={previousImageSize:null,currentImageSize:null,isRetinaScreen:!1,initConditionalImages:function(){this.currentImageSize=this.previousImageSize="default",this.isRetinaScreen=void 0!==this._isRetina&&!0===this._isRetina(),this.on("update."+t,n.proxy(this._conditionalImagesOnUpdate,this)),this.on("sliderResize."+t,n.proxy(this._conditionalImagesOnResize,this))},_conditionalImagesOnUpdate:function(){n.each(this.slides,function(t,i){i.$slide.find("img:not([ data-default ])").each(function(){var t=n(this);void 0!==t.attr("data-src")?t.attr("data-default",t.attr("data-src")):t.attr("data-default",t.attr("src"))})})},_conditionalImagesOnResize:function(){var s;this.slideWidth<=this.settings.smallSize?this.currentImageSize="small":this.slideWidth<=this.settings.mediumSize?this.currentImageSize="medium":this.slideWidth<=this.settings.largeSize?this.currentImageSize="large":this.currentImageSize="default",this.previousImageSize!==this.currentImageSize&&(n.each((s=this).slides,function(t,e){e.$slide.find("img").each(function(){var t=n(this),i="";!0===s.isRetinaScreen&&void 0!==t.attr("data-retina"+s.currentImageSize)?(i=t.attr("data-retina"+s.currentImageSize),void 0!==t.attr("data-retina")&&t.attr("data-retina")!==i&&t.attr("data-retina",i)):(!1===s.isRetinaScreen||!0===s.isRetinaScreen&&void 0===t.attr("data-retina"))&&void 0!==t.attr("data-"+s.currentImageSize)&&(i=t.attr("data-"+s.currentImageSize),void 0!==t.attr("data-src")&&t.attr("data-src")!==i&&t.attr("data-src",i)),""!==i&&void 0===t.attr("data-src")&&t.attr("src")!==i&&s._loadConditionalImage(t,i,function(t){t.hasClass("sp-image")&&(e.$mainImage=t,e.resizeMainImage(!0))})})}),this.previousImageSize=this.currentImageSize)},_loadConditionalImage:function(t,i,e){var s=n(new Image);s.attr("class",t.attr("class")),s.attr("style",t.attr("style")),n.each(t.data(),function(t,i){s.attr("data-"+t,i)}),void 0!==t.attr("width")&&s.attr("width",t.attr("width")),void 0!==t.attr("height")&&s.attr("height",t.attr("height")),void 0!==t.attr("alt")&&s.attr("alt",t.attr("alt")),void 0!==t.attr("title")&&s.attr("title",t.attr("title")),s.attr("src",i),s.insertAfter(t),t.remove(),t=null,"function"==typeof e&&e(s)},destroyConditionalImages:function(){this.off("update."+t),this.off("sliderResize."+t)},conditionalImagesDefaults:{smallSize:480,mediumSize:768,largeSize:1024}};n.SliderPro.addModule("ConditionalImages",i)}((window,jQuery)),function(t,o){"use strict";var i="Retina."+o.SliderPro.namespace,e={initRetina:function(){!1!==this._isRetina()&&(this.on("sliderResize."+i,o.proxy(this._checkRetinaImages,this)),0!==this.$slider.find(".sp-thumbnail").length&&this.on("update.Thumbnails."+i,o.proxy(this._checkRetinaThumbnailImages,this)))},_isRetina:function(){return 2<=t.devicePixelRatio||!(!t.matchMedia||!t.matchMedia("(-webkit-min-device-pixel-ratio: 2),(min-resolution: 2dppx)").matches)},_checkRetinaImages:function(){var s=this;o.each(this.slides,function(t,i){var e=i.$slide;void 0===e.attr("data-retina-loaded")&&(e.attr("data-retina-loaded",!0),e.find("img[data-retina]").each(function(){var t=o(this);void 0!==t.attr("data-src")?t.attr("data-src",t.attr("data-retina")):s._loadRetinaImage(t,function(t){t.hasClass("sp-image")&&(i.$mainImage=t,i.resizeMainImage(!0))})}))})},_checkRetinaThumbnailImages:function(){var s=this;o.each(this.thumbnails,function(t,i){var e=i.$thumbnailContainer;void 0===e.attr("data-retina-loaded")&&(e.attr("data-retina-loaded",!0),e.find("img[data-retina]").each(function(){var t=o(this);void 0!==t.attr("data-src")?t.attr("data-src",t.attr("data-retina")):s._loadRetinaImage(t,function(t){t.hasClass("sp-thumbnail")&&i.resizeImage()})}))})},_loadRetinaImage:function(t,i){var e,s=!1,n="";void 0!==t.attr("data-retina")&&(s=!0,n=t.attr("data-retina")),void 0!==t.attr("data-src")&&(!1===s&&(n=t.attr("data-src")),t.removeAttr("data-src")),""!==n&&((e=o(new Image)).attr("class",t.attr("class")),e.attr("style",t.attr("style")),o.each(t.data(),function(t,i){e.attr("data-"+t,i)}),void 0!==t.attr("width")&&e.attr("width",t.attr("width")),void 0!==t.attr("height")&&e.attr("height",t.attr("height")),void 0!==t.attr("alt")&&e.attr("alt",t.attr("alt")),void 0!==t.attr("title")&&e.attr("title",t.attr("title")),e.insertAfter(t),t.remove(),t=null,e.attr("src",n),"function"==typeof i&&i(e))},destroyRetina:function(){this.off("update."+i),this.off("update.Thumbnails."+i)}};o.SliderPro.addModule("Retina",e)}(window,jQuery),function(n){"use strict";var t="LazyLoading."+n.SliderPro.namespace,i={allowLazyLoadingCheck:!0,initLazyLoading:function(){this.on("sliderResize."+t,n.proxy(this._lazyLoadingOnResize,this)),this.on("gotoSlide."+t,n.proxy(this._checkAndLoadVisibleImages,this)),this.on("thumbnailsUpdate."+t+" thumbnailsMoveComplete."+t,n.proxy(this._checkAndLoadVisibleThumbnailImages,this))},_lazyLoadingOnResize:function(){var t=this;!1!==this.allowLazyLoadingCheck&&(this.allowLazyLoadingCheck=!1,this._checkAndLoadVisibleImages(),0!==this.$slider.find(".sp-thumbnail").length&&this._checkAndLoadVisibleThumbnailImages(),setTimeout(function(){t.allowLazyLoadingCheck=!0},500))},_checkAndLoadVisibleImages:function(){var s,t,i,e;0!==this.$slider.find(".sp-slide:not([ data-loaded ])").length&&(t=!0===(s=this).settings.loop?this.middleSlidePosition:this.selectedSlideIndex,e=Math.ceil((parseInt(this.$slidesMask.css(this.sizeProperty),10)-this.averageSlideSize)/2/this.averageSlideSize),i=!0===this.settings.centerSelectedSlide?Math.max(t-e-1,0):Math.max(t-1,0),e=!0===this.settings.centerSelectedSlide?Math.min(t+e+1,this.getTotalSlides()-1):Math.min(t+2*e+1,this.getTotalSlides()-1),e=this.slidesOrder.slice(i,e+1),n.each(e,function(t,i){var e=s.slides[i],i=e.$slide;void 0===i.attr("data-loaded")&&(i.attr("data-loaded",!0),i.find("img[ data-src ]").each(function(){var t=n(this);s._loadImage(t,function(t){t.hasClass("sp-image")&&(e.$mainImage=t,e.resizeMainImage(!0))})}))}))},_checkAndLoadVisibleThumbnailImages:function(){var s,t,i;0!==this.$slider.find(".sp-thumbnail-container:not([ data-loaded ])").length&&(i=(s=this).thumbnailsSize/this.thumbnails.length,t=Math.floor(Math.abs(this.thumbnailsPosition/i)),i=Math.floor((-this.thumbnailsPosition+this.thumbnailsContainerSize)/i),i=this.thumbnails.slice(t,i+1),n.each(i,function(t,i){var e=i.$thumbnailContainer;void 0===e.attr("data-loaded")&&(e.attr("data-loaded",!0),e.find("img[ data-src ]").each(function(){var t=n(this);s._loadImage(t,function(){i.resizeImage()})}))}))},_loadImage:function(t,i){var e=n(new Image);e.attr("class",t.attr("class")),e.attr("style",t.attr("style")),n.each(t.data(),function(t,i){e.attr("data-"+t,i)}),void 0!==t.attr("width")&&e.attr("width",t.attr("width")),void 0!==t.attr("height")&&e.attr("height",t.attr("height")),void 0!==t.attr("alt")&&e.attr("alt",t.attr("alt")),void 0!==t.attr("title")&&e.attr("title",t.attr("title")),e.attr("src",t.attr("data-src")),e.removeAttr("data-src"),e.insertAfter(t),t.remove(),t=null,"function"==typeof i&&i(e)},destroyLazyLoading:function(){this.off("update."+t),this.off("gotoSlide."+t),this.off("sliderResize."+t),this.off("thumbnailsUpdate."+t),this.off("thumbnailsMoveComplete."+t)}};n.SliderPro.addModule("LazyLoading",i)}((window,jQuery)),function(t,h){"use strict";var s="Layers."+h.SliderPro.namespace,i={layersGotoSlideReference:null,waitForLayersTimer:null,initLayers:function(){this.on("update."+s,h.proxy(this._layersOnUpdate,this)),this.on("sliderResize."+s,h.proxy(this._layersOnResize,this)),this.on("gotoSlide."+s,h.proxy(this._layersOnGotoSlide,this))},_layersOnUpdate:function(t){var i=this;h.each(this.slides,function(t,i){i.$slide;this.$slide.find(".sp-layer:not([ data-layer-init ])").each(function(){var t=new n(h(this));void 0===i.layers&&(i.layers=[]),i.layers.push(t),!1===h(this).hasClass("sp-static")&&(void 0===i.animatedLayers&&(i.animatedLayers=[]),i.animatedLayers.push(t))})}),!0===this.settings.waitForLayers&&(clearTimeout(this.waitForLayersTimer),this.waitForLayersTimer=setTimeout(function(){i.layersGotoSlideReference=i.gotoSlide,i.gotoSlide=i._layersGotoSlide},1)),setTimeout(function(){i.showLayers(i.selectedSlideIndex)},1)},_layersOnResize:function(){var t,e,i=this.settings.autoScaleLayers;!1!==this.settings.autoScaleLayers&&(-1===this.settings.autoScaleReference?"string"==typeof this.settings.width&&-1!==this.settings.width.indexOf("%")?i=!1:t=parseInt(this.settings.width,10):t=this.settings.autoScaleReference,e=!0===i&&this.slideWidth<t?this.slideWidth/t:1,h.each(this.slides,function(t,i){void 0!==i.layers&&h.each(i.layers,function(t,i){i.scale(e)})}))},_layersGotoSlide:function(t){var i=this,e=this.slides[this.selectedSlideIndex].animatedLayers;this.$slider.hasClass("sp-swiping")||void 0===e||0===e.length?this.layersGotoSlideReference(t):(this.on("hideLayersComplete."+s,function(){i.off("hideLayersComplete."+s),i.layersGotoSlideReference(t)}),this.hideLayers(this.selectedSlideIndex))},_layersOnGotoSlide:function(t){this.previousSlideIndex!==this.selectedSlideIndex&&this.hideLayers(this.previousSlideIndex),this.showLayers(this.selectedSlideIndex)},showLayers:function(t){var e=this,s=this.slides[t].animatedLayers,n=0;void 0!==s&&h.each(s,function(t,i){!0===i.isVisible()?++n===s.length&&(e.trigger({type:"showLayersComplete",index:t}),h.isFunction(e.settings.showLayersComplete)&&e.settings.showLayersComplete.call(e,{type:"showLayersComplete",index:t})):i.show(function(){++n===s.length&&(e.trigger({type:"showLayersComplete",index:t}),h.isFunction(e.settings.showLayersComplete)&&e.settings.showLayersComplete.call(e,{type:"showLayersComplete",index:t}))})})},hideLayers:function(t){var e=this,s=this.slides[t].animatedLayers,n=0;void 0!==s&&h.each(s,function(t,i){!1===i.isVisible()?++n===s.length&&(e.trigger({type:"hideLayersComplete",index:t}),h.isFunction(e.settings.hideLayersComplete)&&e.settings.hideLayersComplete.call(e,{type:"hideLayersComplete",index:t})):i.hide(function(){++n===s.length&&(e.trigger({type:"hideLayersComplete",index:t}),h.isFunction(e.settings.hideLayersComplete)&&e.settings.hideLayersComplete.call(e,{type:"hideLayersComplete",index:t}))})})},destroyLayers:function(){this.off("update."+s),this.off("sliderResize."+s),this.off("gotoSlide."+s),this.off("hideLayersComplete."+s)},layersDefaults:{waitForLayers:!1,autoScaleLayers:!0,autoScaleReference:-1,showLayersComplete:function(){},hideLayersComplete:function(){}}},e=t.SliderProSlide.prototype.destroy;t.SliderProSlide.prototype.destroy=function(){void 0!==this.layers&&(h.each(this.layers,function(t,i){i.destroy()}),this.layers.length=0),void 0!==this.animatedLayers&&(this.animatedLayers.length=0),e.apply(this)};var n=function(t){this.$layer=t,this.visible=!1,this.styled=!1,this.data=null,this.position=null,this.horizontalProperty=null,this.verticalProperty=null,this.horizontalPosition=null,this.verticalPosition=null,this.scaleRatio=1,this.supportedAnimation=SliderProUtils.getSupportedAnimation(),this.vendorPrefix=SliderProUtils.getVendorPrefix(),this.transitionEvent=SliderProUtils.getTransitionEvent(),this.delayTimer=null,this.stayTimer=null,this._init()};n.prototype={_init:function(){this.$layer.attr("data-layer-init",!0),this.$layer.hasClass("sp-static")?this._setStyle():this.$layer.css({visibility:"hidden"})},_setStyle:function(){this.styled=!0,this.data=this.$layer.data(),void 0!==this.data.width&&this.$layer.css("width",this.data.width),void 0!==this.data.height&&this.$layer.css("height",this.data.height),void 0!==this.data.depth&&this.$layer.css("z-index",this.data.depth),this.position=this.data.position?this.data.position.toLowerCase():"topleft",-1!==this.position.indexOf("right")?this.horizontalProperty="right":-1!==this.position.indexOf("left")?this.horizontalProperty="left":this.horizontalProperty="center",-1!==this.position.indexOf("bottom")?this.verticalProperty="bottom":-1!==this.position.indexOf("top")?this.verticalProperty="top":this.verticalProperty="center",this._setPosition(),this.scale(this.scaleRatio)},_setPosition:function(){var t=this.$layer.attr("style");this.horizontalPosition=void 0!==this.data.horizontal?this.data.horizontal:0,this.verticalPosition=void 0!==this.data.vertical?this.data.vertical:0,"center"===this.horizontalProperty?(!1===this.$layer.is("img")&&(void 0===t||void 0!==t&&-1===t.indexOf("width"))&&(this.$layer.css("white-space","nowrap"),this.$layer.css("width",this.$layer.outerWidth(!0))),this.$layer.css({marginLeft:"auto",marginRight:"auto",left:this.horizontalPosition,right:0})):this.$layer.css(this.horizontalProperty,this.horizontalPosition),"center"===this.verticalProperty?(!1===this.$layer.is("img")&&(void 0===t||void 0!==t&&-1===t.indexOf("height"))&&(this.$layer.css("white-space","nowrap"),this.$layer.css("height",this.$layer.outerHeight(!0))),this.$layer.css({marginTop:"auto",marginBottom:"auto",top:this.verticalPosition,bottom:0})):this.$layer.css(this.verticalProperty,this.verticalPosition)},scale:function(t){var i,e;this.$layer.hasClass("sp-no-scale")||(this.scaleRatio=t,!1!==this.styled&&(i="center"===this.horizontalProperty?"left":this.horizontalProperty,e="center"===this.verticalProperty?"top":this.verticalProperty,(t={})[this.vendorPrefix+"transform-origin"]=this.horizontalProperty+" "+this.verticalProperty,t[this.vendorPrefix+"transform"]="scale("+this.scaleRatio+")","string"!=typeof this.horizontalPosition&&(t[i]=this.horizontalPosition*this.scaleRatio),"string"!=typeof this.verticalPosition&&(t[e]=this.verticalPosition*this.scaleRatio),"string"==typeof this.data.width&&-1!==this.data.width.indexOf("%")&&(t.width=(parseInt(this.data.width,10)/this.scaleRatio).toString()+"%"),"string"==typeof this.data.height&&-1!==this.data.height.indexOf("%")&&(t.height=(parseInt(this.data.height,10)/this.scaleRatio).toString()+"%"),this.$layer.css(t)))},show:function(i){var e,t,s,n,o,a,h,r;!0!==this.visible&&(!(this.visible=!0)===this.styled&&this._setStyle(),t=void 0!==(e=this).data.showOffset?this.data.showOffset:50,s=void 0!==this.data.showDuration?this.data.showDuration/1e3:.4,n=void 0!==this.data.showDelay?this.data.showDelay:10,o=void 0!==e.data.stayDuration?parseInt(e.data.stayDuration,10):-1,"javascript"===this.supportedAnimation?this.$layer.stop().delay(n).css({opacity:0,visibility:"visible"}).animate({opacity:1},1e3*s,function(){-1!==o&&(e.stayTimer=setTimeout(function(){e.hide(),e.stayTimer=null},o)),void 0!==i&&i()}):(h={opacity:1},r="",(a={opacity:0,visibility:"visible"})[this.vendorPrefix+"transform"]="scale("+this.scaleRatio+")",h[this.vendorPrefix+"transform"]="scale("+this.scaleRatio+")",h[this.vendorPrefix+"transition"]="opacity "+s+"s",void 0!==this.data.showTransition&&("left"===this.data.showTransition?r=t+"px, 0":"right"===this.data.showTransition?r="-"+t+"px, 0":"up"===this.data.showTransition?r="0, "+t+"px":"down"===this.data.showTransition&&(r="0, -"+t+"px"),a[this.vendorPrefix+"transform"]+="css-3d"===this.supportedAnimation?" translate3d("+r+", 0)":" translate("+r+")",h[this.vendorPrefix+"transform"]+="css-3d"===this.supportedAnimation?" translate3d(0, 0, 0)":" translate(0, 0)",h[this.vendorPrefix+"transition"]+=", "+this.vendorPrefix+"transform "+s+"s"),this.$layer.on(this.transitionEvent,function(t){t.target===t.currentTarget&&(e.$layer.off(e.transitionEvent).css(e.vendorPrefix+"transition",""),-1!==o&&(e.stayTimer=setTimeout(function(){e.hide(),e.stayTimer=null},o)),void 0!==i&&i())}),this.$layer.css(a),this.delayTimer=setTimeout(function(){e.$layer.css(h)},n)))},hide:function(i){var e,t,s,n,o,a;!1!==this.visible&&(t=void 0!==(e=this).data.hideOffset?this.data.hideOffset:50,s=void 0!==this.data.hideDuration?this.data.hideDuration/1e3:.4,n=void 0!==this.data.hideDelay?this.data.hideDelay:10,this.visible=!1,null!==this.stayTimer&&clearTimeout(this.stayTimer),"javascript"===this.supportedAnimation?this.$layer.stop().delay(n).animate({opacity:0},1e3*s,function(){h(this).css("visibility","hidden"),void 0!==i&&i()}):(o="",(a={opacity:0})[this.vendorPrefix+"transform"]="scale("+this.scaleRatio+")",a[this.vendorPrefix+"transition"]="opacity "+s+"s",void 0!==this.data.hideTransition&&("left"===this.data.hideTransition?o="-"+t+"px, 0":"right"===this.data.hideTransition?o=t+"px, 0":"up"===this.data.hideTransition?o="0, -"+t+"px":"down"===this.data.hideTransition&&(o="0, "+t+"px"),a[this.vendorPrefix+"transform"]+="css-3d"===this.supportedAnimation?" translate3d("+o+", 0)":" translate("+o+")",a[this.vendorPrefix+"transition"]+=", "+this.vendorPrefix+"transform "+s+"s"),this.$layer.on(this.transitionEvent,function(t){t.target===t.currentTarget&&(e.$layer.off(e.transitionEvent).css(e.vendorPrefix+"transition",""),!1===e.visible&&e.$layer.css("visibility","hidden"),void 0!==i&&i())}),this.delayTimer=setTimeout(function(){e.$layer.css(a)},n)))},isVisible:function(){return!1!==this.visible&&!this.$layer.is(":hidden")},destroy:function(){this.$layer.removeAttr("style"),this.$layer.removeAttr("data-layer-init"),clearTimeout(this.delayTimer),clearTimeout(this.stayTimer),this.delayTimer=null,this.stayTimer=null}},h.SliderPro.addModule("Layers",i)}(window,jQuery),function(i){"use strict";var t="Fade."+i.SliderPro.namespace,e={fadeGotoSlideReference:null,initFade:function(){this.on("update."+t,i.proxy(this._fadeOnUpdate,this))},_fadeOnUpdate:function(){!0===this.settings.fade&&(this.fadeGotoSlideReference=this.gotoSlide,this.gotoSlide=this._fadeGotoSlide)},_fadeGotoSlide:function(t){var s,n,o,a;t!==this.selectedSlideIndex&&(this.$slider.hasClass("sp-swiping")?this.fadeGotoSlideReference(t):(a=t,i.each((s=this).slides,function(t,i){var e=i.getIndex(),i=i.$slide;e===a?(i.css({opacity:0,left:0,top:0,"z-index":20,visibility:"visible"}),n=i):e===s.selectedSlideIndex?(i.css({opacity:1,left:0,top:0,"z-index":10,visibility:"visible"}),o=i):i.css({opacity:1,visibility:"hidden","z-index":""})}),this.previousSlideIndex=this.selectedSlideIndex,this.selectedSlideIndex=t,this.$slides.find(".sp-selected").removeClass("sp-selected"),this.$slides.find(".sp-slide").eq(this.selectedSlideIndex).addClass("sp-selected"),!0===s.settings.loop&&s._updateSlidesOrder(),this._moveTo(0,!0),this._fadeSlideTo(n,1,function(){var e=!0;i.each(s.slides,function(t,i){void 0!==i.$slide.attr("data-transitioning")&&(e=!1)}),!0===e&&(i.each(s.slides,function(t,i){i.$slide.css({visibility:"",opacity:"","z-index":""})}),s._resetSlidesPosition()),s.trigger({type:"gotoSlideComplete",index:t,previousIndex:s.previousSlideIndex}),i.isFunction(s.settings.gotoSlideComplete)&&s.settings.gotoSlideComplete.call(s,{type:"gotoSlideComplete",index:t,previousIndex:s.previousSlideIndex})}),!0===this.settings.fadeOutPreviousSlide&&this._fadeSlideTo(o,0),!0===this.settings.autoHeight&&this._resizeHeight(),this.trigger({type:"gotoSlide",index:t,previousIndex:this.previousSlideIndex}),i.isFunction(this.settings.gotoSlide)&&this.settings.gotoSlide.call(this,{type:"gotoSlide",index:t,previousIndex:this.previousSlideIndex})))},_fadeSlideTo:function(i,e,s){var n=this;1===e&&i.attr("data-transitioning",!0),"css-3d"===this.supportedAnimation||"css-2d"===this.supportedAnimation?(setTimeout(function(){var t={opacity:e};t[n.vendorPrefix+"transition"]="opacity "+n.settings.fadeDuration/1e3+"s",i.css(t)},100),i.on(this.transitionEvent,function(t){t.target===t.currentTarget&&(i.off(n.transitionEvent),i.css(n.vendorPrefix+"transition",""),i.removeAttr("data-transitioning"),"function"==typeof s&&s())})):i.stop().animate({opacity:e},this.settings.fadeDuration,function(){i.removeAttr("data-transitioning"),"function"==typeof s&&s()})},destroyFade:function(){this.off("update."+t),null!==this.fadeGotoSlideReference&&(this.gotoSlide=this.fadeGotoSlideReference)},fadeDefaults:{fade:!1,fadeOutPreviousSlide:!0,fadeDuration:500}};i.SliderPro.addModule("Fade",e)}((window,jQuery)),function(n){"use strict";var t="TouchSwipe."+n.SliderPro.namespace,i={touchStartPoint:{x:0,y:0},touchEndPoint:{x:0,y:0},touchDistance:{x:0,y:0},touchStartPosition:0,isTouchMoving:!1,touchSwipeEvents:{startEvent:"",moveEvent:"",endEvent:""},allowOppositeScrolling:!0,previousStartEvent:"",initTouchSwipe:function(){var i=this;!1!==this.settings.touchSwipe&&(this.touchSwipeEvents.startEvent="touchstart."+t+" mousedown."+t,this.touchSwipeEvents.moveEvent="touchmove."+t+" mousemove."+t,this.touchSwipeEvents.endEvent="touchend."+this.uniqueId+"."+t+" mouseup."+this.uniqueId+"."+t,this.$slidesMask.on(this.touchSwipeEvents.startEvent,n.proxy(this._onTouchStart,this)),this.$slidesMask.on("dragstart."+t,function(t){t.preventDefault()}),this.$slidesMask.find("a").on("click."+t,function(t){i.$slider.hasClass("sp-swiping")&&t.preventDefault()}),this.$slidesMask.addClass("sp-grab"))},_onTouchStart:function(t){var i;"mousedown"!==t.type||"touchstart"!==this.previousStartEvent?(this.previousStartEvent=t.type,1<=n(t.target).closest(".sp-selectable").length||(i=void 0!==t.originalEvent.touches?t.originalEvent.touches[0]:t.originalEvent,this.touchStartPoint.x=i.pageX||i.clientX,this.touchStartPoint.y=i.pageY||i.clientY,this.touchStartPosition=this.slidesPosition,this.touchDistance.x=this.touchDistance.y=0,this.$slides.hasClass("sp-animated")&&(this.isTouchMoving=!0,this._stopMovement(),this.touchStartPosition=this.slidesPosition),this.$slidesMask.on(this.touchSwipeEvents.moveEvent,n.proxy(this._onTouchMove,this)),n(document).on(this.touchSwipeEvents.endEvent,n.proxy(this._onTouchEnd,this)),this.$slidesMask.removeClass("sp-grab").addClass("sp-grabbing"))):this.previousStartEvent=t.type},_onTouchMove:function(t){var i=void 0!==t.originalEvent.touches?t.originalEvent.touches[0]:t.originalEvent;!(this.isTouchMoving=!0)===this.$slider.hasClass("sp-swiping")&&this.$slider.addClass("sp-swiping"),this.touchEndPoint.x=i.pageX||i.clientX,this.touchEndPoint.y=i.pageY||i.clientY,this.touchDistance.x=this.touchEndPoint.x-this.touchStartPoint.x,this.touchDistance.y=this.touchEndPoint.y-this.touchStartPoint.y;var e="horizontal"===this.settings.orientation?this.touchDistance.x:this.touchDistance.y,i="horizontal"===this.settings.orientation?this.touchDistance.y:this.touchDistance.x;Math.abs(e)>Math.abs(i)&&(this.allowOppositeScrolling=!1),!0!==this.allowOppositeScrolling&&(t.preventDefault(),!1===this.settings.loop&&(this.slidesPosition>this.touchStartPosition&&0===this.selectedSlideIndex||this.slidesPosition<this.touchStartPosition&&this.selectedSlideIndex===this.getTotalSlides()-1)&&(e*=.2),this._moveTo(this.touchStartPosition+e,!0))},_onTouchEnd:function(t){var i,e=this,s="horizontal"===this.settings.orientation?this.touchDistance.x:this.touchDistance.y;this.$slidesMask.off(this.touchSwipeEvents.moveEvent),n(document).off(this.touchSwipeEvents.endEvent),this.allowOppositeScrolling=!0,this.$slidesMask.removeClass("sp-grabbing").addClass("sp-grab"),this.$slider.hasClass("sp-swiping")&&setTimeout(function(){e.$slider.removeClass("sp-swiping")},100),!1!==this.isTouchMoving&&(i=!(this.isTouchMoving=!1)===this.settings.centerSelectedSlide&&"auto"!==this.settings.visibleSize?Math.round((parseInt(this.$slidesMask.css(this.sizeProperty),10)-this.getSlideAt(this.selectedSlideIndex).getSize()[this.sizeProperty])/2):0,i=-parseInt(this.$slides.find(".sp-slide").eq(this.selectedSlideIndex).css(this.positionProperty),10)+i,Math.abs(s)<this.settings.touchSwipeThreshold?this._moveTo(i):(s=(!0===this.settings.rightToLeft&&"horizontal"===this.settings.orientation?-1:1)*s/(this.averageSlideSize+this.settings.slideDistance),s=parseInt(s,10)+(0<s?1:-1),s=this.slidesOrder[n.inArray(this.selectedSlideIndex,this.slidesOrder)-s],!0===this.settings.loop||void 0!==s?this.gotoSlide(s):this._moveTo(i)))},destroyTouchSwipe:function(){this.$slidesMask.off("dragstart."+t),this.$slidesMask.find("a").off("click."+t),this.$slidesMask.off(this.touchSwipeEvents.startEvent),this.$slidesMask.off(this.touchSwipeEvents.moveEvent),n(document).off(this.touchSwipeEvents.endEvent),this.$slidesMask.removeClass("sp-grab")},touchSwipeDefaults:{touchSwipe:!0,touchSwipeThreshold:50}};n.SliderPro.addModule("TouchSwipe",i)}((window,jQuery)),function(t){"use strict";var i="Caption."+t.SliderPro.namespace,e={$captionContainer:null,captionContent:"",initCaption:function(){this.on("update."+i,t.proxy(this._captionOnUpdate,this)),this.on("gotoSlide."+i,t.proxy(this._updateCaptionContent,this))},_captionOnUpdate:function(){this.$captionContainer=this.$slider.find(".sp-caption-container"),this.$slider.find(".sp-caption").length&&0===this.$captionContainer.length&&(this.$captionContainer=t('<div class="sp-caption-container"></div>').appendTo(this.$slider),this._updateCaptionContent()),this.$slides.find(".sp-caption").each(function(){t(this).css("display","none")})},_updateCaptionContent:function(){var t=this,i=this.$slider.find(".sp-slide").eq(this.selectedSlideIndex).find(".sp-caption"),e=0!==i.length?i.html():"";!0===this.settings.fadeCaption?""!==this.captionContent?(0===parseFloat(this.$captionContainer.css("opacity"),10)&&(this.$captionContainer.css(this.vendorPrefix+"transition",""),this.$captionContainer.css("opacity",1)),this._fadeCaptionTo(0,function(){""!==(t.captionContent=e)?(t.$captionContainer.html(t.captionContent),t._fadeCaptionTo(1)):t.$captionContainer.empty()})):(this.captionContent=e,this.$captionContainer.html(this.captionContent),this.$captionContainer.css("opacity",0),this._fadeCaptionTo(1)):(this.captionContent=e,this.$captionContainer.html(this.captionContent))},_fadeCaptionTo:function(i,e){var s=this;"css-3d"===this.supportedAnimation||"css-2d"===this.supportedAnimation?(setTimeout(function(){var t={opacity:i};t[s.vendorPrefix+"transition"]="opacity "+s.settings.captionFadeDuration/1e3+"s",s.$captionContainer.css(t)},1),this.$captionContainer.on(this.transitionEvent,function(t){t.target===t.currentTarget&&(s.$captionContainer.off(s.transitionEvent),s.$captionContainer.css(s.vendorPrefix+"transition",""),"function"==typeof e&&e())})):this.$captionContainer.stop().animate({opacity:i},this.settings.captionFadeDuration,function(){"function"==typeof e&&e()})},destroyCaption:function(){this.off("update."+i),this.off("gotoSlide."+i),this.$captionContainer.remove(),this.$slider.find(".sp-caption").each(function(){t(this).css("display","")})},captionDefaults:{fadeCaption:!0,captionFadeDuration:500}};t.SliderPro.addModule("Caption",e)}((window,jQuery)),function(s,t){"use strict";var i="DeepLinking."+t.SliderPro.namespace,e={initDeepLinking:function(){var e=this;this.on("init."+i,function(){e._gotoHash(s.location.hash)}),this.on("gotoSlide."+i,function(t){var i;!0===e.settings.updateHash&&(void 0===(i=e.$slider.find(".sp-slide").eq(t.index).attr("id"))&&(i=t.index),s.location.hash=e.$slider.attr("id")+"/"+i)}),t(s).on("hashchange."+this.uniqueId+"."+i,function(){e._gotoHash(s.location.hash)})},_parseHash:function(t){if(""!==t){var i=(t=t.substring(1)).split("/").pop(),t=t.slice(0,-i.toString().length-1);if(this.$slider.attr("id")===t)return{sliderID:t,slideId:i}}return!1},_gotoHash:function(t){var i=this._parseHash(t);!1!==i&&(t=i.slideId,i=parseInt(t,10),isNaN(i)?-1!==(t=this.$slider.find(".sp-slide#"+t).index())&&t!==this.selectedSlideIndex&&this.gotoSlide(t):i!==this.selectedSlideIndex&&this.gotoSlide(i))},destroyDeepLinking:function(){this.off("init."+i),this.off("gotoSlide."+i),t(s).off("hashchange."+this.uniqueId+"."+i)},deepLinkingDefaults:{updateHash:!1}};t.SliderPro.addModule("DeepLinking",e)}(window,jQuery),function(i){"use strict";var e="Autoplay."+i.SliderPro.namespace,t={autoplayTimer:null,isTimerRunning:!1,isTimerPaused:!1,initAutoplay:function(){this.on("update."+e,i.proxy(this._autoplayOnUpdate,this))},_autoplayOnUpdate:function(t){!0===this.settings.autoplay?(this.on("gotoSlide."+e,i.proxy(this._autoplayOnGotoSlide,this)),this.on("mouseenter."+e,i.proxy(this._autoplayOnMouseEnter,this)),this.on("mouseleave."+e,i.proxy(this._autoplayOnMouseLeave,this)),this.startAutoplay()):(this.off("gotoSlide."+e),this.off("mouseenter."+e),this.off("mouseleave."+e),this.stopAutoplay())},_autoplayOnGotoSlide:function(t){!0===this.isTimerRunning&&this.stopAutoplay(),!1===this.isTimerPaused&&this.startAutoplay()},_autoplayOnMouseEnter:function(t){!this.isTimerRunning||"pause"!==this.settings.autoplayOnHover&&"stop"!==this.settings.autoplayOnHover||(this.stopAutoplay(),this.isTimerPaused=!0)},_autoplayOnMouseLeave:function(t){!0===this.settings.autoplay&&!1===this.isTimerRunning&&"stop"!==this.settings.autoplayOnHover&&(this.startAutoplay(),this.isTimerPaused=!1)},startAutoplay:function(){var t=this;this.isTimerRunning=!0,this.autoplayTimer=setTimeout(function(){"normal"===t.settings.autoplayDirection?t.nextSlide():"backwards"===t.settings.autoplayDirection&&t.previousSlide()},this.settings.autoplayDelay)},stopAutoplay:function(){this.isTimerRunning=!1,this.isTimerPaused=!1,clearTimeout(this.autoplayTimer)},destroyAutoplay:function(){clearTimeout(this.autoplayTimer),this.off("update."+e),this.off("gotoSlide."+e),this.off("mouseenter."+e),this.off("mouseleave."+e)},autoplayDefaults:{autoplay:!0,autoplayDelay:5e3,autoplayDirection:"normal",autoplayOnHover:"pause"}};i.SliderPro.addModule("Autoplay",t)}((window,jQuery)),function(t){"use strict";var s="Keyboard."+t.SliderPro.namespace,i={initKeyboard:function(){var i=this,e=!1;!1!==this.settings.keyboard&&(this.$slider.on("focus."+s,function(){e=!0}),this.$slider.on("blur."+s,function(){e=!1}),t(document).on("keydown."+this.uniqueId+"."+s,function(t){!0===i.settings.keyboardOnlyOnFocus&&!1===e||(37===t.which?i.previousSlide():39===t.which?i.nextSlide():13!==t.which||0!==(t=i.$slider.find(".sp-slide").eq(i.selectedSlideIndex).find(".sp-image-container a")).length&&t[0].click())}))},destroyKeyboard:function(){this.$slider.off("focus."+s),this.$slider.off("blur."+s),t(document).off("keydown."+this.uniqueId+"."+s)},keyboardDefaults:{keyboard:!0,keyboardOnlyOnFocus:!1}};t.SliderPro.addModule("Keyboard",i)}((window,jQuery)),function(t){"use strict";var i="FullScreen."+t.SliderPro.namespace,e={isFullScreen:!1,$fullScreenButton:null,sizeBeforeFullScreen:{},initFullScreen:function(){(document.fullscreenEnabled||document.webkitFullscreenEnabled||document.mozFullScreenEnabled||document.msFullscreenEnabled)&&this.on("update."+i,t.proxy(this._fullScreenOnUpdate,this))},_fullScreenOnUpdate:function(){!0===this.settings.fullScreen&&null===this.$fullScreenButton?this._addFullScreen():!1===this.settings.fullScreen&&null!==this.$fullScreenButton&&this._removeFullScreen(),!0===this.settings.fullScreen&&(!0===this.settings.fadeFullScreen?this.$fullScreenButton.addClass("sp-fade-full-screen"):!1===this.settings.fadeFullScreen&&this.$fullScreenButton.removeClass("sp-fade-full-screen"))},_addFullScreen:function(){this.$fullScreenButton=t('<div class="sp-full-screen-button"></div>').appendTo(this.$slider),this.$fullScreenButton.on("click."+i,t.proxy(this._onFullScreenButtonClick,this)),document.addEventListener("fullscreenchange",t.proxy(this._onFullScreenChange,this)),document.addEventListener("mozfullscreenchange",t.proxy(this._onFullScreenChange,this)),document.addEventListener("webkitfullscreenchange",t.proxy(this._onFullScreenChange,this)),document.addEventListener("MSFullscreenChange",t.proxy(this._onFullScreenChange,this))},_removeFullScreen:function(){null!==this.$fullScreenButton&&(this.$fullScreenButton.off("click."+i),this.$fullScreenButton.remove(),this.$fullScreenButton=null,document.removeEventListener("fullscreenchange",this._onFullScreenChange),document.removeEventListener("mozfullscreenchange",this._onFullScreenChange),document.removeEventListener("webkitfullscreenchange",this._onFullScreenChange),document.removeEventListener("MSFullscreenChange",this._onFullScreenChange))},_onFullScreenButtonClick:function(){!1===this.isFullScreen?this.instance.requestFullScreen?this.instance.requestFullScreen():this.instance.mozRequestFullScreen?this.instance.mozRequestFullScreen():this.instance.webkitRequestFullScreen?this.instance.webkitRequestFullScreen():this.instance.msRequestFullscreen&&this.instance.msRequestFullscreen():document.exitFullScreen?document.exitFullScreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.webkitCancelFullScreen?document.webkitCancelFullScreen():document.msExitFullscreen&&document.msExitFullscreen()},_onFullScreenChange:function(){this.isFullScreen=!!(document.fullscreenElement||document.webkitFullscreenElement||document.mozFullScreenElement||document.msFullscreenElement),!0===this.isFullScreen?(this.sizeBeforeFullScreen={forceSize:this.settings.forceSize,autoHeight:this.settings.autoHeight},this.$slider.addClass("sp-full-screen"),this.settings.forceSize="fullWindow",this.settings.autoHeight=!1):(this.$slider.css("margin",""),this.$slider.removeClass("sp-full-screen"),this.settings.forceSize=this.sizeBeforeFullScreen.forceSize,this.settings.autoHeight=this.sizeBeforeFullScreen.autoHeight),this.resize()},destroyFullScreen:function(){this.off("update."+i),this._removeFullScreen()},fullScreenDefaults:{fullScreen:!1,fadeFullScreen:!0}};t.SliderPro.addModule("FullScreen",e)}((window,jQuery)),function(e){"use strict";var s="Buttons."+e.SliderPro.namespace,t={$buttons:null,initButtons:function(){this.on("update."+s,e.proxy(this._buttonsOnUpdate,this))},_buttonsOnUpdate:function(){this.$buttons=this.$slider.find(".sp-buttons"),!0===this.settings.buttons&&1<this.getTotalSlides()&&0===this.$buttons.length?this._createButtons():!0===this.settings.buttons&&this.getTotalSlides()!==this.$buttons.find(".sp-button").length&&0!==this.$buttons.length?this._adjustButtons():(!1===this.settings.buttons||this.getTotalSlides()<=1&&0!==this.$buttons.length)&&this._removeButtons()},_createButtons:function(){var i=this;this.$buttons=e('<div class="sp-buttons"></div>').appendTo(this.$slider);for(var t=0;t<this.getTotalSlides();t++)e('<div class="sp-button"></div>').appendTo(this.$buttons);this.$buttons.on("click."+s,".sp-button",function(){i.gotoSlide(e(this).index())}),this.$buttons.find(".sp-button").eq(this.selectedSlideIndex).addClass("sp-selected-button"),this.on("gotoSlide."+s,function(t){i.$buttons.find(".sp-selected-button").removeClass("sp-selected-button"),i.$buttons.find(".sp-button").eq(t.index).addClass("sp-selected-button")}),this.$slider.addClass("sp-has-buttons")},_adjustButtons:function(){this.$buttons.empty();for(var t=0;t<this.getTotalSlides();t++)e('<div class="sp-button"></div>').appendTo(this.$buttons);this.$buttons.find(".sp-selected-button").removeClass("sp-selected-button"),this.$buttons.find(".sp-button").eq(this.selectedSlideIndex).addClass("sp-selected-button")},_removeButtons:function(){this.$buttons.off("click."+s,".sp-button"),this.off("gotoSlide."+s),this.$buttons.remove(),this.$slider.removeClass("sp-has-buttons")},destroyButtons:function(){this._removeButtons(),this.off("update."+s)},buttonsDefaults:{buttons:!0}};e.SliderPro.addModule("Buttons",t)}((window,jQuery)),function(i){"use strict";var e="Arrows."+i.SliderPro.namespace,t={$arrows:null,$previousArrow:null,$nextArrow:null,initArrows:function(){this.on("update."+e,i.proxy(this._arrowsOnUpdate,this)),this.on("gotoSlide."+e,i.proxy(this._checkArrowsVisibility,this))},_arrowsOnUpdate:function(){var t=this;!0===this.settings.arrows&&null===this.$arrows?(this.$arrows=i('<div class="sp-arrows"></div>').appendTo(this.$slidesContainer),this.$previousArrow=i('<div class="sp-arrow sp-previous-arrow"></div>').appendTo(this.$arrows),this.$nextArrow=i('<div class="sp-arrow sp-next-arrow"></div>').appendTo(this.$arrows),this.$previousArrow.on("click."+e,function(){t.previousSlide()}),this.$nextArrow.on("click."+e,function(){t.nextSlide()}),this._checkArrowsVisibility()):!1===this.settings.arrows&&null!==this.$arrows&&this._removeArrows(),!0===this.settings.arrows&&(!0===this.settings.fadeArrows?this.$arrows.addClass("sp-fade-arrows"):!1===this.settings.fadeArrows&&this.$arrows.removeClass("sp-fade-arrows"))},_checkArrowsVisibility:function(){!1!==this.settings.arrows&&!0!==this.settings.loop&&(0===this.selectedSlideIndex?this.$previousArrow.css("display","none"):this.$previousArrow.css("display","block"),this.selectedSlideIndex===this.getTotalSlides()-1?this.$nextArrow.css("display","none"):this.$nextArrow.css("display","block"))},_removeArrows:function(){null!==this.$arrows&&(this.$previousArrow.off("click."+e),this.$nextArrow.off("click."+e),this.$arrows.remove(),this.$arrows=null)},destroyArrows:function(){this._removeArrows(),this.off("update."+e),this.off("gotoSlide."+e)},arrowsDefaults:{arrows:!1,fadeArrows:!0}};i.SliderPro.addModule("Arrows",t)}((window,jQuery)),function(s){"use strict";var n="ThumbnailTouchSwipe."+s.SliderPro.namespace,t={thumbnailTouchStartPoint:{x:0,y:0},thumbnailTouchEndPoint:{x:0,y:0},thumbnailTouchDistance:{x:0,y:0},thumbnailTouchStartPosition:0,isThumbnailTouchMoving:!1,isThumbnailTouchSwipe:!1,thumbnailTouchSwipeEvents:{startEvent:"",moveEvent:"",endEvent:""},thumbnailPreviousStartEvent:"",initThumbnailTouchSwipe:function(){this.on("update."+n,s.proxy(this._thumbnailTouchSwipeOnUpdate,this))},_thumbnailTouchSwipeOnUpdate:function(){!1!==this.isThumbnailScroller&&!0===this.settings.thumbnailTouchSwipe&&!1===this.isThumbnailTouchSwipe&&(this.isThumbnailTouchSwipe=!0,this.thumbnailTouchSwipeEvents.startEvent="touchstart."+n+" mousedown."+n,this.thumbnailTouchSwipeEvents.moveEvent="touchmove."+n+" mousemove."+n,this.thumbnailTouchSwipeEvents.endEvent="touchend."+this.uniqueId+"."+n+" mouseup."+this.uniqueId+"."+n,this.$thumbnails.on(this.thumbnailTouchSwipeEvents.startEvent,s.proxy(this._onThumbnailTouchStart,this)),this.$thumbnails.on("dragstart."+n,function(t){t.preventDefault()}),this.$thumbnails.addClass("sp-grab"),s.each(this.thumbnails,function(t,i){i.off("thumbnailClick")}))},_onThumbnailTouchStart:function(t){var i;"mousedown"!==t.type||"touchstart"!==this.thumbnailPreviousStartEvent?(this.thumbnailPreviousStartEvent=t.type,1<=s(t.target).closest(".sp-selectable").length||(i=void 0!==t.originalEvent.touches?t.originalEvent.touches[0]:t.originalEvent,void 0===t.originalEvent.touches&&t.preventDefault(),s(t.target).parents(".sp-thumbnail-container").find("a").one("click."+n,function(t){t.preventDefault()}),this.thumbnailTouchStartPoint.x=i.pageX||i.clientX,this.thumbnailTouchStartPoint.y=i.pageY||i.clientY,this.thumbnailTouchStartPosition=this.thumbnailsPosition,this.thumbnailTouchDistance.x=this.thumbnailTouchDistance.y=0,this.$thumbnails.hasClass("sp-animated")&&(this.isThumbnailTouchMoving=!0,this._stopThumbnailsMovement(),this.thumbnailTouchStartPosition=this.thumbnailsPosition),this.$thumbnails.on(this.thumbnailTouchSwipeEvents.moveEvent,s.proxy(this._onThumbnailTouchMove,this)),s(document).on(this.thumbnailTouchSwipeEvents.endEvent,s.proxy(this._onThumbnailTouchEnd,this)),this.$thumbnails.removeClass("sp-grab").addClass("sp-grabbing"),this.$thumbnailsContainer.addClass("sp-swiping"))):this.thumbnailPreviousStartEvent=t.type},_onThumbnailTouchMove:function(t){var i=void 0!==t.originalEvent.touches?t.originalEvent.touches[0]:t.originalEvent;this.isThumbnailTouchMoving=!0,this.thumbnailTouchEndPoint.x=i.pageX||i.clientX,this.thumbnailTouchEndPoint.y=i.pageY||i.clientY,this.thumbnailTouchDistance.x=this.thumbnailTouchEndPoint.x-this.thumbnailTouchStartPoint.x,this.thumbnailTouchDistance.y=this.thumbnailTouchEndPoint.y-this.thumbnailTouchStartPoint.y;var e,s="horizontal"===this.thumbnailsOrientation?this.thumbnailTouchDistance.x:this.thumbnailTouchDistance.y,i="horizontal"===this.thumbnailsOrientation?this.thumbnailTouchDistance.y:this.thumbnailTouchDistance.x;Math.abs(s)>Math.abs(i)&&(t.preventDefault(),0<=this.thumbnailsPosition?s=(e=-this.thumbnailTouchStartPosition)+.2*(s-e):this.thumbnailsPosition<=-this.thumbnailsSize+this.thumbnailsContainerSize&&(s=.2*(s+(e=this.thumbnailsSize-this.thumbnailsContainerSize+this.thumbnailTouchStartPosition))-e),this._moveThumbnailsTo(this.thumbnailTouchStartPosition+s,!0))},_onThumbnailTouchEnd:function(t){var i,e=this;"horizontal"===this.thumbnailsOrientation?this.thumbnailTouchDistance.x:this.thumbnailTouchDistance.y;this.$thumbnails.off(this.thumbnailTouchSwipeEvents.moveEvent),s(document).off(this.thumbnailTouchSwipeEvents.endEvent),this.$thumbnails.removeClass("sp-grabbing").addClass("sp-grab"),!1===this.isThumbnailTouchMoving||!0===this.isThumbnailTouchMoving&&Math.abs(this.thumbnailTouchDistance.x)<10&&Math.abs(this.thumbnailTouchDistance.y)<10?(i=(s(t.target).hasClass("sp-thumbnail-container")?s(t.target):s(t.target).parents(".sp-thumbnail-container")).index(),0!==s(t.target).parents("a").length?(s(t.target).parents("a").off("click."+n),this.$thumbnailsContainer.removeClass("sp-swiping")):i!==this.selectedThumbnailIndex&&-1!==i&&this.gotoSlide(i)):(this.isThumbnailTouchMoving=!1,s(t.target).parents(".sp-thumbnail").one("click",function(t){t.preventDefault()}),setTimeout(function(){e.$thumbnailsContainer.removeClass("sp-swiping")},1),0<this.thumbnailsPosition?this._moveThumbnailsTo(0):this.thumbnailsPosition<this.thumbnailsContainerSize-this.thumbnailsSize&&this._moveThumbnailsTo(this.thumbnailsContainerSize-this.thumbnailsSize),this.trigger({type:"thumbnailsMoveComplete"}),s.isFunction(this.settings.thumbnailsMoveComplete)&&this.settings.thumbnailsMoveComplete.call(this,{type:"thumbnailsMoveComplete"}))},destroyThumbnailTouchSwipe:function(){this.off("update."+n),!1!==this.isThumbnailScroller&&(this.$thumbnails.off(this.thumbnailTouchSwipeEvents.startEvent),this.$thumbnails.off(this.thumbnailTouchSwipeEvents.moveEvent),this.$thumbnails.off("dragstart."+n),s(document).off(this.thumbnailTouchSwipeEvents.endEvent),this.$thumbnails.removeClass("sp-grab"))},thumbnailTouchSwipeDefaults:{thumbnailTouchSwipe:!0}};s.SliderPro.addModule("ThumbnailTouchSwipe",t)}((window,jQuery)),function(e){"use strict";var s="ThumbnailArrows."+e.SliderPro.namespace,t={$thumbnailArrows:null,$previousThumbnailArrow:null,$nextThumbnailArrow:null,initThumbnailArrows:function(){var t=this;this.on("update."+s,e.proxy(this._thumbnailArrowsOnUpdate,this)),this.on("sliderResize."+s+" thumbnailsMoveComplete."+s,function(){!0===t.isThumbnailScroller&&!0===t.settings.thumbnailArrows&&t._checkThumbnailArrowsVisibility()})},_thumbnailArrowsOnUpdate:function(){var i=this;!1!==this.isThumbnailScroller&&(!0===this.settings.thumbnailArrows&&null===this.$thumbnailArrows?(this.$thumbnailArrows=e('<div class="sp-thumbnail-arrows"></div>').appendTo(this.$thumbnailsContainer),this.$previousThumbnailArrow=e('<div class="sp-thumbnail-arrow sp-previous-thumbnail-arrow"></div>').appendTo(this.$thumbnailArrows),this.$nextThumbnailArrow=e('<div class="sp-thumbnail-arrow sp-next-thumbnail-arrow"></div>').appendTo(this.$thumbnailArrows),this.$previousThumbnailArrow.on("click."+s,function(){var t=Math.min(0,i.thumbnailsPosition+i.thumbnailsContainerSize);i._moveThumbnailsTo(t)}),this.$nextThumbnailArrow.on("click."+s,function(){var t=Math.max(i.thumbnailsContainerSize-i.thumbnailsSize,i.thumbnailsPosition-i.thumbnailsContainerSize);i._moveThumbnailsTo(t)})):!1===this.settings.thumbnailArrows&&null!==this.$thumbnailArrows&&this._removeThumbnailArrows(),!0===this.settings.thumbnailArrows&&(!0===this.settings.fadeThumbnailArrows?this.$thumbnailArrows.addClass("sp-fade-thumbnail-arrows"):!1===this.settings.fadeThumbnailArrows&&this.$thumbnailArrows.removeClass("sp-fade-thumbnail-arrows"),this._checkThumbnailArrowsVisibility()))},_checkThumbnailArrowsVisibility:function(){0===this.thumbnailsPosition?this.$previousThumbnailArrow.css("display","none"):this.$previousThumbnailArrow.css("display","block"),this.thumbnailsPosition===this.thumbnailsContainerSize-this.thumbnailsSize?this.$nextThumbnailArrow.css("display","none"):this.$nextThumbnailArrow.css("display","block")},_removeThumbnailArrows:function(){null!==this.$thumbnailArrows&&(this.$previousThumbnailArrow.off("click."+s),this.$nextThumbnailArrow.off("click."+s),this.$thumbnailArrows.remove(),this.$thumbnailArrows=null)},destroyThumbnailArrows:function(){this._removeThumbnailArrows(),this.off("update."+s),this.off("sliderResize."+s),this.off("thumbnailsMoveComplete."+s)},thumbnailArrowsDefaults:{thumbnailArrows:!1,fadeThumbnailArrows:!0}};e.SliderPro.addModule("ThumbnailArrows",t)}((window,jQuery)),function(l){"use strict";var s="Video."+l.SliderPro.namespace,t={firstInit:!1,initVideo:function(){this.on("update."+s,l.proxy(this._videoOnUpdate,this)),this.on("gotoSlide."+s,l.proxy(this._videoOnGotoSlide,this)),this.on("gotoSlideComplete."+s,l.proxy(this._videoOnGotoSlideComplete,this))},_videoOnUpdate:function(){var i=this;this.$slider.find(".sp-video").not("a, [data-video-init]").each(function(){var t=l(this);i._initVideo(t)}),this.$slider.find("a.sp-video").not("[data-video-preinit]").each(function(){var t=l(this);i._preinitVideo(t)}),!1===this.firstInit&&(this.firstInit=!0,this._videoOnGotoSlideComplete({index:this.selectedSlideIndex,previousIndex:-1}))},_initVideo:function(i){var e=this;i.attr("data-video-init",!0).videoController(),i.on("videoPlay."+s,function(){"stopAutoplay"===e.settings.playVideoAction&&void 0!==e.stopAutoplay&&(e.stopAutoplay(),e.settings.autoplay=!1);var t={type:"videoPlay",video:i};e.trigger(t),l.isFunction(e.settings.videoPlay)&&e.settings.videoPlay.call(e,t)}),i.on("videoPause."+s,function(){"startAutoplay"===e.settings.pauseVideoAction&&void 0!==e.startAutoplay&&(e.stopAutoplay(),e.startAutoplay(),e.settings.autoplay=!0);var t={type:"videoPause",video:i};e.trigger(t),l.isFunction(e.settings.videoPause)&&e.settings.videoPause.call(e,t)}),i.on("videoEnded."+s,function(){"startAutoplay"===e.settings.endVideoAction&&void 0!==e.startAutoplay?(e.stopAutoplay(),e.startAutoplay(),e.settings.autoplay=!0):"nextSlide"===e.settings.endVideoAction?e.nextSlide():"replayVideo"===e.settings.endVideoAction&&i.videoController("replay");var t={type:"videoEnd",video:i};e.trigger(t),l.isFunction(e.settings.videoEnd)&&e.settings.videoEnd.call(e,t)})},_preinitVideo:function(h){var r=this;h.attr("data-video-preinit",!0),h.on("click."+s,function(t){var i,e,s,n,o,a;r.$slider.hasClass("sp-swiping")||(t.preventDefault(),n=h.attr("href"),o=h.children("img").attr("width")||h.children("img").width(),a=h.children("img").attr("height")||h.children("img").height(),-1!==n.indexOf("youtube")||-1!==n.indexOf("youtu.be")?i="youtube":-1!==n.indexOf("vimeo")&&(i="vimeo"),t=n.match("youtube"===i?/^.*(youtu.be\/|v\/|u\/\w\/|embed\/|watch\?v=|\&v=)([^#\&\?]*).*/:/http:\/\/(www\.)?vimeo.com\/(\d+)/),e=t[2],s="youtube"===i?"//www.youtube.com/embed/"+e+"?enablejsapi=1&wmode=opaque":"//player.vimeo.com/video/"+e,void 0!==(n=n.split("?")[1])&&(n=n.split("&"),l.each(n,function(t,i){-1===i.indexOf(e)&&(s+="&"+i)})),a=l("<iframe></iframe>").attr({src:s,width:o,height:a,class:h.attr("class"),frameborder:0,allowfullscreen:"allowfullscreen"}).insertBefore(h),r._initVideo(a),a.videoController("play"),h.css("display","none"))})},_videoOnGotoSlide:function(t){var i=this.$slides.find(".sp-slide").eq(t.previousIndex).find(".sp-video[data-video-init]");-1!==t.previousIndex&&0!==i.length&&("stopVideo"===this.settings.leaveVideoAction?i.videoController("stop"):"pauseVideo"===this.settings.leaveVideoAction?i.videoController("pause"):"removeVideo"===this.settings.leaveVideoAction&&(0!==i.siblings("a.sp-video").length?(i.siblings("a.sp-video").css("display",""),i.videoController("destroy"),i.remove()):i.videoController("stop")))},_videoOnGotoSlideComplete:function(t){var i;"playVideo"===this.settings.reachVideoAction&&t.index===this.selectedSlideIndex&&(i=this.$slides.find(".sp-slide").eq(t.index).find(".sp-video[data-video-init]"),t=this.$slides.find(".sp-slide").eq(t.index).find(".sp-video[data-video-preinit]"),0!==i.length?i.videoController("play"):0!==t.length&&t.trigger("click."+s),0===i.length&&0===t.length||"stopAutoplay"!==this.settings.playVideoAction||void 0===this.stopAutoplay||(this.stopAutoplay(),this.settings.autoplay=!1))},destroyVideo:function(){this.$slider.find(".sp-video[ data-video-preinit ]").each(function(){var t=l(this);t.removeAttr("data-video-preinit"),t.off("click."+s)}),this.$slider.find(".sp-video[ data-video-init ]").each(function(){var t=l(this);t.removeAttr("data-video-init"),t.off("Video"),t.videoController("destroy")}),this.off("update."+s),this.off("gotoSlide."+s),this.off("gotoSlideComplete."+s)},videoDefaults:{reachVideoAction:"none",leaveVideoAction:"pauseVideo",playVideoAction:"stopAutoplay",pauseVideoAction:"none",endVideoAction:"none",videoPlay:function(){},videoPause:function(){},videoEnd:function(){}}};l.SliderPro.addModule("Video",t)}((window,jQuery)),function(o){"use strict";function s(t,i){this.$video=o(t),this.options=i,this.settings={},this.player=null,this._init()}var t=!!window.navigator.userAgent.match(/(iPad|iPhone|iPod)/g);s.prototype={_init:function(){this.settings=o.extend({},this.defaults,this.options);var t,s=this,i=o.VideoController.players,n=this.$video.attr("id");for(t in i)if(void 0!==i[t]&&i[t].isType(this.$video)){this.player=new i[t](this.$video);break}null!==this.player&&o.each(["ready","start","play","pause","ended"],function(t,i){var e="video"+i.charAt(0).toUpperCase()+i.slice(1);s.player.on(i,function(){s.trigger({type:e,video:n}),o.isFunction(s.settings[e])&&s.settings[e].call(s,{type:e,video:n})})})},play:function(){!0==t&&!1===this.player.isStarted()||"playing"===this.player.getState()||this.player.play()},stop:function(){!0==t&&!1===this.player.isStarted()||"stopped"===this.player.getState()||this.player.stop()},pause:function(){!0==t&&!1===this.player.isStarted()||"paused"===this.player.getState()||this.player.pause()},replay:function(){!0==t&&!1===this.player.isStarted()||this.player.replay()},on:function(t,i){return this.$video.on(t,i)},off:function(t){return this.$video.off(t)},trigger:function(t){return this.$video.triggerHandler(t)},destroy:function(){!0===this.player.isStarted()&&this.stop(),this.player.off("ready"),this.player.off("start"),this.player.off("play"),this.player.off("pause"),this.player.off("ended"),this.$video.removeData("videoController")},defaults:{videoReady:function(){},videoStart:function(){},videoPlay:function(){},videoPause:function(){},videoEnded:function(){}}},o.VideoController={players:{},addPlayer:function(t,i){this.players[t]=i}},o.fn.videoController=function(i){var e=Array.prototype.slice.call(arguments,1);return this.each(function(){var t;void 0===o(this).data("videoController")?(t=new s(this,i),o(this).data("videoController",t)):void 0!==i&&("function"==typeof(t=o(this).data("videoController"))[i]?t[i].apply(t,e):o.error(i+" does not exist in videoController."))})};function n(t){this.$video=t,this.player=null,this.ready=!1,this.started=!1,this.state="",this.events=o({}),this._init()}var e={youtubeAPIAdded:!(n.prototype={_init:function(){},play:function(){},pause:function(){},stop:function(){},replay:function(){},isType:function(){},isReady:function(){return this.ready},isStarted:function(){return this.started},getState:function(){return this.state},on:function(t,i){return this.events.on(t,i)},off:function(t){return this.events.off(t)},trigger:function(t){return this.events.triggerHandler(t)}}),youtubeVideos:[]},i=function(t){var i;this.init=!1,void 0!==(window.YT&&window.YT.Player)?n.call(this,t):(e.youtubeVideos.push({video:t,scope:this}),!1===e.youtubeAPIAdded&&(e.youtubeAPIAdded=!0,(i=document.createElement("script")).src="//www.youtube.com/player_api",(t=document.getElementsByTagName("script")[0]).parentNode.insertBefore(i,t),window.onYouTubePlayerAPIReady=function(){o.each(e.youtubeVideos,function(t,i){n.call(i.scope,i.video)})}))};i.prototype=new n,o.VideoController.addPlayer("YoutubeVideo",i.prototype.constructor=i),i.isType=function(t){if(t.is("iframe")){t=t.attr("src");if(-1!==t.indexOf("youtube.com")||-1!==t.indexOf("youtu.be"))return!0}return!1},i.prototype._init=function(){this.init=!0,this._setup()},i.prototype._setup=function(){var i=this;this.player=new YT.Player(this.$video[0],{events:{onReady:function(){i.trigger({type:"ready"}),i.ready=!0},onStateChange:function(t){switch(t.data){case YT.PlayerState.PLAYING:!1===i.started&&(i.started=!0,i.trigger({type:"start"})),i.state="playing",i.trigger({type:"play"});break;case YT.PlayerState.PAUSED:i.state="paused",i.trigger({type:"pause"});break;case YT.PlayerState.ENDED:i.state="ended",i.trigger({type:"ended"})}}}})},i.prototype.play=function(){var t,i=this;!0===this.ready?this.player.playVideo():t=setInterval(function(){!0===i.ready&&(clearInterval(t),i.player.playVideo())},100)},i.prototype.pause=function(){!0==t?this.stop():this.player.pauseVideo()},i.prototype.stop=function(){this.player.seekTo(1),this.player.stopVideo(),this.state="stopped"},i.prototype.replay=function(){this.player.seekTo(1),this.player.playVideo()};var a={vimeoAPIAdded:!(i.prototype.on=function(t,i){var e,s=this;!0===this.init?n.prototype.on.call(this,t,i):e=setInterval(function(){!0===s.init&&(clearInterval(e),n.prototype.on.call(s,t,i))},100)}),vimeoVideos:[]},i=function(t){var i,e;this.init=!1,void 0!==window.Vimeo?n.call(this,t):(a.vimeoVideos.push({video:t,scope:this}),!1===a.vimeoAPIAdded&&(a.vimeoAPIAdded=!0,(i=document.createElement("script")).src="//player.vimeo.com/api/player.js",(t=document.getElementsByTagName("script")[0]).parentNode.insertBefore(i,t),e=setInterval(function(){void 0!==window.Vimeo&&(clearInterval(e),o.each(a.vimeoVideos,function(t,i){n.call(i.scope,i.video)}))},100)))};i.prototype=new n,o.VideoController.addPlayer("VimeoVideo",i.prototype.constructor=i),i.isType=function(t){if(t.is("iframe")&&-1!==t.attr("src").indexOf("vimeo.com"))return!0;return!1},i.prototype._init=function(){this.init=!0,this._setup()},i.prototype._setup=function(){var t=this;this.player=new Vimeo.Player(this.$video[0]),t.ready=!0,t.trigger({type:"ready"}),t.player.on("play",function(){!1===t.started&&(t.started=!0,t.trigger({type:"start"})),t.state="playing",t.trigger({type:"play"})}),t.player.on("pause",function(){t.state="paused",t.trigger({type:"pause"})}),t.player.on("ended",function(){t.state="ended",t.trigger({type:"ended"})})},i.prototype.play=function(){var t,i=this;!0===this.ready?this.player.play():t=setInterval(function(){!0===i.ready&&(clearInterval(t),i.player.play())},100)},i.prototype.pause=function(){this.player.pause()},i.prototype.stop=function(){var t=this;this.player.setCurrentTime(0).then(function(){t.player.pause(),t.state="stopped"})},i.prototype.replay=function(){var t=this;this.player.setCurrentTime(0).then(function(){t.player.play()})},i.prototype.on=function(t,i){var e,s=this;!0===this.init?n.prototype.on.call(this,t,i):e=setInterval(function(){!0===s.init&&(clearInterval(e),n.prototype.on.call(s,t,i))},100)};i=function(t){n.call(this,t)};i.prototype=new n,o.VideoController.addPlayer("HTML5Video",i.prototype.constructor=i),i.isType=function(t){return!(!t.is("video")||!1!==t.hasClass("video-js")||!1!==t.hasClass("sublime"))},i.prototype._init=function(){var t=this;this.player=this.$video[0];var i=setInterval(function(){4===t.player.readyState&&(clearInterval(i),t.ready=!0,t.trigger({type:"ready"}),t.player.addEventListener("play",function(){!1===t.started&&(t.started=!0,t.trigger({type:"start"})),t.state="playing",t.trigger({type:"play"})}),t.player.addEventListener("pause",function(){t.state="paused",t.trigger({type:"pause"})}),t.player.addEventListener("ended",function(){t.state="ended",t.trigger({type:"ended"})}))},100)},i.prototype.play=function(){var t,i=this;!0===this.ready?this.player.play():t=setInterval(function(){!0===i.ready&&(clearInterval(t),i.player.play())},100)},i.prototype.pause=function(){this.player.pause()},i.prototype.stop=function(){this.player.currentTime=0,this.player.pause(),this.state="stopped"},i.prototype.replay=function(){this.player.currentTime=0,this.player.play()};i=function(t){n.call(this,t)};i.prototype=new n,o.VideoController.addPlayer("VideoJSVideo",i.prototype.constructor=i),i.isType=function(t){return!(void 0===t.attr("data-videojs-id")&&!t.hasClass("video-js")||"undefined"==typeof videojs)},i.prototype._init=function(){var t=this,i=this.$video.hasClass("video-js")?this.$video.attr("id"):this.$video.attr("data-videojs-id");this.player=videojs(i),this.player.ready(function(){t.ready=!0,t.trigger({type:"ready"}),t.player.on("play",function(){!1===t.started&&(t.started=!0,t.trigger({type:"start"})),t.state="playing",t.trigger({type:"play"})}),t.player.on("pause",function(){t.state="paused",t.trigger({type:"pause"})}),t.player.on("ended",function(){t.state="ended",t.trigger({type:"ended"})})})},i.prototype.play=function(){this.player.play()},i.prototype.pause=function(){this.player.pause()},i.prototype.stop=function(){this.player.currentTime(0),this.player.pause(),this.state="stopped"},i.prototype.replay=function(){this.player.currentTime(0),this.player.play()};i=function(t){n.call(this,t)};i.prototype=new n,o.VideoController.addPlayer("SublimeVideo",i.prototype.constructor=i),i.isType=function(t){return!(!t.hasClass("sublime")||"undefined"==typeof sublime)},i.prototype._init=function(){var t=this;sublime.ready(function(){t.player=sublime.player(t.$video.attr("id")),t.ready=!0,t.trigger({type:"ready"}),t.player.on("play",function(){!1===t.started&&(t.started=!0,t.trigger({type:"start"})),t.state="playing",t.trigger({type:"play"})}),t.player.on("pause",function(){t.state="paused",t.trigger({type:"pause"})}),t.player.on("stop",function(){t.state="stopped",t.trigger({type:"stop"})}),t.player.on("end",function(){t.state="ended",t.trigger({type:"ended"})})})},i.prototype.play=function(){this.player.play()},i.prototype.pause=function(){this.player.pause()},i.prototype.stop=function(){this.player.stop()},i.prototype.replay=function(){this.player.stop(),this.player.play()};i=function(t){n.call(this,t)};i.prototype=new n,o.VideoController.addPlayer("JWPlayerVideo",i.prototype.constructor=i),i.isType=function(t){return!(void 0===t.attr("data-jwplayer-id")&&!t.hasClass("jwplayer")&&0===t.find("object[data*='jwplayer']").length||"undefined"==typeof jwplayer)},i.prototype._init=function(){var t,i=this;this.$video.hasClass("jwplayer")?t=this.$video.attr("id"):void 0!==this.$video.attr("data-jwplayer-id")?t=this.$video.attr("data-jwplayer-id"):0!==this.$video.find("object[data*='jwplayer']").length&&(t=this.$video.find("object").attr("id")),this.player=jwplayer(t),this.player.onReady(function(){i.ready=!0,i.trigger({type:"ready"}),i.player.onPlay(function(){!1===i.started&&(i.started=!0,i.trigger({type:"start"})),i.state="playing",i.trigger({type:"play"})}),i.player.onPause(function(){i.state="paused",i.trigger({type:"pause"})}),i.player.onComplete(function(){i.state="ended",i.trigger({type:"ended"})})})},i.prototype.play=function(){this.player.play(!0)},i.prototype.pause=function(){this.player.pause(!0)},i.prototype.stop=function(){this.player.stop(),this.state="stopped"},i.prototype.replay=function(){this.player.seek(0),this.player.play(!0)}}(jQuery);