/* ==========================================================================
   NEXVORK AI & AUTOMATION PAGE — UNIQUE VISUAL IDENTITY
   All classes prefixed `ai-` so zero conflict with index.css and features.css
   Reuses color tokens from index.css (--brand-purple, --bg, etc.)
   so theme switching works automatically
   ========================================================================== */

/* ==========================================================================
   1. CONTAINER & TYPOGRAPHY HELPERS
   ========================================================================== */
.ai-container {
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 24px;
}
@media (max-width: 768px) {
    .ai-container { padding: 0 18px; }
}

.ai-mono,
.ai-mono-tag,
.ai-mono-label {
    font-family: 'JetBrains Mono', 'SF Mono', Consolas, monospace;
    font-size: 0.72rem;
    font-weight: 500;
    letter-spacing: 0.12em;
    color: var(--text-muted);
    text-transform: uppercase;
}
.ai-mono-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 100px;
    font-size: 0.7rem;
    margin-bottom: 24px;
}
.ai-mono-pulse {
    width: 7px; height: 7px;
    border-radius: 50%;
    background: var(--accent-emerald, #10B981);
    box-shadow: 0 0 10px var(--accent-emerald, #10B981);
    animation: aiMonoPulse 1.6s ease-in-out infinite;
}
@keyframes aiMonoPulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%      { opacity: 0.4; transform: scale(1.5); }
}

/* Buttons */
.ai-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 11px 20px;
    font-size: 0.9rem;
    font-weight: 600;
    border-radius: 8px;
    transition: all 0.35s cubic-bezier(0.22, 1, 0.36, 1);
    text-decoration: none;
    border: 1px solid transparent;
    cursor: pointer;
    line-height: 1;
}
.ai-btn-primary {
    background: linear-gradient(135deg, var(--brand-purple), var(--brand-blue));
    color: #fff;
    box-shadow: 0 8px 24px rgba(130, 62, 157, 0.25);
}
.ai-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(130, 62, 157, 0.4);
}
.ai-btn-ghost {
    background: transparent;
    color: var(--text);
    border-color: var(--border);
}
.ai-btn-ghost:hover {
    border-color: var(--text);
    background: var(--bg-elevated);
}
.ai-btn-lg { padding: 13px 24px; font-size: 0.95rem; }

/* ==========================================================================
   2. SCROLL REVEAL — slide-from-direction (different from index masks)
   ========================================================================== */
[data-ai-reveal] {
    opacity: 0;
    will-change: transform, opacity;
    transition:
        opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
        transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}
[data-ai-reveal="up"]    { transform: translateY(24px); }
[data-ai-reveal="left"]  { transform: translateX(-30px); }
[data-ai-reveal="right"] { transform: translateX(30px); }
[data-ai-reveal="line"]  {
    transform: translateY(20px);
    display: block;
}
[data-ai-reveal].ai-in {
    opacity: 1;
    transform: translate(0, 0);
}
@media (prefers-reduced-motion: reduce) {
    [data-ai-reveal] { opacity: 1 !important; transform: none !important; }
}

/* ==========================================================================
   3. HERO — centered with terminal console below
   ========================================================================== */
.ai-hero {
    position: relative;
    padding: 90px 0 80px;
    overflow: hidden;
    border-bottom: 1px solid var(--border-subtle);
}
.ai-hero-bg {
    position: absolute;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
}
.ai-hero-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.25;
    animation: aiOrbDrift 20s ease-in-out infinite alternate;
}
.ai-hero-orb-1 {
    width: 400px; height: 400px;
    background: radial-gradient(circle, var(--brand-purple), transparent 70%);
    top: -100px; left: -100px;
}
.ai-hero-orb-2 {
    width: 360px; height: 360px;
    background: radial-gradient(circle, var(--brand-blue), transparent 70%);
    top: 20%; right: -120px;
    animation-delay: -10s;
}
.dark .ai-hero-orb { opacity: 0.4; }
@keyframes aiOrbDrift {
    from { transform: translate(0, 0); }
    to   { transform: translate(40px, -30px); }
}

