(function(){var H=YAHOO.util.Dom;var J=YAHOO.util.Anim;var A=YAHOO.util.Event;var E=5000;var G=true;var P=false;var D;var M;var F;function B(R,Q){if("undefined"===typeof R){return Q}return R}function O(R,Q){Q=B(Q,{});var U=B(Q.force,false);var V=B(Q.duration,0.5);for(var T=0;T<D.length;T++){var S=D[T];S.stop();if(T==R){S.show({duration:V})}else{S.hide({duration:V})}}F=R}var C=function(S,Q,T){this.panel=S;this.trigger=Q;this.panel_anim=null;this.trigger_anim=null;this.id=T;var R=this;A.addListener(this.trigger,"mouseover",function(){O(R.id,{duration:0.2})});this.stop=function(){if(this.panel_anim){this.panel_anim.stop();this.panel_anim=null}if(this.trigger_anim){this.trigger_anim.stop();this.trigger_anim=null}};this.show=function(U){U=B(U,{});var V=B(U.duration,0.5);H.setStyle(this.panel,"visibility","visible");this.panel_anim=new J(this.panel,{opacity:{to:1}},V);this.panel_anim.onComplete.subscribe(function(){R.panel_anim=null});this.panel_anim.animate();this.trigger_anim=new J(this.trigger,{opacity:{to:1},marginBottom:{to:10}},V);this.trigger_anim.onComplete.subscribe(function(){R.trigger_anim=null});this.trigger_anim.animate()};this.hide=function(U){U=B(U,{});var V=B(U.duration,0.5);this.panel_anim=new J(this.panel,{opacity:{to:0}},V);this.panel_anim.onComplete.subscribe(function(){R.panel_anim=null;H.setStyle(R.panel,"visibility","hidden")});this.panel_anim.animate();this.trigger_anim=new J(this.trigger,{opacity:{to:0.5},marginBottom:{to:0}},V);this.trigger_anim.onComplete.subscribe(function(){R.trigger_anim=null});this.trigger_anim.animate()}};function I(){trigger_ids=["feature_trigger_1","feature_trigger_2","feature_trigger_3"];var R=H.getChildren("feature_panels");D=[];for(var Q=0;Q<R.length;Q++){D[Q]=new C(R[Q],H.get(trigger_ids[Q]),Q)}A.addListener(H.get("feature_container"),"mouseover",function(){P=true});A.addListener(H.get("feature_container"),"mouseout",function(){P=false});F=2}function L(Q){Q=Q%D.length;return D[Q]}function N(Q){Q=Q%M.length;return M[Q]}function K(){if(G&&!P){O((F+1)%D.length)}setTimeout(K,E)}I();K()})();