//JavaScript Document

$(function(){
	$("#content ul").css({overflow:"hidden"}); // for graceful degradation
	
	var slider = $("#slider").jSlideView({ // creates the content slider
		view: 1,
		direction: "horizontal",
		width: 995,
		height: 500,
		prev: ".prev",
		next: ".next",
		loop: false,
		speed: 600,
		easing: "easeInOutBack"
	});
	
	$("#homeBtn").click(function(e){
		$("#navHover").animate({marginLeft: 0, width: 85}, {duration: 400, easing: "easeInOutBack"});
		
		slider.goto(0);
		$(this).addClass("selectedNav");
		$(this).parent().siblings().children("a").removeClass("selectedNav");		
		return false;
	});
	
	$("#portfolioBtn").click(function(e){
		$("#navHover").animate({marginLeft: 105, width: 145}, {duration: 400, easing: "easeInOutBack"});
		
		slider.goto(1);
		$(this).addClass("selectedNav");
		$(this).parent().siblings().children("a").removeClass("selectedNav");		
		return false;
	});
	
	$("#servicesBtn").click(function(e){
		$("#navHover").animate({marginLeft: 270, width: 135}, {duration: 400, easing: "easeInOutBack"});
		
		slider.goto(2);
		$(this).addClass("selectedNav");
		$(this).parent().siblings().children("a").removeClass("selectedNav");		
		return false;
	});
	
	$("#contactBtn").click(function(e){
		$("#navHover").animate({marginLeft: 425, width: 125}, {duration: 400, easing: "easeInOutBack"});
		
		slider.goto(3);
		$(this).addClass("selectedNav");
		$(this).parent().siblings().children("a").removeClass("selectedNav");		
		return false;
	});
		
	//--------------- Print Images ---------------//
	$("#printThumbs").click(function(e){
		$("#thumbContainer").empty();
		$("#thumbContainer").html('<ul id="thumbs"></ul>');
			$("#thumbs").append('<li><a href="img/print/ticket_concepts.jpg" rel="shadowbox[gallery]"><img src="img/print/thumb_ticket_concepts.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/print/grad_poster_3.jpg" rel="shadowbox[gallery]"><img src="img/print/thumb_grad_poster_3.jpg" alt="Print Thumb" /></a></li>');		
	        $("#thumbs").append('<li><a href="img/print/selmon_leeroy_cd_.jpg" rel="shadowbox[gallery]"><img src="img/print/thumb_selmon_leeroy_cd_mock.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/print/grisham_book_2.jpg" rel="shadowbox[gallery]"><img src="img/print/thumb_grisham_book_2.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/print/grisham_book.jpg" rel="shadowbox[gallery]"><img src="img/print/thumb_grisham_book.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/print/movado.jpg" rel="shadowbox[gallery]"><img src="img/print/thumb_movado.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/print/movado_ad_2.jpg" rel="shadowbox[gallery]"><img src="img/print/thumb_movado_ad_2.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/print/watch.jpg" rel="shadowbox[gallery]"><img src="img/print/thumb_watch.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/print/movado_mall.jpg" rel="shadowbox[gallery]"><img src="img/print/thumb_movado_mall.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/print/olivebar_layout.jpg" rel="shadowbox[gallery]"><img src="img/print/thumb_olivebar_layout.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/print/whaling_poster_kid.jpg" rel="shadowbox[gallery]"><img src="img/print/thumb_whaling_poster_kid.png" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/print/poster_bus_stop.jpg" rel="shadowbox[gallery]"><img src="img/print/thumb_poster_bus.jpg" alt="Print Thumb" /></a></li>');
		    
		Shadowbox.clearCache();
		Shadowbox.setup("a[rel*=shadowbox]",{gallery:'gallery'});
		return false;
	});
	
	$("#identityThumbs").click(function(e){
		Shadowbox.clearCache();
		$("#thumbContainer").empty();
		$("#thumbContainer").html('<ul id="thumbs"></ul>');
			$("#thumbs").append('<li><a href="img/identity/cheerleader_logo.jpg" rel="shadowbox[gallery]"><img src="img/identity/thumb_cheerleader_logo.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/identity/you_neq.png" rel="shadowbox[gallery]"><img src="img/identity/thumb_you_neq.png" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/identity/ares.jpg" rel="shadowbox[gallery]"><img src="img/identity/thumb_ares.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/identity/IFCD.jpg" rel="shadowbox[gallery]"><img src="img/identity/thumb_IFCD.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/identity/cardinal.jpg" rel="shadowbox[gallery]"><img src="img/identity/thumb_cardinal.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/identity/mulberry.jpg" rel="shadowbox[gallery]"><img src="img/identity/thumb_mulberry.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/identity/redphos_logo.jpg" rel="shadowbox[gallery]"><img src="img/identity/thumb_redphos.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/identity/songvote_logo.jpg" rel="shadowbox[gallery]"><img src="img/identity/thumb_songvote.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/identity/zilla_sport_logo.jpg" rel="shadowbox[gallery]"><img src="img/identity/thumb_zilla_sport.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/identity/riccio.jpg" rel="shadowbox[gallery]"><img src="img/identity/thumb_riccio.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/identity/ascend_stationary.jpg" rel="shadowbox[gallery]"><img src="img/identity/thumb_ascend_stationary.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/identity/ascend_dvd.jpg" rel="shadowbox[gallery]"><img src="img/identity/thumb_ascend_dvd.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/identity/orange_stationery.jpg" rel="shadowbox[gallery]"><img src="img/identity/thumb_orange_stationery.jpg" alt="Print Thumb" /></a></li>');
		$("#thumbs").append('<li><a href="img/identity/youneq_stationery.png" rel="shadowbox[gallery]"><img src="img/identity/youneq_stationery_thumb.png" alt="Print Thumb" /></a></li>');
		Shadowbox.clearCache();
		Shadowbox.setup("a[rel*=shadowbox]",{gallery:'gallery'});
		return false;
	});
	
	$("#miscThumbs").click(function(e){
		$("#thumbContainer").empty();
		$("#thumbContainer").html('<ul id="thumbs"></ul>');
			$("#thumbs").append('<li><a href="img/misc/snowboard_aphosis.jpg" rel="shadowbox[gallery]"><img src="img/misc/thumb_snowboard_aphosis.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/misc/snowboard_helios.jpg" rel="shadowbox[gallery]"><img src="img/misc/thumb_snowboard_helios.jpg" alt="Print Thumb" /></a></li>');
			$("#thumbs").append('<li><a href="img/misc/snowboard_onyx.jpg" rel="shadowbox[gallery]"><img src="img/misc/thumb_snowboard_onyx.jpg" alt="Print Thumb" /></a></li>');
	        $("#thumbs").append('<li><a href="img/misc/nidecker_snowboard.jpg" rel="shadowbox[gallery]"><img src="img/misc/thumb_nidecker_.jpg" alt="Print Thumb" /></a></li>');
		Shadowbox.clearCache();
		Shadowbox.setup("a[rel*=shadowbox]",{gallery:'gallery'});
		return false;
	});
		
	$("#webThumbs").click(function(e){
		$("#thumbContainer").empty();
		$("#thumbContainer").html('<p class="comingSoon">Coming soon.</p>');
		return false;
	});
	
	// $("#printThumbs").trigger("click");
});