﻿$(function() {
    $('#outer h4.expand').wrapInner('<a style="display:block" href="#" title="expand/collapse"></a>');
   
    //demo 1 - div.demo:eq(0) - Accordion slide effect with first section initially expanded
    $('#outer div.demo:eq(0)').find('h4.expand:eq(0)').addClass('open').end()
    .find('div.collapse:gt(0)').hide().end()
    .find('h4.expand').click(function() {
        $(this).toggleClass('open').siblings().removeClass('open').end()
        .next('div.collapse').slideToggle().siblings('div.collapse:visible').slideUp();
        return false;
    });
    
    $('#outer div.demo:eq(1)').find('h4.expand:eq(0)').addClass('open').end()
    .find('div.collapse:gt(0)').hide().end()
    .find('h4.expand').click(function() {
        $(this).toggleClass('open').siblings().removeClass('open').end()
        .next('div.collapse').slideToggle().siblings('div.collapse:visible').slideUp();
        return false;
    });
    
    $('#outer div.demo:eq(2)').find('h4.expand:eq(0)').addClass('open').end()
    .find('div.collapse:gt(0)').hide().end()
    .find('h4.expand').click(function() {
        $(this).toggleClass('open').siblings().removeClass('open').end()
        .next('div.collapse').slideToggle().siblings('div.collapse:visible').slideUp();
        return false;
    });
    
    $('#outer div.demo:eq(3)').find('h4.expand:eq(0)').addClass('open').end()
    .find('div.collapse:gt(0)').hide().end()
    .find('h4.expand').click(function() {
        $(this).toggleClass('open').siblings().removeClass('open').end()
        .next('div.collapse').slideToggle().siblings('div.collapse:visible').slideUp();
        return false;
    });
    

/*    
    //demo 2 - div.demo:eq(1) - Accordion slide effect with first section initially expanded. Always keeps one section visible 
    $('#outer div.demo:eq(1)').find('h4.expand:eq(0)').addClass('open').end()
    .find('div.collapse:gt(0)').hide().end()
    .find('h4.expand').click(function() {
        $(this).addClass('open').siblings().removeClass('open').end()
        .next('div.collapse:hidden').slideToggle().siblings('div.collapse:visible').slideUp();
        return false;
    });
    
    //demo 3 - div.demo:eq(2) - Queued Slide Effects 
   
    $('#outer div.demo:eq(2)').find('h4.expand:eq(0)').addClass('open').end()
    .find('div.collapse:gt(0)').hide().end()
    .find('h4.expand').each(function() {
          $(this).click(function() {
          
              var $thisCllps = $(this).next('div.collapse');
              var $cllpsVisible = $(this).siblings('h4.expand').next('div.collapse:visible');
              
              ($cllpsVisible.length) ? $(this).toggleClass('open').siblings('h4.expand').removeClass('open')
                  .next('div.collapse:visible').slideUp('fast', function() {
                  $thisCllps.slideDown();
                  }) : $(this).toggleClass('open').next('div.collapse').slideToggle();
              return false;
          });
     });*/

});

<!--//--><![CDATA[//><!--
$("html").addClass("js");
$(function() {
    $("html").removeClass("js");
});
//--><!]]>



$(document).ready(function(){
	
		
		/* $('btn1 a').bt({ 
			hoverIntentOpts: 
			{ 
    			interval: 0, timeout: 0 
    		},
    		
    		width: 350, 
    		strokeWidth: 0, 
		    fill:'#D202FF', 
		    spikeLength: 20, 
		    spikeGirth: 30, 
		    padding: 20, 
		    cornerRadius: 10, 
		    cssClass: 'answer', 
		    cssStyles: { }, 
		    closeWhenOthersOpen: true, 
		    positions: ['top', 'right', 'bottom'], 
		    windowMargin: 20 
    		}); */
   
	$('#rotator').cycle({
		fx: 'scrollHorz',
		timeout: 3000,
		pause: 1,
		next: '#next',
		prev: '#back',
		speed: 300,
		/*easing: 'easeOutCirc'*/ 
	});
});




