the lone pair is donated to the C=O. This makes amide N-Hs slightly acidic (pKa ~17) and the amide N essentially unreactive as a base.