And how Kurt Cobain became an unlikely inspiration.

In the ten years since The Lightning Thief first hit shelves, author Rick Riordan has crafted an entire middle-grade literary universe out of Greek mythology. After Percy Jackson finally defeated the evil titan Kronos and his host of Greek monsters, Riordan started playing with Roman mythology (in the Heroes of Olympus series) and moved onto Egyptian mythology (with The Kane Chronicles).

Now, with The Sword of Summer, Riordan kickstarts a new series, Magnus Chase and the Gods of Asgard. As the title suggests, the author is now applying his signature blend of witty teen protagonists and mythic reinvention to the Norse sagas. Although Magnus Chase narrates his adventures in first-person just like Percy, he’s a little rough around the edges. (When we first meet Magnus, he’s living homeless on the streets of Boston.) With more vibrant supporting characters and the generally more violent tone of Norse myths, Magnus Chase manages to stand out from its predecessors while still providing the same beats Riordan’s fans love.

EW caught up with Riordan before the Sword of Summer launch event at Symphony Space in New York last week to talk about the challenges both of adapting Norse myths and differentiating them from his earlier work.

ENTERTAINMENT WEEKLY: The tone of Magnus is very similar to Percy but he still seems like he has his own personality. How do you differentiate your protagonists?

RICK RIORDAN: Yeah I worried about that because I’m going back to the first person narrator like I did with Percy Jackson, and a lot of the structures of the myths are very similar. I did want Magnus to be his own person with his own voice. I just decided that I wasn’t going to stress about it if I could avoid it. So I let Magnus kind of tell me what his story was. I knew he was homeless, I knew he was 16, so he’s older than Percy. His background is a little rougher. He’s had some really hard knocks in life. He does have that sarcastic edge like Percy but he’s a little grittier. He’s a little more cynical about life.

How did you go about tackling that teen homelessness issue and balancing it with your light-hearted tone?

I think any time you tackle a really difficult subject, that‘s probably the time you need humor the most because it’s kind of a leavening agent. It keeps things from getting unwieldy and just so serious that it’s hard to kind of take.

I have taught homeless kids in the past so I pulled on what I knew about what that was like for them and how difficult that made their day to day life. Coming to school and you don’t have you homework done, that’s one problem if you live in a middle-class household, it’s an entirely other thing if you’re living in a car with your dad, like some of my students were. I kind of pulled on that. It’s such a huge problem in Boston especially. I was reading a lot of articles about homelessness in Boston, the stories of some of the kids who are trying to struggle through. It struck me that Magnus might put a face to some of that.

What were lessons you learned from earlier books that you applied to this one?

Well I like to hope that I’m learning lessons. We all hope we’re getting better at what we do. I cut my teeth writing private eye novels for adults. That taught me a lot about the wisecracking first-person narrator. It taught me a lot about plotting and clues and the mystery elements. Percy Jackson came from my experience being a middle school teacher. That taught me what kids like, what they relate to, what they find funny. I think as the books go along, I hope that I’m fine-tuning my style, my narrative format that works best for the readers. After a certain point too they sort of expect, if they pick up a book by me, it’ll have certain things in it. It’ll have the action, it’ll have the page-turning, it’ll have the humor. Fortunately that’s the stuff I like too, so I’m happy to do that.

What were the unique challenges of adapting Norse myths versus Greek and Egyptian?

The Norse myths are a lot more gruesome. They have a lot of blood and violence. I mean Valhalla is basically about killing each other all the time every day. So turning that into a funny scene for kids was definitely a challenge. The first big battle they have in Valhalla, I had to struggle with, how do I present this accurately but also in a way that’s not completely terrifying?

There’s so many ridiculous things that happen in Norse myths, kids just regard that the way they regard everything they find stupid in the adult world.

I think that just sort of reinforces what kids expect anyway, that the world is kind of absurd. That just ties into that. Absolutely, mead comes from a magical goat that lives in a tree – sure, why not? We certainly have things that ridiculous in real life. And I think the Vikings themselves played a lot of that for humor too. I don’t think they necessarily took it all at face value.

Were there any particular Norse gods or monsters you were excited about?

