When the wax (solid state) is subjected to heating, the molecules absorb the heat energy provided, which increases the kinetic energy of the molcules. This results in increase of temperature.
ii) When wax reaches its melting point, Further supply of heat energy does not raise the kinetic energy anymore. Instead, the heat energy in converted to potential energy and stored. With increase of potential energy, the intermolecular forces of attraction decreases which results in increase in intermolecular spaces (inter particle distance, as you have asked).
You can see the graph where the temperature increase has paused for a time interval. That was the time interval when the interparticle distance was increasing.