Long before investors lost faith in the Chinese stock market, something seemed amiss at the ports of Long Beach and Los Angeles. The number of containers coming from China was up, but beginning in 2013, fewer loads were being sent in the other direction.