Get next element's URL in CMS Collection

Hello everybody.
I’m trying to create a blog page where it scrolls to the next blog post automatically. I understand I need to add JS and I have that settled, my problem comes on how to get the URL of a different post without it being the same all along? I don’t know if that makes sense.
So element #1 will scroll down to element #2, #2 to #3 and so on…
I can’t find a solution on how to add a dynamic URL to JS!

Any help appreciated, thank you!!

Here is my public share link: (