CSS has just added an image form of light-dark(). So as well as choosing between a pair of colors based on light or dark mode, you can also choose between a pair of images.
No you can't mix them because parsing would be hard.
#CSS

https://www.w3.org/TR/css-color-5/#light-dark

CSS Color Module Level 5

@svgeesus Great to see more progress on this feature.

Does this only include `url()` images or could we use gradients? I don't have a use-case in mind, but I could imagine a two-stop gradient in light mode, and three-stop gradient in dark mode, for example, where inlining `light-dark()` for each colour stop wouldn't work.

@chriskirknielsen Any <image>.

The corresponding edit to CSS Images 4 has not yet been made, but will be soon.

@svgeesus Neat! Thanks for the clarification.
CSS Images Module Level 4