Let’s face it, Isaiah was not thinking about Jesus when he spoke these words to King Ahaz. His focus was on a baby to be born very soon, not hundreds of years later, and he’s assuring Ahaz that the military threat he’s worried about is going to evaporate before this kid is old enough to know right from wrong. And that’s what happened. The military threat did evaporate in just a few years. That’s why this kid is appropriately named, God-is-with-us (“Immanuel”).
Also, the Hebrew says the mother is a young woman, not that she’s a virgin (as the old translations have it). She may have been Isaiah‘s wife, or maybe Ahaz’.
Centuries later, when Greek-speaking Jews translated Isaiah into Greek, they did use the Greek word for virgin, and that’s the version Matthew quotes to help explain why Mary’s scandalously unwed pregnancy is nevertheless holy. Why? Because it’s God’s doing.
Mary’s pregnancy still breaks all the rules of decent behavior. But the ultimate rule-breaker here is the Holy Spirit. When the reconciliation of all things is at stake, God will go to indecent, scandalous lengths to get it to happen. That’s why all the women mentioned in Matthew’s genealogy (1:1-16) got pregnant under scandalous circumstances. What they and Mary did broke the rules, even Biblical rules. But they did good! What they did was holy.
People today get stuck debating the biological details of Mary‘s pregnancy. I’m pretty convinced that the writers of Matthew and Luke did believe that Mary’s pregnancy did not involve a man. (They are, incidentally, the only New Testament writers to mention Mary‘s virginity.) They also believed that we live under a giant, solid dome with Heaven above the dome and Hades (the abode of the dead) beneath our feet. So if they were mistaken about these cosmological details (as they obviously were), it’s OK if you think that they were mistaken about these biological details.
But the more important point they are making is not about what Mary’s pregnancy did not involve but what it did—the holy, rule-breaking reconciliation of God, God-is-with-us, Immanuel.