/* Navigation: Mobile-First Responsive Design */

/* ============================================
   MOBILE (Base - bis 575px)
   ============================================ */

.header {
    font-family: var(--font-family-primary);
    font-size: 14px;
    line-height: 1.8;
    background: var(--glass-bg-strong);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border-bottom: 1px solid var(--glass-border);
    padding: 12px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 0 auto;
    position: relative;
    overflow-x: clip;
    overflow-y: visible;
    box-sizing: border-box;
    gap: 10px;
    z-index: 1000;
    max-width: 1600px;
    width: 100%;
    left: 0;
    right: 0;
}

.header-logo-area {
    font-family: var(--font-family-primary);
    font-size: 14px;
    line-height: 1.8;
    flex: 0 0 auto;
    min-width: 0;
    max-width: 100%;
    overflow: visible;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

/* Navigation: Auf Mobile versteckt, wird über Hamburger-Menü geöffnet */
.header-nav {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--glass-bg-strong);
    backdrop-filter: blur(var(--glass-blur-strong));
    -webkit-backdrop-filter: blur(var(--glass-blur-strong));
    flex-direction: column;
    align-items: flex-start;
    padding: 80px 20px 20px 20px;
    z-index: 999;
    overflow-y: auto;
    box-shadow: var(--shadow-medium);
    gap: 20px;
}

/* Navigation geöffnet (Mobile) */
.header-nav.open {
    display: flex;
}

.nav-link {
    font-family: var(--font-family-primary);
    font-size: 18px;
    line-height: 1.8;
    text-decoration: none;
    color: var(--color-text);
    padding: 12px 0;
    border-radius: 0;
    transition: var(--transition-fast);
    font-weight: 400;
    letter-spacing: 0.6px;
    white-space: nowrap;
    width: 100%;
    border-bottom: 1px solid var(--color-border);
}

.nav-link:hover {
    text-decoration: none;
    color: var(--color-primary);
    background-color: transparent;
}

.header-actions {
    font-family: var(--font-family-primary);
    font-size: 14px;
    line-height: 1.8;
    display: flex;
    gap: 10px;
    flex: 0 0 auto;
    min-width: 0;
    max-width: 100%;
    overflow: visible;
    box-sizing: border-box;
    align-items: center;
    flex-shrink: 0;
}

/* Hamburger-Menü Button (Mobile) */
.mobile-nav-toggle {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1001;
    gap: 5px;
}

.mobile-nav-toggle-line {
    width: 24px;
    height: 2px;
    background: var(--color-text);
    transition: var(--transition-fast);
    border-radius: 1px;
}

.mobile-nav-toggle.active .mobile-nav-toggle-line:nth-child(1) {
    transform: rotate(45deg) translate(7px, 7px);
}

.mobile-nav-toggle.active .mobile-nav-toggle-line:nth-child(2) {
    opacity: 0;
}

.mobile-nav-toggle.active .mobile-nav-toggle-line:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

/* Language Switcher Styles wurden nach widgets-translation-flags-language-switcher.css verschoben */

.header-user-avatar {
    font-family: var(--font-family-primary);
    font-size: 14px;
    line-height: 1.8;
    display: none;
    align-items: center;
}

.header-user-avatar-link {
    font-family: var(--font-family-primary);
    font-size: 14px;
    line-height: 1.8;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    text-decoration: none;
    border: 2px solid var(--color-border);
}

.header-user-avatar-link:hover {
    border-color: var(--color-primary);
}

.header-user-avatar-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.header-user-avatar-placeholder {
    font-family: var(--font-family-primary);
    font-size: 14px;
    line-height: 1.8;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--color-primary);
    color: var(--color-text-inverse);
    font-weight: bold;
    text-transform: uppercase;
}

/* ============================================
   TABLET (600px - 1023px)
   ============================================ */

@media (min-width: 600px) {
    .header {
        padding: 12px 40px;
    }

    .header-nav {
        padding: 80px 40px 40px 40px;
    }
}

/* ============================================
   DESKTOP (1024px - 1439px)
   ============================================ */

@media (min-width: 1024px) {
    .header {
        padding: 12px 60px;
    }

    /* Navigation: Auf Desktop immer sichtbar; flex: 1 damit Flaggen ganz rechts Platz haben */
    .header-nav {
        display: flex;
        position: static;
        flex-direction: row;
        flex: 1;
        min-width: 0;
        background: transparent;
        border: none;
        padding: 0;
        box-shadow: none;
        gap: 10px;
        align-items: center;
        top: auto;
        left: auto;
        right: auto;
        bottom: auto;
        overflow: visible;
    }

    /* Home-Link mittig zwischen Logo und Flaggen */
    .header-nav::before {
        content: '';
        flex: 1;
    }

    .header-nav.open {
        display: flex;
    }

    .nav-link {
        font-size: 14px;
        padding: 8px 16px;
        width: auto;
        border-bottom: none;
    }

    /* Hamburger-Menü auf Desktop versteckt */
    .mobile-nav-toggle {
        display: none;
    }

    /* Language Switcher Styles wurden nach widgets-translation-flags-language-switcher.css verschoben */
}

/* ============================================
   WIDESCREEN (1440px+)
   ============================================ */

@media (min-width: 1440px) {
    .header {
        padding: 12px 60px;
    }
}