.ai-hero-inner {
    position: relative;
    z-index: 1;
    max-width: 880px;
    margin: 0 auto;
    text-align: center;
}
.ai-hero-title {
    font-family: 'Cabinet Grotesk', system-ui, sans-serif;
    font-size: clamp(2.4rem, 5.5vw, 4.4rem);
    font-weight: 800;
    line-height: 1.02;
    letter-spacing: -0.035em;
    color: var(--text);
    margin: 0 0 24px;
}
.ai-line {
    display: block;
    overflow: hidden;
}
.ai-line-grad {
    background: linear-gradient(135deg, var(--brand-purple), var(--brand-blue));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.ai-hero-sub {
    font-size: 1.08rem;
    line-height: 1.65;
    color: var(--text-muted);
    margin: 0 auto 32px;
    max-width: 640px;
}
.ai-hero-cta {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
    margin-bottom: 56px;
}

/* Terminal Console — UNIQUE feature for AI page */
.ai-console {
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 16px 48px rgba(11, 11, 20, 0.08);
    text-align: left;
    position: relative;
}
.ai-console::before {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--brand-purple), var(--brand-blue), transparent);
    opacity: 0.6;
}
.ai-console-head {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: var(--bg-subtle);
    border-bottom: 1px solid var(--border-subtle);
}
.ai-console-dots {
    display: flex;
    gap: 6px;
}
.ai-console-dots span {
    width: 11px; height: 11px;
    border-radius: 50%;
}
.ai-console-dots span:nth-child(1) { background: #FF5F57; }
.ai-console-dots span:nth-child(2) { background: #FEBC2E; }
.ai-console-dots span:nth-child(3) { background: #28C840; }
.ai-console-title {
    flex: 1;
    text-align: center;
    color: var(--text-subtle);
}
.ai-console-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    background: rgba(16, 185, 129, 0.12);
    color: var(--accent-emerald, #10B981);
    border-radius: 100px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.1em;
}
.ai-pulse-dot {
    width: 6px; height: 6px;
    border-radius: 50%;
    background: var(--accent-emerald, #10B981);
    box-shadow: 0 0 8px var(--accent-emerald, #10B981);
    animation: aiMonoPulse 1.4s ease-in-out infinite;
}

.ai-console-body {
    padding: 14px 16px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.82rem;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.ai-console-row {
    display: grid;
    grid-template-columns: auto auto 1fr auto;
    align-items: center;
    gap: 12px;
    padding: 6px 0;
    color: var(--text-muted);
    border-bottom: 1px dashed var(--border-subtle);
}
.ai-console-row:last-child { border-bottom: none; }
.ai-console-row.ai-console-active {
    background: var(--grad-brand-soft);
    border-radius: 6px;
    padding: 8px 10px;
    border-bottom: none;
}
.ai-cr-time {
    color: var(--text-faint);
    font-size: 0.74rem;
}
.ai-cr-tag {
    font-size: 0.6rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    padding: 3px 8px;
    border-radius: 4px;
    color: var(--brand-purple);
    background: var(--grad-brand-soft);
}
.ai-tag-cyan   { background: rgba(34, 211, 238, 0.14); color: #22D3EE; }
.ai-tag-blue   { background: rgba(65, 143, 228, 0.14); color: var(--brand-blue); }
.ai-tag-purple { background: rgba(168, 85, 199, 0.14); color: var(--brand-purple-light, #A855C7); }
.ai-tag-green  { background: rgba(16, 185, 129, 0.14); color: var(--accent-emerald, #10B981); }
.ai-cr-text {
    color: var(--text);
    font-size: 0.85rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.ai-cr-status {
    font-weight: 700;
    color: var(--accent-emerald, #10B981);
}
.ai-cr-pending {
    width: 12px; height: 12px;
    border: 2px solid var(--brand-purple);
    border-top-color: transparent;
    border-radius: 50%;
    animation: aiSpin 0.8s linear infinite;
    display: inline-block;
}
@keyframes aiSpin { to { transform: rotate(360deg); } }
.ai-typing::after {
    content: "";
    display: inline-block;
    width: 6px; height: 6px;
    border-radius: 50%;
    background: var(--brand-purple);
    margin-left: 6px;
    animation: aiMonoPulse 0.8s ease-in-out infinite;
}

@media (max-width: 768px) {
    .ai-console-row { grid-template-columns: auto 1fr auto; }
    .ai-cr-time { display: none; }
    .ai-cr-text { white-space: normal; font-size: 0.78rem; }
}

/* ==========================================================================
   4. STATS BAND
   ========================================================================== */
.ai-stats {
    padding: 60px 0;
    background: var(--bg-elevated);
    border-bottom: 1px solid var(--border-subtle);
}
.ai-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}
@media (max-width: 768px) {
    .ai-stats-grid { grid-template-columns: repeat(2, 1fr); }
}
.ai-stat {
    text-align: center;
    padding: 20px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}
.ai-stat:hover {
    transform: translateY(-4px);
    border-color: var(--brand-purple);
    box-shadow: 0 12px 28px rgba(130, 62, 157, 0.12);
}
.ai-stat-num {
    font-family: 'Cabinet Grotesk', system-ui, sans-serif;
    font-size: 2.4rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--brand-purple), var(--brand-blue));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    line-height: 1;
    font-variant-numeric: tabular-nums;
    letter-spacing: -0.02em;
}
.ai-stat-lbl {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 8px;
    letter-spacing: 0.02em;
}

/* ==========================================================================
   5. SECTION HEADS
   ========================================================================== */
.ai-section-head {
    margin-bottom: 56px;
    max-width: 720px;
}
.ai-section-head.ai-center {
    margin-left: auto;
    margin-right: auto;
    text-align: center;
}
.ai-section-title {
    font-family: 'Cabinet Grotesk', system-ui, sans-serif;
    font-size: clamp(1.8rem, 3.6vw, 2.8rem);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.025em;
    color: var(--text);
    margin: 12px 0 0;
}
.ai-section-sub {
    font-size: 0.98rem;
    line-height: 1.65;
    color: var(--text-muted);
    margin: 14px 0 0;
}

/* ==========================================================================
   6. AI WORKFORCE — 4 worker cards (different from features bento)
   ========================================================================== */
.ai-workforce {
    padding: 90px 0;
    border-bottom: 1px solid var(--border-subtle);
}
.ai-workers-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}
@media (max-width: 900px) {
    .ai-workers-grid { grid-template-columns: 1fr; }
}

.ai-worker {
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 24px;
    transition: all 0.45s cubic-bezier(0.22, 1, 0.36, 1);
    position: relative;
    overflow: hidden;
}
.ai-worker::before {
    content: "";
    position: absolute;
    top: 0; left: 0;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--brand-purple), var(--brand-blue));
    transition: width 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}
.ai-worker:hover {
    transform: translateY(-4px);
    border-color: var(--brand-purple);
    box-shadow: 0 16px 40px rgba(130, 62, 157, 0.12);
}
.ai-worker:hover::before { width: 100%; }

.ai-worker-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border-subtle);
}
.ai-worker-id {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}
.ai-worker-avatar {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    display: grid;
    place-items: center;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.78rem;
    font-weight: 800;
    color: #fff;
    flex-shrink: 0;
    letter-spacing: 0.04em;
}
.ai-avatar-cyan   { background: linear-gradient(135deg, #22D3EE, #0891B2); }
.ai-avatar-blue   { background: linear-gradient(135deg, var(--brand-blue), #2563EB); }
.ai-avatar-purple { background: linear-gradient(135deg, var(--brand-purple), #5E2974); }
.ai-avatar-green  { background: linear-gradient(135deg, #10B981, #047857); }

.ai-worker-role {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    color: var(--text-faint);
    text-transform: uppercase;
    margin-bottom: 2px;
}
.ai-worker-name {
    font-family: 'Cabinet Grotesk', system-ui, sans-serif;
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text);
    letter-spacing: -0.01em;
    line-height: 1.2;
}

.ai-worker-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.6rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    padding: 4px 10px;
    border-radius: 100px;
    flex-shrink: 0;
}
.ai-status-active {
    background: rgba(16, 185, 129, 0.12);
    color: var(--accent-emerald, #10B981);
}
.ai-status-dot {
    width: 6px; height: 6px;
    border-radius: 50%;
    background: var(--accent-emerald, #10B981);
    box-shadow: 0 0 6px var(--accent-emerald, #10B981);
    animation: aiMonoPulse 1.4s ease-in-out infinite;
}

.ai-worker-desc {
    font-size: 0.93rem;
    line-height: 1.6;
    color: var(--text-muted);
    margin: 0 0 16px;
}

.ai-worker-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    padding: 12px;
    background: var(--bg);
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    margin-bottom: 14px;
}
.ai-worker-stats > div {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}
.ai-worker-stats span {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.65rem;
    color: var(--text-faint);
    letter-spacing: 0.04em;
    text-transform: uppercase;
}
.ai-worker-stats strong {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ai-worker-task {
    padding: 10px 12px;
    background: var(--grad-brand-soft);
    border-radius: 8px;
    border-left: 3px solid var(--brand-purple);
}
.ai-worker-task .ai-mono {
    display: block;
    font-size: 0.62rem;
    font-weight: 700;
    color: var(--brand-purple);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    margin-bottom: 4px;
}
.ai-worker-task div {
    font-size: 0.84rem;
    color: var(--text);
    line-height: 1.4;
}

/* ==========================================================================
   7. ZIGZAG DEEP-DIVE ROWS
   ========================================================================== */
.ai-deepdive {
    padding: 90px 0;
    background: var(--bg-elevated);
    border-bottom: 1px solid var(--border-subtle);
}
.ai-zigzag {
    display: flex;
    flex-direction: column;
    gap: 80px;
}
.ai-zz-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}
.ai-zz-reverse {
    direction: rtl;
}
.ai-zz-reverse > * {
    direction: ltr;
}
@media (max-width: 900px) {
    .ai-zz-row { grid-template-columns: 1fr; gap: 28px; direction: ltr; }
    .ai-zigzag { gap: 60px; }
}

.ai-zz-text { min-width: 0; }
.ai-zz-title {
    font-family: 'Cabinet Grotesk', system-ui, sans-serif;
    font-size: clamp(1.4rem, 2.4vw, 1.9rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.15;
    color: var(--text);
    margin: 12px 0 12px;
}
.ai-zz-text p {
    font-size: 0.98rem;
    line-height: 1.65;
    color: var(--text-muted);
    margin: 0 0 18px;
}
.ai-zz-points {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.ai-zz-points li {
    padding-left: 20px;
    position: relative;
    font-size: 0.9rem;
    color: var(--text-muted);
    line-height: 1.55;
}
.ai-zz-points li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 9px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--brand-purple), var(--brand-blue));
}
.ai-zz-points strong {
    color: var(--text);
    font-weight: 600;
}

/* Visuals on the right side */
.ai-zz-visual { min-width: 0; }

.ai-data-stack {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.ai-data-item {
    padding: 14px 16px;
    background: var(--bg-elevated);
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    font-size: 0.92rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.3s ease;
}
.ai-data-item:hover {
    transform: translateX(4px);
    border-color: var(--brand-purple);
}
.ai-data-item span {
    font-family: 'Cabinet Grotesk', system-ui, sans-serif;
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--text);
    flex-shrink: 0;
    min-width: 60px;
    font-variant-numeric: tabular-nums;
}
.ai-data-item-active {
    background: linear-gradient(135deg, rgba(130, 62, 157, 0.08), rgba(65, 143, 228, 0.08));
    border-color: var(--brand-purple);
}
.ai-data-item-active span {
    background: linear-gradient(135deg, var(--brand-purple), var(--brand-blue));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.ai-perf-card {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 18px;
}
.ai-perf-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-subtle);
}
.ai-perf-target {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.7rem;
    color: var(--accent-emerald, #10B981);
    background: rgba(16, 185, 129, 0.12);
    padding: 3px 8px;
    border-radius: 4px;
    font-weight: 600;
}
.ai-bars {
    display: flex;
    align-items: end;
    gap: 4px;
    height: 100px;
    padding: 0 4px;
}
.ai-bars span {
    flex: 1;
    height: var(--h);
    background: linear-gradient(180deg, var(--brand-blue), var(--brand-purple));
    border-radius: 3px 3px 0 0;
    opacity: 0.4;
    transition: opacity 0.3s ease;
}
.ai-bars span:hover { opacity: 0.85; }
.ai-bar-active {
    opacity: 1 !important;
    box-shadow: 0 0 12px rgba(65, 143, 228, 0.5);
}
.ai-perf-foot {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid var(--border-subtle);
}
.ai-perf-foot > div {
    display: flex;
    flex-direction: column;
    gap: 2px;
    text-align: center;
}
.ai-perf-foot span {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.65rem;
    color: var(--text-faint);
    letter-spacing: 0.05em;
    text-transform: uppercase;
}
.ai-perf-foot strong {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text);
    font-variant-numeric: tabular-nums;
}

.ai-learn-card {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 18px;
}
.ai-learn-head { margin-bottom: 12px; }
.ai-learn-chart svg { width: 100%; height: auto; }
.ai-learn-foot {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid var(--border-subtle);
}
.ai-learn-foot > div {
    display: flex;
    flex-direction: column;
    gap: 2px;
    text-align: center;
}
.ai-learn-foot span {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.65rem;
    color: var(--text-faint);
    letter-spacing: 0.05em;
    text-transform: uppercase;
}
.ai-learn-foot strong {
    font-size: 1.15rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--brand-purple), var(--brand-blue));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-variant-numeric: tabular-nums;
}

.ai-cert-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}
.ai-cert {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 14px;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.3s ease;
}
.ai-cert:hover {
    border-color: var(--brand-purple);
    transform: translateY(-2px);
}
.ai-cert-icon {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: var(--grad-brand-soft);
    display: grid;
    place-items: center;
    font-size: 1.1rem;
    flex-shrink: 0;
}
.ai-cert > div:last-child {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}
.ai-cert strong {
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--text);
}
.ai-cert span {
    font-size: 0.74rem;
    color: var(--text-subtle);
}

/* ==========================================================================
   8. AUTOMATION FLOW — 3 nodes with arrows
   ========================================================================== */
.ai-flow {
    padding: 90px 0;
    border-bottom: 1px solid var(--border-subtle);
}
.ai-flow-track {
    display: grid;
    grid-template-columns: 1fr auto 1fr auto 1fr;
    gap: 16px;
    align-items: center;
    margin-top: 30px;
}
@media (max-width: 900px) {
    .ai-flow-track {
        grid-template-columns: 1fr;
        gap: 24px;
    }
}

.ai-flow-node {
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 24px;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1);
    position: relative;
}
.ai-flow-node:hover {
    transform: translateY(-4px);
    border-color: var(--brand-purple);
    box-shadow: 0 16px 36px rgba(130, 62, 157, 0.12);
}
.ai-flow-num {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--brand-purple);
    letter-spacing: 0.1em;
    margin-bottom: 14px;
}
.ai-flow-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 16px;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--brand-purple), var(--brand-blue));
    color: #fff;
    display: grid;
    place-items: center;
    box-shadow: 0 10px 24px rgba(130, 62, 157, 0.25);
}
.ai-flow-title {
    font-family: 'Cabinet Grotesk', system-ui, sans-serif;
    font-size: 1.35rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--text);
    margin: 0 0 10px;
}
.ai-flow-desc {
    font-size: 0.88rem;
    line-height: 1.55;
    color: var(--text-muted);
    margin: 0 0 14px;
}
.ai-flow-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    justify-content: center;
}
.ai-flow-pills span {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.65rem;
    font-weight: 600;
    padding: 3px 9px;
    border-radius: 100px;
    background: var(--bg);
    border: 1px solid var(--border);
    color: var(--text-muted);
    letter-spacing: 0.04em;
}

