The post follows closely the book of Otto Nachtmann -- Elementary particle physics (German edition).
The question is related with the fact how electrons and neutrinos are combined into representation vectors under SU(2) and U(1).
Although the particles mentioned here have mass, for this consideration they will be considered as massless. Furthermore, the acquisition of mass by means of the Higgs mechanism is not presented, it is just briefly mentioned when it is necessary.
Here only leptons of the first generation of SM particles are considered.
Let's start with SU(2):
A left-handed electron neutrino $\nu_{eL}$ and left-handed electron $e_L$ are combined into a duplett which transforms under SU(2) group transformations U:
$$\left( \begin{array}{c} \nu_{eL} \\ e_{L} \end{array}\right) \rightarrow U\left( \begin{array}{c} \nu_{eL} \\ e_{L} \end{array}\right)$$
whereas the right-handed electron $e_R$ is not affected by the SU(2) group (it is a singlet):
$$e_R \rightarrow e_R$$
In order to make the Lagrangian invariant under these local transformation a gauge field $\mathbf{W}_\mu = \mathbf{W}^a_\mu\frac{\sigma^a}{2}$ has to be introduced ($\sigma^a$ are the Pauli-matrices). This gauge field will provide us with 3 fields: $W^\pm_\mu = (W^1_\mu \pm i W^2_\mu)/\sqrt{2}$ and $W^3_\mu$. One could now suspect that the fields $W^\pm_\mu$ correspond to the 2 charged vector bosons and $W^3_\mu$ to the photon. However, $W^3_\mu$ does not couple to the right-handed electron $e_R$ (a photon undiscriminately would couple to $e_L$ and $e_R$), so we don't get what we want.
However, another local gauge transformation can be introduced to act on the 3 "particles" which is actually U(1):
$$\left(\begin{array}{c} \nu_{eL} \\ e_L \\ e_R\end{array}\right) \rightarrow e^{i\chi \mathbf{Y}}\left(\begin{array}{c} \nu_{eL} \\ e_L \\ e_R\end{array}\right)$$
$\mathbf{Y}$ is a matrix:
$$\mathbf{Y} =\left( \begin{array}{ccc} y_L & 0 & 0 \\ 0 & y_L & 0\\0 & 0 & y_R\end{array}\right)$$
This transformation can simply be achieved as phase transformation, so it is of the group U(1). We know the group U(1) from electromagnetism, we can associate it with a gauge field as in EM-theory, i.e. a 4-vector field called $B_\mu$. However, $B_\mu$ can't be the photon field neither since it couples to a neutral particle, the neutrino.
We now construct the gauge exchange bosons associated to the gauge fields. $W^\pm_\mu$ are the fields which can be associated with the vector bosons $W^+$ and $W^-$. But $W^3_\mu$ and the $B_\mu$-field combine to create the $Z^\circ$ particle (necessary to explain the neutral currents found by the experiments, remember LEP was running on the $Z^\circ$ resonance for years and generating millions of it) and the photon $\gamma$($g$ and $g'$ are the coupling constants of the gauge fields $W^a_\mu$ and $B_\mu$):
$$Z_\mu = (g W^3_\mu - g' B_\mu)/\sqrt{g^2+ g'^2}$$
and
$$A_\mu = (g W^3_\mu + g' B_\mu)/\sqrt{g^2+ g'^2}$$
It is important to note that the $\mathbf{Y}$ represents the weak Hypercharge which is different from the electrical charge by:
$$Q = \mathbf{Y} + T_3$$
the last being the third component of the weak Isospin.
Still all introduced gauge bosons are massless. Via the Higgs-mechanism they adopt mass in a rather subtle way so that $W^\pm$ and $Z^\circ$ adopt mass, whereas the photon $\gamma$ does not. In order to at least vaguely understand this one has to note that the Higgs field $\phi$ is a priori also a dublett that transforms under SU(2):
$$\phi = \left( \begin{array}{c} \phi_1 \\ \phi_2 \end{array}\right)$$
The trick to be used is to select a vaccum state of this field that breaks the SU(2) symmetry in a way that $W^\pm$ and $Z^\circ$ adopt mass, but the $\gamma$ not. This is done by:
$$\langle 0 | \phi | 0\rangle = \left( \begin{array}{c} 0 \\ \rho_0/\sqrt{2} \end{array}\right)$$
I will not go further into details, this has to be looked up in the corresponding textbooks. I recommend Otto Nachtmann -- Elementary Particle Physics and Aitchison & Hey for this subjects. The books on QFT present the SU(2) x U(1) gauge field towards the end, and in order to understand well what they say, one has to read at least 500 pages before this topic is discussed.
Recap: Once the SU(2) duplett is combined/created it is very difficult to find an additional transformation which could represent the U(1) symmetry of EM-theory. Because the SU(2) duplett is a combination of a neutral particle, the neutrino and a charged one, the left-handed electron $e_L$.
Actually, the U(1) out of SU(2) X U(1) is not the U(1) symmetry of EM-theory, it is the symmetry described by the weak Hypercharge $\mathbf{Y}$ and not the electric charge. The electric charge is a combination of Hypercharge and weak Isospin. Once one has realized that it is quite clear that the B field cannot be $A_{EM}$, the $A_{EM}$ has to be constructed out of 2 different fields, the $W^3$ and the $B$.
The quantum number $T_3$ distinguishes between the left-handed neutrino $\nu_{eL}$ where it is $T_3=1/2$, whereas for the left-handed electron it is $T_3=-1/2$. However, for the right-handed electron $e_R$ $T_3=0$. For completeness I give also the values for the weak Hypercharge: $y_L=-\frac{1}{2}$ and $y_R = -1$. Using these numbers the EM-charge $Q$ of all 3 particles neutrino $\nu_{eL}$ and left-handed electron $e_L$ and the right-handed electron can be computed correctly.