$(window).load(function() {
    $('#slider').nivoSlider({
	effect:'fade',
	slices:15,
	animSpeed:500,
	pauseTime:5000,
	directionNav:true, //Next & Prev
	directionNavHide:false, //Only show on hover
	controlNav:false, //1,2,3...
	pauseOnHover:true, //Stop animation while hovering
	beforeChange: function(){},
	afterChange: function(){}
    });
});
$(document).ready(function(){
    
    // Recruitment tabs
    var tabContainers = $('div.tabs > div');
    tabContainers.hide().filter(':first').show();
    
    $('div.tabs .nav a').click(function () {
	
	tabContainers.hide();
	tabContainers.filter(this.hash).show();
	$('div.tabs .nav a').removeClass('current_item');
	$(this).addClass('current_item');
	return false;
    }).filter(':first').click();
    
 
 
    
    // Fancybox Initiate
/*
    $(".screenshots a[@rel=" + el.rel + "]").lightBox();
*/

$('.screenshots').each(function(){
            $('a', this).lightBox();
        });


/*       
    $(".iframe_recent_news").fancybox({
	'titlePosition'		: 'inside',
	'transitionIn'		: 'none',
	'transitionOut'		: 'none'
    });
    
 
$('.iframe_recent_news').live('hover', function(){
    $(".iframe_recent_news").fancybox({
	'titlePosition'		: 'inside',
	'transitionIn'		: 'none',
	'transitionOut'		: 'none'
    });
});

*/



    $('#home_recent_news .controls a').live('click', function(){
	
	var toLoad = $(this).attr('href');
	
	$("#recent_news_list").load(toLoad);
	
	return false;
    });




});

// Initiate Cufon
Cufon.replace('.page_title');