document.documentElement.className = 'js';

jQuery.fn.fadeIn = function(speed, callback) { 
    return this.animate({opacity: 'show'}, speed, function() { 
        if (jQuery.browser.msie)  
            this.style.removeAttribute('filter');  
        if (jQuery.isFunction(callback)) 
            callback();  
    }); 
}; 

$(window).load(function() {
    $('#slider').nivoSlider({
        effect:'fade', //Specify sets like: 'fold,fade,sliceDown'
        animSpeed:500, //Slide transition speed
        pauseTime:5000,
        controlNav:false, //1,2,3...
        captionOpacity:1, //Universal caption opacity
        directionNavHide:false
    });
});

 jQuery(function($){ // on page ready
  $('a.thumbnail img, #slider, .hero img, #content-contact').onImagesLoaded(function(_this){
    $(_this).fadeIn(1000);
  });
}); // end on ready

$(document).ready(function() { 
var options = { 
target: '#alert'
}; 
$('#contactForm').ajaxForm(options); 
}); 


$(function() {
   
   $('a.thumbnail').hover(function() {
      
      $('.overlay',this).fadeTo("fast",0.5);
            
      }, function() { $('.overlay').fadeOut();
   });
});

$(function() {
   
   $('#more a.thumbnail').hover(function() {
      
      $('#more .overlay',this).fadeTo("fast",0.5);
            
      }, function() { $('#more .overlay').fadeOut();
   });
});


