$(document).ready(function () {
	
	// JavaScript countdown 
    var austDay = new Date();
    austDay = new Date(austDay.getFullYear() + 0, 1, 11); //Just change this to your own date of launching
    $('#countdown').countdown({
        until: austDay
    });
	
	/* Social Icon Hover Tooltip Function */
	$(document).ready(function(){
		$('a.tipsy').tipsy({	
			delayIn: 0,      // delay before showing tooltip (ms)
			delayOut: 0,     // delay before hiding tooltip (ms)
			fade: true,     // fade tooltips in/out?
			fallback: '',    // fallback text to use when no tooltip text
			gravity: 's',    // gravity
			html: false,     // is tooltip content HTML?
			live: false,     // use live event support?
			offset: 15,       // pixel offset of tooltip from element
			opacity: 0.8,    // opacity of tooltip
			title: 'title',  // attribute/callback containing tooltip text
			trigger: 'hover' // how tooltip is triggered - hover | focus | manual	
		});
	});
	/* Social Icon Hover Tooltip Function */
	
	/* Lightbox Function */
	$(document).ready(function() {
	$("a[rel^='prettyPhoto']").prettyPhoto({
		opacity:0.80,
		default_width:500,
		default_height:344,
		theme:'light_square',
		hideflash:false,
		modal:false,
		showTitle: false,
		});
	});
	/* Lightbox Function */
	

	 $('.slide-out-div').tabSlideOut({
		 tabHandle: '.handle',                      //class of the element that will be your tab
		 pathToTabImage: 'images/arrows.png', 	//path to the image for the tab (optionaly can be set using css)
		 imageHeight: '63px',                       //height of tab image
		 imageWidth: '23px',                         //width of tab image    
		 tabLocation: 'left',                        //side of screen where tab lives, top, right, bottom, or left
		 speed: 300,                                 //speed of animation
		 action: 'click',                            //options: 'click' or 'hover', action to trigger animation
		 topPos: '260px',                            //position from the top
		 fixedPosition: false                        //options: true makes it stick(fixed position) on scroll
	 });
	
	// Bottom contact form JavaScript Validation
    $("#newslatter_form").validate({
        meta: "validate",
        submitHandler: function (form) {
            $('#newslatter_form').hide();
            $('#newslattersucessmessage').append("<h4 class='form_thanks'>Thanks! We'll make sure you'll be the first to hear when we are live!</h4>");
            return false;
            form.submit();
        },
        /* */
        rules: {
            emailAddress: {
                required: true,
                email: true
            },
        },
        messages: {
            emailAddress: {
                required: "Please Enter Email Address",
                email: "Email address should be valid"
            },
        },
    });
	//End
});
