// JavaScript Document
jQuery.noConflict();

(function($) {
	// Validate contact form 
	$("#contactForm").validator();
	
	// Create hover-over effects for gallery thumbnails
	$('#example_6_frame img').fadeTo("fast", 0.6);
	
	$('#example_6_frame img').hover(function(){   
		$(this).stop().fadeTo("fast", 1.0);   
	},function(){ 	
		$(this).stop().fadeTo("fast", 0.6);   
	});	
	
	// Initialize thumbnail carousel
	$('#thumbCarousel').jcarousel();
	
	// Add jQuery effects to dropdown menus
	$('li.dropDown ul').css('display','none');
	
	$('li.dropDown').hover(function(){
		$(this).addClass('hoveredOver');
		$('li.hoveredOver ul').stop().fadeTo(200, 1.0);
	},function(){
		$('li.hoveredOver ul').stop().fadeTo(200, 0.0);
		$(this).removeClass('hoveredOver');
	});
	
	
	// Fix carousel width for larger galleries
	var exampleWidth = $('#example_6_content').width();
	var newWidth = exampleWidth * 3;
	$('#example_6_content').css('width',newWidth);
	

})(jQuery);
