jQuery(document).ready(function() {
    jQuery('#mycarousel').jcarousel({
        start: 3
    });

jQuery('ul.mainmenu').hide();
jQuery('ul.mainmenu2').hide();
jQuery('ul.mainmenu3').hide();

$(window).load(function(){



jQuery('ul.mainmenu').slideDown('slow');
jQuery('ul.mainmenu2').delay(400).slideDown('slow');
jQuery('ul.mainmenu3').delay(800).slideDown('slow');


});


jQuery('.hovers').mouseover(function() {
jQuery('.hovers').not(this).fadeTo('slow', 0.33);


});

jQuery('.hovers').mouseout(function() {

jQuery('.hovers').fadeTo('slow', 1.0);


});


 jQuery(".hovers").hover( function() {
       var hoverImg = HoverImgOf($(this).attr("src"));
       $(this).attr("src", hoverImg);
     }, function() {
       var normalImg = NormalImgOf($(this).attr("src"));
       $(this).attr("src", normalImg);
     });


function HoverImgOf(filename)
{
   var re = new RegExp("(.+)\\.(gif|png|jpg)", "g");
   return filename.replace(re, "$1_hover.$2");
}
function NormalImgOf(filename)
{
   var re = new RegExp("(.+)_hover\\.(gif|png|jpg)", "g");
   return filename.replace(re, "$1.$2");
}


jQuery('.backtotop').click(function(){


jQuery('html, body').animate({scrollTop:0}, 'slow');
return false;
});

});

