Impact of habitat fragmentation and loss on coastal ecosystems: implications for sustainable management under climate change