Why does these capacitances have no effect on the output of this amplifier?
When an op-amp is operating closed-loop with negative feedback within its linear region of operation (all input/output specifications met). The two input terminals will have an equal voltage due the feedback action of amplifier A. This action creates a virtual ground at the opposing input terminal of the amplifier.

With no potential being developed across the cable's terminals, no current flows through \$C_g\$ or \$C_c\$. All the signal current flows through the feedback network of amplifier A.