  We study superconductivity in isolated superconducting nano-cubes and
nano-squares of size $L$ in the limit of negligible disorder, $\delta/\Delta_0
\ll 1$ and $k_F L \gg 1$ for which mean-field theory and semiclassical
techniques are applicable, with $k_F$ the Fermi wave vector, $\delta$ the mean
level spacing and $\Delta_0$ the bulk gap. By using periodic orbit theory and
number theory we find explicit analytical expressions for the size dependence
of the superconducting order parameter. Our formalism takes into account
contributions from both the spectral density and the interaction matrix
elements in a basis of one-body eigenstates. The leading size dependence of the
energy gap in three dimensions seems to be universal as it agrees with the
result for chaotic grains. In the region of parameters corresponding to
conventional metallic superconductors, and for sizes $L \gtrsim 10$nm, the
contribution to the superconducting gap from the matrix elements is substantial
($\sim 20\%$). Deviations from the bulk limit are still clearly observed even
for comparatively large grains $L \sim 50$nm. These analytical results are in
excellent agreement with the numerical solution of the mean-field gap equation.
