A lot of early Anime has sci-fi/post-apocalyptic vibes because Japan was essentially a post-apocalyptic society. Japan is the only nation to have nuclear weapons used against it. It was so devastating, the entire world decided to just not do that sort of thing again.
But the level of national trauma Japan faced must have been something else. It affected their creative output for decades. Kaiju movies are essentially a response to the event. And elements of nuclear desolation is present in a lot of Anime. Akira, Vampire Hunter D, the earlier works of Miyazaki.
It's a huge fucking cultural touchstone for at least a couple of generations of Japanese people.
But we're also about 80 years from the event. Things are different in Japan. People have been born, lived full lives, and died between the time the bombs fell and today. There likely are children of children of people who were born after the bombs.
Japan today does have a lot more in common with the world at large. Their contemporary cultural touchstones are much the same ones around the world. So it makes sense that their art would reflect this.