Stack Exchange network consists of 177 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
Trick circumvents [position: sticky] restriction to parent
My question was put on hold. Please vote to reopen it.
it seems that the issue is that you needed to have content in the HTML enough to make it scroll before the button.
I have added a stack snippet example that works for me and reopened the question.