0

I want to make my links in the navigation bar highlight and grow when you hover over them but it only changes color. I'm relatively new to coding so I don't know what to do. The transform scale property doesn't do anything and I can't find a way to fix it. If it helps I'm using Safari.

body {
    margin: 0;
    padding: 0;
    background: rgb(33, 33, 33);
}

nav {
    font-size: 0;
    display: inline-block;
    background: rgba(0, 0, 0, 0.4);
    width: 100%;
}

nav a {
    margin: 20px;
    font-size: 20px;
    text-align: center;
    text-decoration: none;
    text-transform: uppercase;
    color: rgb(212, 212, 212);
    line-height: 50px;
    transition: .5s;
} nav a:hover {
    transform:scale(1.5, 1.5);
    color: cyan;
}
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <link rel="stylesheet" href="style.css">
    <title>Test</title>
</head>
<header>
    <nav>
        <ul>
            <a href="#">Home</a>
            <a href="#">About us</a>
            <a href="#">Contact</a>
        </ul>
    </nav>
</header>
<body>
</body>
</html>
Josué
  • 1

0 Answers0