$.browser.msie6 = $.browser.msie && /MSIE 6\.0/i.test(window.navigator.userAgent) && !/MSIE 7\.0/i.test(window.navigator.userAgent);

/*log*/
function log(a,a1,a2,a3,a4,a5,a6,a7) {
 window.console && window.console.log && window.console.log(a,a1,a2,a3,a4,a5,a6,a7);
}

function trJs(o){
	o.className += ' js';
}
var bodyLoaded;

window.onload = function(){
	bodyLoaded = true;
}

function initOnLoad(sElementName,loadFunction) {  
	var oElement = (sElementName == "body") ? document[sElementName] : 
		document.getElementById(sElementName); 
	if(oElement != null && typeof(oElement) != "undefined") { loadFunction(oElement); } 
	else if(!bodyLoaded) { setTimeout(function() {initOnLoad(sElementName,loadFunction); }, 0); } 
}

//initOnLoad("call-form",trJs);


document.write('<style type="text/css">\
#text-cols .upp{display:none;}\
</style>')


$(document).ready(function(){

if($.browser.msie){
	$('hr').not('.hr > hr').wrap('<div class="hr"></div>')
}

	intTextColHrefs()

});



function intTextColHrefs(){

	var textColsHrefs = $('#text-cols-hrefs');
	var textCols = $('#text-cols');
	
	if(!textColsHrefs.length || !textCols.length) return;

	textColsHrefs.find('a').bind('click',function(){
		
		if(textCols.lock) return false;

		textCols.lock = true;
		var tO = this,
      href = this.href.slice( this.href.lastIndexOf('#'), this.href.length );
		
		$(this).parent().addClass('activepl')
			.siblings().filter('.activepl').removeClass('activepl')
			
		var vis = $(href).siblings().filter('.vis');
			
		vis.parent().height(vis.height())
		$(href).css('visibility','hidden')
			
		vis.fadeOut('fast',function(){
				
				$(this).removeClass('vis');
				$(href).show().addClass('vis');
				
			//log(this.runtimeStyle.filter)
		//		delete this.runtimeStyle.filter;
		//		$(this).removeAttr('filter');
				
				$(this).parent().animate({height:$(href).height()},'fast',function(){
					$(href).css('visibility','visible')
					textCols.lock = false;
				})
		})
	
		
		return false;
	})

}
