/*
	共通セッティング
*/
 
$(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 }, 600, 'easeOutExpo');
				return false;
			}
		}
	});

	/* 	
		フォームフォーカス	
	*/

	var formInputs = $("form input[type=text],form textarea")
	
	formInputs.focus(function() {
		$(this).css("background-color","#ffffff");
	}).blur(function() {
		$(this).css("background-color","#ffffff");
	});

	/* 	
		フォームボタン	
	*/

	var formButtons = $("ul.form-block-01 button")
	
	formButtons.mouseover(function() {
		$(this).css("background-position","0% -56px");
	}).mouseout(function() {
		$(this).css("background-position","0% 0%");
	});
});


window.onload = function() {
  var myIMG = document.getElementById("site-logo");
  var myMonth =new Date();
  myDate = myMonth.getMonth() + 1;
  if(myDate>=3 && myDate<6){
    myIMG.style.backgroundImage = "url(/images/tree.png)";//春
  }else if(myDate>=6 && myDate<9){
    myIMG.style.backgroundImage = "url(/images/tree_g.png)";//夏
  }else if(myDate>=9 && myDate<12){
    myIMG.style.backgroundImage = "url(/images/tree.png)";//秋
  }else if(myDate==12 || myDate<=3){
    myIMG.style.backgroundImage = "url(/images/tree_g.png)";//冬
  }
}

