jQuery(document).ready(function(){	jQuery.fn.exists = function(){ return jQuery(this).length > 0; }	jQuery('#scroll_pane_services, #scroll_pane_about').jScrollPane({showArrows:true});	jQuery('.box_content_services').click(function(){		if (jQuery(this).find('.box_details_txt').exists()) {			var box_details_txt = jQuery(this).find('.box_details_txt').html();			jQuery('.page_content').find('.box_content_services .box_c').html(box_details_txt);			jQuery('#scroll_pane_services').jScrollPane({showArrows:true});		}	});	jQuery('.box_content_about').click(function(){		if (jQuery(this).find('.box_details_txt').exists()) {			var box_details_txt = jQuery(this).find('.box_details_txt').html();			jQuery('.page_content').find('.box_content_about .box_c').html(box_details_txt);			jQuery('#scroll_pane_about').jScrollPane({showArrows:true});		}	});	jQuery('.box_content_best').click(function(){		if (jQuery(this).find('.box_image').exists()) {			var image = jQuery(this).find('.box_image').children('img').attr('src');			jQuery('.box_image_best .box_c').css('width', '550px');			jQuery('.box_image_best .box_c').css('height', '310px');			jQuery('.box_image_best .box_c').css('padding', '0');			jQuery('.box_image_best .box_c').css('opacity', '0');			jQuery('.box_image_best .box_c').html('&nbsp;').css({'background':'url('+image+') no-repeat 50% 50%'});			jQuery('.box_image_best .box_c').animate({opacity: 1}, 800);		}		if (jQuery(this).find('.box_details_txt2').exists()) {			var box_details_txt = jQuery(this).find('.box_details_txt2').html();			jQuery('.box_content_best .box_c').html(box_details_txt);		}	});	jQuery('.fb_default').fancybox({		'titleShow'			: false,		'transitionIn'		: 'elastic',		'transitionOut'		: 'elastic',		'overlayOpacity'	: 0.5,		'overlayColor'		: '#000'	});	jQuery('.fb_elastic').fancybox({		'titlePosition'		: 'over',		'transitionIn'		: 'elastic',		'transitionOut'		: 'elastic',		'overlayOpacity'	: 0.5,		'overlayColor'		: '#000'	});	// box hover	jQuery('.box_zoom').hover(function() {		jQuery(this).css({'z-index' : '10'}); /*Add a higher z-index value so this image stays on top*/;		jQuery(this).find('a img').addClass('hover').stop() /* Add class of "hover", then stop animation queue buildup*/			.animate({				marginTop: '-6px', /* The next 4 lines will vertically align this image */				marginLeft: '-6px',				top: '50%',				left: '50%',				width: '80px', /* Set new width */				height: '80px' /* Set new height */			}, 200); /* this value of "200" is the speed of how fast/slow this hover animates */		} , function() {		jQuery(this).css({'z-index' : '0'}); /* Set z-index back to 0 */		jQuery(this).find('a img').removeClass("hover").stop()  /* Remove the "hover" class , then stop animation queue buildup*/			.animate({				marginTop: '0', /* Set alignment back to default */				marginLeft: '0',				top: '0',				left: '0',				width: '70px', /* Set width back to default */				height: '70px' /* Set height back to default */			}, 400);	});	jQuery('.box_zoom2text').hover(function() {		jQuery(this).css({'z-index' : '10'}); /*Add a higher z-index value so this image stays on top*/;		jQuery(this).find('div').hide();		jQuery(this).find('img').addClass('hover').stop() /* Add class of "hover", then stop animation queue buildup*/			.animate({				marginTop: '-6px', /* The next 4 lines will vertically align this image */				marginLeft: '-6px',				top: '50%',				left: '50%',				width: '80px', /* Set new width */				height: '80px' /* Set new height */			}, 200); /* this value of "200" is the speed of how fast/slow this hover animates */		jQuery(this).find('div').fadeIn('slow');		} , function() {		jQuery(this).css({'z-index' : '0'}); /* Set z-index back to 0 */		jQuery(this).find('div').fadeOut("fast");		jQuery(this).find('img').removeClass("hover").stop()  /* Remove the "hover" class , then stop animation queue buildup*/			.animate({				marginTop: '0', /* Set alignment back to default */				marginLeft: '0',				top: '0',				left: '0',				width: '70px', /* Set width back to default */				height: '70px' /* Set height back to default */			}, 400);	});	jQuery('.box_zoom2image').hover(function() {		jQuery(this).css({'z-index' : '10'}); /*Add a higher z-index value so this image stays on top*/;		jQuery(this).find('div').hide();		jQuery(this).find('img').addClass('hover').stop() /* Add class of "hover", then stop animation queue buildup*/			.animate({				marginTop: '-6px', /* The next 4 lines will vertically align this image */				marginLeft: '-6px',				top: '50%',				left: '50%',				width: '80px', /* Set new width */				height: '80px' /* Set new height */			}, 200); /* this value of "200" is the speed of how fast/slow this hover animates */		jQuery(this).find('div').fadeIn('slow');		} , function() {		jQuery(this).css({'z-index' : '0'}); /* Set z-index back to 0 */		jQuery(this).find('div').fadeOut('slow');		jQuery(this).find('img').removeClass('hover').stop()  /* Remove the "hover" class , then stop animation queue buildup*/			.animate({				marginTop: '0', /* Set alignment back to default */				marginLeft: '0',				top: '0',				left: '0',				width: '70px', /* Set width back to default */				height: '70px' /* Set height back to default */			}, 400);	});	jQuery('.box_zoom2txt').hover(function() {		jQuery(this).css({'z-index' : '10'}); /*Add a higher z-index value so this image stays on top*/;		jQuery(this).find('div').hide();		jQuery(this).find('div').fadeIn('slow');		} , function() {		jQuery(this).css({'z-index' : '0'}); /* Set z-index back to 0 */		jQuery(this).find('div').fadeOut('slow');	});});
