this same thing just happened to me...
I didn't know iCloud was copying files sent to my desktop and I just added A TON of them because I have a new MacBook and couldn't 'migrate' my old one over cause it locked me out, SO I was loading tons of old photos and videos from old USB drives, SO I finally find them on the iCloud site and delete them, having ZERO CLUE it would also physically delete them via internet from MY machine on my lap...yeah I'm about to just get ride of iCloud altogether over this stupidity. I also found the way to turn off copying to the desktop/cloud automatically but clearly a little too late, how f'ing annoying. 3 days worth of work gone haha, thanks Apple.
MacBook Air, macOS 15.2