There is a rather large piece of unexploded ordnance in the middle of the Brexit talks, which kicked off last week. It lay buried through most of the referendum campaign – but if not skilfully defused, it could go off with devastating consequences for our food system.

Consider these little-discussed facts: that food and drink is the UK’s largest remaining manufacturing sector – it’s bigger than the car and aerospace industries combined, and contributes over £28bn a year to the economy; that Europe is its most significant export market; that across the whole chain including farming, food accounts for over 13% of national employment; that 55% of all UK farm income is derived from European subsidies; that since we only produce just over half of what we eat, we depend on European imports for a quarter of our consumption; and that the sector has become so dependent on European migrant workers that without them it could collapse, as British strawberry growers have just warned.

Our departure from the EU represents both an existential risk to our food and farming system and a once-in-a-generation opportunity to reform it. Farmers received about £3bn in support from the much-reviled common agricultural policy last year – over £2bn in direct payments, paid per hectare, and about £600m in rural development payments. The Treasury has been itching to abolish direct payments for years, believing agriculture should be treated the same as any other part of the economy – that is, British farmers must be competitive in international markets without subsidy.

But take subsidies away, and only the largest-scale and most intensive greenhouse-gas-generating British producers are able to compete in globalised commodity markets. Even they struggle. Food is not like other sectors. With climate change and population growth threatening food security globally, keeping our farmers in business matters. They cannot maintain our treasured landscapes if they cannot make money. We need an imaginative new system of subsidy that gives public money to farmers for public goods, or we risk driving them off the land in droves.

Then there are the practicalities of adopting, amending, or abolishing the 4,500 or so EU regulations covering food, farming and environmental standards that fall within the remit of the Department for Environment, Food and Rural Affairs. Brexiters may loathe the Brussels bureaucracy that dictates everything down to the size of olive oil cans, but we need many of these rules to protect us from the sort of food safety scandals and adulteration frauds of the past. They are also what make trade deals and borders frictionless. Our exports depend on this sort of harmonisation of rules.

Take the jam regulations. When they were being reviewed a few years ago, department insiders said the then Tory secretary of state was embarrassed to take proposals to cabinet for fear of provoking humiliating laughter. What could embody red-tape madness of the sort leavers hate more than pages and pages of rules driven from Europe about how much sugar makes a jam a jam, or a jelly or a marmalade? Yet the UK food industry was lobbying for new rules. It wanted to respond to market trends for less sugary food and to bring the UK in line with Europe so it could develop export markets in France and Germany. Business sense won out; amended jam regulations were introduced. So a bonfire of the regulations will meet with resistance not just from consumers, but industry too.

The industry has also been screaming blue Brexit murder about its need for migrant workers. Now the government faces the impossible task of reconciling the Conservative commitment to curb immigration with the economic realities of this sector. Ending freedom of movement will almost certainly require creating a brand new Brexit bureaucracy of UK permits and visas for the 500,000 foreign workers whom farmers, food processors and food manufacturers say they must have to keep in business.

All this will have to be done by a team that suffered the largest cuts of any government department over the two parliaments to 2015. By the end of last year it had only a third of the number of core civil servants it had a decade before; so much expertise has been shed, in fact, that it is not clear that it now has the capacity to deal with its Brexit load.

If you are of the school of thought that the Brexiter Tories should be made to sort out the mess they’ve made, there are few more suitable candidates for the job than Michael Gove.

Michael Gove (second from left) admires a sheep at the Royal Three Counties Show in Worcestershire, earlier this month. ‘Whether Gove can force the future of our farming to prominence in negotiations will depend on his approach.’ Photograph: Paul Nicholls / Barcroft Images

As the new secretary of state at Defra, Gove landed the task of drafting the agriculture bill promised in last week’s Queen’s speech. The bill is meant to take us out of the common agricultural policy, which has reshaped our farming and landscape over the last 40 years. But it is not clear what will replace it: 40% of all European legislation relates to food and agriculture; 80% of all UK food legislation has been negotiated in the EU. Environmentalists were quick to express dismay at Gove’s appointment. Caroline Lucas, the Green party leader, said that Gove’s record of voting against measures to halt climate change and his attempt to stop schools teaching on the subject made him unfit to be Defra secretary. Jonathon Porritt tweeted that Gove was an “ideologically driven threat to all that environmentalists hold dear”.

But the big farm and landowner-lobby groups are quietly pleased that Gove’s resurrection has at least given them a high-profile secretary of state with sufficient intellect and clout to demand his own seat at the Brexit talks. Whether Gove can force the future of our food and farming to prominence in negotiations – or reduces it to a bargaining chip to be thrown away for other gains – will depend on his approach. Will he treat food, farming and the environment with as much disdain as he did education, and label its establishment the agricultural equivalent of “the blob”? Or will he temper ideology with a more practical energy and intelligence, of the sort he brought to prison reform?

Although when appointed he committed his department to maintaining subsidies until 2022, the instincts of Gove, an economic liberal, will be to get rid of them post-Brexit. He said during the referendum campaign that we would have better trade deals and cheaper food outside the market-distorting protections of the EU. Instead, thanks to a fall in sterling post-Brexit, rising food prices, increasing inflation and labour shortages are likely to make things worse.

Free of EU competition rules, Gove could make all sorts of active state interventions that would change our food system for the better. He could use the powerful lever of government procurement for schools, hospitals, the military and prisons to favour healthy British food. He could adopt a joined-up policy and target subsidies to increase production of the sort we need for health – more fruit and vegetables, less sugar and intensive meat production. He could ensure that new trade deals are built on maintaining welfare and environmental standards, rather than lowering them to compete in new markets. He could insist that continued access to foreign labour is tied to the industry, improving what are often appalling working conditions and pay so British workers are drawn back to jobs they now shun.

He will have to park his ideological preoccupations at the gate to make a success of it. He has said he is in humble and listening mode. Let’s hope he means it.