It is shown that when relativistically intense ultrashort laser pulses are reflected from the boundary of a plasma with a near-critical density, Doppler frequency shift leads to generation of intense radiation both in the high-frequency, up to the X-ray, range, and in the low-frequency, mid-infrared, range. The efficiency of energy conversion into the wavelength range of greater than 3 µm can reach several percent, which makes it possible to obtain relativistically intense pulses in the mid-infrared range. These pulses are synchronized with high harmonics in the ultraviolet and X-ray ranges, which opens up opportunities for high-precision pump-probe measurements, in particular, laser-induced electron diffraction and transient absorption spectroscopy.