Dine-in patrons provide an important advertising benefit for restaurant owners that dine-in patrons do not. If you see a resaurant empty during peak times, you infer that it's no good; if you see a restaurant full during off-peak times, you infer that it's excellent.
As a result, restaurants are willing to give a price break to dine-in customers to encourage them to sit down and serve as human billboards. Or in other words, dine-in customers actually double as covert employees, whose job it is to advertise the restaurant. Their implicit pay roughly matches the extra cost of the dine-in experience, bringing it into parity with the cost of take-out.
So why are high-end restaurants that only do take-out so rare? Perhaps there is a lot more variation in quality for high-end restaurants, partly because the market is thinner, leading to a smaller role for franchising.