Most ultraluminous X-ray sources (ULXs) are thought to be powered by neutron stars and black holes accreting beyond the Eddington limit. If the compact object is a black hole or a neutron star with a magnetic field $lesssim10^{12}$ G, the accretion disc is expected to thicken and launch powerful winds driven by radiation pressure. Evidence of such winds has been found in ULXs through the high-resolution spectrometers onboard XMM-Newton, but several unknowns remain, such as the geometry and launching mechanism of these winds. In order to better understand ULX winds and their link to the accretion regime, we have undertaken a major campaign with XMM-Newton to study the ULX NGC 1313 X-1, which is known to exhibit strong emission and absorption features from a mildly-relativistic wind. The new observations show clear changes in the wind with a significantly weakened fast component (0.2c) and the rise of a new wind phase which is cooler and slower (0.06-0.08c). We also detect for the first time variability in the emission lines which indicates an origin within the accretion disc or in the wind. We describe the variability of the wind in the framework of variable super-Eddington accretion rate and discuss a possible geometry for the accretion disc.