プレビュー
HTML
<article>
<header>Top</header>
<p>Flexible middle.</p>
<footer>Bottom</footer>
</article>
CSS
:root {
--ink: #241c16;
--paper: #fffaf1;
--accent: #d4552b;
--accent-2: #4338ca;
--on-accent: #fff;
--muted: #6a6156;
--line: #d7ccb8;
--chip: #efe6d6;
}
article {
display: flex;
flex-direction: column;
min-height: 14rem;
border-radius: 1rem;
overflow: hidden;
background: var(--paper);
}
header,
footer,
p {
margin: 0;
padding: 0.8rem 1rem;
}
header,
footer {
background: var(--chip);
font-weight: 700;
}
p {
flex: 1;
}
Tailwind
<style>
:root {
--ink: #241c16;
--paper: #fffaf1;
--accent: #d4552b;
--accent-2: #4338ca;
--on-accent: #fff;
--muted: #6a6156;
--line: #d7ccb8;
--chip: #efe6d6;
}
</style>
<article class="flex flex-col min-h-[14rem] rounded-[1rem] overflow-hidden bg-[var(--paper)]">
<header class="m-0 p-[0.8rem_1rem] bg-[var(--chip)] font-bold">Top</header>
<p class="m-0 p-[0.8rem_1rem] [flex:1]">Flexible middle.</p>
<footer class="m-0 p-[0.8rem_1rem] bg-[var(--chip)] font-bold">Bottom</footer>
</article>