I don't think countries are closed systems, since they interact with the rest of the world. Countries can increase revenues without increasing costs. Suppose a country figures out how to get fusion to work: decreases electricity cost, increases revenues from sales of fusion plants. Or they talk to other countries about how to grow more/better crops; assuming they weren't at 1st world yields, there are many things that are cheap to implement that produce more money.