$(document).ready(function(){
	// Swap Values Input Fields
	$(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]);}
	        });
	    });
	});
	
	// Colorbox
	$(".colorbox_photo").colorbox({
		maxWidth: "95%", 
		maxHeight: "95%", 
		photoScaling: "true",
		slideshow: "true",
		slideshowSpeed: 6000,
		opacity: .75});
	$(".colorbox_floorplan").colorbox({
		maxWidth: "95%", 
		maxHeight: "95%", 
		photoScaling: "true",
		opacity: .75});
	$(".colorbox").colorbox({
		opacity: .75
	});
	$(".colorbox_iframe").colorbox({width:"900px", height:"700px", iframe:true, opacity: .75});
	$(".colorbox_map").colorbox({width:"500px", height:"500px", iframe:true, opacity: .75});
	$(".colorbox_vow").colorbox({width:"1080px", height:"1000px", iframe:true, opacity: .75});
	
	// Drop Down Navigation System
	$(".drop_down").click(function(){
		var dropDown = $(this).attr('href');
		if ($('#drop_down_navigations').children('div:visible').length > 0){
			var tempDrop = $('#drop_down_navigations').children('div:visible').attr('id');
			var currentDrop = '#'+(tempDrop);
			if (dropDown == currentDrop){
				$(this).removeClass('active');
				$(currentDrop).slideUp(700,'easeOutQuad');
				return false;
			};
			$('#navigation a.active').removeClass('active');
			$('#drop_down_navigations').children('div:visible').slideUp(700,'easeOutQuad');
			$(this).addClass('active');
			$(dropDown).delay(700).slideDown(700,'easeOutQuad');
		} else {
			$(this).addClass('active');
			$(dropDown).slideDown(700,'easeOutQuad');
		};
		return false;
	});
	
	// Manually Close Drop Down
	$('.close_slide').click(function(){
		$(this).closest('.drop_down_navigation_wrapper').slideUp(700,'easeOutQuad');
		$('#navigation a.active').removeClass('active');
		return false;
	});
	
	
	
	// Newsletter Form Focus
	if ($('#cutyku-cutyku').attr('value')){$('#cutyku-cutyku').addClass('active');}
	$('#cutyku-cutyku').focus(function(){$(this).addClass('active');});
	$('#cutyku-cutyku').blur(function(){
		if ($('#cutyku-cutyku').attr('value')){$('#cutyku-cutyku').addClass('active');} else {$('#cutyku-cutyku').removeClass('active');}
	});
	
	
	
});
