About 50 million years ago, dog-like mammals returned to the seas, eventually evolving into whales and dolphins. Around then, too, an early cousin of elephants took the plunge, giving rise to manatees and dugongs.

About 20 million years later, bearlike mammals also waded back into the sea, evolving into seals, sea lions and walruses.

Each of these marine species adapted to the aquatic life in its own way. Manatees and dugongs slowly graze on sea grass. Seals and their relatives dive deep underwater after prey but still haul themselves onto beaches to mate and rear pups.

Whales and dolphins have made the most radical adaptations, including blowholes, baleen and echolocation.

But a new study reveals a common bond: In all three groups of mammals, many species stopped making the same enzyme. Now that loss may come back to haunt them.

The enzyme provides an essential defense against certain kinds of harmful pesticides. The study raises the possibility that marine mammals may be particularly vulnerable to these chemicals, which are carried from farm fields into coastal waters.

“It’s too important not to pay attention to,” said Nathan Clark, a co-author of the study and an evolutionary biologist at the University of Pittsburgh.

Charles Darwin was the first to recognize that marine mammals evolved from ancestors on land. The clues were in their anatomy: Seal flippers are just modified feet. The whale’s blowhole is a nose that has migrated.

More recently, the DNA of marine mammals has revealed more details about their adaptations. Some genes evolved to do new things, but others simply stopped working.

Clark and his colleagues developed a new way to search for these genes and looked for those more likely to be broken in marine mammals than in terrestrial ones. The scientists ended up with a shortlist of genes that were repeatedly shut down in marine mammals.

Most were involved in smelling. But at the top of the list was a gene that had nothing to do with smell, called PON1.

Wynn Meyer, a postdoctoral researcher at the University of Pittsburgh and study co-author, said she was taken aback when she found out what the gene is best known for: a defense against some toxic chemicals.

These chemicals are called organophosphates, a class of compounds that includes certain pesticides as well as nerve agents like sarin gas. PON1 encodes an enzyme called paraoxonase that can break down organophosphates. Mice genetically engineered without paraoxonase die quickly when they are exposed to the chemicals.

The researchers found that marine mammals have broken copies of the PON1 gene, with a few exceptions: walruses, fur seals and spotted seals.

Mammals did not evolve the paraoxonase enzyme to fight the pesticides that humans have invented. After all, the animals have had the adaptation for millions of years.

But paraoxonase breaks down other harmful molecules that our bodies naturally produce. These oxygen-bearing molecules can damage our cells, causing a variety of problems like a buildup of plaque on the walls of blood vessels. People who make low levels of paraoxonase run a greater risk of atherosclerosis and heart disease.

So why did marine mammals lose such an important gene? One possibility is that their bodies abandoned paraoxonase when they started taking long dives. In preparation, the animals suck in tremendous amounts of oxygen, which may create a lot of damaging oxygen-bearing molecules.

Marine mammals may have evolved a more powerful way to defend against oxygen-bearing molecules, making PON1 unnecessary, the researchers speculated.

Some organophosphate pesticides are widely used on farms, despite decades of research indicating that they can cause brain damage in children. In some parts of the world, such as Florida, marine mammals may be exposed to the chemicals on a regular basis.