Insights into surface-adsorbate interactions in corrosion inhibition processes at the molecular level