Selective recognition of metal ions by metalloregulatory proteins