I have made a small web page for my university project. But after some testing i noticed that if there isn't enough content in the <main> section of <body> then <footer> will appear after the end of content despite there being some empty space down bellow. I tried to fix this using css properties bottom: 0; margin-top: auto. But it had no effect at all. After inspecting some popular web sites i discovered that a lot of them definitely used JavaScript to place some sort of adjustable margin if there wasn't enough content. Is it even possible to do that without using JavaScript?