Ships have differnet numbers of slots at different sizes, why not planets?
Population, buildings, farming, mining, industry and construction need space. Trading and Research maybe not so much.
Say for example that planets have slots say Tiny=5, Small=10, Medium=15, Large=20, Huge=25. Each point of population fills one slot. Each building fills one slot. Producing 2 food fills a slot. etc.
A population advance lets you put 2 populaton in a slot (or 1.5, whatever). A farming advance lets you produce 3 food in a slot. So underground living in programming terms is more people in a slot. We tell the player (in the tech description) that it is people living underground. Or it is people in skyscrapers, or farms in the sky - whatever.
This makes easy programming and game balance. A Gaia world is just increased slot size. Putting a building in has a cost associated - less farming/population whatever.
We can have farming worlds with lots of wide cornfields but low population - as you'd picture.
We can have big metropilises with lots of people, but no space for anything else.
If you focus farming the game gradually changes all the slots to farms (1 pop + 2 food) or to orbital farms (1 pop + 3 food). Just give tech names, say what goes in each slot. Buildings can use the correct amount of space. Buildings which affect everyplamet could use space on every planet. A palace fit for an emperor uses a piece of land that could have been a farm.
I think it is better that my homeworld, stuffed full of palaces/galactic wonders/100 constrcution/massive storehouses/planetary defences etc can't also feed half the empire with planetwide farms.