function scrollFooter(){  
    var windowHeight = document.documentElement.clientHeight;  
    var footerHeight = jQuery("#footer").height();  
    
    var scrollTop = jQuery(document).scrollTop();
    var top =  scrollTop + (windowHeight-footerHeight);
    jQuery("#footer").css({    
        "top": top    
    }); 
}

jQuery(document).ready(function() { 
    
    if(jQuery.browser.name == "msie" && jQuery.browser.versionNumber < 7){
        DD_belatedPNG.fix('#header h1 a,#header .menutop,.footer a,.gecko1,.gecko2,.gecko3,.gecko,h1.logo a');
        
        // IE6 footer - position: absolute - scrolling window
        jQuery(window).bind("scroll", function() {
            scrollFooter();
        });
               
    }
    
    jQuery("#footer a").hover(function(){
        jQuery(this).animate({top: "0"}, 200 );
    },function(){
        jQuery(this).animate({top: "5px"}, 200 );
    });
    
    jQuery("#right ul li a").click(function(){
        if(jQuery(this).parent().has("ul").length){
            jQuery(this).next().slideToggle();
            jQuery(this).toggleClass("open");
            return false;
        }
    });
     
});
