Longtime lurker, first time poster. I'm just so chuffed that this worked I wanted to share it with y'all.
I made the mistake of buying an M1 iMac without researching whether it would support Target Display Mode and of course it does not. I spent an hour on the phone with three different Apple...