A reparametrization-invariant approach to string field theory