// JavaScript Document
$(document).ready(function(){
	$(".user").focus(function(){
		if($(this).val() == this.defaultValue){
			$(this).val("").css("color","#404040");
        }
	});
	$(".user").blur(function(){
		if($(this).val() == ""){
        	$(this).val(this.defaultValue).css("color","#ccc");
        }
	});
	$(".section4 li").hover(function(){
		$(this).children('span').stop().toggleClass("animated flipInX").toggle();
		$(this).children('img').stop().toggle();
	});
	$(".s1_right").addClass("wow slideInRight");
	$("#menu_bg").addClass("wow slideInDown");
	$(".section2 ul img").addClass("wow bounceIn");
	$("#lc_img,.section4 li").addClass("wow fadeInUp");
	$(".fu1,.fu2,.fu3,.fu4").addClass("wow fadeInRight");
	$(".lx_box").addClass("wow fadeIn");
	$(".a_list li").children(".qq").click(function(){
		$(".a_list li").children(".aa").stop().slideUp("fast");
		$(this).siblings(".aa").stop().slideToggle("fast");
	});
	$(".pf .li2").hover(function(){
		$(".pf_ewm").stop().fadeToggle();
	});
});
function setTab(name,m,n){ 
	for( var i=1;i<=n;i++){ 
		var menu = document.getElementById(name+i); 
		var showDiv = document.getElementById("cont_"+name+"_"+i); 
		menu.className = i==m ?"on":""; 
		showDiv.style.display = i==m?"block":"none"; 
	} 
} 

var _width = parseInt(window.screen.width);
var scale = _width/1220;
var ua = navigator.userAgent.toLowerCase();
var result = /android (\d+\.\d+)/.exec(ua);
if (result){
var version = parseFloat(result[1]);
if(version>2.3){
document.write('<meta name="viewport" content="width=1220, minimum-scale = '+scale+', maximum-scale = '+scale+', target-densitydpi=device-dpi">');
}else{
document.write('<meta name="viewport" content="width=1220, target-densitydpi=device-dpi">');
}
} else {
document.write('<meta name="viewport" content="width=1220, user-scalable=yes, target-densitydpi=device-dpi">');
}