
$(function() {
		   				
	
                $('.g1').hover(
                function () {
					$('#gas_pic_01').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				},
				
                function () {
					$('#gas_pic_01').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
                }
            					);
				
				
				 $('.g1').hover(
                function () {
					$('#gas_pic_01 .descriprion').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				
				},
				
                function () {
					$('#gas_pic_01 .descriprion').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
			
                }
            					);
				
				
				  $('.g2').hover(
                function () {
					$('#gas_pic_02').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				},
				
                function () {
					$('#gas_pic_02').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
                }
            					);
				  
				 $('.g2').hover(
                function () {
					$('#gas_pic_02 .descriprion').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				},
				
                function () {
					$('#gas_pic_02 .descriprion').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
                }
            					);
				 
				  
				  
				  $('.g3').hover(
                function () {
					$('#gas_pic_03').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				},
				
                function () {
					$('#gas_pic_03').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
                }
            					);
				  
				  $('.g3').hover(
                function () {
					$('#gas_pic_03 .descriprion').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				},
				
                function () {
					$('#gas_pic_03 .descriprion').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
                }
            					);
				  
				  
				  $('.g4').hover(
                function () {
					$('#gas_pic_04').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				},
				
                function () {
					$('#gas_pic_04').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
                }
            					);
				  
				  $('.g4').hover(
                function () {
					$('#gas_pic_04 .descriprion').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				},
				
                function () {
					$('#gas_pic_04 .descriprion').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
                }
            					);
				  
				  
				   $('.g5').hover(
                function () {
					$('#gas_pic_05').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				},
				
                function () {
					$('#gas_pic_05').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
                }
            					);
				  
				  $('.g5').hover(
                function () {
					$('#gas_pic_05 .descriprion').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				},
				
                function () {
					$('#gas_pic_05 .descriprion').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
                }
            					);
				  
				  
				  
				  
				   $('.r1').hover(
                function () {
					$('#ref_pic_01').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				},
				
                function () {
					$('#ref_pic_01').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
                }
            					);
				   
				   $('.r1').hover(
                function () {
					$('#ref_pic_01 .descriprion').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				
				},
				
                function () {
					$('#ref_pic_01 .descriprion').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
			
                }
            					);
				
				
				  $('.r2').hover(
                function () {
					$('#ref_pic_02').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				},
				
                function () {
					$('#ref_pic_02').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
                }
            					);
				  
				  $('.r2').hover(
                function () {
					$('#ref_pic_02 .descriprion').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				
				},
				
                function () {
					$('#ref_pic_02 .descriprion').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
			
                }
            					);
				  
				  
				  $('.r3').hover(
                function () {
					$('#ref_pic_03').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				},
				
                function () {
					$('#ref_pic_03').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
                }
            					);
				  
				  $('.r3').hover(
                function () {
					$('#ref_pic_03 .descriprion').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				
				},
				
                function () {
					$('#ref_pic_03 .descriprion').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
			
                }
            					);
				  
				  
				  $('.r4').hover(
                function () {
					$('#ref_pic_04').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				},
				
                function () {
					$('#ref_pic_04').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
                }
            					);
				  
				  $('.r4').hover(
                function () {
					$('#ref_pic_04 .descriprion').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				
				},
				
                function () {
					$('#ref_pic_04 .descriprion').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
			
                }
            					);
				  
				  $('.s1').hover(
                function () {
					$('#sma_pic_01').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
					
				},
				
                function () {
					$('#sma_pic_01').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
                }
            					);
				  
				  $('.s1').hover(
                function () {
					$('#sma_pic_01 .descriprion').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				
				},
				
                function () {
					$('#sma_pic_01 .descriprion').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
			
                }
            					);
				
				
				  $('.s2').hover(
                function () {
					$('#sma_pic_02').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				},
				
                function () {
					$('#sma_pic_02').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
                }
            					);
				  
				  $('.s2').hover(
                function () {
					$('#sma_pic_02 .descriprion').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				
				},
				
                function () {
					$('#sma_pic_02 .descriprion').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
			
                }
            					);
				  
				  
				  $('.s3').hover(
                function () {
					$('#sma_pic_03').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				},
				
                function () {
					$('#sma_pic_03').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
                }
            					);
				  
				  $('.s3').hover(
                function () {
					$('#sma_pic_03 .descriprion').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				
				},
				
                function () {
					$('#sma_pic_03 .descriprion').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
			
                }
            					);
				  
				  
				  $('.s4').hover(
                function () {
					$('#sma_pic_04').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
					
				},
				
                function () {
					$('#sma_pic_04').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
                }
            					);
				  
				  $('.s4').hover(
                function () {
					$('#sma_pic_04 .descriprion').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				
				},
				
                function () {
					$('#sma_pic_04 .descriprion').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
			
                }
            					);
				  
				  
				   $('.s5').hover(
                function () {
					$('#sma_pic_05').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
					
				},
				
                function () {
					$('#sma_pic_05').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
                                       
                }
            					);
				  
				  $('.s5').hover(
                function () {
					$('#sma_pic_05 .descriprion').stop().animate({'opacity':'1'});
                                        $('div.slogan').css({'zIndex': '0'});
				
				},
				
                function () {
					$('#sma_pic_05 .descriprion').stop().animate({'opacity':'0'});
                                        $('div.slogan').css({'zIndex': '99999'});
			
                }
            					);
				  
				  
				  
				  
				   
				
});





