Append part of the audio at the end of another audio
Assuming the duration of B is X (in seconds), you would use

ffmpeg -i A -i B -filter_complex "[0]volume=0:enable='lt(t,X)'[a];[a][1]amix=duration=first:dropout_transition=0,volume=2" out