7 rectangles can be divided into $n$ identical squares, and it can also be divided into $n+76$ identical squares, find the value of the positive integer $n$.

---

Note: The translation keeps the original format and line breaks as requested. However, the phrase "7-个长方形" is translated as "7 rectangles" for clarity in English, assuming it refers to 7 rectangles. If it refers to a single rectangle, the correct translation would be "A rectangle can be divided into $n$ identical squares...". Please clarify if needed.
7. Let the side length of the squares when divided into $n$ squares be $x$, and the side length when divided into $n+76$ squares be $y$, then
$$n x^{2}=(n+76) y^{2}$$

Since both divisions are performed on the same rectangle, $\frac{x}{y}$ is a rational number (this can be seen by considering one side of the rectangle), thus $\frac{n+76}{n}=\left(\frac{x}{y}\right)^{2}$ is the square of a rational number. Therefore, we can set
$$n=k a^{2}, n+76=k b^{2}$$

where $k$, $a$, and $b$ are all positive integers. Consequently,

that is
$$\begin{array}{c}
k\left(b^{2}-a^{2}\right)=76 \\
k(b-a)(b+a)=76=2^{2} \times 19
\end{array}$$

Noting that $b-a$ and $b+a$ have the same parity, we have
$$(k, b-a, b+a)=(1,2,38),(4,1,19)$$

which gives
$$(k, a, b)=(1,18,20),(4,9,10)$$

The resulting $n$ is 324 in both cases. Therefore, $n=324$.