/*CSS Browser Selector v0.3.2Rafael Lima (http://rafael.adm.br)http://rafael.adm.br/css_browser_selectorLicense: http://creativecommons.org/licenses/by/2.5/Contributors: http://rafael.adm.br/css_browser_selector#contributors*/function css_browser_selector(u){var ua = u.toLowerCase(),is=function(t){return ua.indexOf(t)>-1;},g='gecko',w='webkit',s='safari',h=document.getElementsByTagName('html')[0],b=[(!(/opera|webtv/i.test(ua))&&/msie\s(\d)/.test(ua))?('ie ie'+RegExp.$1):is('firefox/2')?g+' ff2':is('firefox/3')?g+' ff3':is('gecko/')?g:/opera(\s|\/)(\d+)/.test(ua)?'opera opera'+RegExp.$2:is('konqueror')?'konqueror':is('chrome')?w+' chrome':is('applewebkit/')?w+' '+s+(/version\/(\d+)/.test(ua)?' '+s+RegExp.$1:''):is('mozilla/')?g:'',is('j2me')?'mobile':is('iphone')?'iphone':is('ipod')?'ipod':is('mac')?'mac':is('darwin')?'mac':is('webtv')?'webtv':is('win')?'win':is('freebsd')?'freebsd':(is('x11')||is('linux'))?'linux':'','js']; c = b.join(' '); h.className += ' '+c; return c;}; css_browser_selector(navigator.userAgent);/* navigation */jQuery(document).ready(function(){       jQuery("ul.subnav").parent().append("<span></span>"); //Only shows drop down trigger when js is enabled (Adds empty span tag after ul.subnav*)        jQuery("ul#globalNav li span").hover(function() { //When trigger is clicked...            //Following events are applied to the subnav itself (moving subnav up and down)          jQuery(this).parent().find("ul.subnav").slideDown('fast').show(); //Drop down the subnav on click            jQuery(this).parent().hover(function() {          }, function(){              jQuery(this).parent().find("ul.subnav").slideUp('slow'); //When the mouse hovers out of the subnav, move it back up          });            //Following events are applied to the trigger (Hover events for the trigger)          }).hover(function() {              jQuery(this).addClass("subhover"); //On hover over, add class "subhover"          }, function(){  //On Hover Out              jQuery(this).removeClass("subhover"); //On hover out, remove class "subhover"      });    });  /* /navigation *//* group_photo */jQuery(document).ready(function() {		jQuery("a[rel=group_photo]").fancybox({			'transitionIn'	: 'elastic',			'transitionOut'	: 'elastic',			'overlayColor'		: '#000',			'overlayOpacity'	: 0.8		});	});/* /group_photo *//* group_photo */jQuery(document).ready(function() {		jQuery("a[rel=history_images]").fancybox({			'transitionIn'	: 'elastic',			'transitionOut'	: 'elastic',			'overlayColor'		: '#000',			'overlayOpacity'	: 0.8		});	});/* /group_photo *//* video */jQuery(document).ready(function() {		jQuery("#video").fancybox({				'autoScale'			: true,				'transitionIn'		: 'elastic',				'transitionOut'		: 'elastic',				'overlayColor'		: '#000',				'overlayOpacity'	: 0.8,				'padding'			: 0,				'hideOnContentClick': true,				'type'				: 'iframe'			});});/* /video *//* tooltip */jQuery(function(){     jQuery(".tooltip a").hover(function() {        jQuery(this).next("span").animate({opacity: "show", top: "43"}, "slow");}, function() {               jQuery(this).next("span").animate({opacity: "hide", top: "68"}, "fast");     });});/* /tooltip *//*Auto	scroll*/// Easingの追加jQuery.easing.quart = function (x, t, b, c, d) {    return -c * ((t=t/d-1)*t*t*t - 1) + b;}; // scroll設定jQuery(document).ready(function(){jQuery('a[href*=#]').click(function() {        if (location.pathname.replace(/^\//,'') == this.pathname.replace(/^\//,'') && location.hostname == this.hostname) {            var $target = jQuery(this.hash);            $target = $target.length && $target || jQuery('[name=' + this.hash.slice(1) +']');            if ($target.length) {                var targetOffset = $target.offset().top;                jQuery('html,body').animate({ scrollTop: targetOffset }, 1200, 'quart');                return false;            }        }    }); });
