It’s easy to create the aggregate input device, go to the Audio MIDI Setup app, in the audio window click the plus in the bottom right and choose “new aggregate device”, then tick MacBook Microphone on the right. Then to System Preferences > Sound > Input and assign this new “virtual” device as your input device. (You can rename it if you want)
Now your Mac will automatically switch audio output source as usual, but the input remains locked to the microphone so you don’t get this annoying problem.
This is configured from 'Audio MIDI Setup.app'
Apps configured to use that as their input device then don't reconfigure themselves whenever a Bluetooth input device shows up.
I dont add output devices as I'm happy for that to flip between speakers/headphones - whatever is available.
Also I haven't upgraded macOS to >= 13 yet on my personal laptop, so I can't use any of these apps.