Amplitude is defined as the maximum displacement from the rest position. In other words, the furthest distance something moves from where it was at rest.
Looking at the snapshot below of part of a longitudinal motion. At the top, the red line is at its rest position.
Underneath is the red line shown at its maximum displacement to the right. The distance it has moved is the amplitude of the oscillation.