$(document).ready(function() {

	// Stuff to do as soon as the DOM is ready;
	
	//$('#content').cycle({ 
	//    fx: 'scrollHorz', 
	//	speed:  'slow', 
	//	speedOut: 100,
	//	speedIn: 300,
	//    delay: 0,
	//	timeout: 0,
	//	// easeIn:  'bounceout', 
	//	// easeOut: 'backin',
	//	prev:   '.more', 
	//});
	
	//$('.more').hover(function(){
	//	$(this).attr("src", "assets/icons/more-active.png");
	//}, function(){
	//	$(this).attr("src", "assets/icons/more.png");
	//});
	$('.slide img:eq(1)').css({zIndex: 99, width: 340, height: 260, marginLeft: -15, marginTop: -20}, 20);
	
	// Gallery	
	$("#lastfm:empty").each(function(i){
		$(this).html("Loading...");
	});
	
	$('.thumbwell').click(function(){
		var temp_dir = '/wp-content/themes/portfolio/assets/slides'
		var url = temp_dir + $(this).attr("rel");
		var title = $(this).attr("title");
		//alert(url);
		//$('#overlay').fadeIn(200);
		$('#main').animate({opacity: 0.25});
		$('.single-pic').html("<img src="+url+">" + "<h5>" + title + "</h5>");
		$('.single-pic').fadeIn(400);
	});
	$('.single-pic').click(function(){
		//$('#overlay').fadeOut(400);
		$('#main').animate({opacity: 100.0});
		$('.single-pic').fadeOut(200);
	});
	
	// Form
	$('#submit_me').click(function(){
		$('#leftcolumn > form').submit();
	});
	$('input,textarea').focus(function(){
		$(this).addClass('active');
	});
	$('input,textarea').blur(function(){
		$(this).removeClass('active');
	});
});