	var iULLeft = 0;
	$(document).ready(function()
	{
		
		//SLIDER CODE ------------------------------------------------------------------------------
		$("#queen_slider_container > ul").attr("id","queen_slider_ul");
		var iXSlide = 0;
		$("#queen_slider_ul > li").each(function(){
			$(this).css("position", "absolute");
			$(this).css("left", iXSlide+"px");
			iXSlide = iXSlide + 226;
			if ( $(this).find('img').attr('alt') != '') 
			{
				sURL = $(this).find('a').attr('href');
				$(this).html( $(this).html()+'<span></span>' );
				$(this).html( $(this).html()+'<p><a href="'+sURL+'">'+ $(this).find('img').attr('alt' )+'</a></p>' );
				iPHeight = $(this).find('p').height();
				iBottom = 9 + Math.round( ($(this).find('span').height() - iPHeight)/2);
				$(this).find('p').css('bottom',iBottom+'px');
			}
		});
		$("#queen_slider_ul").width(iXSlide);

		$("#queen_slider_right").click(function(){
			var iContWidth = $("#queen_slider_container").width();
			var iULWidth = $("#queen_slider_ul").width();
			
			if ( (iULWidth-iULLeft-iContWidth)/iContWidth >= 1)
			{
				iULLeft = iULLeft + iContWidth;
				$("#queen_slider_ul").animate( {left: (-1)*iULLeft }, {duration: 1000, easing: 'easeOutBack'});
			}
			else
			{
				iULLeft = iULWidth - iContWidth;
				$("#queen_slider_ul").animate( {left: (-1)*iULLeft }, {duration: 1000, easing: 'easeOutBack'});
			}
			return false;
		});
		
		$("#queen_slider_left").click(function(){
			var iContWidth = $("#queen_slider_container").width();
			var iULWidth = $("#queen_slider_ul").width();
			
			if ( iULLeft/iContWidth >= 1)
			{
				iULLeft = iULLeft - iContWidth;
				$("#queen_slider_ul").animate( {left: (-1)*iULLeft }, {duration: 1000, easing: 'easeOutBack'});
			}
			else
			{
				iULLeft = 0;
				$("#queen_slider_ul").animate( {left: iULLeft }, {duration: 1000, easing: 'easeOutBack'} );
			}
			return false;
		});		
		//SLIDER CODE ------------------------------------------------------------------------------	
		
		
		
			
		//MENU CODE ------------------------------------------------------------------------------
		$("#menu > ul").attr("id","menu_ul");
		$("#menu_ul li ul").find('.selected').parent().parent().addClass('selected');
		$("#menu_ul > li").each(function(){
			$(this).attr("liwidth", $(this).width() );
			$(this).css("width", $(this).width()+"px");
			$(this).attr("ulheight", $(this).find('ul').height() );
			$(this).find('ul').css("display","block");
			$(this).find('ul').height(0);
			$(this).find('ul').css("padding-bottom","0px");
		});
		
		
		$("#menu_ul > li").hover(
		  function () {
			var found = $(this).find('ul');
			if (found.length != 0) {
				$(this).next().addClass('overnext');
				$(this).addClass('over');
				$(this).find('ul').css("padding-bottom","11px");
				$(this).find('ul').animate( {height: $(this).attr("ulheight") }, 400);
			} 

		  }, 
		  function () {
			$(this).find('ul').stop(true, true).animate( {height:0}, 200);
			$(this).find('ul').css("padding-bottom","0px");
			$(this).removeClass('over');
			$(this).next().removeClass('overnext');
		  }
		);
		//MENU CODE ------------------------------------------------------------------------------
		

	});

