I also have that problem. I exit the tab and when I can back all my progress was all gone and I was back at the start.
You might want to look into having a way for the players to download their save file periodically (I think cookie clicker does this but I think they are using Javascript). Not sure if it would work with your set up, but it might be worth checking into since I'm assuming a lot of updates will be happening with the popularity of this game. That way if someone loses their save data, they can import their last save file and not lose everything!