jQuery(document).ready(function(){
	//Enable Tooltips
	jQuery('.small-tooltip').tooltip({effect: 'fade', tipClass: 'tooltip_small'});
	jQuery('.big-tooltip').tooltip({effect: 'fade', tipClass: 'tooltip_big'});
	// Easy jQuery Accordion (a bit customized)
	jQuery('#Accordion div.stretcher').hide();
	jQuery('#Accordion h6.toggle:first').removeClass('toggle').addClass('toggle_active');
	jQuery('#Accordion div.stretcher:first').show();
	jQuery('#Accordion h6').bind('click', function() {
		if ( jQuery(this).next().css('display') == 'none' ) {
			jQuery('#Accordion div.stretcher').each(function(){
				if (jQuery(this).next().css('display') == 'block') {
					jQuery(this).slideUp(300);
				}
			});
			jQuery('#Accordion h6.toggle_active').each(function(){
				jQuery(this).removeClass('toggle_active').addClass('toggle');
			});
			jQuery(this).next().slideDown(300);
			jQuery(this).addClass('toggle_active');
		} else {
			jQuery(this).next().slideUp(300);
			jQuery(this).removeClass('toggle_active').addClass('toggle');
		}
	});
	// Enable tabulators (Accessories at classic overview)
	jQuery(function() {
		jQuery('ul.tabulators').tabs('div.panes > div', {effect: 'fade', fadeOutSpeed: 400});
	});
	// Enable Image carousel for preview of image thumbnails
	jQuery(".image_carousel").scrollable({mousewheel: true});
	// Create an overlay including tabs (image preview)
	//jQuery('a[rel]').overlay({mask: '#ffffff'});
	//jQuery('.ImgPrevLinks').tabs('.images > div', {effect: 'fade', rotate: true}).slideshow();
	// Enable Quick scroll
	if(jQuery('.scrollToDesc')){
		jQuery('.scrollToDesc').click(function(){jQuery('html').animate({scrollTop: jQuery('#descr').offset().top}, 800);});
	}
	if(jQuery('.scrollToSpec')){
		jQuery('.scrollToSpec').click(function(){jQuery('html').animate({scrollTop: jQuery('#spec').offset().top}, 800);});
	}
	if(jQuery('.scrollToTech')){
		jQuery('.scrollToTech').click(function(){jQuery('html').animate({scrollTop: jQuery('#techdat').offset().top}, 800);});
	}
	if(jQuery('.scrollToTop')){
		jQuery('.scrollToTop').click(function(){jQuery('html').animate({scrollTop: 0}, 800);});
	}
	jQuery('a.setOverlay[rel]').overlay({effect: 'apple'});
	// Download area styles to set at the beginning
	jQuery('.user-productpresentation-pi2 #spinner').hide();
	jQuery('#download-area .step:first').show();
});