(function($) {$(document).ready(function(){		var ie6Flag = navigator.userAgent.search('MSIE 6') != -1; // IE6フラグ	var ie7Flag = navigator.userAgent.search('MSIE 7') != -1; // IE7フラグ	if( ie6Flag || ie7Flag ){		var tarElm = $('#toPageTop');		var elmHei = tarElm.innerHeight();		var winHei = $(window).height();		var getBot = tarElm.css('bottom').replace('px','');		var el = tarElm.css('position','absolute')[0];		el.style.setExpression( 'top', 'eval('+(winHei-elmHei-getBot)+'+(document.body.scrollTop||document.documentElement.scrollTop))');		$('html').css({ 'background-image':'url(null)', 'background-attachment':'fixed'});	}		//only InterviewPage	if( $("body").hasClass("interview") ){		$("ul.linkList:first").remove();	};	//only InterviewPage	if( $("body").hasClass("pv") ){		$("ul.linkList:eq(1)").remove();	};	//only BackStiryPage	if( $("body").hasClass("story") ){		$("ul.linkList:last").remove();	};		//Align the height	var alignHeight=['about','csr','conference', 'artist', 'hair', 'interview' ,'pv' ,'story'];	for(j=0; j<alignHeight.length; j++){		if( $("body").hasClass(alignHeight[j]) ){			var h=$('#header').innerHeight();			var c=$('#contents').innerHeight();			var p=$('#container').css("padding-top").replace("px","");			var n=$('#navigation02').outerHeight({margin:true});			if(n<c-h-p){				$('#contentWrap').css({ height:c-h-p });			}else{				if( $("body").hasClass('hair') ){					if($('#mapArea').size()>0){						$('#contentsInner').css({ height:n+h-$('h1').innerHeight()-$('#mapArea').innerHeight()-5 });					}else{						$('#contentsInner').css({ height:n+h-$('h1').innerHeight()+5 });					}				}else{					$('#contentWrap').css({ height:n });					$('#contentsInner').css({ height:n });				}			}		}	}	var conf = { nav01:'about', nav02:'asian_beauties', nav03:'hair', nav04:'csr', nav05:'conference' };	//SUBNAVIGATION	for (var key in conf){    	$("#navigation01 ul li ul#"+key+"List").each(function(){    		var ul = $(this);    		ul.data('h', ul.outerHeight());    	}).css({ opacity: 0.7 }).css("height","0px");    }    //STAY	var imgPostfix = '_o';	for (var key in conf){		if( $("body").hasClass(conf[key])){			var imgElm = $("#navigation01 #"+key+" img").addClass("stayImg").get(0);			var dot = imgElm.src.lastIndexOf('.');			if(! imgElm.src.match(imgPostfix) ){				imgElm.src = imgElm.src.substr(0, dot) + imgPostfix + imgElm.src.substr(dot, 4);			}		}	}	//IMG PRELOAD FUNCTION	var preloadedImages = new Array();	function preloadImage(uri){		var plength = preloadedImages.length;		preloadedImages[plength] = new Image();		preloadedImages[plength].src = uri;	}	//ROLLOVER	var conf02 = {className:"", postfix:"_o"};	$(".imgover").each(function(){		this.oSrc = this.src;		this.rSrc = this.oSrc.replace(/(\.gif|\.jpg|\.png)/, conf02.postfix + "$1");		preloadImage(this.rSrc);	}).hover(function(){		this.src = this.rSrc;	},function(){		this.src = this.oSrc;	});	//NAVIGATION ROLLOVER	$("#navigation01 a > img.over").each(function(){		var imgElm2 = $(this).get(0);		var dot2 = imgElm2.src.lastIndexOf('.');				$(this).hover(function(){			imgElm2.src = imgElm2.src.substr(0, dot2) + conf02.postfix + imgElm2.src.substr(dot2, 4);		},function(){			imgElm2.src = imgElm2.src.replace(conf02.postfix, '');		});	});	//NAVIGATION	for (var key in conf){		$("#navigation01 ul li#"+key).hover(function(){			menuFunc( $(this).get(0).id, "Down");		},function(){			menuFunc( $(this).get(0).id, "Up");		});	}	function menuFunc(num,type){		var img = $("#navigation01 ul li#"+num+" img.category").get(0);		if(img==undefined){ return true;}		var dot3 = img.src.lastIndexOf('.');		var elm = $("#navigation01 ul li#"+num+" ul#"+num+"List");		var time=300;		if(type=="Down"){			if(elm.is(":hidden")){elm.stop().animate({opacity: 1,height:elm.data('h')+'px'},{queue:false,duration:time} );}			if(elm.is(":animated")){elm.stop().animate({opacity: 1,height:elm.data('h')+'px'},{queue:false,duration:time} );}			if($(img).hasClass("stayImg")){				img.src = img.src.replace(imgPostfix,conf02.postfix);				return true;			}			if(!img.src.match(conf02.postfix)){img.src = img.src.substr(0, dot3) + conf02.postfix + img.src.substr(dot3, 4);}		}else{			if(!elm.is(":hidden")){elm.stop().animate({opacity: 0.7,height:"0px"},{queue:false,duration:time});}			if(elm.is(":animated")){elm.stop().animate({opacity: 0.7,height:"0px"},{queue:false,duration:time});}			if($(img).hasClass("stayImg")){				img.src = img.src.replace(conf02.postfix,imgPostfix);				return true;			}			img.src = img.src.replace(conf02.postfix, '');		}	}	//SMOOTH SCROLL	function objectOffsetTop(elem){ return $(elem).offset().top; }	var pagetopAncObj = $('.pagetopAnchor');	var className = "#page-top";	if(!$(className).size()){		className = "#PAGE-TOP";	}	pagetopAncObj.click(function(){		$('html, body').animate({scrollTop: objectOffsetTop(className)}, 400, "swing");		return false;	});	var pagetopAncObjA = $('.pagetopAnchor > a');	pagetopAncObjA.attr('href', '#');	pagetopAncObjA.click(function(){		$('html, body').animate({scrollTop: objectOffsetTop(className)}, 400, "swing");		return false;	});	var count = 0;	$('.pageTargetAnchor').each(function(){		$(this).click(function(){						var target = objectOffsetTop(jQuery(this).attr("href"));			$('html, body').animate({scrollTop:(target - 10)}, 400, "swing");			return false;		});		count++;	});});})(jQuery);
