I used to write code by hand, now I just write prompts and manage the AI. There is some expertise involved but considerably less than before, and no doubt even that will vanish in the coming years.
For mathematicians the picture is even more bleak because their field is being strip mined and they face a future where there are perhaps no human reachable conjectures. Moreover if your job is to teach other mathematicians and nobody wants to become a mathematician... This is the future even if the technology hardly improves at all.
You don't need to know if there will be safe jobs in the future to avoid jobs that are unsafe today.
Personally if I were a teenager today I'd choose a career in medicine. You can still exercise your brain, but because it's practical and the fact that you have people's lives in your hands means that it's considerably less likely to be replaced by AI any time soon.