Today I Learnt

Build a system that can install GRUB2 on UEFI and on legacy systems

grub-efi-amd64 and grub-pc are not coinstallable. It turns out however that
they do not contain GRUB, but the machinery to keep GRUB configuration up to
date on the current system. If I want to be able to install GRUB on other
systems, I can use the -bin packages:

apt install grub-common grub2-common grub-efi-amd64-bin grub-pc-bin

That gave me a grub-install command that worked on both kinds of systems.

GRUB configuration on a UEFI system

An old GRUB configuration on a UEFI system gave me this:

error:nosuitablemodefoundBootingblind

which boots on a blank screen until the kernel reinitialises the video
hardware.

The Arch Linux Wiki
has excellent documentation for this case, and here's the resulting UEFI GRUB
snippet: