Greenbrier Cos. reported a sharp decline in quarterly profit and revenue as the freight-railcar manufacturer contended…