<div class="post">
<h2>Title</h2>
</div>
.post {
container-type: inline-size;
}
@container (min-width: 480px) {
.post h2 {
font-size: 3em;
}
}
This Pen doesn't use any external CSS resources.
This Pen doesn't use any external JavaScript resources.