Logic optoisolators with >10MHz bandwidths are commonly available. I've used the ACSL-4xx0 series
before, 15Mbaud rated. But yes, stock opto's are very slow photo-transistor outputs, not high-speed
photodiode+schmitt-trigger.
There are many others and there are also RF galvanic isolation devices like the ISO734x series, again
rated to 25Mbaud - these use a high voltage capacitor rather than an optical path to give isolation.