A square and a rectangle have the same area. One side of the rectangle is 5 cm more than the other. The perimeter of the rectangle is 26 cm. Find the length of the side of the square.