var $j=jQuery.noConflict();

$j(document).ready(function(){
$j('#widget embed').attr("wmode", "transparent");
$j('#widget embed').before('<param name="wmode" value="transparent">');
$j('#auto1378646 embed').css('z-index', '300');
	//$j('#obNav li a').css('z-index', '300');
	$j('#widget').css('z-index', '200');
	$j('#primaryPersonal li').css('z-index', '100');

	// $j('#widget').mouseenter( function(e){
	// 	var asdf = getPosition(e);
	// 	//console.log(asdf.y);
	// 	if( asdf.y > 145 ){
	// 		$j('#mainContent').animate({marginTop: "125px"});
	// 	}
	// });
	// $j('#widget').mouseleave( function(e){
	// 	var asdf = getPosition(e);
	// 	if( asdf.y > 145 ){
	// 		$j('#mainContent').animate({marginTop: "5px"});
	// 	}
	// });
	if($j('#ssnWhy').length > 0){
		$j("a#ssnWhy").fancybox({
			'frameWidth': 300,
			'frameHeight': 190
		});
	}
});

function getPosition(e) {
    e = e || window.event;
    var cursor = {x:0, y:0};
    if (e.pageX || e.pageY) {
        cursor.x = e.pageX;
        cursor.y = e.pageY;
    }
    else {
        cursor.x = e.clientX +
            (document.documentElement.scrollLeft ||
            document.body.scrollLeft) -
            document.documentElement.clientLeft;
        cursor.y = e.clientY +
            (document.documentElement.scrollTop ||
            document.body.scrollTop) -
            document.documentElement.clientTop;
	}
    return cursor;
}
