(a) The atmosphere is densest near the ground and becomes steadily less dense with height. Light from the Sun therefore travels from rarer layers into denser ones on its way down to us, and is refracted towards the normal a little at every boundary.
The path is not straight but gently curved, so light from a Sun that is really below the horizon can still be bent round to reach the eye. Because we judge direction along the straight line the light arrives on, we see the Sun higher than it really is — and go on seeing it for a short while after it has truly set.
(b) Because of the path length through the atmosphere.
Light from a star at the horizon enters the atmosphere at a very shallow angle and travels a long, slanting path through many layers of changing density, so the bending accumulates. Light from a star directly overhead comes down almost perpendicular to those layers; it meets each boundary head-on, where refraction produces little or no change of direction, and its path is nearly straight.
(c) About four minutes — roughly two minutes of advanced sunrise in the morning, when the Sun is seen before it has actually risen, and about two minutes of delayed sunset in the evening.