/*Global variable decleration*/
var link_slide_link_container_mouse_over_pointer;
var link_slide_panel_container_mouse_over_pointer;
$(document)
	.ready
	(
	 	function()
		{
		
		
			jQuery.each(jQuery.browser, function(i, val) {
			
			if(i=="msie" && jQuery.browser.version.substr(0,3)=="6.0")
				var img = new Image();
				$(img)
					.load
					(
					 	function() 
						{    // when image has loaded...
							
							$(this).css('display', 'none'); // hide image by default
							$('.ie_block_body')
								.fadeIn()
								.removeClass('loading')
								.append(this);   // remove 'div#loader.loading' class (loading anim gif), then insert our image in 'loader' div
							$(this)
								.fadeIn('slow')
								.animate
								(
									{ 
										"margin-top"	: 0
									}, 
									{
										duration:	1100,
										complete: 
											function () 
											{
												//
											}
									}
								);
						}
					)
					
					.attr({
						  src: "images/Pop_up_i6.jpg",
						  usemap: "#popup"
						});
				//loadIfnotIe6();
			});
			jQuery.each(jQuery.browser, function(i, val) {
			if(i=="msie" && jQuery.browser.version.substr(0,3)=="7.0")
				loadIfnotIe6();
			});
			jQuery.each(jQuery.browser, function(i, val) {
			if(i=="msie" && jQuery.browser.version.substr(0,3)=="8.0")
				loadIfnotIe6();
			});
			jQuery.each(jQuery.browser, function(i, val) {
			if(i=="msie" && jQuery.browser.version.substr(0,3)=="9.0")
				loadIfnotIe6();
			});
			jQuery.each(jQuery.browser, function(i, val) {
			if(i=="mozilla" || i=="opera" || i=="safari")
				loadIfnotIe6();
			});
	}
);
function loadIfnotIe6()
{
	var second_child = $(".ramco_header .content");
	//$('body').scrollTo( second_child, { duration:500, axis:'x', onAfter:function(){
		//alert('scrolled!!');																   
	//}});
	/*Create data array for homa page rotating data*/
	var images = 
	[
		'images/theme_imges/ramco_home_theme_01.jpg',
		'images/theme_imges/ramco_home_theme_02.jpg',
		'images/theme_imges/ramco_home_theme_03.jpg',
		'images/theme_imges/ramco_home_theme_04.jpg'
	];
	var image_width = 
	[
		1002,
		1002,
		1002,
		1002
	];
	var image_height = 
	[
		487,
		487,
		487,
		487
	];
	var arr_related_header_content =
	[
	 	'SAY NO TO CONVENTIONAL ERP',
		'SAY NO TO CONVENTIONAL ERP',
		'SAY NO TO CONVENTIONAL ERP',
		'SAY NO TO CONVENTIONAL ERP'
	];
	var class_set_related_header_content =
	[
		'content display-block color_c5c5c5 related_header_content_text',
		'content display-block color_c5c5c5 related_header_content_text',
		'content display-block color_ffffff related_header_content_text',
		'content display-block color_c5c5c5 related_header_content_text'
	]
	var arr_ramco_theme_opec_des_1_text =
	[
	 	'EXPERIENCE THE PLANET&acute;S MOST ROBUST ERP ON THE CLOUD',
		'EXPERIENCE THE PLANET&acute;S MOST RELIABLE ERP ON THE CLOUD',		
		'EXPERIENCE THE PLANET&acute;S MOST AGILE ERP ON THE CLOUD',
		'EXPERIENCE THE PLANET&acute;S MOST POWERFUL ERP ON THE CLOUD'
	];
	var class_set_ramco_theme_opec_des_1_text =
	[
		'content display-block color_1A1E43',
		'content display-block color_1A1E43',
		'content display-block color_1A1E43',
		'content display-block color_1A1E43'
	]
	var arr_more_data_content = 
	[
	 	'Lets you scale up or down based on business needs',
		'No new hardware, training or additional IT staff',
		'Pay only for what you use on a subscription basis',
		'Gain valuable insights across your business processes'
	];
	var class_set_more_data_content =
	[
		'float-left more_button_data display-block',
		'float-left more_button_data display-block',
		'float-left more_button_data display-block',
		'float-left more_button_data display-block'
	]
	var arr_more_button_url =
	[
		'/campaign-print/index.html',
		'/campaign-print/index.html',
		'/campaign-print/index.html',
		'/campaign-print/index.html'
	];
	/*Create data array for homa page rotating data*/
	/*load images*/
	
	/*click pointers to chenge slides*/
	$(".rotate_image_pointer_placeholder .pointers")
	.live
	(
		'click', function() 
		{
			var $current_index = $(".rotate_image_pointer_placeholder .pointers").index(this);
			$(".ramco_theme_image img").hide();
			$(".rotate_image_pointer_placeholder .pointers")
				.removeClass("pointers_sel");
			$(".ramco_theme_opec_des_2_text .more_button_data")
				.hide();
			$(".related_header_content_text")
				.hide();
			$(".ramco_theme_opec_des_1_text .content")
				.hide();
			$(".more_button_data")
				.hide();
			$(".more_button a")
				.hide();
			$(this)
				.addClass("pointers_sel");
			$("#ramco_theme_image"+$current_index+"")
				.fadeIn("slow");
			$("#related_header_content_text"+$current_index+"")
				.fadeIn("slow");
			$("#more_button_data"+$current_index+"")
				.fadeIn("slow");
			$("#ramco_theme_opec_des_1_text"+$current_index+"")
				.fadeIn("slow");
			$("#more_button_data"+$current_index+"")
				.fadeIn("slow");
			$("#more_button"+$current_index+"")
				.fadeIn("slow");
			clearTimeout(myImageInterval);
			banner_image_index = $current_index + 1;
			myImageInterval = setInterval("ScrollImage(banner_image_index)",2500);
		}
	);
	/*click pointers to chenge slides*/
	
	/*home page image rorator*/
	$(".rotate_image_pointer_placeholder .pointers")
	.each
	(
		function(index)
		{
			var $current_index = $(".rotate_image_pointer_placeholder .pointers").index(this);
			$(this)
				.attr("id","rotate_image_pointers"+$current_index);
		}
	);
	$(".rotate_image_pointer_placeholder .pointers")
		.eq(0)
		.addClass("pointers_sel");
	$(".related_header_content .content")
	.each
	(
		function(index)
		{
			var $current_index = $(".related_header_content .content").index(this);
			$(this)
				.attr("id","related_header_content_text"+$current_index);
		}
	);
	$(".ramco_theme_opec_des_2_text .more_button_data")
	.each
	(
		function(index)
		{
			var $current_index = $(".ramco_theme_opec_des_2_text .more_button_data").index(this);
			$(this)
				.attr("id","more_button_data"+$current_index);
		}
	);
	//myImageInterval = setInterval("ScrollImage()",5000);
	/*home page image rorator*/
	
	
	/*Home image size magane according to screen resolution*/
	/*Input hint*/
	$('input[title!=""]').hint();
	/*Input hint*/
	/*Home fixed layers position, with, margin management */
	$(".ramco_theme_opec_des_2")
		.css
		(
			{
				"opacity":"0.4",
				"background":"#ffffff"
			}
		);
	$(".ramco_theme_opec_des_1")
		.css
		(
			{
				"opacity":"0.4",
				"background":"#ffffff"
			}
		);
	$(".link_opec_container")
		.css
		(
			{
				"opacity":"0.1"
			}
		);
	$(".link_slide_panel_container .panels .opac_gray")
		.css
		(
			{
				"opacity":"0.7"
			}
		);
	/*Home fixed layers position, with, margin management */
			
	/*Top menu devider*/
	$(".layers ul")
		.each
		(
			function()
			{
				$("li> a",this)
					.addClass("a_bar");
				$("li> a:last",this)		
					.removeClass("a_bar")
					.css
					(
						{
							"padding-right":0
						}
					);
			}
		);
	/*Top menu devider*/
	
	/* Toll free number */
	
		$(".layers ul li .call_arrow .call_arrow_drop").hover(
	function () {
			$(".layers ul li .call_arrow2").show();
				},
	function () {
			$(".layers ul li .call_arrow2").hide();
				}
					);
	
	   
	/* Toll free number */
	
	/*Country tab*/
	$(".country_tab")
		.hoverIntent
		(
			{
				sensitivity: 7, // number = sensitivity threshold (must be 1 or higher)
				interval: 100,   // number = milliseconds of polling interval
				over: show_country,  // function = onMouseOver callback (required)
				timeout: 100,   // number = milliseconds delay before onMouseOut function call
				out: hide_country    // function = onMouseOut callback (required)
			}
		);
	$(".country_tab a")
		.hoverIntent
		(
			{
				sensitivity: 7, // number = sensitivity threshold (must be 1 or higher)
				interval: 100,   // number = milliseconds of polling interval
				over: show_country_a,  // function = onMouseOver callback (required)
				timeout: 100,   // number = milliseconds delay before onMouseOut function call
				out: hide_country_a    // function = onMouseOut callback (required)
			}
		);
	/*Country tab*/
	/*login tab*/
	$(".login_tab")
		.hoverIntent
		(
			{
				sensitivity: 7, // number = sensitivity threshold (must be 1 or higher)
				interval: 100,   // number = milliseconds of polling interval
				over: show_login,  // function = onMouseOver callback (required)
				timeout: 100,   // number = milliseconds delay before onMouseOut function call
				out: hide_login    // function = onMouseOut callback (required)
			}
		);
	$(".login_tab a")
		.hoverIntent
		(
			{
				sensitivity: 7, // number = sensitivity threshold (must be 1 or higher)
				interval: 100,   // number = milliseconds of polling interval
				over: show_login_a,  // function = onMouseOver callback (required)
				timeout: 100,   // number = milliseconds delay before onMouseOut function call
				out: hide_login_a    // function = onMouseOut callback (required)
			}
		);
	/*login tab*/
	/*$(".ramco_header .content .logo")
		.css
		(
			{
				"margin-left":-(gray_space_width - 216)
			}
		);*/
	/*home gray_space management*/
	/*Main menu automation*/
	/*Assign class to each phase of menu*/
	$(".menu ul")
		.attr("class","first_phase");
	$(".menu ul ul")
		.attr("class","second_phase");
	$(".menu ul ul ul")
		.attr("class","third_phase");
	$(".menu ul ul ul ul")
		.attr("class","fourth_phase")
		.remove();
	$(".second_phase")
		.each
		(
			function()
			{
				$(".second_phase_li:last a:first",this)	
					.addClass("second_phase_last_li")
			}
		);
	$(".third_phase")
		.each
		(
			function()
			{
				$(".third_phase_li:last a",this)	
					.addClass("third_phase_last_li")
			}
		);
	/*Assign class to each phase of menu*/
	$(".first_phase li")
		.hoverIntent
		(
			{
				sensitivity: 7, // number = sensitivity threshold (must be 1 or higher)
				interval: 100,   // number = milliseconds of polling interval
				over: show_first_phase,  // function = onMouseOver callback (required)
				timeout: 100,   // number = milliseconds delay before onMouseOut function call
				out: hide_first_phase    // function = onMouseOut callback (required)
			}
		);
	$(".second_phase li")
		.hoverIntent
		(
			{
				sensitivity: 7, // number = sensitivity threshold (must be 1 or higher)
				interval: 100,   // number = milliseconds of polling interval
				over: show_second_phase,  // function = onMouseOver callback (required)
				timeout: 100,   // number = milliseconds delay before onMouseOut function call
				out: hide_second_phase    // function = onMouseOut callback (required)
			}
		);
	$(".third_phase li")
		.hoverIntent
		(
			{
				sensitivity: 7, // number = sensitivity threshold (must be 1 or higher)
				interval: 100,   // number = milliseconds of polling interval
				over: show_third_phase,  // function = onMouseOver callback (required)
				timeout: 100,   // number = milliseconds delay before onMouseOut function call
				out: hide_third_phase    // function = onMouseOut callback (required)
			}
		);
	/*Assign class to each phase of menu*/
	$(".link_slide_link_icon_container .icons")
		.hoverIntent
			(
				{
					sensitivity: 7, // number = sensitivity threshold (must be 1 or higher)
					interval: 200,   // number = milliseconds of polling interval
					over: link_slide_link_icon_container_icons_show,  // function = onMouseOver callback (required)
					timeout: 300,   // number = milliseconds delay before onMouseOut function call
					out: link_slide_link_icon_container_icons_hide    // function = onMouseOut callback (required)
				}
			);
	$(".link_slide_link_container")
		.hoverIntent
			(
				{
					sensitivity: 7, // number = sensitivity threshold (must be 1 or higher)
					interval: 100,   // number = milliseconds of polling interval
					over: link_slide_panel_container_show,  // function = onMouseOver callback (required)
					timeout: 100,   // number = milliseconds delay before onMouseOut function call
					out: do_nothing    // function = onMouseOut callback (required)
				}
			);
	$(".link_slide_panel_container")
		.hoverIntent
			(
				{
					sensitivity: 7, // number = sensitivity threshold (must be 1 or higher)
					interval: 100,   // number = milliseconds of polling interval
					over: link_slide_panel_container_show,  // function = onMouseOver callback (required)
					timeout: 100,   // number = milliseconds delay before onMouseOut function call
					out: link_slide_panel_container_hide    // function = onMouseOut callback (required)
				}
			);
	/*loader implementation*/
	var max = $(images).length;
	//$('<div class="ramco_theme_loader_container"><div class="ramco_theme_loader"></div></div>').insertAfter('.ramco_header');
	var each_lod_move = (1002/max);
	var total_move = each_lod_move;
	/*loader implementation*/
	// at least 1 image exist
	if(max>0)
	{
		LoadImage(0,max);
	}
	// function of loading image
	// params: (int) index of image in array, (int) length of images array
	function LoadImage(index,max)
	{
		// if current index is lower then max element (max-1)
		if(index<max)
		{
			var curr = $(".ramco_theme_image");
			var curr_pointer = $(".rotate_image_pointer_placeholder");
			var curr_related_header_content = $(".related_header_content");
			var curr_more_data_content = $(".more_data_content");
			var curr_ramco_theme_opec_des_1_text = $(".ramco_theme_opec_des_1_text");
			var curr_more_button = $(".more_button")
			// new image object
			var img = new Image();
			// image onload
			$(img).load
			(
				function () 
				{
					$(".ramco_theme_image img")
						.hide();
					$(this)
						.attr("id","ramco_theme_image"+index)
						.css('display','none'); // since .hide() failed in safari
					$(curr)
						.removeClass('loading')
						.append(this);
					$(curr_pointer)
						.append('<div class="pointers" id="rotate_image_pointers_'+index+'"><!--%nbsp;--></div>');
					$(".related_header_content_text")
						.hide();
					$(curr_related_header_content)
						.append('<div class="'+class_set_related_header_content[index]+'" id="related_header_content_text'+index+'" style="display: block;">'+arr_related_header_content[index]+'</div>');
					$(".more_button_data")
						.hide();
					$(curr_more_data_content)
						.append('<div class="'+class_set_more_data_content[index]+'" id="more_button_data'+index+'">'+arr_more_data_content[index]+'</div>');
					
					$(".ramco_theme_opec_des_1_text .content")
						.hide();
					$(curr_ramco_theme_opec_des_1_text)
						.append('<div class="'+class_set_ramco_theme_opec_des_1_text[index]+'" id="ramco_theme_opec_des_1_text'+index+'">'+arr_ramco_theme_opec_des_1_text[index]+'</div>');
					$(".more_button a")
						.hide();
					$(curr_more_button)
						.append('<a href="'+arr_more_button_url[index]+'" id="more_button'+index+'"> <img src="images/home/home_ramco_more.gif"></a>')
					/*$(".related_header_content .content")
						.hide();
					$(".ramco_theme_opec_des_2_text .more_button_data")
						.hide()
					$("#related_header_content_text"+index+"")
						.fadeIn("slow");
					$("#more_button_data"+index+"")
						.fadeIn("slow");*/
					$(".ramco_theme_loader")
						.animate
						(
							{ 
								"width"	: total_move
							}, 
							{
								duration:	1000,
								complete: 
									function () 
									{
										if($(this).width() == 1002)
										{
											$(this).hide();	
										}
									}
							}
						);
					total_move = total_move + each_lod_move;
					$(this)
						.fadeIn
						(
							'slow',
							function()
							{
								// once the current loaded, trigger the next image
								LoadImage(index+1,max);
								if(index == (max - 1))
								{
									pic = $(".ramco_theme_image").children("img");
									numImgs = pic.length;
									banner_image_index = 0;
									myImageInterval = setInterval("ScrollImage()",9000);
								}
							}
						);
					}
				)
				.error
				(
					function () 
					{
						// on error remove current
						$(curr).remove();
						// trigger the next image
						LoadImage(index+1,max);
					}
				)
				.attr
				(
					'src', images[index]
				)
				.css
				(
					'width' ,image_width[index]
				)
				.css
				(
					'height',image_height[index]
				);
			}
	}
	/*load images*/	
	$(".ramco_bodywrap")
		.fadeIn();
	/*Remove anchor tags form first level menus*/
	$(".first_phase_li >a").attr("href","#");
	/*Remove anchor tags form first level menus*/
	/*call_mumber animation*/
	$(".call_mumber")
		.hoverIntent
			(
				{
					sensitivity: 7, // number = sensitivity threshold (must be 1 or higher)
					interval: 100,   // number = milliseconds of polling interval
					over: call_mumber_show,  // function = onMouseOver callback (required)
					timeout: 100,   // number = milliseconds delay before onMouseOut function call
					out: call_mumber_hide    // function = onMouseOut callback (required)
				}
			);
		
}
/*ScrollImage*/
function ScrollImage()
{
	if( banner_image_index != numImgs){
		$(".ramco_theme_image img").hide();
		$(".rotate_image_pointer_placeholder .pointers")
			.removeClass("pointers_sel");
		$(".related_header_content .content")
			.hide();
		$(".ramco_theme_opec_des_2_text .more_button_data")
			.hide();
		$(".ramco_theme_opec_des_1_text .content")
			.hide();
		$(".more_button a")
			.hide();
		$("#ramco_theme_image"+banner_image_index+"")
			.fadeIn("slow");
		$("#rotate_image_pointers_"+banner_image_index+"")
			.addClass("pointers_sel");
		$("#related_header_content_text"+banner_image_index+"")
			.fadeIn("slow");
		$("#more_button_data"+banner_image_index+"")
			.fadeIn("slow");
		$("#ramco_theme_opec_des_1_text"+banner_image_index+"")
			.fadeIn("slow");
		$("#more_button"+banner_image_index+"")
			.fadeIn("slow");
		banner_image_index = banner_image_index + 1;
	}
	else
	{
		banner_image_index = 0;
	}
}
/*ScrollImage*/
/*show_first_phase*/
function show_first_phase()
{
	
	var current_element=$(this)
	$("ul:first",this)
		.fadeIn();
	var managed_width;
	jQuery.each(jQuery.browser, function(i, val) {
	if(i=="msie" && jQuery.browser.version.substr(0,3)=="6.0")
		managed_width = $(current_element).width() + 4;
	});
	jQuery.each(jQuery.browser, function(i, val) {
	if(i=="msie" && jQuery.browser.version.substr(0,3)=="7.0")
		managed_width = $(current_element).width() + 4;
	});
	jQuery.each(jQuery.browser, function(i, val) {
	if(i=="msie" && jQuery.browser.version.substr(0,3)=="9.0")
		managed_width = 0;
	});
	jQuery.each(jQuery.browser, function(i, val) {
	if(i=="msie" && jQuery.browser.version.substr(0,3)=="8.0" || i=="mozilla" || i=="opera" || i=="safari")
		managed_width = 0;
	});
	//alert($(this).width());
	if($(this).index() != 0)
	{
		var first_phase_li_left_margin = $(this).prevAll().andSelf().sumOuterWidth(true) - $(this).width() + managed_width;
	}
	else
	{
		var first_phase_li_left_margin = managed_width;
	}
	jQuery.each(jQuery.browser, function(i, val) {
	if(i=="msie" && jQuery.browser.version.substr(0,3)=="6.0")
		ie_6_managed_width = 60;
	});
	jQuery.each(jQuery.browser, function(i, val) {
	if(i=="msie" && jQuery.browser.version.substr(0,3)=="7.0")
		ie_6_managed_width = 10;
	});
	jQuery.each(jQuery.browser, function(i, val) {
	if(i=="msie" && jQuery.browser.version.substr(0,3)=="9.0")
		ie_6_managed_width = 0;
	});
	jQuery.each(jQuery.browser, function(i, val) {
	if(i=="msie" && jQuery.browser.version.substr(0,3)=="8.0" || i=="mozilla" || i=="opera" || i=="safari")
		ie_6_managed_width = 0;
	});
	if($(".second_phase .second_phase_li",this).prevAll().andSelf().sumOuterWidth(true) < 500)
	{
		$(".second_phase",this).css({"width":500});	
	}
	else
	{
		$(".second_phase",this).css({"width":($(".second_phase .second_phase_li",this).prevAll().andSelf().sumOuterWidth(true) + ie_6_managed_width)})	
	}
	$("ul:first",this)
		.css
		(
			{
				"margin-left" : -first_phase_li_left_margin
			}
		);
	$(this)
		.css
		(
			{
				"background":"#2384c8"
			}
		);
	$(">a",this)
		.css
		(
			{
				//"font-weight":"bold"
			}
		);
}
/*show_first_phase*/
/*hide_first_phase*/
function hide_first_phase()
{	
	$("ul:first",this)
		.fadeOut();
	$(this)
		.css
		(
			{
				"background":"#263578"
			}
		);
	$(">a",this)
		.css
		(
			{
				"font-weight":"normal"
			}
		);
}
/*hide_first_phase*/
/*show_second_phase*/
function show_second_phase()
{	
	$(">a",this)
		.removeClass("second_level_menu_devider")
		.addClass("second_level_menu_devider_sel");
	$("ul:first",this)
		.fadeIn()
		.css
		(
			{
				"border-bottom" : "none"
			}
		);
	/*Dianamic height to third_phase meu*/
	var third_phase_li_length = $("ul li",this).length;
	third_phase_li_length_if_float = third_phase_li_length % 3;//check whether module is 0
	if( third_phase_li_length_if_float == 0)
	{
		//just devide by 3 n get the no of rows
		third_phase_li_length = third_phase_li_length / 3;
		third_phase_li_length = parseInt(third_phase_li_length);
	}
	else
	{
		//devide by 3 n get the no of rows
		third_phase_li_length_if_float = third_phase_li_length / 3;	
		//convert to int
		third_phase_li_length_if_float = parseInt(third_phase_li_length_if_float);
		//add 1 more to get the next
		third_phase_li_length = third_phase_li_length_if_float + 1;
	}
	//to get the total height
	third_phase_height = (third_phase_li_length * 20);
	$("ul",this)
		.css
		(
			{
				"height":third_phase_height,
				"border-top" : "none",
				"border-bottom" : "1px solid #213e6f"
			}
		);
	/*Dianamic height to third_phase meu*/
	/*$("ul:first",this)
		.css
		(
			{
				"left" : 0
			}
		);*/
}
/*show_second_phase*/
/*hide_second_phase*/
function hide_second_phase()
{	
	if($(">a",this).hasClass("second_phase_last_li"))
	{
		$(">a",this)
			.removeClass("second_level_menu_devider_sel")
			.removeClass("second_level_menu_devider");
	}
	else
	{
		$(">a",this)
			.removeClass("second_level_menu_devider_sel")
			.addClass("second_level_menu_devider");
	}
	$("ul:first",this)
		.fadeOut();
}
/*hide_second_phase*/
/*show_third_phase*/
function show_third_phase()
{	
	$("a",this)
		.css
		(
			{
				"color":"#cccccc"
			}
		);
}
/*show_third_phase*/
/*hide_third_phase*/
function hide_third_phase()
{	
	$("a",this)
		.css
		(
			{
				"color":"#ffffff"
			}
		);
}
/*hide_third_phase*/
function link_slide_link_icon_container_icons_show()
{
	/*check if noe all elements are in default position*/
	var link_slide_panel_container_panels_left_margin = $(".link_slide_panel_container .panels").css('margin-left');
	//console.log(link_slide_panel_container_panels_left_margin);
	if( link_slide_panel_container_panels_left_margin != "877px")
	{
		$(".link_slide_link_container .links")
			.animate
				(
					{ 
						"margin-left"	: 477
					}, 
					{
						duration:	'slow',
						easing: 'easeInOutExpo',
						complete: 
							function () 
							{
								//do stuff
							}
					}
				);
		$(".link_slide_panel_container .panels")
			.animate
			(
				{ 
					"margin-left"	: 878
				}, 
				{
					duration: 'slow',
					easing: 'easeInOutExpo',
					complete: 
						function () 
						{
							//do stuff
						}
				}
			);	
	}
	/*check if noe all elements are in default position*/
	var current_link_id = $(this).attr("id")
	var link_width = $(".slide_"+current_link_id).width();
	var link_left_margin = 470 - link_width;
	$(".slide_"+current_link_id)
		.animate
			(
				{ 
					"margin-left"	: link_left_margin
				}, 
				{
					duration: 'slow',
					easing: 'easeInOutExpo',
					complete: 
						function () 
						{
							//do stuff
						}
				}
			);
		$(".link_slide_panel_container .panel_"+current_link_id)
			.animate
			(
				{ 
					"margin-left"	: 0
				}, 
				{
					duration: 'slow',
					easing: 'easeInOutExpo',
					complete: 
						function () 
						{
							//do stuff
						}
				}
			);
		link_slide_link_container_mouse_over_pointer = false; 
		link_slide_panel_container_mouse_over_pointer = false; 
}
function link_slide_link_icon_container_icons_hide()
{
	if(link_slide_link_container_mouse_over_pointer == true || link_slide_panel_container_mouse_over_pointer == true)
	{
		return false;
	}
	else
	{
		$(".link_slide_link_container .links")
			.animate
				(
					{ 
						"margin-left"	: 477
					}, 
					{
						duration:	'slow',
						easing: 'easeInOutExpo',
						complete: 
							function () 
							{
								//do stuff
							}
					}
				);
		$(".link_slide_panel_container .panels")
			.animate
			(
				{ 
					"margin-left"	: 878
				}, 
				{
					duration: 'slow',
					easing: 'easeInOutExpo',
					complete: 
						function () 
						{
							//do stuff
						}
				}
			);
	}
}
function link_slide_panel_container_show()
{
	link_slide_panel_container_mouse_over_pointer = true;
	//console.log(link_slide_panel_container_mouse_over_pointer);
}
function link_slide_panel_container_hide()
{
	$(".link_slide_link_container .links")
		.animate
			(
				{ 
					"margin-left"	: 477
				}, 
				{
					duration:	'slow',
					easing: 'easeInOutExpo',
					complete: 
						function () 
						{
							//do stuff
						}
				}
			);
	$(".link_slide_panel_container .panels")
		.animate
		(
			{ 
				"margin-left"	: 878
			}, 
			{
				duration: 'slow',
				easing: 'easeInOutExpo',
				complete: 
					function () 
					{
						//do stuff
					}
			}
		);
}
function show_country()
{
	$(".country_menu")	
		.fadeIn();
}
function hide_country()
{
	$(".country_menu")	
		.fadeOut();
}
function show_country_a()
{
	$(".country_menu a")
		.removeClass("a_sel");
	$(this)		
		.addClass("a_sel");
}
function hide_country_a()
{
	$(".country_menu a")
		.removeClass("a_sel");
}

function show_login()
{
	$(".login_menu")	
		.fadeIn();
}
function hide_login()
{
	$(".login_menu")	
		.fadeOut();
}
function show_login_a()
{
	$(".login_menu a")
		.removeClass("a_sel");
	$(this)		
		.addClass("a_sel");
}
function hide_login_a()
{
	$(".login_menu a")
		.removeClass("a_sel");
}
function call_mumber_show()
{
	$(this)
		.css
		(
		 	{
			 	"background":"url(images/basic/ramco_arrow_type_4.gif)"
			}
		)
		.animate
		(
			{ 
				"width"	: 234
			}, 
			{
				duration:	1000,
				complete: 
					function () 
					{
						//
					}
			}
		);
}
function call_mumber_hide()
{
	$(this)
		.css
		(
		 	{
			 	"background":"url(images/basic/ramco_arrow_type_3.gif)"
			}
		)
		.animate
		(
			{ 
				"width"	: 117
			}, 
			{
				duration:	1000,
				complete: 
					function () 
					{
						//
					}
			}
		);	
}

function do_nothing()
{	
	
}
