Then the sea gave up the dead that were in it, and death and Hades gave up the dead that were in them; each one was judged according to their works.
We felt we understood what it means that "death and Hades" give up the dead, but what does it mean when it says "the sea gave up the dead"?
Are the dead in the sea?
In answering the question, I pointed to the next chapter to make an observation about the new heavens and the new earth:
Then I saw a new heaven and a new earth; for the first heaven and the first earth had passed away, and the sea was no more.
The sea doesn't exist in the new creation.
Two answers present themselves. First, in the ancient imagination, the sea represented a primordial and destructive chaos. You see a hint of that cosmology in the open lines of Genesis, where the waters of the deep are described as tohu wa-bohu, translated as "waste and void." In the various acts of creation God brings order and structure to this formless chaos. And yet, that destructive power persists. For example, in the flood narrative God allows the destructive powers of chaos to break free, effectively rebooting the world and starting over.
Given this, the declaration in Revelation that "there is no sea" means that, in the New Creation, the destructive power of chaos has been finally and permanently eradicated.
Concerning the sea as a location of the dead, ancient peoples speculated those lost at sea resided in its depths. Those dying at sea didn't go underground, to Hades, like those who died on land. This is the old mariner's tale that those who die at sea go down to Davy Jones's locker. In short, both land (Hades) and the sea were realms of the dead.
Consequently, both land and sea give up their dead in the general resurrection.