I noticed exactly the same issue on my Samsung A71 running Android 11 - double and triple clicks on a wired headset don't work as intended when Poweramp is not the front app (even when phone is unlocked)
Other aps like Podcast Addict or Spotify work fine.
Thanks
Bart