A landmark ruling has blocked offshore oil exploration in South Africa, strengthening protections for coastal communities, marine ecosystems and their livelihoods.