It doesn't matter much what Linux you use. Rather what is your desktop environment? (KDE Plasma, Gnome, sway etc.)
On KDE for example there is a shortcut to restart the compositor, which might fix your issue.
But in general you might have luck "restarting" it by switching the tty. You do that by pressing CTRL + ALT + some function key between F1 and F8 (the standard gui tty number depends on the distro). Try to switch to a non gui tty and then back.
+1 to ctrl-alt-fsomething (start at f1 and go up to move through the different virtual terminals). once in a while there are graphics problems which this will fix.
If you're using GNOME Shell on X you can reload the shell (and all of its extensions) with alt-f2 and then in the "Run a command" dialog that appears type r and hit enter. Unfortunately this doesn't work in GNOME on Wayland.
If the kernel runs into a oops it can recover and you won't notice anything except a nasty looking error in dmesg. If it runs into a panic you need to hard reboot the system as it can't continue to run.