Optimizing Solid-State Spins in Diamond for Nano- to Millimeter-Scale Magnetic Field Sensing