Light changes direction when it changes speed. Snell's law is the geometry of that statement, and it can be derived without knowing anything about light at all.
All ladders