    jQuery.easing.quart = function(x,t,b,c,d) {
   	    return -c * ((t=t/d-1)*t*t*t -1) + b;
    }
    function openWebOrderWindow() {
      if( $('#divWebOrderWindow').is(':visible')) {
        $('#thWebOrder').css({'border-bottom':'1px dotted gray'});
        $('#tdWebOrder').css({'border-bottom':'1px dotted gray'});
    	$('#divWebOrderWindow').animate({'height':'hide','opacity':'0.1'});
      } else {   
        $('#thWebOrder').css({'border-bottom':'none'});
        $('#tdWebOrder').css({'border-bottom':'none'});
      	$('#divWebOrderWindow').animate({'height':'show','opacity':'1.0'});
      }
    }
    $(function() {
        $("#h_menu ul").lavaLamp({
            fx    : "backinout", 
            speed : 500
        });
        $('#navigation').accordion({
            active: '.current',
            header: '.head',
            navigation: false,
            alwaysOpen: true,
            event: 'mouseover',
            fillSpace: false,
            autoHeight:true,
            animated: 'easeslide'
        });
        $('a[href*=#][rel!="face"]').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 },1000,'quart');
        			return false;
        		}
        	}
        });	
    	startTs();
    	
    	$('.dMenuFrame').corner();
    	$('.cts_bgbox').corner();
    	
    	$('#popupPickTime').hide();
    	$('#popupHowZisseki').hide();
    	$('#popupPickArea').hide();
    	$('#popupDeliArea').hide();
    	$('a[rel*=face]').facebox();

    	$('#divWebOrderWindow').hide();
    	
    	$('.tipNE').tipsy({gravity:'sw'});
    	$('.tip').tipsy({gravity:'s'});
    });
    

