$(document).ready(function(){
                var dHeight = $(document).height();
                var wHeight = $(window).height();
                if (dHeight>(wHeight+300)) {
                $(window).scroll(function(){
                    var tScroll = $(this).scrollTop();
                    var pScroll = (-tScroll/(wHeight-dHeight)*100)+0.0001;
                    $('#about').css({
                        'top':((-$('#about').height()/wHeight*100)-5+pScroll)*1.8+'%',
                        'right':7+pScroll/22+'%',
                        'background-color' : 'rgb(' + Math.round(50+pScroll/2) + ',' + Math.round(170+pScroll*1.5) + ',' + Math.round(150+pScroll*2) + ')'
                    });
                    $('#yvi').css({
                        'top':(-$('#yvi').height()/wHeight*100)-1+pScroll*2.5+'%',
                        'right':4-pScroll/20+'%',
                        'background-color' : 'rgb(' + Math.round(190+pScroll*2.5) + ',' + Math.round(120+pScroll*3) + ',' + Math.round(100+pScroll) + ')'
                    });
                    $('#logo').css({
                        'top':($('#logo').height()/wHeight*100)-1+pScroll/1.37+'%',
                        'background-color' : 'rgb(222,' + Math.round(0+pScroll/8) + ',' + Math.round(100+pScroll*2) + ')'
                    });
                });
                }
                else {
                    
                    $('#logo').css({
                        'top':'29.72%',
                        'right':'8.34%',
                        'background-color' : 'rgb(222,0,100)'
                    });
                    $('#about').css({
                        'top':'20.24%',
                        'right':'8.33%',
                        'background-color' : 'rgb(15,159,209)'
                    });
                    $('#yvi').css({
                        'top':'33.02%',
                        'right':'2.53%',
                        'background-color' : 'rgb(254,168,54)'
                    });
                }
});
