code for opacity by scrolling