/* Shared header/navigation (index, news, shorts) */
.nav-links {
    gap: 0.5rem;
    align-items: center;
    flex-wrap: wrap;
}

.nav-links a {
    display: inline-flex;
    flex-shrink: 0;
    line-height: 0;
}

.nav-links .nav-icon {
    height: 40px;
    width: auto;
    display: block;
    margin: 0;
    box-shadow: none;
    border-radius: 0;
    max-width: none;
}

.nav-links .nav-esports-link {
    line-height: 1.2;
    padding: 8px 12px;
    border-radius: 8px;
    border: 1px solid rgba(255, 215, 0, 0.35);
    color: #ffd700;
    font-size: 0.8rem;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
}

.nav-links .nav-esports-link:hover {
    background: rgba(255, 215, 0, 0.12);
    color: #fff;
}

.header .logo img {
    height: 50px;
    width: auto;
    margin-left: 30px;
}

.header-spacer {
    height: 5rem;
}

/* Language dropdown — share-btn styling */
.nav-lang-dropdown {
    position: relative;
    display: inline-flex;
    align-items: center;
    margin-left: 0.5rem;
    flex-shrink: 0;
}

.nav-lang-dropdown .share-btn {
    display: inline-block;
    width: auto;
    height: auto;
    min-width: 0;
    min-height: 0;
    padding: 10px 20px;
    background: transparent;
    color: var(--accent);
    border: 2px solid var(--accent);
    border-radius: 25px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    z-index: 2;
    transition: color 0.4s ease;
    line-height: 1.2;
    white-space: nowrap;
    align-items: unset;
    justify-content: unset;
    box-shadow: none;
    transform: none;
}

.nav-lang-dropdown .share-btn::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 0;
    background: var(--accent);
    transition: height 0.4s ease;
    z-index: -1;
    border-radius: 25px;
}

.nav-lang-dropdown .share-btn:hover {
    color: var(--accent-hover-text);
}

.nav-lang-dropdown .share-btn:hover::before {
    height: 100%;
}

.nav-lang-dropdown .share-btn:active {
    transform: scale(0.98);
}

.nav-lang-dropdown .lang-menu {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 15px;
    padding: 8px;
    min-width: 220px;
    max-height: 70vh;
    overflow-y: auto;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    box-shadow: 0 10px 40px var(--shadow-lg);
    backdrop-filter: blur(10px);
    z-index: 1100;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.nav-lang-dropdown.active .lang-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.nav-lang-dropdown .lang-item {
    display: block;
    padding: 12px 16px;
    color: var(--text-primary);
    text-decoration: none;
    border-radius: 10px;
    transition: all 0.2s ease;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.35;
    white-space: nowrap;
}

.nav-lang-dropdown .lang-item:hover {
    background: var(--bg-hover);
    color: var(--accent);
}

.nav-lang-dropdown .lang-item.active {
    background: var(--accent-soft);
    color: var(--accent);
}

@media (max-width: 768px) {
    .header .nav {
        position: relative;
        height: auto;
        min-height: 3rem;
        padding: 0.35rem 0;
        justify-content: flex-start;
    }

    .header .logo {
        flex: 0 0 auto;
    }

    .header .menu-button {
        display: block;
        flex: 0 0 auto;
        margin-left: auto;
        margin-right: 30px;
    }

    .header .nav-links:not(.active) {
        display: none !important;
    }

    .header .logo img {
        height: 32px !important;
        margin-left: 30px;
    }

    .header .nav-links.active {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        align-items: center;
        gap: 0.25rem 0.35rem;
    }

    .header .nav-links .nav-icon {
        height: 40px !important;
        width: auto !important;
        max-width: none !important;
    }

    .header .theme-toggle-wrap,
    .header .nav-lang-dropdown {
        flex: 0 0 auto;
    }

    .header .nav-lang-dropdown {
        margin: 0.35rem 0 0;
    }

    .header .theme-toggle-wrap {
        margin: 0.35rem 0 0;
    }

    .header .nav-lang-dropdown .share-btn {
        width: auto;
        height: auto;
        padding: 8px 18px;
        font-size: 12px;
        border-radius: 25px;
    }

    .header .nav-lang-dropdown .lang-menu {
        left: 50%;
        right: auto;
        transform: translateX(-50%) translateY(-10px);
        min-width: min(280px, calc(100vw - 2rem));
    }

    .header .nav-lang-dropdown.active .lang-menu {
        transform: translateX(-50%) translateY(0);
    }

    .header-spacer {
        height: 3.25rem;
    }
}


/* Theme toggle button */
.theme-toggle-wrap {
    position: relative;
    display: inline-flex;
    align-items: center;
    margin-left: 0.5rem;
    flex-shrink: 0;
}

.theme-toggle-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    padding: 0;
    background: transparent;
    color: var(--accent);
    border: 2px solid var(--accent);
    border-radius: 50%;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    z-index: 2;
    transition: color 0.4s ease;
    line-height: 1;
}

.theme-toggle-btn::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 0;
    background: var(--accent);
    transition: height 0.4s ease;
    z-index: -1;
    border-radius: 50%;
}

.theme-toggle-btn:hover {
    color: var(--accent-hover-text);
}

.theme-toggle-btn:hover::before {
    height: 100%;
}

.theme-toggle-btn:active {
    transform: scale(0.98);
}

@media (max-width: 768px) {
    .header .theme-toggle-wrap {
        flex: 0 0 auto;
        margin: 0;
    }

    .header .theme-toggle-btn {
        width: 38px;
        height: 38px;
        font-size: 16px;
    }
}
