/* jquery.timers.js */
jquery.fn.extend({everytime:function(e,t,n,r,i){return this.each(function(){jquery.timer.add(this,e,t,n,r,i)})},onetime:function(e,t,n){return this.each(function(){jquery.timer.add(this,e,t,n,1)})},stoptime:function(e,t){return this.each(function(){jquery.timer.remove(this,e,t)})}});jquery.extend({timer:{guid:1,global:{},regex:/^([0-9]+)\s*(.*s)?$/,powers:{ms:1,cs:10,ds:100,s:1e3,das:1e4,hs:1e5,ks:1e6},timeparse:function(e){if(e==undefined||e==null)return null;var t=this.regex.exec(jquery.trim(e.tostring()));if(t[2]){var n=parseint(t[1],10);var r=this.powers[t[2]]||1;return n*r}else{return e}},add:function(e,t,n,r,i,s){var o=0;if(jquery.isfunction(n)){if(!i)i=r;r=n;n=t}t=jquery.timer.timeparse(t);if(typeof t!="number"||isnan(t)||t<=0)return;if(i&&i.constructor!=number){s=!!i;i=0}i=i||0;s=s||false;if(!e.$timers)e.$timers={};if(!e.$timers[n])e.$timers[n]={};r.$timerid=r.$timerid||this.guid++;var u=function(){if(s&&this.inprogress)return;this.inprogress=true;if(++o>i&&i!==0||r.call(e,o)===false)jquery.timer.remove(e,n,r);this.inprogress=false};u.$timerid=r.$timerid;if(!e.$timers[n][r.$timerid])e.$timers[n][r.$timerid]=window.setinterval(u,t);if(!this.global[n])this.global[n]=[];this.global[n].push(e)},remove:function(e,t,n){var r=e.$timers,i;if(r){if(!t){for(t in r)this.remove(e,t,n)}else if(r[t]){if(n){if(n.$timerid){window.clearinterval(r[t][n.$timerid]);delete r[t][n.$timerid]}}else{for(var n in r[t]){window.clearinterval(r[t][n]);delete r[t][n]}}for(i in r[t])break;if(!i){i=null;delete r[t]}}for(i in r)break;if(!i)e.$timers=null}}}});
/* jquery.scrollto */
;(function(a){if(typeof define==='function'&&define.amd){define(['jquery'],a)}else{a(jquery)}}(function($){var j=$.scrollto=function(a,b,c){return $(window).scrollto(a,b,c)};j.defaults={axis:'xy',duration:parsefloat($.fn.jquery)>=1.3?0:1,limit:true};j.window=function(a){return $(window)._scrollable()};$.fn._scrollable=function(){return this.map(function(){var a=this,iswin=!a.nodename||$.inarray(a.nodename.tolowercase(),['iframe','#document','html','body'])!=-1;if(!iswin)return a;var b=(a.contentwindow||a).document||a.ownerdocument||a;return/webkit/i.test(navigator.useragent)||b.compatmode=='backcompat'?b.body:b.documentelement})};$.fn.scrollto=function(f,g,h){if(typeof g=='object'){h=g;g=0}if(typeof h=='function')h={onafter:h};if(f=='max')f=9e9;h=$.extend({},j.defaults,h);g=g||h.duration;h.queue=h.queue&&h.axis.length>1;if(h.queue)g/=2;h.offset=both(h.offset);h.over=both(h.over);return this._scrollable().each(function(){if(f==null)return;var d=this,$elem=$(d),targ=f,toff,attr={},win=$elem.is('html,body');switch(typeof targ){case'number':case'string':if(/^([+-]=?)?\d+(\.\d+)?(px|%)?$/.test(targ)){targ=both(targ);break}targ=$(targ,this);if(!targ.length)return;case'object':if(targ.is||targ.style)toff=(targ=$(targ)).offset()}var e=$.isfunction(h.offset)&&h.offset(d,targ)||h.offset;$.each(h.axis.split(''),function(i,a){var b=a=='x'?'left':'top',pos=b.tolowercase(),key='scroll'+b,old=d[key],max=j.max(d,a);if(toff){attr[key]=toff[pos]+(win?0:old-$elem.offset()[pos]);if(h.margin){attr[key]-=parseint(targ.css('margin'+b))||0;attr[key]-=parseint(targ.css('border'+b+'width'))||0}attr[key]+=e[pos]||0;if(h.over[pos])attr[key]+=targ[a=='x'?'width':'height']()*h.over[pos]}else{var c=targ[pos];attr[key]=c.slice&&c.slice(-1)=='%'?parsefloat(c)/100*max:c}if(h.limit&&/^\d+$/.test(attr[key]))attr[key]=attr[key]<=0?0:math.min(attr[key],max);if(!i&&h.queue){if(old!=attr[key])animate(h.onafterfirst);delete attr[key]}});animate(h.onafter);function animate(a){$elem.animate(attr,g,h.easing,a&&function(){a.call(this,targ,h)})}}).end()};j.max=function(a,b){var c=b=='x'?'width':'height',scroll='scroll'+c;if(!$(a).is('html,body'))return a[scroll]-$(a)[c.tolowercase()]();var d='client'+c,html=a.ownerdocument.documentelement,body=a.ownerdocument.body;return math.max(html[scroll],body[scroll])-math.min(html[d],body[d])};function both(a){return $.isfunction(a)||typeof a=='object'?a:{top:a,left:a}};return j}));
/* jquery.imageloader */
(function(e){e.imageloader=function(t){var n=e.extend({urls:[],oncomplete:function(){},onupdate:function(e,t){},onerror:function(e){}},t);var r=0,i=[],s=n.urls,o=s.length;e.each(s,function(t,i){var u=new image,a=false;u.src=i;u.onerror=function(){r++;n.onerror("error loading image: "+i)};e("").attr("src",i).load(function(e){r++;n.onupdate(r/o,s[r-1]);if(r===o)n.oncomplete()})})}})(jquery)
/* modernizr.js */
/* modernizr 2.6.2 (custom build) | mit & bsd */
;window.modernizr=function(a,b,c){function b(a){j.csstext=a}function c(a,b){return b(m.join(a+";")+(b||""))}function d(a,b){return typeof a===b}function e(a,b){return!!~(""+a).indexof(b)}function f(a,b){for(var d in a){var e=a[d];if(!e(e,"-")&&j[e]!==c)return b=="pfx"?e:!0}return!1}function g(a,b,d){for(var e in a){var f=b[a[e]];if(f!==c)return d===!1?a[e]:d(f,"function")?f.bind(d||b):f}return!1}function h(a,b,c){var d=a.charat(0).touppercase()+a.slice(1),e=(a+" "+o.join(d+" ")+d).split(" ");return d(b,"string")||d(b,"undefined")?f(e,b):(e=(a+" "+p.join(d+" ")+d).split(" "),g(e,b,c))}var d="2.6.2",e={},f=!0,g=b.documentelement,h="modernizr",i=b.createelement(h),j=i.style,k,l={}.tostring,m=" -webkit- -moz- -o- -ms- ".split(" "),n="webkit moz o ms",o=n.split(" "),p=n.tolowercase().split(" "),q={svg:"http://www.w3.org/2000/svg"},r={},s={},t={},u=[],v=u.slice,w,x=function(a,c,d,e){var f,i,j,k,l=b.createelement("div"),m=b.body,n=m||b.createelement("body");if(parseint(d,10))while(d--)j=b.createelement("div"),j.id=e?e[d]:h+(d+1),l.appendchild(j);return f=["",'"].join(""),l.id=h,(m?l:n).innerhtml+=f,n.appendchild(l),m||(n.style.background="",n.style.overflow="hidden",k=g.style.overflow,g.style.overflow="hidden",g.appendchild(n)),i=c(l,a),m?l.parentnode.removechild(l):(n.parentnode.removechild(n),g.style.overflow=k),!!i},y=function(){function d(d,e){e=e||b.createelement(a[d]||"div"),d="on"+d;var f=d in e;return f||(e.setattribute||(e=b.createelement("div")),e.setattribute&&e.removeattribute&&(e.setattribute(d,""),f=d(e[d],"function"),d(e[d],"undefined")||(e[d]=c),e.removeattribute(d))),e=null,f}var a={select:"input",change:"input",submit:"form",reset:"form",error:"img",load:"img",abort:"img"};return d}(),z={}.hasownproperty,a;!d(z,"undefined")&&!d(z.call,"undefined")?a=function(a,b){return z.call(a,b)}:a=function(a,b){return b in a&&d(a.constructor.prototype[b],"undefined")},function.prototype.bind||(function.prototype.bind=function(b){var c=this;if(typeof c!="function")throw new typeerror;var d=v.call(arguments,1),e=function(){if(this instanceof e){var a=function(){};a.prototype=c.prototype;var f=new a,g=c.apply(f,d.concat(v.call(arguments)));return object(g)===g?g:f}return c.apply(b,d.concat(v.call(arguments)))};return e}),r.canvas=function(){var a=b.createelement("canvas");return!!a.getcontext&&!!a.getcontext("2d")},r.webgl=function(){return!!a.webglrenderingcontext},r.touch=function(){var c;return"ontouchstart"in a||a.documenttouch&&b instanceof documenttouch?c=!0:x(["@media (",m.join("touch-enabled),("),h,")","{#modernizr{top:9px;position:absolute}}"].join(""),function(a){c=a.offsettop===9}),c},r.geolocation=function(){return"geolocation"in navigator},r.rgba=function(){return b("background-color:rgba(150,255,150,.5)"),e(j.backgroundcolor,"rgba")},r.backgroundsize=function(){return h("backgroundsize")},r.borderradius=function(){return h("borderradius")},r.boxshadow=function(){return h("boxshadow")},r.textshadow=function(){return b.createelement("div").style.textshadow===""},r.fontface=function(){var a;return x('@font-face {font-family:"font";src:url("https://")}',function(c,d){var e=b.getelementbyid("smodernizr"),f=e.sheet||e.stylesheet,g=f?f.cssrules&&f.cssrules[0]?f.cssrules[0].csstext:f.csstext||"":"";a=/src/i.test(g)&&g.indexof(d.split(" ")[0])===0}),a},r.video=function(){var a=b.createelement("video"),c=!1;try{if(c=!!a.canplaytype)c=new boolean(c),c.ogg=a.canplaytype('video/ogg; codecs="theora"').replace(/^no$/,""),c.h264=a.canplaytype('video/mp4; codecs="avc1.42e01e"').replace(/^no$/,""),c.webm=a.canplaytype('video/webm; codecs="vp8, vorbis"').replace(/^no$/,"")}catch(d){}return c},r.audio=function(){var a=b.createelement("audio"),c=!1;try{if(c=!!a.canplaytype)c=new boolean(c),c.ogg=a.canplaytype('audio/ogg; codecs="vorbis"').replace(/^no$/,""),c.mp3=a.canplaytype("audio/mpeg;").replace(/^no$/,""),c.wav=a.canplaytype('audio/wav; codecs="1"').replace(/^no$/,""),c.m4a=(a.canplaytype("audio/x-m4a;")||a.canplaytype("audio/aac;")).replace(/^no$/,"")}catch(d){}return c},r.applicationcache=function(){return!!a.applicationcache},r.svg=function(){return!!b.createelementns&&!!b.createelementns(q.svg,"svg").createsvgrect},r.inlinesvg=function(){var a=b.createelement("div");return a.innerhtml="",(a.firstchild&&a.firstchild.namespaceuri)==q.svg},r.svgclippaths=function(){return!!b.createelementns&&/svgclippath/.test(l.call(b.createelementns(q.svg,"clippath")))};for(var i in r)a(r,i)&&(w=i.tolowercase(),e[w]=r[i](),u.push((e[w]?"":"no-")+w));return e.addtest=function(a,b){if(typeof a=="object")for(var d in a)a(a,d)&&e.addtest(d,a[d]);else{a=a.tolowercase();if(e[a]!==c)return e;b=typeof b=="function"?b():b,typeof f!="undefined"&&f&&(g.classname+=" "+(b?"":"no-")+a),e[a]=b}return e},b(""),i=k=null,function(a,b){function k(a,b){var c=a.createelement("p"),d=a.getelementsbytagname("head")[0]||a.documentelement;return c.innerhtml="x",d.insertbefore(c.lastchild,d.firstchild)}function l(){var a=r.elements;return typeof a=="string"?a.split(" "):a}function m(a){var b=i[a[g]];return b||(b={},h++,a[g]=h,i[h]=b),b}function n(a,c,f){c||(c=b);if(j)return c.createelement(a);f||(f=m(c));var g;return f.cache[a]?g=f.cache[a].clonenode():e.test(a)?g=(f.cache[a]=f.createelem(a)).clonenode():g=f.createelem(a),g.canhavechildren&&!d.test(a)?f.frag.appendchild(g):g}function o(a,c){a||(a=b);if(j)return a.createdocumentfragment();c=c||m(a);var d=c.frag.clonenode(),e=0,f=l(),g=f.length;for(;e",f="hidden"in a,j=a.childnodes.length==1||function(){b.createelement("a");var a=b.createdocumentfragment();return typeof a.clonenode=="undefined"||typeof a.createdocumentfragment=="undefined"||typeof a.createelement=="undefined"}()}catch(c){f=!0,j=!0}})();var r={elements:c.elements||"abbr article aside audio bdi canvas data datalist details figcaption figure footer header hgroup mark meter nav output progress section summary time video",shivcss:c.shivcss!==!1,supportsunknownelements:j,shivmethods:c.shivmethods!==!1,type:"default",shivdocument:q,createelement:n,createdocumentfragment:o};a.html5=r,q(b)}(this,b),e._version=d,e._prefixes=m,e._domprefixes=p,e._cssomprefixes=o,e.hasevent=y,e.testprop=function(a){return f([a])},e.testallprops=h,e.teststyles=x,g.classname=g.classname.replace(/(^|\s)no-js(\s|$)/,"$1$2")+(f?" js "+u.join(" "):""),e}(this,this.document),function(a,b,c){function d(a){return"[object function]"==o.call(a)}function e(a){return"string"==typeof a}function f(){}function g(a){return!a||"loaded"==a||"complete"==a||"uninitialized"==a}function h(){var a=p.shift();q=1,a?a.t?m(function(){("c"==a.t?b.injectcss:b.injectjs)(a.s,0,a.a,a.x,a.e,1)},0):(a(),h()):q=0}function i(a,c,d,e,f,i,j){function k(b){if(!o&&g(l.readystate)&&(u.r=o=1,!q&&h(),l.onload=l.onreadystatechange=null,b)){"img"!=a&&m(function(){t.removechild(l)},50);for(var d in y[c])y[c].hasownproperty(d)&&y[c][d].onload()}}var j=j||b.errortimeout,l=b.createelement(a),o=0,r=0,u={t:d,s:c,e:f,a:i,x:j};1===y[c]&&(r=1,y[c]=[]),"object"==a?l.data=c:(l.src=c,l.type=a),l.width=l.height="0",l.onerror=l.onload=l.onreadystatechange=function(){k.call(this,r)},p.splice(e,0,u),"img"!=a&&(r||2===y[c]?(t.insertbefore(l,s?null:n),m(k,j)):y[c].push(l))}function j(a,b,c,d,f){return q=0,b=b||"j",e(a)?i("c"==b?v:u,a,b,this.i++,c,d,f):(p.splice(this.i++,0,a),1==p.length&&h()),this}function k(){var a=b;return a.loader={load:j,i:0},a}var l=b.documentelement,m=a.settimeout,n=b.getelementsbytagname("script")[0],o={}.tostring,p=[],q=0,r="mozappearance"in l.style,s=r&&!!b.createrange().comparenode,t=s?l:n.parentnode,l=a.opera&&"[object opera]"==o.call(a.opera),l=!!b.attachevent&&!l,u=r?"object":l?"script":"img",v=l?"script":u,w=array.isarray||function(a){return"[object array]"==o.call(a)},x=[],y={},z={timeout:function(a,b){return b.length&&(a.timeout=b[0]),a}},a,b;b=function(a){function b(a){var a=a.split("!"),b=x.length,c=a.pop(),d=a.length,c={url:c,origurl:c,prefixes:a},e,f,g;for(f=0;f",e[0]};while(t()){continue}if(s>4){return s}else{return i}}();i=false;p=void 0;if(typeof n.hidden!=="undefined"){i="hidden";p="visibilitychange"}else if(typeof n.mozhidden!=="undefined"){i="mozhidden";p="mozvisibilitychange"}else if(typeof n.mshidden!=="undefined"){i="mshidden";p="msvisibilitychange"}else if(typeof n.webkithidden!=="undefined"){i="webkithidden";p="webkitvisibilitychange"}h=function(){var t,r;t=false;r=function(){cleartimeout(t);if(c!=="active"){a.wakeup()}s=+(new date);return t=settimeout(function(){if(c==="active"){return a.idle()}},o)};r();e(n,"mousemove",r);e(n,"keyup",r);e(window,"scroll",r);return a.focus(r)};f=function(){var t;if(l){return true}if(i===false){t="blur";if(u<9){t="focusout"}e(window,t,function(){return a.blur()});e(window,"focus",function(){return a.focus()})}else{e(n,p,function(){if(n[i]){return a.blur()}else{return a.focus()}},false)}l=true;return h()};a={setidleduration:function(e){return o=e*1e3},getidleduration:function(){return o},getidleinfo:function(){var e,t;e=+(new date);t={};if(c==="idle"){t.isidle=true;t.idlefor=e-s;t.timeleft=0;t.timeleftper=100}else{t.isidle=false;t.idlefor=e-s;t.timeleft=s+o-e;t.timeleftper=(100-t.timeleft*100/o).tofixed(2)}return t},focus:function(e){if(typeof e==="function"){return this.on("focus",e)}c="active";t.fire(this,"focus");t.fire(this,"wakeup");return t.fire(this,"statuschanged",{status:c})},blur:function(e){if(typeof e==="function"){return this.on("blur",e)}c="hidden";t.fire(this,"blur");t.fire(this,"idle");return t.fire(this,"statuschanged",{status:c})},idle:function(e){if(typeof e==="function"){return this.on("idle",e)}c="idle";t.fire(this,"idle");return t.fire(this,"statuschanged",{status:c})},wakeup:function(e){if(typeof e==="function"){return this.on("wakeup",e)}c="active";t.fire(this,"wakeup");return t.fire(this,"statuschanged",{status:c})},on:function(e,n){f();return t.add(this,e,n)},onevery:function(e,t){var n;f();n=setinterval(function(){if(c==="active"){return t()}},e*1e3);return{stop:function(){return clearinterval(n)},code:n,callback:t}},now:function(){f();return c==="active"}};if(typeof define==="function"&&define.amd){define(function(){return a})}else{window.ifvisible=a}}).call(this);
/* touchswipe */
(function(a){if(typeof define==="function"&&define.amd&&define.amd.jquery){define(["jquery"],a)}else{a(jquery)}}(function(f){var p="left",o="right",e="up",x="down",c="in",z="out",m="none",s="auto",l="swipe",t="pinch",a="tap",j="doubletap",b="longtap",y="hold",d="horizontal",u="vertical",i="all",r=10,g="start",k="move",h="end",q="cancel",a="ontouchstart" in window,v=window.navigator.mspointerenabled&&!window.navigator.pointerenabled,d=window.navigator.pointerenabled||window.navigator.mspointerenabled,b="touchswipe";var n={fingers:1,threshold:75,cancelthreshold:null,pinchthreshold:20,maxtimethreshold:null,fingerreleasethreshold:250,longtapthreshold:500,doubletapthreshold:200,swipe:null,swipeleft:null,swiperight:null,swipeup:null,swipedown:null,swipestatus:null,pinchin:null,pinchout:null,pinchstatus:null,click:null,tap:null,doubletap:null,longtap:null,hold:null,triggerontouchend:true,triggerontouchleave:false,allowpagescroll:"auto",fallbacktomouseevents:true,excludedelements:"label, button, input, select, textarea, a, .noswipe",preventdefaultevents:true};f.fn.swipe=function(g){var f=f(this),e=f.data(b);if(e&&typeof g==="string"){if(e[g]){return e[g].apply(this,array.prototype.slice.call(arguments,1))}else{f.error("method "+g+" does not exist on jquery.swipe")}}else{if(!e&&(typeof g==="object"||!g)){return w.apply(this,arguments)}}return f};f.fn.swipe.defaults=n;f.fn.swipe.phases={phase_start:g,phase_move:k,phase_end:h,phase_cancel:q};f.fn.swipe.directions={left:p,right:o,up:e,down:x,in:c,out:z};f.fn.swipe.pagescroll={none:m,horizontal:d,vertical:u,auto:s};f.fn.swipe.fingers={one:1,two:2,three:3,all:i};function w(e){if(e&&(e.allowpagescroll===undefined&&(e.swipe!==undefined||e.swipestatus!==undefined))){e.allowpagescroll=m}if(e.click!==undefined&&e.tap===undefined){e.tap=e.click}if(!e){e={}}e=f.extend({},f.fn.swipe.defaults,e);return this.each(function(){var g=f(this);var f=g.data(b);if(!f){f=new c(this,e);g.data(b,f)}})}function c(a4,av){var az=(a||d||!av.fallbacktomouseevents),j=az?(d?(v?"mspointerdown":"pointerdown"):"touchstart"):"mousedown",ay=az?(d?(v?"mspointermove":"pointermove"):"touchmove"):"mousemove",u=az?(d?(v?"mspointerup":"pointerup"):"touchend"):"mouseup",s=az?null:"mouseleave",ad=(d?(v?"mspointercancel":"pointercancel"):"touchcancel");var ag=0,ap=null,ab=0,a1=0,az=0,g=1,aq=0,aj=0,m=null;var ar=f(a4);var z="start";var w=0;var aq=null;var t=0,a2=0,a5=0,ad=0,n=0;var aw=null,af=null;try{ar.bind(j,an);ar.bind(ad,a9)}catch(ak){f.error("events not supported "+j+","+ad+" on jquery.swipe")}this.enable=function(){ar.bind(j,an);ar.bind(ad,a9);return ar};this.disable=function(){ak();return ar};this.destroy=function(){ak();ar.data(b,null);ar=null};this.option=function(bc,bb){if(av[bc]!==undefined){if(bb===undefined){return av[bc]}else{av[bc]=bb}}else{f.error("option "+bc+" does not exist on jquery.swipe.options")}return null};function an(bd){if(ab()){return}if(f(bd.target).closest(av.excludedelements,ar).length>0){return}var be=bd.originalevent?bd.originalevent:bd;var bc,bb=a?be.touches[0]:be;z=g;if(a){w=be.touches.length}else{bd.preventdefault()}ag=0;ap=null;aj=null;ab=0;a1=0;az=0;g=1;aq=0;aq=aj();m=aa();r();if(!a||(w===av.fingers||av.fingers===i)||ax()){ai(0,bb);t=at();if(w==2){ai(1,be.touches[1]);a1=az=au(aq[0].start,aq[1].start)}if(av.swipestatus||av.pinchstatus){bc=o(be,z)}}else{bc=false}if(bc===false){z=q;o(be,z);return bc}else{if(av.hold){af=settimeout(f.proxy(function(){ar.trigger("hold",[be.target]);if(av.hold){bc=av.hold.call(ar,be,be.target)}},this),av.longtapthreshold)}ao(true)}return null}function a3(be){var bh=be.originalevent?be.originalevent:be;if(z===h||z===q||am()){return}var bd,bc=a?bh.touches[0]:bh;var bf=ah(bc);a2=at();if(a){w=bh.touches.length}if(av.hold){cleartimeout(af)}z=k;if(w==2){if(a1==0){ai(1,bh.touches[1]);a1=az=au(aq[0].start,aq[1].start)}else{ah(bh.touches[1]);az=au(aq[0].end,aq[1].end);aj=ar(aq[0].end,aq[1].end)}g=a7(a1,az);aq=math.abs(a1-az)}if((w===av.fingers||av.fingers===i)||!a||ax()){ap=al(bf.start,bf.end);al(be,ap);ag=as(bf.start,bf.end);ab=am();ai(ap,ag);if(av.swipestatus||av.pinchstatus){bd=o(bh,z)}if(!av.triggerontouchend||av.triggerontouchleave){var bb=true;if(av.triggerontouchleave){var bg=ay(this);bb=e(bf.end,bg)}if(!av.triggerontouchend&&bb){z=ac(k)}else{if(av.triggerontouchleave&&!bb){z=ac(h)}}if(z==q||z==h){o(bh,z)}}}else{z=q;o(bh,z)}if(bd===false){z=q;o(bh,z)}}function l(bb){var bc=bb.originalevent;if(a){if(bc.touches.length>0){f();return true}}if(am()){w=ad}a2=at();ab=am();if(ba()||!an()){z=q;o(bc,z)}else{if(av.triggerontouchend||(av.triggerontouchend==false&&z===k)){bb.preventdefault();z=h;o(bc,z)}else{if(!av.triggerontouchend&&a6()){z=h;af(bc,z,a)}else{if(z===k){z=q;o(bc,z)}}}}ao(false);return null}function a9(){w=0;a2=0;t=0;a1=0;az=0;g=1;r();ao(false)}function k(bb){var bc=bb.originalevent;if(av.triggerontouchleave){z=ac(h);o(bc,z)}}function ak(){ar.unbind(j,an);ar.unbind(ad,a9);ar.unbind(ay,a3);ar.unbind(u,l);if(s){ar.unbind(s,k)}ao(false)}function ac(bf){var be=bf;var bd=aa();var bc=an();var bb=ba();if(!bd||bb){be=q}else{if(bc&&bf==k&&(!av.triggerontouchend||av.triggerontouchleave)){be=h}else{if(!bc&&bf==h&&av.triggerontouchleave){be=q}}}return be}function o(bd,bb){var bc=undefined;if((i()||v())||(p()||ax())){if(i()||v()){bc=af(bd,bb,l)}if((p()||ax())&&bc!==false){bc=af(bd,bb,t)}}else{if(ag()&&bc!==false){bc=af(bd,bb,j)}else{if(ap()&&bc!==false){bc=af(bd,bb,b)}else{if(ah()&&bc!==false){bc=af(bd,bb,a)}}}}if(bb===q){a9(bd)}if(bb===h){if(a){if(bd.touches.length==0){a9(bd)}}else{a9(bd)}}return bc}function af(be,bb,bd){var bc=undefined;if(bd==l){ar.trigger("swipestatus",[bb,ap||null,ag||0,ab||0,w,aq]);if(av.swipestatus){bc=av.swipestatus.call(ar,be,bb,ap||null,ag||0,ab||0,w,aq);if(bc===false){return false}}if(bb==h&&av()){ar.trigger("swipe",[ap,ag,ab,w,aq]);if(av.swipe){bc=av.swipe.call(ar,be,ap,ag,ab,w,aq);if(bc===false){return false}}switch(ap){case p:ar.trigger("swipeleft",[ap,ag,ab,w,aq]);if(av.swipeleft){bc=av.swipeleft.call(ar,be,ap,ag,ab,w,aq)}break;case o:ar.trigger("swiperight",[ap,ag,ab,w,aq]);if(av.swiperight){bc=av.swiperight.call(ar,be,ap,ag,ab,w,aq)}break;case e:ar.trigger("swipeup",[ap,ag,ab,w,aq]);if(av.swipeup){bc=av.swipeup.call(ar,be,ap,ag,ab,w,aq)}break;case x:ar.trigger("swipedown",[ap,ag,ab,w,aq]);if(av.swipedown){bc=av.swipedown.call(ar,be,ap,ag,ab,w,aq)}break}}}if(bd==t){ar.trigger("pinchstatus",[bb,aj||null,aq||0,ab||0,w,g,aq]);if(av.pinchstatus){bc=av.pinchstatus.call(ar,be,bb,aj||null,aq||0,ab||0,w,g,aq);if(bc===false){return false}}if(bb==h&&a8()){switch(aj){case c:ar.trigger("pinchin",[aj||null,aq||0,ab||0,w,g,aq]);if(av.pinchin){bc=av.pinchin.call(ar,be,aj||null,aq||0,ab||0,w,g,aq)}break;case z:ar.trigger("pinchout",[aj||null,aq||0,ab||0,w,g,aq]);if(av.pinchout){bc=av.pinchout.call(ar,be,aj||null,aq||0,ab||0,w,g,aq)}break}}}if(bd==a){if(bb===q||bb===h){cleartimeout(aw);cleartimeout(af);if(y()&&!h()){n=at();aw=settimeout(f.proxy(function(){n=null;ar.trigger("tap",[be.target]);if(av.tap){bc=av.tap.call(ar,be,be.target)}},this),av.doubletapthreshold)}else{n=null;ar.trigger("tap",[be.target]);if(av.tap){bc=av.tap.call(ar,be,be.target)}}}}else{if(bd==j){if(bb===q||bb===h){cleartimeout(aw);n=null;ar.trigger("doubletap",[be.target]);if(av.doubletap){bc=av.doubletap.call(ar,be,be.target)}}}else{if(bd==b){if(bb===q||bb===h){cleartimeout(aw);n=null;ar.trigger("longtap",[be.target]);if(av.longtap){bc=av.longtap.call(ar,be,be.target)}}}}}return bc}function an(){var bb=true;if(av.threshold!==null){bb=ag>=av.threshold}return bb}function ba(){var bb=false;if(av.cancelthreshold!==null&&ap!==null){bb=(at(ap)-ag)>=av.cancelthreshold}return bb}function ae(){if(av.pinchthreshold!==null){return aq>=av.pinchthreshold}return true}function aa(){var bb;if(av.maxtimethreshold){if(ab>=av.maxtimethreshold){bb=false}else{bb=true}}else{bb=true}return bb}function al(bb,bc){if(av.preventdefaultevents===false){return}if(av.allowpagescroll===m){bb.preventdefault()}else{var bd=av.allowpagescroll===s;switch(bc){case p:if((av.swipeleft&&bd)||(!bd&&av.allowpagescroll!=d)){bb.preventdefault()}break;case o:if((av.swiperight&&bd)||(!bd&&av.allowpagescroll!=d)){bb.preventdefault()}break;case e:if((av.swipeup&&bd)||(!bd&&av.allowpagescroll!=u)){bb.preventdefault()}break;case x:if((av.swipedown&&bd)||(!bd&&av.allowpagescroll!=u)){bb.preventdefault()}break}}}function a8(){var bc=ao();var bb=x();var bd=ae();return bc&&bb&&bd}function ax(){return !!(av.pinchstatus||av.pinchin||av.pinchout)}function p(){return !!(a8()&&ax())}function av(){var be=aa();var bg=an();var bd=ao();var bb=x();var bc=ba();var bf=!bc&&bb&&bd&&bg&&be;return bf}function v(){return !!(av.swipe||av.swipestatus||av.swipeleft||av.swiperight||av.swipeup||av.swipedown)}function i(){return !!(av()&&v())}function ao(){return((w===av.fingers||av.fingers===i)||!a)}function x(){return aq[0].end.x!==0}function a6(){return !!(av.tap)}function y(){return !!(av.doubletap)}function au(){return !!(av.longtap)}function q(){if(n==null){return false}var bb=at();return(y()&&((bb-n)<=av.doubletapthreshold))}function h(){return q()}function ax(){return((w===1||!a)&&(isnan(ag)||agav.longtapthreshold)&&(ag=0)){return p}else{if((bd<=360)&&(bd>=315)){return p}else{if((bd>=135)&&(bd<=225)){return o}else{if((bd>45)&&(bd<135)){return x}else{return e}}}}}function at(){var bb=new date();return bb.gettime()}function ay(bb){bb=f(bb);var bd=bb.offset();var bc={left:bd.left,right:bd.left+bb.outerwidth(),top:bd.top,bottom:bd.top+bb.outerheight()};return bc}function e(bb,bc){return(bb.x>bc.left&&bb.xbc.top&&bb.y-1;n.transition=i("transition");n.transitiondelay=i("transitiondelay");n.transform=i("transform");n.transformorigin=i("transformorigin");n.filter=i("filter");n.transform3d=r();var a={transition:"transitionend",moztransition:"transitionend",otransition:"otransitionend",webkittransition:"webkittransitionend",mstransition:"mstransitionend"};var o=n.transitionend=a[n.transition]||null;for(var u in n){if(n.hasownproperty(u)&&typeof t.support[u]==="undefined"){t.support[u]=n[u]}}e=null;t.cssease={_default:"ease","in":"ease-in",out:"ease-out","in-out":"ease-in-out",snap:"cubic-bezier(0,1,.5,1)",easeincubic:"cubic-bezier(.550,.055,.675,.190)",easeoutcubic:"cubic-bezier(.215,.61,.355,1)",easeinoutcubic:"cubic-bezier(.645,.045,.355,1)",easeincirc:"cubic-bezier(.6,.04,.98,.335)",easeoutcirc:"cubic-bezier(.075,.82,.165,1)",easeinoutcirc:"cubic-bezier(.785,.135,.15,.86)",easeinexpo:"cubic-bezier(.95,.05,.795,.035)",easeoutexpo:"cubic-bezier(.19,1,.22,1)",easeinoutexpo:"cubic-bezier(1,0,0,1)",easeinquad:"cubic-bezier(.55,.085,.68,.53)",easeoutquad:"cubic-bezier(.25,.46,.45,.94)",easeinoutquad:"cubic-bezier(.455,.03,.515,.955)",easeinquart:"cubic-bezier(.895,.03,.685,.22)",easeoutquart:"cubic-bezier(.165,.84,.44,1)",easeinoutquart:"cubic-bezier(.77,0,.175,1)",easeinquint:"cubic-bezier(.755,.05,.855,.06)",easeoutquint:"cubic-bezier(.23,1,.32,1)",easeinoutquint:"cubic-bezier(.86,0,.07,1)",easeinsine:"cubic-bezier(.47,0,.745,.715)",easeoutsine:"cubic-bezier(.39,.575,.565,1)",easeinoutsine:"cubic-bezier(.445,.05,.55,.95)",easeinback:"cubic-bezier(.6,-.28,.735,.045)",easeoutback:"cubic-bezier(.175, .885,.32,1.275)",easeinoutback:"cubic-bezier(.68,-.55,.265,1.55)"};t.csshooks["transit:transform"]={get:function(e){return t(e).data("transform")||new f},set:function(e,i){var r=i;if(!(r instanceof f)){r=new f(r)}if(n.transform==="webkittransform"&&!s){e.style[n.transform]=r.tostring(true)}else{e.style[n.transform]=r.tostring()}t(e).data("transform",r)}};t.csshooks.transform={set:t.csshooks["transit:transform"].set};t.csshooks.filter={get:function(t){return t.style[n.filter]},set:function(t,e){t.style[n.filter]=e}};if(t.fn.jquery<"1.8"){t.csshooks.transformorigin={get:function(t){return t.style[n.transformorigin]},set:function(t,e){t.style[n.transformorigin]=e}};t.csshooks.transition={get:function(t){return t.style[n.transition]},set:function(t,e){t.style[n.transition]=e}}}p("scale");p("scalex");p("scaley");p("translate");p("rotate");p("rotatex");p("rotatey");p("rotate3d");p("perspective");p("skewx");p("skewy");p("x",true);p("y",true);function f(t){if(typeof t==="string"){this.parse(t)}return this}f.prototype={setfromstring:function(t,e){var n=typeof e==="string"?e.split(","):e.constructor===array?e:[e];n.unshift(t);f.prototype.set.apply(this,n)},set:function(t){var e=array.prototype.slice.apply(arguments,[1]);if(this.setter[t]){this.setter[t].apply(this,e)}else{this[t]=e.join(",")}},get:function(t){if(this.getter[t]){return this.getter[t].apply(this)}else{return this[t]||0}},setter:{rotate:function(t){this.rotate=b(t,"deg")},rotatex:function(t){this.rotatex=b(t,"deg")},rotatey:function(t){this.rotatey=b(t,"deg")},scale:function(t,e){if(e===undefined){e=t}this.scale=t+","+e},skewx:function(t){this.skewx=b(t,"deg")},skewy:function(t){this.skewy=b(t,"deg")},perspective:function(t){this.perspective=b(t,"px")},x:function(t){this.set("translate",t,null)},y:function(t){this.set("translate",null,t)},translate:function(t,e){if(this._translatex===undefined){this._translatex=0}if(this._translatey===undefined){this._translatey=0}if(t!==null&&t!==undefined){this._translatex=b(t,"px")}if(e!==null&&e!==undefined){this._translatey=b(e,"px")}this.translate=this._translatex+","+this._translatey}},getter:{x:function(){return this._translatex||0},y:function(){return this._translatey||0},scale:function(){var t=(this.scale||"1,1").split(",");if(t[0]){t[0]=parsefloat(t[0])}if(t[1]){t[1]=parsefloat(t[1])}return t[0]===t[1]?t[0]:t},rotate3d:function(){var t=(this.rotate3d||"0,0,0,0deg").split(",");for(var e=0;e<=3;++e){if(t[e]){t[e]=parsefloat(t[e])}}if(t[3]){t[3]=b(t[3],"deg")}return t}},parse:function(t){var e=this;t.replace(/([a-za-z0-9]+)\((.*?)\)/g,function(t,n,i){e.setfromstring(n,i)})},tostring:function(t){var e=[];for(var i in this){if(this.hasownproperty(i)){if(!n.transform3d&&(i==="rotatex"||i==="rotatey"||i==="perspective"||i==="transformorigin")){continue}if(i[0]!=="_"){if(t&&i==="scale"){e.push(i+"3d("+this[i]+",1)")}else if(t&&i==="translate"){e.push(i+"3d("+this[i]+",0)")}else{e.push(i+"("+this[i]+")")}}}}return e.join(" ")}};function c(t,e,n){if(e===true){t.queue(n)}else if(e){t.queue(e,n)}else{t.each(function(){n.call(this)})}}function l(e){var i=[];t.each(e,function(e){e=t.camelcase(e);e=t.transit.propertymap[e]||t.cssprops[e]||e;e=h(e);if(n[e])e=h(n[e]);if(t.inarray(e,i)===-1){i.push(e)}});return i}function d(e,n,i,r){var s=l(e);if(t.cssease[i]){i=t.cssease[i]}var a=""+y(n)+" "+i;if(parseint(r,10)>0){a+=" "+y(r)}var o=[];t.each(s,function(t,e){o.push(e+" "+a)});return o.join(", ")}t.fn.transition=t.fn.transit=function(e,i,r,s){var a=this;var u=0;var f=true;var l=t.extend(true,{},e);if(typeof i==="function"){s=i;i=undefined}if(typeof i==="object"){r=i.easing;u=i.delay||0;f=typeof i.queue==="undefined"?true:i.queue;s=i.complete;i=i.duration}if(typeof r==="function"){s=r;r=undefined}if(typeof l.easing!=="undefined"){r=l.easing;delete l.easing}if(typeof l.duration!=="undefined"){i=l.duration;delete l.duration}if(typeof l.complete!=="undefined"){s=l.complete;delete l.complete}if(typeof l.queue!=="undefined"){f=l.queue;delete l.queue}if(typeof l.delay!=="undefined"){u=l.delay;delete l.delay}if(typeof i==="undefined"){i=t.fx.speeds._default}if(typeof r==="undefined"){r=t.cssease._default}i=y(i);var p=d(l,i,r,u);var h=t.transit.enabled&&n.transition;var b=h?parseint(i,10)+parseint(u,10):0;if(b===0){var g=function(t){a.css(l);if(s){s.apply(a)}if(t){t()}};c(a,f,g);return a}var m={};var v=function(e){var i=false;var r=function(){if(i){a.unbind(o,r)}if(b>0){a.each(function(){this.style[n.transition]=m[this]||null})}if(typeof s==="function"){s.apply(a)}if(typeof e==="function"){e()}};if(b>0&&o&&t.transit.usetransitionend){i=true;a.bind(o,r)}else{window.settimeout(r,b)}a.each(function(){if(b>0){this.style[n.transition]=p}t(this).css(l)})};var z=function(t){this.offsetwidth;v(t)};c(a,f,z);return this};function p(e,i){if(!i){t.cssnumber[e]=true}t.transit.propertymap[e]=n.transform;t.csshooks[e]={get:function(n){var i=t(n).css("transit:transform");return i.get(e)},set:function(n,i){var r=t(n).css("transit:transform");r.setfromstring(e,i);t(n).css({"transit:transform":r})}}}function h(t){return t.replace(/([a-z])/g,function(t){return"-"+t.tolowercase()})}function b(t,e){if(typeof t==="string"&&!t.match(/^[\-0-9\.]+$/)){return t}else{return""+t+e}}function y(e){var n=e;if(typeof n==="string"&&!n.match(/^[\-0-9\.]+/)){n=t.fx.speeds[n]||t.fx.speeds._default}return b(n,"ms")}t.transit.gettransitionvalue=d;return t});
/* standard functions */
function checkemail(email) {
var atpos = email.indexof("@");
var stoppos = email.lastindexof(".");
var result = "";
if (email == "" || atpos == -1 || stoppos == -1 || stoppos < atpos || (stoppos - atpos == 1)) {
result = "not a valid email address";
}
return result
}
function openpopupcenter(pageurl, title, w, h) {
var left = (screen.width - w) / 2;
var top = (screen.height - h) / 3; // for 25% - devide by 4 | for 33% - devide by 3
var targetwin = window.open(pageurl, title, 'toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=no, copyhistory=no, width=' + w + ', height=' + h + ', top=' + top + ', left=' + left);
}
function scrollbarwidth() {
var outer = document.createelement("div");
outer.style.visibility = "hidden";
outer.style.width = "100px";
outer.style.msoverflowstyle = "scrollbar"; // needed for winjs apps
document.body.appendchild(outer);
var widthnoscroll = outer.offsetwidth;
// force scrollbars
outer.style.overflow = "scroll";
// add innerdiv
var inner = document.createelement("div");
inner.style.width = "100%";
outer.appendchild(inner);
var widthwithscroll = inner.offsetwidth;
// remove divs
outer.parentnode.removechild(outer);
return widthnoscroll - widthwithscroll;
}
function ismobile() {
return preg_match("/(android|avantgo|blackberry|bolt|boost|cricket|docomo|fone|hiptop|mini|mobi|palm|phone|pie|tablet|up\.browser|up\.link|webos|wos)/i", $_server["http_user_agent"]);
}
function fixedencodeuricomponent(str){
return encodeuricomponent(str).replace(/[!'()]/g, escape).replace(/\*/g, "%2a");
}
// fontello
function togglecodes(on) {var obj = document.getelementbyid('icons'); if(on) {obj.classname += ' codeson'; } else {obj.classname = obj.classname.replace(' codeson', '');}}
// replace external links to target='_blank'
/*
$(function() {
$('a:not([href=""])').each(function() {
var linkurl = $(this).attr('href');
if (linkurl === undefined || linkurl === null) {
}else{
if (linkurl.indexof("mailto") > -1){
}else{
if (this.hostname !== location.hostname) {
$(this).attr('target', "_blank");
}
}
}
});
});*/