function setPicNum(height){
if (height<850)  
    { if (height<600) {height=600}
	var resize=850;
	
	var sma_pic_h=resize/281;
	var sma_pic_w=resize/171;
	var refreg_pic_h=resize/568;
	var refreg_pic_w=resize/258;
	var gasstove_pic_h=resize/307;
	var gass=resize/169;
	var gas_info_height=resize/570;
	
	var products_cont=resize/558;
	var products_cont_t=resize/-14;
	
	var refrig_cont=resize/570;
	var refrig_content_w=resize/380;
	var sma_cont=resize/570;
	var sma_info_height=resize/570;
	var gas_stove_con=resize/570;
	
	var flash_resize=resize/800;
	var flash_top=resize;
	
	var footer_top_h=resize/80;
	
	var refr_inf=resize/253;
	var refr_info_height=resize/570;
	
	var sma_pic_t=resize/-20;
	
	
	var sma_pic_height=height/sma_pic_h+'px';
	var sma_pic_width=height/sma_pic_w+'px';
	var sma_content=height/sma_cont+'px';
	var sma_info=height*0.205+'px';
	var sma_info_h=height/sma_info_height+'px';
	
	var refreg_pic_height=height/refreg_pic_h+'px';
	var refreg_pic_width=height/refreg_pic_w+'px';
	var refrig_content=height/refrig_cont+'px';
	var refrig_content_width=height/refrig_content_w+'px';
	
	
	
	var refr_info=height/refr_inf+'px';
	var refr_info_h=height/refr_info_height+'px';
	
	var gasstove_pic_height=height/gasstove_pic_h+'px';
	var gas=height/gass+'px';
	var gas_stove_cont=height/gas_stove_con+'px';
	var gas_info=height*0.198+'px';
	var gas_info_h=height/gas_info_height+'px';
	
	var gas_pic_01=-30+height*0.12+'px';
	var gas_pic_02=-30+height*0.12+'px';
	var gas_pic_03=-30+height*0.12+'px';
	var gas_pic_04=-30+height*0.12+'px';
	var gas_pic_05=-30+height*0.12+'px';
	
	var sma_pic_01=-40+height*0.12+'px';
	var sma_pic_02=-40+height*0.12+'px';
	var sma_pic_03=-40+height*0.12+'px';
	var sma_pic_04=-40+height*0.12+'px';
	var sma_pic_05=-40+height*0.12+'px';
	
	var ref_pic_01=65+height*0.122+'px';
	var ref_pic_02=65+height*0.122+'px';
	var ref_pic_03=65+height*0.122+'px';
	var ref_pic_04=65+height*0.122+'px';
	var ref_pic_05=65+height*0.122+'px';
	
	
	
	var footer_height=height/footer_top_h+'px';
	var footer_top=414*(height/580)+'px';
	
	
	var flash=height/flash_resize+'px';
	var flash_top=height*0.01+'px';
	var flashimg=height*0.02+'px';
	
	var products_cont_h=height/products_cont+'px';
	var products_cont_top=height/products_cont_t+'px';
	
	var sma_pic_top=height/sma_pic_t+'px';
	
	
	$('.footer_top').css('height',footer_height);
	$('.footer_top').css('top',footer_top);
		$('.flash_bg object').css('height',flash);	
		$('.flash_bg img').css('margin-top',flashimg);	
		$('.flash_bg img').css('height',flash);

	$('.flash_bg').css('top',flash_top);	
	
	$('.sma_pic').css('height',sma_pic_height);
	$('.sma_pic').css('width',sma_pic_width);
	$('.sma_content').css('height',sma_content);
	$('.sma_info').css('width',sma_info);	
	$('.sma_info').css('height',sma_info_h);
	
	$('img.refreg_pic').css('height',refreg_pic_height);
	$('img.refreg_pic').css('width',refreg_pic_width);
	$('.refrig_content').css('height',refrig_content);
	//$('.refrig_content').css('width',refrig_content_width);
	$('.refr_info').css('width',refr_info);
	$('.refr_info').css('height',refr_info_h);
	
	$('img.gasstove_pic').css('height',gasstove_pic_height);	
	$('img.gasstove_pic').css('width',gas);	
	$('#gas-stove_content').css('height',gas_stove_cont);
	$('.gas_info').css('width',gas_info);
	$('.gas_info').css('height',gas_info_h);
	
	$('#gas_pic_01').css('left',gas_pic_01);
	$('#gas_pic_02').css('left',gas_pic_02);
	$('#gas_pic_03').css('left',gas_pic_03);
	$('#gas_pic_04').css('left',gas_pic_04);
	$('#gas_pic_05').css('left',gas_pic_05);
	
	$('#sma_pic_01').css('right',sma_pic_01);
	$('#sma_pic_02').css('right',sma_pic_02);
	$('#sma_pic_03').css('right',sma_pic_03);
	$('#sma_pic_04').css('right',sma_pic_04);
	$('#sma_pic_05').css('right',sma_pic_05);
	
	$('#ref_pic_01').css('right',ref_pic_01);
	$('#ref_pic_02').css('right',ref_pic_02);
	$('#ref_pic_03').css('right',ref_pic_03);
	$('#ref_pic_04').css('right',ref_pic_04);
	$('#ref_pic_05').css('right',ref_pic_05);
	
	
	
	
	$('#products_content').css('height',products_cont_h);
	$('#products_content').css('top',products_cont_top);
	
	}    
    
   
	
}

	

 function OnWindowResize() {
		                 
	                        var myWidth = 0, myHeight = 0;
	  
          if( typeof( window.innerWidth ) == 'number' )
		  {
		  //Non-IE
		  myWidth = window.innerWidth;
		  myHeight = window.innerHeight;
	      } else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) )
		  {
		  //IE 6+ in 'standards compliant mode'
		  myWidth = document.documentElement.clientWidth;
		  myHeight = document.documentElement.clientHeight;
	      } else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) 
		  {		  
		   //IE 4 compatible
		   myWidth = document.body.clientWidth;
		   myHeight = document.body.clientHeight;
	      }
	        	
		     setPicNum(myHeight);	
}
OnWindowResize();
window.onresize = OnWindowResize; 

