Light is not a mechanical wave through air. Indeed you cannot have transverse mechanical waves in a gas because these (the mechanical waves) rely on shear stress in the medium. But light does not need the air to propagate, air is more "in the way" rather than an element necessary for propagation of EM waves.