About a month ago my micro sd card completely crapped out on me. I don't quite understand why, I can think of only one of 2 things that had happened, I ejected the card from computer without right clicking eject, however this is a practice I've been doing for years, and I never had anything just stop working entirely because of it. And the only other thing I can think of was that I was particularly sweaty that night when I was moving it from the computer to the 3DS and its possible the sweat infiltrated the contacts. I mean I can't imagine that would destroy a microsd card, but it completely stopped working, whether I put it in my 3DS, my computer, or my phone, it just died. After about a year and half of service. Doesn't sound like the same issue as your card still works in other places than the 3DS, but I guess my point is, from first hand experience, treat your sd cards (micro or otherwise) well, be sure to take the extra time to properly eject it and try not to get it dirty. I was careless with mine and it cost me my micro sd card (and a lot of time building back up my library with the missing games (it had been a long time since I had made a backup of the sd card)), but next time it could be something worse. Also make backups regularly people, if you have a lot of content anyway.
The one silver-lining to it all, I only just the other day replaced the Micro SD card, meaning I wasn't playing my A9LH 3DS in all that time, and when Pokemon Sun and Moon leaked I would have downloaded it right away, and I likely would then in turn have ended up getting banned from online on my 3DS entirely. So my folly may have saved my ability to keep playing online on my 3DS, so its not all bad haha.