$(function(){
	
	$().piroBox_ext({
        piro_speed : 500,
        bg_alpha : 0.5,
        piro_scroll : true //pirobox always positioned at the center of the page
    });
	
	$('.mnu td:first').prepend('<img id="hl" src="i/menu_blik.png">');
	$hl = $('#hl');

	$cur = $('a.active'); off = $cur.offset();
	$hl.css({'left': off.left-(($.browser.msie) ? 120 : 20), 'width': $($cur).parent().width()}).show();




if ($.browser.msie) {

	$('.mnu td a').hover(
		function(){
		off = $(this).offset();
		$hl.css({'left': off.left-120, 'width': $(this).parent().width()}).show()},
		function(){ $hl.hide()}
	);
} else {

	$('.mnu td').hover(
		function(){
		off = $(this).offset();
		$hl.clearQueue().css({ 'left': off.left-20, 'width': $(this).width()}).fadeTo(300, 1)},
		function(){ $hl.fadeTo(100, 0)}

	);
}

if ($.browser.version!='6.0') {
	$('<img class="za tr" src="/i/z_tr.png" alt="" /><img class="za tl" src="/i/z_tl.png" alt="" /><img class="za br" src="/i/z_br.png" alt="" /><img class="za bl" src="/i/z_bl.png" alt="" /><img class="za l" src="/i/z_l.png" alt="" /><img class="za r" src="/i/z_r.png" alt="" /><img class="za br" src="/i/z_br.png" alt="" />').prependTo('.bigFrame');
}
	function imageresize() {
			var contentwidth = $('body').width();
			if ((contentwidth) < '1100'){
			    $('body').addClass('piccolo');
			} else {
			    $('body').removeClass('piccolo');
			}
		}
	
		imageresize();	
	
		$(window).bind("resize", function(){
			imageresize();
		});



});



