//var j = jQuery.noConflict();

$(window).load(function() {
	$('#headerimg').nivoSlider({
		effect:'fold', //Specify sets like: 'fold,fade,sliceDown'
		//slices:15,
		animSpeed:500, //Slide transition speed
		pauseTime:3000,
		startSlide:0, //Set starting Slide (0 index)
		directionNav:false, //Next & Prev
		directionNavHide:false, //Only show on hover
		controlNav:false, //1,2,3...
		controlNavThumbs:false, //Use thumbnails for Control Nav
      controlNavThumbsFromRel:false, //Use image rel for thumbs
		//controlNavThumbsSearch: '.jpg', //Replace this with...
		//controlNavThumbsReplace: '_thumb.jpg', //...this in thumb Image src
		keyboardNav:false, //Use left & right arrows
		pauseOnHover:false, //Stop animation while hovering
		manualAdvance:false, //Force manual transitions
		captionOpacity:0.8, //Universal caption opacity
		beforeChange: function(){},
		afterChange: function(){},
		slideshowEnd: function(){} //Triggers after all slides have been shown
	});
});

$(document).ready(function(){
  
  $('#menu ul li').hover(function(){
    $(this).children('.sub_menu').fadeIn(400);
  },function(){
    $(this).children('.sub_menu').hide();
  });
  $('.sub_menu ul li').hover(function(){
    $(this).children('.sub_menu1').fadeIn(400);
  },function(){
    $(this).children('.sub_menu1').hide();
  });
  $(function() {
    $('#content .one_col a div img').parent().parent().lightBox();
  });

	// Sizing
	var elem = $(window);
  var ell = elem.width();
  //alert(ell);
  $('.head_img').css({'width' : ell});
  // END Sizing

});
  
// Snow
/*
container='container';
snow_intensive=400; 
snow_speed=20000; 
snow_src=new Array('/images/sneg1.gif','/images/sneg2.gif','/images/sneg3.gif','/images/sneg4.png'); 

$(document).ready(snow_start); 

function snow_start() { 
	snow_id=1; 
	snow_y=$("#" + container).height()-30; 
	setInterval(function() { 
		snow_x=Math.random()*document.body.offsetWidth-100; 
		snow_img=(snow_src instanceof Array ? snow_src[Math.floor(Math.random()*snow_src.length)] : snow_src); 
		snow_elem='<img class="png" id="snow'+snow_id+'" style="position:absolute; left:'+snow_x+'px; top:0;z-index:10000" src="'+snow_img+'">'; 
		$("#" + container).append(snow_elem); 
		snow_move(snow_id); 
		snow_id++; 
	},snow_intensive);
} 
	
function snow_move(id) { 
	$('#snow'+id).animate({top:snow_y,left:"+="+Math.random()*100},snow_speed,function() { 
	$(this).empty().remove(); 
});}
*/
// END Snow
