# Why do heavy mid-sized stars become more luminous as they leave the subgiant branch entering the red-giant branch?

Wikipedia says:

For stars heavier than the around a solar mass the "outer layers cool sufficiently to become opaque" which "cause the hydrogen shell to increase in temperature and the luminosity of the star to increase, at which point the star expands onto the red-giant branch."

To my understanding, the source of luminosity is the H shell burning. If the outer layers become opaque (ie not transparent), why does the star become more luminous in this process?

Recall the Stefan-Boltzmann Law which describes blackbody radiation: $$L=4\pi\sigma R^2T^4$$ where $$L$$ is bolometric luminosity, $$R$$ is the radius of the star, and $$T$$ is surface temperature (in Kelvin). This implies that as the star expands, $$R$$ increases dramatically, causing $$L$$ to rise. Note that $$T$$ also drops by a bit, but this effect is relatively insignificant as $$R$$ experiences a much larger relative change, and $$L$$ increases overall.