SCSS code losing a lot of changes after editting CSS

Hi all. Not sure if anyone else has had the same issue. I have my main editor window, SCSS styles window and HTML code window open. When I make changes to the HTML window, I lose a heap of SCSS code. Not sure what the pattern is other than when I edit the HTML, it seems to happen.

It’s really frustrating and it really making me want to use external editors for everything as I cannot even CMD+Z to get the changes back. It just does nothing. If I at least had that, it would be something.

Cheers and props to all.