  We perform a combined analysis of the recent AMS-02 data on electrons,
positrons, electrons plus positrons and positron fraction, in a self-consistent
framework where we realize a theoretical modeling of all the astrophysical
components that can contribute to the observed fluxes in the whole energy
range. The primary electron contribution is modeled through the sum of an
average flux from distant sources and the fluxes from the local supernova
remnants in the Green catalog. The secondary electron and positron fluxes
originate from interactions on the interstellar medium of primary cosmic rays,
for which we derive a novel determination by using AMS-02 proton and helium
data. Primary positrons and electrons from pulsar wind nebulae in the ATNF
catalog are included and studied in terms of their most significant (while
loosely known) properties and under different assumptions (average contribution
from the whole catalog, single dominant pulsar, a few dominant pulsars). We
obtain a remarkable agreement between our various modeling and the AMS-02 data
for all types of analysis, demonstrating that the whole AMS-02 leptonic data
admit a self-consistent interpretation in terms of astrophysical contributions.
