High-frequency dynamics of liquid and supercritical nitrogen