I keep losing as soon as I return from collecting the green sphere, nevermind collecting anything else.
I figured it out and it's a pretty tight squeeze but you can manage it. You need to head to top right for the green sphere, stalling as little as possible. Then, if you have the space, drop down to the middle (alternatively, if you don't have the space, you can attempt to jump over the shadow and drop down to the lower level) and head right again for the yellow sphere and drop down as soon as the shadow approach so it doesn't cut through the level and catch you. The head all the way to the left and grab the purple sphere. After that, just get caught and you win.