Competing superconductivity and charge-density wave in Kagome metal CsV3Sb5: evidence from their evolutions with sample thickness