fix: Navbar-Layout in index.html korrigiert und Skip-Link entfernt
parent
5111f84ade
commit
61d9208578
233
index.html
233
index.html
|
|
@ -10,9 +10,6 @@
|
||||||
/>
|
/>
|
||||||
<title>Ernährung · Tri-hub</title>
|
<title>Ernährung · Tri-hub</title>
|
||||||
|
|
||||||
<!-- Bestehende Tri-hub CSS als Basis -->
|
|
||||||
<link rel="stylesheet" href="/src/styles/navigation.css" />
|
|
||||||
|
|
||||||
<!-- Neue Typografie für diese Unterseite -->
|
<!-- Neue Typografie für diese Unterseite -->
|
||||||
<link rel="preconnect" href="https://fonts.googleapis.com" />
|
<link rel="preconnect" href="https://fonts.googleapis.com" />
|
||||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
|
||||||
|
|
@ -151,236 +148,6 @@
|
||||||
background: rgba(16, 185, 129, 0.14);
|
background: rgba(16, 185, 129, 0.14);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ===== Navigationsleiste ===== */
|
|
||||||
.skip-link {
|
|
||||||
position: absolute;
|
|
||||||
top: -100px;
|
|
||||||
left: 16px;
|
|
||||||
z-index: 100;
|
|
||||||
padding: 10px 16px;
|
|
||||||
border-radius: 8px;
|
|
||||||
background: var(--green);
|
|
||||||
color: #04150e;
|
|
||||||
font-weight: 700;
|
|
||||||
}
|
|
||||||
|
|
||||||
.skip-link:focus {
|
|
||||||
top: 12px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar {
|
|
||||||
position: sticky;
|
|
||||||
top: 0;
|
|
||||||
z-index: 50;
|
|
||||||
border-bottom: 1px solid rgba(248, 250, 252, 0.08);
|
|
||||||
background: rgba(13, 13, 26, 0.84);
|
|
||||||
backdrop-filter: blur(18px);
|
|
||||||
-webkit-backdrop-filter: blur(18px);
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__inner {
|
|
||||||
position: relative;
|
|
||||||
width: min(var(--max), calc(100% - 40px));
|
|
||||||
min-height: 76px;
|
|
||||||
margin: 0 auto;
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
justify-content: space-between;
|
|
||||||
gap: 24px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__brand {
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
gap: 12px;
|
|
||||||
min-width: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__logo-img {
|
|
||||||
width: 40px;
|
|
||||||
height: 40px;
|
|
||||||
flex: none;
|
|
||||||
object-fit: contain;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__brand-text {
|
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
line-height: 1.2;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__brand-title {
|
|
||||||
color: var(--white);
|
|
||||||
font-size: 1.15rem;
|
|
||||||
font-weight: 700;
|
|
||||||
letter-spacing: 0.04em;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__brand-tagline {
|
|
||||||
color: var(--muted);
|
|
||||||
font-size: 0.72rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__toggle {
|
|
||||||
display: none;
|
|
||||||
width: 44px;
|
|
||||||
height: 44px;
|
|
||||||
padding: 0;
|
|
||||||
border: 1px solid var(--line);
|
|
||||||
border-radius: 10px;
|
|
||||||
background: transparent;
|
|
||||||
color: var(--white);
|
|
||||||
cursor: pointer;
|
|
||||||
align-items: center;
|
|
||||||
justify-content: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__toggle-icon,
|
|
||||||
.navbar__toggle-icon::before,
|
|
||||||
.navbar__toggle-icon::after {
|
|
||||||
display: block;
|
|
||||||
width: 20px;
|
|
||||||
height: 2px;
|
|
||||||
border-radius: 2px;
|
|
||||||
background: currentColor;
|
|
||||||
transition:
|
|
||||||
transform 0.2s ease,
|
|
||||||
opacity 0.2s ease;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__toggle-icon {
|
|
||||||
position: relative;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__toggle-icon::before,
|
|
||||||
.navbar__toggle-icon::after {
|
|
||||||
content: "";
|
|
||||||
position: absolute;
|
|
||||||
left: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__toggle-icon::before {
|
|
||||||
top: -6px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__toggle-icon::after {
|
|
||||||
top: 6px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__toggle[aria-expanded="true"] .navbar__toggle-icon {
|
|
||||||
background: transparent;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__toggle[aria-expanded="true"] .navbar__toggle-icon::before {
|
|
||||||
transform: translateY(6px) rotate(45deg);
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__toggle[aria-expanded="true"] .navbar__toggle-icon::after {
|
|
||||||
transform: translateY(-6px) rotate(-45deg);
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__menu {
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
gap: 22px;
|
|
||||||
margin: 0;
|
|
||||||
padding: 0;
|
|
||||||
list-style: none;
|
|
||||||
color: var(--muted);
|
|
||||||
font-size: 0.9rem;
|
|
||||||
font-weight: 500;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__link {
|
|
||||||
display: inline-flex;
|
|
||||||
align-items: center;
|
|
||||||
gap: 6px;
|
|
||||||
transition: color 0.2s ease;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__link:hover,
|
|
||||||
.navbar__link[aria-current="page"] {
|
|
||||||
color: var(--white);
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__link--home {
|
|
||||||
padding: 9px 14px;
|
|
||||||
border: 1px solid rgba(16, 185, 129, 0.42);
|
|
||||||
border-radius: 999px;
|
|
||||||
color: var(--white);
|
|
||||||
background: rgba(16, 185, 129, 0.07);
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__link--home:hover {
|
|
||||||
background: rgba(16, 185, 129, 0.14);
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__home-icon {
|
|
||||||
display: inline-flex;
|
|
||||||
width: 18px;
|
|
||||||
height: 18px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__home-icon svg {
|
|
||||||
width: 100%;
|
|
||||||
height: 100%;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar a:focus-visible,
|
|
||||||
.navbar__toggle:focus-visible {
|
|
||||||
outline: 2px solid var(--green);
|
|
||||||
outline-offset: 3px;
|
|
||||||
}
|
|
||||||
|
|
||||||
@media (max-width: 1024px) {
|
|
||||||
.navbar__toggle {
|
|
||||||
display: inline-flex;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__nav {
|
|
||||||
position: absolute;
|
|
||||||
top: 100%;
|
|
||||||
right: 0;
|
|
||||||
left: 0;
|
|
||||||
display: none;
|
|
||||||
padding: 12px 0 20px;
|
|
||||||
border-bottom: 1px solid var(--line);
|
|
||||||
background: rgba(13, 13, 26, 0.97);
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__nav.is-open {
|
|
||||||
display: block;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__menu {
|
|
||||||
flex-direction: column;
|
|
||||||
align-items: stretch;
|
|
||||||
gap: 4px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__link {
|
|
||||||
display: flex;
|
|
||||||
padding: 12px 4px;
|
|
||||||
font-size: 1rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__link--home {
|
|
||||||
justify-content: center;
|
|
||||||
margin-top: 8px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@media (max-width: 600px) {
|
|
||||||
.navbar__inner {
|
|
||||||
width: min(var(--max), calc(100% - 28px));
|
|
||||||
min-height: 68px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar__brand-tagline {
|
|
||||||
display: none;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.container {
|
.container {
|
||||||
width: min(var(--max), calc(100% - 40px));
|
width: min(var(--max), calc(100% - 40px));
|
||||||
margin: 0 auto;
|
margin: 0 auto;
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,10 @@
|
||||||
<a href="#main-content" class="skip-link">Zum Hauptinhalt springen</a>
|
|
||||||
|
|
||||||
<header class="navbar" id="site-navbar">
|
<header class="navbar" id="site-navbar">
|
||||||
<div class="navbar__inner">
|
<div class="navbar__inner">
|
||||||
<div class="navbar__brand">
|
<a
|
||||||
|
href="#main-content"
|
||||||
|
class="navbar__brand"
|
||||||
|
aria-label="Zum Hauptinhalt springen"
|
||||||
|
>
|
||||||
<img src="/images/logo.png" alt="" class="navbar__logo-img" />
|
<img src="/images/logo.png" alt="" class="navbar__logo-img" />
|
||||||
<span class="navbar__brand-text">
|
<span class="navbar__brand-text">
|
||||||
<span class="navbar__brand-title">TRI-HUB</span>
|
<span class="navbar__brand-title">TRI-HUB</span>
|
||||||
|
|
@ -10,7 +12,7 @@
|
||||||
>Ernährungsberatung für Triathleten ab 50</span
|
>Ernährungsberatung für Triathleten ab 50</span
|
||||||
>
|
>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</a>
|
||||||
|
|
||||||
<button
|
<button
|
||||||
class="navbar__toggle"
|
class="navbar__toggle"
|
||||||
|
|
@ -34,14 +36,14 @@
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a
|
<a
|
||||||
href="/src/design/tri-hub-ernaehrungsberatung.html"
|
href="/index.html"
|
||||||
class="navbar__link"
|
class="navbar__link"
|
||||||
>Beraterprofil</a
|
>Beraterprofil</a
|
||||||
>
|
>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a
|
<a
|
||||||
href="/src/design/tri-hub-ernaehrungsberatung.html"
|
href="/index.html"
|
||||||
class="navbar__link"
|
class="navbar__link"
|
||||||
>FAQ</a
|
>FAQ</a
|
||||||
>
|
>
|
||||||
|
|
@ -51,7 +53,7 @@
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a
|
<a
|
||||||
href="/src/design/tri-hub-ernaehrungsberatung.html"
|
href="/index.html"
|
||||||
class="navbar__link"
|
class="navbar__link"
|
||||||
>Kontakt</a
|
>Kontakt</a
|
||||||
>
|
>
|
||||||
|
|
|
||||||
|
|
@ -41,12 +41,14 @@
|
||||||
gap: 16px;
|
gap: 16px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ---------- Logo + Markenname (kein Link mehr, nur Anzeige) ---------- */
|
/* ---------- Logo und Markenname als Sprunglink zum Hauptinhalt ---------- */
|
||||||
.navbar__brand {
|
.navbar__brand {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 12px;
|
gap: 12px;
|
||||||
flex-shrink: 0;
|
flex-shrink: 0;
|
||||||
|
color: inherit;
|
||||||
|
text-decoration: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
.navbar__logo-img {
|
.navbar__logo-img {
|
||||||
|
|
@ -138,23 +140,6 @@
|
||||||
stroke-width: 1.5;
|
stroke-width: 1.5;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ---------- Kriterium 2: barrierefreie Tastatursteuerung ---------- */
|
|
||||||
.skip-link {
|
|
||||||
position: absolute;
|
|
||||||
top: -40px;
|
|
||||||
left: 0;
|
|
||||||
background: var(--nav-green);
|
|
||||||
color: #06130f;
|
|
||||||
font-weight: 700;
|
|
||||||
padding: 0.75rem 1rem;
|
|
||||||
z-index: 1100;
|
|
||||||
transition: top 0.2s ease;
|
|
||||||
}
|
|
||||||
|
|
||||||
.skip-link:focus {
|
|
||||||
top: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar a:focus-visible,
|
.navbar a:focus-visible,
|
||||||
.navbar button:focus-visible {
|
.navbar button:focus-visible {
|
||||||
outline: 3px solid var(--nav-green);
|
outline: 3px solid var(--nav-green);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue