currentOffsetX = 0;
currentOffsetY = 0;
shapeWidth=260;
shapeHeight=140;
positioning = 0; //Three type boolean. 0: Normal, 1: Undergoing, 2: Settled
$(document).ready(function() {
	/*Get Shape Position */
	currentOffsetX=$('#shape').offset().left+shapeWidth/2;//+130 Adding half of shape's width, since offset is got from upper left corner.
	currentOffsetY=$('#shape').offset().top+shapeHeight/2;//+70 Adding half of shape's height, since offset is got from upper left corner.
	
	/* Trace Mouse */
	$(document).mousemove(function(e){
		if(Math.abs(e.pageX-currentOffsetX)<=shapeWidth/2 && Math.abs(e.pageY-currentOffsetY)<=shapeHeight/2){
			if(positioning!=1){
				positioning=1;
				$('.headingWrapper>h1').stop();
				$('.headingWrapper>h1').animate({
					position:'absolute',
					'padding-left':'100',
					opacity:'.0'
				},{
					duration:150,
					complete:function(){
						$('.headingWrapper>h1').html('Very Soon');
						$('.headingWrapper>h1').animate({
							'padding-left':'68',
							opacity:'1'
						},150);
					}
				});
			}
			
		}else if(positioning!=0){
			positioning=0;
			$('.headingWrapper>h1').stop();
			$('.headingWrapper>h1').animate({
				'padding-left':'100',
				opacity:'.0'
			},{
				duration:150,
				complete:function(){
					$('.headingWrapper>h1').html('Coming Soon');
					$('.headingWrapper>h1').animate({
						'padding-left':'68',
						opacity:'1'
					},{
						duration:150,
						complete:function(){
							$('.headingWrapper>h1').animate({
								position:'static'
							});
						}
					});
				}
			});
		}
	});
});

