$(document).ready(function(){
	//To switch directions up/down and left/right just place a "-" in front of the top/left attribute
	//Caption Sliding (Partially Hidden to Visible)
	$('.forsideBoks.introTekst').hover(function(){
		$(".slide", this).stop().animate({top:'250px'},{queue:false,duration:160});
	}, function() {
		$(".slide", this).stop().animate({top:'335px'},{queue:false,duration:160});
	});
	$('#karusell').cycle({ 
	  	fx: 		'fade', 
	  	speed: 		1500, 
	  	timeout: 	6000,
	  	pause: 		1, 
	  	pager: 		'.nav' 
	  });
});
// SEARCH FIELD VALUE SWAP
$(function() {
    swapValues = [];
    $(".swap_value").each(function(i){
        swapValues[i] = $(this).val();
        $(this).focus(function(){
            if ($(this).val() == swapValues[i]) {
                $(this).val("");
            }
        }).blur(function(){
            if ($.trim($(this).val()) == "") {
                $(this).val(swapValues[i]);
            }
        });
    });
});
