/* =============================================================================
 * Lattice marketing site
 * Brand cues mirror the developer portal (portal.css):
 *   bg #0f1117 · panels #1a1d29 / #21263a · border #2c3147
 *   text #e6e9f2 · muted #8b91a7 · accent (indigo) #6d7cff · accent-2 (mint) #4cd6b4
 * ========================================================================== */

:root {
  --bg:        #0f1117;
  --bg-2:      #0b0d13;
  --panel:     #1a1d29;
  --panel-2:   #21263a;
  --border:    #2c3147;
  --text:      #e6e9f2;
  --muted:     #8b91a7;
  --accent:    #6d7cff;
  --accent-2:  #4cd6b4;
  --danger:    #ff6b6b;
  --warn:      #f0b429;

  --grad: linear-gradient(120deg, #6d7cff 0%, #8a6dff 45%, #4cd6b4 100%);
  --radius: 14px;
  --radius-lg: 22px;
  --maxw: 1180px;
  --ease: cubic-bezier(.16,.84,.44,1);

  --shadow-1: 0 8px 30px rgba(0,0,0,.35);
  --shadow-glow: 0 0 0 1px rgba(109,124,255,.25), 0 18px 60px -20px rgba(109,124,255,.45);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 84px; }

body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
.muted { color: var(--muted); }
.grad {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

code, .code-block code { font-family: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace; }
code.inline {
  background: var(--panel-2); color: var(--accent-2);
  padding: 2px 7px; border-radius: 6px; font-size: .9em;
}

h1, h2, h3, h4 { line-height: 1.15; letter-spacing: -.02em; margin: 0; }

/* ---- buttons ----------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-size: 15px; font-weight: 600; cursor: pointer;
  padding: 11px 20px; border-radius: 10px; border: 1px solid transparent;
  transition: transform .18s var(--ease), box-shadow .18s var(--ease),
              background .18s var(--ease), border-color .18s var(--ease), color .18s var(--ease);
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn-lg { padding: 15px 28px; font-size: 16px; border-radius: 12px; }

.btn-primary {
  background: var(--accent); color: #fff;
  box-shadow: 0 10px 30px -10px rgba(109,124,255,.7);
}
.btn-primary:hover { background: #7d8aff; box-shadow: 0 16px 40px -12px rgba(109,124,255,.85); }

.btn-outline { border-color: var(--border); color: var(--text); background: rgba(255,255,255,.02); }
.btn-outline:hover { border-color: var(--accent); color: #fff; background: rgba(109,124,255,.08); }

.btn-ghost { color: var(--muted); }
.btn-ghost:hover { color: var(--text); }

/* ---- NAV ---------------------------------------------------------------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  transition: background .25s var(--ease), border-color .25s var(--ease), backdrop-filter .25s;
  border-bottom: 1px solid transparent;
}
.nav.scrolled {
  background: rgba(15,17,23,.78);
  backdrop-filter: blur(14px) saturate(140%);
  border-bottom-color: var(--border);
}
.nav-inner {
  max-width: var(--maxw); margin: 0 auto;
  display: flex; align-items: center; gap: 28px;
  padding: 16px 24px;
}
.brand {
  display: inline-flex; align-items: center; gap: 10px;
  font-weight: 800; font-size: 20px; letter-spacing: -.01em;
}
.brand-mark {
  width: 22px; height: 22px; border-radius: 7px;
  background: var(--grad);
  box-shadow: 0 0 18px rgba(109,124,255,.6);
  position: relative; flex: none;
}
.brand-mark::after {
  content: ""; position: absolute; inset: 4px;
  border-radius: 4px;
  background:
    linear-gradient(transparent 45%, rgba(15,17,23,.85) 45%, rgba(15,17,23,.85) 55%, transparent 55%),
    linear-gradient(90deg, transparent 45%, rgba(15,17,23,.85) 45%, rgba(15,17,23,.85) 55%, transparent 55%);
}
.nav-links { display: flex; gap: 4px; margin-left: 8px; }
.nav-links a {
  color: var(--muted); font-size: 15px; font-weight: 500;
  padding: 8px 12px; border-radius: 8px; transition: color .15s, background .15s;
}
.nav-links a:hover { color: var(--text); background: var(--panel-2); }
.nav-cta { margin-left: auto; display: flex; align-items: center; gap: 10px; }

.nav-toggle {
  display: none; margin-left: auto; flex-direction: column; gap: 5px;
  background: none; border: none; cursor: pointer; padding: 8px;
}
.nav-toggle span { width: 24px; height: 2px; background: var(--text); border-radius: 2px; transition: .25s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---- HERO --------------------------------------------------------------- */
.hero { position: relative; padding: 170px 24px 90px; overflow: hidden; }
.hero-bg { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
.orb {
  position: absolute; border-radius: 50%; filter: blur(70px); opacity: .55;
  will-change: transform;
}
.orb-a { width: 620px; height: 620px; top: -180px; left: -120px;
  background: radial-gradient(circle at 30% 30%, #6d7cff, transparent 70%); }
.orb-b { width: 560px; height: 560px; top: -60px; right: -160px;
  background: radial-gradient(circle at 60% 40%, #4cd6b4, transparent 70%); opacity: .4; }
.grid-overlay {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(109,124,255,.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(109,124,255,.06) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 80% 70% at 50% 0%, #000 30%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 0%, #000 30%, transparent 80%);
}
.hero-inner { position: relative; z-index: 1; max-width: 920px; margin: 0 auto; text-align: center; }
.eyebrow {
  display: inline-block; font-size: 13px; font-weight: 600; letter-spacing: .12em;
  text-transform: uppercase; color: var(--accent-2);
  padding: 7px 14px; border: 1px solid var(--border); border-radius: 999px;
  background: rgba(76,214,180,.06); margin: 0 0 26px;
}
.hero-title { font-size: clamp(34px, 6vw, 66px); font-weight: 900; letter-spacing: -.03em; }
.hero-sub {
  font-size: clamp(16px, 2vw, 20px); color: var(--muted);
  max-width: 680px; margin: 24px auto 0;
}
.hero-sub em { color: var(--text); font-style: normal; }
.hero-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin-top: 36px; }
.hero-badges {
  list-style: none; padding: 0; margin: 48px auto 0; max-width: 760px;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px;
}
.hero-badges li {
  background: linear-gradient(180deg, var(--panel) 0%, rgba(26,29,41,.4) 100%);
  border: 1px solid var(--border); border-radius: var(--radius);
  padding: 16px 12px; font-size: 13px; color: var(--muted);
}
.hero-badges strong { display: block; font-size: 18px; color: var(--text); margin-bottom: 4px; letter-spacing: -.02em; }

/* ---- ENGINES STRIP ------------------------------------------------------ */
.strip {
  max-width: var(--maxw); margin: 0 auto; padding: 8px 24px 8px;
  display: flex; align-items: center; gap: 28px; flex-wrap: wrap; justify-content: center;
}
.strip-label { font-size: 13px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.strip-logos { display: flex; gap: 14px; flex-wrap: wrap; justify-content: center; }
.engine-chip {
  display: inline-flex; flex-direction: column; gap: 1px;
  padding: 10px 18px; border: 1px solid var(--border); border-radius: 12px;
  background: var(--panel); font-weight: 700; font-size: 15px;
  transition: border-color .2s, transform .2s;
}
.engine-chip small { font-weight: 500; font-size: 11px; color: var(--muted); }
.engine-chip:hover { border-color: var(--accent); transform: translateY(-2px); }

/* ---- SECTION SCAFFOLD --------------------------------------------------- */
.section { max-width: var(--maxw); margin: 0 auto; padding: 96px 24px; }
.section-head { max-width: 740px; margin: 0 auto 56px; text-align: center; }
.kicker {
  font-size: 13px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: var(--accent); margin: 0 0 14px;
}
.section-head h2 { font-size: clamp(28px, 4vw, 42px); font-weight: 800; }
.lede { color: var(--muted); font-size: 18px; margin: 18px 0 0; }
.lede em, .section-head em { color: var(--text); font-style: normal; }

/* ---- FEATURE CARDS ------------------------------------------------------ */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.card {
  position: relative; overflow: hidden;
  background: linear-gradient(180deg, var(--panel) 0%, rgba(26,29,41,.5) 100%);
  border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 30px 26px;
  transition: transform .25s var(--ease), border-color .25s, box-shadow .25s;
}
.card::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit;
  background: radial-gradient(420px circle at var(--mx,50%) var(--my,0%), rgba(109,124,255,.14), transparent 60%);
  opacity: 0; transition: opacity .3s; pointer-events: none;
}
.card:hover { transform: translateY(-6px); border-color: rgba(109,124,255,.5); box-shadow: var(--shadow-glow); }
.card:hover::before { opacity: 1; }
.card h3 { font-size: 20px; margin: 18px 0 10px; }
.card p { color: var(--muted); font-size: 15px; margin: 0; }
.card p em { color: var(--text); font-style: normal; }

.card-ico {
  width: 48px; height: 48px; border-radius: 12px;
  background: linear-gradient(140deg, rgba(109,124,255,.18), rgba(76,214,180,.12));
  border: 1px solid var(--border);
  display: grid; place-items: center; position: relative;
}
.card-ico::after {
  content: ""; width: 22px; height: 22px;
  background: var(--accent-2);
  -webkit-mask-size: contain; mask-size: contain;
  -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat;
  -webkit-mask-position: center; mask-position: center;
}
/* simple inline SVG icons via mask */
.card-ico[data-ico="predict"]::after  { -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M3 13h4l2 5 4-12 2 7h6v2h-8l-1-4-3 9-3-7H3z'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M3 13h4l2 5 4-12 2 7h6v2h-8l-1-4-3 9-3-7H3z'/%3E%3C/svg%3E"); }
.card-ico[data-ico="authority"]::after { -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M12 2l8 4v6c0 5-3.5 8-8 10-4.5-2-8-5-8-10V6z'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M12 2l8 4v6c0 5-3.5 8-8 10-4.5-2-8-5-8-10V6z'/%3E%3C/svg%3E"); }
.card-ico[data-ico="engine"]::after { -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M4 4h7v7H4zM13 4h7v7h-7zM4 13h7v7H4zM13 13h7v7h-7z'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M4 4h7v7H4zM13 4h7v7h-7zM4 13h7v7H4zM13 13h7v7h-7z'/%3E%3C/svg%3E"); }
.card-ico[data-ico="wire"]::after { -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M2 11h6v2H2zm14 0h6v2h-6zM9 7h6v2H9zm0 8h6v2H9zM11 9h2v6h-2z'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M2 11h6v2H2zm14 0h6v2h-6zM9 7h6v2H9zm0 8h6v2H9zM11 9h2v6h-2z'/%3E%3C/svg%3E"); }
.card-ico[data-ico="nat"]::after { -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M12 2a10 10 0 100 20 10 10 0 000-20zm0 2c1.5 1.7 2.5 4.6 2.5 8s-1 6.3-2.5 8c-1.5-1.7-2.5-4.6-2.5-8s1-6.3 2.5-8zM4.3 9h3.2a18 18 0 000 6H4.3a8 8 0 010-6zm12.2 0h3.2a8 8 0 010 6h-3.2a18 18 0 000-6z'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M12 2a10 10 0 100 20 10 10 0 000-20zm0 2c1.5 1.7 2.5 4.6 2.5 8s-1 6.3-2.5 8c-1.5-1.7-2.5-4.6-2.5-8s1-6.3 2.5-8zM4.3 9h3.2a18 18 0 000 6H4.3a8 8 0 010-6zm12.2 0h3.2a8 8 0 010 6h-3.2a18 18 0 000-6z'/%3E%3C/svg%3E"); }
.card-ico[data-ico="shield"]::after { -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M12 2l8 4v6c0 5-3.5 8-8 10-4.5-2-8-5-8-10V6zm-1 13l5-5-1.4-1.4L11 12.2 9.4 10.6 8 12z'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M12 2l8 4v6c0 5-3.5 8-8 10-4.5-2-8-5-8-10V6zm-1 13l5-5-1.4-1.4L11 12.2 9.4 10.6 8 12z'/%3E%3C/svg%3E"); }

/* ---- SPLIT FEATURE (alternating) --------------------------------------- */
.feature-split {
  display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center;
}
.feature-split.reverse .split-text { order: 2; }
.feature-split h2 { font-size: clamp(26px, 3.4vw, 38px); font-weight: 800; margin-bottom: 18px; }
.split-text p { color: var(--muted); font-size: 17px; margin: 0 0 16px; }
.split-text p em { color: var(--text); font-style: normal; }
.split-text .btn { margin-top: 10px; }
.check-list { list-style: none; padding: 0; margin: 0 0 24px; }
.check-list li { position: relative; padding: 7px 0 7px 30px; color: var(--text); font-size: 15px; }
.check-list li::before {
  content: ""; position: absolute; left: 0; top: 12px;
  width: 18px; height: 18px; border-radius: 6px;
  background: rgba(76,214,180,.15); border: 1px solid var(--accent-2);
}
.check-list li::after {
  content: ""; position: absolute; left: 5px; top: 15px; width: 8px; height: 5px;
  border-left: 2px solid var(--accent-2); border-bottom: 2px solid var(--accent-2);
  transform: rotate(-45deg);
}

/* write-once flow visual */
.split-visual { display: flex; justify-content: center; }
.flow {
  width: 100%; max-width: 420px;
  background: var(--panel); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 28px; display: flex; flex-direction: column; align-items: center; gap: 6px;
  box-shadow: var(--shadow-1);
}
.flow-node {
  width: 100%; text-align: center; padding: 16px;
  border: 1px solid var(--border); border-radius: 12px; background: var(--panel-2);
}
.flow-source { background: linear-gradient(140deg, rgba(109,124,255,.2), rgba(76,214,180,.1)); border-color: rgba(109,124,255,.5); }
.flow-node-accent { border-color: rgba(76,214,180,.55); background: rgba(76,214,180,.08); }
.flow-tag { display: block; font-weight: 700; font-size: 16px; }
.flow-sub { display: block; font-size: 12.5px; color: var(--muted); margin-top: 3px; }
.flow-fork { width: 2px; height: 26px; background: linear-gradient(var(--accent), var(--accent-2)); margin: 4px 0; }
.flow-targets { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; width: 100%; }

/* live-ops console mock */
.console-card {
  width: 100%; max-width: 460px;
  background: var(--bg-2); border: 1px solid var(--border); border-radius: var(--radius-lg);
  overflow: hidden; box-shadow: var(--shadow-1);
}
.console-bar {
  display: flex; align-items: center; gap: 7px;
  padding: 12px 16px; background: var(--panel); border-bottom: 1px solid var(--border);
}
.console-bar .dot { width: 11px; height: 11px; border-radius: 50%; background: var(--border); }
.console-bar .dot:nth-child(1) { background: #ff6b6b; }
.console-bar .dot:nth-child(2) { background: #f0b429; }
.console-bar .dot:nth-child(3) { background: #4cd6b4; }
.console-title { margin-left: 8px; font-size: 13px; color: var(--muted); }
.console-body { padding: 20px; }
.metric-row { display: grid; grid-template-columns: repeat(3,1fr); gap: 12px; margin-bottom: 18px; }
.metric { background: var(--panel); border: 1px solid var(--border); border-radius: 10px; padding: 12px; text-align: center; }
.metric .m-val { display: block; font-size: 22px; font-weight: 800; color: var(--accent-2); letter-spacing: -.02em; }
.metric .m-lbl { display: block; font-size: 11px; color: var(--muted); margin-top: 3px; }
.bars { display: flex; align-items: flex-end; gap: 8px; height: 90px; padding: 12px; background: var(--panel); border: 1px solid var(--border); border-radius: 10px; margin-bottom: 14px; }
.bars span { flex: 1; height: var(--h); background: linear-gradient(var(--accent), rgba(109,124,255,.25)); border-radius: 4px 4px 0 0; }
.console-log { font-family: "JetBrains Mono", monospace; font-size: 12px; display: flex; flex-direction: column; gap: 6px; }
.console-log span { color: var(--muted); }
.console-log b { font-style: normal; }
.console-log b.ok { color: var(--accent-2); }
.console-log b.warn { color: var(--warn); }

/* ---- COMPARISON TABLE --------------------------------------------------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius-lg); background: var(--panel); }
.compare { width: 100%; border-collapse: collapse; min-width: 720px; }
.compare th, .compare td { text-align: left; padding: 16px 18px; border-bottom: 1px solid var(--border); font-size: 14.5px; vertical-align: top; }
.compare thead th { font-size: 14px; color: var(--muted); font-weight: 600; background: var(--panel-2); position: sticky; top: 0; }
.compare tbody th { color: var(--text); font-weight: 600; }
.compare tbody tr:last-child th, .compare tbody tr:last-child td { border-bottom: none; }
.compare td { color: var(--muted); }
.compare .col-lattice { color: var(--text); background: rgba(109,124,255,.07); font-weight: 500; }
.compare thead .col-lattice { color: #fff; background: rgba(109,124,255,.18); font-weight: 700; }
.compare em { color: var(--text); font-style: normal; }
.yes { color: var(--accent-2); font-weight: 600; }
.meh { color: var(--warn); }
.no  { color: var(--muted); }

/* ---- CODE SHOWCASE ------------------------------------------------------ */
.code-showcase {
  max-width: 880px; margin: 0 auto;
  background: var(--bg-2); border: 1px solid var(--border); border-radius: var(--radius-lg);
  overflow: hidden; box-shadow: var(--shadow-1);
}
.code-tabs { display: flex; gap: 4px; padding: 12px 12px 0; background: var(--panel); border-bottom: 1px solid var(--border); }
.code-tab {
  background: none; border: none; color: var(--muted); cursor: pointer;
  font-family: inherit; font-size: 14px; font-weight: 600; padding: 10px 16px;
  border-radius: 8px 8px 0 0; border-bottom: 2px solid transparent;
}
.code-tab.active { color: var(--text); border-bottom-color: var(--accent); background: var(--bg-2); }
.code-block { display: none; margin: 0; padding: 24px 26px; overflow-x: auto; font-size: 13.5px; line-height: 1.7; }
.code-block.active { display: block; }
.code-block code { color: #c7cce0; white-space: pre; }
.c-key  { color: #8a6dff; }
.c-type { color: #4cd6b4; }
.c-attr { color: #6d7cff; }
.c-fn   { color: #f0b429; }
.c-str  { color: #9ad17f; }
.c-cmt  { color: #5d6480; font-style: italic; }
.code-foot { text-align: center; color: var(--muted); font-size: 14px; margin-top: 20px; }
.code-foot a { color: var(--accent); }
.code-foot a:hover { text-decoration: underline; }

/* ---- MIGRATE ------------------------------------------------------------ */
.migrate { padding-top: 40px; }
.migrate-card {
  display: grid; grid-template-columns: 1.2fr 1fr; gap: 48px; align-items: center;
  background:
    radial-gradient(600px circle at 0% 0%, rgba(109,124,255,.12), transparent 60%),
    linear-gradient(180deg, var(--panel) 0%, rgba(26,29,41,.5) 100%);
  border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 48px;
}
.migrate-text h2 { font-size: clamp(24px, 3vw, 34px); font-weight: 800; margin-bottom: 16px; }
.migrate-text p { color: var(--muted); font-size: 16px; margin: 0 0 22px; }
.migrate-text strong { color: var(--accent-2); }
.migrate-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.migrate-diff {
  background: var(--bg-2); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 18px; font-family: "JetBrains Mono", monospace; font-size: 12.5px;
}
.diff-line { display: flex; gap: 10px; padding: 4px 8px; border-radius: 6px; }
.diff-line span { width: 12px; color: var(--muted); }
.diff-line code { background: none; color: #c7cce0; }
.diff-rm  { background: rgba(255,107,107,.08); }
.diff-rm span, .diff-rm code { color: #ff9a9a; }
.diff-add { background: rgba(76,214,180,.08); }
.diff-add span, .diff-add code { color: #7fe6c9; }
.diff-flag { margin-top: 12px; padding: 8px 10px; border-radius: 6px; background: rgba(240,180,41,.1); color: var(--warn); }
.diff-flag b { color: var(--warn); }

/* ---- FINAL CTA ---------------------------------------------------------- */
.cta { position: relative; overflow: hidden; padding: 110px 24px; text-align: center; }
.cta-bg { position: absolute; inset: 0; z-index: 0; }
.orb-c { position: absolute; width: 700px; height: 700px; left: 50%; top: 50%; transform: translate(-50%,-50%);
  background: radial-gradient(circle, rgba(109,124,255,.22), transparent 65%); filter: blur(40px); }
.cta-inner { position: relative; z-index: 1; max-width: 640px; margin: 0 auto; }
.cta h2 { font-size: clamp(30px, 4.5vw, 48px); font-weight: 900; letter-spacing: -.03em; }
.cta p { color: var(--muted); font-size: 18px; margin: 18px auto 32px; max-width: 520px; }
.cta-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ---- FOOTER ------------------------------------------------------------- */
.footer { border-top: 1px solid var(--border); background: var(--bg-2); }
.footer-inner {
  max-width: var(--maxw); margin: 0 auto; padding: 56px 24px 36px;
  display: grid; grid-template-columns: 1.4fr 2fr; gap: 40px;
}
.footer-brand .brand { margin-bottom: 12px; }
.footer-brand p { max-width: 280px; font-size: 14px; }
.footer-cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.footer-col h4 { font-size: 13px; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); margin-bottom: 14px; }
.footer-col a { display: block; color: var(--text); font-size: 14.5px; padding: 5px 0; opacity: .85; transition: opacity .15s, color .15s; }
.footer-col a:hover { opacity: 1; color: var(--accent); }
.footer-base {
  max-width: var(--maxw); margin: 0 auto; padding: 20px 24px 36px;
  border-top: 1px solid var(--border);
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: 13px;
}

/* ---- REVEAL ANIMATIONS -------------------------------------------------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
/* gentle stagger for grids */
.cards .card.reveal:nth-child(2) { transition-delay: .07s; }
.cards .card.reveal:nth-child(3) { transition-delay: .14s; }
.cards .card.reveal:nth-child(4) { transition-delay: .07s; }
.cards .card.reveal:nth-child(5) { transition-delay: .14s; }
.cards .card.reveal:nth-child(6) { transition-delay: .21s; }
.hero .reveal:nth-child(2) { transition-delay: .06s; }
.hero .reveal:nth-child(3) { transition-delay: .12s; }
.hero .reveal:nth-child(4) { transition-delay: .18s; }
.hero .reveal:nth-child(5) { transition-delay: .24s; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn:hover, .card:hover, .engine-chip:hover { transform: none; }
  .orb { animation: none !important; }
}

/* ---- RESPONSIVE --------------------------------------------------------- */
@media (max-width: 980px) {
  .feature-split { grid-template-columns: 1fr; gap: 36px; }
  .feature-split.reverse .split-text { order: 0; }
  .migrate-card { grid-template-columns: 1fr; gap: 32px; padding: 36px 28px; }
  .footer-inner { grid-template-columns: 1fr; }
}
@media (max-width: 820px) {
  .nav-links { display: none; }
  .nav-cta { display: none; }
  .nav-toggle { display: flex; }
  .nav.menu-open .nav-links {
    display: flex; flex-direction: column; position: absolute; top: 100%; left: 0; right: 0;
    background: rgba(15,17,23,.97); backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--border); padding: 16px 24px; gap: 4px;
  }
  .nav.menu-open .nav-links a { padding: 12px; font-size: 16px; }
  .cards { grid-template-columns: 1fr 1fr; }
  .hero-badges { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  .hero { padding-top: 130px; }
  .cards { grid-template-columns: 1fr; }
  .flow-targets { grid-template-columns: 1fr; }
  .footer-cols { grid-template-columns: 1fr 1fr; }
  .footer-base { flex-direction: column; gap: 8px; }
  .section { padding: 64px 20px; }
}
