/* ═══════════════════════════════════════════════════════════
   MARKETING NAVBAR — Automated Worx
   Clean, premium public-facing navigation
   Used on: index, about, services, pricing, contact,
            case-studies, testimonials, process, blog,
            integrations, sitemap, docs, strategy, login
   ═══════════════════════════════════════════════════════════ */

/* ══ ISOLATION: prevent page styles from leaking in ═════ */
.navbar-marketing,
.navbar-marketing *,
.navbar-marketing *::before,
.navbar-marketing *::after {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: 1.5;
    letter-spacing: normal;
    text-transform: none;
    font-style: normal;
    box-sizing: border-box;
}
.navbar-marketing a         { text-decoration: none; outline: none; }
.navbar-marketing ul,
.navbar-marketing li        { list-style: none; margin: 0; padding: 0; }
.navbar-marketing button    { font-family: inherit; }

/* ── Base ─────────────────────────────────────────────── */
.navbar-marketing {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(2, 6, 23, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(14, 242, 255, 0.08);
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

.navbar-marketing.scrolled {
    background: rgba(2, 6, 23, 0.95);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.4);
    border-bottom-color: rgba(14, 242, 255, 0.15);
}

/* ── Container: CSS Grid 3-column ────────────────────── */
.nm-container {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    height: 64px;
}

/* ── Brand (left column) ─────────────────────────────── */
.nm-brand {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    text-decoration: none;
    color: #f8fafc;
    font-weight: 700;
    font-size: 1.15rem;
    letter-spacing: -0.3px;
    transition: opacity 0.2s;
}

.nm-brand:hover {
    opacity: 0.85;
}

.nm-brand img {
    width: 32px;
    height: 32px;
    border-radius: 6px;
}

.nm-brand-text {
    background: linear-gradient(135deg, #0ef 0%, #3b82f6 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ── Nav Links (center column) ───────────────────────── */
.nm-links {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.25rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nm-links a {
    display: inline-flex;
    align-items: center;
    padding: 0.5rem 1rem;
    color: #94a3b8;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    border-radius: 6px;
    transition: color 0.2s, background 0.2s;
    white-space: nowrap;
}

.nm-links a:hover {
    color: #e2e8f0;
    background: rgba(255, 255, 255, 0.05);
}

.nm-links a.active {
    color: #0ef;
    background: rgba(14, 242, 255, 0.08);
}

/* ── Actions (right column) ──────────────────────────── */
.nm-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.nm-signin {
    display: inline-flex;
    align-items: center;
    padding: 0.45rem 1rem;
    color: #cbd5e1;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    border-radius: 6px;
    transition: color 0.2s;
}

.nm-signin:hover {
    color: #f8fafc;
}

.nm-cta {
    display: inline-flex;
    align-items: center;
    padding: 0.5rem 1.25rem;
    background: linear-gradient(135deg, #0ef 0%, #06b6d4 100%);
    color: #020617;
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 8px;
    transition: transform 0.2s, box-shadow 0.2s;
    box-shadow: 0 2px 12px rgba(14, 242, 255, 0.2);
}

.nm-cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(14, 242, 255, 0.35);
}

/* ── Mobile Toggle ───────────────────────────────────── */
.nm-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 28px;
    height: 28px;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0;
}

.nm-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background: #94a3b8;
    border-radius: 2px;
    transition: transform 0.3s, opacity 0.3s;
}

.nm-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.nm-toggle.active span:nth-child(2) {
    opacity: 0;
}

.nm-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* ── Responsive: Tablet ──────────────────────────────── */
@media (max-width: 1024px) {
    .nm-container {
        padding: 0 1.25rem;
    }

    .nm-links a {
        padding: 0.5rem 0.75rem;
        font-size: 0.85rem;
    }
}

/* ── Responsive: Mobile ──────────────────────────────── */
@media (max-width: 768px) {
    .nm-container {
        grid-template-columns: 1fr auto auto;
        grid-template-rows: 64px auto;
        height: auto;
    }

    .nm-toggle {
        display: flex;
        order: 2;
    }

    .nm-actions {
        order: 3;
        /* Hide CTA on mobile, keep sign-in */
    }

    .nm-actions .nm-cta {
        display: none;
    }

    .nm-links {
        display: none;
        grid-column: 1 / -1;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: 0.5rem 0 1rem;
        border-top: 1px solid rgba(14, 242, 255, 0.1);
    }

    .nm-links.active {
        display: flex;
    }

    .nm-links a {
        padding: 0.75rem 1rem;
        border-radius: 0;
        font-size: 0.95rem;
    }

    .nm-links a:hover {
        background: rgba(14, 242, 255, 0.06);
    }
}
