/* ══════════════════════════════════════════
   SHARED NAVBAR — navbar.css
   Barcha sahifalarda ishlatiladi.
   CSS o'zgaruvchilar (--violet, --cyan va h.k.)
   landing.css yoki registration.css dan keladi.
══════════════════════════════════════════ */

/* ── Nav shell ── */
.landing-nav {
    position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
    background: #070214;
    border-bottom: 2px solid rgba(124,58,237,.50);
    box-shadow: 0 4px 32px rgba(0,0,0,.70), 0 2px 0 rgba(124,58,237,.20);
    transition: border-color .3s ease, box-shadow .3s ease;
}
.landing-nav.nav-scrolled {
    border-bottom-color: rgba(0,212,255,.45);
    box-shadow: 0 6px 48px rgba(0,0,0,.80), 0 2px 0 rgba(0,212,255,.18);
}

.nav-inner {
    display: flex; align-items: center; justify-content: space-between;
    padding: 18px 0;
}

/* ── Logo ── */
.nav-logo { display: flex; align-items: center; gap: 14px; text-decoration: none; }
.nav-logo-icon {
    width: 42px; height: 42px; flex-shrink: 0;
    background: linear-gradient(135deg, #7C3AED, #00D4FF);
    border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 0 24px rgba(124,58,237,.65);
    transition: all .28s cubic-bezier(.4,0,.2,1);
}
.nav-logo:hover .nav-logo-icon { transform: rotate(-10deg) scale(1.08); }
.nav-logo-icon i { font-size: 18px; color: #ffffff; }
.nav-logo-text strong {
    display: block; font-size: 16px; font-weight: 800;
    color: #ffffff; letter-spacing: -.2px;
}
.nav-logo-text span {
    font-size: 13px; font-weight: 500; color: #C4B5FD;
}

/* ── CTA tugma ── */
.nav-cta {
    display: inline-flex; align-items: center; gap: 9px;
    padding: 12px 28px;
    background: linear-gradient(135deg, #7C3AED, #DB2777);
    color: #ffffff; border-radius: 50px; font-size: 16px; font-weight: 800;
    letter-spacing: .2px; text-decoration: none;
    border: 1px solid rgba(255,255,255,.20);
    box-shadow: 0 4px 24px rgba(124,58,237,.60), 0 0 0 1px rgba(196,181,253,.15);
    transition: all .28s cubic-bezier(.4,0,.2,1);
    position: relative; overflow: hidden;
    white-space: nowrap;
}
.nav-cta::before {
    content: ''; position: absolute; top: 0; left: -100%; width: 100%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,.20), transparent);
    transition: left .5s ease;
}
.nav-cta:hover::before { left: 100%; }
.nav-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 36px rgba(124,58,237,.75), 0 0 20px rgba(0,212,255,.30);
    color: #ffffff;
}

/* ── Nav links — desktop ── */
.nav-links {
    flex: 1;
    display: flex; align-items: center; justify-content: center;
    gap: 4px;
    list-style: none; margin: 0; padding: 0;
}

