Rotate Matrix Over Diagonals
tomtom's note: Feel free to check out the source image below for the original problem statement :)
Imagine you have a beautiful square matrix and a number, turns. Your mission is to gracefully rotate this matrix turns times "over its diagonals," creating a new, enchanting pattern with each rotation. After you've completed the rotations, you'll return the transformed matrix, now dressed in its new, elegant arrangement. 🌟
The elements along the two main diagonals remain beautifully in place, untouched by the rotation. However, the four sections formed by these diagonals gracefully swap positions in a clockwise dance. With each rotation, these segments move to their new spots, creating a fresh, charming pattern. Take a look at the images below to see this elegant transformation in action! 🌼
ദ്ദി(˵ •̀ ᴗ - ˵ ) ✧ Credit to robot ༊࿐ ͎. 。˚ ° ˚🧡.
1Example 1

Constraints
Limits and guarantees your solution can rely on.
🐰