In 2003, Justin Timberlake helped launch an ambitious new McDonald’s marketing campaign. Tied around the slogan “I’m Lovin’ It,” the advertising blitz marked, surprisingly, the first time the venerable fast-food company had ever used a single message and set of commercials worldwide at the same time. Over the past 13 years, “I’m Lovin’ It” has gone on to become by far the longest-running McDonald’s slogan in history. And the jingle’s “ba da ba ba ba” vocal hook, originally sung by Timberlake, has grown more famous than Timberlake’s actual hits.

“I’m Lovin’ It” popped up in discussion again last month when word resurfaced of Pusha T’s involvement. The now-president of Kanye West’s G.O.O.D. Music basked in the attention on Twitter, showing what a hold this multibillion-dollar melody still has on the popular imagination. As it turns out, the full story behind the McDonald’s ditty is part David and Goliath, part King Midas, and part “Mad Men,” with plenty that foreshadows both the 21st-century music industry and the culture beyond it.

Early in 2003, its business in trouble, McDonald’s held a competition between 14 international ad agencies, including the industry’s largest. The winning firm, Heye & Partner—though affiliated with a bigger company—was a “tiny” shop, according to The Wall Street Journal, and based in, of all places, the quiet Munich suburb of Unterhaching, Germany. (Not as delicious as Hamburg, but still.) The idea: “ich liebe es,” which translates to “I love it.” That September, McDonald’s debuted its campaign in Germany in recognition of the agency’s role.

Music, specifically hip-hop, was part of the package from the beginning. Heye worked with German music house Mona Davis Music. In 2004, Mona Davis president Tom Batoy told Adweek he got the inspiration for “ba da ba ba ba,” the campaign’s “audio logo,” when he heard an unnamed backup vocalist sing it in the studio. “Everybody can remember it,” he said at the time.

McDonald’s spent $1.37 billion on advertising the year of “I’m Lovin’ It,” according to AdAge, so it’s understandable that many people played a part. (Think of all the collaborators credited on today’s blockbuster albums like Beyoncé’s Lemonade.) But McDonald’s specifically named Mona Davis as leading “music development.” Batoy and his business partner Franco Tortora are consistently listed among the songwriters for the myriad versions of “I’m Lovin’ It” in the databases of ASCAP, BMI, and SESAC, organizations that track songwriting royalties.