There are no winners in this story. There are only losers. Ever since Mesut Özil’s explosive retirement from international football, that phrase is on everybody’s lips. From the editors of Kicker magazine to the members of Angela Merkel’s cabinet, they all agree. There are only losers.

Özil’s retirement, in which he unleashed a withering attack on what he argued was structural racism within the German football federation (DFB), media and society, was the climax of a bitter debate which has overshadowed German football this summer. It has also prompted a much broader discussion. In late July, the 24-year-old Ali Can started the hashtag #MeTwo, which promptly went viral as immigrants and Germans with immigrant backgrounds shared their experiences of everyday racism and the difficulties of dual identity.

For a footballer, albeit a very good one, to unleash a national debate on this scale is unusual. It takes the game out of its comfort zone of straightforward force-for-good narratives about sport and society. Nothing in this story is straightforward. It is a tale which deals almost exclusively in nuance, which is inseparable from immensely complex issues such as German-Turkish relations and the role of Islam in German society. It has been a long, hot summer, in which ill-feeling has often boiled over into something more sinister. At the heart of it all is a footballer who posed for a photograph.

On May 14, the summer was at its coolest, with an average of just over 11 degrees across Germany. On that day, photos emerged which showed Mesut Özil and his Germany teammate İlkay Gündoğan posing, smiling, with the Turkish president Recep Tayyip Erdoğan at an event in London. From then on, it would only get hotter.

With both the World Cup and a crucial Turkish election just weeks away, the photos opened up Özil and Gündoğan, both Germans of Turkish descent, to fierce criticism. The DFB hastily organised clear-the-air talks with both players, as did the German president Frank-Walter Steinmeier. The DFB then declared the discussion to be ended, but it clearly wasn’t. The longer Özil failed to make a public statement, the more the public’s confusion and outrage about the matter grew. Then Germany crashed out of the World Cup and the whole thing exploded.

Having tried to bury the Erdoğan issue before the tournament, the DFB were only too happy to dig it up again in the aftermath. Germany’s general manager Oliver Bierhoff suggested that Özil had not followed the DFB’s advice and that they should have considered dropping him. Shortly afterwards, the DFB president Reinhard Grindel pompously called on Özil to make a public statement. A few weeks later, Özil did break his silence, resigning with an eloquent but raw attack on politicians, the media and the DFB. Tellingly, he wrote the statement in English. This, it seemed, was about more than just one scandal: it was Özil’s reckoning with an entire country.

“We all knew that, if Germany got knocked out, Özil would be blamed,” said Ünal Oğuz. “Not the other players, not the president, Özil.”

Oğuz is, like Özil, a German citizen of Turkish descent. Like Özil, and millions of others, he was born and raised in Germany. On a scorching day in Berlin, he is wearing shorts adorned with the German Olympic emblem. He has, he says, always told his wife that he wants to be buried in Kreuzberg, his home district. He, unlike Özil, has never met Erdoğan. Yet like Özil he feels that there are some parts of German society who are unable or unwilling to see him as a compatriot.

“You have black hair, you’re interesting, you’re exotic, but at the end of the day, you’re something people fear,” he says.

Özil struck a similar tone in his resignation statement. Here the much-quoted sentence about being German when the team wins and an immigrant when they lose, there the point about Lukas Podolski never being referred to as “German-Polish”. Whether it is about skin colour or religion, there is undoubtedly a much more deep-seated objection to the idea of a Turkish German. The structural problems are also unquestionable: Özil’s elegant assertion that he has “two hearts” subtly hinted at the real problem: that he does not have two passports. The right to dual citizenship was only recently introduced, phased in laboriously over the course of the 21st century. At the age of 23, Özil had to choose which nationality to take and he chose German. At that time, MeTwo wasn’t an option.

That the DFB president Reinhard Grindel was one of the many Christian Democrat politicians who had previously campaigned against the introduction of dual nationality at all makes the DFB’s political clumsiness an even more bitter pill to swallow. Many feel that the association cynically hung Özil out to dry, in order to avoid difficult questions about other topics. The future of Joachim Löw, for example, or that of Reinhard Grindel. There is no doubt that Özil, both in meeting Erdoğan at all and in his protracted silence, made a grave error. Yet for many, the DFB’s failure to defend him properly was far worse.

Grindel released a statement a few days after Özil’s retirement, saying that while he rejected all accusations of racism, he could have been clearer in his condemnation of it earlier on. But, as many critics pointed out, that ship had sailed. The DFB had attempted to sit out the situation and missed numerous opportunities to denounce racism unequivocally. The same goes for many of Özil’s teammates. Even as late as August, Manuel Neuer’s contribution to the debate was to say that it had been “strenuous” for him to have to read about it all, and that there had been no racism within the team. Throughout the summer, the only team mate who expressly defended Özil was Jérôme Boateng, who said in July that some of the criticism was “borderline” and overlooked that “Mesut is a human being”.

