Have you ever wondered why veterinarians advertise chocolate as a death threat for your dog? Well, it all has to do with a molecule called theobromine, which is made of up nitrogen, hydrogen, oxygen, and carbon atoms. Theobromine is a type of alkaloid, which is a huge class of molecules that generally contain rings with at least one nitrogen atom. Caffeine is another alkaloid and many alkaloids like these two have physiological effects on humans and animals.
The right amount of theobromine can make our hearts pump faster, dilate our blood vessels, and give us energy, all of which we as humans tend to see as good physiological reactions - up to a point. But too much theobromine (after, say, downing a king-size chocolate bar) can make us feel sick with nausea, make our hearts pump too quickly and our muscles contract uncontrollably. This, as it sounds, can be dangerous.
But luckily for us humans, we process theobromine rather quickly and rarely does too much chocolate in one sitting cause any real health threat. An average adult human would need to eat about 8 kg of dark chocolate for theobromine to be lethal. Dogs, on the other hand, process theobromine much more slowly and the alkaloid can build up in their systems and cause all those scary symptoms. That, combined with the fact that dogs are smaller and lighter, means that a medium-sized dog would only have to eat about 1 kg of dark chocolate for the theobromine to be very dangerous for the animal.