And a great first post mate! If only they were all like that.
A very interesting perspective from a beginner. I'm pretty impressed that was your first ever race, on a $600 bike, with clips. You are right, that was a pretty technical course, well done for getting around it and still having a good time.
Regarding some of your questions:
This year's Mont course at Sparrow Hill was heaps easier than the Scott, less climbing and hardly any tech. However, for next year I believe it will be run at a different venue.
Most punctures are what are called pinch flats, where you hit a rock hard and the rim gets driven through the tube. This is why you see so many flats being repaired on or after decending sections of trail. Avoiding pinch flats is primarily a technique thing and comes with experience, but tubeless can substantially help too.
Edit: And regards your night riding, a couple of tips. This might sound obvious, but the more lighting power you have, the further you can see ahead, and the better you ride. Lighting power makes a big difference. Also having a handle bar mounted light as well as your helmet mounted light is very helpful, as you can see the shadow behind obstacles so your perception of them is clearer.