Cufon.replace('ul.topnav li a.main',  {
   textShadow: '#403d3e -1px -1px', 
   hover: true,
   fontFamily: 'DINOT-CondMedium'
}); 

Cufon.replace('#copy h1',  {
   textShadow: '#ffffff -1px -1px',
   fontFamily: 'DINOT-CondMedium'
}); 

Cufon.replace('#content_header h1',  {
   textShadow: '#3c3a3b -1px -1px',
   fontFamily: 'DINOT-CondMedium'
}); 

Cufon.replace('#copy h2', { 
	textShadow: '#ffffff -1px -1px',			  
	fontFamily: 'felttip'
});

Cufon.replace('#copy h3', { 
	textShadow: '#ffffff -1px -1px',			  
	fontFamily: 'felttip'
});

Cufon.replace('h2#zindex', { 
	textShadow: '#393536 -1px -1px',			  
	fontFamily: 'felttip'
});

Cufon.replace('#whatsdoing_header h2', { 
	textShadow: '#393536 -1px -1px',			  
	fontFamily: 'felttip'
});

Cufon.replace('.gallery_container span', { 
	textShadow: '#ffffff -1px -1px',			  
	fontFamily: 'felttip'
});



$(document).ready(function(){

	$("ul.topnav li a").click(function() { //When trigger is clicked...
		//Following events are applied to the subnav itself (moving subnav up and down)
		$(this).parent().find("ul.subnav").slideDown('fast').show(); //Drop down the subnav on click
				
		$(this).parent().hover(function() {
		}, function(){
			$(this).parent().find("ul.subnav").slideUp('fast'); //When the mouse hovers out of the subnav, move it back up
		});

		//Following events are applied to the trigger (Hover events for the trigger)
		}).hover(function() {
			$(this).addClass("subhover"); //On hover over, add class "subhover"
		}, function(){	//On Hover Out
			$(this).removeClass("subhover"); //On hover out, remove class "subhover"
	});
	
	$('.itinerary tr:even').addClass('alt'); 
	
	$('#right_whatsdoing ul').bxSlider({
	        prev_image: 'http://www.pngtours.com/images/btn_arrow_left.jpg',
	        next_image: 'http://www.pngtours.com/images/btn_arrow_right.jpg',
	        wrapper_class: 'slides_wrap',
	        margin: 70,
			pause: 8000,
	        auto: false,
	        auto_controls: false
	 });
	
	var num=$('.itinerary').length;

	if(num > 5)
	{
		$('.itinerary').addClass('list');
		$('.itinerary td').removeAttr('align');
	}

});

$(function() {
	$('a.lightbox').lightBox({
	txtImage: 'Image',
	txtOf: 'of'
   });

});

function slideSwitch() {
    var $active = $('#slideshow_inner IMG.active');

    if ( $active.length == 0 ) $active = $('#slideshow_inner IMG:last');

    // use this to pull the images in the order they appear in the markup
    var $next =  $active.next().length ? $active.next()
        : $('#slideshow_inner IMG:first');

    // uncomment the 3 lines below to pull the images in random order
    
    // var $sibs  = $active.siblings();
    // var rndNum = Math.floor(Math.random() * $sibs.length );
    // var $next  = $( $sibs[ rndNum ] );


    $active.addClass('last-active');

    $next.css({opacity: 0.0})
        .addClass('active')
        .animate({opacity: 1.0}, 1000, function() {
            $active.removeClass('active last-active');
        });
}

$(function() {
    setInterval( "slideSwitch()", 5000 );
});


