Foreign funds have pulled around $11 billion from local shares this year, but improving earnings prospects in the rest of 2025 could draw some of that capital back