Here's why:
* Blackbody Radiation: Stars are excellent approximations of blackbodies. A blackbody is an idealized object that absorbs all radiation that falls on it and emits radiation at all wavelengths.
* Stefan-Boltzmann Law: The Stefan-Boltzmann law states that the total energy radiated per unit surface area of a blackbody is proportional to the fourth power of its absolute temperature. In simpler terms, the hotter the object, the more energy it radiates.
* Luminosity: The luminosity of a star is the total amount of energy it radiates per unit time. Since the energy radiated per unit area increases with temperature, a hotter star will have a higher luminosity.
So, the hotter a star is, the more light it emits.