Envelope of time domain signal // Hilbert transform
Hilbert envelope, also called Energy-Time Curve (ETC), only works well for narrow-band fluctuations. Producing an analytic signal, of which you later take the absolute value, is a linear operation, so it treats all frequencies of your signal equally. If you give it a pure sine wave, it will indeed return to you a straight line. When you give it white noise however, you will likely get noise back.

Example 1:

$$
\lvert\cos(\omega t)\rvert^2 + \lvert i\sin(\omega t)\rvert^2  = \cos^2(\omega t) + \sin^2(\omega t)= 1
$$

Here, you have $\cos(\omega t)$ as you input signal, and its analysis counterpart is $\cos(\omega t) + i\sin(\omega t)$. In it easy to see from expression above that its envelope is always a constant. Let's look at another example.

Example 2:

Let $x(t) = \cos(\omega_1 t) + \cos(\omega_2 t)$. Then its analytic counterpart is
$$
a(t) = \cos(\omega_1 t) + \cos(\omega_2 t) + i\sin(\omega_1 t) + i\sin(\omega_2 t).
$$
Let's take the absolute value of this signal.

$$\begin{align}
\lvert a(t)\rvert^2 &amp;= \lvert\cos(\omega_1 t) + \cos(\omega_2 t)\rvert^2 + \lvert i\sin(\omega_1 t) + i\sin(\omega_2 t)\rvert^2\\&amp;=\left(\cos(\omega_1 t) + \cos(\omega_2 t)\right)^2 + \left( \sin(\omega_1 t) + \sin(\omega_2 t) \right)^2 \\ &amp;= \cos^2(\omega_1t) + \cos(\omega_1t)\cos(\omega_2t) + \cos^2(\omega_2t)\\&amp; \quad + \sin^2(\omega_1t) + \sin(\omega_1t)\sin(\omega_2t) + \sin^2(\omega_2t) \\&amp;= \cos^2(\omega_1t) + \frac{1}{2}\left[ \cos(\omega_1t-\omega_2t)+\cos(\omega_1t+\omega_2t)\right] + \cos^2(\omega_2t)\\&amp;\quad + \sin^2(\omega_1t) + \frac{1}{2}\left[ \sin(\omega_1t-\omega_2t)-\sin(\omega_1t+\omega_2t)\right] + \sin^2(\omega_2t) \\ &amp;= \left[ \cos^2(\omega_1t) + \sin^2(\omega_1t)\right] + \left[ \cos^2(\omega_2t) + \sin^2(\omega_2t)\right] \\ &amp;\quad + \frac{1}{2}\left[\cos(\omega_1t-\omega_2t) + \cos(\omega_1t-\omega_2t) \right] + \frac{1}{2}\left[\sin(\omega_1t+\omega_2t) - \sin(\omega_1t+\omega_2t) \right] \\ &amp;= 1 + 1 + \cos(\omega_1t - \omega_2t) + 0 \\ &amp;= 2+\cos\left( \left[\omega_1-\omega_2\right]t\right)\end{align}$$

As you can see, this is not a constant as one would expect. Note that if $\omega_1$ and $\omega_2$ are close to each other, only low-frequency oscillations are produced as an artifact. hope this helps.