It sounds like you already conceived of using planes to define arbitrarily shaped regions. It's not necessarily the most efficient method, but you can use them for collision detection. The planes can represent half-spaces, informally meaning that one half of space is on one side of the plane.
An axis-aligned bounding box is a specific case of using six halfspaces, two for each axis with opposite directions. If a point is on the positive side of all six planes, it is within the bounding box. If a point is on the wrong side of any plane, you immediately know it does not intersect the box, and you can skip further checks.
The same method can be used for an oriented bounding box (different plane normals) or for shapes other than rectangular prisms. Wikipedia calls them convex polytopes.
So for your purposes, you could use planes to define your diagonal walls. Planes are purple, your player is red.
If your player's position, projected onto the plane's normal vector (dot product), is less than the plane's distance from the origin in the direction of its normal (accounting for some radius of size of the player), then that player has not collided with the wall. If it exceeds that check value, then you know the distance and direction to push your player back out of collision.
Unforuntely, you don't get the early-exit benefit because you aren't using convex shapes, but you can still accomplish what you want.