$(document).ready(function($){
	
	equalHeight(jQuery(".stockblock .in li"));
	
	jQuery(".tab:not(:first)").hide();

	//to fix u know who
	jQuery(".tab:first").show();
	
	jQuery(".htabs a").click(function(){
	
		$(".htabs li").removeClass("act");
		$(this).parent().addClass("act");
	
		stringref = jQuery(this).attr("href").split('#')[1];

		jQuery('.tab:not(#'+stringref+')').hide();

		if (jQuery.browser.msie && jQuery.browser.version.substr(0,3) == "6.0") {
			jQuery('.tab#' + stringref).show();
		}
		else 
			jQuery('.tab#' + stringref).fadeIn();
		
		return false;
	});
	jQuery('.lft a').click(function(){
		jQuery('.htabs a[href=#pict]').click();
		return false;
	});
	if($("#slider").length > 0)
	{
		$("#slider").easySlider({auto: true, continuous: true, numeric: true, speed: 1400});
	}
	if($('#shk-power option').length > 0)
	{
		$('#shk-power').val($('#shk-power option:first').val());
		$('#shk-contact input').click(function(){
			document.location.href = '/contact-us';
		});
	}
	$('#shk-power').change(function(){
		price = $('#shk-power').val();
		if(price == 'По запросу')
		{
			$('#shk-submit').css('display', 'none');
			$('#price-block').css('display', 'none');
			$('#shk-contact').css('display', 'block');
		}
		else
		{
			$('#shk-contact').css('display', 'none');
			$('#price-block').css('display', 'block');
			$('#shk-submit').css('display', 'block');
			$('#shk-price').val(price);
			$('#display-price').html(price);
			$('#shk-pow').val($('#shk-power option:selected').text());
		}
	});
});

hljs.tabReplace = '\x09';
hljs.tabReplace = '<span class="indent">&nbsp;</span>';
hljs.initHighlightingOnLoad();
