Adding a few points from my own experience:
- Keep the front wheel as light as possible, that means pushing your body far back whilst standing on the pegs.
- If things start to get twitchy give it some gas - throttle heals most such situations, though is counter-intuitive and scary.
Sand needs skinny and big (radius) front wheel, that's why most offroad motorcycles have 21" front wheel. The counter point to this is harder turning in the twisties on tarmac due to increased gyroscopic effect of bigger radius wheel. Sportsbikes have 17" for this reason, tourist and soft-enduro bikes try to strike a balance with 19" wheel and hard enduros are all 21". Bigger wheel climbs up, smaller wheel digs itself in.