
$(document).ready(function(){


    bgColourFade = setInterval(fnChangeColour, 8000);
    x = 1;
    function fnChangeColour(){

	newColour = "#330000";
	if (x == 1) {
	    newColour = "#330000"
	}
	if (x == 2) {
	    newColour = "#330033"
	}		
	if (x == 3) {
	    newColour = "#000033"
	}	
	if (x == 4) {
	    newColour = "#003333"
	}
	if (x == 5) {
	    newColour = "#003300"
	    x = 1;
	}
	$('html').animate({
            'backgroundColor':newColour
        });
    }

    $("#sidebar .menu .page_item a").mouseenter(function(){
        if ($(this).parent().hasClass("current_page_item") == false) {
            $(this).animate({
                fontSize: "1.8em",
                paddingBottom: "0px"
            }, 100);
 
        }
    });
    $("#sidebar .menu .page_item a").mouseleave(function(){
        if ($(this).parent().hasClass("current_page_item") == false) {
            $(this).animate({
                fontSize: "1.3em"

            }, 50);
        }
    });

    $(".linkcat .blogroll li").mouseenter(function(){
        if ($(this).parent().hasClass("current_page_item") == false) {
            $(this).animate({
                opacity: ".7"

            }, 100);
        }
    });
    $(".linkcat .blogroll li").mouseleave(function(){
        if ($(this).parent().hasClass("current_page_item") == false) {
            $(this).animate({
                opacity: "1"

            }, 100);
        }
    });
    $("#sidebar .menu .cat-item a").mouseenter(function(){
        if ($(this).parent().hasClass("current_page_item") == false) {
            $(this).animate({
                fontSize: "1.6em"

            }, 100);
        }
    });
     $("#sidebar .menu .cat-item a").mouseleave(function(){
        if ($(this).parent().hasClass("current_page_item") == false) {
            $(this).animate({
                fontSize: "1.3em"

            }, 100);
        }
    });
        $("#pi").mouseenter(function(){

            $(this).animate({
                opacity: ".5"

            }, 100);

    });
     $("#pi").mouseleave(function(){

            $(this).animate({
                opacity: "1"

            }, 100);

    });

  
});