.nav-link-item {
    position: relative;
    display: inline-flex; align-items: center;
    padding: 10px 18px;
    font-size: 16px; font-weight: 600;
    color: rgba(226, 220, 255, .92);
    text-decoration: none; border-radius: 10px;
    letter-spacing: .15px; white-space: nowrap;
    transition: color .25s ease, background .25s ease;
}
.nav-link-item::after {
    content: '';
    position: absolute; bottom: 5px; left: 50%;
    transform: translateX(-50%);
    width: 0; height: 2px;
    background: linear-gradient(90deg, #7C3AED, #00D4FF);
    border-radius: 2px;
    transition: width .35s cubic-bezier(.4,0,.2,1);
}
.nav-link-item:hover             { color: #fff; background: rgba(124,58,237,.18); }
.nav-link-item:hover::after,
.nav-link-item.active::after     { width: calc(100% - 30px); }
.nav-link-item.active            { color: #ffffff; }

/* ── Nav right wrapper ── */
.nav-right {
    display: flex; align-items: center; gap: 12px; flex-shrink: 0;
}

/* ── Hamburger tugma ── */
.nav-burger {
    display: none;
    flex-direction: column; justify-content: center; align-items: center;
    gap: 5px; width: 40px; height: 40px;
    background: rgba(124,58,237,.14);
    border: 1px solid rgba(124,58,237,.38);
    border-radius: 10px;
    cursor: pointer; padding: 0; flex-shrink: 0;
    transition: all .28s cubic-bezier(.4,0,.2,1);
}
.nav-burger span {
    display: block; width: 18px; height: 2px;
    background: rgba(255,255,255,.82); border-radius: 2px;
    transform-origin: center;
    transition: transform .32s cubic-bezier(.4,0,.2,1), opacity .25s ease;
}
.nav-burger:hover                  { background: rgba(124,58,237,.28); border-color: rgba(196,181,253,.55); }
.nav-burger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-burger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-burger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── Mobile overlay ── */
.nav-mobile-overlay {
    position: fixed; inset: 0;
    background: rgba(3,0,14,.68);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    z-index: 998;
    opacity: 0; pointer-events: none;
    transition: opacity .35s ease;
}
.nav-mobile-overlay.open { opacity: 1; pointer-events: all; }

/* ── Mobile drawer (≤860px) ── */
@media (max-width: 860px) {
    .nav-links {
        position: fixed;
        top: 0; right: -290px; bottom: 0; left: auto;
        width: 272px; flex: none;
        background: linear-gradient(160deg, #0f0522 0%, #090119 100%);
        border-left: 1px solid rgba(124,58,237,.28);
        box-shadow: -18px 0 70px rgba(0,0,0,.65);
        flex-direction: column; align-items: flex-start; justify-content: flex-start;
        padding: 90px 14px 40px; gap: 3px; z-index: 999;
        transition: right .38s cubic-bezier(.4,0,.2,1);
        overflow-y: auto;
    }
    .nav-links.open { right: 0; }
    .nav-links::before {
        content: 'NAVIGATSIYA';
        display: block;
        font-size: 10px; font-weight: 800; letter-spacing: 2.5px;
        color: rgba(196,181,253,.32);
        padding: 0 10px 10px;
        border-bottom: 1px solid rgba(124,58,237,.14);
        margin-bottom: 6px; width: 100%;
    }
    .nav-link-item {
        width: 100%;
        font-size: 17px; padding: 14px 16px;
        border-radius: 12px;
        color: rgba(226,220,255,.92);
    }
    .nav-link-item::after   { display: none; }
    .nav-link-item.active   { background: rgba(124,58,237,.22); color: #ffffff; }
    .nav-link-item:hover    { background: rgba(124,58,237,.16); color: #ffffff; }

    .nav-burger { display: flex; }
}

/* ── 640px: subtitle yashirin, icon kichikroq, tugma compact ── */
@media (max-width: 640px) {
    .nav-inner            { padding: 12px 0; }
    .nav-logo             { gap: 10px; }
    .nav-logo-icon        { width: 36px; height: 36px; border-radius: 10px; }
    .nav-logo-icon i      { font-size: 16px; }
    .nav-logo-text span   { display: none; }
    .nav-logo-text strong { font-size: 14px; letter-spacing: -.1px; }
    .nav-cta { padding: 10px 18px; font-size: 15px; gap: 6px; letter-spacing: 0; }
    .nav-cta i { font-size: 14px; }
}

/* ── 480px: logo matn to'liq yashirin ── */
@media (max-width: 480px) {
    .nav-logo-text { display: none; }
    .nav-cta { padding: 9px 14px; }
}

/* ── 400px ── */
@media (max-width: 400px) {
    .nav-inner { padding: 10px 0; }
    .nav-cta   { padding: 9px 14px; font-size: 15px; }
}
