Relativistic harmonic content of nonlinear electromagnetic waves in underdense plasmas