Selecting a Cap Value for Offsetting
For this specific scenario you need to consider:


Working voltage: you will have a 20 V difference between the two sides of your capacitor. You probably want to de-rate and choose a cap with at least 40 V WV rating. You should also consider turn-on and turn-off transients and be sure not to exceed your cap's WV rating at any time.
Capacitance: You want the capacitor to present a low impedance at the frequency of your ac signal. "Low" means low enough compared to the source and load impedances that it doesn't affect the circuit operation. Since \$X_C = 1 / (2 \pi f C)\$, you want a larger capacitor value the lower the frequency of your signal.


Of course, as with any other time you're selecting a capacitor, you need to look at operating temperature range, reliability, physical size, etc.