function css() {

	/* go on for IE in generall */
	if($.browser.msie){
		
		/* take care IE 6 only */
		if($.browser.version <= 6) {
		
			$('#top #nav li:first-child, #news-mod li:first-child, #prod-short #prod-gal li:first-child,#footer ul li:first-child, #prod-details .mod-tabs .tabs-nav li:first-child').addClass('first-child');
		
			$('img').css('behavior','url(js/iepngfix.htc)');
		
		}
	}
	
	$('.mod-tabs').tabs();
	
	 $('.simple-slide').slide({
      cookieName: 'homepage',
      slideAnimate: true,
      slideSpeed: 750,
      slideInterval1: 7000,             
	  slideInterval2: 0         });
	  
	
	$('.multiple-slide').slide({cookieName: 'subpage'});
	
}

$(document).ready(css);

jQuery.fn.tabs = function(){
	return this.each(function(i){
		var tTabs, tNav, tItem, tTab;
		tTabs = $(this);
		tNav = $(this).children('.tabs-nav');
		tItem = $(tNav).children().children('a');
		tTab = $(this).children('.tab');
		
		
		
		$(tItem).each(function(i){
			tAct = 0;
			tLoop = true;
			if($(this).parent().is('.act')){
				tAct = i;
				tLoop = false;
			}
			if(tAct == 0){
				$(tItem).eq(0).parent().addClass('act');
				$(tTab).eq(0).show();
			}
			else{
				$(tTab).hide();
				$(tItem).parent().removeClass('act');
				$(tItem).eq(tAct).parent().addClass('act');
				$(tTab).eq(tAct).show();
			}
			return tLoop;
		});
		
		
		$(tItem).click(function(t){
			t.preventDefault();
			tID = $(this).attr('href');
			tID = tID.split('#')[1];
			$(this).parent().siblings().removeClass('act');
			$(this).parent().addClass('act');
			$(this).parent().parent().siblings('.tab').hide();
			$('#'+tID).show();
		});
		

	}); // each	
};

// this tells jquery to run the function below once the DOM is ready
$(document).ready(function() {

// choose text for the show/hide link
var showText="Zobacz opinie o produktach Monkey's Grip";
var hideText="Schowaj tekst";

// create the toggle link
$("#hide_this").before("<p><a href='#' id='toggle_link'>"+ showText +"</a>");

// hide the content
$('#hide_this').hide();

// capture clicks on the newly created link
$('a#toggle_link').click(function() {

// change the link text
if ($('a#toggle_link').text()==showText) {
$('a#toggle_link').text(hideText);
}
else {
$('a#toggle_link').text(showText);
}

// toggle the display
$('#hide_this').toggle('slow');

// return false so any link destination is not followed
return false;
				});

});


