The Cepheid changes its radius, temperature and luminosity. The oscillation period of a Cepheid depends on its average luminosity. The greater the luminosity of the Cepheid, the slower it makes its pulsations. This dependence makes it possible to determine the period of the Cepheid from observations, and then determine the distance to it.
Remember: The process of learning a person lasts a lifetime. The value of the same knowledge for different people may be different, it is determined by their individual characteristics and needs. Therefore, knowledge is always needed at any age and position.