Two-layer design protects genes from mutations in their enhancers