/* Home "Epic Insights" section (assets/js/nx-insights.js), 2026-10-13. Replaces the pinned scroll story.
 * A crawler works through a client site's pages (illustration), findings roll in beside it, and two client
 * figures count up once when they scroll into view. Tokens from nx.css/site.css; reduced motion = final state. */
.nx-ins { padding-top: 96px; }
.nx-ins-head { max-width: 46rem; }
.nx-ins-head .nx-lede { margin-top: 16px; }
.nx-ins-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 40px; align-items: stretch; margin-top: 44px; }

/* Crawl report */
.nx-ins-crawl { margin: 0; position: relative; display: grid; grid-template-rows: auto 1fr auto; border-radius: 24px; border: 1px solid var(--border-hover); background: linear-gradient(180deg, rgba(255,255,255,.04), rgba(255,255,255,.015)); overflow: hidden; }
.nx-ins-bar { display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-bottom: 1px solid var(--nx-line); font-size: .76rem; color: var(--muted); }
.nx-ins-bar > b { color: var(--text); font-weight: 700; }
.nx-ins-bar .nx-ins-live { display: inline-flex; align-items: center; gap: 6px; padding: 3px 9px; border-radius: 999px; background: rgba(62,227,161,.12); color: #3ee3a1; font-weight: 800; font-size: .66rem; letter-spacing: .06em; text-transform: uppercase; }
.nx-ins-bar .nx-ins-live i { width: 6px; height: 6px; border-radius: 50%; background: #3ee3a1; }
.nx-ins-crawl.is-done .nx-ins-live { background: rgba(130,87,255,.14); color: var(--purple-light); }
.nx-ins-crawl.is-done .nx-ins-live i { background: var(--purple-light); }
.nx-ins-bar em { margin-left: auto; font-style: normal; font-size: .66rem; border: 1px solid var(--nx-line); border-radius: 999px; padding: 2px 8px; }
.nx-crawl-count { font-variant-numeric: tabular-nums; }
.nx-crawl-count b { color: var(--text); }
.nx-crawl-list { list-style: none; margin: 0; padding: 6px 8px; display: grid; align-content: start; }
.nx-crawl-row { position: relative; display: grid; grid-template-columns: 132px 1fr auto; grid-template-areas: "path bar pill" "path find pill"; column-gap: 14px; row-gap: 3px; align-items: center; min-height: 52px; padding: 8px 10px 8px 14px; border-radius: 12px; color: var(--muted); }
.nx-crawl-row::before { content: ""; position: absolute; left: 0; top: 10px; bottom: 10px; width: 3px; border-radius: 3px; background: transparent; transition: background .3s ease; }
.nx-crawl-row.is-cur { background: rgba(130,87,255,.08); }
.nx-crawl-row.is-cur::before { background: var(--purple-light); box-shadow: 0 0 12px rgba(169,141,255,.8); }
.nx-crawl-row.is-ok::before { background: #3ee3a1; }
.nx-crawl-path { grid-area: path; display: grid; gap: 1px; min-width: 0; }
.nx-crawl-path b { font-size: .86rem; color: var(--text); font-weight: 700; }
.nx-crawl-path small { font-size: .72rem; color: var(--muted); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }
.nx-crawl-bar { grid-area: bar; display: block; height: 4px; border-radius: 2px; background: rgba(255,255,255,.08); overflow: hidden; }
.nx-crawl-bar i { display: block; height: 100%; width: 0; border-radius: 2px; background: linear-gradient(90deg, var(--purple), var(--purple-light), var(--cyan)); transition: width 1.1s cubic-bezier(.2,.7,.2,1); }
.nx-crawl-row.is-ok .nx-crawl-bar i { width: 100%; background: #3ee3a1; transition: width .3s ease, background .3s ease; }
.nx-crawl-find { grid-area: find; font-size: .76rem; color: var(--muted); opacity: 0; transform: translateY(3px); transition: opacity .35s ease, transform .4s var(--nx-ease); }
.nx-crawl-row.is-ok .nx-crawl-find { opacity: 1; transform: none; color: var(--nx-ink-2); }
.nx-crawl-pill { grid-area: pill; justify-self: end; padding: 4px 9px; border-radius: 999px; font-size: .64rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; background: rgba(62,227,161,.12); color: #3ee3a1; opacity: 0; transform: scale(.85); transition: opacity .3s ease, transform .35s cubic-bezier(.2,.8,.2,1.3); }
.nx-crawl-row.is-ok .nx-crawl-pill { opacity: 1; transform: none; }
.nx-crawl-row.is-cur .nx-crawl-pill { opacity: .9; transform: none; background: rgba(130,87,255,.14); color: var(--purple-light); }
.nx-crawl-foot { display: grid; grid-template-columns: auto 1fr 1fr 1fr; gap: 14px; align-items: center; padding: 14px 16px; border-top: 1px solid var(--nx-line); background: rgba(255,255,255,.015); }
.nx-crawl-score { display: flex; align-items: center; gap: 10px; }
.nx-crawl-score svg { width: 48px; height: 48px; transform: rotate(-90deg); }
.nx-crawl-score circle { fill: none; stroke-width: 4; }
.nx-crawl-score .t { stroke: rgba(255,255,255,.08); }
.nx-crawl-score .f { stroke: var(--purple-light); stroke-linecap: round; stroke-dasharray: 62 38; transition: stroke-dasharray 1s var(--nx-ease), stroke .4s ease; }
.nx-ins-crawl.is-done .nx-crawl-score .f { stroke: #3ee3a1; }
.nx-crawl-score b, .nx-crawl-stat b { display: block; font-family: "Manrope", Inter, sans-serif; font-size: 1.15rem; font-weight: 800; letter-spacing: -.02em; color: var(--text); font-variant-numeric: tabular-nums; line-height: 1.1; }
.nx-crawl-score span, .nx-crawl-stat span { display: block; margin-top: 2px; font-size: .68rem; color: var(--muted); }
.nx-crawl-stat b.is-up { color: #3ee3a1; }
/* Figures */
.nx-ins-stats { display: grid; gap: 16px; align-content: start; }
.nx-ins-stat { padding: 26px 26px 24px; border-radius: 20px; border: 1px solid var(--nx-line); background: rgba(255,255,255,.025); }
.nx-ins-stat.is-big { border-color: rgba(169,141,255,.35); background: radial-gradient(120% 120% at 0% 0%, rgba(130,87,255,.18), transparent 60%), rgba(255,255,255,.025); }
.nx-ins-k { margin: 0; font-size: .74rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--purple-light); }
.nx-ins-n { margin: 10px 0 0; font-family: "Manrope", Inter, sans-serif; font-size: clamp(2.1rem, 3.6vw, 3.2rem); font-weight: 800; letter-spacing: -.035em; line-height: 1; color: var(--text); font-variant-numeric: tabular-nums; }
.nx-ins-stat.is-big .nx-ins-n { font-size: clamp(2.3rem, 4.6vw, 4rem); }
.nx-ins-n .nx-ins-cur { font-size: .62em; vertical-align: .22em; margin-right: 2px; color: var(--purple-light); }
.nx-ins-n .nx-ins-cents { font-size: .5em; color: var(--muted); }
.nx-ins-n.is-done { animation: nx-ins-glow 1.2s ease-out; }
.nx-ins-s { margin: 12px 0 0; font-size: .9rem; line-height: 1.55; color: var(--nx-ink-2); }
.nx-ins-stats .button { justify-self: start; margin-top: 6px; }
.nx-ins-note { margin: 22px 0 0; font-size: .76rem; line-height: 1.5; color: var(--muted); max-width: 60rem; }
@keyframes nx-ins-glow { 0% { text-shadow: 0 0 0 rgba(169,141,255,0); } 35% { text-shadow: 0 0 28px rgba(169,141,255,.75); } 100% { text-shadow: 0 0 0 rgba(169,141,255,0); } }

@media (max-width: 1020px) { .nx-ins-grid { grid-template-columns: 1fr; gap: 24px; } }
@media (max-width: 720px) {
  .nx-ins { padding-top: 72px; }
  .nx-crawl-row { grid-template-columns: 1fr auto; grid-template-areas: "path pill" "bar bar" "find find"; min-height: 74px; row-gap: 5px; }
  .nx-crawl-foot { grid-template-columns: repeat(3, 1fr); row-gap: 14px; }
  .nx-crawl-score { grid-column: 1 / -1; }
  .nx-ins-stat { padding: 20px 18px; }
  .nx-ins-feed li em { justify-self: start; }
  .nx-ins-stats .button { justify-self: stretch; text-align: center; }
}
@media (prefers-reduced-motion: reduce) {
  .nx-crawl-row::before, .nx-crawl-bar i, .nx-crawl-find, .nx-crawl-pill, .nx-crawl-score .f { transition: none; }
  .nx-ins-n.is-done { animation: none; }
}
