I feel that tabbing to the wrong instance of an app is a problem that can be solved on the software level. It’s a nightmare on the default macOS app switcher. I use an app called Contexts as a solution and it works reasonably well. There seems to be some free and open source solutions as well.