.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 1000;
    padding: 10px 0;
    border-bottom: 1px solid #e2e8f0;
    transition: all 0.3s ease;
    animation: slideInDown 0.6s ease-out;
}

.header.scrolled {
    background: rgba(255, 255, 255, 0.98);
    padding: 7px 0;
    box-shadow: 0 8px 28px rgba(15, 23, 42, 0.10);
}

.header-content {
    max-width: 1500px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 2fr 1fr;
    align-items: center;
    padding: 0 24px;
    gap: 32px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #0f172a;
    text-decoration: none;
    font-size: 20px;
    font-weight: 700;
    transition: all 0.3s ease;
    justify-self: start;
}

.logo:hover {
    transform: scale(1.05);
}

.logo-icon {
    display: flex;
    align-items: center;
}

.logo-icon img {
    height: 46px;
    width: 46px;
    display: block;
}

.logo-text {
    font-family: 'Inter', sans-serif;
    font-size: 19px;
    font-weight: 900;
    letter-spacing: -0.02em;
    color: #0f172a;
}

.nav-menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 10px;
    justify-content: center;
    justify-self: center;
}

.nav-menu li {
    position: relative;
}

.nav-menu a {
    font-family: 'Inter', sans-serif;
    color: #475569;
    text-decoration: none;
    font-weight: 700;
    font-size: 16px;
    letter-spacing: normal;
    padding: 8px 12px;
    border-radius: 999px;
    transition: all 0.2s ease;
    position: relative;
    display: block;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: #0f172a;
    background: #f1f5f9;
}

.user-menu {
    display: flex;
    align-items: center;
    gap: 12px;
    justify-self: end;
    color: #0f172a;
    font-weight: 600;
    font-size: 14px;
}

.login-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 22px;
    background: #0f172a;
    color: white;
    text-decoration: none;
    border-radius: 999px;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.2s ease;
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.22);
}

.login-btn:hover {
    transform: translateY(-2px);
    background: #2563eb;
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.35);
}

.user-avatar {
    width: 40px;
    height: 40px;
    background: #0f172a;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.22);
}

.user-avatar:hover {
    transform: translateY(-2px);
    background: #2563eb;
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.35);
}

.user-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 8px;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.15);
    padding: 12px 0;
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

.user-avatar:hover .user-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    color: #374151;
    text-decoration: none;
    transition: all 0.2s ease;
    font-weight: 500;
}

.dropdown-item:hover {
    background: #f8fafc;
    color: #2563eb;
}

.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 4px;
    padding: 8px;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.mobile-menu-btn span {
    width: 24px;
    height: 2px;
    background: #0f172a;
    transition: all 0.3s ease;
    transform-origin: center;
}

.mobile-menu-btn.active span:nth-child(1) {
    transform: rotate(45deg) translateY(6px);
}

.mobile-menu-btn.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-btn.active span:nth-child(3) {
    transform: rotate(-45deg) translateY(-6px);
}

.mobile-nav {
    position: fixed;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(12px);
    padding: 32px 24px;
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    border-top: 1px solid #e2e8f0;
    box-shadow: 0 16px 32px rgba(15, 23, 42, 0.12);
}

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

.mobile-nav-menu {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.mobile-nav-menu a {
    color: #0f172a;
    text-decoration: none;
    font-weight: 600;
    font-size: 18px;
    padding: 10px 8px;
    border-radius: 12px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    transition: all 0.3s ease;
    text-align: center;
    display: block;
}

.mobile-nav-menu a:hover {
    background: #eff6ff;
    color: #2563eb;
}

@media (max-width: 968px) {
    .header-content {
        grid-template-columns: auto 1fr auto;
        gap: 16px;
    }

    .nav-menu {
        display: none;
    }

    .mobile-menu-btn {
        display: flex;
    }
}

@media (max-width: 768px) {
    .header-content {
        padding: 0 16px;
    }

    .logo-icon img {
        height: 38px;
        width: 38px;
    }

    .logo-text {
        font-size: 16px;
    }
}
