"Now, most of those farms have been sold off to mega farms or handed off to kids that don't really want to be a "farmer"."
It's common practice that the person doing the farming may not be the land owner. Field leases are extremely common. So they can inherit the land and just lease the fields until they decide to sell to a residential developer for big money as the urban sprawl encroaches.
The vast majority of farms are not in danger of urban sprawl. Farms near cities are but there is a lot of land not close.
The easy test is ask someone who has known an area for 50 years how many new houses have gone up. You might be surprised. Even in depressed areas with some reduction in population, such as some areas of Appalachia, there are many new houses in rural areas.
"there are more houses in my area, therefore there are more houses everywhere" is illogical. i wish it were true in the seattle area. also, there will always be more houses today than 50 years ago in a society with an above zero birth rate.