Ext.onReady(function(){
	var banner = Ext.get('home-banner');
	var h1 = Ext.select('#home-banner h1');
	banner.origHeight = banner.getHeight();
	banner.origWidth = banner.getWidth();
	banner.origY = banner.getY();;
	Ext.select('a.expander').on('click',function(){
		var me = Ext.get(this);
		if(me.hasClass('open')){
			h1.fadeOut({
				duration:0.2,
				useDisplay:true,
				callback:function(){
					banner.shift({
						width:125,
						height:30,
						easing:'easeOut',
						y:banner.origY,
						callback:function(){
							me.dom.innerHTML = me.dom.innerHTML.replace('-','+');
							me.removeClass('open');
							me.addClass('close');
						}
					});
			}});
		} else if (me.hasClass('close')){
			banner.shift({
				width:854,
				height:162,
				easing:'easeOut',
				y:385,
				callback:function(){
					h1.fadeIn({duration:0.2});
					me.dom.innerHTML = me.dom.innerHTML.replace('+','-');
					me.removeClass('close');
					me.addClass('open');
				}
			});
		}
	});
});
