UN says 338,000 Afghans internally displaced in 2017