Fast optical cooling of a nanomechanical cantilever by a dynamical Stark-shift gate