Dear Student,
The process of production of ATP using the energy of sunlight is called as Photophosporylation. This process is achieved by chemiosmosis. Chemiosmosis is defined as the process of ions movement across a selectively permeable membrane down their concentration gradient.
Chlorophyll molecule absorbs light during photosynthesis. the electrons present in these molecules are then elevated to a higher energy level. then, these molecules moves to the Photosystem I and II. While doing this, they release energy.
This energy is then to move hydrogen ion across Thylakoid membrane (the space enclosed within thylakoid).This step leads to the formation of a concentration gradient of Hydrogen ions in these spaces.
when ATP synthesis takes place, these ions then goes back to the thylakoid membrane down their concentration gradient. ATP synthesis takes place by the enzyme ATP synthase which uses energy that is released by the transfer of hydrogen ion down their concentration gradient to Synthesise ATP. This ATP is derived from ADP and some inorganic phosphate.
Regards.