Graphitic carbon nitride with different dimensionalities for energy and environmental applications