In a landmark ruling, the International Court of Justice declared that failure to act on climate change can be an “internationally wrongful act”—meaning countries could face legal consequences for harming the planet.