When Peyton Reed inherited the mantle of Ant-Man director from Edgar Wright, who left midway through the Marvel caper he’d scripted about a hero who shrinks to fantastical bug-sized proportions, the idea of the Quantum Realm had not yet touched paper. It was Reed and co-writer Adam McKay who thought to create for the screen a version of the alternate dimension where human concepts of space and time become irrelevant, opening a Pandora’s Box of reality-bending possibilities.

Now, three years and one cataclysmic shift in the Marvel Cinematic Universe later, their idea may hold the key to reversing the cruelest events of Avengers: Infinity War—or so heartbroken fans might hope.

Ant-Man and the Wasp, Reed’s sunny sequel to his 2015 superhero-origin-heist-story starring Paul Rudd, comes on the heels of the darkest entry in the Marvel canon yet. Thanos, that purple menace now armed with all-powerful abilities, has decimated the Avengers and pulverized half the universe, including marquee heroes like Spider-Man, Black Panther, and the Guardians of the Galaxy (minus poor Rocket).

The decidedly bouncier Ant-Man and the Wasp takes place in the same timeframe, focusing on Scott Lang (Rudd) and Hope van Dyne (Evangeline Lilly) as they scour the Quantum Realm in search of the original Wasp, Hope’s mother Janet (Michelle Pfeiffer). Still, it references Infinity War just once before its own cliffhanger ending, a shock at such odds with the film’s zippy tone that Reed sounds at once satisfied, relieved, and half-apologetic discussing it.

“Even when we started working on the script, we knew what the ending of Infinity War was going to be, and we knew that we were going to come after that movie,” Reed says by phone from Los Angeles. “We kept sort of talking around the issue like, well, if it does tie into Infinity War, is it little news items on the TVs in the background? That didn’t seem very interesting to us.”

Reconciling his own film’s effervescence with the gravitas of what Marvel audiences beheld just two months before, he says, proved a puzzle his team mostly coped with through avoidance, “kicking the problem down the road” until there was no road left: “As we got closer, we arrived at this structure that is in the final movie that really appealed to us, where we’re doing our movie and we do the tone of our movie” and then, suddenly, “it does something very differently.”

“ This whole thing where there’s a weird sense of entitlement that certain fans have about their ability to control the content of something in a weird way, or this thing where it’s like, ‘Star Wars is dudes, man, you can’t have women! You’ll ruin it!’ It’s so crazy to me. It’s OK to have a walrus creature or a robot, but not a woman? ”

The Quantum Realm bestowed an even trickier blessing/curse. “The good news was that we could make it anything we wanted and it was virtually infinite. But that was also the bad news because there’s so much to deal with,” Reed says. An idea as vast and vague as a space and time-warping microverse (and not the same one as in the comics) was complicated further by how the mechanics assigned to it in Ant-Man and the Wasp might reverberate post-Infinity War.

Before Thanos snapped his fingers, allusions to time vortexes and quantum entanglement might have stayed mostly in Ant-Man’s sandbox. (And Doctor Strange, whose portal-opening sling rings allow access to the Quantum Realm, too.) After Infinity War, they sound tantalizingly like tools with the potential to help undo the Mad Titan’s devastation. That’s a universe of pressure on ant-sized shoulders.

“We really had lots of discussions about how much this movie and this intimate story about family and this mission to rescue Hope’s mom, how much we get to stay in and tell that story,” Reed says of balancing his San Francisco-set sequel’s grounded stakes with the cosmic implications of what it reveals about the Quantum Realm. His team decided, he says, on exploring “just enough” of the dimension to propel the van Dynes’ search forward, while leaving “little hints of other stuff” for future Marvel movies to build on.

Audiences by now know to expect that they will. Ten years and 20 films in, the Marvel Cinematic Universe has woven an unprecedentedly consistent tapestry of shared details, histories, and characters, from the high fantasy of Asgard and the Guardians’ galactic domain, to the sociopolitical intrigue surrounding Captain America and Black Panther, to Peter Parker’s high school hijinks in Queens.

Ant-Man and the Wasp, however, adds a singular new thread, one whose omission has glared conspicuously from the tapestry for years: a female superhero with equal billing in the title.

The first Ant-Man saw Evangeline Lilly’s Hope van Dyne forced by her overprotective father (Michael Douglas’ Hank Pym) to train a far less competent male substitute to take over opportunities she wanted. It was frustrating—for Hope, and for fans hungry to see a Marvel film finally center a woman in her own story. (That Wasp, a founding member of the Avengers and the character who named the team in the comics, sacrificed herself and went missing in a flashback also stung.)

The sequel makes it up to Hope, at least: her father now sees her as an equal, both as a scientist and a hero, and she wields the Wasp suit confidently sans male interference. “It was really important for us in this movie to finally see her as a fully-formed, costumed hero,” Reed says. “I think for me, the great joy of this movie was working closely with Evangeline from the beginning, even before the screenplay, when we were talking about initial story and how we wanted to progress her character.”

