Facile synthesis of N-doped carbon dots for direct/indirect detection of heavy metal ions and cell imaging