As you increase the temperature of a liquid, it expands. Its density decreases.
Similarly, if you take a gas, and you increase the pressure, it compresses. Its density increases.
Imagine that you take a container, that contains both liquid and gas. They are both at the same temperature. The pressure of the liquid is slightly higher, because of the force of gravity.
They both co-exist because if some of the gas became liquid, the pressure would decrease; which would cause some of the liquid to evaporate. Similarly if some of the liquid became gas, the pressure would increase, causing some of the gas to condense.
So, they are both co-existing, but they have different densities, and viscosities.
Now, take that container and gradually apply heat. As the liquid heats up, it expands, taking up more space, becoming less dense, and less viscose. As the gas heats up, well, it cant expand, since the liquid is taking up more and more space. So, the density of the gas is increasing, and its viscosity too.
At some point, the density of the gas and the liquid become equal, as are their viscosities. In fact, everything about the gas and the liquid becomes entirely indistinguishable. The boundary between them disappears. The container at this point contains only SCF ("supercritical fluid").