// rollover
$(function(){
	$("img.rollover").mouseover(function(){
		$(this).attr("src",$(this).attr("src").replace(/^(.+)(\.[a-z]+)$/,"$1-on$2"));
		}).mouseout(function(){
			$(this).attr("src",$(this).attr("src").replace(/^(.+)-on(\.[a-z]+)$/,"$1$2"));
	});
});

////scroll
$(document).ready(function(){
  $('a[href*=#]').click(function() {
    if (location.pathname.replace(/^\//,'') == this.pathname.replace(/^\//,'')
    && location.hostname == this.hostname) {
      var $target = $(this.hash);
      $target = $target.length && $target
      || $('[name=' + this.hash.slice(1) +']');
      if ($target.length) {
        var targetOffset = $target.offset().top;
        $('html,body')
        .animate({scrollTop: targetOffset}, 1000);
       return false;
      }
    }
  });


//#header .header-nav ul li.last
	$("#header .header-nav ul li:last-child").addClass("last");

//#contents-wrap #contents #article .section02 .box-04.last
	$("#contents-wrap #contents #article .section02 .box-04:nth-child(3n)").addClass("last");

//#nav-wrap #page-nav ul li.fast
	$("#nav-wrap #page-nav ul li:last-child").addClass("last");

//stripe table
 $("table.hyou tr:nth-child(even)").addClass("even");
});




