
function crazyMainMenu() {
	
	$('#mainestOfTheMenus li').hover(function(){
		$(this).siblings().find('img.mTaggy').stop(true,true).css({"top" : "75px"});
		if($.browser.msie && parseInt($.browser.version) < 7) {}
		else if($.browser.msie) $(this).find('img.mHovery').css({'display' : 'block' });
		else $(this).find('img.mHovery').fadeIn(200);
		$(this).find('img.mTaggy').animate({top : "142px" },{ queue: true, duration:120 });
		},function(){
		$(this).find('img.mHovery').css({'display' : 'none' });
		$(this).find('img.mTaggy').animate({top : "75px" },{ queue: true, duration:20 });
		});
	}

//replace headings
function replaceHeading(){
	$("#copyCopy h2").each(function (){
		content = $(this).text();
			
		if ($(this).css('color') == 'rgb(255, 255, 255)') headingColorRep = "0xffffff";
		else headingColorRep = "0x3e594c";
		
		$(this).flashembed({
			//flashembed vars
			src: "/assets/flash/hRep.swf", version: [9, 0], wmode: "transparent", width: "100%", height: "100%", scale: "noscale", salign: "lt" }, {
			//vars to flash file
			headingText: encodeURIComponent(content), headingColor: headingColorRep, headingSize: 30, headingLetterSpacing: 0, headingOffsetX: -2, headingOffsetY: -8 	});
	});
	
	$("#copyCopy h3").each(function (){
		content = $(this).text();
		headingColorRep = "0xab7c51";
		
		$(this).flashembed({
			//flashembed vars
			src: "/assets/flash/hRep.swf", version: [9, 0], wmode: "transparent", width: "100%", height: "100%", scale: "noscale", salign: "lt" }, {
			//vars to flash file
			headingText: encodeURIComponent(content), headingColor: headingColorRep, headingSize: 23, headingLetterSpacing: 1, headingOffsetX: -3, headingOffsetY: -8 	});
	});
}

$(document).ready(function(){
	crazyMainMenu();
	replaceHeading();
	$('#homeSlideshow').cycle({ speed: 1000, timeout: 3000 });
	});