/////////////////////////// PAGE LOADER GRAPHIC
	function contentLoaded() {
		$("div#loaderContainer").hide();
		$("div#content").fadeIn(1000);
	}

$(document).ready(function () {
	
	/////////////////////////// LOGO ROLLOVER FADE
		$('h1#logo a, #homepageImage').hover(
			function() {
				$(this).stop().fadeTo(250, 0.7);
			},
			function() {
				$(this).stop().fadeTo(300, 1);
			}
		);
		$('a.zoom, a.thumbMedium').hover(
			function() {
				$(this).stop().fadeTo(250, 0.7);
			},
			function() {
				$(this).stop().fadeTo(300, 1);
			}
		);
		
	/////////////////////////// SET-UP FOR ROLLOVER FADE EFFECT 
			$(function(){
				$(".fademe").jFade({
					trigger: "mouseover",
					property: 'color',
					start: '333333',
					end: '77307D',
					steps: 14,
					duration: 12
				}).jFade({
					trigger: "mouseout",
					property: 'color',
					start: '77307D',
					end: '333333',
					steps: 12,
					duration: 12
				});				
			});
			
	/////////////////////////// FORM: CONTACT PANEL
    $('#contactForm').ajaxForm(function(data) {
	    if (data==1){
	    	$('#successContact').fadeIn("slow");
	        $('#bademailContact').fadeOut("slow");
	        $('#contactForm').resetForm();
	        $('#contactForm').hide();
	    }
	    else if (data==2) $('#badserver').fadeIn("slow");
	    else if (data==3) {
	        $('#bademailContact').fadeIn("slow");
	        $('#contactFormEmail').focus();
	    }
    });
    /////////////////////////// FORM: NEWSLETTER SIGNUP
    $('#newsletterSignup').ajaxForm(function(data) {
	    if (data==1){
	    	$('#successNewsletter').fadeIn("slow");
	        $('#bademailNewsletter').fadeOut("slow");
	        $('#newsletterSignup').resetForm();
	        $('#newsletterSignup').hide();
	    }
	    else if (data==2) $('#badserverNewsletter').fadeIn("slow");
	    else if (data==3) {
	        $('#bademailNewsletter').fadeIn("slow");
	        $('#newsletterSignupEmail').focus();
	    }
    });
		
	/////////////////////////// FANCY BOX IMAGE ZOOM SETUP
		$("a.zoom").fancybox({
			'zoomSpeedIn'		:	400,
			'zoomSpeedOut'		:	600,
			'overlayShow'		:	false,
			'hideOnOverlayClick':	true,
			'padding'			:	0,
			'easingIn'			:	'easeOutExpo',
			'easingOut'			:	'easeInBack'
		});
		
});