For me, D&D is "scifi" (including fantasy and other speculative fiction).
D&D is near-future. Magic = supertech. All contemporary challenges are present in D&D, whether gender equality or environmental concerns or the blurry line between humanity and magics-and-or-technologies.
If the setting is in year 2040, I want the supertech cop to be the Paladin class swearing the oath of a police officer. The popculture supertech holistic medicine guru to be the Bard class. And so on.
If the setting is in year 1040, I want Dancing Lights cantrips and similar magic illuminating city streets, and people aware of governmental ethics.
In scifi, in practice, the palpable difference between years 2040 and 1040 is the size of cities. For 1040, the DM can put every go-to location on a single page map. The entire city within the walls might be only 10 city blocks apart. For 2040, the city space is vast and sprawling, with patchworks of loosely defined neighborhoods, where the go-to places scatter randomly with no obvious relationship to each other, difficult to know and navigate, and challenging for the players to know what to do next.
Also, for 1040, divination magic can monitor public places. But in 2040, the surveillance technology makes "divination magic" impossible to ignore. Everything that players do has consequences.