Summer’s here. Along with barbecues, beach excursions and baseball games, that also means the arrival of a particularly unwelcome visitor—the mosquito.

But as we cringe, imagining the hordes of mosquitoes that will bother us shortly, we’ve also got to hand it to them—they’re remarkable hardy creatures, resisting all manner of sprays, repellents, candles and anything else we throw at them. And one of their most amazing abilities is that they can remain in flight in the midst of one of nature’s own attacks: a falling raindrop.

For a mosquito, getting hit with a raindrop is the equivalent of a human getting hit by a 3 ton object—something roughly the size of a pickup truck. An individual raindrop is about 50 times the mass of a mosquito, and the drops fall at speeds as fast as 22 miles per hour. Yet the tiny insects are able to survive countless collisions during the course of a storm, when these truck-sized hazards are plummeting all around them.

How do they do it? According to a study published earlier this week in the Proceedings of the National Academy of Sciences, it is the mosquito’s tiny size—along with a zen-like approach of passive resistance—that allows it to stay in flight despite these massive collisions.

Mosquitoes, it turns out, combine an extremely strong exoskeleton with a minuscule mass to minimize the force of each raindrop when it hits. The fact that they are so much lighter than the raindrops means that the drops lose very little momentum when they collide with the mosquitoes, which translates into very little force expelled onto the insect.

Additionally, instead of standing strong against the drops, or even trying to dodge them, mosquitoes simply go with the flow. ”As the raindrop falls, rather than resisting the raindrop, they basically join together kind of like a stowaway,” David Hu, an engineer at Georgia Tech and an author of the study, told NPR. “So as a result they get very, very little force.” The impact of the raindrop can knock the mosquito partly off course, but it doesn’t harm the insect nearly as much as it would if it were absorbed as a direct hit.

Moments after the mosquitoes latch on to the raindrops, they use their wings and long legs as miniature sails to lift themselves off the falling droplets before they crash into the ground, as shown in the video below. The main danger, the researchers found, is when mosquitoes are hit by raindrops when they are already close to the ground, because if they can’t dislodge in time, they’ll be slammed into the earth at the same speed as the falling drop.

How did the research group, led by Hu’s doctoral student Andrew Dickerson, figure out the mosquitoes’ strategy? ”Hitting a mosquito with a raindrop is a difficult experiment,” Hu said. “The first thing we did was drop small drops from the third floor story of our building onto a container of mosquitoes, and you can imagine that didn’t go very well. It’s kind of like playing the worst game of darts you can imagine.”

Eventually, the researchers brought the experiment inside, constructing an acrylic mesh cage to contain the mosquitoes that would also permit the entry of water drops.

They then hit the insects with tiny jets of water to simulate the velocity of falling raindrops, and filmed six Anopheles mosquitoes entering the water stream. They used a high-speed camera that captured 4000 frames per second (a typical video camera captures 24 frames per second). All six of the insects survived, and the footage—along with theoretical equations—allowed the scientists to better understand the insects’ remarkable ability to deal with rain.

The experiments were also conducted with an eye towards practical engineering. The design and construction of micro air vehicles (MAVs)—tiny robotic aircraft that could potentially be used for surveillance and other purposes—is progressing in labs around the world. The California company AeroVironment has developed a hummingbird-inspired micro aircraft that weighs less than a AA battery, and other companies and research labs are currently looking into making even smaller autonomous aircraft. Better understanding how natural life evolved to fly in the rain, the researchers note, might help us design our own tiny crafts to stay aloft in the elements as well.