I dont know the official answer, but I think the "unofficial" answer is when the last guests have left the park.
I say this because I remember a trip a few years back when I was at Epcot, my friends and I had a few too many drinks and kept lingering around the World's Showcase long after the park closed.
By the time we made it back to the bus stops, there were a handful of other guests waiting from various hotels. They basically called one bus that brought us all back and just made several stops to several different resorts.
One of the CMs around the bus stop said they generally run a bus or two after hours to make sure all the guests have been picked up.