I was in the car with a friend recently when she pulled up to a stoplight, picked up her phone and replied to a text. I gave her the side eye. What? she glared back. “I only use my phone when we’re stopped.”

“OK, fine,” I said. But, I wondered, is it?

We all know that it’s dangerous to text while driving, but our phones have become overlords that demand our constant attention. In the car, I limit my phone use to things I can do hands-free — talking and listening to preloaded playlists — and assumed this made me safer. But I may be fooling myself. Research has found that when it comes to distracted driving, what your eyes and hands are doing is only part of the issue — what your mind is doing is at least as crucial. Before you can reduce the risks of cellphone use while driving, you need to understand the nature of distraction itself.

You can think of driving’s demands as a three-legged stool, requiring eyes on the road, hands on the wheel (not to mention feet on the pedals), and mind on the task. Anything less than all three, and you’re driving impaired.

Most attempts to mitigate the risk of cellphone use while driving have focused on the first two legs. Texting while driving is banned in 47 states, and 16 states prohibit drivers from handheld phone use. But legislative approaches like these don’t address the third leg of the distraction stool. “You can’t do a drug test for cognitive impairment,” said Kyle Mathewson, an assistant professor of psychology at the University of Alberta.

Anything that takes the eyes off the road or hands off the wheel is clearly dangerous. A 2009 study funded by the U.S. Department of Transportation examined data on the behavior of more than 200 commercial motor vehicle operators and found that the riskiest tasks were those that drew drivers’ eyes away from the road. Texting was the worst. Truckers who texted while driving were 23.2 times more likely to have a crash, near-miss, unintentional lane deviation or other safety issue compared with when they weren’t texting. Texting was also the thing that drew eyes off the road for the longest time — 4.6 seconds in a 6-second interval, or the equivalent of driving the length of a football field at 55 mph.

But putting down the phone and talking only via a hands-free system in the car doesn’t necessarily solve the distraction problem, said David Strayer, a psychologist at the University of Utah. Strayer’s research has found that drivers can get a sort of “tunnel vision” when their minds are focused elsewhere. People can enter this state during a phone conversation, whether or not they’re holding a phone, Strayer said. “There’s something like 35 studies now trying to compare handheld to hands-free, and they find that you’re impaired with both,” he said. “There really isn’t a safety advantage to one over the other.” Strayer’s research testing volunteers in a driving simulator found that people drove more sluggishly and had delayed reaction times when talking on the phone. Although they were different from the impairments experienced by people in the study who drove in the simulator while legally drunk, they were just as dangerous.

But studies that test people in simulators seem to find greater risks from talking on the phone than studies based on real driving patterns using video cameras and recorders, said Brian Johnston, a professor of pediatrics at the University of Washington and former editor-in-chief of the journal Injury Prevention. For instance, the Transportation Department study of real-life trucker data found that talking or listening on a handheld phone didn’t increase the likelihood of being in a crash or having a serious safety issue.

Interestingly, talking seems to become less risky if the other person knows what’s going on in the car. Mathewson and his colleagues did an experiment with volunteers that compared four situations, all of which involved a simulator: someone driving alone, driving while talking on a hands-free phone system, driving while talking with a passenger who is also in the simulator, and driving while talking on the phone with a person who could view what the driver was seeing. When a conversation took place in an environment where both parties could see what was happening on the road, the speakers naturally adapted their conversations to the driving — initiating discussions about traffic conditions and naturally pausing the conversation at moments when the driver needed to pay extra attention to the road.

Today’s cars present their own menu of interruptions by putting an array of “electronics on steroids” at a driver’s fingertips, Strayer said. He recently examined a car that had 112 buttons for 117 different functions, and that didn’t include the touch screen. “Many features and functions enabled in a car while driving are too complex and mentally taxing,” he said. Voice-enabled apps can become a dangerous frustration when they bungle commands. Automations like cruise control, auto braking and blind-spot detection might seem like safety features, Mathewson said, but they can actually increase danger by making a driver less attentive and engaged.

So how to proceed in this age of distraction? “I think that it’s kind of unreasonable to say you can’t use technology,” Strayer said. Some diversions appear to be more dangerous than others. “We’re not too worried about listening to the radio or a book on tape or a podcast,” Strayer said. On long, monotonous drives, a little bit of mental engagement may even prevent your mind from wandering off the driving task.

Before you start rolling, prepare yourself to drive safely, said Lisa Robinson, a senior program manager for the National Safety Council, a nonprofit advocacy group. Adjust the mirrors and seat and set the radio dials and navigation system. Never attempt to enter navigation while moving, she said. Even if you’re entering information hands-free, the amount of cognitive focus required will steal too much attention from your driving. If you need to scroll or type on your device, pull over.

And for the life of the people around you (and yourself), turn off your phone notifications. “We know that when that ping comes, you will want to answer that phone,” Robinson said. The best way to resist the temptation is to prevent it. Both iPhones and Android devices have modes that will turn off notifications while you’re driving. (They’ll also notify senders that you are driving and provide instructions on how to override the setting in an emergency.)

The seriousness of device distractions shouldn’t be overlooked. Strayer’s research has shown what he calls a “technology hangover.” After hanging up the phone, “it takes up to 27 seconds to regain what you lost while interacting with the technology,” he said. “It was an eye-opener.”

Which brings us back to my friend’s rule about texting only at stoplights. Sure, that’s safer than texting while in motion, but it’s still an impaired way to operate. Consider: While your eyes and hands are on the phone, you’re missing the changes happening in your surroundings — the pedestrian who just entered the crosswalk, the cyclist who pulled up next to you. If you look up and the light has changed, you don’t have time to fully update your situational awareness. Putting the car in motion in that state is like shooting a gun before being sure of your target, and the results can be just as deadly.

“Driving is the most likely way we’ll kill someone else,” Mathewson said. “But we’re not treating cars like the dangerous things that they are.”

Read more: “How To Break Your Phone Addiction”