Near-edge X-ray absorption fine structure study of carbon nitride films