Thank you so much for your quick response and info. I'll check on these diseases.
Yesterday, the vet did x-ray and general blood work but basically he found nothing suspicious. He thinks my dog possibly ate something toxic. He orally gave the dog some liquid (?) charcoal in case it would help to get rid of some of the toxins in his system. But by then, his condition was getting a little bit better anyway, so I'm not sure what helped or caused this problem after all.
Next day (which is today), he is no longer swaying like he did, but he is still very weak. I'm very worried especially because I don't know what the problem is.
I actually filmed a little bit when my dog was swaying his head/body yesterday. Here is the link.