現在マウスオーバーでナビゲーションバーの要素を大きくしようとしています。しかし、マウスオーバーするとウェブサイトの残りの部分が少し動いているので、ひどいです。 ウェブサイトの他の要素に影響を与えずにナビゲーションバーのテキストを大きくする方法はありますか?マージンを持たないホバリングサイズのCSS
nav {
text-align:center;
margin-top: 20px;
margin-bottom: -4px;
}
.nav{
text-decoration: none;
color: black;
text-transform:uppercase;
font-weight: 600;
padding: 5px;
font-family: calibri;
padding-top: 2px;
transition-property: all;
transition-duration: 500ms;
}
.nav:hover {
font-size: 130%;
opacity: 0.6;
}
.LLHashtag {
width: 370px;
margin: 0 Auto;
text-align: center;
text-decoration: none;
margin-top: 5px;
font-size: 50px;
text-transform:uppercase;
font-weight: 600;
color: black;
border-top: solid black 2px;
font-family: "helvetica Neue";
font-weight: 400;
}
<nav>
<a class="nav" href="http://www.google.de">Home</a>
<a class="nav" href="http://www.google.de">Über</a>
<a class="nav" href="http://www.google.de">Motivation</a>
<a class="nav" href="http://www.google.de">Kontakt</a>
<a class="nav" href="http://www.google.de">Impressum</a>
</nav>
<h1 class="LLHashtag">#LifeLetics</h1>
コードを添付してください。 –
あなたのコードを最初に投稿してください –
あなたのコードを添付してください。 –