jQuery().ready(function(){
	// simple Accordion
	jQuery('#list1').Accordion();
	jQuery('#list2').Accordion();
	jQuery('#list3').Accordion();
	jQuery('#list4').Accordion();
	jQuery('#list5').Accordion();
	jQuery('#list6').Accordion();
	// second simple Accordion with special markup
	jQuery('#navigation').Accordion({
		active: false,
		header: '.head',
		navigation: true,
		event: 'mouseover',
		autoheight: true,
		animated: 'easeslide'
	});
	
	// highly customized Accordion
	
	// first simple Accordion with special markup
	
	var wizard = $("#wizard").Accordion({
		header: '.title',
		event: false
	});
	
	$("div.title", wizard).each(function(index) {
		$(this)
		.next()
		.children(":button")
		.filter(".next, .previous")
		.click(function() {
			wizard.activate(index + ($(this).is(".next") ? 1 : -1))
		});
	});
	
	// bind to change event of select to control first and seconds accordion
	// similar to tab's plugin triggerTab(), without an extra method
	jQuery('#switch select').change(function() {
		jQuery('#list1, #list2, #list3, #list4, #list5, #list6, #navigation').activate( this.selectedIndex-1 );
	});
	jQuery('#close').click(function() {
		jQuery('#list1, #list2, #list3, #list4, #list5, #list6, #navigation').activate(-1);
	});
	jQuery('#switch2').change(function() {
		jQuery('#list1, #list2, #list3, #list4, #list5, #list6, #navigation').activate(this.value);
	});
	
});