I'm really not sure you asked the right question.
This question has 2 parts.
1:
But here is an example that I think you need:

enter link description here
As you can see, we have 2 vector: Curve Normal
and Curve Tangent
.
Math side of this problem: Matrix. For build correct euler rotation vector, first have to build matrix. This not so correct, but it clear.
Idea: Cross production of 2 vector is other one, perpendicular vector.
Now, is combine 3 parallel vector in one object, we have matrix.
Matrix can be reinterpreted in to euler rotation vector.
- Right now you can skip matrix part in geometry nodes by using
Align Euler to Vector
. If imagine: this node create serphase, what normal is inputting vector. Theoretically, now you can get random rotation from this surface. But this no make sense. We can get only one random rotation to point on this surface.
- Now another one
Align Euler to Vector
rotate previous euler rotation (attached to new surface) for align to new normal what is Curve Normal
.
This step finalize mathix by 2 vector, but virtually, we work only with surfaces, normals and rotations.
But as result, we get full rotation matrix, builded in euler rotation vector.
- Last one step. Random rotation, if convert it to rotation matrix, we can multiply it on other matrix, that can be other rotation matrix is.
You can avoid matrix on this step by
Rotate Euler
node.
If write this as math formular:
Curve Basis = {Curve Normal, Curve Normal * Curve Tangent, Curve Tangetn};
Other Matrix (Rangeom intances rotation euler vector) -> to matrix;
New one = Curve Basis * Other Matrix;
Rotation = New one -> as euler;
Not yet:
- Patrionally this task will be solved, if Jacques Lucke (Geometry Node dev) will add
Axis to Euler
node (that just combine first two steps).

- Or if Lukas Toenne finished
nodes-matrix-types
branch
2:
The rotation of the curve implies a complete change in its position. Unlike default attributes, normal and tangent are parametric. And the calculation happens at the moment you need the attribute.
That is, if you rotate your geometry, the parametric attributes will be calculated according to the new state. This means that the parametric normal will be calculated differently. And under certain conditions, it will look like excessive rotation.
Since you are not deforming the curve, but transforming it (by multiplying by the matrix in theory), then in order to be able to capture the normal before the transformation, during the transformation, the normal must also be rotated (multiplied by the matrix of the new space). Just like any other vector. But the parametric normal is the only thing that changes in this case.
Fixed your example file
At last, will be more simple, if instansing all elements at first, and after this just use Transform Geometry
(or make it to be another instane and transfome this)