“They should have thought about Mesut Özil as a person more,” agrees Oğuz. “Where was their solidarity?”

You only had to take a cursory glance at İlkay Gündoğan this summer to see that the scandal was taking its toll on a personal level. The Manchester City player wept openly after he was booed in a friendly against Saudi Arabia, and looked a broken man in the few cameo appearances he made in Russia. In terms of pure self-preservation, Özil’s decision to pull out of the Saudi Arabia game was probably sensible.

For if Gündoğan was relentlessly booed, how would they have treated Özil, who has long been the most divisive player in the national team? In recent years, a debate has raged as to whether he is underrated, a talisman working magic in the shadows, or overrated, a spoiled and lacklustre celebrity who is prone to disappear when it matters.

Arsenal fans will understand the conundrum. Özil is a slender midfielder who glides between the lines and angles of a game. To the naked eye, he never looks as effective as the statistics say he is. That also makes it difficult to distinguish when he is performing badly and when he is simply running the game from the shadows. His effortlessness as a footballer is enchanting and infuriating in equal measure.

In the context of the national team, the perceived effortlessness fits dangerously well into a more sinister debate. A debate about him not singing the national anthem, for example, or not pulling his weight in a Germany shirt. These questions are not new; they have followed Özil throughout the second half of his international career. Even in 2014, the biggest topic of debate around Germany was, until the final, Mesut Özil. Was he pulling his weight? Should he be dropped.

The questions resurfaced this summer, with Lothar Matthäus writing a column in Bild in which he claimed that Özil “doesn’t feel comfortable in a Germany shirt”. A few days later, Özil was left out of the starting line-up against Sweden and in the fan zone at the Brandenburg Gate many were delighted by the news. Özil should have been left at home in the first place, some said. Several echoed Matthäus’s words, saying that Özil didn’t respect the shirt. Bild may protest that they never ran an openly racist headline or article about Özil, but in the fan zone on that day, it felt like many had heard the dog whistle.

That dog whistle had been sounding for a long time, so why did it all come to a head this summer? The photo is certainly important, more important than most outside of Germany have understood. Yet as Özil pointed out, Matthäus himself came in for far less criticism when he shook hands with Vladimir Putin during the tournament. As an honorary captain and thus ambassador for the DFB, Matthäus’s deference in the face of an autocrat was surely just as scandalous as Özil’s. But here the outrage was quickly nipped in the bud. Bild, to their credit, did criticise their columnist, prompting Matthäus to tweet an old photograph of a former Bild editor shaking hands with Putin. Again, everyone was tarnished, and nobody a winner.

With Özil, it was about more than photographs. It was about a broader battle going on within German society. One which politicians and media have cynically exacerbated in recent years, most notably the interior minister Horst Seehofer, who earlier this year reasserted his claim that “Islam isn’t part of Germany.” Seehofer is another who said that “there are only losers” in the Özil affair, but without his populism there might well have been a few more winners.

The compatibility debate about Islam and Germany is directly relevant to Özil, a German Muslim who prays while his teammates sing the national anthem. But it is also a phoney debate. Like the debate about Özil himself, it does not start from a neutral or factual position. It sets up a patsy and demands that they justify themselves. In this regard, Özil is just the tip of a very toxic iceberg.

“I feel like we are living in a time machine,” Esra Küçük, founder of the Young Islam Conference and a former director of Berlin’s Maxim Gorki Theatre, told the Spiegel at the end of July. “While I am living in modern Germany, the debate going on around is straight out of the 1990s. All our achievements on the way to being a modern country of immigration have been set back miles.”

The 1990s. A time at which neo-Nazi grassroots organisations were flourishing in certain parts of Germany. One of those organisations, in Thuringia, would spawn the infamous National Socialist Underground (NSU) group. Between 2000 and 2006, the NSU would murder nine small-business owners, eight of them Germans of Turkish descent. The media, having tastelessly labelled them the “doner kebab murders”, ascribed the killings to Turkish mafia until the true identity of the three neo-Nazi murderers was revealed in 2011. Among repeated accusations of incompetence and even compliance from organs of the state, the NSU scandal has cast a long shadow over German society. Beate Zschäpe, the one surviving member of the group, was finally sentenced to life in prison in July this year, two weeks after Germany had crashed out of the World Cup, and 11 days before Özil’s retirement.