.ai-flow-arrow {
    color: var(--text-faint);
    display: flex;
    align-items: center;
    justify-content: center;
}
@media (max-width: 900px) {
    .ai-flow-arrow svg { transform: rotate(90deg); }
}

/* ==========================================================================
   9. USE CASES — timeline-style
   ========================================================================== */
.ai-cases {
    padding: 90px 0;
    background: var(--bg-elevated);
    border-bottom: 1px solid var(--border-subtle);
}
.ai-cases-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}
@media (max-width: 900px) { .ai-cases-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .ai-cases-grid { grid-template-columns: 1fr; } }

.ai-case {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 22px;
    transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1);
    position: relative;
    display: flex;
    flex-direction: column;
}
.ai-case:hover {
    transform: translateY(-3px);
    border-color: var(--brand-purple);
    box-shadow: 0 14px 32px rgba(130, 62, 157, 0.1);
}

.ai-case-time {
    display: inline-flex;
    align-self: flex-start;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--brand-purple);
    background: var(--grad-brand-soft);
    padding: 5px 11px;
    border-radius: 100px;
    margin-bottom: 14px;
    letter-spacing: 0.05em;
}
.ai-case-title {
    font-family: 'Cabinet Grotesk', system-ui, sans-serif;
    font-size: 1.15rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    color: var(--text);
    margin: 0 0 8px;
    line-height: 1.2;
}
.ai-case p {
    font-size: 0.9rem;
    line-height: 1.6;
    color: var(--text-muted);
    margin: 0 0 14px;
    flex: 1;
}
.ai-case-result {
    font-size: 0.82rem;
    color: var(--text-muted);
    padding-top: 14px;
    border-top: 1px solid var(--border-subtle);
}
.ai-case-result strong {
    color: var(--text);
    font-weight: 600;
}

