I am working on a ul that contains several list items comprised of h3s and lis with the "close" class.
When I hover, I want to expand the letter spacing on the h3s, but the items with the close class also expand. I have tried using nth child selectors in the code without success. I would like the close classed lis to remain the same size when the h3s are expanded.
Any assistance on this issue would be greatly appreciated.
To view the code, visit: https://jsfiddle.net/snowwhyte/7eLmarnp/7/#&togetherjs=Uq5j49dUG0
CSS:
a {text-decoration:none;
}
li {list-style:none;
}
}
#openClose {
position:absolute;
top:200px;
margin-top:55px;
}
#openClose li{
list-style-type:none;
display:block;
padding-right:-50px;
}
#openClose li:nth-child(2n+2){
margin:30px 0 100px 0;
background-color:#000;
border:2px #fff solid;
text-align:center;
letter-spacing:1rem;
padding:10px 0 10px 0;
}
#openClose li:nth-child(2n+2):hover{
letter-spacing:-0.1rem;
transition:.3s;
}
#openClose li a h3{
font-family:Helvetica, Gotham, Helvetica, Arial, sans-serif;
color:#73a6c2;
}
.close{
}
#openClose li a h3:hover{color:#fff;
text-shadow:2px 1px 2px #000;
transition:.2s;
letter-spacing:1rem;
}
a:visited { text-decoration: none; color:#B8CEDB; }
a:hover { text-decoration: none; color:#D7D8D8; }
a:focus { text-decoration: none; color:#fff;
}
HTML:
<section id="openClose">
<ul>
<li><a href="#wrapper"><h3>Tool Descriptions</h3></a></li>
<li class="close"><a href="#">Close</a></li>
<li><a href="#wrapper2"><h3>Key tools</h3></a></li>
<li class="close"><a href="#">Close</a></li>
<li><a href="#wrapper3"><h3>Adjustment Layers & <br>
Blending modes</h3></a></li>
<li class="close"><a href="#">Close</a></li>
</ul></section>