$(document).ready(function() {
	Cufon.replace('h1')('h2')('h3')('#menu LI A', {hover: true})('A.button-red')('A.button-orange')('A.button-footer');
	$("a[rel^=lightbox]").fancybox({overlayOpacity:0.7, centerOnScroll:false, imageScale: false});
	$("a[class^=iframe]").fancybox({overlayOpacity:0.7, centerOnScroll:false, hideOnContentClick:false,frameWidth:700,frameHeight:500});
	//OLD BROWSER NOTIFICATION
	var notification = '<div id="browser-upgrade"><div class="upgrade-container"><p>Browser-ul tau <strong>este mult prea vechi</strong>. Versiunea pe care o folosesti are probleme si vulnerabilitati si nu afiseaza multe din functionalitatile site-ului. <strong>Iti recomandam sa instalezi o versiune noua!</strong></p><div class="browsers"><a href="http://www.google.com/chrome" title="Google Chrome" id="chrome" rel="blank"></a><a href="http://windows.microsoft.com/en-US/internet-explorer/products/ie/home" title="Internet Explorer" id="ie9" rel="blank"></a><a href="http://www.mozilla.org/en-US/firefox/new/" title="Mozilla Firefox" id="firefox" rel="blank"></a><a href="http://www.opera.com/download/" title="Opera" id="opera" rel="blank"></a><a href="http://www.apple.com/safari/download/" title="Safari" id="safari" rel="blank"></a></div><div class="clear">&nbsp;</div></div></div>';
	var b = $.browser;
	var body = $('body');
	if((b.msie && b.version < '8.0')){
		body.prepend(notification);
		$('#top-link').remove();
	}
	if((b.opera) && (b.version < '10.1')){
		body.prepend(notification);
	}
	if((b.safari) && (b.version < '3.2')){
		body.prepend(notification);
	}
	if((b.mozilla) && (b.version.slice(0,2) == '1.9')){
		body.prepend(notification);
	}
	//external attribute
	$('a[rel="blank"]').click(function(){
		window.open(this.href);
		return false;
	});
});
function personalization_form(check_name, div_name){
	if(document.getElementById(check_name).value == 0){
		$('#'+div_name).show('slow');
		document.getElementById(check_name).value = 1;
		return false;
	}else{
		/*$('#'+div_name).hide('slow');
		document.getElementById(check_name).value = 0;*/
		/*document.forms['shop-form'].submit();*/
		$('#'+div_name).parent().parent().submit();
	}
}
//************************************************************************************
//jQuery Highlight selected "Custom product"
function highlight(pr){
	$("div[class='custom_product highlight']").removeClass("highlight");
	$("#"+pr).addClass("highlight");
}
//************************************************************************************
//jQuery Highlight selected "Shopping steps"
function highlight_options(pr){
	$("div[class='modalitate-plata highlight']").removeClass("highlight");
	$("#"+pr).addClass("highlight");
}

