function resetBG(){
$('.single_post_textsize_wrap .small').css('background-position','0px -20px');
$('.single_post_textsize_wrap .medium').css('background-position','-20px -20px');
$('.single_post_textsize_wrap .large').css('background-position','-40px -20px');
}


$(document).ready(function(){
		$('#topnav ul.sf-menu').superfish({ 

            delay:       1000,                            // one second delay on mouseout 

            animation:                                    // fade-in and slide-down animation
						{
            				opacity:'show',
							height:'show'
						},   

            speed:       'normal',                          // faster animation speed 

            autoArrows:  false,                           // disable generation of arrow mark-up 

            dropShadows: false,                            // disable drop shadows
            
            pathClass: 'current'                            //

	}); 
   

   
  $(".clickplace").click(function(){
        window.location = $(this).find("a:first").attr("href");
  });
  $(".clickplace_blank").click(function(){
        window.open($(this).find("a:first").attr("href"),'_blank');
  });
  
  $(".clickplace_comment").click(function(){
        window.location = $(this).find("a:first").attr("href")+"#comments";
  });
  
  $('.maindiv').hover(function(){
        $('.my_animated_image_bot').stop().animate({top: '-1'},'slow');
    },function(){
        $('.my_animated_image_bot').stop().animate({top: '-142'},'slow');
    });    
    
    jQuery('.mb_button_amazon').hover(function(){
    jQuery(this).css('background','url(/wp-content/themes/wp-genius-prem-new/images/contents/amazon-btt-long-onclick.jpg) no-repeat');
    },function(){
        jQuery(this).css('background','url(/wp-content/themes/wp-genius-prem-new/images/contents/amazon-btt-long.jpg) no-repeat');
    });
    
    jQuery('.mb_button_o2').hover(function(){
        jQuery(this).css('background','url(/wp-content/themes/wp-genius-prem-new/images/button-mh-nokia-onmouseover2.jpg) no-repeat');
    },function(){
        jQuery(this).css('background','url(/wp-content/themes/wp-genius-prem-new/images/button-mh-nokia2.jpg) no-repeat');
    });
    
    $('#order_bei_hersteller').click(function(){
        $('#div_all').html('<div style="text-align:center;margin-top:20px"><h5>Laden...</h5><img src="/wp-content/themes/wp-genius-prem-new/images/ajax-loader-bar.gif" /></div>');
        $('#div_all').load('/wp-content/themes/wp-genius-prem-new/js/ajax/div_all.php',{order:'hersteller'},function(){
        $('#order_bei_hersteller').addClass('select_o');
        $('#order_bei_name').removeClass('select_o');
        $('#order_bei_bewertung').removeClass('select_o');        
        } );
        
    });
    
    $('#order_bei_name').click(function(){
        $('#div_all').html('<div style="text-align:center;margin-top:20px"><h5>Laden...</h5><img src="/wp-content/themes/wp-genius-prem-new/images/ajax-loader-bar.gif" /></div>');
        $('#div_all').load('/wp-content/themes/wp-genius-prem-new/js/ajax/div_all.php',function(){
        $('#order_bei_name').addClass('select_o');
        $('#order_bei_hersteller').removeClass('select_o');
        $('#order_bei_bewertung').removeClass('select_o');
        });
        
    });
    
    $('#order_bei_bewertung').click(function(){
        $('#div_all').html('<div style="text-align:center;margin-top:20px"><h5>Laden...</h5><img src="/wp-content/themes/wp-genius-prem-new/images/ajax-loader-bar.gif" /></div>');
        $('#div_all').load('/wp-content/themes/wp-genius-prem-new/js/ajax/div_all.php',{order:'bewertung'},function(){
        $('#order_bei_bewertung').addClass('select_o');
        $('#order_bei_name').removeClass('select_o');
        $('#order_bei_hersteller').removeClass('select_o');
        });
        
    });
    
    $('#order_bei_hersteller_t').click(function(){
        $('#div_all').html('<div style="text-align:center;margin-top:20px"><h5>Laden...</h5><img src="/wp-content/themes/wp-genius-prem-new/images/ajax-loader-bar.gif" /></div>');
        $('#div_all').load('/wp-content/themes/wp-genius-prem-new/js/ajax/div_all_tablets.php',{order:'hersteller'},function(){
        $('#order_bei_hersteller_t').addClass('select_o');
        $('#order_bei_name_t').removeClass('select_o');
        $('#order_bei_bewertung_t').removeClass('select_o');        
        } );
        
    });
    
    $('#order_bei_name_t').click(function(){
        $('#div_all').html('<div style="text-align:center;margin-top:20px"><h5>Laden...</h5><img src="/wp-content/themes/wp-genius-prem-new/images/ajax-loader-bar.gif" /></div>');
        $('#div_all').load('/wp-content/themes/wp-genius-prem-new/js/ajax/div_all_tablets.php',function(){
        $('#order_bei_name_t').addClass('select_o');
        $('#order_bei_hersteller_t').removeClass('select_o');
        $('#order_bei_bewertung_t').removeClass('select_o');
        });
        
    });
    
    $('#order_bei_bewertung_t').click(function(){
        $('#div_all').html('<div style="text-align:center;margin-top:20px"><h5>Laden...</h5><img src="/wp-content/themes/wp-genius-prem-new/images/ajax-loader-bar.gif" /></div>');
        $('#div_all').load('/wp-content/themes/wp-genius-prem-new/js/ajax/div_all_tablets.php',{order:'bewertung'},function(){
        $('#order_bei_bewertung_t').addClass('select_o');
        $('#order_bei_name_t').removeClass('select_o');
        $('#order_bei_hersteller_t').removeClass('select_o');
        });
        
    });
    
    
    $('#order_bei_hersteller_e').click(function(){
        $('#div_all').html('<div style="text-align:center;margin-top:20px"><h5>Laden...</h5><img src="/wp-content/themes/wp-genius-prem-new/images/ajax-loader-bar.gif" /></div>');
        $('#div_all').load('/wp-content/themes/wp-genius-prem-new/js/ajax/div_all_ebooks.php',{order:'hersteller'},function(){
        $('#order_bei_hersteller_e').addClass('select_o');
        $('#order_bei_name_e').removeClass('select_o');
        $('#order_bei_bewertung_e').removeClass('select_o');        
        } );
        
    });
    
    $('#order_bei_name_e').click(function(){
        $('#div_all').html('<div style="text-align:center;margin-top:20px"><h5>Laden...</h5><img src="/wp-content/themes/wp-genius-prem-new/images/ajax-loader-bar.gif" /></div>');
        $('#div_all').load('/wp-content/themes/wp-genius-prem-new/js/ajax/div_all_ebooks.php',function(){
        $('#order_bei_name_e').addClass('select_o');
        $('#order_bei_hersteller_e').removeClass('select_o');
        $('#order_bei_bewertung_e').removeClass('select_o');
        });
        
    });
    
    $('#order_bei_bewertung_e').click(function(){
        $('#div_all').html('<div style="text-align:center;margin-top:20px"><h5>Laden...</h5><img src="/wp-content/themes/wp-genius-prem-new/images/ajax-loader-bar.gif" /></div>');
        $('#div_all').load('/wp-content/themes/wp-genius-prem-new/js/ajax/div_all_ebooks.php',{order:'bewertung'},function(){
        $('#order_bei_bewertung_e').addClass('select_o');
        $('#order_bei_name_e').removeClass('select_o');
        $('#order_bei_hersteller_e').removeClass('select_o');
        });
        
    });
    
	$('.mb_longbtt_amazon').hover(function(){
        $(this).css('background','url(http://www.mobilehighlights.de/wp-content/themes/wp-genius-prem-new/images/amazon-btt-on-mouseover.png) no-repeat');
    },function(){
        $(this).css('background','url(http://www.mobilehighlights.de/wp-content/themes/wp-genius-prem-new/images/amazon-btt.png) no-repeat');
    });
    
    $('.email_field').attr('value','Ihre Email');
	$('.email_field').click(function(){
	   $(this).attr('value','');
	});

  

  $("img.apps_img")
        .mouseover(function() { 
            var src = $(this).attr("src").match(/[^\.]+/) + "-hover.jpg";
            $(this).attr("src", src);
        })
        .mouseout(function() {
            var src = $(this).attr("src").replace("-hover", "");
            $(this).attr("src", src);
        });
  /****************** NEUE SINGLE   **********************/
    var texti = '';
    texti = texti + '<div class="single_post_textsize_wrap" style="display:block;">';
    texti =  texti +    '<div class="inner_wrap">';
    texti =   texti +       '<div class="title">Textgr&ouml;&szlig;e </div>  ';
    texti =  texti +        '<div class="small">&nbsp;</div>  ';
    texti =   texti +       '<div class="medium">&nbsp;</div>  ';
    texti =   texti +       '<div class="large">&nbsp;</div>  ';
    texti =  texti +    '</div>';
    texti =    texti +  '<div class="clearer">&nbsp;</div>    ';
    texti = texti + '</div>                       ';

    $('.new_single_content div.wp-caption').after(texti);





        $('.inner_wrap .large').click(function(){
        resetBG();
        $('.new_single_content').css('font-size','15px');
        $('.new_single_content').css('line-height','20px');        
        $('.new_single_content h4').css('font-size','16px');
        $('.new_single_content h4').css('line-height','20px');        
        $(this).css('background-position', '-40px 0px');
    });

    $('.inner_wrap .medium').click(function(){
        resetBG();
        $('.new_single_content').css('font-size','14px');
        $('.new_single_content').css('line-height','20px');           
        $('.new_single_content h4').css('font-size','15px');
        $('.new_single_content h4').css('line-height','20px');        
        $(this).css('background-position', '-20px 0px');
    });

    $('.inner_wrap .small').click(function(){
        resetBG();
        $('.new_single_content').css('font-size','12px');
        $('.new_single_content').css('line-height','18px');           
        $('.new_single_content h4').css('font-size','13px');
        $('.new_single_content h4').css('line-height','18px');
        $('.new_single_content h4').css('letter-spacing','0.01em');
        $(this).css('background-position', '-0px 0px');        
    });

  });


                             