Lilly, who performs many of her own stunts in the film, came armed with ideas “about how she saw that character and what she wanted to do and not do,” Reed recalls. “And it was everything from very minute details, like she was very vocal early on about, ‘I don’t want to be in a fight sequence and come out of it with beautiful hair and beautiful nails. I want to sweat when I fight and I want my hair in a very practical ponytail, because that’s the only way that helmet will go on and off.”

“And we really responded,” he adds. “I really liked that pragmatic, nuts-and-bolts approach to being a hero, where it wasn’t a guy’s vision of a female hero.”

There are those who prefer female heroes filtered through a male gaze, of course. Reed laughs recalling a Twitter user who took aim at the movie’s poster, writing (by all appearances non-ironically), “This is the future the liberals are planning for you. Women are men and men are women.” No one knows what, exactly, the user objects to, whether Hope’s position in front of Scott, her head-to-toe protective suit, or her existence itself—but its hysteric absurdity made it an irresistible meme. Reed still scratches his head over it.

“The first time I read that I was like, ‘Oh, this is a brilliant comedic conceit, that there’s a guy out there who is so offended by this notion.’ I really couldn’t believe it was real,” he says. “I mean, I know it’s ultimately not funny, but it’s like, shocking to me.”

A self-avowed “boilerplate nerd” for movies and comics growing up, Reed understands what it’s like to be a diehard fan. “But this whole thing where there’s a weird sense of entitlement that certain fans have about their ability to control the content of something in a weird way, or this thing where it’s like, ‘Star Wars is dudes, man, you can’t have women! You’ll ruin it!’ It’s so crazy to me. It’s OK to have a walrus creature or a robot, but not a woman?”

“The pinnacle to me is whoever the guy is who’s like, trying to get a petition to remake The Last Jedi, Rian Johnson’s movie. Rian and I had a laugh about that because it’s just so mental,” he adds. But outliers aside, he believes the majority of fans, particularly of Marvel movies, simply “want to see the world around them reflected. They want to see a reflection of reality and someone that speaks to them and their concerns and that it’s relatable, and that goes to gender and ethnicity and everything in between. That just feels logical and normal and right to me.”

Reed’s retort to the Twitter user doubled as a plug for his greatest hits: “Dude if this scares you, you should check out my cheerleader comedy or my Doris Day/Rock Hudson homage,” he quipped, referencing his ‘00s-classic breakout comedy Bring It On and his 2003 rom-com Down with Love. “Telling stories about women has been part of my moviemaking for a long time, so to see that this is a conflict for someone is just fundamentally weird to me,” he says now.

Romantic comedies helped inform the dynamic between Scott and Hope, too, whose partnership evolves more naturally now that both see each other as equals: “Stuff like Philadelphia Story and His Girl Friday and It Happened One Night,” he says. “Like the true old romantic comedies where female characters were incredibly well-written and there was mutual respect and the women largely drove the plot. That was something that was the go-to in the movie business for some time decades ago, so it shouldn’t be such a revelation.”

For a gag in which one character suddenly inhabits the body of Paul Rudd’s through quantum entanglement, Reed looked to a scene from 1984’s All of Me, in which Lily Tomlin’s character commandeers Steve Martin’s to perfect slapstick effect. “Because we have Paul Rudd, I mean, it was a big swing for this movie but it was like, this could be awesome,” he says. “We should do this and commit to it and make it real. And it’s really fun to see that with an audience now because it is so weird.”

No topic makes Reed nerd out harder, however, than the memory of working with his movie’s biggest get: Michelle Pfeiffer as Janet van Dyne, in the actress’s first superhero movie sojourn since her iconic turn as Catwoman in Batman Returns. A brief flashback in the first Ant-Man offered a fleeting glimpse of the original Wasp: round, expressive eyes behind a mask, ones that Reed asked casting director Sarah Halley Finn to approximate Pfeiffer’s, “never knowing whether we would actually be able to make a sequel to the movie, but just in case,” he says.

He met with Pfeiffer for the first time in a conference room at Marvel HQ: “Just the two of us, kind of talking to her about this world, these types of movies, and the legacy of this character in the comics and her role in this movie. And she really got into it,” he remembers. “She obviously played Catwoman but I didn’t know what her appetite would be for playing this type of character. And she really responded to the idea that this is a legacy Marvel hero and that the whole plot was really predicated on finding her.”

Reed tore through Pfeiffer’s “whole filmography” before working with her, elated: “I was thrilled because she’s Michelle Pfeiffer and I was thrilled because I had no backup plan whatsoever,” he laughs. Her screen time in the film is regrettably short, but Marvel might yet call for another sequel, and for more of Janet van Dyne.

Though of course, she and the rest of the Ant-verse will first have to make it out of next year’s Avengers 4 alive. Fingers (and antennas) crossed.