/* ==========================================================================
   10. INTEGRATIONS GRID
   ========================================================================== */
.ai-integrations {
    padding: 80px 0;
    border-bottom: 1px solid var(--border-subtle);
}
.ai-int-head {
    text-align: center;
    margin-bottom: 36px;
}
.ai-int-title {
    font-family: 'Cabinet Grotesk', system-ui, sans-serif;
    font-size: clamp(1.4rem, 2.4vw, 1.9rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--text);
    margin: 12px 0 0;
}
.ai-int-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 1px;
    background: var(--border);
    border: 1px solid var(--border);
    border-radius: 14px;
    overflow: hidden;
}
@media (max-width: 900px) { .ai-int-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 540px) { .ai-int-grid { grid-template-columns: repeat(2, 1fr); } }

.ai-int-cell {
    background: var(--bg);
    padding: 24px 16px;
    text-align: center;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    transition: all 0.3s ease;
}
.ai-int-cell:hover {
    background: var(--bg-elevated);
    color: var(--text);
}

/* ==========================================================================
   11. FAQ — minimal expandable
   ========================================================================== */
.ai-faq {
    padding: 90px 0;
    border-bottom: 1px solid var(--border-subtle);
}
.ai-faq-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-width: 820px;
    margin: 0 auto;
}
.ai-faq-item {
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 10px;
    overflow: hidden;
    transition: border-color 0.3s ease;
}
.ai-faq-item[open] {
    border-color: var(--brand-purple);
    background: var(--bg-elevated);
}
.ai-faq-item summary {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 14px;
    padding: 16px 20px;
    cursor: pointer;
    list-style: none;
    color: var(--text);
    transition: color 0.3s ease;
}
.ai-faq-item summary::-webkit-details-marker { display: none; }
.ai-faq-item summary:hover { color: var(--brand-purple); }

