I'm getting essentially the same error as in this question except when I try to do the proposed solution, at this step:
grub-install --target=x86_64-efi /dev/nvme0n1
I get this error:
grub-install: error: cannot find EFI directory.
This is a clean install using an ASRock motherboard with the Z170 chipset, in case that's relevant.