Get learning lol. I know that there’s some command line program that gives process info on mouse hover and then that can be parsed with awk to get the pid, then pipe that again into kill -kill. Then use xbindkeys or whatever keybindings program to bind that script to a key.
Tbh. For involved stuff like this chatgpt will help you more than stackoverflow.
Thanks!