Container query stack
Container query stack: a CSS card. Copy the rules, or the prompt that rebuilds it.
Sized by the parent
Resize the wrapper below 400px and this card stacks vertically.
CSS
.card-069-wrap{container-type:inline-size;max-width:100%}
.card-069{display:flex;flex-direction:column;background:#fff;border:1px solid #e5e7eb;border-radius:14px;overflow:hidden;font-family:system-ui,sans-serif;color:#111827}
.card-069__img{height:160px;background:linear-gradient(135deg,#a7f3d0,#0d9488)}
.card-069__body{padding:18px 20px}
.card-069 h3{margin:0 0 6px;font-size:17px}
.card-069 p{margin:0;font-size:14px;line-height:1.5;color:#6b7280}
@container (min-width:400px){
.card-069{flex-direction:row}
.card-069__img{flex:0 0 180px;height:auto}
.card-069 h3{font-size:20px}
}
HTML
<div class="card-069-wrap" style="width:520px">
<article class="card-069">
<div class="card-069__img"></div>
<div class="card-069__body"><h3>Sized by the parent</h3><p>Resize the wrapper below 400px and this card stacks vertically.</p></div>
</article>
</div>Prompt
Build a card that responds to its container, not the viewport. Wrap it in a div with container-type: inline-size. The card is white with a 1px #e5e7eb border and 14px radius, stacked by default (160px image on top with 135deg gradient #a7f3d0 to #0d9488, then a body with 17px title and 14px #6b7280 text). Under @container (min-width: 400px) switch to a row with a fixed 180px image column and bump the title to 20px.