Can media queries resize based on a div element instead of the screen?
Yes, CSS Container Queries are what you’re looking for. The CSS Containment Module is the specification that details this feature. You can read more about the decade of work, including proposals, proofs-of-concept, discussions and other contributions by the broader web developer community here! For more details on how such a feature might work and be … Read more