"In Darboux's theorem proof there is no use of continuity of the derivative as there is no in Fermat's theorem. Only existence is being used.
Existence + local (maximum or minimum) = zero derivative.  "