Thanks for asking a question on thisisyourbible.com.
Heaven and earth in this context means the earthly "cosmos" or order of things that exist today. Look at 2nd Peter 3 and you will see 3 different "heavens and earths" mentioned:
1. The "heavens and earth" which existed before the flood and which were destroyed in the flood
2. The "heavens and earth" which has existed from the flood until now and which will be destroyed when
Christ comes to establish his kingdom.
3. The new "heavens and earth" which will be established in God's Kingdom at Christ's return.
The symbol of the "heavens" being the seat of political power and the earth representing those ruled by such powers is common in scripture. Let's look at Isaiah:
Isaiah 1:2 Hear, O heavens, and give ear, O earth; for the LORD has spoken: "Sons have I reared and brought up, but they have rebelled against me. Note that the people of Israel are addressed as "Heavens and earth" What does he mean by this. We find out quickly in verse 10 when he changes the metaphor:
Isaiah 1:10 Hear the word of the LORD, you rulers of Sodom! Give ear to the teaching of our God, you people of Gomorrah! It is clear that he is addressing the people of Judah who have become as corrupt as Sodom and Gomorrah. And instead of heavens and earth he says rulers and people. Now the clincher in Isaiah 65:
Isaiah 65:17, 18 "For behold, I create new heavens and a new earth; and the former things shall not be remembered or come into mind. 18 But be glad and rejoice for ever in that which I create; for behold, I create Jerusalem a rejoicing, and her people a joy.
The new heavens and the new earth are the same as "Jerusalem and her people" - the rulers and the ruled in God's kingdom.
Linking this passage to Peter's "new heavens and new earth in which righteousness dwells" shows us that Peter is talking about a new world order in which righteousness will reign supreme when all of the corrupt systems and works of mankind have been consumed in judgement.
Interestingly this also explains Paul's vision of the "third heaven" in 2 Corinthians 12
2 Corinthians 12:2 I know a man in Christ who fourteen years ago was caught up to the third heaven
What was the "third heaven". Peter tells us in 2 Peter 3 - it is the kingdom of God, specifically the "new Jerusalem". He saw a vision of Christ and the saints in glory in the Kingdom age.
I hope you have found this helpful.