Saw this funny behavior a few days ago, where a button will run away from the cursor if the form is invalid and tried to do something similar with CSS and a little JavaScript.
In this code I use transitions and transforms. I also use the "checkValidity" method to get the validation status with JavaScript.
On this page of the site you can watch the video online Evading button effect with CSS and JavaScript with a duration of hours minute second in good quality, which was uploaded by the user Coder 11 October 2022, share the link with friends and acquaintances, this video has already been watched 544 times on youtube and it was liked by 7 viewers. Enjoy your viewing!