window.addEvent('domready', function() {

	new SmoothScroll();
	var faqmenu = new Accordion('div.faq h3', 'div.faq div.csc-textpic', { display: -1, alwaysHide: true } );
	
	$$('.produkt-neuheit').each(function(element,index) {  
		var content = element.get('title').split('::');  
		element.store('tip:title', content[0]);  
		element.store('tip:text', content[1]);  
	});  

	var myTips = new Tips($$('.produkt-neuheit'), {className: 'transparent',offsets :{'x': 20, 'y': 20} });
	myTips.addEvents({
		'show': function(tip) { tip.set('tween', {duration: 250}).fade('in'); },  
		'hide': function(tip) { tip.set('tween', {duration: 0}).fade('out'); }
	});

	
	var home_slideshow = new noobSlide({
		box: $('home_slideshow_box'),
		items: $$('#home_slideshow_box div.element'),
		size: 320,
		interval: 8000,
		fxOptions: { duration: 700 },
		autoPlay: true,
		handles: $$('#home_slideshow .handles p'),
		addButtons: {next: $('slide_next'),previous: $('slide_previous')}, 
		onWalk: function(currentItem,currentHandle){
			this.handles.removeClass('active');
			currentHandle.addClass('active');
		}
	});

});
