function initMenus() {

	var animTime = 800;
	var menuElements=$('#content .menu-item');
	var disable=0;

	$('#content .section').hide();
	/*
	$('#content>div').hide();
	$('#content>div').css('opacity', 0);
	$('#bottom-logo').css('opacity', 0);
	$('#content>div').animate({height: 'toggle', opacity: 1}, animTime);
	$('#bottom-logo').animate({'opacity': 1}, animTime);
	*/

	var clicky = function(clicked) {
		disable=1;
		var checkElement = $(this).closest('table').next();
		var sectionID = '#'+clicked.closest('.menu-item')[0].id;
		var collapsible = $('#content>div').not($('#bottom-logo')).not(clicked.closest('.menu-item'));

		// open item
		if(!$('.section:visible').length){
			var i=0;

			//$('#content>div').stop(true, true);
			clicked.animate({ borderTopColor: "white" }, animTime);
			$('#bottom-logo').fadeOut();
			$('#pad').animate({height: 'toggle'}, animTime);
			$('#content .menu-item').not(clicked).animate({opacity: 0, borderTopWidth: 0, height: 'toggle'}, animTime, function(){
				if (i==0) {
					i++;
					clicked.animate({ borderBottomColor: "white" }, animTime);
					clicked.find('.section').slideDown(animTime, function(){disable=0});
					
					sIFR.replace(georgia, {
						selector: '.dynamic',
						wmode: 'opaque',
						//tuneHeight: -7.5,
						css: [
							'.sIFR-root{text-align:center;}',
							'.current {text-decoration: underline;}',
							'a {color: black; text-decoration: none;}',
							'a:hover {color: black; text-decoration: underline;}'
							]
						});
					sIFR.replace(georgia, {
						selector: sectionID+' .proj-text',
						wmode: 'opaque',
						//tuneHeight: -7.5,
						css: [
							'.sIFR-root{text-align:center;}',
							'a {color: black; text-decoration: none;}',
							'a:hover {color: black; text-decoration: underline;}'
							]
						});
					sIFR.replace(georgia, {
						selector: sectionID+' .prev',
						wmode: 'opaque',
						tuneHeight: -7.5,
						offsetLeft: 2,
						css: [
							'.sIFR-root{text-align:right;}',
							'a {color: black; text-decoration: none;}',
							'a:hover {color: black; text-decoration: underline;}'
							],
						onRelease: function(fi) {
							prev('#'+$(fi.getFlashElement()).closest('.menu-item')[0].id);
							}
						});
					sIFR.replace(georgia, {
						selector: sectionID+' .next',
						wmode: 'opaque',
						tuneHeight: -7.5,
						css: [
							'.sIFR-root{text-align:left;}',
							'a {color: black; text-decoration: none;}',
							'a:hover {color: black; text-decoration: underline;}'
							],
						onRelease: function(fi) {
							next('#'+$(fi.getFlashElement()).closest('.menu-item')[0].id);
							}
						});
					sIFR.replace(georgia, {
						selector: sectionID+' .proj-menu span',
						wmode: 'opaque',
						tuneHeight: -7.5,
						css: [
							'.sIFR-root{text-align:center;}',
							'a {color: black; text-decoration: none; text-align:center;}',
							'a.current {color: black; text-decoration: underline;}',
							'a:hover {color: black; text-decoration: underline;}'
							],
						onRelease: function(fi) {
							switchMenus($(fi.getFlashElement()).closest('.menu-item'),
							$(fi.getAncestor())[0]);
							}
						});
					}
				});
			}

		// return to menu screen
		if((clicked.find('.section').is(':visible'))) {
		
			clicked.animate({ borderBottomColor: "black" }, animTime);
			clicked.find('.section').slideUp(animTime, function(){
				clicked.animate({ borderTopColor: "black" }, animTime);
				$('#pad').animate({height: 'toggle'});
				$('#content .menu-item').not(clicked).animate({opacity: 1, borderTopWidth: 1, height: 'toggle'}, animTime);
				$('#bottom-logo').fadeIn(animTime, function(){disable=0});
				});
			}

		return false;
		
		};
	
	$('a.scrollPage').click(
		function (){
			if (disable==0) {
				clicky($(this).closest('.menu-item'));
				return false
				} else {
				return false
				};
			}
		);

	$('#top-logo').click(
		function (){
			if ((disable==0) & $('.section').is(':visible')) {
				clicky($('.section').filter(':visible').closest('.menu-item'));
				} else {
				return false
				};
			}
		);

/* PAGE TRANSITION */
	$('#bottom-logo').click(
		function (){
			/*
			var topLogoOffset='-25px';
			if (studiosOrAlaska=="alaska") {topLogoOffset='-40px'};
			$('.container').css('overflow-y', 'visible');
			$('.container').css('margin-left', '-8px');
			$('#pad').animate({height: 'toggle'}, animTime);
			$('#content .menu-item').animate({opacity: 0, borderTopWidth: 0, height: 'toggle'}, animTime);
			$('#top-logo').fadeOut(animTime);
			//$('#bottom-logo').fadeOut(animTime);
			$('#bottom-logo').animate({marginTop: topLogoOffset}, animTime, function() {window.location = this.href});
			//window.location = "http://www.google.com";
			*/
			return true;
			}
		);

	};

$(document).ready(function() {
	initMenus();
	$('.section').animate({height: 'toggle'}, animTime);
});