The material contained in the given link suffers from mistakes such as:
For a process carried out at constant temperature and pressure, the Gibbs free
energy change is equal to the maximum amount of work (wmax) that can be done by the process.$G° = –nF$.
Coming to answer your questions, the second equality in your equations: δQ−δW = δQ−(pdV + other forms of work output) = dU for an arbitrary process (1st law) δQrev−δWrev = δQrev−δWmax = (pdV + other forms of work output)max= dU for a reversible process (1st law)
δQrev = TdS 2nd law
Combination of 1st and 2nd laws gives for a reversible process the equality sign and the inequality sign for an irreversible process.
$$δQ−δW=dU=TdS−pdV+∑_i μ_i \mathrm{d}N_i $$
applies only to reversible processes, since you have substituted δQ = TdS, which applies only for reversible processes. Consequently, your next step must read as:
$$ ⇒δW−p\mathrm{d}V+∑_i μ_i \mathrm{d}N_i=δQ−T\mathrm{d}S=0 $$ ∵2nd law
and not as:
$$⇒δW−p\mathrm{d}V+∑_i μ_i \mathrm{d}N_i=δQ−T\mathrm{d}S ≤ 0 $$ ∵2nd law
This leads to the last step with equality sign
$$⇒δW−p\mathrm{d}V=−\mathrm{d}G\bigr|_{p,T}$$
This equation says, the decrease in free energy of a system (redox reaction) corresponds to the maximum work that the system can provide other than pressure-volume (pdV) work.
The statement in the link: For a process carried out at constant temperature and pressure, the Gibbs free energy change is equal to the maximum amount of work ($W_{max}$) that can be done by the process. $ΔG=W_{max}$, is not correct.
This must suffice as the answer for your first 3 points.
For your 4th point:
When both the donor and acceptor of electron in the chemical reaction lay inside the system the electric work will nowhere enter the formulation as the electric work is an internal work that does not crosses the boundary of the system!? But the whole formulation is here to study Welectric in the system as spontaneity of the reaction should be related to the electromotive force of the reaction which has a chance to appear in Welectric only! So what should be taken as system here?
You can very well have the electrons getting transfered from the donor to the acceptor within the system. In such a case, you will be studying a corrosion reaction and the free energy will be liberated as heat and gets tranfered to the heat reservoir that maintains the system at constant temperature.
But when you want to study the process under reversible conditions (open circuit emf you take leads outside the cell.
When you take the electric leads out and connect your load, the electrons don't get tranfered from the donor to the acceptor directly, but, liberated from the donor, they pass through the external circuit and then reach the acceptor - while the ion transfers within the cell do the job of transporting the electric charge, thereby maintaing the continuity of passage of electricity though the cell.
If you have more questions or if your questions are not answered completely, you may seek clarifications and I will be happy to answer to the best of my knowledge.