Gold gains 13% in August as ETF inflows fuel rally