Why E = (Vc + Vr) in a circuit with a capacitor and a resistor in series?
Let's start with E=Vc+Vr in a circuit with a battery of emf E and a capacitor of and a resistor.


This has nothing to do with any special property of capacitors or resistors. Consider this circuit:







simulate this circuit &ndash; Schematic created using CircuitLab

Regardless of what the U2 and U3 are, Kirchoff's Voltage Law (KVL) tells us that \$V_1 = V_2 + V_3\$. 

This is true if U2 is a resistor and U3 is a capacitor or if U2 is one coil of a transformer and U3 is a spark gap.


  My understanding is that the capacitor produces a voltage Vc in the opposite direction to the battery's emf E,


I think using the word "opposing" in this description is a bit confusing. It's really simple once you get the hang of it.

Consider the circuit above where U2 is a short circuit (so \$V_2\$ is 0). Then you have \$V_1 = V_3\$. The source is connected directly across U3, so the voltage across U3 is exactly equal to the source voltage. When we say it's "opposing" the source voltage we just mean that the reference direction of U3 is opposite the reference direction of V1 (which is why we've had \$V_1\$ on one side of the equals sign and \$V_3\$ on the other side in our KVL equations). 

Again KVL requires this to be true, no matter what kind of component U3 is. It could be the b-e junction of a transistor. It could be a coil of a transformer. It could be a resistor. Or it could be a capacitor. In all cases, the voltage \$V_3\$ must be equal to \$V_1\$ with opposite reference direction.