Theres currently a bug going around with the sdl2 library that source 2 uses. There was a recent update to the demo viewer that switches your keyboard layout to a controller one while the demo is trying to play. Try compiling sdl2 from the official repository https://github.com/libsdl-org/SDL...
Try updating to the latest nvidia driver in the beta branch should probably fix the issue, also compiling https://github.com/ValveSoftware/gamescope from the latest branch with -O3 and running that combined with the game should fix the issue, works atleast on my machine running with Artix Linux...
This is a very easy and simple fix.
So first of all I dont know if you are on KDE or on Gnome but it doesnt matter because this fix is universal for wayland and x11.
Before you start you have to check if the Xwayland package has been updated if not you may or may not have to compile the package...
I wrote about this in a different thread since a lot of people seem to have issues with the graphical rendering pipeline integration of the vulkan renderer. So what you have to do is.
Step 1. Downgrade to version 415.68 nvidia drivers, if youre an amd you will need to fetch the latest patches...
Ubuntu 22.01 I had to downgrade my nvidia drivers to 420.26 and then one of gnome's packages had to be recompiled because of a regression https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/5941 I then had to also recompile my linux kernel because the nvidia drivers require a specific nvidia...