/**
 *	AnimationBox 動畫盒初始化
 */
$(function() {				
	var hover_in_easing		= "easeInOutQuart";
	var hover_out_easing	= "easeInOutQuart";

	$(".BoxContainer").show();
	$(".InfoBox").css('opacity', 0.9);

	$("UL.AnimationBox LI").hover(function() {
		$(this).find(".InfoBox").animate({bottom:"0"},{duration: 400, easing: hover_in_easing});
	}, function() {
		$(this).find(".InfoBox").animate({bottom:"-42px"},{duration: 300, easing: hover_out_easing});
	});
});

/**
 *	PictureBox 縮圖區初始化
 */
$(function() {
	var spotlight = {
		opacity		: 0.7,
		picWidth	: $('.PictureBox LI').find('IMG').width(), 
		picHeight	: $('.PictureBox LI').find('IMG').height()
	};

	$('.PictureBox LI').css({ 'width' : spotlight.picWidth, 'height' : spotlight.picHeight });

	// 縮圖區(PictureBox)滑鼠特效
	// Hover 時
	$('.PictureBox LI').hover(function(){$(this).find('IMG').addClass('active').css('opacity', 1)}, function(){$(this).find('IMG').removeClass('active')});

	// 綁定滑鼠離開 PictureBox 觸發
	$('.PictureBox LI').bind('mouseleave', function(){ $(this).find('IMG').css('opacity', spotlight.opacity) });

	// 初始化新增透明度
	$('.PictureBox LI').find('IMG').css('opacity', spotlight.opacity);
});

/**
 *	HyperLink 模擬
 */
function GO(url) {
	window.location.href = url;
}

