Pressure-induced superconductivity was studied for a spin-ladder cuprate Sr$_2$Ca$_{12}$Cu$_{24}$O$_{41}$ using nuclear magnetic resonance (NMR) under pressures up to the optimal pressure 3.8 GPa. Pressure application leads to a transitional change from a spin-gapped state to a Fermi-liquid state at temperatures higher than $T_c$. The relaxation rate $1/T_1$ shows activated-type behavior at an onset pressure, whereas Korringa-like behavior becomes predominant at the optimal pressure, suggesting that an increase in the density of states (DOS) at the Fermi energy leads to enhancement of $T_c$. Nuclear quadrupole resonance (NQR) spectra suggest that pressure application causes transfer of holes from the chain to the ladder sites. The transfer of holes increases DOS below the optimal pressure. A dome-shaped $T_c$ versus pressure curve arises from naive balance between the transfer of holes and broadening of the band width.