
previewStiri=function()
{
	if ($('nextStire'))
		$('nextStire').onclick=function(){
		var showNext=false;
		var first=false;								  
		$$('.stire').each(function(item){
			if (!first)
				first=item;
			if (showNext)
			{
				item.appear({duration:0.3});
				showNext=false;
			}
			else
				if (item.visible())
				{
					item.fade({duration:0.3});
					showNext=true;
				}
		})	
		if (showNext)	
			first.appear({duration:0.3});
		};

	if ($('prevStire'))
		$('prevStire').onclick=function(){
		var gasit=false;							   
		var ilast=false;
		$$('.stire').each(function(item){
			if (item.visible())
			{
				item.fade({duration:0.3});
				if (ilast)
				{
					ilast.appear({duration:0.3});
					gasit=true;
				}
			}
		ilast=item;	
		})	
		if (!gasit)	
		{
			ilast.appear({duration:0.3});
		}
			
			
		};

$$('.newsletterclip').each(function(item) { 
		item.onclick=function() { 
		Element.removeClassName.delay(0.3,'news-div','nw-div');
		Element.addClassName.delay(0.3,'news-div','nw-div-over');
		Element.removeClassName.delay(0.8,'news-div','nw-div-over');
		Element.addClassName.delay(0.8,'news-div','nw-div');
		
		Element.removeClassName.delay(1.2,'news-div','nw-div');
		Element.addClassName.delay(1.2,'news-div','nw-div-over');
		Element.removeClassName.delay(1.8,'news-div','nw-div-over');
		Element.addClassName.delay(1.8,'news-div','nw-div');

/*		$('news-div').highlight({startcolor:"#FFFFFF",endcolor:"#900B09",duration: 0.5});
		$('newsletterbox').highlight({startcolor:"#FFFFFF",endcolor:"#900B09",restorecolor: "#900B09",duration: 0.5,queue:'end'});
		$('newsletterbox').highlight({startcolor:"#900B09",endcolor:"#FFFFFF",restorecolor: "#FFFFFF",duration: 0.5,queue:'end'});*/
		}									
		})
}





document.observe("dom:loaded", function() {  previewStiri();  }); 
