I believe it is tricky as it is filtered twice with the same filer. For band pass filters (including low pass and high pass) it usually works as it is, since there is no gain or attention in the pass band an filtering twice. Here filtfilt just zeros out the phase differences.
Thanks Jake, I suspect it would be difficult to obtain the same amplitude using some type of scaling as integration is basically a low-pass (i.e 1/s) characteristic and highly frequency dependent. Usually, filtfilt is used to reduce the impact of non-linear phase distortion in a non-causal situation.
This can be seen by lowering the input signal frequencies by a factor of 100 (and increasing the recording time accordingly). Then this will pass through in better shape:
Nice plots! I agree: for high-, low-, or band-pass filters where the frequency response amplitude is close to one in some frequency region of interest, filtfilt is perfect for non-causal filtering. I.e. when we want to keep just some band of frequency components and remove the others from the signal.