Ich brauche Hilfe mit diesem, ich bin nicht ganz sicher, wie ich mein Problem in Worten zu erklären, also hier ist ein Bild. this is what it looks likeText vertikal mit Flexbox zentrieren, Ergebnis nicht erstellen Ich möchte
this is what I want it to look like (from another website) Nicht Stil alle, nur die Zentrierung.
Ich möchte, dass meine Links wie folgt zentriert werden: ÜBER SPENCER HILTBRAND DIENSTLEISTUNGEN KONTAKT
Heres mein CSS
/* Navigation */
.navigation {
background: #fff;
width: 100%;
height: 156px;
display: flex;
align-items: center;
justify-content: center;
box-shadow: 1px 1px 15px rgba(0, 0, 0, 0.5);
}
.nav-item {
text-decoration: none !important;
font-size: 35px;
text-transform: uppercase;
transition: 0.3s color;
padding: 20px;
}
HTML-Struktur:
<!-- Header -->
<div class="container">
<nav class="navigation">
<ul>
<a class="nav-item">Home</a>
<a class="nav-item">About</a>
<a class="brand"><i class="orange">Spencer</i> Hiltbrand</a>
<a class="nav-item">Services</a>
<a class="nav-item">Contact</a>
</ul>
</nav>
</div>
Hallo Spencer - Willkommen Überlauf Stack! Es ist hilfreich, wenn wir das Problem reproduzieren können, das Sie haben. Bitte posten Sie Ihre HTML und CSS. Hier ein paar Tipps: http://stackoverflow.com/help/how-to-ask –
ein 'margin: auto;' on '.nav-item' würde tun, wenn sie direkt Kind von' .navigation' sind ... zu viel Flex stört Flex :) –
@GCyrillus Lies mein Update, vielleicht hilft es dir besser zu verstehen, dein Vorschlag hat nicht funktioniert. –