Many, like Küçük, had hoped that German society had moved on. That, with the introduction of dual nationality, and the slow but steady proliferation of ethnic minority figures in Germany’s parliament, its public sphere and, yes, its football team, the country had assumed a confident identity as a nation of immigration. The NSU scandal shook that confidence to its core, the rise of the far-right AfD party even more so. The Özil affair is for many the final proof that German society still has enormous problems with diversity and immigration. In the same Spiegel article, the SPD politician Cansel Kiziltepe told of a constituent who, using a familiar German expression, had said to her that “if a donkey is born in a horse’s stable, it is still a donkey.”

Like many German politicians of Turkish descent, though, Kiziltepe has received abuse and threats not just from racists, but also from Erdoğan supporters. The Turkish president has a record of demonising German-Turkish MPs, and ahead of last year’s German elections, he urged voters of Turkish heritage not to vote for three main parties, calling them “enemies of Turkey”.

That is only part of it. The year-long imprisonment of the German journalist Deniz Yücel, the absurd defamation charges brought against the comedian Jan Böhmermann in 2016, the repeated characterisation of Germans as “Nazis” and the cynical exploitation of Özil’s retirement have, in recent years, made Erdoğan more than just a foreign populist. They have made him a national bogeyman, and not without reason.

They also make the Özil affair more than a straightforward racism scandal. For all his undoubted eloquence in calling out the structural racism of the media and the DFB, Özil’s justification for meeting Erdoğan wilfully ignored a political context of which he cannot claim to be ignorant. To compare it with Theresa May or the Queen meeting Erdoğan was patently absurd. Özil is not a head of state and he is not responsible for international diplomacy. But he is a high-profile footballer and he is responsible for how he allows people to use his image.

As Cem Özdemir, former leader of Germany’s Green Party, put it at the time: “I am not critical of [Özil and Gündoğan] for supposedly not being German. On the contrary, I am critical of the fact that a German citizen has had a photograph taken with a despot who shares none of our values.”

The nuance of that position remains important, precisely because there are so many people who would make it about Özil’s supposed German-ness. After the defeat to South Korea, some AfD politicians made the absurd suggestion that Özil had deliberately sabotaged Germany’s World Cup campaign on Erdoğan’s orders. Erdoğan himself, meanwhile, happily crowed that Özil’s retirement was an act of Turkish patriotism. If there are any winners in this story, then they are the political extremists, the populists, who can mould it and simplify it to serve their own cynical narratives. At this stage, the only possible way to stop them winning is to assess every aspect of the scandal honestly, in all its inglorious complexity. Germany is traditionally very good at that.

For it is all intimately related. Even something as straightforward and understandable as Özil’s anger at being called a “goat fucker” is layered with context. “Goat fucker” is the term to which Erdoğan took offence in Jan Böhmermann’s satirical poem. It is symbolic, both of lazy German racism towards Turkish people and of Erdoğan’s calculated meddling in German political discourse. Most of all, it is symbolic of the vicious circle between those two things. In both the Böhmermann and the Özil affair divisions were further entrenched and the only people who gained were Erdoğan and the right-wing populists in Germany. Otherwise, there were only losers.

Both cases not only deepened Germany’s suspicion of the Turkish state, but arguably also the Turkish community’s suspicion of their fellow Germans. “The Özil affair will probably encourage more nationalist feeling in the Turkish community,” says Oğuz. “They feel betrayed.”

“Özil was a role model, especially for young people,” he continues. “I had hoped that players like him and Gündoğan, because they were successful, would change something for the better.”

That, for years, was the dream. A dream shared not only by ethnic minorities in Germany, but also by many others. A dream perpetuated by the DFB’s positive work, both at the grassroots and in public relations, with regard to integration. It was the dream that saw Mesut Özil awarded the very first Bambi integration prize in 2010. The dream was that a national team made up of Germans whose families came from Bavaria, Tunisia, Poland, Turkey, Ghana and Berlin could act as a beacon for society at large.

And in many ways, it was and is more than just a dream. For over a decade after 2006, the national team was an almost universal source of pride, albeit characteristically reluctant pride for many Germans. When the AfD politician Alexander Gauland said two years ago that Jérôme Boateng was “a good footballer, but not somebody you would want as your neighbour”, a whole country rose to shout him down. Perhaps, too, some good will come of the Özil affair as movements like #MeTwo prompt a more constructive debate. For now though, it is a bitter tragedy which calls into question much of the achievements of the last decade or so.

“There is a Turkish proverb which says that when a tree bears fruit, people will throw stones at it,” says Oğuz.

Something good takes time to grow. Yet once it has grown, people often want to tear it down. The trouble is, if you tear down the tree, then nobody gets any fruit. In the end, everyone is a loser.