		$(document).ready(function(){
			//toogle box in sidebar
			$('.box h3').css("cursor","pointer").click(function() {
				$(this).parent().children('.content').slideToggle("slow");
			});
			

			//cicle plugin in "our team". This "if" is to avoid an ie6 error
			if(document.getElementById('ourTeam')) {
				$('#ourTeam').cycle({ 
					speed:   500, 
					timeout: 0, 
					next:   '#slideControl .controlNext', 
					prev:   '#slideControl .controlPrev' 
				});
			}
			
			//photos from where we work
			$('#slidePager a').click(function() {
				  var largePath = $(this).attr("href");
				  var largeAlt = $(this).attr("title");
				  $('#slidePager a').removeClass('activeSlide');
				  $(this).addClass('activeSlide');
				  $("#photosWorkplace img").attr({ src: largePath, alt: largeAlt });
				  return false;
			});
			
			//sidebar and main with equal height
			var mainHeight = $('#main').height();
			var sidebarHeight = $('#sidebar').height();
			
			if(mainHeight > sidebarHeight) {
				$('#sidebar').height(mainHeight);
			} else {
				$('#main').height(sidebarHeight);
			}
			
			//ajax contact form
			$("#contactForm").submit(function(){
                $('#result').empty();
                $('#result').append('<img src="images/ajax-loader.gif" alt="Loading" id="loading" class="no-border"/>');
				$.post($(this).attr("action"), $(this).serialize(), AjaxFormReturn)
				return false
			})
 
			AjaxFormReturn = function(responseHtml)
			{
				$('#loading').fadeOut(500, function() {
					$('#result').empty();
					$('#result').append(responseHtml).fadeIn(500);
				})
			}
			
			//slide from homepage
			$('#slider').s3Slider({
				timeOut: 4000
			});

		});
		//cufon
		Cufon.replace('h2');