Curiously enough I just watched this interview with Horner and the director about how much of the score was improvised on the recording stage with the synth players and the pan flute players. The orchestral parts obviously weren't, but what a fascinating contrast: