// source --> https://www.annamonteverdi.it/digital/wp-content/plugins/wp-advanced-pdf/asset/js/ajaxsave.js?ver=1.1.5 jQuery( document ).on( 'click', '#guest_email', function(e) { e.preventDefault(); var ced_email_to = jQuery('#ced-email-to').val(); var postid = jQuery('#emailpostID').val(); $this = jQuery(this).parent().parent(); jQuery(this).parent().remove(); jQuery($this).append('processing'); jQuery.ajax({ url: postajaxsave.ajax_url, type: 'post', data: { action: 'postajax_exportandmail', ced_email_to: ced_email_to, postid: postid, }, success: function (response) { if(response.NOTSENT){ jQuery($this).find('img').remove(); jQuery($this).append('
processing

Sorry Your Email is not sent.

'); } else if(response.INVALIDEMAIL) { jQuery($this).find('img').remove(); var htmlq="
"; htmlq+= '

Please enter a valid e-mail address.

'; htmlq+=''; htmlq+="
"; jQuery($this).append(htmlq); } else if(response.SENT) { jQuery($this).html('sent

PDF is sent To Your Email Address

'); } } }); }); jQuery(function ($) { jQuery('.export-pdf').click(function(e) { e.preventDefault(); var postID = jQuery(this).attr('id'); var htmlq="
"; htmlq+=''; htmlq+=""; htmlq+="
"; jQuery('#examplePopup1').html(htmlq); jQuery('#emailpostID').val(postID); }); jQuery( document ).on( 'click', '#send_again', function(e) { $this = jQuery(this).parent().parent(); jQuery(this).parent().remove(); var htmlq="
"; htmlq+=''; htmlq+=""; htmlq+="
"; jQuery($this).append(htmlq); }); }); // source --> https://www.annamonteverdi.it/digital/wp-content/themes/agama/assets/js/min/particles.min.js?ver=1.2.8.10.1505293712 /* ----------------------------------------------- /* Author : Vincent Garreau - vincentgarreau.com /* MIT license: http://opensource.org/licenses/MIT /* Demo / Generator : vincentgarreau.com/particles.js /* GitHub : github.com/VincentGarreau/particles.js /* How to use? : Check the GitHub README /* v2.0.0 /* ----------------------------------------------- */ function hexToRgb(e){var a=/^#?([a-f\d])([a-f\d])([a-f\d])$/i;e=e.replace(a,function(e,a,t,i){return a+a+t+t+i+i});var t=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e);return t?{r:parseInt(t[1],16),g:parseInt(t[2],16),b:parseInt(t[3],16)}:null}function clamp(e,a,t){return Math.min(Math.max(e,a),t)}function isInArray(e,a){return a.indexOf(e)>-1}var pJS=function(e,a){var t=document.querySelector("#"+e+" > .particles-js-canvas-el");this.pJS={canvas:{el:t,w:t.offsetWidth,h:t.offsetHeight},particles:{number:{value:400,density:{enable:!0,value_area:800}},color:{value:"#fff"},shape:{type:"circle",stroke:{width:0,color:"#ff0000"},polygon:{nb_sides:5},image:{src:"",width:100,height:100}},opacity:{value:1,random:!1,anim:{enable:!1,speed:2,opacity_min:0,sync:!1}},size:{value:20,random:!1,anim:{enable:!1,speed:20,size_min:0,sync:!1}},line_linked:{enable:!0,distance:100,color:"#fff",opacity:1,width:1},move:{enable:!0,speed:2,direction:"none",random:!1,straight:!1,out_mode:"out",bounce:!1,attract:{enable:!1,rotateX:3e3,rotateY:3e3}},array:[]},interactivity:{detect_on:"canvas",events:{onhover:{enable:!0,mode:"grab"},onclick:{enable:!0,mode:"push"},resize:!0},modes:{grab:{distance:100,line_linked:{opacity:1}},bubble:{distance:200,size:80,duration:.4},repulse:{distance:200,duration:.4},push:{particles_nb:4},remove:{particles_nb:2}},mouse:{}},retina_detect:!1,fn:{interact:{},modes:{},vendors:{}},tmp:{}};var i=this.pJS;a&&Object.deepExtend(i,a),i.tmp.obj={size_value:i.particles.size.value,size_anim_speed:i.particles.size.anim.speed,move_speed:i.particles.move.speed,line_linked_distance:i.particles.line_linked.distance,line_linked_width:i.particles.line_linked.width,mode_grab_distance:i.interactivity.modes.grab.distance,mode_bubble_distance:i.interactivity.modes.bubble.distance,mode_bubble_size:i.interactivity.modes.bubble.size,mode_repulse_distance:i.interactivity.modes.repulse.distance},i.fn.retinaInit=function(){i.retina_detect&&window.devicePixelRatio>1?(i.canvas.pxratio=window.devicePixelRatio,i.tmp.retina=!0):(i.canvas.pxratio=1,i.tmp.retina=!1),i.canvas.w=i.canvas.el.offsetWidth*i.canvas.pxratio,i.canvas.h=i.canvas.el.offsetHeight*i.canvas.pxratio,i.particles.size.value=i.tmp.obj.size_value*i.canvas.pxratio,i.particles.size.anim.speed=i.tmp.obj.size_anim_speed*i.canvas.pxratio,i.particles.move.speed=i.tmp.obj.move_speed*i.canvas.pxratio,i.particles.line_linked.distance=i.tmp.obj.line_linked_distance*i.canvas.pxratio,i.interactivity.modes.grab.distance=i.tmp.obj.mode_grab_distance*i.canvas.pxratio,i.interactivity.modes.bubble.distance=i.tmp.obj.mode_bubble_distance*i.canvas.pxratio,i.particles.line_linked.width=i.tmp.obj.line_linked_width*i.canvas.pxratio,i.interactivity.modes.bubble.size=i.tmp.obj.mode_bubble_size*i.canvas.pxratio,i.interactivity.modes.repulse.distance=i.tmp.obj.mode_repulse_distance*i.canvas.pxratio},i.fn.canvasInit=function(){i.canvas.ctx=i.canvas.el.getContext("2d")},i.fn.canvasSize=function(){i.canvas.el.width=i.canvas.w,i.canvas.el.height=i.canvas.h,i&&i.interactivity.events.resize&&window.addEventListener("resize",function(){i.canvas.w=i.canvas.el.offsetWidth,i.canvas.h=i.canvas.el.offsetHeight,i.tmp.retina&&(i.canvas.w*=i.canvas.pxratio,i.canvas.h*=i.canvas.pxratio),i.canvas.el.width=i.canvas.w,i.canvas.el.height=i.canvas.h,i.particles.move.enable||(i.fn.particlesEmpty(),i.fn.particlesCreate(),i.fn.particlesDraw(),i.fn.vendors.densityAutoParticles()),i.fn.vendors.densityAutoParticles()})},i.fn.canvasPaint=function(){i.canvas.ctx.fillRect(0,0,i.canvas.w,i.canvas.h)},i.fn.canvasClear=function(){i.canvas.ctx.clearRect(0,0,i.canvas.w,i.canvas.h)},i.fn.particle=function(e,a,t){if(this.radius=(i.particles.size.random?Math.random():1)*i.particles.size.value,i.particles.size.anim.enable&&(this.size_status=!1,this.vs=i.particles.size.anim.speed/100,i.particles.size.anim.sync||(this.vs=this.vs*Math.random())),this.x=t?t.x:Math.random()*i.canvas.w,this.y=t?t.y:Math.random()*i.canvas.h,this.x>i.canvas.w-2*this.radius?this.x=this.x-this.radius:this.x<2*this.radius&&(this.x=this.x+this.radius),this.y>i.canvas.h-2*this.radius?this.y=this.y-this.radius:this.y<2*this.radius&&(this.y=this.y+this.radius),i.particles.move.bounce&&i.fn.vendors.checkOverlap(this,t),this.color={},"object"==typeof e.value)if(e.value instanceof Array){var s=e.value[Math.floor(Math.random()*i.particles.color.value.length)];this.color.rgb=hexToRgb(s)}else void 0!=e.value.r&&void 0!=e.value.g&&void 0!=e.value.b&&(this.color.rgb={r:e.value.r,g:e.value.g,b:e.value.b}),void 0!=e.value.h&&void 0!=e.value.s&&void 0!=e.value.l&&(this.color.hsl={h:e.value.h,s:e.value.s,l:e.value.l});else"random"==e.value?this.color.rgb={r:Math.floor(256*Math.random())+0,g:Math.floor(256*Math.random())+0,b:Math.floor(256*Math.random())+0}:"string"==typeof e.value&&(this.color=e,this.color.rgb=hexToRgb(this.color.value));this.opacity=(i.particles.opacity.random?Math.random():1)*i.particles.opacity.value,i.particles.opacity.anim.enable&&(this.opacity_status=!1,this.vo=i.particles.opacity.anim.speed/100,i.particles.opacity.anim.sync||(this.vo=this.vo*Math.random()));var n={};switch(i.particles.move.direction){case"top":n={x:0,y:-1};break;case"top-right":n={x:.5,y:-.5};break;case"right":n={x:1,y:-0};break;case"bottom-right":n={x:.5,y:.5};break;case"bottom":n={x:0,y:1};break;case"bottom-left":n={x:-.5,y:1};break;case"left":n={x:-1,y:0};break;case"top-left":n={x:-.5,y:-.5};break;default:n={x:0,y:0}}i.particles.move.straight?(this.vx=n.x,this.vy=n.y,i.particles.move.random&&(this.vx=this.vx*Math.random(),this.vy=this.vy*Math.random())):(this.vx=n.x+Math.random()-.5,this.vy=n.y+Math.random()-.5),this.vx_i=this.vx,this.vy_i=this.vy;var r=i.particles.shape.type;if("object"==typeof r){if(r instanceof Array){var c=r[Math.floor(Math.random()*r.length)];this.shape=c}}else this.shape=r;if("image"==this.shape){var o=i.particles.shape;this.img={src:o.image.src,ratio:o.image.width/o.image.height},this.img.ratio||(this.img.ratio=1),"svg"==i.tmp.img_type&&void 0!=i.tmp.source_svg&&(i.fn.vendors.createSvgImg(this),i.tmp.pushing&&(this.img.loaded=!1))}},i.fn.particle.prototype.draw=function(){function e(){i.canvas.ctx.drawImage(r,a.x-t,a.y-t,2*t,2*t/a.img.ratio)}var a=this;if(void 0!=a.radius_bubble)var t=a.radius_bubble;else var t=a.radius;if(void 0!=a.opacity_bubble)var s=a.opacity_bubble;else var s=a.opacity;if(a.color.rgb)var n="rgba("+a.color.rgb.r+","+a.color.rgb.g+","+a.color.rgb.b+","+s+")";else var n="hsla("+a.color.hsl.h+","+a.color.hsl.s+"%,"+a.color.hsl.l+"%,"+s+")";switch(i.canvas.ctx.fillStyle=n,i.canvas.ctx.beginPath(),a.shape){case"circle":i.canvas.ctx.arc(a.x,a.y,t,0,2*Math.PI,!1);break;case"edge":i.canvas.ctx.rect(a.x-t,a.y-t,2*t,2*t);break;case"triangle":i.fn.vendors.drawShape(i.canvas.ctx,a.x-t,a.y+t/1.66,2*t,3,2);break;case"polygon":i.fn.vendors.drawShape(i.canvas.ctx,a.x-t/(i.particles.shape.polygon.nb_sides/3.5),a.y-t/.76,2.66*t/(i.particles.shape.polygon.nb_sides/3),i.particles.shape.polygon.nb_sides,1);break;case"star":i.fn.vendors.drawShape(i.canvas.ctx,a.x-2*t/(i.particles.shape.polygon.nb_sides/4),a.y-t/1.52,2*t*2.66/(i.particles.shape.polygon.nb_sides/3),i.particles.shape.polygon.nb_sides,2);break;case"image":if("svg"==i.tmp.img_type)var r=a.img.obj;else var r=i.tmp.img_obj;r&&e()}i.canvas.ctx.closePath(),i.particles.shape.stroke.width>0&&(i.canvas.ctx.strokeStyle=i.particles.shape.stroke.color,i.canvas.ctx.lineWidth=i.particles.shape.stroke.width,i.canvas.ctx.stroke()),i.canvas.ctx.fill()},i.fn.particlesCreate=function(){for(var e=0;e=i.particles.opacity.value&&(a.opacity_status=!1),a.opacity+=a.vo):(a.opacity<=i.particles.opacity.anim.opacity_min&&(a.opacity_status=!0),a.opacity-=a.vo),a.opacity<0&&(a.opacity=0)),i.particles.size.anim.enable&&(1==a.size_status?(a.radius>=i.particles.size.value&&(a.size_status=!1),a.radius+=a.vs):(a.radius<=i.particles.size.anim.size_min&&(a.size_status=!0),a.radius-=a.vs),a.radius<0&&(a.radius=0)),"bounce"==i.particles.move.out_mode)var s={x_left:a.radius,x_right:i.canvas.w,y_top:a.radius,y_bottom:i.canvas.h};else var s={x_left:-a.radius,x_right:i.canvas.w+a.radius,y_top:-a.radius,y_bottom:i.canvas.h+a.radius};switch(a.x-a.radius>i.canvas.w?(a.x=s.x_left,a.y=Math.random()*i.canvas.h):a.x+a.radius<0&&(a.x=s.x_right,a.y=Math.random()*i.canvas.h),a.y-a.radius>i.canvas.h?(a.y=s.y_top,a.x=Math.random()*i.canvas.w):a.y+a.radius<0&&(a.y=s.y_bottom,a.x=Math.random()*i.canvas.w),i.particles.move.out_mode){case"bounce":a.x+a.radius>i.canvas.w?a.vx=-a.vx:a.x-a.radius<0&&(a.vx=-a.vx),a.y+a.radius>i.canvas.h?a.vy=-a.vy:a.y-a.radius<0&&(a.vy=-a.vy)}if(isInArray("grab",i.interactivity.events.onhover.mode)&&i.fn.modes.grabParticle(a),(isInArray("bubble",i.interactivity.events.onhover.mode)||isInArray("bubble",i.interactivity.events.onclick.mode))&&i.fn.modes.bubbleParticle(a),(isInArray("repulse",i.interactivity.events.onhover.mode)||isInArray("repulse",i.interactivity.events.onclick.mode))&&i.fn.modes.repulseParticle(a),i.particles.line_linked.enable||i.particles.move.attract.enable)for(var n=e+1;n0){var c=i.particles.line_linked.color_rgb_line;i.canvas.ctx.strokeStyle="rgba("+c.r+","+c.g+","+c.b+","+r+")",i.canvas.ctx.lineWidth=i.particles.line_linked.width,i.canvas.ctx.beginPath(),i.canvas.ctx.moveTo(e.x,e.y),i.canvas.ctx.lineTo(a.x,a.y),i.canvas.ctx.stroke(),i.canvas.ctx.closePath()}}},i.fn.interact.attractParticles=function(e,a){var t=e.x-a.x,s=e.y-a.y,n=Math.sqrt(t*t+s*s);if(n<=i.particles.line_linked.distance){var r=t/(1e3*i.particles.move.attract.rotateX),c=s/(1e3*i.particles.move.attract.rotateY);e.vx-=r,e.vy-=c,a.vx+=r,a.vy+=c}},i.fn.interact.bounceParticles=function(e,a){var t=e.x-a.x,i=e.y-a.y,s=Math.sqrt(t*t+i*i),n=e.radius+a.radius;n>=s&&(e.vx=-e.vx,e.vy=-e.vy,a.vx=-a.vx,a.vy=-a.vy)},i.fn.modes.pushParticles=function(e,a){i.tmp.pushing=!0;for(var t=0;e>t;t++)i.particles.array.push(new i.fn.particle(i.particles.color,i.particles.opacity.value,{x:a?a.pos_x:Math.random()*i.canvas.w,y:a?a.pos_y:Math.random()*i.canvas.h})),t==e-1&&(i.particles.move.enable||i.fn.particlesDraw(),i.tmp.pushing=!1)},i.fn.modes.removeParticles=function(e){i.particles.array.splice(0,e),i.particles.move.enable||i.fn.particlesDraw()},i.fn.modes.bubbleParticle=function(e){function a(){e.opacity_bubble=e.opacity,e.radius_bubble=e.radius}function t(a,t,s,n,c){if(a!=t)if(i.tmp.bubble_duration_end){if(void 0!=s){var o=n-p*(n-a)/i.interactivity.modes.bubble.duration,l=a-o;d=a+l,"size"==c&&(e.radius_bubble=d),"opacity"==c&&(e.opacity_bubble=d)}}else if(r<=i.interactivity.modes.bubble.distance){if(void 0!=s)var v=s;else var v=n;if(v!=a){var d=n-p*(n-a)/i.interactivity.modes.bubble.duration;"size"==c&&(e.radius_bubble=d),"opacity"==c&&(e.opacity_bubble=d)}}else"size"==c&&(e.radius_bubble=void 0),"opacity"==c&&(e.opacity_bubble=void 0)}if(i.interactivity.events.onhover.enable&&isInArray("bubble",i.interactivity.events.onhover.mode)){var s=e.x-i.interactivity.mouse.pos_x,n=e.y-i.interactivity.mouse.pos_y,r=Math.sqrt(s*s+n*n),c=1-r/i.interactivity.modes.bubble.distance;if(r<=i.interactivity.modes.bubble.distance){if(c>=0&&"mousemove"==i.interactivity.status){if(i.interactivity.modes.bubble.size!=i.particles.size.value)if(i.interactivity.modes.bubble.size>i.particles.size.value){var o=e.radius+i.interactivity.modes.bubble.size*c;o>=0&&(e.radius_bubble=o)}else{var l=e.radius-i.interactivity.modes.bubble.size,o=e.radius-l*c;o>0?e.radius_bubble=o:e.radius_bubble=0}if(i.interactivity.modes.bubble.opacity!=i.particles.opacity.value)if(i.interactivity.modes.bubble.opacity>i.particles.opacity.value){var v=i.interactivity.modes.bubble.opacity*c;v>e.opacity&&v<=i.interactivity.modes.bubble.opacity&&(e.opacity_bubble=v)}else{var v=e.opacity-(i.particles.opacity.value-i.interactivity.modes.bubble.opacity)*c;v=i.interactivity.modes.bubble.opacity&&(e.opacity_bubble=v)}}}else a();"mouseleave"==i.interactivity.status&&a()}else if(i.interactivity.events.onclick.enable&&isInArray("bubble",i.interactivity.events.onclick.mode)){if(i.tmp.bubble_clicking){var s=e.x-i.interactivity.mouse.click_pos_x,n=e.y-i.interactivity.mouse.click_pos_y,r=Math.sqrt(s*s+n*n),p=((new Date).getTime()-i.interactivity.mouse.click_time)/1e3;p>i.interactivity.modes.bubble.duration&&(i.tmp.bubble_duration_end=!0),p>2*i.interactivity.modes.bubble.duration&&(i.tmp.bubble_clicking=!1,i.tmp.bubble_duration_end=!1)}i.tmp.bubble_clicking&&(t(i.interactivity.modes.bubble.size,i.particles.size.value,e.radius_bubble,e.radius,"size"),t(i.interactivity.modes.bubble.opacity,i.particles.opacity.value,e.opacity_bubble,e.opacity,"opacity"))}},i.fn.modes.repulseParticle=function(e){function a(){var a=Math.atan2(d,p);if(e.vx=u*Math.cos(a),e.vy=u*Math.sin(a),"bounce"==i.particles.move.out_mode){var t={x:e.x+e.vx,y:e.y+e.vy};t.x+e.radius>i.canvas.w?e.vx=-e.vx:t.x-e.radius<0&&(e.vx=-e.vx),t.y+e.radius>i.canvas.h?e.vy=-e.vy:t.y-e.radius<0&&(e.vy=-e.vy)}}if(i.interactivity.events.onhover.enable&&isInArray("repulse",i.interactivity.events.onhover.mode)&&"mousemove"==i.interactivity.status){var t=e.x-i.interactivity.mouse.pos_x,s=e.y-i.interactivity.mouse.pos_y,n=Math.sqrt(t*t+s*s),r={x:t/n,y:s/n},c=i.interactivity.modes.repulse.distance,o=100,l=clamp(1/c*(-1*Math.pow(n/c,2)+1)*c*o,0,50),v={x:e.x+r.x*l,y:e.y+r.y*l};"bounce"==i.particles.move.out_mode?(v.x-e.radius>0&&v.x+e.radius0&&v.y+e.radius=m&&a()}else 0==i.tmp.repulse_clicking&&(e.vx=e.vx_i,e.vy=e.vy_i)},i.fn.modes.grabParticle=function(e){if(i.interactivity.events.onhover.enable&&"mousemove"==i.interactivity.status){var a=e.x-i.interactivity.mouse.pos_x,t=e.y-i.interactivity.mouse.pos_y,s=Math.sqrt(a*a+t*t);if(s<=i.interactivity.modes.grab.distance){var n=i.interactivity.modes.grab.line_linked.opacity-s/(1/i.interactivity.modes.grab.line_linked.opacity)/i.interactivity.modes.grab.distance;if(n>0){var r=i.particles.line_linked.color_rgb_line;i.canvas.ctx.strokeStyle="rgba("+r.r+","+r.g+","+r.b+","+n+")",i.canvas.ctx.lineWidth=i.particles.line_linked.width,i.canvas.ctx.beginPath(),i.canvas.ctx.moveTo(e.x,e.y),i.canvas.ctx.lineTo(i.interactivity.mouse.pos_x,i.interactivity.mouse.pos_y),i.canvas.ctx.stroke(),i.canvas.ctx.closePath()}}}},i.fn.vendors.eventsListeners=function(){"window"==i.interactivity.detect_on?i.interactivity.el=window:i.interactivity.el=i.canvas.el,(i.interactivity.events.onhover.enable||i.interactivity.events.onclick.enable)&&(i.interactivity.el.addEventListener("mousemove",function(e){if(i.interactivity.el==window)var a=e.clientX,t=e.clientY;else var a=e.offsetX||e.clientX,t=e.offsetY||e.clientY;i.interactivity.mouse.pos_x=a,i.interactivity.mouse.pos_y=t,i.tmp.retina&&(i.interactivity.mouse.pos_x*=i.canvas.pxratio,i.interactivity.mouse.pos_y*=i.canvas.pxratio),i.interactivity.status="mousemove"}),i.interactivity.el.addEventListener("mouseleave",function(e){i.interactivity.mouse.pos_x=null,i.interactivity.mouse.pos_y=null,i.interactivity.status="mouseleave"})),i.interactivity.events.onclick.enable&&i.interactivity.el.addEventListener("click",function(){if(i.interactivity.mouse.click_pos_x=i.interactivity.mouse.pos_x,i.interactivity.mouse.click_pos_y=i.interactivity.mouse.pos_y,i.interactivity.mouse.click_time=(new Date).getTime(),i.interactivity.events.onclick.enable)switch(i.interactivity.events.onclick.mode){case"push":i.particles.move.enable?i.fn.modes.pushParticles(i.interactivity.modes.push.particles_nb,i.interactivity.mouse):1==i.interactivity.modes.push.particles_nb?i.fn.modes.pushParticles(i.interactivity.modes.push.particles_nb,i.interactivity.mouse):i.interactivity.modes.push.particles_nb>1&&i.fn.modes.pushParticles(i.interactivity.modes.push.particles_nb);break;case"remove":i.fn.modes.removeParticles(i.interactivity.modes.remove.particles_nb);break;case"bubble":i.tmp.bubble_clicking=!0;break;case"repulse":i.tmp.repulse_clicking=!0,i.tmp.repulse_count=0,i.tmp.repulse_finish=!1,setTimeout(function(){i.tmp.repulse_clicking=!1},1e3*i.interactivity.modes.repulse.duration)}})},i.fn.vendors.densityAutoParticles=function(){if(i.particles.number.density.enable){var e=i.canvas.el.width*i.canvas.el.height/1e3;i.tmp.retina&&(e/=2*i.canvas.pxratio);var a=e*i.particles.number.value/i.particles.number.density.value_area,t=i.particles.array.length-a;0>t?i.fn.modes.pushParticles(Math.abs(t)):i.fn.modes.removeParticles(t)}},i.fn.vendors.checkOverlap=function(e,a){for(var t=0;tv;v++)e.lineTo(i,0),e.translate(i,0),e.rotate(l);e.fill(),e.restore()},i.fn.vendors.exportImg=function(){window.open(i.canvas.el.toDataURL("image/png"),"_blank")},i.fn.vendors.loadImg=function(e){if(i.tmp.img_error=void 0,""!=i.particles.shape.image.src)if("svg"==e){var a=new XMLHttpRequest;a.open("GET",i.particles.shape.image.src),a.onreadystatechange=function(e){4==a.readyState&&(200==a.status?(i.tmp.source_svg=e.currentTarget.response,i.fn.vendors.checkBeforeDraw()):(console.log("Error pJS - Image not found"),i.tmp.img_error=!0))},a.send()}else{var t=new Image;t.addEventListener("load",function(){i.tmp.img_obj=t,i.fn.vendors.checkBeforeDraw()}),t.src=i.particles.shape.image.src}else console.log("Error pJS - No image.src"),i.tmp.img_error=!0},i.fn.vendors.draw=function(){"image"==i.particles.shape.type?"svg"==i.tmp.img_type?i.tmp.count_svg>=i.particles.number.value?(i.fn.particlesDraw(),i.particles.move.enable?i.fn.drawAnimFrame=requestAnimFrame(i.fn.vendors.draw):cancelRequestAnimFrame(i.fn.drawAnimFrame)):i.tmp.img_error||(i.fn.drawAnimFrame=requestAnimFrame(i.fn.vendors.draw)):void 0!=i.tmp.img_obj?(i.fn.particlesDraw(),i.particles.move.enable?i.fn.drawAnimFrame=requestAnimFrame(i.fn.vendors.draw):cancelRequestAnimFrame(i.fn.drawAnimFrame)):i.tmp.img_error||(i.fn.drawAnimFrame=requestAnimFrame(i.fn.vendors.draw)):(i.fn.particlesDraw(),i.particles.move.enable?i.fn.drawAnimFrame=requestAnimFrame(i.fn.vendors.draw):cancelRequestAnimFrame(i.fn.drawAnimFrame))},i.fn.vendors.checkBeforeDraw=function(){"image"==i.particles.shape.type?"svg"==i.tmp.img_type&&void 0==i.tmp.source_svg?i.tmp.checkAnimFrame=requestAnimFrame(check):(cancelRequestAnimFrame(i.tmp.checkAnimFrame),i.tmp.img_error||(i.fn.vendors.init(),i.fn.vendors.draw())):(i.fn.vendors.init(),i.fn.vendors.draw())},i.fn.vendors.init=function(){i.fn.retinaInit(),i.fn.canvasInit(),i.fn.canvasSize(),i.fn.canvasPaint(),i.fn.particlesCreate(),i.fn.vendors.densityAutoParticles(),i.particles.line_linked.color_rgb_line=hexToRgb(i.particles.line_linked.color)},i.fn.vendors.start=function(){isInArray("image",i.particles.shape.type)?(i.tmp.img_type=i.particles.shape.image.src.substr(i.particles.shape.image.src.length-3),i.fn.vendors.loadImg(i.tmp.img_type)):i.fn.vendors.checkBeforeDraw()},i.fn.vendors.eventsListeners(),i.fn.vendors.start()};Object.deepExtend=function(e,a){for(var t in a)a[t]&&a[t].constructor&&a[t].constructor===Object?(e[t]=e[t]||{},arguments.callee(e[t],a[t])):e[t]=a[t];return e},window.requestAnimFrame=function(){return window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.oRequestAnimationFrame||window.msRequestAnimationFrame||function(e){window.setTimeout(e,1e3/60)}}(),window.cancelRequestAnimFrame=function(){return window.cancelAnimationFrame||window.webkitCancelRequestAnimationFrame||window.mozCancelRequestAnimationFrame||window.oCancelRequestAnimationFrame||window.msCancelRequestAnimationFrame||clearTimeout}(),window.pJSDom=[],window.particlesJS=function(e,a){"string"!=typeof e&&(a=e,e="particles-js"),e||(e="particles-js");var t=document.getElementById(e),i="particles-js-canvas-el",s=t.getElementsByClassName(i);if(s.length)for(;s.length>0;)t.removeChild(s[0]);var n=document.createElement("canvas");n.className=i,n.style.width="100%",n.style.height="100%";var r=document.getElementById(e).appendChild(n);null!=r&&pJSDom.push(new pJS(e,a))},window.particlesJS.load=function(e,a,t){var i=new XMLHttpRequest;i.open("GET",a),i.onreadystatechange=function(a){if(4==i.readyState)if(200==i.status){var s=JSON.parse(a.currentTarget.response);window.particlesJS(e,s),t&&t()}else console.log("Error pJS - XMLHttpRequest status: "+i.status),console.log("Error pJS - File config not found")},i.send()}; // source --> https://www.annamonteverdi.it/digital/wp-content/themes/agama/assets/js/plugins.js?ver=1.2.8.10.1505293712 /* * jQuery Easing v1.3 - http://gsgd.co.uk/sandbox/jquery/easing/ * * Uses the built in easing capabilities added In jQuery 1.1 * to offer multiple easing options * * TERMS OF USE - jQuery Easing * * Open source under the BSD License. * * Copyright © 2008 George McGinley Smith * All rights reserved. * * Redistribution and use in source and binary forms, with or without modification, * are permitted provided that the following conditions are met: * * Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. * * Neither the name of the author nor the names of contributors may be used to endorse * or promote products derived from this software without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED * OF THE POSSIBILITY OF SUCH DAMAGE. * */ jQuery.easing.jswing=jQuery.easing.swing,jQuery.extend(jQuery.easing,{def:"easeOutQuad",swing:function(n,e,t,u,a){return jQuery.easing[jQuery.easing.def](n,e,t,u,a)},easeInQuad:function(n,e,t,u,a){return u*(e/=a)*e+t},easeOutQuad:function(n,e,t,u,a){return-u*(e/=a)*(e-2)+t},easeInOutQuad:function(n,e,t,u,a){return(e/=a/2)<1?u/2*e*e+t:-u/2*(--e*(e-2)-1)+t},easeInCubic:function(n,e,t,u,a){return u*(e/=a)*e*e+t},easeOutCubic:function(n,e,t,u,a){return u*((e=e/a-1)*e*e+1)+t},easeInOutCubic:function(n,e,t,u,a){return(e/=a/2)<1?u/2*e*e*e+t:u/2*((e-=2)*e*e+2)+t},easeInQuart:function(n,e,t,u,a){return u*(e/=a)*e*e*e+t},easeOutQuart:function(n,e,t,u,a){return-u*((e=e/a-1)*e*e*e-1)+t},easeInOutQuart:function(n,e,t,u,a){return(e/=a/2)<1?u/2*e*e*e*e+t:-u/2*((e-=2)*e*e*e-2)+t},easeInQuint:function(n,e,t,u,a){return u*(e/=a)*e*e*e*e+t},easeOutQuint:function(n,e,t,u,a){return u*((e=e/a-1)*e*e*e*e+1)+t},easeInOutQuint:function(n,e,t,u,a){return(e/=a/2)<1?u/2*e*e*e*e*e+t:u/2*((e-=2)*e*e*e*e+2)+t},easeInSine:function(n,e,t,u,a){return-u*Math.cos(e/a*(Math.PI/2))+u+t},easeOutSine:function(n,e,t,u,a){return u*Math.sin(e/a*(Math.PI/2))+t},easeInOutSine:function(n,e,t,u,a){return-u/2*(Math.cos(Math.PI*e/a)-1)+t},easeInExpo:function(n,e,t,u,a){return 0==e?t:u*Math.pow(2,10*(e/a-1))+t},easeOutExpo:function(n,e,t,u,a){return e==a?t+u:u*(-Math.pow(2,-10*e/a)+1)+t},easeInOutExpo:function(n,e,t,u,a){return 0==e?t:e==a?t+u:(e/=a/2)<1?u/2*Math.pow(2,10*(e-1))+t:u/2*(-Math.pow(2,-10*--e)+2)+t},easeInCirc:function(n,e,t,u,a){return-u*(Math.sqrt(1-(e/=a)*e)-1)+t},easeOutCirc:function(n,e,t,u,a){return u*Math.sqrt(1-(e=e/a-1)*e)+t},easeInOutCirc:function(n,e,t,u,a){return(e/=a/2)<1?-u/2*(Math.sqrt(1-e*e)-1)+t:u/2*(Math.sqrt(1-(e-=2)*e)+1)+t},easeInElastic:function(n,e,t,u,a){var r=1.70158,i=0,s=u;if(0==e)return t;if(1==(e/=a))return t+u;if(i||(i=.3*a),se?-.5*(s*Math.pow(2,10*(e-=1))*Math.sin((e*a-r)*(2*Math.PI)/i))+t:s*Math.pow(2,-10*(e-=1))*Math.sin((e*a-r)*(2*Math.PI)/i)*.5+u+t},easeInBack:function(n,e,t,u,a,r){return void 0==r&&(r=1.70158),u*(e/=a)*e*((r+1)*e-r)+t},easeOutBack:function(n,e,t,u,a,r){return void 0==r&&(r=1.70158),u*((e=e/a-1)*e*((r+1)*e+r)+1)+t},easeInOutBack:function(n,e,t,u,a,r){return void 0==r&&(r=1.70158),(e/=a/2)<1?u/2*(e*e*(((r*=1.525)+1)*e-r))+t:u/2*((e-=2)*e*(((r*=1.525)+1)*e+r)+2)+t},easeInBounce:function(n,e,t,u,a){return u-jQuery.easing.easeOutBounce(n,a-e,0,u,a)+t},easeOutBounce:function(n,e,t,u,a){return(e/=a)<1/2.75?u*(7.5625*e*e)+t:2/2.75>e?u*(7.5625*(e-=1.5/2.75)*e+.75)+t:2.5/2.75>e?u*(7.5625*(e-=2.25/2.75)*e+.9375)+t:u*(7.5625*(e-=2.625/2.75)*e+.984375)+t},easeInOutBounce:function(n,e,t,u,a){return a/2>e?.5*jQuery.easing.easeInBounce(n,2*e,0,u,a)+t:.5*jQuery.easing.easeOutBounce(n,2*e-a,0,u,a)+.5*u+t}}); /*! * imagesLoaded PACKAGED v3.1.8 * JavaScript is all like "You images are done yet or what?" * MIT License */ (function(){function e(){}function t(e,t){for(var n=e.length;n--;)if(e[n].listener===t)return n;return-1}function n(e){return function(){return this[e].apply(this,arguments)}}var i=e.prototype,r=this,o=r.EventEmitter;i.getListeners=function(e){var t,n,i=this._getEvents();if("object"==typeof e){t={};for(n in i)i.hasOwnProperty(n)&&e.test(n)&&(t[n]=i[n])}else t=i[e]||(i[e]=[]);return t},i.flattenListeners=function(e){var t,n=[];for(t=0;e.length>t;t+=1)n.push(e[t].listener);return n},i.getListenersAsObject=function(e){var t,n=this.getListeners(e);return n instanceof Array&&(t={},t[e]=n),t||n},i.addListener=function(e,n){var i,r=this.getListenersAsObject(e),o="object"==typeof n;for(i in r)r.hasOwnProperty(i)&&-1===t(r[i],n)&&r[i].push(o?n:{listener:n,once:!1});return this},i.on=n("addListener"),i.addOnceListener=function(e,t){return this.addListener(e,{listener:t,once:!0})},i.once=n("addOnceListener"),i.defineEvent=function(e){return this.getListeners(e),this},i.defineEvents=function(e){for(var t=0;e.length>t;t+=1)this.defineEvent(e[t]);return this},i.removeListener=function(e,n){var i,r,o=this.getListenersAsObject(e);for(r in o)o.hasOwnProperty(r)&&(i=t(o[r],n),-1!==i&&o[r].splice(i,1));return this},i.off=n("removeListener"),i.addListeners=function(e,t){return this.manipulateListeners(!1,e,t)},i.removeListeners=function(e,t){return this.manipulateListeners(!0,e,t)},i.manipulateListeners=function(e,t,n){var i,r,o=e?this.removeListener:this.addListener,s=e?this.removeListeners:this.addListeners;if("object"!=typeof t||t instanceof RegExp)for(i=n.length;i--;)o.call(this,t,n[i]);else for(i in t)t.hasOwnProperty(i)&&(r=t[i])&&("function"==typeof r?o.call(this,i,r):s.call(this,i,r));return this},i.removeEvent=function(e){var t,n=typeof e,i=this._getEvents();if("string"===n)delete i[e];else if("object"===n)for(t in i)i.hasOwnProperty(t)&&e.test(t)&&delete i[t];else delete this._events;return this},i.removeAllListeners=n("removeEvent"),i.emitEvent=function(e,t){var n,i,r,o,s=this.getListenersAsObject(e);for(r in s)if(s.hasOwnProperty(r))for(i=s[r].length;i--;)n=s[r][i],n.once===!0&&this.removeListener(e,n.listener),o=n.listener.apply(this,t||[]),o===this._getOnceReturnValue()&&this.removeListener(e,n.listener);return this},i.trigger=n("emitEvent"),i.emit=function(e){var t=Array.prototype.slice.call(arguments,1);return this.emitEvent(e,t)},i.setOnceReturnValue=function(e){return this._onceReturnValue=e,this},i._getOnceReturnValue=function(){return this.hasOwnProperty("_onceReturnValue")?this._onceReturnValue:!0},i._getEvents=function(){return this._events||(this._events={})},e.noConflict=function(){return r.EventEmitter=o,e},"function"==typeof define&&define.amd?define("eventEmitter/EventEmitter",[],function(){return e}):"object"==typeof module&&module.exports?module.exports=e:this.EventEmitter=e}).call(this),function(e){function t(t){var n=e.event;return n.target=n.target||n.srcElement||t,n}var n=document.documentElement,i=function(){};n.addEventListener?i=function(e,t,n){e.addEventListener(t,n,!1)}:n.attachEvent&&(i=function(e,n,i){e[n+i]=i.handleEvent?function(){var n=t(e);i.handleEvent.call(i,n)}:function(){var n=t(e);i.call(e,n)},e.attachEvent("on"+n,e[n+i])});var r=function(){};n.removeEventListener?r=function(e,t,n){e.removeEventListener(t,n,!1)}:n.detachEvent&&(r=function(e,t,n){e.detachEvent("on"+t,e[t+n]);try{delete e[t+n]}catch(i){e[t+n]=void 0}});var o={bind:i,unbind:r};"function"==typeof define&&define.amd?define("eventie/eventie",o):e.eventie=o}(this),function(e,t){"function"==typeof define&&define.amd?define(["eventEmitter/EventEmitter","eventie/eventie"],function(n,i){return t(e,n,i)}):"object"==typeof exports?module.exports=t(e,require("wolfy87-eventemitter"),require("eventie")):e.imagesLoaded=t(e,e.EventEmitter,e.eventie)}(window,function(e,t,n){function i(e,t){for(var n in t)e[n]=t[n];return e}function r(e){return"[object Array]"===d.call(e)}function o(e){var t=[];if(r(e))t=e;else if("number"==typeof e.length)for(var n=0,i=e.length;i>n;n++)t.push(e[n]);else t.push(e);return t}function s(e,t,n){if(!(this instanceof s))return new s(e,t);"string"==typeof e&&(e=document.querySelectorAll(e)),this.elements=o(e),this.options=i({},this.options),"function"==typeof t?n=t:i(this.options,t),n&&this.on("always",n),this.getImages(),a&&(this.jqDeferred=new a.Deferred);var r=this;setTimeout(function(){r.check()})}function f(e){this.img=e}function c(e){this.src=e,v[e]=this}var a=e.jQuery,u=e.console,h=u!==void 0,d=Object.prototype.toString;s.prototype=new t,s.prototype.options={},s.prototype.getImages=function(){this.images=[];for(var e=0,t=this.elements.length;t>e;e++){var n=this.elements[e];"IMG"===n.nodeName&&this.addImage(n);var i=n.nodeType;if(i&&(1===i||9===i||11===i))for(var r=n.querySelectorAll("img"),o=0,s=r.length;s>o;o++){var f=r[o];this.addImage(f)}}},s.prototype.addImage=function(e){var t=new f(e);this.images.push(t)},s.prototype.check=function(){function e(e,r){return t.options.debug&&h&&u.log("confirm",e,r),t.progress(e),n++,n===i&&t.complete(),!0}var t=this,n=0,i=this.images.length;if(this.hasAnyBroken=!1,!i)return this.complete(),void 0;for(var r=0;i>r;r++){var o=this.images[r];o.on("confirm",e),o.check()}},s.prototype.progress=function(e){this.hasAnyBroken=this.hasAnyBroken||!e.isLoaded;var t=this;setTimeout(function(){t.emit("progress",t,e),t.jqDeferred&&t.jqDeferred.notify&&t.jqDeferred.notify(t,e)})},s.prototype.complete=function(){var e=this.hasAnyBroken?"fail":"done";this.isComplete=!0;var t=this;setTimeout(function(){if(t.emit(e,t),t.emit("always",t),t.jqDeferred){var n=t.hasAnyBroken?"reject":"resolve";t.jqDeferred[n](t)}})},a&&(a.fn.imagesLoaded=function(e,t){var n=new s(this,e,t);return n.jqDeferred.promise(a(this))}),f.prototype=new t,f.prototype.check=function(){var e=v[this.img.src]||new c(this.img.src);if(e.isConfirmed)return this.confirm(e.isLoaded,"cached was confirmed"),void 0;if(this.img.complete&&void 0!==this.img.naturalWidth)return this.confirm(0!==this.img.naturalWidth,"naturalWidth"),void 0;var t=this;e.on("confirm",function(e,n){return t.confirm(e.isLoaded,n),!0}),e.check()},f.prototype.confirm=function(e,t){this.isLoaded=e,this.emit("confirm",this,t)};var v={};return c.prototype=new t,c.prototype.check=function(){if(!this.isChecked){var e=new Image;n.bind(e,"load",this),n.bind(e,"error",this),e.src=this.src,this.isChecked=!0}},c.prototype.handleEvent=function(e){var t="on"+e.type;this[t]&&this[t](e)},c.prototype.onload=function(e){this.confirm(!0,"onload"),this.unbindProxyEvents(e)},c.prototype.onerror=function(e){this.confirm(!1,"onerror"),this.unbindProxyEvents(e)},c.prototype.confirm=function(e,t){this.isConfirmed=!0,this.isLoaded=e,this.emit("confirm",this,t)},c.prototype.unbindProxyEvents=function(e){n.unbind(e.target,"load",this),n.unbind(e.target,"error",this)},s}); /* * jQuery Superfish Menu Plugin - v1.7.10 * Copyright (c) 2018 Joel Birch * * Dual licensed under the MIT and GPL licenses: * http://www.opensource.org/licenses/mit-license.php * http://www.gnu.org/licenses/gpl.html */ ;!function(a,b){"use strict";var c=function(){var c={bcClass:"sf-breadcrumb",menuClass:"sf-js-enabled",anchorClass:"sf-with-ul",menuArrowClass:"sf-arrows"},d=function(){var b=/^(?![\w\W]*Windows Phone)[\w\W]*(iPhone|iPad|iPod)/i.test(navigator.userAgent);return b&&a("html").css("cursor","pointer").on("click",a.noop),b}(),e=function(){var a=document.documentElement.style;return"behavior"in a&&"fill"in a&&/iemobile/i.test(navigator.userAgent)}(),f=function(){return!!b.PointerEvent}(),g=function(a,b,d){var e,f=c.menuClass;b.cssArrows&&(f+=" "+c.menuArrowClass),e=d?"addClass":"removeClass",a[e](f)},h=function(b,d){return b.find("li."+d.pathClass).slice(0,d.pathLevels).addClass(d.hoverClass+" "+c.bcClass).filter(function(){return a(this).children(d.popUpSelector).hide().show().length}).removeClass(d.pathClass)},i=function(a,b){var d=b?"addClass":"removeClass";a.children("a")[d](c.anchorClass)},j=function(a){var b=a.css("ms-touch-action"),c=a.css("touch-action");c=c||b,c="pan-y"===c?"auto":"pan-y",a.css({"ms-touch-action":c,"touch-action":c})},k=function(a){return a.closest("."+c.menuClass)},l=function(a){return k(a).data("sfOptions")},m=function(){var b=a(this),c=l(b);clearTimeout(c.sfTimer),b.siblings().superfish("hide").end().superfish("show")},n=function(b){b.retainPath=a.inArray(this[0],b.$path)>-1,this.superfish("hide"),this.parents("."+b.hoverClass).length||(b.onIdle.call(k(this)),b.$path.length&&a.proxy(m,b.$path)())},o=function(){var b=a(this),c=l(b);d?a.proxy(n,b,c)():(clearTimeout(c.sfTimer),c.sfTimer=setTimeout(a.proxy(n,b,c),c.delay))},p=function(b){var c=a(this),d=l(c),e=c.siblings(b.data.popUpSelector);return d.onHandleTouch.call(e)===!1?this:void(e.length>0&&e.is(":hidden")&&(c.one("click.superfish",!1),"MSPointerDown"===b.type||"pointerdown"===b.type?c.trigger("focus"):a.proxy(m,c.parent("li"))()))},q=function(b,c){var g="li:has("+c.popUpSelector+")";a.fn.hoverIntent&&!c.disableHI?b.hoverIntent(m,o,g):b.on("mouseenter.superfish",g,m).on("mouseleave.superfish",g,o);var h="MSPointerDown.superfish";f&&(h="pointerdown.superfish"),d||(h+=" touchend.superfish"),e&&(h+=" mousedown.superfish"),b.on("focusin.superfish","li",m).on("focusout.superfish","li",o).on(h,"a",c,p)};return{hide:function(b){if(this.length){var c=this,d=l(c);if(!d)return this;var e=d.retainPath===!0?d.$path:"",f=c.find("li."+d.hoverClass).add(this).not(e).removeClass(d.hoverClass).children(d.popUpSelector),g=d.speedOut;if(b&&(f.show(),g=0),d.retainPath=!1,d.onBeforeHide.call(f)===!1)return this;f.stop(!0,!0).animate(d.animationOut,g,function(){var b=a(this);d.onHide.call(b)})}return this},show:function(){var a=l(this);if(!a)return this;var b=this.addClass(a.hoverClass),c=b.children(a.popUpSelector);return a.onBeforeShow.call(c)===!1?this:(c.stop(!0,!0).animate(a.animation,a.speed,function(){a.onShow.call(c)}),this)},destroy:function(){return this.each(function(){var b,d=a(this),e=d.data("sfOptions");return!!e&&(b=d.find(e.popUpSelector).parent("li"),clearTimeout(e.sfTimer),g(d,e),i(b),j(d),d.off(".superfish").off(".hoverIntent"),b.children(e.popUpSelector).attr("style",function(a,b){if("undefined"!=typeof b)return b.replace(/display[^;]+;?/g,"")}),e.$path.removeClass(e.hoverClass+" "+c.bcClass).addClass(e.pathClass),d.find("."+e.hoverClass).removeClass(e.hoverClass),e.onDestroy.call(d),void d.removeData("sfOptions"))})},init:function(b){return this.each(function(){var d=a(this);if(d.data("sfOptions"))return!1;var e=a.extend({},a.fn.superfish.defaults,b),f=d.find(e.popUpSelector).parent("li");e.$path=h(d,e),d.data("sfOptions",e),g(d,e,!0),i(f,!0),j(d),q(d,e),f.not("."+c.bcClass).superfish("hide",!0),e.onInit.call(this)})}}}();a.fn.superfish=function(b,d){return c[b]?c[b].apply(this,Array.prototype.slice.call(arguments,1)):"object"!=typeof b&&b?a.error("Method "+b+" does not exist on jQuery.fn.superfish"):c.init.apply(this,arguments)},a.fn.superfish.defaults={popUpSelector:"ul,.sf-mega",hoverClass:"sfHover",pathClass:"overrideThisToUse",pathLevels:1,delay:800,animation:{opacity:"show"},animationOut:{opacity:"hide"},speed:"normal",speedOut:"fast",cssArrows:!0,disableHI:!1,onInit:a.noop,onBeforeShow:a.noop,onShow:a.noop,onBeforeHide:a.noop,onHide:a.noop,onIdle:a.noop,onDestroy:a.noop,onHandleTouch:a.noop}}(jQuery,window); /*! * hoverIntent v1.9.0 // 2017.09.01 // jQuery v1.7.0+ * http://briancherne.github.io/jquery-hoverIntent/ * * You may use hoverIntent under the terms of the MIT license. Basically that * means you are free to use hoverIntent as long as this header is left intact. * Copyright 2007-2017 Brian Cherne */ !function(factory){"use strict";"function"==typeof define&&define.amd?define(["jquery"],factory):jQuery&&!jQuery.fn.hoverIntent&&factory(jQuery)}(function($){"use strict";var cX,cY,_cfg={interval:100,sensitivity:6,timeout:0},INSTANCE_COUNT=0,track=function(ev){cX=ev.pageX,cY=ev.pageY},compare=function(ev,$el,s,cfg){if(Math.sqrt((s.pX-cX)*(s.pX-cX)+(s.pY-cY)*(s.pY-cY))=e[c].enter&&a<=e[c].exit){b=!0;break}b&&f!==e[c].label?(g=f,f=e[c].label,p()):b||""===f||(f="",p())},r=function(a){if("object"==typeof a){if(a.join().indexOf(f)>=0)return!0}else{if("*"===a)return!0;if("string"==typeof a&&f===a)return!0}},s=function(){var a=m();a!==i?(l=j,q(a)):l=k,i=a,setTimeout(s,l)};return s(),{addFunc:function(a){n(a)},getBreakpoint:function(){return f}}}}(this,this.document)); /*! * Smart Resize * https://github.com/peschee/jquery-smartresize */ !function(n,r){var t=function(n,r,t){var i;return function(){var e=this,u=arguments;i?clearTimeout(i):t&&n.apply(e,u),i=setTimeout(function(){t||n.apply(e,u),i=null},r||100)}};jQuery.fn[r]=function(n,i){return n?this.bind("resize",t(n,i)):this.trigger(r)}}(jQuery,"smartresize"); /*! * Infinite Scroll PACKAGED v3.0.4 * Automatically add next page * * Licensed GPLv3 for open source use * or Infinite Scroll Commercial License for commercial use * * https://infinite-scroll.com * Copyright 2018 Metafizzy */ !function(t,e){"function"==typeof define&&define.amd?define("jquery-bridget/jquery-bridget",["jquery"],function(i){return e(t,i)}):"object"==typeof module&&module.exports?module.exports=e(t,require("jquery")):t.jQueryBridget=e(t,t.jQuery)}(window,function(t,e){"use strict";function i(i,r,l){function a(t,e,n){var o,r="$()."+i+'("'+e+'")';return t.each(function(t,a){var h=l.data(a,i);if(!h)return void s(i+" not initialized. Cannot call methods, i.e. "+r);var c=h[e];if(!c||"_"==e.charAt(0))return void s(r+" is not a valid method");var u=c.apply(h,n);o=void 0===o?u:o}),void 0!==o?o:t}function h(t,e){t.each(function(t,n){var o=l.data(n,i);o?(o.option(e),o._init()):(o=new r(n,e),l.data(n,i,o))})}l=l||e||t.jQuery,l&&(r.prototype.option||(r.prototype.option=function(t){l.isPlainObject(t)&&(this.options=l.extend(!0,this.options,t))}),l.fn[i]=function(t){if("string"==typeof t){var e=o.call(arguments,1);return a(this,t,e)}return h(this,t),this},n(l))}function n(t){!t||t&&t.bridget||(t.bridget=i)}var o=Array.prototype.slice,r=t.console,s="undefined"==typeof r?function(){}:function(t){r.error(t)};return n(e||t.jQuery),i}),function(t,e){"function"==typeof define&&define.amd?define("ev-emitter/ev-emitter",e):"object"==typeof module&&module.exports?module.exports=e():t.EvEmitter=e()}("undefined"!=typeof window?window:this,function(){function t(){}var e=t.prototype;return e.on=function(t,e){if(t&&e){var i=this._events=this._events||{},n=i[t]=i[t]||[];return n.indexOf(e)==-1&&n.push(e),this}},e.once=function(t,e){if(t&&e){this.on(t,e);var i=this._onceEvents=this._onceEvents||{},n=i[t]=i[t]||{};return n[e]=!0,this}},e.off=function(t,e){var i=this._events&&this._events[t];if(i&&i.length){var n=i.indexOf(e);return n!=-1&&i.splice(n,1),this}},e.emitEvent=function(t,e){var i=this._events&&this._events[t];if(i&&i.length){i=i.slice(0),e=e||[];for(var n=this._onceEvents&&this._onceEvents[t],o=0;o=0,this.isPrefilling?(this.log("prefill"),this.loadNextPage()):this.stopPrefill()},s.getPrefillDistance=function(){return this.options.elementScroll?this.scroller.clientHeight-this.scroller.scrollHeight:this.windowHeight-this.element.clientHeight},s.stopPrefill=function(){this.log("stopPrefill"),this.off("append",this.prefill)},e}),function(t,e){"function"==typeof define&&define.amd?define("infinite-scroll/js/scroll-watch",["./core","fizzy-ui-utils/utils"],function(i,n){return e(t,i,n)}):"object"==typeof module&&module.exports?module.exports=e(t,require("./core"),require("fizzy-ui-utils")):e(t,t.InfiniteScroll,t.fizzyUIUtils)}(window,function(t,e,i){var n=e.prototype;return e.defaults.scrollThreshold=400,e.create.scrollWatch=function(){this.pageScrollHandler=this.onPageScroll.bind(this),this.resizeHandler=this.onResize.bind(this);var t=this.options.scrollThreshold,e=t||0===t;e&&this.enableScrollWatch()},e.destroy.scrollWatch=function(){this.disableScrollWatch()},n.enableScrollWatch=function(){this.isScrollWatching||(this.isScrollWatching=!0,this.updateMeasurements(),this.updateScroller(),this.on("last",this.disableScrollWatch),this.bindScrollWatchEvents(!0))},n.disableScrollWatch=function(){this.isScrollWatching&&(this.bindScrollWatchEvents(!1),delete this.isScrollWatching)},n.bindScrollWatchEvents=function(e){var i=e?"addEventListener":"removeEventListener";this.scroller[i]("scroll",this.pageScrollHandler),t[i]("resize",this.resizeHandler)},n.onPageScroll=e.throttle(function(){var t=this.getBottomDistance();t<=this.options.scrollThreshold&&this.dispatchEvent("scrollThreshold")}),n.getBottomDistance=function(){return this.options.elementScroll?this.getElementBottomDistance():this.getWindowBottomDistance()},n.getWindowBottomDistance=function(){var e=this.top+this.element.clientHeight,i=t.pageYOffset+this.windowHeight;return e-i},n.getElementBottomDistance=function(){var t=this.scroller.scrollHeight,e=this.scroller.scrollTop+this.scroller.clientHeight;return t-e},n.onResize=function(){this.updateMeasurements()},i.debounceMethod(e,"onResize",150),e}),function(t,e){"function"==typeof define&&define.amd?define("infinite-scroll/js/history",["./core","fizzy-ui-utils/utils"],function(i,n){return e(t,i,n)}):"object"==typeof module&&module.exports?module.exports=e(t,require("./core"),require("fizzy-ui-utils")):e(t,t.InfiniteScroll,t.fizzyUIUtils)}(window,function(t,e,i){var n=e.prototype;e.defaults.history="replace";var o=document.createElement("a");return e.create.history=function(){if(this.options.history){o.href=this.getAbsolutePath();var t=o.origin||o.protocol+"//"+o.host,e=t==location.origin;return e?void(this.options.append?this.createHistoryAppend():this.createHistoryPageLoad()):void console.error("[InfiniteScroll] cannot set history with different origin: "+o.origin+" on "+location.origin+" . History behavior disabled.")}},n.createHistoryAppend=function(){this.updateMeasurements(),this.updateScroller(),this.scrollPages=[{top:0,path:location.href,title:document.title}],this.scrollPageIndex=0,this.scrollHistoryHandler=this.onScrollHistory.bind(this),this.unloadHandler=this.onUnload.bind(this),this.scroller.addEventListener("scroll",this.scrollHistoryHandler),this.on("append",this.onAppendHistory),this.bindHistoryAppendEvents(!0)},n.bindHistoryAppendEvents=function(e){var i=e?"addEventListener":"removeEventListener";this.scroller[i]("scroll",this.scrollHistoryHandler),t[i]("unload",this.unloadHandler)},n.createHistoryPageLoad=function(){this.on("load",this.onPageLoadHistory)},e.destroy.history=n.destroyHistory=function(){var t=this.options.history&&this.options.append;t&&this.bindHistoryAppendEvents(!1)},n.onAppendHistory=function(t,e,i){if(i&&i.length){var n=i[0],r=this.getElementScrollY(n);o.href=e,this.scrollPages.push({top:r,path:o.href,title:t.title})}},n.getElementScrollY=function(t){return this.options.elementScroll?this.getElementElementScrollY(t):this.getElementWindowScrollY(t)},n.getElementWindowScrollY=function(e){var i=e.getBoundingClientRect();return i.top+t.pageYOffset},n.getElementElementScrollY=function(t){return t.offsetTop-this.top},n.onScrollHistory=function(){for(var t,e,i=this.getScrollViewY(),n=0;n=i)break;t=n,e=o}t!=this.scrollPageIndex&&(this.scrollPageIndex=t,this.setHistory(e.title,e.path))},i.debounceMethod(e,"onScrollHistory",150),n.getScrollViewY=function(){return this.options.elementScroll?this.scroller.scrollTop+this.scroller.clientHeight/2:t.pageYOffset+this.windowHeight/2},n.setHistory=function(t,e){var i=this.options.history,n=i&&history[i+"State"];n&&(history[i+"State"](null,t,e),this.options.historyTitle&&(document.title=t),this.dispatchEvent("history",null,[t,e]))},n.onUnload=function(){var e=this.scrollPageIndex;if(0!==e){var i=this.scrollPages[e],n=t.pageYOffset-i.top+this.top;this.destroyHistory(),scrollTo(0,n)}},n.onPageLoadHistory=function(t,e){this.setHistory(t.title,e)},e}),function(t,e){"function"==typeof define&&define.amd?define("infinite-scroll/js/button",["./core","fizzy-ui-utils/utils"],function(i,n){return e(t,i,n)}):"object"==typeof module&&module.exports?module.exports=e(t,require("./core"),require("fizzy-ui-utils")):e(t,t.InfiniteScroll,t.fizzyUIUtils)}(window,function(t,e,i){function n(t,e){this.element=t,this.infScroll=e,this.clickHandler=this.onClick.bind(this),this.element.addEventListener("click",this.clickHandler),e.on("request",this.disable.bind(this)),e.on("load",this.enable.bind(this)),e.on("error",this.hide.bind(this)),e.on("last",this.hide.bind(this))}return e.create.button=function(){var t=i.getQueryElement(this.options.button);if(t)return void(this.button=new n(t,this))},e.destroy.button=function(){this.button&&this.button.destroy()},n.prototype.onClick=function(t){t.preventDefault(),this.infScroll.loadNextPage()},n.prototype.enable=function(){this.element.removeAttribute("disabled")},n.prototype.disable=function(){this.element.disabled="disabled"},n.prototype.hide=function(){this.element.style.display="none"},n.prototype.destroy=function(){this.element.removeEventListener("click",this.clickHandler)},e.Button=n,e}),function(t,e){"function"==typeof define&&define.amd?define("infinite-scroll/js/status",["./core","fizzy-ui-utils/utils"],function(i,n){return e(t,i,n)}):"object"==typeof module&&module.exports?module.exports=e(t,require("./core"),require("fizzy-ui-utils")):e(t,t.InfiniteScroll,t.fizzyUIUtils)}(window,function(t,e,i){function n(t){r(t,"none")}function o(t){r(t,"block")}function r(t,e){t&&(t.style.display=e)}var s=e.prototype;return e.create.status=function(){var t=i.getQueryElement(this.options.status);t&&(this.statusElement=t,this.statusEventElements={request:t.querySelector(".infinite-scroll-request"),error:t.querySelector(".infinite-scroll-error"),last:t.querySelector(".infinite-scroll-last")},this.on("request",this.showRequestStatus),this.on("error",this.showErrorStatus),this.on("last",this.showLastStatus),this.bindHideStatus("on"))},s.bindHideStatus=function(t){var e=this.options.append?"append":"load";this[t](e,this.hideAllStatus)},s.showRequestStatus=function(){this.showStatus("request")},s.showErrorStatus=function(){this.showStatus("error")},s.showLastStatus=function(){this.showStatus("last"),this.bindHideStatus("off")},s.showStatus=function(t){o(this.statusElement),this.hideStatusEventElements();var e=this.statusEventElements[t];o(e)},s.hideAllStatus=function(){n(this.statusElement),this.hideStatusEventElements()},s.hideStatusEventElements=function(){for(var t in this.statusEventElements){var e=this.statusEventElements[t];n(e)}},e}),function(t,e){"function"==typeof define&&define.amd?define(["infinite-scroll/js/core","infinite-scroll/js/page-load","infinite-scroll/js/scroll-watch","infinite-scroll/js/history","infinite-scroll/js/button","infinite-scroll/js/status"],e):"object"==typeof module&&module.exports&&(module.exports=e(require("./core"),require("./page-load"),require("./scroll-watch"),require("./history"),require("./button"),require("./status")))}(window,function(t){return t}),function(t,e){"use strict";"function"==typeof define&&define.amd?define("imagesloaded/imagesloaded",["ev-emitter/ev-emitter"],function(i){return e(t,i)}):"object"==typeof module&&module.exports?module.exports=e(t,require("ev-emitter")):t.imagesLoaded=e(t,t.EvEmitter)}("undefined"!=typeof window?window:this,function(t,e){function i(t,e){for(var i in e)t[i]=e[i];return t}function n(t){if(Array.isArray(t))return t;var e="object"==typeof t&&"number"==typeof t.length;return e?h.call(t):[t]}function o(t,e,r){if(!(this instanceof o))return new o(t,e,r);var s=t;return"string"==typeof t&&(s=document.querySelectorAll(t)),s?(this.elements=n(s),this.options=i({},this.options),"function"==typeof e?r=e:i(this.options,e),r&&this.on("always",r),this.getImages(),l&&(this.jqDeferred=new l.Deferred),void setTimeout(this.check.bind(this))):void a.error("Bad element for imagesLoaded "+(s||t))}function r(t){this.img=t}function s(t,e){this.url=t,this.element=e,this.img=new Image}var l=t.jQuery,a=t.console,h=Array.prototype.slice;o.prototype=Object.create(e.prototype),o.prototype.options={},o.prototype.getImages=function(){this.images=[],this.elements.forEach(this.addElementImages,this)},o.prototype.addElementImages=function(t){"IMG"==t.nodeName&&this.addImage(t),this.options.background===!0&&this.addElementBackgroundImages(t);var e=t.nodeType;if(e&&c[e]){for(var i=t.querySelectorAll("img"),n=0;n=t&&u<=t+c+f&&o+h+a>=e&&o<=e+p+a){if(!n.appeared)n.trigger("appear",r.data)}else{n.appeared=false}};var o=function(){n.appeared=true;if(r.one){i.unbind("scroll",s);var o=e.inArray(s,e.fn.appear.checks);if(o>=0)e.fn.appear.checks.splice(o,1)}t.apply(this,arguments)};if(r.one)n.one("appear",r.data,o);else n.bind("appear",r.data,o);i.scroll(s);e.fn.appear.checks.push(s);s()})};e.extend(e.fn.appear,{checks:[],timeout:null,checkAll:function(){var t=e.fn.appear.checks.length;if(t>0)while(t--)e.fn.appear.checks[t]()},run:function(){if(e.fn.appear.timeout)clearTimeout(e.fn.appear.timeout);e.fn.appear.timeout=setTimeout(e.fn.appear.checkAll,20)}});e.each(["append","prepend","after","before","attr","removeAttr","addClass","removeClass","toggleClass","remove","css","show","hide"],function(t,n){var r=e.fn[n];if(r){e.fn[n]=function(){var t=r.apply(this,arguments);e.fn.appear.run();return t}}})})(jQuery); /*! jQuery scrollToTop v1.0 - 2013-03-15 (c) 2013 Yang Zhao - geniuscarrier.com license: http://www.opensource.org/licenses/mit-license.php */ !function(e){e.fn.scrollToTop=function(n){var o={speed:800};return n&&e.extend(o,{speed:n}),this.each(function(){var n=e(this);e(window).scroll(function(){e(this).scrollTop()>100?n.fadeIn():n.fadeOut()}),n.click(function(n){n.preventDefault(),e("body, html").animate({scrollTop:0},o.speed)})})}}(jQuery); !function(e){"function"==typeof define&&define.amd?define(["jquery"],e):"object"==typeof exports?module.exports=e(require("jquery")):e(jQuery)}(function(e){"use strict";var o=!1,t=!1,r=0,i=2e3,s=0,n=e,l=document,a=window,c=n(a),d=[];var u=a.requestAnimationFrame||a.webkitRequestAnimationFrame||a.mozRequestAnimationFrame||!1,h=a.cancelAnimationFrame||a.webkitCancelAnimationFrame||a.mozCancelAnimationFrame||!1;if(u)a.cancelAnimationFrame||(h=function(e){});else{var p=0;u=function(e,o){var t=(new Date).getTime(),r=Math.max(0,16-(t-p)),i=a.setTimeout(function(){e(t+r)},r);return p=t+r,i},h=function(e){a.clearTimeout(e)}}var m,f,g,v=a.MutationObserver||a.WebKitMutationObserver||!1,w=Date.now||function(){return(new Date).getTime()},b={zindex:"auto",cursoropacitymin:0,cursoropacitymax:1,cursorcolor:"#424242",cursorwidth:"6px",cursorborder:"1px solid #fff",cursorborderradius:"5px",scrollspeed:40,mousescrollstep:27,touchbehavior:!1,emulatetouch:!1,hwacceleration:!0,usetransition:!0,boxzoom:!1,dblclickzoom:!0,gesturezoom:!0,grabcursorenabled:!0,autohidemode:!0,background:"",iframeautoresize:!0,cursorminheight:32,preservenativescrolling:!0,railoffset:!1,railhoffset:!1,bouncescroll:!0,spacebarenabled:!0,railpadding:{top:0,right:0,left:0,bottom:0},disableoutline:!0,horizrailenabled:!0,railalign:"right",railvalign:"bottom",enabletranslate3d:!0,enablemousewheel:!0,enablekeyboard:!0,smoothscroll:!0,sensitiverail:!0,enablemouselockapi:!0,cursorfixedheight:!1,directionlockdeadzone:6,hidecursordelay:400,nativeparentscrolling:!0,enablescrollonselection:!0,overflowx:!0,overflowy:!0,cursordragspeed:.3,rtlmode:"auto",cursordragontouch:!1,oneaxismousemode:"auto",scriptpath:(f=l.currentScript||!!(m=l.getElementsByTagName("script")).length&&m[m.length-1],g=f?f.src.split("?")[0]:"",g.split("/").length>0?g.split("/").slice(0,-1).join("/")+"/":""),preventmultitouchscrolling:!0,disablemutationobserver:!1,enableobserver:!0,scrollbarid:!1,scrollCLass:!1},y=!1,x=function(e,p){var m=this;this.version="3.7.6",this.name="nicescroll",this.me=p;var f=n("body"),g=this.opt={doc:f,win:!1};if(n.extend(g,b),g.snapbackspeed=80,e)for(var x in g)void 0!==e[x]&&(g[x]=e[x]);if(g.disablemutationobserver&&(v=!1),this.doc=g.doc,this.iddoc=this.doc&&this.doc[0]&&this.doc[0].id||"",this.ispage=/^BODY|HTML/.test(g.win?g.win[0].nodeName:this.doc[0].nodeName),this.haswrapper=!1!==g.win,this.win=g.win||(this.ispage?c:this.doc),this.docscroll=this.ispage&&!this.haswrapper?c:this.win,this.body=f,this.viewport=!1,this.isfixed=!1,this.iframe=!1,this.isiframe="IFRAME"==this.doc[0].nodeName&&"IFRAME"==this.win[0].nodeName,this.istextarea="TEXTAREA"==this.win[0].nodeName,this.forcescreen=!1,this.canshowonmouseevent="scroll"!=g.autohidemode,this.onmousedown=!1,this.onmouseup=!1,this.onmousemove=!1,this.onmousewheel=!1,this.onkeypress=!1,this.ongesturezoom=!1,this.onclick=!1,this.onscrollstart=!1,this.onscrollend=!1,this.onscrollcancel=!1,this.onzoomin=!1,this.onzoomout=!1,this.view=!1,this.page=!1,this.scroll={x:0,y:0},this.scrollratio={x:0,y:0},this.cursorheight=20,this.scrollvaluemax=0,"auto"==g.rtlmode){var z=this.win[0]==a?this.body:this.win,k=z.css("writing-mode")||z.css("-webkit-writing-mode")||z.css("-ms-writing-mode")||z.css("-moz-writing-mode");"horizontal-tb"==k||"lr-tb"==k||""===k?(this.isrtlmode="rtl"==z.css("direction"),this.isvertical=!1):(this.isrtlmode="vertical-rl"==k||"tb"==k||"tb-rl"==k||"rl-tb"==k,this.isvertical="vertical-rl"==k||"tb"==k||"tb-rl"==k)}else this.isrtlmode=!0===g.rtlmode,this.isvertical=!1;if(this.scrollrunning=!1,this.scrollmom=!1,this.observer=!1,this.observerremover=!1,this.observerbody=!1,!1!==g.scrollbarid)this.id=g.scrollbarid;else do{this.id="ascrail"+i++}while(l.getElementById(this.id));this.rail=!1,this.cursor=!1,this.cursorfreezed=!1,this.selectiondrag=!1,this.zoom=!1,this.zoomactive=!1,this.hasfocus=!1,this.hasmousefocus=!1,this.railslocked=!1,this.locked=!1,this.hidden=!1,this.cursoractive=!0,this.wheelprevented=!1,this.overflowx=g.overflowx,this.overflowy=g.overflowy,this.nativescrollingarea=!1,this.checkarea=0,this.events=[],this.saved={},this.delaylist={},this.synclist={},this.lastdeltax=0,this.lastdeltay=0,this.detected=function(){if(y)return y;var e=l.createElement("DIV"),o=e.style,t=navigator.userAgent,r=navigator.platform,i={};return i.haspointerlock="pointerLockElement"in l||"webkitPointerLockElement"in l||"mozPointerLockElement"in l,i.isopera="opera"in a,i.isopera12=i.isopera&&"getUserMedia"in navigator,i.isoperamini="[object OperaMini]"===Object.prototype.toString.call(a.operamini),i.isie="all"in l&&"attachEvent"in e&&!i.isopera,i.isieold=i.isie&&!("msInterpolationMode"in o),i.isie7=i.isie&&!i.isieold&&(!("documentMode"in l)||7===l.documentMode),i.isie8=i.isie&&"documentMode"in l&&8===l.documentMode,i.isie9=i.isie&&"performance"in a&&9===l.documentMode,i.isie10=i.isie&&"performance"in a&&10===l.documentMode,i.isie11="msRequestFullscreen"in e&&l.documentMode>=11,i.ismsedge="msCredentials"in a,i.ismozilla="MozAppearance"in o,i.iswebkit=!i.ismsedge&&"WebkitAppearance"in o,i.ischrome=i.iswebkit&&"chrome"in a,i.ischrome38=i.ischrome&&"touchAction"in o,i.ischrome22=!i.ischrome38&&i.ischrome&&i.haspointerlock,i.ischrome26=!i.ischrome38&&i.ischrome&&"transition"in o,i.cantouch="ontouchstart"in l.documentElement||"ontouchstart"in a,i.hasw3ctouch=!!a.PointerEvent&&(navigator.maxTouchPoints>0||navigator.msMaxTouchPoints>0),i.hasmstouch=!i.hasw3ctouch&&(a.MSPointerEvent||!1),i.ismac=/^mac$/i.test(r),i.isios=i.cantouch&&/iphone|ipad|ipod/i.test(r),i.isios4=i.isios&&!("seal"in Object),i.isios7=i.isios&&"webkitHidden"in l,i.isios8=i.isios&&"hidden"in l,i.isios10=i.isios&&a.Proxy,i.isandroid=/android/i.test(t),i.haseventlistener="addEventListener"in e,i.trstyle=!1,i.hastransform=!1,i.hastranslate3d=!1,i.transitionstyle=!1,i.hastransition=!1,i.transitionend=!1,i.trstyle="transform",i.hastransform="transform"in o||function(){for(var e=["msTransform","webkitTransform","MozTransform","OTransform"],t=0,r=e.length;t=1?this.ed:this.st+this.df*o|0},update:function(e,o){return this.st=this.getNow(),this.ed=e,this.spd=o,this.ts=w(),this.df=this.ed-this.st,this}},this.ishwscroll){this.doc.translate={x:0,y:0,tx:"0px",ty:"0px"},T.hastranslate3d&&T.isios&&this.doc.css("-webkit-backface-visibility","hidden"),this.getScrollTop=function(e){if(!e){var o=L();if(o)return 16==o.length?-o[13]:-o[5];if(m.timerscroll&&m.timerscroll.bz)return m.timerscroll.bz.getNow()}return m.doc.translate.y},this.getScrollLeft=function(e){if(!e){var o=L();if(o)return 16==o.length?-o[12]:-o[4];if(m.timerscroll&&m.timerscroll.bh)return m.timerscroll.bh.getNow()}return m.doc.translate.x},this.notifyScrollEvent=function(e){var o=l.createEvent("UIEvents");o.initUIEvent("scroll",!1,!1,a,1),o.niceevent=!0,e.dispatchEvent(o)};var M=this.isrtlmode?1:-1;T.hastranslate3d&&g.enabletranslate3d?(this.setScrollTop=function(e,o){m.doc.translate.y=e,m.doc.translate.ty=-1*e+"px",m.doc.css(T.trstyle,"translate3d("+m.doc.translate.tx+","+m.doc.translate.ty+",0)"),o||m.notifyScrollEvent(m.win[0])},this.setScrollLeft=function(e,o){m.doc.translate.x=e,m.doc.translate.tx=e*M+"px",m.doc.css(T.trstyle,"translate3d("+m.doc.translate.tx+","+m.doc.translate.ty+",0)"),o||m.notifyScrollEvent(m.win[0])}):(this.setScrollTop=function(e,o){m.doc.translate.y=e,m.doc.translate.ty=-1*e+"px",m.doc.css(T.trstyle,"translate("+m.doc.translate.tx+","+m.doc.translate.ty+")"),o||m.notifyScrollEvent(m.win[0])},this.setScrollLeft=function(e,o){m.doc.translate.x=e,m.doc.translate.tx=e*M+"px",m.doc.css(T.trstyle,"translate("+m.doc.translate.tx+","+m.doc.translate.ty+")"),o||m.notifyScrollEvent(m.win[0])})}else this.getScrollTop=function(){return m.docscroll.scrollTop()},this.setScrollTop=function(e){m.docscroll.scrollTop(e)},this.getScrollLeft=function(){return m.hasreversehr?m.detected.ismozilla?m.page.maxw-Math.abs(m.docscroll.scrollLeft()):m.page.maxw-m.docscroll.scrollLeft():m.docscroll.scrollLeft()},this.setScrollLeft=function(e){return setTimeout(function(){if(m)return m.hasreversehr&&(e=m.detected.ismozilla?-(m.page.maxw-e):m.page.maxw-e),m.docscroll.scrollLeft(e)},1)};this.getTarget=function(e){return!!e&&(e.target?e.target:!!e.srcElement&&e.srcElement)},this.hasParent=function(e,o){if(!e)return!1;for(var t=e.target||e.srcElement||e||!1;t&&t.id!=o;)t=t.parentNode||!1;return!1!==t};var C={thin:1,medium:3,thick:5};function N(e,o,t){var r=e.css(o),i=parseFloat(r);if(isNaN(i)){var s=3==(i=C[r]||0)?t?m.win.outerHeight()-m.win.innerHeight():m.win.outerWidth()-m.win.innerWidth():1;return m.isie8&&i&&(i+=1),s?i:0}return i}this.getDocumentScrollOffset=function(){return{top:a.pageYOffset||l.documentElement.scrollTop,left:a.pageXOffset||l.documentElement.scrollLeft}},this.getOffset=function(){if(m.isfixed){var e=m.win.offset(),o=m.getDocumentScrollOffset();return e.top-=o.top,e.left-=o.left,e}var t=m.win.offset();if(!m.viewport)return t;var r=m.viewport.offset();return{top:t.top-r.top,left:t.left-r.left}},this.updateScrollBar=function(e){var o,t;if(m.ishwscroll)m.rail.css({height:m.win.innerHeight()-(g.railpadding.top+g.railpadding.bottom)}),m.railh&&m.railh.css({width:m.win.innerWidth()-(g.railpadding.left+g.railpadding.right)});else{var r=m.getOffset();if((o={top:r.top,left:r.left-(g.railpadding.left+g.railpadding.right)}).top+=N(m.win,"border-top-width",!0),o.left+=m.rail.align?m.win.outerWidth()-N(m.win,"border-right-width")-m.rail.width:N(m.win,"border-left-width"),(t=g.railoffset)&&(t.top&&(o.top+=t.top),t.left&&(o.left+=t.left)),m.railslocked||m.rail.css({top:o.top,left:o.left,height:(e?e.h:m.win.innerHeight())-(g.railpadding.top+g.railpadding.bottom)}),m.zoom&&m.zoom.css({top:o.top+1,left:1==m.rail.align?o.left-20:o.left+m.rail.width+4}),m.railh&&!m.railslocked){o={top:r.top,left:r.left},(t=g.railhoffset)&&(t.top&&(o.top+=t.top),t.left&&(o.left+=t.left));var i=m.railh.align?o.top+N(m.win,"border-top-width",!0)+m.win.innerHeight()-m.railh.height:o.top+N(m.win,"border-top-width",!0),s=o.left+N(m.win,"border-left-width");m.railh.css({top:i-(g.railpadding.top+g.railpadding.bottom),left:s,width:m.railh.width})}}},this.doRailClick=function(e,o,t){var r,i,s,n;m.railslocked||(m.cancelEvent(e),"pageY"in e||(e.pageX=e.clientX+l.documentElement.scrollLeft,e.pageY=e.clientY+l.documentElement.scrollTop),o?(r=t?m.doScrollLeft:m.doScrollTop,s=t?(e.pageX-m.railh.offset().left-m.cursorwidth/2)*m.scrollratio.x:(e.pageY-m.rail.offset().top-m.cursorheight/2)*m.scrollratio.y,m.unsynched("relativexy"),r(0|s)):(r=t?m.doScrollLeftBy:m.doScrollBy,s=t?m.scroll.x:m.scroll.y,n=t?e.pageX-m.railh.offset().left:e.pageY-m.rail.offset().top,i=t?m.view.w:m.view.h,r(s>=n?i:-i)))},m.newscrolly=m.newscrollx=0,m.hasanimationframe="requestAnimationFrame"in a,m.hascancelanimationframe="cancelAnimationFrame"in a,m.hasborderbox=!1,this.init=function(){if(m.saved.css=[],T.isoperamini)return!0;if(T.isandroid&&!("hidden"in l))return!0;g.emulatetouch=g.emulatetouch||g.touchbehavior,m.hasborderbox=a.getComputedStyle&&"border-box"===a.getComputedStyle(l.body)["box-sizing"];var e={"overflow-y":"hidden"};if((T.isie11||T.isie10)&&(e["-ms-overflow-style"]="none"),m.ishwscroll&&(this.doc.css(T.transitionstyle,T.prefixstyle+"transform 0ms ease-out"),T.transitionend&&m.bind(m.doc,T.transitionend,m.onScrollTransitionEnd,!1)),m.zindex="auto",m.ispage||"auto"!=g.zindex?m.zindex=g.zindex:m.zindex=function(){var e=m.win;if("zIndex"in e)return e.zIndex();for(;e.length>0;){if(9==e[0].nodeType)return!1;var o=e.css("zIndex");if(!isNaN(o)&&0!==o)return parseInt(o);e=e.parent()}return!1}()||"auto",!m.ispage&&"auto"!=m.zindex&&m.zindex>s&&(s=m.zindex),m.isie&&0===m.zindex&&"auto"==g.zindex&&(m.zindex="auto"),!m.ispage||!T.isieold){var i=m.docscroll;m.ispage&&(i=m.haswrapper?m.win:m.doc),m.css(i,e),m.ispage&&(T.isie11||T.isie)&&m.css(n("html"),e),!T.isios||m.ispage||m.haswrapper||m.css(f,{"-webkit-overflow-scrolling":"touch"});var d=n(l.createElement("div"));d.css({position:"relative",top:0,float:"right",width:g.cursorwidth,height:0,"background-color":g.cursorcolor,border:g.cursorborder,"background-clip":"padding-box","-webkit-border-radius":g.cursorborderradius,"-moz-border-radius":g.cursorborderradius,"border-radius":g.cursorborderradius}),d.addClass("nicescroll-cursors"),m.cursor=d;var u=n(l.createElement("div"));u.attr("id",m.id),u.addClass("nicescroll-rails nicescroll-rails-vr"),g.scrollCLass&&u.addClass(g.scrollCLass);var h,p,w=["left","right","top","bottom"];for(var b in w)p=w[b],(h=g.railpadding[p]||0)&&u.css("padding-"+p,h+"px");u.append(d),u.width=Math.max(parseFloat(g.cursorwidth),d.outerWidth()),u.css({width:u.width+"px",zIndex:m.zindex,background:g.background,cursor:"default"}),u.visibility=!0,u.scrollable=!0,u.align="left"==g.railalign?0:1,m.rail=u,m.rail.drag=!1;var y,x=!1;if(!g.boxzoom||m.ispage||T.isieold||(x=l.createElement("div"),m.bind(x,"click",m.doZoom),m.bind(x,"mouseenter",function(){m.zoom.css("opacity",g.cursoropacitymax)}),m.bind(x,"mouseleave",function(){m.zoom.css("opacity",g.cursoropacitymin)}),m.zoom=n(x),m.zoom.css({cursor:"pointer",zIndex:m.zindex,backgroundImage:"url("+g.scriptpath+"zoomico.png)",height:18,width:18,backgroundPosition:"0 0"}),g.dblclickzoom&&m.bind(m.win,"dblclick",m.doZoom),T.cantouch&&g.gesturezoom&&(m.ongesturezoom=function(e){return e.scale>1.5&&m.doZoomIn(e),e.scale<.8&&m.doZoomOut(e),m.cancelEvent(e)},m.bind(m.win,"gestureend",m.ongesturezoom))),m.railh=!1,g.horizrailenabled&&(m.css(i,{overflowX:"hidden"}),(d=n(l.createElement("div"))).css({position:"absolute",top:0,height:g.cursorwidth,width:0,backgroundColor:g.cursorcolor,border:g.cursorborder,backgroundClip:"padding-box","-webkit-border-radius":g.cursorborderradius,"-moz-border-radius":g.cursorborderradius,"border-radius":g.cursorborderradius}),T.isieold&&d.css("overflow","hidden"),d.addClass("nicescroll-cursors"),m.cursorh=d,(y=n(l.createElement("div"))).attr("id",m.id+"-hr"),y.addClass("nicescroll-rails nicescroll-rails-hr"),g.scrollCLass&&y.addClass(g.scrollCLass),y.height=Math.max(parseFloat(g.cursorwidth),d.outerHeight()),y.css({height:y.height+"px",zIndex:m.zindex,background:g.background}),y.append(d),y.visibility=!0,y.scrollable=!0,y.align="top"==g.railvalign?0:1,m.railh=y,m.railh.drag=!1),m.ispage)u.css({position:"fixed",top:0,height:"100%"}),u.css(u.align?{right:0}:{left:0}),m.body.append(u),m.railh&&(y.css({position:"fixed",left:0,width:"100%"}),y.css(y.align?{bottom:0}:{top:0}),m.body.append(y));else{if(m.ishwscroll){"static"==m.win.css("position")&&m.css(m.win,{position:"relative"});var z="HTML"==m.win[0].nodeName?m.body:m.win;n(z).scrollTop(0).scrollLeft(0),m.zoom&&(m.zoom.css({position:"absolute",top:1,right:0,"margin-right":u.width+4}),z.append(m.zoom)),u.css({position:"absolute",top:0}),u.css(u.align?{right:0}:{left:0}),z.append(u),y&&(y.css({position:"absolute",left:0,bottom:0}),y.css(y.align?{bottom:0}:{top:0}),z.append(y))}else{m.isfixed="fixed"==m.win.css("position");var k=m.isfixed?"fixed":"absolute";m.isfixed||(m.viewport=m.getViewport(m.win[0])),m.viewport&&(m.body=m.viewport,/fixed|absolute/.test(m.viewport.css("position"))||m.css(m.viewport,{position:"relative"})),u.css({position:k}),m.zoom&&m.zoom.css({position:k}),m.updateScrollBar(),m.body.append(u),m.zoom&&m.body.append(m.zoom),m.railh&&(y.css({position:k}),m.body.append(y))}T.isios&&m.css(m.win,{"-webkit-tap-highlight-color":"rgba(0,0,0,0)","-webkit-touch-callout":"none"}),g.disableoutline&&(T.isie&&m.win.attr("hideFocus","true"),T.iswebkit&&m.win.css("outline","none"))}if(!1===g.autohidemode?(m.autohidedom=!1,m.rail.css({opacity:g.cursoropacitymax}),m.railh&&m.railh.css({opacity:g.cursoropacitymax})):!0===g.autohidemode||"leave"===g.autohidemode?(m.autohidedom=n().add(m.rail),T.isie8&&(m.autohidedom=m.autohidedom.add(m.cursor)),m.railh&&(m.autohidedom=m.autohidedom.add(m.railh)),m.railh&&T.isie8&&(m.autohidedom=m.autohidedom.add(m.cursorh))):"scroll"==g.autohidemode?(m.autohidedom=n().add(m.rail),m.railh&&(m.autohidedom=m.autohidedom.add(m.railh))):"cursor"==g.autohidemode?(m.autohidedom=n().add(m.cursor),m.railh&&(m.autohidedom=m.autohidedom.add(m.cursorh))):"hidden"==g.autohidemode&&(m.autohidedom=!1,m.hide(),m.railslocked=!1),T.cantouch||m.istouchcapable||g.emulatetouch||T.hasmstouch){m.scrollmom=new S(m);m.ontouchstart=function(e){if(m.locked)return!1;if(e.pointerType&&("mouse"===e.pointerType||e.pointerType===e.MSPOINTER_TYPE_MOUSE))return!1;if(m.hasmoving=!1,m.scrollmom.timer&&(m.triggerScrollEnd(),m.scrollmom.stop()),!m.railslocked){var o=m.getTarget(e);if(o)if(/INPUT/i.test(o.nodeName)&&/range/i.test(o.type))return m.stopPropagation(e);var t="mousedown"===e.type;if(!("clientX"in e)&&"changedTouches"in e&&(e.clientX=e.changedTouches[0].clientX,e.clientY=e.changedTouches[0].clientY),m.forcescreen){var r=e;(e={original:e.original?e.original:e}).clientX=r.screenX,e.clientY=r.screenY}if(m.rail.drag={x:e.clientX,y:e.clientY,sx:m.scroll.x,sy:m.scroll.y,st:m.getScrollTop(),sl:m.getScrollLeft(),pt:2,dl:!1,tg:o},m.ispage||!g.directionlockdeadzone)m.rail.drag.dl="f";else{var i={w:c.width(),h:c.height()},s=m.getContentSize(),l=s.h-i.h,a=s.w-i.w;m.rail.scrollable&&!m.railh.scrollable?m.rail.drag.ck=l>0&&"v":!m.rail.scrollable&&m.railh.scrollable?m.rail.drag.ck=a>0&&"h":m.rail.drag.ck=!1}if(g.emulatetouch&&m.isiframe&&T.isie){var d=m.win.position();m.rail.drag.x+=d.left,m.rail.drag.y+=d.top}if(m.hasmoving=!1,m.lastmouseup=!1,m.scrollmom.reset(e.clientX,e.clientY),o&&t){if(!/INPUT|SELECT|BUTTON|TEXTAREA/i.test(o.nodeName))return T.hasmousecapture&&o.setCapture(),g.emulatetouch?(o.onclick&&!o._onclick&&(o._onclick=o.onclick,o.onclick=function(e){if(m.hasmoving)return!1;o._onclick.call(this,e)}),m.cancelEvent(e)):m.stopPropagation(e);/SUBMIT|CANCEL|BUTTON/i.test(n(o).attr("type"))&&(m.preventclick={tg:o,click:!1})}}},m.ontouchend=function(e){if(!m.rail.drag)return!0;if(2==m.rail.drag.pt){if(e.pointerType&&("mouse"===e.pointerType||e.pointerType===e.MSPOINTER_TYPE_MOUSE))return!1;m.rail.drag=!1;var o="mouseup"===e.type;if(m.hasmoving&&(m.scrollmom.doMomentum(),m.lastmouseup=!0,m.hideCursor(),T.hasmousecapture&&l.releaseCapture(),o))return m.cancelEvent(e)}else if(1==m.rail.drag.pt)return m.onmouseup(e)};var E=g.emulatetouch&&m.isiframe&&!T.hasmousecapture,L=.3*g.directionlockdeadzone|0;m.ontouchmove=function(e,o){if(!m.rail.drag)return!0;if(e.targetTouches&&g.preventmultitouchscrolling&&e.targetTouches.length>1)return!0;if(e.pointerType&&("mouse"===e.pointerType||e.pointerType===e.MSPOINTER_TYPE_MOUSE))return!0;if(2==m.rail.drag.pt){var t,r;if("changedTouches"in e&&(e.clientX=e.changedTouches[0].clientX,e.clientY=e.changedTouches[0].clientY),r=t=0,E&&!o){var i=m.win.position();r=-i.left,t=-i.top}var s=e.clientY+t,n=s-m.rail.drag.y,a=e.clientX+r,c=a-m.rail.drag.x,d=m.rail.drag.st-n;if(m.ishwscroll&&g.bouncescroll)d<0?d=Math.round(d/2):d>m.page.maxh&&(d=m.page.maxh+Math.round((d-m.page.maxh)/2));else if(d<0?(d=0,s=0):d>m.page.maxh&&(d=m.page.maxh,s=0),0===s&&!m.hasmoving)return m.ispage||(m.rail.drag=!1),!0;var u=m.getScrollLeft();if(m.railh&&m.railh.scrollable&&(u=m.isrtlmode?c-m.rail.drag.sl:m.rail.drag.sl-c,m.ishwscroll&&g.bouncescroll?u<0?u=Math.round(u/2):u>m.page.maxw&&(u=m.page.maxw+Math.round((u-m.page.maxw)/2)):(u<0&&(u=0,a=0),u>m.page.maxw&&(u=m.page.maxw,a=0))),!m.hasmoving){if(m.rail.drag.y===e.clientY&&m.rail.drag.x===e.clientX)return m.cancelEvent(e);var h=Math.abs(n),p=Math.abs(c),f=g.directionlockdeadzone;if(m.rail.drag.ck?"v"==m.rail.drag.ck?p>f&&h<=L?m.rail.drag=!1:h>f&&(m.rail.drag.dl="v"):"h"==m.rail.drag.ck&&(h>f&&p<=L?m.rail.drag=!1:p>f&&(m.rail.drag.dl="h")):h>f&&p>f?m.rail.drag.dl="f":h>f?m.rail.drag.dl=p>L?"f":"v":p>f&&(m.rail.drag.dl=h>L?"f":"h"),!m.rail.drag.dl)return m.cancelEvent(e);m.triggerScrollStart(e.clientX,e.clientY,0,0,0),m.hasmoving=!0}return m.preventclick&&!m.preventclick.click&&(m.preventclick.click=m.preventclick.tg.onclick||!1,m.preventclick.tg.onclick=m.onpreventclick),m.rail.drag.dl&&("v"==m.rail.drag.dl?u=m.rail.drag.sl:"h"==m.rail.drag.dl&&(d=m.rail.drag.st)),m.synched("touchmove",function(){m.rail.drag&&2==m.rail.drag.pt&&(m.prepareTransition&&m.resetTransition(),m.rail.scrollable&&m.setScrollTop(d),m.scrollmom.update(a,s),m.railh&&m.railh.scrollable?(m.setScrollLeft(u),m.showCursor(d,u)):m.showCursor(d),T.isie10&&l.selection.clear())}),m.cancelEvent(e)}return 1==m.rail.drag.pt?m.onmousemove(e):void 0},m.ontouchstartCursor=function(e,o){if(!m.rail.drag||3==m.rail.drag.pt){if(m.locked)return m.cancelEvent(e);m.cancelScroll(),m.rail.drag={x:e.touches[0].clientX,y:e.touches[0].clientY,sx:m.scroll.x,sy:m.scroll.y,pt:3,hr:!!o};var t=m.getTarget(e);return!m.ispage&&T.hasmousecapture&&t.setCapture(),m.isiframe&&!T.hasmousecapture&&(m.saved.csspointerevents=m.doc.css("pointer-events"),m.css(m.doc,{"pointer-events":"none"})),m.cancelEvent(e)}},m.ontouchendCursor=function(e){if(m.rail.drag){if(T.hasmousecapture&&l.releaseCapture(),m.isiframe&&!T.hasmousecapture&&m.doc.css("pointer-events",m.saved.csspointerevents),3!=m.rail.drag.pt)return;return m.rail.drag=!1,m.cancelEvent(e)}},m.ontouchmoveCursor=function(e){if(m.rail.drag){if(3!=m.rail.drag.pt)return;if(m.cursorfreezed=!0,m.rail.drag.hr){m.scroll.x=m.rail.drag.sx+(e.touches[0].clientX-m.rail.drag.x),m.scroll.x<0&&(m.scroll.x=0);var o=m.scrollvaluemaxw;m.scroll.x>o&&(m.scroll.x=o)}else{m.scroll.y=m.rail.drag.sy+(e.touches[0].clientY-m.rail.drag.y),m.scroll.y<0&&(m.scroll.y=0);var t=m.scrollvaluemax;m.scroll.y>t&&(m.scroll.y=t)}return m.synched("touchmove",function(){m.rail.drag&&3==m.rail.drag.pt&&(m.showCursor(),m.rail.drag.hr?m.doScrollLeft(Math.round(m.scroll.x*m.scrollratio.x),g.cursordragspeed):m.doScrollTop(Math.round(m.scroll.y*m.scrollratio.y),g.cursordragspeed))}),m.cancelEvent(e)}}}if(m.onmousedown=function(e,o){if(!m.rail.drag||1==m.rail.drag.pt){if(m.railslocked)return m.cancelEvent(e);m.cancelScroll(),m.rail.drag={x:e.clientX,y:e.clientY,sx:m.scroll.x,sy:m.scroll.y,pt:1,hr:o||!1};var t=m.getTarget(e);return T.hasmousecapture&&t.setCapture(),m.isiframe&&!T.hasmousecapture&&(m.saved.csspointerevents=m.doc.css("pointer-events"),m.css(m.doc,{"pointer-events":"none"})),m.hasmoving=!1,m.cancelEvent(e)}},m.onmouseup=function(e){if(m.rail.drag)return 1!=m.rail.drag.pt||(T.hasmousecapture&&l.releaseCapture(),m.isiframe&&!T.hasmousecapture&&m.doc.css("pointer-events",m.saved.csspointerevents),m.rail.drag=!1,m.cursorfreezed=!1,m.hasmoving&&m.triggerScrollEnd(),m.cancelEvent(e))},m.onmousemove=function(e){if(m.rail.drag){if(1!==m.rail.drag.pt)return;if(T.ischrome&&0===e.which)return m.onmouseup(e);if(m.cursorfreezed=!0,m.hasmoving||m.triggerScrollStart(e.clientX,e.clientY,0,0,0),m.hasmoving=!0,m.rail.drag.hr){m.scroll.x=m.rail.drag.sx+(e.clientX-m.rail.drag.x),m.scroll.x<0&&(m.scroll.x=0);var o=m.scrollvaluemaxw;m.scroll.x>o&&(m.scroll.x=o)}else{m.scroll.y=m.rail.drag.sy+(e.clientY-m.rail.drag.y),m.scroll.y<0&&(m.scroll.y=0);var t=m.scrollvaluemax;m.scroll.y>t&&(m.scroll.y=t)}return m.synched("mousemove",function(){m.cursorfreezed&&(m.showCursor(),m.rail.drag.hr?m.scrollLeft(Math.round(m.scroll.x*m.scrollratio.x)):m.scrollTop(Math.round(m.scroll.y*m.scrollratio.y)))}),m.cancelEvent(e)}m.checkarea=0},T.cantouch||g.emulatetouch)m.onpreventclick=function(e){if(m.preventclick)return m.preventclick.tg.onclick=m.preventclick.click,m.preventclick=!1,m.cancelEvent(e)},m.onclick=!T.isios&&function(e){return!m.lastmouseup||(m.lastmouseup=!1,m.cancelEvent(e))},g.grabcursorenabled&&T.cursorgrabvalue&&(m.css(m.ispage?m.doc:m.win,{cursor:T.cursorgrabvalue}),m.css(m.rail,{cursor:T.cursorgrabvalue}));else{var M=function(e){if(m.selectiondrag){if(e){var o=m.win.outerHeight(),t=e.pageY-m.selectiondrag.top;t>0&&t=o&&(t-=o),m.selectiondrag.df=t}if(0!==m.selectiondrag.df){var r=-2*m.selectiondrag.df/6|0;m.doScrollBy(r),m.debounced("doselectionscroll",function(){M()},50)}}};m.hasTextSelected="getSelection"in l?function(){return l.getSelection().rangeCount>0}:"selection"in l?function(){return"None"!=l.selection.type}:function(){return!1},m.onselectionstart=function(e){m.ispage||(m.selectiondrag=m.win.offset())},m.onselectionend=function(e){m.selectiondrag=!1},m.onselectiondrag=function(e){m.selectiondrag&&m.hasTextSelected()&&m.debounced("selectionscroll",function(){M(e)},250)}}if(T.hasw3ctouch?(m.css(m.ispage?n("html"):m.win,{"touch-action":"none"}),m.css(m.rail,{"touch-action":"none"}),m.css(m.cursor,{"touch-action":"none"}),m.bind(m.win,"pointerdown",m.ontouchstart),m.bind(l,"pointerup",m.ontouchend),m.delegate(l,"pointermove",m.ontouchmove)):T.hasmstouch?(m.css(m.ispage?n("html"):m.win,{"-ms-touch-action":"none"}),m.css(m.rail,{"-ms-touch-action":"none"}),m.css(m.cursor,{"-ms-touch-action":"none"}),m.bind(m.win,"MSPointerDown",m.ontouchstart),m.bind(l,"MSPointerUp",m.ontouchend),m.delegate(l,"MSPointerMove",m.ontouchmove),m.bind(m.cursor,"MSGestureHold",function(e){e.preventDefault()}),m.bind(m.cursor,"contextmenu",function(e){e.preventDefault()})):T.cantouch&&(m.bind(m.win,"touchstart",m.ontouchstart,!1,!0),m.bind(l,"touchend",m.ontouchend,!1,!0),m.bind(l,"touchcancel",m.ontouchend,!1,!0),m.delegate(l,"touchmove",m.ontouchmove,!1,!0)),g.emulatetouch&&(m.bind(m.win,"mousedown",m.ontouchstart,!1,!0),m.bind(l,"mouseup",m.ontouchend,!1,!0),m.bind(l,"mousemove",m.ontouchmove,!1,!0)),(g.cursordragontouch||!T.cantouch&&!g.emulatetouch)&&(m.rail.css({cursor:"default"}),m.railh&&m.railh.css({cursor:"default"}),m.jqbind(m.rail,"mouseenter",function(){if(!m.ispage&&!m.win.is(":visible"))return!1;m.canshowonmouseevent&&m.showCursor(),m.rail.active=!0}),m.jqbind(m.rail,"mouseleave",function(){m.rail.active=!1,m.rail.drag||m.hideCursor()}),g.sensitiverail&&(m.bind(m.rail,"click",function(e){m.doRailClick(e,!1,!1)}),m.bind(m.rail,"dblclick",function(e){m.doRailClick(e,!0,!1)}),m.bind(m.cursor,"click",function(e){m.cancelEvent(e)}),m.bind(m.cursor,"dblclick",function(e){m.cancelEvent(e)})),m.railh&&(m.jqbind(m.railh,"mouseenter",function(){if(!m.ispage&&!m.win.is(":visible"))return!1;m.canshowonmouseevent&&m.showCursor(),m.rail.active=!0}),m.jqbind(m.railh,"mouseleave",function(){m.rail.active=!1,m.rail.drag||m.hideCursor()}),g.sensitiverail&&(m.bind(m.railh,"click",function(e){m.doRailClick(e,!1,!0)}),m.bind(m.railh,"dblclick",function(e){m.doRailClick(e,!0,!0)}),m.bind(m.cursorh,"click",function(e){m.cancelEvent(e)}),m.bind(m.cursorh,"dblclick",function(e){m.cancelEvent(e)})))),g.cursordragontouch&&(this.istouchcapable||T.cantouch)&&(m.bind(m.cursor,"touchstart",m.ontouchstartCursor),m.bind(m.cursor,"touchmove",m.ontouchmoveCursor),m.bind(m.cursor,"touchend",m.ontouchendCursor),m.cursorh&&m.bind(m.cursorh,"touchstart",function(e){m.ontouchstartCursor(e,!0)}),m.cursorh&&m.bind(m.cursorh,"touchmove",m.ontouchmoveCursor),m.cursorh&&m.bind(m.cursorh,"touchend",m.ontouchendCursor)),g.emulatetouch||T.isandroid||T.isios?(m.bind(T.hasmousecapture?m.win:l,"mouseup",m.ontouchend),m.onclick&&m.bind(l,"click",m.onclick),g.cursordragontouch?(m.bind(m.cursor,"mousedown",m.onmousedown),m.bind(m.cursor,"mouseup",m.onmouseup),m.cursorh&&m.bind(m.cursorh,"mousedown",function(e){m.onmousedown(e,!0)}),m.cursorh&&m.bind(m.cursorh,"mouseup",m.onmouseup)):(m.bind(m.rail,"mousedown",function(e){e.preventDefault()}),m.railh&&m.bind(m.railh,"mousedown",function(e){e.preventDefault()}))):(m.bind(T.hasmousecapture?m.win:l,"mouseup",m.onmouseup),m.bind(l,"mousemove",m.onmousemove),m.onclick&&m.bind(l,"click",m.onclick),m.bind(m.cursor,"mousedown",m.onmousedown),m.bind(m.cursor,"mouseup",m.onmouseup),m.railh&&(m.bind(m.cursorh,"mousedown",function(e){m.onmousedown(e,!0)}),m.bind(m.cursorh,"mouseup",m.onmouseup)),!m.ispage&&g.enablescrollonselection&&(m.bind(m.win[0],"mousedown",m.onselectionstart),m.bind(l,"mouseup",m.onselectionend),m.bind(m.cursor,"mouseup",m.onselectionend),m.cursorh&&m.bind(m.cursorh,"mouseup",m.onselectionend),m.bind(l,"mousemove",m.onselectiondrag)),m.zoom&&(m.jqbind(m.zoom,"mouseenter",function(){m.canshowonmouseevent&&m.showCursor(),m.rail.active=!0}),m.jqbind(m.zoom,"mouseleave",function(){m.rail.active=!1,m.rail.drag||m.hideCursor()}))),g.enablemousewheel&&(m.isiframe||m.mousewheel(T.isie&&m.ispage?l:m.win,m.onmousewheel),m.mousewheel(m.rail,m.onmousewheel),m.railh&&m.mousewheel(m.railh,m.onmousewheelhr)),m.ispage||T.cantouch||/HTML|^BODY/.test(m.win[0].nodeName)||(m.win.attr("tabindex")||m.win.attr({tabindex:++r}),m.bind(m.win,"focus",function(e){o=m.getTarget(e).id||m.getTarget(e)||!1,m.hasfocus=!0,m.canshowonmouseevent&&m.noticeCursor()}),m.bind(m.win,"blur",function(e){o=!1,m.hasfocus=!1}),m.bind(m.win,"mouseenter",function(e){t=m.getTarget(e).id||m.getTarget(e)||!1,m.hasmousefocus=!0,m.canshowonmouseevent&&m.noticeCursor()}),m.bind(m.win,"mouseleave",function(e){t=!1,m.hasmousefocus=!1,m.rail.drag||m.hideCursor()})),m.onkeypress=function(e){if(m.railslocked&&0===m.page.maxh)return!0;e=e||a.event;var r=m.getTarget(e);if(r&&/INPUT|TEXTAREA|SELECT|OPTION/.test(r.nodeName)&&(!(r.getAttribute("type")||r.type||!1)||!/submit|button|cancel/i.tp))return!0;if(n(r).attr("contenteditable"))return!0;if(m.hasfocus||m.hasmousefocus&&!o||m.ispage&&!o&&!t){var i=e.keyCode;if(m.railslocked&&27!=i)return m.cancelEvent(e);var s=e.ctrlKey||!1,l=e.shiftKey||!1,c=!1;switch(i){case 38:case 63233:m.doScrollBy(72),c=!0;break;case 40:case 63235:m.doScrollBy(-72),c=!0;break;case 37:case 63232:m.railh&&(s?m.doScrollLeft(0):m.doScrollLeftBy(72),c=!0);break;case 39:case 63234:m.railh&&(s?m.doScrollLeft(m.page.maxw):m.doScrollLeftBy(-72),c=!0);break;case 33:case 63276:m.doScrollBy(m.view.h),c=!0;break;case 34:case 63277:m.doScrollBy(-m.view.h),c=!0;break;case 36:case 63273:m.railh&&s?m.doScrollPos(0,0):m.doScrollTo(0),c=!0;break;case 35:case 63275:m.railh&&s?m.doScrollPos(m.page.maxw,m.page.maxh):m.doScrollTo(m.page.maxh),c=!0;break;case 32:g.spacebarenabled&&(l?m.doScrollBy(m.view.h):m.doScrollBy(-m.view.h),c=!0);break;case 27:m.zoomactive&&(m.doZoom(),c=!0)}if(c)return m.cancelEvent(e)}},g.enablekeyboard&&m.bind(l,T.isopera&&!T.isopera12?"keypress":"keydown",m.onkeypress),m.bind(l,"keydown",function(e){(e.ctrlKey||!1)&&(m.wheelprevented=!0)}),m.bind(l,"keyup",function(e){e.ctrlKey||!1||(m.wheelprevented=!1)}),m.bind(a,"blur",function(e){m.wheelprevented=!1}),m.bind(a,"resize",m.onscreenresize),m.bind(a,"orientationchange",m.onscreenresize),m.bind(a,"load",m.lazyResize),T.ischrome&&!m.ispage&&!m.haswrapper){var C=m.win.attr("style"),N=parseFloat(m.win.css("width"))+1;m.win.css("width",N),m.synched("chromefix",function(){m.win.attr("style",C)})}if(m.onAttributeChange=function(e){m.lazyResize(m.isieold?250:30)},g.enableobserver&&(m.isie11||!1===v||(m.observerbody=new v(function(e){if(e.forEach(function(e){if("attributes"==e.type)return f.hasClass("modal-open")&&f.hasClass("modal-dialog")&&!n.contains(n(".modal-dialog")[0],m.doc[0])?m.hide():m.show()}),m.me.clientWidth!=m.page.width||m.me.clientHeight!=m.page.height)return m.lazyResize(30)}),m.observerbody.observe(l.body,{childList:!0,subtree:!0,characterData:!1,attributes:!0,attributeFilter:["class"]})),!m.ispage&&!m.haswrapper)){var P=m.win[0];!1!==v?(m.observer=new v(function(e){e.forEach(m.onAttributeChange)}),m.observer.observe(P,{childList:!0,characterData:!1,attributes:!0,subtree:!1}),m.observerremover=new v(function(e){e.forEach(function(e){if(e.removedNodes.length>0)for(var o in e.removedNodes)if(m&&e.removedNodes[o]===P)return m.remove()})}),m.observerremover.observe(P.parentNode,{childList:!0,characterData:!1,attributes:!1,subtree:!1})):(m.bind(P,T.isie&&!T.isie9?"propertychange":"DOMAttrModified",m.onAttributeChange),T.isie9&&P.attachEvent("onpropertychange",m.onAttributeChange),m.bind(P,"DOMNodeRemoved",function(e){e.target===P&&m.remove()}))}!m.ispage&&g.boxzoom&&m.bind(a,"resize",m.resizeZoom),m.istextarea&&(m.bind(m.win,"keydown",m.lazyResize),m.bind(m.win,"mouseup",m.lazyResize)),m.lazyResize(30)}if("IFRAME"==this.doc[0].nodeName){var R=function(){var o;m.iframexd=!1;try{(o="contentDocument"in this?this.contentDocument:this.contentWindow._doc).domain}catch(e){m.iframexd=!0,o=!1}if(m.iframexd)return"console"in a&&console.log("NiceScroll error: policy restriced iframe"),!0;if(m.forcescreen=!0,m.isiframe&&(m.iframe={doc:n(o),html:m.doc.contents().find("html")[0],body:m.doc.contents().find("body")[0]},m.getContentSize=function(){return{w:Math.max(m.iframe.html.scrollWidth,m.iframe.body.scrollWidth),h:Math.max(m.iframe.html.scrollHeight,m.iframe.body.scrollHeight)}},m.docscroll=n(m.iframe.body)),!T.isios&&g.iframeautoresize&&!m.isiframe){m.win.scrollTop(0),m.doc.height("");var t=Math.max(o.getElementsByTagName("html")[0].scrollHeight,o.body.scrollHeight);m.doc.height(t)}m.lazyResize(30),m.css(n(m.iframe.body),e),T.isios&&m.haswrapper&&m.css(n(o.body),{"-webkit-transform":"translate3d(0,0,0)"}),"contentWindow"in this?m.bind(this.contentWindow,"scroll",m.onscroll):m.bind(o,"scroll",m.onscroll),g.enablemousewheel&&m.mousewheel(o,m.onmousewheel),g.enablekeyboard&&m.bind(o,T.isopera?"keypress":"keydown",m.onkeypress),T.cantouch?(m.bind(o,"touchstart",m.ontouchstart),m.bind(o,"touchmove",m.ontouchmove)):g.emulatetouch&&(m.bind(o,"mousedown",m.ontouchstart),m.bind(o,"mousemove",function(e){return m.ontouchmove(e,!0)}),g.grabcursorenabled&&T.cursorgrabvalue&&m.css(n(o.body),{cursor:T.cursorgrabvalue})),m.bind(o,"mouseup",m.ontouchend),m.zoom&&(g.dblclickzoom&&m.bind(o,"dblclick",m.doZoom),m.ongesturezoom&&m.bind(o,"gestureend",m.ongesturezoom))};this.doc[0].readyState&&"complete"===this.doc[0].readyState&&setTimeout(function(){R.call(m.doc[0],!1)},500),m.bind(this.doc,"load",R)}},this.showCursor=function(e,o){if(m.cursortimeout&&(clearTimeout(m.cursortimeout),m.cursortimeout=0),m.rail){if(m.autohidedom&&(m.autohidedom.stop().css({opacity:g.cursoropacitymax}),m.cursoractive=!0),m.rail.drag&&1==m.rail.drag.pt||(void 0!==e&&!1!==e&&(m.scroll.y=e/m.scrollratio.y|0),void 0!==o&&(m.scroll.x=o/m.scrollratio.x|0)),m.cursor.css({height:m.cursorheight,top:m.scroll.y}),m.cursorh){var t=m.hasreversehr?m.scrollvaluemaxw-m.scroll.x:m.scroll.x;m.cursorh.css({width:m.cursorwidth,left:!m.rail.align&&m.rail.visibility?t+m.rail.width:t}),m.cursoractive=!0}m.zoom&&m.zoom.stop().css({opacity:g.cursoropacitymax})}},this.hideCursor=function(e){m.cursortimeout||m.rail&&m.autohidedom&&(m.hasmousefocus&&"leave"===g.autohidemode||(m.cursortimeout=setTimeout(function(){m.rail.active&&m.showonmouseevent||(m.autohidedom.stop().animate({opacity:g.cursoropacitymin}),m.zoom&&m.zoom.stop().animate({opacity:g.cursoropacitymin}),m.cursoractive=!1),m.cursortimeout=0},e||g.hidecursordelay)))},this.noticeCursor=function(e,o,t){m.showCursor(o,t),m.rail.active||m.hideCursor(e)},this.getContentSize=m.ispage?function(){return{w:Math.max(l.body.scrollWidth,l.documentElement.scrollWidth),h:Math.max(l.body.scrollHeight,l.documentElement.scrollHeight)}}:m.haswrapper?function(){return{w:m.doc[0].offsetWidth,h:m.doc[0].offsetHeight}}:function(){return{w:m.docscroll[0].scrollWidth,h:m.docscroll[0].scrollHeight}},this.onResize=function(e,o){if(!m||!m.win)return!1;var t=m.page.maxh,r=m.page.maxw,i=m.view.h,s=m.view.w;if(m.view={w:m.ispage?m.win.width():m.win[0].clientWidth,h:m.ispage?m.win.height():m.win[0].clientHeight},m.page=o||m.getContentSize(),m.page.maxh=Math.max(0,m.page.h-m.view.h),m.page.maxw=Math.max(0,m.page.w-m.view.w),m.page.maxh==t&&m.page.maxw==r&&m.view.w==s&&m.view.h==i){if(m.ispage)return m;var n=m.win.offset();if(m.lastposition){var l=m.lastposition;if(l.top==n.top&&l.left==n.left)return m}m.lastposition=n}return 0===m.page.maxh?(m.hideRail(),m.scrollvaluemax=0,m.scroll.y=0,m.scrollratio.y=0,m.cursorheight=0,m.setScrollTop(0),m.rail&&(m.rail.scrollable=!1)):(m.page.maxh-=g.railpadding.top+g.railpadding.bottom,m.rail.scrollable=!0),0===m.page.maxw?(m.hideRailHr(),m.scrollvaluemaxw=0,m.scroll.x=0,m.scrollratio.x=0,m.cursorwidth=0,m.setScrollLeft(0),m.railh&&(m.railh.scrollable=!1)):(m.page.maxw-=g.railpadding.left+g.railpadding.right,m.railh&&(m.railh.scrollable=g.horizrailenabled)),m.railslocked=m.locked||0===m.page.maxh&&0===m.page.maxw,m.railslocked?(m.ispage||m.updateScrollBar(m.view),!1):(m.hidden||(m.rail.visibility||m.showRail(),m.railh&&!m.railh.visibility&&m.showRailHr()),m.istextarea&&m.win.css("resize")&&"none"!=m.win.css("resize")&&(m.view.h-=20),m.cursorheight=Math.min(m.view.h,Math.round(m.view.h*(m.view.h/m.page.h))),m.cursorheight=g.cursorfixedheight?g.cursorfixedheight:Math.max(g.cursorminheight,m.cursorheight),m.cursorwidth=Math.min(m.view.w,Math.round(m.view.w*(m.view.w/m.page.w))),m.cursorwidth=g.cursorfixedheight?g.cursorfixedheight:Math.max(g.cursorminheight,m.cursorwidth),m.scrollvaluemax=m.view.h-m.cursorheight-(g.railpadding.top+g.railpadding.bottom),m.hasborderbox||(m.scrollvaluemax-=m.cursor[0].offsetHeight-m.cursor[0].clientHeight),m.railh&&(m.railh.width=m.page.maxh>0?m.view.w-m.rail.width:m.view.w,m.scrollvaluemaxw=m.railh.width-m.cursorwidth-(g.railpadding.left+g.railpadding.right)),m.ispage||m.updateScrollBar(m.view),m.scrollratio={x:m.page.maxw/m.scrollvaluemaxw,y:m.page.maxh/m.scrollvaluemax},m.getScrollTop()>m.page.maxh?m.doScrollTop(m.page.maxh):(m.scroll.y=m.getScrollTop()/m.scrollratio.y|0,m.scroll.x=m.getScrollLeft()/m.scrollratio.x|0,m.cursoractive&&m.noticeCursor()),m.scroll.y&&0===m.getScrollTop()&&m.doScrollTo(m.scroll.y*m.scrollratio.y|0),m)},this.resize=m.onResize;var P=0;function R(e,o,t,r){m._bind(e,o,function(r){var i={original:r=r||a.event,target:r.target||r.srcElement,type:"wheel",deltaMode:"MozMousePixelScroll"==r.type?0:1,deltaX:0,deltaZ:0,preventDefault:function(){return r.preventDefault?r.preventDefault():r.returnValue=!1,!1},stopImmediatePropagation:function(){r.stopImmediatePropagation?r.stopImmediatePropagation():r.cancelBubble=!0}};return"mousewheel"==o?(r.wheelDeltaX&&(i.deltaX=-.025*r.wheelDeltaX),r.wheelDeltaY&&(i.deltaY=-.025*r.wheelDeltaY),!i.deltaY&&!i.deltaX&&(i.deltaY=-.025*r.wheelDelta)):i.deltaY=r.detail,t.call(e,i)},r)}this.onscreenresize=function(e){clearTimeout(P);var o=!m.ispage&&!m.haswrapper;o&&m.hideRails(),P=setTimeout(function(){m&&(o&&m.showRails(),m.resize()),P=0},120)},this.lazyResize=function(e){return clearTimeout(P),e=isNaN(e)?240:e,P=setTimeout(function(){m&&m.resize(),P=0},e),m},this.jqbind=function(e,o,t){m.events.push({e:e,n:o,f:t,q:!0}),n(e).on(o,t)},this.mousewheel=function(e,o,t){var r="jquery"in e?e[0]:e;if("onwheel"in l.createElement("div"))m._bind(r,"wheel",o,t||!1);else{var i=void 0!==l.onmousewheel?"mousewheel":"DOMMouseScroll";R(r,i,o,t||!1),"DOMMouseScroll"==i&&R(r,"MozMousePixelScroll",o,t||!1)}};var _=!1;if(T.haseventlistener){try{var I=Object.defineProperty({},"passive",{get:function(){_=!0}});a.addEventListener("test",null,I)}catch(e){}this.stopPropagation=function(e){return!!e&&((e=e.original?e.original:e).stopPropagation(),!1)},this.cancelEvent=function(e){return e.cancelable&&e.preventDefault(),e.stopImmediatePropagation(),e.preventManipulation&&e.preventManipulation(),!1}}else Event.prototype.preventDefault=function(){this.returnValue=!1},Event.prototype.stopPropagation=function(){this.cancelBubble=!0},a.constructor.prototype.addEventListener=l.constructor.prototype.addEventListener=Element.prototype.addEventListener=function(e,o,t){this.attachEvent("on"+e,o)},a.constructor.prototype.removeEventListener=l.constructor.prototype.removeEventListener=Element.prototype.removeEventListener=function(e,o,t){this.detachEvent("on"+e,o)},this.cancelEvent=function(e){return(e=e||a.event)&&(e.cancelBubble=!0,e.cancel=!0,e.returnValue=!1),!1},this.stopPropagation=function(e){return(e=e||a.event)&&(e.cancelBubble=!0),!1};this.delegate=function(e,o,t,r,i){var s=d[o]||!1;s||(s={a:[],l:[],f:function(e){for(var o=s.l,t=!1,r=o.length-1;r>=0;r--)if(!1===(t=o[r].call(e.target,e)))return!1;return t}},m.bind(e,o,s.f,r,i),d[o]=s),m.ispage?(s.a=[m.id].concat(s.a),s.l=[t].concat(s.l)):(s.a.push(m.id),s.l.push(t))},this.undelegate=function(e,o,t,r,i){var s=d[o]||!1;if(s&&s.l)for(var n=0,l=s.l.length;n0)return t;o=!!o.parentNode&&o.parentNode}return!1},this.triggerScrollStart=function(e,o,t,r,i){if(m.onscrollstart){var s={type:"scrollstart",current:{x:e,y:o},request:{x:t,y:r},end:{x:m.newscrollx,y:m.newscrolly},speed:i};m.onscrollstart.call(m,s)}},this.triggerScrollEnd=function(){if(m.onscrollend){var e=m.getScrollLeft(),o=m.getScrollTop(),t={type:"scrollend",current:{x:e,y:o},end:{x:e,y:o}};m.onscrollend.call(m,t)}};var O=0,Y=0,H=0,B=1;function X(e,o,t,r){m.scrollrunning||(m.newscrolly=m.getScrollTop(),m.newscrollx=m.getScrollLeft(),H=w());var i=w()-H;if(H=w(),i>350?B=1:B+=(2-B)/10,o=o*B|0,e=e*B|0){if(r)if(e<0){if(m.getScrollLeft()>=m.page.maxw)return!0}else if(m.getScrollLeft()<=0)return!0;var s=e>0?1:-1;Y!==s&&(m.scrollmom&&m.scrollmom.stop(),m.newscrollx=m.getScrollLeft(),Y=s),m.lastdeltax-=e}if(o){if(function(){var e=m.getScrollTop();if(o<0){if(e>=m.page.maxh)return!0}else if(e<=0)return!0}()){if(g.nativeparentscrolling&&t&&!m.ispage&&!m.zoomactive)return!0;var n=m.view.h>>1;m.newscrolly<-n?(m.newscrolly=-n,o=-1):m.newscrolly>m.page.maxh+n?(m.newscrolly=m.page.maxh+n,o=1):o=0}var l=o>0?1:-1;O!==l&&(m.scrollmom&&m.scrollmom.stop(),m.newscrolly=m.getScrollTop(),O=l),m.lastdeltay-=o}(o||e)&&m.synched("relativexy",function(){var e=m.lastdeltay+m.newscrolly;m.lastdeltay=0;var o=m.lastdeltax+m.newscrollx;m.lastdeltax=0,m.rail.drag||m.doScrollPos(o,e)})}var D=!1;function A(e,o,t){var r,i;if(!t&&D)return!0;(0===e.deltaMode?(r=-e.deltaX*(g.mousescrollstep/54)|0,i=-e.deltaY*(g.mousescrollstep/54)|0):1===e.deltaMode&&(r=-e.deltaX*g.mousescrollstep*50/80|0,i=-e.deltaY*g.mousescrollstep*50/80|0),o&&g.oneaxismousemode&&0===r&&i)&&(r=i,i=0,t&&(r<0?m.getScrollLeft()>=m.page.maxw:m.getScrollLeft()<=0)&&(i=r,r=0));if(m.isrtlmode&&(r=-r),!X(r,i,t,!0))return D=!1,e.stopImmediatePropagation(),e.preventDefault();t&&(D=!0)}if(this.onmousewheel=function(e){if(m.wheelprevented||m.locked)return!1;if(m.railslocked)return m.debounced("checkunlock",m.resize,250),!1;if(m.rail.drag)return m.cancelEvent(e);if("auto"===g.oneaxismousemode&&0!==e.deltaX&&(g.oneaxismousemode=!1),g.oneaxismousemode&&0===e.deltaX&&!m.rail.scrollable)return!m.railh||!m.railh.scrollable||m.onmousewheelhr(e);var o=w(),t=!1;if(g.preservenativescrolling&&m.checkarea+600m.page.maxh&&(o=m.page.maxh+(o-m.page.maxh)/2|0),e<0?e=e/2|0:e>m.page.maxw&&(e=m.page.maxw+(e-m.page.maxw)/2|0)):(o<0?o=0:o>m.page.maxh&&(o=m.page.maxh),e<0?e=0:e>m.page.maxw&&(e=m.page.maxw)),m.scrollrunning&&e==m.newscrollx&&o==m.newscrolly)return!1;m.newscrolly=o,m.newscrollx=e;var s=m.getScrollTop(),n=m.getScrollLeft(),l={};l.x=e-n,l.y=o-s;var a=0|Math.sqrt(l.x*l.x+l.y*l.y),c=m.prepareTransition(a);m.scrollrunning||(m.scrollrunning=!0,m.triggerScrollStart(n,s,e,o,c),m.cursorupdate.start()),m.scrollendtrapped=!0,T.transitionend||(m.scrollendtrapped&&clearTimeout(m.scrollendtrapped),m.scrollendtrapped=setTimeout(m.onScrollTransitionEnd,c)),m.setScrollTop(m.newscrolly),m.setScrollLeft(m.newscrollx)},this.cancelScroll=function(){if(!m.scrollendtrapped)return!0;var e=m.getScrollTop(),o=m.getScrollLeft();return m.scrollrunning=!1,T.transitionend||clearTimeout(T.transitionend),m.scrollendtrapped=!1,m.resetTransition(),m.setScrollTop(e),m.railh&&m.setScrollLeft(o),m.timerscroll&&m.timerscroll.tm&&clearInterval(m.timerscroll.tm),m.timerscroll=!1,m.cursorfreezed=!1,m.cursorupdate.stop(),m.showCursor(e,o),m},this.onScrollTransitionEnd=function(){if(m.scrollendtrapped){var e=m.getScrollTop(),o=m.getScrollLeft();if(e<0?e=0:e>m.page.maxh&&(e=m.page.maxh),o<0?o=0:o>m.page.maxw&&(o=m.page.maxw),e!=m.newscrolly||o!=m.newscrollx)return m.doScrollPos(o,e,g.snapbackspeed);m.scrollrunning&&m.triggerScrollEnd(),m.scrollrunning=!1,m.scrollendtrapped=!1,m.resetTransition(),m.timerscroll=!1,m.setScrollTop(e),m.railh&&m.setScrollLeft(o),m.cursorupdate.stop(),m.noticeCursor(!1,e,o),m.cursorfreezed=!1}}}else this.doScrollLeft=function(e,o){var t=m.scrollrunning?m.newscrolly:m.getScrollTop();m.doScrollPos(e,t,o)},this.doScrollTop=function(e,o){var t=m.scrollrunning?m.newscrollx:m.getScrollLeft();m.doScrollPos(t,e,o)},this.doScrollPos=function(e,o,t){var r=m.getScrollTop(),i=m.getScrollLeft();((m.newscrolly-r)*(o-r)<0||(m.newscrollx-i)*(e-i)<0)&&m.cancelScroll();var s=!1;if(m.bouncescroll&&m.rail.visibility||(o<0?(o=0,s=!0):o>m.page.maxh&&(o=m.page.maxh,s=!0)),m.bouncescroll&&m.railh.visibility||(e<0?(e=0,s=!0):e>m.page.maxw&&(e=m.page.maxw,s=!0)),m.scrollrunning&&m.newscrolly===o&&m.newscrollx===e)return!0;m.newscrolly=o,m.newscrollx=e,m.dst={},m.dst.x=e-i,m.dst.y=o-r,m.dst.px=i,m.dst.py=r;var n=0|Math.sqrt(m.dst.x*m.dst.x+m.dst.y*m.dst.y),l=m.getTransitionSpeed(n);m.bzscroll={};var a=s?1:.58;m.bzscroll.x=new E(i,m.newscrollx,l,0,0,a,1),m.bzscroll.y=new E(r,m.newscrolly,l,0,0,a,1);w();var c=function(){if(m.scrollrunning){var e=m.bzscroll.y.getPos();m.setScrollLeft(m.bzscroll.x.getNow()),m.setScrollTop(m.bzscroll.y.getNow()),e<=1?m.timer=u(c):(m.scrollrunning=!1,m.timer=0,m.triggerScrollEnd())}};m.scrollrunning||(m.triggerScrollStart(i,r,e,o,l),m.scrollrunning=!0,m.timer=u(c))},this.cancelScroll=function(){return m.timer&&h(m.timer),m.timer=0,m.bzscroll=!1,m.scrollrunning=!1,m};else this.doScrollLeft=function(e,o){var t=m.getScrollTop();m.doScrollPos(e,t,o)},this.doScrollTop=function(e,o){var t=m.getScrollLeft();m.doScrollPos(t,e,o)},this.doScrollPos=function(e,o,t){var r=e>m.page.maxw?m.page.maxw:e;r<0&&(r=0);var i=o>m.page.maxh?m.page.maxh:o;i<0&&(i=0),m.synched("scroll",function(){m.setScrollTop(i),m.setScrollLeft(r)})},this.cancelScroll=function(){};this.doScrollBy=function(e,o){X(0,e)},this.doScrollLeftBy=function(e,o){X(e,0)},this.doScrollTo=function(e,o){var t=o?Math.round(e*m.scrollratio.y):e;t<0?t=0:t>m.page.maxh&&(t=m.page.maxh),m.cursorfreezed=!1,m.doScrollTop(e)},this.checkContentSize=function(){var e=m.getContentSize();e.h==m.page.h&&e.w==m.page.w||m.resize(!1,e)},m.onscroll=function(e){m.rail.drag||m.cursorfreezed||m.synched("scroll",function(){m.scroll.y=Math.round(m.getScrollTop()/m.scrollratio.y),m.railh&&(m.scroll.x=Math.round(m.getScrollLeft()/m.scrollratio.x)),m.noticeCursor()})},m.bind(m.docscroll,"scroll",m.onscroll),this.doZoomIn=function(e){if(!m.zoomactive){m.zoomactive=!0,m.zoomrestore={style:{}};var o=["position","top","left","zIndex","backgroundColor","marginTop","marginBottom","marginLeft","marginRight"],t=m.win[0].style;for(var r in o){var i=o[r];m.zoomrestore.style[i]=void 0!==t[i]?t[i]:""}m.zoomrestore.style.width=m.win.css("width"),m.zoomrestore.style.height=m.win.css("height"),m.zoomrestore.padding={w:m.win.outerWidth()-m.win.width(),h:m.win.outerHeight()-m.win.height()},T.isios4&&(m.zoomrestore.scrollTop=c.scrollTop(),c.scrollTop(0)),m.win.css({position:T.isios4?"absolute":"fixed",top:0,left:0,zIndex:s+100,margin:0});var n=m.win.css("backgroundColor");return(""===n||/transparent|rgba\(0, 0, 0, 0\)|rgba\(0,0,0,0\)/.test(n))&&m.win.css("backgroundColor","#fff"),m.rail.css({zIndex:s+101}),m.zoom.css({zIndex:s+102}),m.zoom.css("backgroundPosition","0 -18px"),m.resizeZoom(),m.onzoomin&&m.onzoomin.call(m),m.cancelEvent(e)}},this.doZoomOut=function(e){if(m.zoomactive)return m.zoomactive=!1,m.win.css("margin",""),m.win.css(m.zoomrestore.style),T.isios4&&c.scrollTop(m.zoomrestore.scrollTop),m.rail.css({"z-index":m.zindex}),m.zoom.css({"z-index":m.zindex}),m.zoomrestore=!1,m.zoom.css("backgroundPosition","0 0"),m.onResize(),m.onzoomout&&m.onzoomout.call(m),m.cancelEvent(e)},this.doZoom=function(e){return m.zoomactive?m.doZoomOut(e):m.doZoomIn(e)},this.resizeZoom=function(){if(m.zoomactive){var e=m.getScrollTop();m.win.css({width:c.width()-m.zoomrestore.padding.w+"px",height:c.height()-m.zoomrestore.padding.h+"px"}),m.onResize(),m.setScrollTop(Math.min(m.page.maxh,e))}},this.init(),n.nicescroll.push(this)},S=function(e){var o=this;this.nc=e,this.lastx=0,this.lasty=0,this.speedx=0,this.speedy=0,this.lasttime=0,this.steptime=0,this.snapx=!1,this.snapy=!1,this.demulx=0,this.demuly=0,this.lastscrollx=-1,this.lastscrolly=-1,this.chkx=0,this.chky=0,this.timer=0,this.reset=function(e,t){o.stop(),o.steptime=0,o.lasttime=w(),o.speedx=0,o.speedy=0,o.lastx=e,o.lasty=t,o.lastscrollx=-1,o.lastscrolly=-1},this.update=function(e,t){var r=w();o.steptime=r-o.lasttime,o.lasttime=r;var i=t-o.lasty,s=e-o.lastx,n=o.nc.getScrollTop()+i,l=o.nc.getScrollLeft()+s;o.snapx=l<0||l>o.nc.page.maxw,o.snapy=n<0||n>o.nc.page.maxh,o.speedx=s,o.speedy=i,o.lastx=e,o.lasty=t},this.stop=function(){o.nc.unsynched("domomentum2d"),o.timer&&clearTimeout(o.timer),o.timer=0,o.lastscrollx=-1,o.lastscrolly=-1},this.doSnapy=function(e,t){var r=!1;t<0?(t=0,r=!0):t>o.nc.page.maxh&&(t=o.nc.page.maxh,r=!0),e<0?(e=0,r=!0):e>o.nc.page.maxw&&(e=o.nc.page.maxw,r=!0),r?o.nc.doScrollPos(e,t,o.nc.opt.snapbackspeed):o.nc.triggerScrollEnd()},this.doMomentum=function(e){var t=w(),r=e?t+e:o.lasttime,i=o.nc.getScrollLeft(),s=o.nc.getScrollTop(),n=o.nc.page.maxh,l=o.nc.page.maxw;o.speedx=l>0?Math.min(60,o.speedx):0,o.speedy=n>0?Math.min(60,o.speedy):0;var a=r&&t-r<=60;(s<0||s>n||i<0||i>l)&&(a=!1);var c=!(!o.speedy||!a)&&o.speedy,d=!(!o.speedx||!a)&&o.speedx;if(c||d){var u=Math.max(16,o.steptime);if(u>50){var h=u/50;o.speedx*=h,o.speedy*=h,u=50}o.demulxy=0,o.lastscrollx=o.nc.getScrollLeft(),o.chkx=o.lastscrollx,o.lastscrolly=o.nc.getScrollTop(),o.chky=o.lastscrolly;var p=o.lastscrollx,m=o.lastscrolly,f=function(){var e=w()-t>600?.04:.02;o.speedx&&(p=Math.floor(o.lastscrollx-o.speedx*(1-o.demulxy)),o.lastscrollx=p,(p<0||p>l)&&(e=.1)),o.speedy&&(m=Math.floor(o.lastscrolly-o.speedy*(1-o.demulxy)),o.lastscrolly=m,(m<0||m>n)&&(e=.1)),o.demulxy=Math.min(1,o.demulxy+e),o.nc.synched("domomentum2d",function(){if(o.speedx){o.nc.getScrollLeft();o.chkx=p,o.nc.setScrollLeft(p)}if(o.speedy){o.nc.getScrollTop();o.chky=m,o.nc.setScrollTop(m)}o.timer||(o.nc.hideCursor(),o.doSnapy(p,m))}),o.demulxy<1?o.timer=setTimeout(f,u):(o.stop(),o.nc.hideCursor(),o.doSnapy(p,m))};f()}else o.doSnapy(o.nc.getScrollLeft(),o.nc.getScrollTop())}},z=e.fn.scrollTop;e.cssHooks.pageYOffset={get:function(e,o,t){var r=n.data(e,"__nicescroll")||!1;return r&&r.ishwscroll?r.getScrollTop():z.call(e)},set:function(e,o){var t=n.data(e,"__nicescroll")||!1;return t&&t.ishwscroll?t.setScrollTop(parseInt(o)):z.call(e,o),this}},e.fn.scrollTop=function(e){if(void 0===e){var o=this[0]&&n.data(this[0],"__nicescroll")||!1;return o&&o.ishwscroll?o.getScrollTop():z.call(this)}return this.each(function(){var o=n.data(this,"__nicescroll")||!1;o&&o.ishwscroll?o.setScrollTop(parseInt(e)):z.call(n(this),e)})};var k=e.fn.scrollLeft;n.cssHooks.pageXOffset={get:function(e,o,t){var r=n.data(e,"__nicescroll")||!1;return r&&r.ishwscroll?r.getScrollLeft():k.call(e)},set:function(e,o){var t=n.data(e,"__nicescroll")||!1;return t&&t.ishwscroll?t.setScrollLeft(parseInt(o)):k.call(e,o),this}},e.fn.scrollLeft=function(e){if(void 0===e){var o=this[0]&&n.data(this[0],"__nicescroll")||!1;return o&&o.ishwscroll?o.getScrollLeft():k.call(this)}return this.each(function(){var o=n.data(this,"__nicescroll")||!1;o&&o.ishwscroll?o.setScrollLeft(parseInt(e)):k.call(n(this),e)})};var T=function(e){var o=this;if(this.length=0,this.name="nicescrollarray",this.each=function(e){return n.each(o,e),o},this.push=function(e){o[o.length]=e,o.length++},this.eq=function(e){return o[e]},e)for(var t=0;t1?n(e,r):s,i.win=r}!("doc"in i)||"win"in i||(i.win=r);var l=r.data("__nicescroll")||!1;l||(i.doc=i.doc||r,l=new x(i,r),r.data("__nicescroll",l)),t.push(l)}),1===t.length?t[0]:t},a.NiceScroll={getjQuery:function(){return e}},n.nicescroll||(n.nicescroll=new T,n.nicescroll.options=b)}); /*! * Isotope PACKAGED v3.0.6 * * Licensed GPLv3 for open source use * or Isotope Commercial License for commercial use * * https://isotope.metafizzy.co * Copyright 2010-2018 Metafizzy */ !function(t,e){"function"==typeof define&&define.amd?define("jquery-bridget/jquery-bridget",["jquery"],function(i){return e(t,i)}):"object"==typeof module&&module.exports?module.exports=e(t,require("jquery")):t.jQueryBridget=e(t,t.jQuery)}(window,function(t,e){"use strict";function i(i,s,a){function u(t,e,o){var n,s="$()."+i+'("'+e+'")';return t.each(function(t,u){var h=a.data(u,i);if(!h)return void r(i+" not initialized. Cannot call methods, i.e. "+s);var d=h[e];if(!d||"_"==e.charAt(0))return void r(s+" is not a valid method");var l=d.apply(h,o);n=void 0===n?l:n}),void 0!==n?n:t}function h(t,e){t.each(function(t,o){var n=a.data(o,i);n?(n.option(e),n._init()):(n=new s(o,e),a.data(o,i,n))})}a=a||e||t.jQuery,a&&(s.prototype.option||(s.prototype.option=function(t){a.isPlainObject(t)&&(this.options=a.extend(!0,this.options,t))}),a.fn[i]=function(t){if("string"==typeof t){var e=n.call(arguments,1);return u(this,t,e)}return h(this,t),this},o(a))}function o(t){!t||t&&t.bridget||(t.bridget=i)}var n=Array.prototype.slice,s=t.console,r="undefined"==typeof s?function(){}:function(t){s.error(t)};return o(e||t.jQuery),i}),function(t,e){"function"==typeof define&&define.amd?define("ev-emitter/ev-emitter",e):"object"==typeof module&&module.exports?module.exports=e():t.EvEmitter=e()}("undefined"!=typeof window?window:this,function(){function t(){}var e=t.prototype;return e.on=function(t,e){if(t&&e){var i=this._events=this._events||{},o=i[t]=i[t]||[];return o.indexOf(e)==-1&&o.push(e),this}},e.once=function(t,e){if(t&&e){this.on(t,e);var i=this._onceEvents=this._onceEvents||{},o=i[t]=i[t]||{};return o[e]=!0,this}},e.off=function(t,e){var i=this._events&&this._events[t];if(i&&i.length){var o=i.indexOf(e);return o!=-1&&i.splice(o,1),this}},e.emitEvent=function(t,e){var i=this._events&&this._events[t];if(i&&i.length){i=i.slice(0),e=e||[];for(var o=this._onceEvents&&this._onceEvents[t],n=0;n