function checkBrowser(){}

var windowOptions = 'resizable=no,toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes';
var wWith = "660";
var wHeight = "500";
var windowName = 'aWindow';
    	$(document).ready(function(){
    			if($('ul.tabs li a.selected').size() == 0) $('ul.tabs li a:first').addClass('selected');
    			
    			$('.home-box a').hover(
    			function(){
    				$(this).animate({color:'#111',backgroundColor:'#f3f3f3',borderRightColor:'#222',borderLeftColor:'#222',borderRightColor:'#222',borderTopColor:'#222',borderBottomColor:'#222'},600);
    				$(this).parent().parent().find('.label span').fadeIn();
    			},
    			function(){
    				$(this).animate({color:'#333',backgroundColor:'#fff',borderRightColor:'#d6d6d6',borderLeftColor:'#d6d6d6',borderRightColor:'#d6d6d6',borderTopColor:'#d6d6d6',borderBottomColor:'#d6d6d6'},600);
    				$(this).parent().parent().find('.label span').fadeOut();
    			});
    			if($('ul.tabs li a')){
				$('ul.tabs li a').click(function(){
    					if($(this).hasClass('selected')) return false;
    					$('ul.tabs').parent().find('.selected').removeClass('selected');
    					$(this).addClass('selected');
    				$.ajax({
    					url:this.href, 
						data : {'ajax':true},
    					success: function(html){
    						$('#footer').fadeOut();
    						var aWidth = $('center').width(); 
    						//$('#center').css({width:aWidth});
    						$('#center .content').fadeOut('400');
    						setTimeout(function(){
								$('#center .content').html(html);
								$('.thickbox').click(function(){
									var anHref = $(this).attr('href');
									var newWindow = window.open(anHref, windowName, windowOptions + ',width=' + wWith + ',height=' + wHeight);
        							newWindow.focus();
									return false;
								});
							},500);
    						$('#center .content').fadeIn('400');
    						$('#center').css({width:'auto'});
    						$('#footer').fadeIn();
    						
    					}
    				});
    				return false;
    			});
    			}
				
				$('.new-window').click(function(){
					var anHref = $(this).attr('href');
					var newWindow = window.open(anHref, windowName, windowOptions + ',width=' + wWith + ',height=' + wHeight);
        			newWindow.focus();
					return false;
				});
    	});

$(window).load(function(){
	if($('.section-titles h3')) setTimeout(function(){$('.section-titles h3').fadeIn(400)},400);
    if($('.section-titles h4')) setTimeout(function(){$('.section-titles h4').fadeIn(400)},800);
    $('.accordion').accordion({header:'div.xt-title-wrapper', autoHeight: false});
 });
 
 function newWindowWithURL(el){
    var anHref = $(el).attr('href');
    var newWindow = window.open(anHref, windowName, windowOptions + ',width=' + wWith + ',height=' + wHeight);
    newWindow.focus();
    return false;
 }
