Today I Learned
CSS :has() selector is a game changer
The :has() pseudo-class lets you select a parent element based on its children. For example, div:has(img) selects all divs containing an image. This was previously impossible in pure CSS and required JavaScript. Browser support is now excellent.
View source