Hi,
You're on the right track. Use variables. When you have a lot of content, you can end up with a lot of variables. I recommend grouping those variables using ".", such as "Chapter1.TalkedToWizard", "Chapter1.SolvedRiddle", "Chapter2.FoundCave", etc. Then you can view them in separate foldouts in the Dialogue Editor's Variables section, and those groups appear as submenus in dropdown menus.
Use dialogue entry node groups to visually organize different parts of your conversation tree, or split them into separate conversations and link conversations together.
I'll usually use the Dialogue Editor's "Menu > Play..." feature to test the flow of a conversation before playing it in a scene. Once I'm playing the conversation in a scene, I'll keep the Dialogue Editor window open on the conversation and also use these logging & debugging tips.