Loki is great. The trick there was stepping way from [Loki in the Marvel Cinematic Universe] Tom Hiddleston , who is wonderful and does a fantastic job, but I wanted to get back more to the roots of what Loki was like in the myth. As far as monsters, Fenris Wolf has always just scared the bejeesus out of me. He’s a pretty amazing monster.

I like your portrayal of him. It’s not that he’s a huge wolf but he’s got that silver-tongued devil going on.

Yes, it’s not really the size, it’s the wiliness, the clever way he can convince you basically to slit your own throat.

You even joke about Loki and Thor in the Avengers movies.

What I figured is you can’t avoid them so you might as well confront them and just sort of make a joke about them.

Speaking of Loki, one of my favorite characters in the book is Sam, or Samirah Al-Abbas. I think she’s a great example of a diverse character — not a white man, not a woman who’s there to be a love interest. She’s also seamlessly woven into the history of this myth. Can you talk about the conception of her character?

The idea for her started with the primary sources. The story that Sam tells in The Sword of Summer about an ambassador from the Caliph of Baghdad visiting the Vikings in Russia – that’s true. It really is one of our best sources because the Arabs of the time were reading and writing when nobody else was. That connection back then – that the world was a whole lot more connected even back then than we think of, that these cultures did not exist in these hermetically-sealed little bags, they were blending together all the time – that fascinated me. I thought, what would it be like to have a modern Muslim-American character who still had that connection to the Viking world like the Caliph of Baghdad did all those years ago?

And then again I started pulling on stories from students I’ve had in the past. One very powerful memory I have was being in my American history classroom on 9/11 and one of my students was a Muslim-American girl. She burst into tears when she heard the news, because she knew that her world, her life, had just changed, and had been defined for her in a way that she did not want and could only do so much to control. That really was powerful for me, and it inspired me to learn a lot about Islam and what the tradition actually was, as compared to what we hear about in the media and how it’s often distorted, and to honor her experience. Samirah kind of came out of that confluence of things.

Another thing that’s interesting about the Norse myth is this concept of Ragnarok. ;How did you tackle that? Is that a unique thing to Norse mythology?

I think it is. That level of knowledge that you’re doomed and this is exactly how you’re doomed…yes there is some of that in Greek myths of course. There are prophecies and people try to get around them. But in the Norse myths, everybody accepts that’s the way it’s going to be. It was tricky. How do you make the dramatic tension if you know the ending? Loki has a line in there where he says, “Well what you do is change the details. That’s how you rebel. That’s how you change the narrative. I know how I’m going to die, but between now and then I’m going to make my own game.”

I was carrying this book around the office for a few weeks and everyone who saw the cover said the same thing, that Magnus looks like Kurt Cobain. Was that intentional?

It is intentional. Not to the level that I expected it to necessarily be front and center like that, but that came from a comment in the book where Magnus’ mom used to tease him because he looks like Kurt Cobain. When the illustrator John Rocco read that, he kind of ran with it and he put it on the cover. I’m not gonna complain, because that is what I think he looks like. But yeah, it’s funny because some people were saying, “Oh, no one knows who that is anymore anyway, they won’t notice.” Yeah, they noticed.

One thing that connects Magnus to Percy is they both have strong relationships with their moms, which is interesting because so much of myth is based on patriarchy and who your father is. Did that come out of your own experience?

Yeah that’s true, I’ve always been close to my mom. She’s a real strong figure in my life. She’s a very artistic person, very supportive of me doing creative things. That is probably where that comes from. And of course with kids lit, there’s always the thing about the absent parent. There’s always some sort of device that takes the parents out of the equation, because the kid has to come into their own.

Annabeth Chase shows up and is related to Magnus. How much you can tease for future plans for that? Are you building to an Avengers of YA mythologies?

That would be really fun. Whether I will ever get to that point I don’t know. I do very much enjoy the model where worlds are parallel, that they are happening concurrently. I love the idea that a character from one book series can pop up in another one, and there can be crossovers from time to time. Because these mythologies did exist side by side so it makes sense for me that the modern versions would also exist side by side. And yeah, Annabeth will be in the series. She does have a role to play. It’s not huge, but it’s also not superfluous. You’ll see her again.