What factors contribute to the decline of a coral reef ecosystem?