If motion relative to a frame of reference is purely relative, how do we account for the work done to move relative to the frame of reference? I get the idea that everything is in motion, and there's no absolute reference frame for everything.
But when we consider local events, like a train passing through a town, I have trouble accepting the notion that we have no principled way of asserting the perspective that the train is moving relative to the town over the perspective that it's the train that is stationary and it's the town (and the rest of the Earth) that is moving relative to the train.   The thing that to my mind privileges the perspective that it is the train that is moving is the history of the event, i.e., the fueling of the train, the starting  of the engine, the releasing of the brake, etc.
Are we saying that that work history, and the history and purpose of those who caused it to happen, could just as easily be said to have caused the town and the rest of the earth to move past the train, that that work history modified the earth's orbit just enough to create the illusion that the train moves past the town?
 A: As you point out, it's only your own knowledge of the fueling of the train, etc. that biases your perspective. Imagine for a moment that someone built a very large and elaborate treadmill for the train, so that the train really did stand still with respect to the earth, and that it was actually the landscape passing by instead. The equivalence principle tells us that all inertial frames are equivalent, so you have absolutely no means of telling whether you're on a fueled-up train that propels itself down the track, or a train filled with dummy coal that's on a treadmill with the landscape speeding by.
When you talk about the train accelerating, you now have a non-inertial reference frame, which is not equivalent to inertial frames. When the train starts moving and lurches forward, people on the train naturally take a step backwards to balance themselves. You can't treat this as equivalent to the rest of the world lurching backwards - you don't see people in the station balance themselves as the train leaves!
A: 
Are we saying that that work history, and the history and purpose of those who caused it to happen, could just as easily be said to have caused the town and the rest of the earth to move past the train, that that work history modified the earth's orbit just enough to create the illusion that the train moves past the town?

Yes, exactly. If you think about it, that should not be terribly surprising. After all, work, energy, and other physical principles simultaneously describe the town at rest and the train moving, as well as the sun at rest and the town moving (with the earth), as well as the galaxy at rest and the sun moving, ...
In one case the simplest frame is the one where the town is stationary, but in another case it is one where the sun is stationary. Both cases are equally valid. So if both of those cases are equally valid then it shouldn't be surprising that the case where the train is stationary is also valid.
There is no physical significance to the choice of reference frame. It is a mathematical convenience only. So we always should seek to choose the most convenient frame to work with, knowing that our choice has no physical significance.
A: No. The idea of relativity is that locally the laws of physics are always the same in an inertial (constant linear velocity) reference frame.   Meaning if you are in a sealed box with no access to the outside (Einstein used the example of an elevator), no experiment you can do will let you distinguish your state of motion.  In fact, the size of "local" might get very small, becoming an infinitesimal, in the presence of gravity gradients or other geometrically changing environments.
Your are correct that looking at the global environment and history of an object, one can establish a sensible idea of what is "really" moving.  But that is for our benefit.   The laws of physics do not care.
A: The principle of relativity says that the laws of physics on the train right now are exactly the same as on the station platform, and so there is no way to logically conclude from observations made right now that one is moving and the other is not. It says nothing about how they came to be in relative motion. Maybe the train started out from this station or another station an hour ago. Or maybe it has always been moving at the same speed relative to the station. We don’t know, and the laws of physics cannot tell us.
A: You are misunderstanding what it means to say that all motion is relative. Motion just means changes in positions and distances. If you say the train is moving at thirty miles per hour relative to the station, you mean that the gap between the station and the train is growing at thirty miles every hour. It doesn't matter whether you consider that the train is moving or that the station is- the gap is growing at the same rate either way.
When you say 'we have no way of knowing whether the train is moving relative to the town or the town is moving relative to the train', the reality is that by definition both are happening. 'The town is moving relative to the train' is perfectly correct- you are simply describing events from a particular frame of reference.
Yes, you know for sure that the train was formerly stationary with respect to the town and has been accelerated to its present speed, rather than the town having been accelerated to 30mph in the other direction. But so what? In the reference frame of a spaceship passing the Earth at 30mph, the train now seems to be stationary and the Earth is moving at 30mph the other way.
