Choose the constraint first
If the destination has a maximum size, work toward that limit. If it only specifies resolution, keep the required dimensions and reduce encoding data instead. Resolution, bitrate, frame rate and duration all affect the final size.