// JavaScript Document

//FORM lable/value animation
$(document).ready(function(){
	
	// Maz Special Request - show menu tree + images after a second
	//$("#page-tree").show(100).delay(100).fadeIn(100);
	//$(".widget-content").show(100).delay(100).fadeIn(100);
	
	//$("#page_content").delay(50).slideDown(300);
	$("#page_content").delay(50).css({opacity: 0.0, visibility: "visible"}).animate({opacity: 1.0},'fast');

	
	$("input[type=text]").each(function(){
		$(this).click(function () {
			if (this.value == this.defaultValue) {this.value = '';}
		});
		$(this).blur(function () {
			if (this.value === '') {this.value = this.defaultValue;}
		});
	});
	$(".wpcf7-form-control-wrap input").each(function(){
		$(this).click(function () {
			if (this.value == this.defaultValue) {this.value = '';}
		});
		$(this).blur(function () {
			if (this.value === '') {this.value = this.defaultValue;}
		});
	});
	$(".wpcf7-form-control-wrap textarea").each(function(){
		$(this).click(function () {
			if (this.value == this.defaultValue) {this.value = '';}
		});
		$(this).blur(function () {
			if (this.value === '') {this.value = this.defaultValue;}
		});
	});
});

// IE6 fix
$(document).ready(function(){
	$("*").hover(
		function(){$(this).addClass("hover");}, 
		function(){$(this).removeClass("hover");}
	);
});
// Crap browser
$(document).ready(function(){
	if($.browser.msie && $.browser.version.substr(0,1)<="6") {
		$("body").prepend('<div class="browser_warning" style="width:100%;padding:5px;background-color:#F00;color:#FFF;font-family:Arial,Helvetica, sans-serif;font-size:12px;z-index:999;"><p class="center"><strong>You are using Internet Explorer version 6.0 or lower. Due to security issues and lack of support for Web Standards it is highly recommended that you upgrade to a modern browser.<br/>Switch to a <a style="color:#FFF;" href="http://www.mozilla.com/firefox/">normal browser</a> or consider <a style="color:#FFF;" href="http://www.microsoft.com/windows/internet-explorer">upgrading your Internet Explorer</a> to the latest version.</strong></p></div>');
	}
});

