Image copyright Thinkstock

Mercury is the quixotic bad boy of the periodic table - exquisitely beautiful, but deadly. The ancients believed it was the "first matter" from which all other metals were formed. Yet it is now in such disfavour that an international treaty exists to curb its use.

It is easy to see why mercury holds such fascination. It is the only metal to be liquid at room temperature. It is also one of the few things that reacts with that most alluring of all the elements: gold.

The process is extraordinary to see.

In his laboratory at University College London, chemistry professor Andrea Sella peels off a fragile leaf of gold and places it on a shimmering ball of mercury.

Before my eyes the gold gradually vanishes, folding itself around the silver blob like bed sheets, before dissolving away.

Mercury - key facts Image copyright Thinkstock Formerly known as hydrargyrum, from Greek for water and silver

Symbol: Hg

Atomic number: 80

Weight: 200.59

Liquid at room temperature

Used for making industrial chemicals or for electrical and electronic applications

Cinnabar (mercury sulphide) is most common ore

Biggest producers: China and Kyrgyzstan US Geological Survey: Mercury

"Now boil off the mercury", explains Sella, "and you'll be left with a residue of pure gold."

It is mercury's unique relationship with gold that fascinated the alchemists.

But beware...

"Mercury is a profound, systemic and long-term poison for humans, but also for other organisms," says Sella.

"So getting mercury into the environment is a very serious issue."

About half the mercury that enters the environment every year comes from volcanic eruptions and other geological processes. There is nothing we can do about it.

But the other half is released by mankind.

Mercury's bright red ore, cinnabar, has been employed as a pigment since Neolithic times. Some 10,000 years ago, the earliest artists used it to daub pictures of aurochs, the now extinct giant wild cattle they hunted, on the walls of caves in Turkey.

The Romans used it as a form of rouge make-up, and the Chinese to colour their lacquer, while in the Middle Ages the pigment was mixed with wax to provide the seals placed on formal documents.

For centuries the metal was also used in medicine. Even fairly recently it was still used in antiseptics, laxatives, anti-depressants, and drugs to combat syphilis.

Most adults will have used mercury thermometers, and many of us still have mercury amalgam fillings in our teeth.

Some of the mercury in those medicines and tooth fillings will eventually find its way into the atmosphere. Many of us can expect to be cremated, that means any mercury goes up in smoke along with our bodily remains.

And tiny amounts of mercury vapour are the light source in fluorescent bulbs - that's why they need to be disposed of very carefully.

But tooth fillings and smashed bulbs only account for a fraction of the 2,000 tonnes of mercury released by humans into the environment each year.

About a quarter is a by-product of power generation. There are traces of mercury in coal, so coal-fired power stations pump mercury vapour into the atmosphere.

Even more, over a third, is a consequence of our lust for gold.

Worldwide, an estimated 10-15 million small-scale miners dig, dredge, sluice and pan for gold, and many use mercury to separate the pure metal from the silt.

Image copyright AFP Image caption Mercury forms an amalgam with gold - it is then boiled off, leaving pure gold behind

The problem comes when they boil off the mercury to release the pure gold, or when they dump the mercury-contaminated tailings.

In water, micro-organisms transform mercury into a highly toxic organic molecule - methyl mercury - which is readily absorbed into the bodies of algae and plankton.

More from the Magazine Fahrul Raji, a man in his early 30s, is not feeling well. "I often have a headache, and I am weak. I have a bitter taste in my mouth." Mercury is a neuro-toxin, explains Dr Stephan Bose-O'Reilly. "It affects the cerebellum, which is the part of the brain that helps you move properly, and co-ordinate your movements. Mercury also harms the kidneys and other organs, but the neurological damage it does is irreversible." The metal poisoning millions of miners

Those algae and plankton are eaten by larger animals, which are in turn eaten by larger creatures, which in turn are often eaten by us (and seals).

In the process, the toxic chemical becomes increasingly concentrated, posing a particular threat to the developing brains of young and unborn children.

"What we are concerned about is fish at the top of the food chain, fish like swordfish, the predator fish", says Dr Kate Spencer, an environmental geo-chemist.

"By the time you get to the top of the food chain, we are talking thousands of times more mercury in the flesh of our fish."

The world's governments can't agree on much. So it is a measure of the concern about the effects of mercury in the environment that 93 nations, including the United States, have so far signed the Minamata treaty, designed to curtail mercury pollution.

That means installing equipment to collect it from the exhaust fumes of power stations, smelters and cement works.

It means continuing to phase out of the use of mercury in medicines and equipment.

Mercury in fish Image copyright Thinkstock Women who are pregnant or intending to have a baby, and children under 16: Avoid shark, marlin and swordfish

Do not eat more than four medium-sized cans of tuna or two fresh tuna steaks per week Those over the age of 16: Do not eat more than one portion of shark, marlin or swordfish per week But fish is important for a healthy diet and should be eaten twice a week. Oily fish contain nutrients such as Omega 3 that are good for the heart and help the brain development of young and unborn children. UK Food Standards Agency

But most challenging is likely to be breaking the link between mercury and gold. How do you persuade millions of small-scale gold miners to stop using the stuff?

One way is to use a device known as a retort, that collects the mercury vapour as it is boiled off.

It dramatically reduces how much vapour is released into the atmosphere, and means the miners can re-use the mercury, saving them money.

Or you can substitute other things for mercury, says Chris Davis, who co-ordinates a campaign by the Fairtrade Foundation to support small-scale gold miners.

He suggests some pretty unpleasant substances: borax - an aggressive chemical used for industrial cleaning - or, even more hair-raising, cyanide,

Both "become safe with exposure to air after about 24 hours," he says.

Adopting one of these alternatives would require investment. And that makes it a tough sell for people who are so poor that they willingly endanger the health of their families in order to scrape a living from gold.

But let's not forget the good news here - the world has come together to beat its mercury habit.

And if that's possible, then maybe there is still hope we can deal with some of the even bigger environmental challenges we face.

Follow @BBCNewsMagazine on Twitter and on Facebook