set footer to bottom of page by flex code example
Example: position footer to stay at bottom of screen flexbox
/* Use flex and set auto margin */
body {
display: flex;
flex-direction: column;
min-height: 100vh;
}
footer {
margin-top: auto;
}