﻿if ($.browser.msie && $.browser.version <= 6) {}

else {
// BACKGROUND IMAGE SCALING
$(document).ready(function () {
    $("#leftImage").maxImage({
        isBackground: true,
        overflow: 'auto',
        verticalAlign: 'top',
        horizontalOffset: "-20",
        zIndex: "102"
    });

    $("#rightImage").maxImage({
        isBackground: true,
        overflow: 'auto',
        verticalAlign: 'top',
        horizontalOffset: "-20",
        zIndex: "102"
    });
});


//Portal slide
$(document).ready(function () {

    var maxImageSettings = {
        isBackground: true,
        overflow: 'auto',
        verticalAlign: 'top',
        horizontalOffset: "-20",
        zIndex: "102"
    };

    $("#leftImage").maxImage(maxImageSettings);
    $("#rightImage").maxImage(maxImageSettings);

    var fullWidth = { width: "200px" };
    var normalWidth = { width: "110px" };

    $("#Left a").hover(function () {

        $("#Left").stop(true, true).animate(fullWidth, 500);
        $("#Right").stop(true, true).fadeTo("slow", 0);
        $("#PortalLeft").css("z-index", "100").stop(true, true).animate({ right: "0", width: "100%" }, 1000);

    }, function () {

        $("#Left").stop(true, true).animate(normalWidth, 500);
        $("#Right").stop(true, true).fadeTo("slow", 100);
        $("#PortalLeft").stop(true, true).animate({ width: "50%", right: "50%" }, 250);

    });

    $("#Right a").hover(function () {

        $("#Right").stop(true, true).animate(fullWidth, 500);
        $("#Left").stop(true, true).fadeTo("slow", 0);
        $("#PortalLeft").css("z-index", "100").stop(true, true).animate({ width: "0" }, 1000);

    }, function () {

        $("#Right").stop(true, true).animate(normalWidth, 500);
        $("#Left").stop(true, true).fadeTo("slow", 100);
        $("#PortalLeft").stop(true, true).animate({ width: "50%" }, 250);
    });

});

}//Browser Check
