/*!
 * jQuery Cycle Plugin (with Transition Definitions)
 * Examples and documentation at: http://jquery.malsup.com/cycle/
 * Copyright (c) 2007-2010 M. Alsup
 * Version: 2.9997 (13-OCT-2011)
 * Dual licensed under the MIT and GPL licenses.
 * http://jquery.malsup.com/license.html
 * Requires: jQuery v1.3.2 or later
 */
(function(f){function c(b){f.fn.cycle.debug&&h(b)}function h(){window.console&&console.log&&console.log("[cycle] "+Array.prototype.join.call(arguments," "))}function a(b,g,a){var d=f(b).data("cycle.opts"),c=!!b.cyclePause;c&&d.paused?d.paused(b,d,g,a):!c&&d.resumed&&d.resumed(b,d,g,a)}function i(b,g,k){function c(b,g,a){if(!b&&g===true){b=f(a).data("cycle.opts");if(!b)return h("options not found, can not resume"),false;if(a.cycleTimeout)clearTimeout(a.cycleTimeout),a.cycleTimeout=0;r(b.elements,b,1,!b.backwards)}}if(b.cycleStop==void 0)b.cycleStop=0;if(g===void 0||g===null)g={};if(g.constructor==String)switch(g){case "destroy":case "stop":k=f(b).data("cycle.opts");if(!k)return false;b.cycleStop++;b.cycleTimeout&&clearTimeout(b.cycleTimeout);b.cycleTimeout=0;k.elements&&f(k.elements).stop();f(b).removeData("cycle.opts");g=="destroy"&&d(k);return false;case "toggle":return b.cyclePause=b.cyclePause===1?0:1,c(b.cyclePause,k,b),a(b),false;case "pause":return b.cyclePause=1,a(b),false;case "resume":return b.cyclePause=0,c(false,k,b),a(b),false;case "prev":case "next":k=f(b).data("cycle.opts");if(!k)return h('options not found, "prev/next" ignored'),false;f.fn.cycle[g](k);return false;default:g={fx:g}}else if(g.constructor==Number){var j=g,g=f(b).data("cycle.opts");if(!g)return h("options not found, can not advance slide"),false;if(j<0||j>=g.elements.length)return h("invalid slide index: "+j),false;g.nextSlide=j;if(b.cycleTimeout)clearTimeout(b.cycleTimeout),b.cycleTimeout=0;if(typeof k=="string")g.oneTimeFx=k;r(g.elements,g,1,j>=g.currSlide);return false}return g}function j(b,g){if(!f.support.opacity&&g.cleartype&&b.style.filter)try{b.style.removeAttribute("filter")}catch(a){}}function d(b){b.next&&f(b.next).unbind(b.prevNextEvent);b.prev&&f(b.prev).unbind(b.prevNextEvent);if(b.pager||b.pagerAnchorBuilder)f.each(b.pagerAnchors||[],function(){this.unbind().remove()});b.pagerAnchors=null;b.destroy&&b.destroy(b)}function l(b,g,k,d,c){var e=f.extend({},f.fn.cycle.defaults,d||{},f.metadata?b.metadata():f.meta?b.data():{}),i=f.isFunction(b.data)?b.data(e.metaAttr):null;i&&(e=f.extend(e,i));if(e.autostop)e.countdown=e.autostopCount||k.length;var z=b[0];b.data("cycle.opts",e);e.$cont=b;e.stopCount=z.cycleStop;e.elements=k;e.before=e.before?[e.before]:[];e.after=e.after?[e.after]:[];!f.support.opacity&&e.cleartype&&e.after.push(function(){j(this,e)});e.continuous&&e.after.push(function(){r(k,e,0,!e.backwards)});n(e);!f.support.opacity&&e.cleartype&&!e.cleartypeNoBg&&v(g);b.css("position")=="static"&&b.css("position","relative");e.width&&b.width(e.width);e.height&&e.height!="auto"&&b.height(e.height);if(e.startingSlide)e.startingSlide=parseInt(e.startingSlide,10);else if(e.backwards)e.startingSlide=k.length-1;if(e.random){e.randomMap=[];for(i=0;i<k.length;i++)e.randomMap.push(i);e.randomMap.sort(function(){return Math.random()-0.5});e.randomIndex=1;e.startingSlide=e.randomMap[1]}else if(e.startingSlide>=k.length)e.startingSlide=0;e.currSlide=e.startingSlide||0;var l=e.startingSlide;g.css({position:"absolute",top:0,left:0}).hide().each(function(b){b=e.backwards?l?b<=l?k.length+(b-l):l-b:k.length-b:l?b>=l?k.length-(b-l):l-b:k.length-b;f(this).css("z-index",b)});f(k[l]).css("opacity",1).show();j(k[l],e);e.fit&&(e.aspect?g.each(function(){var b=f(this),g=e.aspect===true?b.width()/b.height():e.aspect;e.width&&b.width()!=e.width&&(b.width(e.width),b.height(e.width/g));e.height&&b.height()<e.height&&(b.height(e.height),b.width(e.height*g))}):(e.width&&g.width(e.width),e.height&&e.height!="auto"&&g.height(e.height)));e.center&&(!e.fit||e.aspect)&&g.each(function(){var b=f(this);b.css({"margin-left":e.width?(e.width-b.width())/2+"px":0,"margin-top":e.height?(e.height-b.height())/2+"px":0})});e.center&&!e.fit&&!e.slideResize&&g.each(function(){var b=f(this);b.css({"margin-left":e.width?(e.width-b.width())/2+"px":0,"margin-top":e.height?(e.height-b.height())/2+"px":0})});if(e.containerResize&&!b.innerHeight()){for(var t=i=0,A=0;A<k.length;A++){var u=f(k[A]),s=u[0],w=u.outerWidth(),x=u.outerHeight();w||(w=s.offsetWidth||s.width||u.attr("width"));x||(x=s.offsetHeight||s.height||u.attr("height"));i=w>i?w:i;t=x>t?x:t}i>0&&t>0&&b.css({width:i+"px",height:t+"px"})}var B=false;e.pause&&b.hover(function(){B=true;this.cyclePause++;a(z,true)},function(){B&&this.cyclePause--;a(z,true)});if(m(e)===false)return false;var C=false;d.requeueAttempts=d.requeueAttempts||0;g.each(function(){var b=f(this);this.cycleH=e.fit&&e.height?e.height:b.height()||this.offsetHeight||this.height||b.attr("height")||0;this.cycleW=e.fit&&e.width?e.width:b.width()||this.offsetWidth||this.width||b.attr("width")||0;if(b.is("img")){var b=f.browser.mozilla&&this.cycleW==34&&this.cycleH==19&&!this.complete,g=f.browser.opera&&(this.cycleW==42&&this.cycleH==19||this.cycleW==37&&this.cycleH==17)&&!this.complete,a=this.cycleH==0&&this.cycleW==0&&!this.complete;if(f.browser.msie&&this.cycleW==28&&this.cycleH==30&&!this.complete||b||g||a)if(c.s&&e.requeueOnImageNotLoaded&&++d.requeueAttempts<100)return h(d.requeueAttempts," - img slide not loaded, requeuing slideshow: ",this.src,this.cycleW,this.cycleH),setTimeout(function(){f(c.s,c.c).cycle(d)},e.requeueTimeout),C=true,false;else h("could not determine size of image: "+this.src,this.cycleW,this.cycleH)}return true});if(C)return false;e.cssBefore=e.cssBefore||{};e.cssAfter=e.cssAfter||{};e.cssFirst=e.cssFirst||{};e.animIn=e.animIn||{};e.animOut=e.animOut||{};g.not(":eq("+l+")").css(e.cssBefore);f(g[l]).css(e.cssFirst);if(e.timeout){e.timeout=parseInt(e.timeout,10);if(e.speed.constructor==String)e.speed=f.fx.speeds[e.speed]||parseInt(e.speed,10);e.sync||(e.speed/=2);for(i=e.fx=="none"?0:e.fx=="shuffle"?500:250;e.timeout-e.speed<i;)e.timeout+=e.speed}if(e.easing)e.easeIn=e.easeOut=e.easing;if(!e.speedIn)e.speedIn=e.speed;if(!e.speedOut)e.speedOut=e.speed;e.slideCount=k.length;e.currSlide=e.lastSlide=l;if(e.random){if(++e.randomIndex==k.length)e.randomIndex=0;e.nextSlide=e.randomMap[e.randomIndex]}else e.nextSlide=e.backwards?e.startingSlide==0?k.length-1:e.startingSlide-1:e.startingSlide>=k.length-1?0:e.startingSlide+1;if(!e.multiFx)if(i=f.fn.cycle.transitions[e.fx],f.isFunction(i))i(b,g,e);else if(e.fx!="custom"&&!e.multiFx)return h("unknown transition: "+e.fx,"; slideshow terminating"),false;b=g[l];e.skipInitializationCallbacks||(e.before.length&&e.before[0].apply(b,[b,b,e,true]),e.after.length&&e.after[0].apply(b,[b,b,e,true]));e.next&&f(e.next).bind(e.prevNextEvent,function(){return y(e,1)});e.prev&&f(e.prev).bind(e.prevNextEvent,function(){return y(e,0)});(e.pager||e.pagerAnchorBuilder)&&E(k,e);q(e,k);return e}function n(b){b.original={before:[],after:[]};b.original.cssBefore=f.extend({},b.cssBefore);b.original.cssAfter=f.extend({},b.cssAfter);b.original.animIn=f.extend({},b.animIn);b.original.animOut=f.extend({},b.animOut);f.each(b.before,function(){b.original.before.push(this)});f.each(b.after,function(){b.original.after.push(this)})}function m(b){var g,a,d=f.fn.cycle.transitions;if(b.fx.indexOf(",")>0){b.multiFx=true;b.fxs=b.fx.replace(/\s*/g,"").split(",");for(g=0;g<b.fxs.length;g++){var i=b.fxs[g];a=d[i];if(!a||!d.hasOwnProperty(i)||!f.isFunction(a))h("discarding unknown transition: ",i),b.fxs.splice(g,1),g--}if(!b.fxs.length)return h("No valid transitions named; slideshow terminating."),false}else if(b.fx=="all")for(p in b.multiFx=true,b.fxs=[],d)a=d[p],d.hasOwnProperty(p)&&f.isFunction(a)&&b.fxs.push(p);if(b.multiFx&&b.randomizeEffects){a=Math.floor(Math.random()*20)+30;for(g=0;g<a;g++)d=Math.floor(Math.random()*b.fxs.length),b.fxs.push(b.fxs.splice(d,1)[0]);c("randomized fx sequence: ",b.fxs)}return true}function q(b,g){b.addSlide=function(a,d){var c=f(a),e=c[0];b.autostopCount||b.countdown++;g[d?"unshift":"push"](e);if(b.els)b.els[d?"unshift":"push"](e);b.slideCount=g.length;c.css("position","absolute");c[d?"prependTo":"appendTo"](b.$cont);d&&(b.currSlide++,b.nextSlide++);!f.support.opacity&&b.cleartype&&!b.cleartypeNoBg&&v(c);b.fit&&b.width&&c.width(b.width);b.fit&&b.height&&b.height!="auto"&&c.height(b.height);e.cycleH=b.fit&&b.height?b.height:c.height();e.cycleW=b.fit&&b.width?b.width:c.width();c.css(b.cssBefore);(b.pager||b.pagerAnchorBuilder)&&f.fn.cycle.createPagerAnchor(g.length-1,e,f(b.pager),g,b);if(f.isFunction(b.onAddSlide))b.onAddSlide(c);else c.hide()}}function r(b,g,a,d){function i(){var a=0;g.timeout&&!g.continuous?(a=s(b[g.currSlide],b[g.nextSlide],g,d),g.fx=="shuffle"&&(a-=g.speedOut)):g.continuous&&e.cyclePause&&(a=10);if(a>0)e.cycleTimeout=setTimeout(function(){r(b,g,0,!g.backwards)},a)}if(a&&g.busy&&g.manualTrump)c("manualTrump in go(), stopping active transition"),f(b).stop(true,true),g.busy=0;if(g.busy)c("transition active, ignoring new tx request");else{var e=g.$cont[0],j=b[g.currSlide],h=b[g.nextSlide];if(!(e.cycleStop!=g.stopCount||e.cycleTimeout===0&&!a))if(!a&&!e.cyclePause&&!g.bounce&&(g.autostop&&--g.countdown<=0||g.nowrap&&!g.random&&g.nextSlide<g.currSlide))g.end&&g.end(g);else{var l=false;if((a||!e.cyclePause)&&g.nextSlide!=g.currSlide){var l=true,n=g.fx;j.cycleH=j.cycleH||f(j).height();j.cycleW=j.cycleW||f(j).width();h.cycleH=h.cycleH||f(h).height();h.cycleW=h.cycleW||f(h).width();if(g.multiFx){if(d&&(g.lastFx==void 0||++g.lastFx>=g.fxs.length))g.lastFx=0;else if(!d&&(g.lastFx==void 0||--g.lastFx<0))g.lastFx=g.fxs.length-1;n=g.fxs[g.lastFx]}if(g.oneTimeFx)n=g.oneTimeFx,g.oneTimeFx=null;f.fn.cycle.resetState(g,n);g.before.length&&f.each(g.before,function(b,a){e.cycleStop==g.stopCount&&a.apply(h,[j,h,g,d])});var m=function(){g.busy=0;f.each(g.after,function(b,a){e.cycleStop==g.stopCount&&a.apply(h,[j,h,g,d])});e.cycleStop||i()};c("tx firing("+n+"); currSlide: "+g.currSlide+"; nextSlide: "+g.nextSlide);g.busy=1;if(g.fxFn)g.fxFn(j,h,g,m,d,a&&g.fastOnEvent);else if(f.isFunction(f.fn.cycle[g.fx]))f.fn.cycle[g.fx](j,h,g,m,d,a&&g.fastOnEvent);else f.fn.cycle.custom(j,h,g,m,d,a&&g.fastOnEvent)}else i();if(l||g.nextSlide==g.currSlide)if(g.lastSlide=g.currSlide,g.random){g.currSlide=g.nextSlide;if(++g.randomIndex==b.length)g.randomIndex=0;g.nextSlide=g.randomMap[g.randomIndex];if(g.nextSlide==g.currSlide)g.nextSlide=g.currSlide==g.slideCount-1?0:g.currSlide+1}else g.backwards?(a=g.nextSlide-1<0)&&g.bounce?(g.backwards=!g.backwards,g.nextSlide=1,g.currSlide=0):(g.nextSlide=a?b.length-1:g.nextSlide-1,g.currSlide=a?0:g.nextSlide+1):(a=g.nextSlide+1==b.length)&&g.bounce?(g.backwards=!g.backwards,g.nextSlide=b.length-2,g.currSlide=b.length-1):(g.nextSlide=a?0:g.nextSlide+1,g.currSlide=a?b.length-1:g.nextSlide-1);l&&g.pager&&g.updateActivePagerLink(g.pager,g.currSlide,g.activePagerClass)}}}function s(b,a,f,d){if(f.timeoutFn){for(b=f.timeoutFn.call(b,b,a,f,d);f.fx!="none"&&b-f.speed<250;)b+=f.speed;c("calculated timeout: "+b+"; speed: "+f.speed);if(b!==false)return b}return f.timeout}function y(b,a){var d=a?1:-1,c=b.elements,j=b.$cont[0],e=j.cycleTimeout;if(e)clearTimeout(e),j.cycleTimeout=0;if(b.random&&d<0){b.randomIndex--;if(--b.randomIndex==-2)b.randomIndex=c.length-2;else if(b.randomIndex==-1)b.randomIndex=c.length-1;b.nextSlide=b.randomMap[b.randomIndex]}else if(b.random)b.nextSlide=b.randomMap[b.randomIndex];else if(b.nextSlide=b.currSlide+d,b.nextSlide<0){if(b.nowrap)return false;b.nextSlide=c.length-1}else if(b.nextSlide>=c.length){if(b.nowrap)return false;b.nextSlide=0}j=b.onPrevNextEvent||b.prevNextClick;f.isFunction(j)&&j(d>0,b.nextSlide,c[b.nextSlide]);r(c,b,1,a);return false}function E(b,a){var d=f(a.pager);f.each(b,function(c,j){f.fn.cycle.createPagerAnchor(c,j,d,b,a)});a.updateActivePagerLink(a.pager,a.startingSlide,a.activePagerClass)}function v(b){function a(b){b=parseInt(b,10).toString(16);return b.length<2?"0"+b:b}function d(b){for(;b&&b.nodeName.toLowerCase()!="html";b=b.parentNode){var c=f.css(b,"background-color");if(c&&c.indexOf("rgb")>=0)return b=c.match(/\d+/g),"#"+a(b[0])+a(b[1])+a(b[2]);if(c&&c!="transparent")return c}return"#ffffff"}c("applying clearType background-color hack");b.each(function(){f(this).css("background-color",d(this))})}if(f.support==void 0)f.support={opacity:!f.browser.msie};f.expr[":"].paused=function(b){return b.cyclePause};f.fn.cycle=function(b,a){var d={s:this.selector,c:this.context};if(this.length===0&&b!="stop"){if(!f.isReady&&d.s)return h("DOM not ready, queuing slideshow"),f(function(){f(d.s,d.c).cycle(b,a)}),this;h("terminating; zero elements found by selector"+(f.isReady?"":" (DOM not ready)"));return this}return this.each(function(){var j=i(this,b,a);if(j!==false){j.updateActivePagerLink=j.updateActivePagerLink||f.fn.cycle.updateActivePagerLink;this.cycleTimeout&&clearTimeout(this.cycleTimeout);this.cycleTimeout=this.cyclePause=0;var o=f(this),e=j.slideExpr?f(j.slideExpr,this):o.children(),n=e.get(),m=l(o,e,n,j,d);if(m!==false)if(n.length<2)h("terminating; too few slides: "+n.length);else if(o=m.continuous?10:s(n[m.currSlide],n[m.nextSlide],m,!m.backwards))o+=m.delay||0,o<10&&(o=10),c("first timeout: "+o),this.cycleTimeout=setTimeout(function(){r(n,m,0,!j.backwards)},o)}})};f.fn.cycle.resetState=function(b,a){a=a||b.fx;b.before=[];b.after=[];b.cssBefore=f.extend({},b.original.cssBefore);b.cssAfter=f.extend({},b.original.cssAfter);b.animIn=f.extend({},b.original.animIn);b.animOut=f.extend({},b.original.animOut);b.fxFn=null;f.each(b.original.before,function(){b.before.push(this)});f.each(b.original.after,function(){b.after.push(this)});var d=f.fn.cycle.transitions[a];f.isFunction(d)&&d(b.$cont,f(b.elements),b)};f.fn.cycle.updateActivePagerLink=function(b,a,d){f(b).each(function(){f(this).children().removeClass(d).eq(a).addClass(d)})};f.fn.cycle.next=function(b){y(b,1)};f.fn.cycle.prev=function(b){y(b,0)};f.fn.cycle.createPagerAnchor=function(b,g,d,j,i){f.isFunction(i.pagerAnchorBuilder)?(g=i.pagerAnchorBuilder(b,g),c("pagerAnchorBuilder("+b+", el) returned: "+g)):g='<a href="#">'+(b+1)+"</a>";if(g){var e=f(g);if(e.parents("body").length===0){var h=[];d.length>1?(d.each(function(){var b=e.clone(true);f(this).append(b);h.push(b[0])}),e=f(h)):e.appendTo(d)}i.pagerAnchors=i.pagerAnchors||[];i.pagerAnchors.push(e);d=function(a){a.preventDefault();i.nextSlide=b;var a=i.$cont[0],e=a.cycleTimeout;if(e)clearTimeout(e),a.cycleTimeout=0;a=i.onPagerEvent||i.pagerClick;f.isFunction(a)&&a(i.nextSlide,j[i.nextSlide]);r(j,i,1,i.currSlide<b)};/mouseenter|mouseover/i.test(i.pagerEvent)?e.hover(d,function(){}):e.bind(i.pagerEvent,d);!/^click/.test(i.pagerEvent)&&!i.allowPagerClickBubble&&e.bind("click.cycle",function(){return false});var l=i.$cont[0],m=false;i.pauseOnPagerHover&&e.hover(function(){m=true;l.cyclePause++;a(l,true,true)},function(){m&&l.cyclePause--;a(l,true,true)})}};f.fn.cycle.hopsFromLast=function(b,a){var f=b.lastSlide,d=b.currSlide;return a?d>f?d-f:b.slideCount-f:d<f?f-d:f+b.slideCount-d};f.fn.cycle.commonReset=function(b,a,d,c,j,e){f(d.elements).not(b).hide();if(typeof d.cssBefore.opacity=="undefined")d.cssBefore.opacity=1;d.cssBefore.display="block";if(d.slideResize&&c!==false&&a.cycleW>0)d.cssBefore.width=a.cycleW;if(d.slideResize&&j!==false&&a.cycleH>0)d.cssBefore.height=a.cycleH;d.cssAfter=d.cssAfter||{};d.cssAfter.display="none";f(b).css("zIndex",d.slideCount+(e===true?1:0));f(a).css("zIndex",d.slideCount+(e===true?0:1))};f.fn.cycle.custom=function(b,a,d,c,j,e){var i=f(b),h=f(a),l=d.speedIn,b=d.speedOut,m=d.easeIn,a=d.easeOut;h.css(d.cssBefore);e&&(l=typeof e=="number"?b=e:b=1,m=a=null);var n=function(){h.animate(d.animIn,l,m,function(){c()})};i.animate(d.animOut,b,a,function(){i.css(d.cssAfter);d.sync||n()});d.sync&&n()};f.fn.cycle.transitions={fade:function(b,a,d){a.not(":eq("+d.currSlide+")").css("opacity",0);d.before.push(function(b,a,d){f.fn.cycle.commonReset(b,a,d);d.cssBefore.opacity=0});d.animIn={opacity:1};d.animOut={opacity:0};d.cssBefore={top:0,left:0}}};f.fn.cycle.ver=function(){return"2.9997"};f.fn.cycle.defaults={activePagerClass:"activeSlide",after:null,allowPagerClickBubble:false,animIn:null,animOut:null,aspect:false,autostop:0,autostopCount:0,backwards:false,before:null,center:null,cleartype:!f.support.opacity,cleartypeNoBg:false,containerResize:1,continuous:0,cssAfter:null,cssBefore:null,delay:0,easeIn:null,easeOut:null,easing:null,end:null,fastOnEvent:0,fit:0,fx:"fade",fxFn:null,height:"auto",manualTrump:true,metaAttr:"cycle",next:null,nowrap:0,onPagerEvent:null,onPrevNextEvent:null,pager:null,pagerAnchorBuilder:null,pagerEvent:"click.cycle",pause:0,pauseOnPagerHover:0,prev:null,prevNextEvent:"click.cycle",random:0,randomizeEffects:1,requeueOnImageNotLoaded:true,requeueTimeout:250,rev:0,shuffle:null,skipInitializationCallbacks:false,slideExpr:null,slideResize:1,speed:1E3,speedIn:null,speedOut:null,startingSlide:0,sync:1,timeout:4E3,timeoutFn:null,updateActivePagerLink:null,width:null}})(jQuery);(function(f){f.fn.cycle.transitions.none=function(c,h,a){a.fxFn=function(a,c,d,h){f(c).show();f(a).hide();h()}};f.fn.cycle.transitions.fadeout=function(c,h,a){h.not(":eq("+a.currSlide+")").css({display:"block",opacity:1});a.before.push(function(a,c,d,h,n,m){f(a).css("zIndex",d.slideCount+(!m===true?1:0));f(c).css("zIndex",d.slideCount+(!m===true?0:1))});a.animIn.opacity=1;a.animOut.opacity=0;a.cssBefore.opacity=1;a.cssBefore.display="block";a.cssAfter.zIndex=0};f.fn.cycle.transitions.scrollUp=function(c,h,a){c.css("overflow","hidden");a.before.push(f.fn.cycle.commonReset);c=c.height();a.cssBefore.top=c;a.cssBefore.left=0;a.cssFirst.top=0;a.animIn.top=0;a.animOut.top=-c};f.fn.cycle.transitions.scrollDown=function(c,h,a){c.css("overflow","hidden");a.before.push(f.fn.cycle.commonReset);c=c.height();a.cssFirst.top=0;a.cssBefore.top=-c;a.cssBefore.left=0;a.animIn.top=0;a.animOut.top=c};f.fn.cycle.transitions.scrollLeft=function(c,h,a){c.css("overflow","hidden");a.before.push(f.fn.cycle.commonReset);c=c.width();a.cssFirst.left=0;a.cssBefore.left=c;a.cssBefore.top=0;a.animIn.left=0;a.animOut.left=0-c};f.fn.cycle.transitions.scrollRight=function(c,h,a){c.css("overflow","hidden");a.before.push(f.fn.cycle.commonReset);c=c.width();a.cssFirst.left=0;a.cssBefore.left=-c;a.cssBefore.top=0;a.animIn.left=0;a.animOut.left=c};f.fn.cycle.transitions.scrollHorz=function(c,h,a){c.css("overflow","hidden").width();a.before.push(function(a,c,d,h){d.rev&&(h=!h);f.fn.cycle.commonReset(a,c,d);d.cssBefore.left=h?c.cycleW-1:1-c.cycleW;d.animOut.left=h?-a.cycleW:a.cycleW});a.cssFirst.left=0;a.cssBefore.top=0;a.animIn.left=0;a.animOut.top=0};f.fn.cycle.transitions.scrollVert=function(c,h,a){c.css("overflow","hidden");a.before.push(function(a,c,d,h){d.rev&&(h=!h);f.fn.cycle.commonReset(a,c,d);d.cssBefore.top=h?1-c.cycleH:c.cycleH-1;d.animOut.top=h?a.cycleH:-a.cycleH});a.cssFirst.top=0;a.cssBefore.left=0;a.animIn.top=0;a.animOut.left=0};f.fn.cycle.transitions.slideX=function(c,h,a){a.before.push(function(a,c,d){f(d.elements).not(a).hide();f.fn.cycle.commonReset(a,c,d,false,true);d.animIn.width=c.cycleW});a.cssBefore.left=0;a.cssBefore.top=0;a.cssBefore.width=0;a.animIn.width="show";a.animOut.width=0};f.fn.cycle.transitions.slideY=function(c,h,a){a.before.push(function(a,c,d){f(d.elements).not(a).hide();f.fn.cycle.commonReset(a,c,d,true,false);d.animIn.height=c.cycleH});a.cssBefore.left=0;a.cssBefore.top=0;a.cssBefore.height=0;a.animIn.height="show";a.animOut.height=0};f.fn.cycle.transitions.shuffle=function(c,h,a){c=c.css("overflow","visible").width();h.css({left:0,top:0});a.before.push(function(a,c,d){f.fn.cycle.commonReset(a,c,d,true,true,true)});if(!a.speedAdjusted)a.speed/=2,a.speedAdjusted=true;a.random=0;a.shuffle=a.shuffle||{left:-c,top:15};a.els=[];for(c=0;c<h.length;c++)a.els.push(h[c]);for(c=0;c<a.currSlide;c++)a.els.push(a.els.shift());a.fxFn=function(a,c,d,h,n){d.rev&&(n=!n);var m=n?f(a):f(c);f(c).css(d.cssBefore);var q=d.slideCount;m.animate(d.shuffle,d.speedIn,d.easeIn,function(){for(var c=f.fn.cycle.hopsFromLast(d,n),j=0;j<c;j++)n?d.els.push(d.els.shift()):d.els.unshift(d.els.pop());if(n){c=0;for(j=d.els.length;c<j;c++)f(d.els[c]).css("z-index",j-c+q)}else c=f(a).css("z-index"),m.css("z-index",parseInt(c,10)+1+q);m.animate({left:0,top:0},d.speedOut,d.easeOut,function(){f(n?this:a).hide();h&&h()})})};f.extend(a.cssBefore,{display:"block",opacity:1,top:0,left:0})};f.fn.cycle.transitions.turnUp=function(c,h,a){a.before.push(function(a,c,d){f.fn.cycle.commonReset(a,c,d,true,false);d.cssBefore.top=c.cycleH;d.animIn.height=c.cycleH;d.animOut.width=c.cycleW});a.cssFirst.top=0;a.cssBefore.left=0;a.cssBefore.height=0;a.animIn.top=0;a.animOut.height=0};f.fn.cycle.transitions.turnDown=function(c,h,a){a.before.push(function(a,c,d){f.fn.cycle.commonReset(a,c,d,true,false);d.animIn.height=c.cycleH;d.animOut.top=a.cycleH});a.cssFirst.top=0;a.cssBefore.left=0;a.cssBefore.top=0;a.cssBefore.height=0;a.animOut.height=0};f.fn.cycle.transitions.turnLeft=function(c,h,a){a.before.push(function(a,c,d){f.fn.cycle.commonReset(a,c,d,false,true);d.cssBefore.left=c.cycleW;d.animIn.width=c.cycleW});a.cssBefore.top=0;a.cssBefore.width=0;a.animIn.left=0;a.animOut.width=0};f.fn.cycle.transitions.turnRight=function(c,h,a){a.before.push(function(a,c,d){f.fn.cycle.commonReset(a,c,d,false,true);d.animIn.width=c.cycleW;d.animOut.left=a.cycleW});f.extend(a.cssBefore,{top:0,left:0,width:0});a.animIn.left=0;a.animOut.width=0};f.fn.cycle.transitions.zoom=function(c,h,a){a.before.push(function(a,c,d){f.fn.cycle.commonReset(a,c,d,false,false,true);d.cssBefore.top=c.cycleH/2;d.cssBefore.left=c.cycleW/2;f.extend(d.animIn,{top:0,left:0,width:c.cycleW,height:c.cycleH});f.extend(d.animOut,{width:0,height:0,top:a.cycleH/2,left:a.cycleW/2})});a.cssFirst.top=0;a.cssFirst.left=0;a.cssBefore.width=0;a.cssBefore.height=0};f.fn.cycle.transitions.fadeZoom=function(c,h,a){a.before.push(function(a,c,d){f.fn.cycle.commonReset(a,c,d,false,false);d.cssBefore.left=c.cycleW/2;d.cssBefore.top=c.cycleH/2;f.extend(d.animIn,{top:0,left:0,width:c.cycleW,height:c.cycleH})});a.cssBefore.width=0;a.cssBefore.height=0;a.animOut.opacity=0};f.fn.cycle.transitions.blindX=function(c,h,a){c=c.css("overflow","hidden").width();a.before.push(function(a,c,d){f.fn.cycle.commonReset(a,c,d);d.animIn.width=c.cycleW;d.animOut.left=a.cycleW});a.cssBefore.left=c;a.cssBefore.top=0;a.animIn.left=0;a.animOut.left=c};f.fn.cycle.transitions.blindY=function(c,h,a){c=c.css("overflow","hidden").height();a.before.push(function(a,c,d){f.fn.cycle.commonReset(a,c,d);d.animIn.height=c.cycleH;d.animOut.top=a.cycleH});a.cssBefore.top=c;a.cssBefore.left=0;a.animIn.top=0;a.animOut.top=c};f.fn.cycle.transitions.blindZ=function(c,h,a){h=c.css("overflow","hidden").height();c=c.width();a.before.push(function(a,c,d){f.fn.cycle.commonReset(a,c,d);d.animIn.height=c.cycleH;d.animOut.top=a.cycleH});a.cssBefore.top=h;a.cssBefore.left=c;a.animIn.top=0;a.animIn.left=0;a.animOut.top=h;a.animOut.left=c};f.fn.cycle.transitions.growX=function(c,h,a){a.before.push(function(a,c,d){f.fn.cycle.commonReset(a,c,d,false,true);d.cssBefore.left=this.cycleW/2;d.animIn.left=0;d.animIn.width=this.cycleW;d.animOut.left=0});a.cssBefore.top=0;a.cssBefore.width=0};f.fn.cycle.transitions.growY=function(c,h,a){a.before.push(function(a,c,d){f.fn.cycle.commonReset(a,c,d,true,false);d.cssBefore.top=this.cycleH/2;d.animIn.top=0;d.animIn.height=this.cycleH;d.animOut.top=0});a.cssBefore.height=0;a.cssBefore.left=0};f.fn.cycle.transitions.curtainX=function(c,h,a){a.before.push(function(a,c,d){f.fn.cycle.commonReset(a,c,d,false,true,true);d.cssBefore.left=c.cycleW/2;d.animIn.left=0;d.animIn.width=this.cycleW;d.animOut.left=a.cycleW/2;d.animOut.width=0});a.cssBefore.top=0;a.cssBefore.width=0};f.fn.cycle.transitions.curtainY=function(c,h,a){a.before.push(function(a,c,d){f.fn.cycle.commonReset(a,c,d,true,false,true);d.cssBefore.top=c.cycleH/2;d.animIn.top=0;d.animIn.height=c.cycleH;d.animOut.top=a.cycleH/2;d.animOut.height=0});a.cssBefore.height=0;a.cssBefore.left=0};f.fn.cycle.transitions.cover=function(c,h,a){var i=a.direction||"left",j=c.css("overflow","hidden").width(),d=c.height();a.before.push(function(a,c,h){f.fn.cycle.commonReset(a,c,h);i=="right"?h.cssBefore.left=-j:i=="up"?h.cssBefore.top=d:i=="down"?h.cssBefore.top=-d:h.cssBefore.left=j});a.animIn.left=0;a.animIn.top=0;a.cssBefore.top=0;a.cssBefore.left=0};f.fn.cycle.transitions.uncover=function(c,h,a){var i=a.direction||"left",j=c.css("overflow","hidden").width(),d=c.height();a.before.push(function(a,c,h){f.fn.cycle.commonReset(a,c,h,true,true,true);i=="right"?h.animOut.left=j:i=="up"?h.animOut.top=-d:i=="down"?h.animOut.top=d:h.animOut.left=-j});a.animIn.left=0;a.animIn.top=0;a.cssBefore.top=0;a.cssBefore.left=0};f.fn.cycle.transitions.toss=function(c,h,a){var i=c.css("overflow","visible").width(),j=c.height();a.before.push(function(a,c,h){f.fn.cycle.commonReset(a,c,h,true,true,true);!h.animOut.left&&!h.animOut.top?f.extend(h.animOut,{left:i*2,top:-j/2,opacity:0}):h.animOut.opacity=0});a.cssBefore.left=0;a.cssBefore.top=0;a.animIn.left=0};f.fn.cycle.transitions.wipe=function(c,h,a){var i=c.css("overflow","hidden").width(),j=c.height();a.cssBefore=a.cssBefore||{};var d;a.clip&&(/l2r/.test(a.clip)?d="rect(0px 0px "+j+"px 0px)":/r2l/.test(a.clip)?d="rect(0px "+i+"px "+j+"px "+i+"px)":/t2b/.test(a.clip)?d="rect(0px "+i+"px 0px 0px)":/b2t/.test(a.clip)?d="rect("+j+"px "+i+"px "+j+"px 0px)":/zoom/.test(a.clip)&&(c=parseInt(j/2,10),h=parseInt(i/2,10),d="rect("+c+"px "+h+"px "+c+"px "+h+"px)"));a.cssBefore.clip=a.cssBefore.clip||d||"rect(0px 0px 0px 0px)";var c=a.cssBefore.clip.match(/(\d+)/g),l=parseInt(c[0],10),n=parseInt(c[1],10),m=parseInt(c[2],10),q=parseInt(c[3],10);a.before.push(function(a,c,d){if(a!=c){var h=f(a),v=f(c);f.fn.cycle.commonReset(a,c,d,true,true,false);d.cssAfter.display="block";var b=1,g=parseInt(d.speedIn/13,10)-1;(function D(){var a=l?l-parseInt(b*(l/g),10):0,c=q?q-parseInt(b*(q/g),10):0,d=m<j?m+parseInt(b*((j-m)/g||1),10):j,f=n<i?n+parseInt(b*((i-n)/g||1),10):i;v.css({clip:"rect("+a+"px "+f+"px "+d+"px "+c+"px)"});b++<=g?setTimeout(D,13):h.css("display","none")})()}});f.extend(a.cssBefore,{display:"block",opacity:1,top:0,left:0});a.animIn={left:0};a.animOut={left:0}}})(jQuery);
