{
  "id": "flexbox-sticky-footer",
  "name": "Flexbox Sticky Footer",
  "category": "layouts",
  "tags": [
    "footer",
    "margin-top auto",
    "flex column",
    "full height",
    "page"
  ],
  "description": "Keeps the footer at the bottom of short pages with a flex column and margin-top: auto on the footer.",
  "url": "https://copy-css.com/snippets/flexbox-sticky-footer",
  "markdown": "https://copy-css.com/snippets/flexbox-sticky-footer.md",
  "html": "<div class=\"flex-page\">\n  <header>Header</header>\n  <main>Short content</main>\n  <footer>Footer</footer>\n</div>",
  "css": ".flex-page {\n  display: flex;\n  flex-direction: column;\n  min-height: 100vh;\n  min-height: 100dvh;\n}\n\n/* Pushes the footer down, however many elements come before it */\n.flex-page > footer {\n  margin-top: auto;\n}",
  "features": [
    "Flexbox"
  ],
  "customProperties": []
}
