/* Reset */ * { margin: 0; padding: 0; box-sizing: border-box; } /* Header / Logo */ header { width: 100%; } .aboutus { display: flex; align-items: center; justify-content: center; min-height: 10vh; background: red; padding: 20px; } .aboutus .brand { text-decoration: none; } .example { background-color: transparent; } /* Navbar */ .navbar { background-color: #1f7837; display: flex; justify-content: center; flex-wrap: wrap; } .navbar a { color: white; font-weight: bold; text-decoration: none !important; text-transform: uppercase; padding: 14px 20px; font-size: 20px; } .navbar a:hover { background-color: yellow; color: black; } /* Toggle button for mobile */ #toggle { display: none; } .togglearea { background-color: #1f7837; border-bottom: 2px solid white; color: white; padding: 10px; display: flex; justify-content: flex-end; } .togglearea label { background-color: white; height: 45px; width: 50px; color: black; border-radius: 6px; cursor: pointer; display: flex; justify-content: center; align-items: center; flex-direction: column; } .togglearea label span { background-color: black; height: 4px; width: 70%; margin: 2px 0px; } .togglearea { display: none; } /* Mobile view styles */ @media screen and (max-width: 700px) { .navbar { flex-direction: column; align-items: center; /* Center text in mobile menu */ display: none; } #toggle:checked + .navbar { display: flex; } .togglearea { display: flex; } .navbar a { width: 100%; text-align: center; /* Center text */ padding: 14px 0; } } .brand { text-decoration: none; }