The best way around that for myself would be to incorporate the register process within the purchase of the product so that they are already registered before they get to the download option.
So, you could leave it as it is for now with all your coding for the Paypal payment and once this is all complete, then have the customer have to enter their details for registration.
You can still have the automatic email sent out to acknowledge the Paypal payment and on which you can add a seperate part saying something like thank you for purchasing etc, etc… Now you have registered with us, please visit our download area and use your details to login… I am sure you can word it much better!
Then when the customer goes to the download area, have everything hidden apart from whatever you want to show to everybody, like login button, company logo etc.
So when the customer clicks on login button, the custom login lightbox appears and the customer logs themselves in using their details and after clicking on the login button, the login lightbox closes itself and the download area page is refreshed so that the code on the page starts and the customer is logged in with the login button changing to say logout and all your hidden download items are now visible.
You could always go down another long winded and more secure route which creates a random number ( https://webiya.wixsite.com/rnd-number-example ) that the customer clicks to generate and then inputs that into their Paypal purchase somewhere.
So the random number they generated would then be stored in a custom field in your dataset, so this random number would always be unique to their account, like the owner field in the dataset.
https://support.wix.com/en/article/about-your-database-collection-fields#system-fields
Then when they login in you could direct them to another lightbox or another page where you can get them to retype in this unique number and then query this number with the number in your customer dataset and if it matches then they are given access to the downloads area. If the numbers don’t match then they can be redirected to any page that you wish or simply have a error message come up on screen.
i would still have everything hidden on your download area regardless of which option you use, so that the only way it shows up is by having the user log themselves in using the details they entered at registration.