It's perfectly normal for a horse to run around and get their silly's out in that fashion, especially if there is a four wheeler being ridden around and they are not used to it.
As for the dog, is it chasing him, barking at him? Maybe your dog needs manners around the horses, because that is a good reason for a horse to kick at a dog.
Is he all by himself? That could have something to do with his behaviour as well, since horses are herd animals. Even a herd will run around and buck, throwing their heads. Horses like to have fun too.