Today I learned about the :has selector. This is helping me keep times aligned on my index page when some posts have titles and some do not. Posts without titles get margin-top: var(--size-step-4) for the time stamps. But using this handy selector, I can set the margin to the next size of H1 elements when there’s a title:

1
2
3
.date:has(+ .post-title) {
  margin-top: var(--size-step-4);
}