Quadrature error estimates for layer potentials evaluated near curved surfaces in three dimensions