.ai-faq-q-num {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--brand-purple);
    letter-spacing: 0.05em;
}
.ai-faq-q {
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.4;
}
.ai-faq-toggle {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: var(--bg);
    border: 1px solid var(--border);
    display: grid;
    place-items: center;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-muted);
    transition: all 0.3s ease;
    line-height: 1;
}
.ai-faq-item[open] .ai-faq-toggle {
    background: linear-gradient(135deg, var(--brand-purple), var(--brand-blue));
    border-color: transparent;
    color: #fff;
    transform: rotate(45deg);
}
.ai-faq-a {
    padding: 0 20px 18px 56px;
    font-size: 0.92rem;
    line-height: 1.65;
    color: var(--text-muted);
}

@media (max-width: 600px) {
    .ai-faq-a { padding-left: 20px; }
}

/* ==========================================================================
   12. CTA — same pattern as features
   ========================================================================== */
.ai-cta {
    padding: 100px 0 90px;
}
.ai-cta-block {
    text-align: center;
    max-width: 640px;
    margin: 0 auto;
    padding: 50px 32px;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 18px;
    position: relative;
    overflow: hidden;
}
.ai-cta-line {
    position: absolute;
    top: 0; left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: linear-gradient(90deg, var(--brand-purple), var(--brand-blue));
    border-radius: 0 0 4px 4px;
}
.ai-cta-title {
    font-family: 'Cabinet Grotesk', system-ui, sans-serif;
    font-size: clamp(1.5rem, 3vw, 2.2rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.15;
    color: var(--text);
    margin: 14px 0 12px;
}
.ai-cta-sub {
    font-size: 1rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin: 0 0 28px;
}
.ai-cta-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-wrap: wrap;
}

/* ==========================================================================
   13. RESPONSIVE TIGHTENS
   ========================================================================== */
@media (max-width: 768px) {
    .ai-hero { padding: 60px 0 50px; }
    .ai-stats { padding: 40px 0; }
    .ai-workforce, .ai-deepdive, .ai-flow, .ai-cases, .ai-faq { padding: 60px 0; }
    .ai-cta { padding: 70px 0 60px; }
    .ai-section-head { margin-bottom: 36px; }
    .ai-stat-num { font-size: 1.8rem; }
    .ai-cta-block { padding: 36px 20px; }
}