/* ============================================================================
   LucidFlow — Landing Page
   Design system: LucidFlow Brand Kit palette + editorial "Monad" grammar.
   Calm, intelligent, editorial, precise. Serif headlines + mono UI.
   ============================================================================ */

:root {
  /* --- Brand palette (LucidFlow Brand Kit) --- */
  --canvas:      #f7f4ee;
  --canvas-2:    #fbf9f4;
  --mist:        #d6e0d4;
  --mist-soft:   #e7ede4;
  --peach:       #e8a070;
  --sage:        #8aa890;
  --amber:       #d49858;
  --ink:         #1a1a1a;
  --ink-soft:    #242424;
  --muted:       #5d5a55;
  --faint:       #8b8780;
  --line:        rgba(26, 26, 26, 0.12);
  --line-soft:   rgba(26, 26, 26, 0.07);

  /* --- Decorative gradients (accent only) --- */
  --wash-sage:  radial-gradient(120% 120% at 85% 12%, rgba(138,168,144,.55), rgba(138,168,144,0) 60%);
  --wash-peach: radial-gradient(120% 120% at 88% 10%, rgba(232,160,112,.50), rgba(232,160,112,0) 58%);
  --wash-amber: radial-gradient(120% 120% at 88% 10%, rgba(212,152,88,.48), rgba(212,152,88,0) 58%);
  --wash-mist:  radial-gradient(120% 120% at 85% 12%, rgba(214,224,212,.85), rgba(214,224,212,0) 62%);
  --aurora: linear-gradient(115deg, var(--sage) 0%, var(--mist) 32%, var(--peach) 66%, var(--amber) 100%);

  /* --- Type --- */
  --serif: "Noto Serif", "Untitled Serif", Georgia, Cambria, "Times New Roman", serif;
  --mono:  "IBM Plex Mono", "ABC Diatype Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  /* --- Scale --- */
  --t-caption: 12px;
  --t-body-sm: 14px;
  --t-body:    16px;
  --t-sub:     20px;
  --t-h-sm:    clamp(22px, 2.4vw, 26px);
  --t-h:       clamp(26px, 3.2vw, 34px);
  --t-h-lg:    clamp(34px, 5vw, 52px);
  --t-display: clamp(48px, 9vw, 116px);

  /* --- Spacing --- */
  --s-8: 8px;  --s-16: 16px; --s-24: 24px; --s-32: 32px;
  --s-40: 40px; --s-56: 56px; --s-72: 72px; --s-96: 96px; --s-160: 160px;

  /* --- Shape --- */
  --r-card: 40px;
  --r-card-sm: 24px;
  --r-pill: 100px;
  --r-tag: 2000px;

  --maxw: 1320px;
  --nav-h: 76px;

  --ease: cubic-bezier(.22, 1, .36, 1);
  --ease-soft: cubic-bezier(.4, 0, .2, 1);
}

/* ----------------------------------------------------------------- reset */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
/* global zoom-out: tighter, more composed canvas on desktop.
   Left at 100% on phones so body text stays legible. */
@media (min-width: 901px) { html { zoom: 0.9; } }

body {
  background: var(--canvas);
  color: var(--ink);
  font-family: var(--mono);
  font-size: var(--t-body);
  line-height: 1.5;
  letter-spacing: -0.01em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img, svg, canvas { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }
::selection { background: var(--ink); color: var(--canvas); }

/* page-grain (static, no blend-mode — blend on a fixed full-screen layer
   forces a full-page recomposite every frame and tanks scroll FPS) */
.grain {
  position: fixed; inset: 0; z-index: 1; pointer-events: none; opacity: .5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2'/%3E%3CfeColorMatrix type='matrix' values='0 0 0 0 0.1 0 0 0 0 0.1 0 0 0 0 0.09 0 0 0 0.022 0'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
  will-change: auto;
}
.scroll-progress {
  position: fixed; top: 0; left: 0; height: 2px; width: 100%;
  transform: scaleX(0); transform-origin: 0 50%;
  background: var(--ink); z-index: 200;
}

/* ----------------------------------------------------------------- layout */
.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 32px; }
section { position: relative; }
.section-pad { padding: clamp(80px, 12vw, 168px) 0; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: var(--t-caption); letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--muted); font-weight: 500;
}
.eyebrow::before {
  content: ""; width: 26px; height: 1px; background: var(--ink); opacity: .45;
}
.section-head { max-width: 760px; margin-bottom: clamp(48px, 6vw, 88px); }
.section-head .eyebrow { display: inline-flex; margin-bottom: clamp(20px, 2.4vw, 32px); }
.section-head h2 {
  font-family: var(--serif); font-weight: 400;
  font-size: var(--t-h-lg); line-height: 1.08; letter-spacing: -0.025em;
  margin: 0;
}
.section-head p {
  margin-top: clamp(20px, 2.2vw, 28px); color: var(--muted); font-size: var(--t-sub);
  line-height: 1.55; max-width: 560px; letter-spacing: -0.015em;
}

/* ----------------------------------------------------------------- buttons */
.btn {
  position: relative; display: inline-flex; align-items: center; gap: 12px;
  padding: 17px 30px; border-radius: var(--r-pill);
  font-family: var(--mono); font-size: var(--t-body-sm); font-weight: 500;
  letter-spacing: 0.01em; white-space: nowrap;
  transition: transform .5s var(--ease), background .35s var(--ease), color .35s var(--ease), border-color .35s var(--ease);
}
.btn .arr { transition: transform .5s var(--ease); }
.btn:hover .arr { transform: translateX(5px); }

.btn-primary { background: var(--ink); color: var(--canvas); }
.btn-primary::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit;
  background: var(--aurora); opacity: 0; transition: opacity .45s var(--ease);
  z-index: -1;
}
.btn-primary:hover { color: var(--ink); }
.btn-primary:hover::after { opacity: 1; }

.btn-ghost { border: 1px solid var(--line); color: var(--ink); background: transparent; }
.btn-ghost:hover { border-color: var(--ink); background: rgba(26,26,26,.04); }

.btn-lg { padding: 21px 38px; font-size: var(--t-body); }

/* ----------------------------------------------------------------- nav */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  height: var(--nav-h);
  display: flex; align-items: center;
  transition: height .4s var(--ease), background .4s var(--ease), border-color .4s var(--ease), box-shadow .4s var(--ease);
  border-bottom: 1px solid transparent;
}
.nav.is-stuck {
  height: 62px;
  /* solid translucent fill — NO backdrop-filter: re-blurring the moving
     page behind a pinned bar repaints every scrolled frame and is the
     single worst scroll-jank source on average hardware. */
  background: rgba(249,246,240,.94);
  border-bottom-color: var(--line-soft);
  box-shadow: 0 1px 0 rgba(26,26,26,.02);
}
.nav .wrap { display: flex; align-items: center; justify-content: space-between; }
.brand { display: flex; align-items: center; gap: 13px; }
.brand img { width: 34px; height: 34px; }
.brand .word {
  font-family: var(--serif); font-size: 22px; letter-spacing: -0.03em; color: var(--ink);
}
.nav-links { display: flex; align-items: center; gap: 6px; }
.nav-links a {
  position: relative; padding: 9px 15px; font-size: var(--t-body-sm); color: var(--ink-soft);
}
.nav-links a::after {
  content: ""; position: absolute; left: 15px; right: 15px; bottom: 4px; height: 1px;
  background: var(--ink); transform: scaleX(0); transform-origin: 0 50%;
  transition: transform .4s var(--ease);
}
.nav-links a:hover::after { transform: scaleX(1); }
.nav-cta { display: flex; align-items: center; gap: 14px; }
.nav-cta .login { font-size: var(--t-body-sm); padding: 9px 14px; color: var(--ink-soft); }
.nav-cta .login:hover { color: var(--ink); }
.nav-cta .btn { padding: 12px 24px; }
.nav-toggle { display: none; }

/* ----------------------------------------------------------------- hero */
.hero { position: relative; padding-top: calc(var(--nav-h) + 40px); overflow: hidden; }
/* split hero — copy left · live product showcase right */
.hero-inner {
  position: relative; z-index: 2;
  display: grid; align-items: center;
  grid-template-columns: minmax(0, 0.78fr) minmax(0, 1.22fr);
  gap: clamp(28px, 3.6vw, 56px);
  min-height: calc(100vh - var(--nav-h) - 40px);
  padding-bottom: clamp(48px, 7vw, 96px);
}
.hero-inner > * { position: relative; z-index: 2; }
.hero-copy { display: flex; flex-direction: column; min-width: 0; text-align: left; }
.hero .hero-copy h1 { font-size: clamp(34px, 3.9vw, 60px); max-width: none; }
/* let the dashboard run longer toward the right edge */
.showcase { margin-right: clamp(-72px, -3.4vw, -8px); }
.hero .hero-copy .hero-sub {
  max-width: 40ch; font-size: clamp(14px, 1vw, 15.5px); line-height: 1.55;
  margin-top: 22px;
}
.hero .hero-copy .hero-meta {
  flex-wrap: nowrap; gap: clamp(14px, 1.6vw, 24px); max-width: none;
}
.hero .hero-copy .hero-meta .k { font-size: clamp(18px, 1.7vw, 22px); }
.hero .hero-copy .hero-meta .v { font-size: 10px; letter-spacing: 0.1em; white-space: nowrap; }
.hero .hero-copy .hero-sub { max-width: 42ch; }
.hero .hero-copy .hero-meta { max-width: 100%; }

/* soft warm aura behind the showcase (right side) */
.hero-aura {
  position: absolute; right: -8%; left: auto; top: 50%; z-index: 0; pointer-events: none;
  width: min(940px, 74vw); height: 720px; transform: translateY(-50%);
  background:
    radial-gradient(44% 50% at 30% 34%, rgba(138,168,144,.32), transparent 70%),
    radial-gradient(46% 52% at 72% 62%, rgba(232,160,112,.30), transparent 72%),
    radial-gradient(38% 42% at 56% 42%, rgba(212,152,88,.18), transparent 70%);
  filter: blur(8px); opacity: .8;
  animation: auraFloat 17s var(--ease-soft) infinite;
}
@keyframes auraFloat {
  0%,100% { transform: translateY(-50%) translateY(0) scale(1); }
  50%     { transform: translateY(-50%) translateY(-16px) scale(1.045); }
}

/* product showcase — a real-looking LucidFlow dashboard */
.showcase {
  position: relative; z-index: 2; width: 100%; min-width: 0; margin: 0;
  perspective: 1700px;
}
.sc-tilt {
  border-radius: 18px; overflow: hidden; background: var(--canvas-2);
  border: 1px solid var(--line); transform-style: preserve-3d; will-change: transform;
  box-shadow: 0 1px 0 rgba(255,255,255,.55) inset,
              0 34px 80px -40px rgba(26,26,26,.45),
              0 10px 26px -20px rgba(26,26,26,.30);
}
.sc-bar {
  display: flex; align-items: center; gap: 14px; padding: 12px 18px;
  border-bottom: 1px solid var(--line-soft); background: var(--canvas);
}
.sc-traffic { display: flex; gap: 6px; }
.sc-traffic i { width: 9px; height: 9px; border-radius: 50%; }
.sc-traffic i:nth-child(1){ background: var(--peach); }
.sc-traffic i:nth-child(2){ background: var(--amber); }
.sc-traffic i:nth-child(3){ background: var(--sage); }
.sc-url { flex: 1; text-align: center; font-family: var(--mono);
  font-size: 12px; color: var(--faint); letter-spacing: .02em; }
.sc-live { display: inline-flex; align-items: center; gap: 7px; font-family: var(--mono);
  font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.sc-live i { width: 7px; height: 7px; border-radius: 50%; background: var(--sage);
  box-shadow: 0 0 0 0 rgba(138,168,144,.5); animation: scPulse 2.4s var(--ease-soft) infinite; }
.sc-body { display: grid; grid-template-columns: 196px 1fr; }
.sc-side { display: flex; flex-direction: column; gap: 4px; padding: 20px 14px;
  border-right: 1px solid var(--line-soft); background: var(--canvas); }
.sc-logo { display: flex; align-items: center; gap: 9px; font-family: var(--serif);
  font-size: 17px; letter-spacing: -.02em; color: var(--ink); margin-bottom: 16px; padding: 0 8px; }
.sc-logo img { width: 22px; height: 22px; }
.sc-nav { font-family: var(--mono); font-size: 12.5px; color: var(--muted);
  padding: 9px 12px; border-radius: 10px; letter-spacing: -.01em; }
.sc-nav.is-on { background: rgba(138,168,144,.18); color: var(--ink); }
.sc-foot { margin-top: auto; font-family: var(--mono); font-size: 11px;
  color: var(--faint); padding: 12px; letter-spacing: .08em; }
.sc-main { padding: clamp(20px,2.4vw,28px); display: flex; flex-direction: column;
  gap: 16px; text-align: left; min-width: 0; }
.sc-greet { font-family: var(--serif); font-size: clamp(18px,1.8vw,23px);
  letter-spacing: -.02em; color: var(--ink); }
.sc-greet span { font-family: var(--mono); font-size: 12px; color: var(--faint); letter-spacing: 0; }
.sc-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.sc-kpi { display: flex; flex-direction: column; gap: 6px; padding: 15px;
  border: 1px solid var(--line-soft); border-radius: 14px; background: var(--canvas); min-width: 0; }
.sc-kpi .l { font-family: var(--mono); font-size: 11px; letter-spacing: .03em; color: var(--faint); }
.sc-kpi .v { font-family: var(--serif); font-size: clamp(21px,2.3vw,29px);
  color: var(--ink); letter-spacing: -.02em; }
.sc-kpi .t { font-family: var(--mono); font-size: 11px; }
.sc-kpi .t.up { color: var(--sage); } .sc-kpi .t.dn { color: var(--peach); }
.sc-grid2 { display: grid; grid-template-columns: 1.1fr 1fr; gap: 12px; }
.sc-card { border: 1px solid var(--line-soft); border-radius: 14px; background: var(--canvas);
  padding: 15px 14px; display: flex; flex-direction: column; gap: 11px; min-width: 0; }
.sc-h { font-family: var(--mono); font-size: 12px; color: var(--ink); letter-spacing: .02em; }
.sc-h span { color: var(--faint); }
.spark { width: 100%; height: 116px; display: block; overflow: visible; }
.spark-line { fill: none; stroke: var(--sage); stroke-width: 2.4;
  stroke-linecap: round; stroke-linejoin: round;
  stroke-dasharray: 620; stroke-dashoffset: 620; animation: scDraw 3.2s var(--ease) forwards; }
.spark-fill { fill: rgba(138,168,144,.15); opacity: 0; animation: scFade .9s ease 2.4s forwards; }
.spark-dot { fill: var(--amber); opacity: 0; animation: scFade .5s ease 2.9s forwards; }
.sc-sig { display: flex; align-items: center; gap: 9px; font-family: var(--mono);
  font-size: 11.5px; color: var(--ink); padding: 8px 0; border-bottom: 1px solid var(--line-soft);
  white-space: nowrap; }
.sc-sig:last-child { border-bottom: 0; }
.sc-sig b { font-family: var(--serif); font-size: 14px; min-width: 16px; }
.sc-sig span.nm { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; color: var(--muted); }
.sc-sig i { width: 7px; height: 7px; border-radius: 50%; flex: none; }
.sc-sig i.q { background: var(--sage); } .sc-sig i.t { background: var(--amber); } .sc-sig i.p { background: var(--peach); }

@keyframes scPulse { 0% { box-shadow: 0 0 0 0 rgba(138,168,144,.5); }
  70%,100% { box-shadow: 0 0 0 8px rgba(138,168,144,0); } }
@keyframes scDraw { to { stroke-dashoffset: 0; } }
@keyframes scFade { to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
  .hero-aura, .sc-live i { animation: none; }
  .spark-line { animation: none; stroke-dashoffset: 0; }
  .spark-fill, .spark-dot { animation: none; opacity: 1; }
}
.hero-eyebrow { margin-bottom: 30px; overflow: hidden; }
.hero h1 {
  font-family: var(--serif); font-weight: 400;
  font-size: var(--t-display); line-height: 1.04; letter-spacing: -0.035em;
  max-width: 15ch;
}
.hero h1 .ln {
  display: block; overflow: hidden;
  padding: 0.1em 0.08em; margin: -0.1em -0.08em;
}
.hero h1 .ln > span { display: block; }
.hero h1 em {
  font-style: italic; position: relative;
  background: var(--aurora); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-sub {
  margin-top: 36px; max-width: 50ch; font-size: var(--t-sub);
  line-height: 1.55; color: var(--muted); letter-spacing: -0.015em;
}
.hero-actions { margin-top: 46px; display: flex; gap: 16px; flex-wrap: wrap; align-items: center; }
.hero-meta {
  margin-top: 70px; display: flex; gap: 40px; flex-wrap: wrap;
  padding-top: 28px; border-top: 1px solid var(--line-soft); max-width: 720px;
}
.hero-meta div { display: flex; flex-direction: column; gap: 4px; }
.hero-meta .k { font-family: var(--serif); font-size: 28px; letter-spacing: -0.02em; }
.hero-meta .v { font-size: var(--t-caption); letter-spacing: 0.14em; text-transform: uppercase; color: var(--faint); }

/* ----------------------------- built-with strip (contained, not full-bleed) */
.stack-strip {
  display: flex; align-items: center; gap: clamp(20px, 3vw, 40px);
  padding: 22px 0; border-top: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
}
.stack-label {
  flex: none; font-family: var(--mono); font-size: 11px; letter-spacing: 0.2em;
  text-transform: uppercase; color: var(--faint);
}
.marquee {
  flex: 1; min-width: 0; overflow: hidden; white-space: nowrap;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
}
.marquee-track { display: inline-flex; will-change: transform; animation: marq 34s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee-track span {
  font-family: var(--mono); font-size: var(--t-body-sm); letter-spacing: -0.005em;
  color: var(--muted); display: inline-flex; align-items: center;
  padding: 0 26px;
}
.marquee-track span::after {
  content: ""; width: 4px; height: 4px; border-radius: 50%;
  background: var(--sage); margin-left: 26px; opacity: .8;
}
@keyframes marq { to { transform: translateX(-50%); } }

/* ----------------------------------------------------------------- pillars */
.pillars-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.pillar {
  position: relative; padding: 44px 40px 48px; border-radius: var(--r-card);
  background: var(--canvas-2); border: 1px solid var(--line-soft); overflow: hidden;
  overflow-wrap: break-word; contain: layout paint;
  transition: transform .6s var(--ease), border-color .6s var(--ease);
}
.pillar::before {
  content: ""; position: absolute; inset: 0; opacity: .9; transition: opacity .6s var(--ease);
}
.pillar:nth-child(1)::before { background: var(--wash-sage); }
.pillar:nth-child(2)::before { background: var(--wash-peach); }
.pillar:nth-child(3)::before { background: var(--wash-amber); }
.pillar:hover { transform: translateY(-6px); border-color: var(--line); }
.pillar > * { position: relative; z-index: 1; }
.pillar .num {
  font-family: var(--mono); font-size: var(--t-caption); letter-spacing: 0.2em;
  color: var(--muted);
}
.pillar h3 {
  font-family: var(--serif); font-weight: 400; font-size: var(--t-h); letter-spacing: -0.02em;
  margin: 70px 0 14px; line-height: 1.1;
}
.pillar p { color: var(--muted); font-size: var(--t-body); line-height: 1.55; }

/* ----------------------------------------------------------------- modules */
/* editorial header: terse stacked statement + gradient accent (echoes the
   hero's "illuminated"), framed by a numbered system index. */
.modules-head { max-width: none; margin-bottom: clamp(36px, 4vw, 56px); }
.modules-head h2 {
  font-size: clamp(40px, 6.4vw, 86px); line-height: 0.98; letter-spacing: -0.035em;
}
.modules-head h2 span { display: block; }
.modules-head h2 .ln-b { color: var(--faint); }
.section-head h2 em {
  font-style: italic; color: transparent;
  background: var(--aurora); -webkit-background-clip: text; background-clip: text;
}
.modules-head p { max-width: 60ch; margin-top: clamp(22px, 2.4vw, 32px); }

/* ===== Bento — four equal capability cards in a balanced 2×2.
   Hand-built SVG/CSS art, brand palette, calm motion. ===== */
.bento {
  display: grid; gap: 16px;
  grid-template-columns: 1fr 1fr;
  grid-auto-rows: minmax(310px, auto);
}

.bcard {
  position: relative; display: flex; flex-direction: column;
  border: 1px solid var(--line-soft); border-radius: var(--r-card);
  background: var(--canvas-2); overflow: hidden;
  transition: transform .55s var(--ease), border-color .55s var(--ease);
}
.bcard::before {                 /* single soft corner wash, top-right */
  content: ""; position: absolute; top: 0; right: 0; width: 58%; height: 58%;
  background: radial-gradient(120% 120% at 100% 0, rgba(138,168,144,.18), rgba(138,168,144,0) 62%);
  opacity: .75; transition: opacity .55s var(--ease); pointer-events: none;
}
.bcard:hover { transform: translateY(-5px); border-color: var(--line); }
.bcard:hover::before { opacity: 1; }

.bc-art {
  position: relative; flex: 1; min-height: 0;
  display: flex; align-items: center; justify-content: center;
  padding: clamp(22px, 3vw, 40px) clamp(22px, 3vw, 40px) 6px;
}
.bc-copy { padding: clamp(20px, 2.4vw, 32px) clamp(24px, 3vw, 40px) clamp(26px, 3vw, 38px); }
.bc-kicker {
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.2em;
  text-transform: uppercase; color: var(--sage);
}
.bc-copy h3 {
  font-family: var(--serif); font-weight: 400; color: var(--ink);
  letter-spacing: -0.02em; margin: 14px 0 0;
  font-size: clamp(19px, 1.7vw, 23px); line-height: 1.18;
}
.bc-copy p {
  margin-top: 11px; color: var(--muted);
  font-size: var(--t-body-sm); line-height: 1.55; max-width: 46ch;
}
.flowdiag, .enginediag { width: 100%; height: 100%; max-height: 200px; }

/* --- flow diagram: source rails merge into one unified stream
   (deliberately distinct from the engine card — no rings/scatter) --- */
.flowdiag .fl-rail { fill: none; stroke: rgba(26,26,26,.17); stroke-width: 1.6; stroke-linecap: round; }
.flowdiag .fl-out { stroke: rgba(138,168,144,.6); stroke-width: 2.4; }
.flowdiag .fl-cap { fill: none; stroke: rgba(138,168,144,.75); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.flowdiag .fl-node { fill: url(#gA); }
.flowdiag .fl-src text { font-family: "IBM Plex Mono", monospace; font-size: 11px; fill: var(--faint); }
.flowdiag .fl-src .s1 { fill: var(--sage); }  .flowdiag .fl-src .s2 { fill: var(--peach); }
.flowdiag .fl-src .s3 { fill: var(--amber); } .flowdiag .fl-src .s4 { fill: var(--ink); }
.flowdiag .fl-lbl { font-family: "IBM Plex Mono", monospace; font-size: 10px; fill: var(--faint);
  text-anchor: end; letter-spacing: .14em; text-transform: uppercase; }
.flowdiag .fl-dot { offset-rotate: 0deg; opacity: 0; }
.flowdiag .fl-d1 { fill: var(--sage);  offset-path: path("M30,30 C 110,30 150,92 208,92");  animation: flRun 3s linear infinite; }
.flowdiag .fl-d2 { fill: var(--peach); offset-path: path("M30,68 C 116,68 150,92 208,92");  animation: flRun 3s linear infinite .5s; }
.flowdiag .fl-d3 { fill: var(--amber); offset-path: path("M30,116 C 116,116 150,92 208,92"); animation: flRun 3s linear infinite 1s; }
.flowdiag .fl-d4 { fill: var(--ink);   offset-path: path("M30,154 C 110,154 150,92 208,92"); animation: flRun 3s linear infinite 1.5s; }
.flowdiag .fl-do { fill: var(--sage);  offset-path: path("M214,92 L338,92"); animation: flRun 2.4s linear infinite .4s; }
@keyframes flRun {
  0%   { offset-distance: 0%;   opacity: 0; }
  12%  { opacity: 1; }
  82%  { opacity: 1; }
  100% { offset-distance: 100%; opacity: 0; }
}

/* --- engine diagram --- */
.enginediag { max-height: 200px; }
.enginediag .noise rect { fill: rgba(26,26,26,.28); animation: drift 5s var(--ease-soft) infinite; }
.enginediag .noise rect:nth-child(2){ animation-delay:-1s } .enginediag .noise rect:nth-child(3){ animation-delay:-2s }
.enginediag .noise rect:nth-child(4){ animation-delay:-3s } .enginediag .noise rect:nth-child(5){ animation-delay:-4s }
.enginediag .efunnel { stroke: rgba(26,26,26,.22); stroke-width: 1.2; stroke-dasharray: 2 5; animation: flux 2.4s linear infinite; }
.enginediag .engine { transform-box: fill-box; transform-origin: 180px 94px; }
.enginediag .eng-ring { fill: none; stroke: rgba(26,26,26,.28); stroke-width: 1.4; stroke-dasharray: 30 14; animation: spin 14s linear infinite; transform-box: fill-box; transform-origin: center; }
.enginediag .eng-ring2 { stroke: rgba(212,152,88,.7); animation-duration: 9s; animation-direction: reverse; }
.enginediag .eng-core { fill: url(#gA); animation: breathe 3.4s var(--ease-soft) infinite; transform-box: fill-box; transform-origin: center; }
.enginediag .clean rect:nth-child(1){ fill: rgba(138,168,144,.85) }
.enginediag .clean rect:nth-child(2){ fill: rgba(232,160,112,.8) }
.enginediag .clean rect:nth-child(3){ fill: rgba(212,152,88,.8) }
.enginediag .clean rect:nth-child(4){ fill: rgba(138,168,144,.55) }
.enginediag .clean rect { transform-box: fill-box; transform-origin: left center; animation: grow 3.4s var(--ease-soft) infinite; }
.enginediag .clean rect:nth-child(2){ animation-delay:-.6s } .enginediag .clean rect:nth-child(3){ animation-delay:-1.2s } .enginediag .clean rect:nth-child(4){ animation-delay:-1.8s }
.enginediag .score { font-family: var(--serif); font-size: 30px; fill: var(--sage); text-anchor: end; }

/* --- rules card --- */
.rulebox { width: 100%; display: flex; flex-direction: column; gap: 12px; font-family: var(--mono); }
.rule-expr {
  display: inline-flex; align-items: center; gap: 10px; align-self: flex-start;
  padding: 9px 14px; border: 1px solid var(--line); border-radius: 12px;
  background: var(--canvas); font-size: 12px; color: var(--ink);
}
.rule-expr b { font-weight: 500; }
.rule-expr span { color: var(--sage); font-size: 11px; letter-spacing: .1em; }
.rule-arrow { color: var(--faint); font-size: 16px; padding-left: 8px; }
.rule-out { display: flex; flex-direction: column; gap: 8px; }
.sig {
  display: flex; align-items: center; gap: 10px; font-size: 12.5px; color: var(--ink);
  padding: 9px 13px; border: 1px solid var(--line-soft); border-radius: 12px;
  background: var(--canvas); transition: transform .4s var(--ease), border-color .4s var(--ease);
}
.b-rules:hover .sig:nth-child(1) { transform: translateX(4px); border-color: var(--line); }
.sig i { width: 7px; height: 7px; border-radius: 50%; flex: none; }
.sig .d-q ~ em, .sig em { margin-left: auto; font-style: normal; font-size: 10px;
  letter-spacing: .12em; text-transform: uppercase; color: var(--faint); }
.sig .d-q { background: var(--sage); } .sig .d-t { background: var(--amber); } .sig .d-p { background: var(--peach); }

/* --- deploy card --- */
.envrow { display: flex; align-items: center; gap: 10px; width: 100%; }
.env {
  flex: 1; display: flex; flex-direction: column; gap: 5px; align-items: flex-start;
  padding: 14px 16px; border: 1px solid var(--line-soft); border-radius: 14px;
  background: var(--canvas); font-family: var(--mono); font-size: 13px; color: var(--ink);
}
.env small { color: var(--faint); font-size: 11px; letter-spacing: .04em; }
.env.hot { border-color: rgba(138,168,144,.5); background: rgba(138,168,144,.10); }
.env-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--sage); }
.env-dot.live { background: var(--amber); box-shadow: 0 0 0 0 rgba(212,152,88,.5); animation: pulse 2.4s var(--ease-soft) infinite; }
.env-link { flex: none; width: 26px; height: 1px; background: var(--line); position: relative; overflow: hidden; }
.env-link i { position: absolute; top: -1px; left: -8px; width: 8px; height: 3px; border-radius: 2px; background: var(--sage); animation: hop 2.4s linear infinite; }
.env-link:nth-of-type(4) i { animation-delay: -1.2s; }

@keyframes flux { to { stroke-dashoffset: -40; } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes breathe { 0%,100%{ transform: scale(1); opacity:.85 } 50%{ transform: scale(1.12); opacity:1 } }
@keyframes drift { 0%,100%{ transform: translateX(0) } 50%{ transform: translateX(5px) } }
@keyframes grow { 0%,100%{ transform: scaleX(.7) } 50%{ transform: scaleX(1) } }
@keyframes pulse { 0%{ box-shadow:0 0 0 0 rgba(212,152,88,.5) } 70%,100%{ box-shadow:0 0 0 9px rgba(212,152,88,0) } }
@keyframes hop { 0%{ left:-8px } 100%{ left:26px } }
@media (prefers-reduced-motion: reduce) {
  .flowdiag *, .enginediag *, .env-dot.live, .env-link i { animation: none !important; }
}

/* ----------------------------------------------------------------- metrics */
.metrics { background: var(--ink); color: var(--canvas); border-radius: var(--r-card); overflow: hidden; position: relative; }
.metrics .glow {
  position: absolute; inset: 0; background:
    radial-gradient(60% 80% at 15% 0%, rgba(138,168,144,.28), transparent 60%),
    radial-gradient(50% 70% at 90% 100%, rgba(232,160,112,.22), transparent 60%);
  pointer-events: none;
}
.metrics-inner { position: relative; padding: clamp(56px, 8vw, 104px) clamp(32px, 6vw, 88px); }
.metrics .section-head h2 { color: var(--canvas); }
.metrics .section-head p, .metrics .eyebrow { color: rgba(247,244,238,.62); }
.metrics .eyebrow::before { background: var(--canvas); }
.metric-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px;
  margin-top: 56px; border-top: 1px solid rgba(247,244,238,.16);
}
.metric { padding: 44px 34px; border-right: 1px solid rgba(247,244,238,.16); }
.metric:last-child { border-right: none; }
.metric .num {
  font-family: var(--serif); font-size: clamp(40px, 6vw, 70px); letter-spacing: -0.03em;
  line-height: 1; display: flex; align-items: baseline; gap: 6px;
}
.metric .num .u { font-size: .32em; color: var(--sage); letter-spacing: 0; }
.metric .lbl { margin-top: 16px; font-size: var(--t-body-sm); color: rgba(247,244,238,.7); }
.metric .win { margin-top: 6px; font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: rgba(247,244,238,.4); }

/* ----------------------------------------------------------------- voices */
#voices.section-pad { padding: clamp(64px, 9vw, 120px) 0; }
.voices-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.voice {
  position: relative; display: flex; flex-direction: column;
  border-radius: var(--r-card); border: 1px solid var(--line-soft);
  background: var(--canvas-2); padding: 32px 32px;
  overflow: hidden; overflow-wrap: break-word; contain: layout paint;
  transition: transform .6s var(--ease), border-color .6s var(--ease);
}
.voice:hover { transform: translateY(-6px); border-color: var(--line); }
.voice.wide { grid-column: 1 / -1; padding: 40px 44px; }
.voice::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  opacity: 0; transition: opacity .55s var(--ease); background: var(--wash-mist);
}
.voice:hover::after { opacity: 1; }
.voice.feature {
  background:
    radial-gradient(110% 110% at 94% 6%, rgba(138,168,144,.34), rgba(138,168,144,0) 52%),
    var(--canvas-2);
}
.voice > * { position: relative; z-index: 1; }
.voice .qmark {
  font-family: var(--serif); font-size: 44px; line-height: .8; color: var(--sage);
  height: 22px; margin-bottom: 12px; user-select: none;
}
.voice blockquote {
  font-family: var(--serif); font-weight: 400; color: var(--ink);
  font-size: 14.5px; line-height: 1.62; letter-spacing: -0.01em;
}
.voice blockquote p { margin: 0; }
.voice.wide blockquote {
  font-size: clamp(15.5px, 1.35vw, 18.5px); line-height: 1.58; max-width: 64ch;
}
.voice blockquote .lead {
  display: block; font-style: italic; font-size: 1.04em; color: var(--ink);
  margin-bottom: 10px; letter-spacing: -0.02em;
}
/* Arabic blessing flows inline as the natural close of the quote —
   same color/size as the quote, isolated so bidi stays correct. */
.voice blockquote .ar {
  unicode-bidi: isolate; direction: rtl; color: inherit;
  font-family: "Almarai", "Noto Naskh Arabic", "Segoe UI", sans-serif;
  font-size: 1.02em; line-height: 1.85; margin-inline-start: 7px;
  font-style: normal; font-weight: 400;
}
.voice figcaption {
  margin-top: auto; padding-top: 26px; display: flex; align-items: center; gap: 14px;
}
.voice .avatar {
  flex: none; width: 46px; height: 46px; border-radius: 50%;
  object-fit: cover; border: 1px solid var(--line); background: var(--mist-soft);
}
.voice.wide .avatar { width: 52px; height: 52px; }
.voice .who strong {
  display: block; font-family: var(--mono); font-weight: 500;
  font-size: var(--t-body-sm); letter-spacing: -0.01em; color: var(--ink);
}
.voice .who span {
  display: block; margin-top: 4px; font-size: 11px; letter-spacing: 0.15em;
  text-transform: uppercase; color: var(--faint);
}

/* ----------------------------------------------------------------- faq */
.faq-grid { display: grid; grid-template-columns: 360px 1fr; gap: 64px; }
.faq-list { border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-q {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 30px 0; text-align: left; font-size: var(--t-sub); letter-spacing: -0.015em;
  font-family: var(--serif); color: var(--ink);
}
.faq-ico { position: relative; width: 16px; height: 16px; flex: none; }
.faq-ico::before, .faq-ico::after {
  content: ""; position: absolute; background: var(--ink); transition: transform .45s var(--ease), opacity .45s var(--ease);
}
.faq-ico::before { top: 50%; left: 0; right: 0; height: 1.5px; transform: translateY(-50%); }
.faq-ico::after { left: 50%; top: 0; bottom: 0; width: 1.5px; transform: translateX(-50%); }
.faq-item.open .faq-ico::after { transform: translateX(-50%) scaleY(0); opacity: 0; }
.faq-a { overflow: hidden; height: 0; }
.faq-a div { padding: 0 0 30px; color: var(--muted); font-size: var(--t-body); line-height: 1.6; max-width: 60ch; }

/* ----------------------------------------------------------------- cta */
.cta-band {
  position: relative; border-radius: var(--r-card); overflow: hidden;
  border: 1px solid var(--line-soft);
  /* baked soft-glow gradient instead of 3 blur(60px) filter layers —
     gradients never trigger filter re-rasterization on scroll. */
  background:
    radial-gradient(48% 60% at 14% 8%, rgba(138,168,144,.55), rgba(138,168,144,0) 70%),
    radial-gradient(52% 64% at 88% 92%, rgba(232,160,112,.50), rgba(232,160,112,0) 70%),
    radial-gradient(40% 50% at 60% 50%, rgba(212,152,88,.22), rgba(212,152,88,0) 70%),
    var(--mist-soft);
  padding: clamp(64px, 10vw, 128px) clamp(32px, 6vw, 96px); text-align: center;
}
.cta-band .blob { display: none; }
.cta-band > * { position: relative; z-index: 1; }
.cta-band h2 {
  font-family: var(--serif); font-weight: 400; font-size: var(--t-h-lg);
  letter-spacing: -0.03em; line-height: 1.05; max-width: 16ch; margin: clamp(24px, 2.8vw, 36px) auto 0;
}
.cta-band p { margin: 22px auto 0; color: var(--muted); max-width: 48ch; font-size: var(--t-sub); }
.cta-band .hero-actions { justify-content: center; margin-top: 42px; }

/* ----------------------------------------------------------------- footer */
.footer { background: var(--ink); color: var(--canvas); padding: 96px 0 40px; margin-top: 0; }
.footer-top { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 48px; padding-bottom: 72px; border-bottom: 1px solid rgba(247,244,238,.14); }
.footer-brand .f-mark { width: 38px; margin-bottom: 22px; }
.footer-brand .word { font-family: var(--serif); font-size: 26px; letter-spacing: -0.03em; }
.footer-brand p { margin-top: 16px; color: rgba(247,244,238,.55); font-size: var(--t-body-sm); max-width: 36ch; line-height: 1.6; }
/* collaboration seal — partnership lockup at the top of the footer */
.collab {
  text-align: center; padding: 8px 0 64px; margin-bottom: 64px;
  border-bottom: 1px solid rgba(247,244,238,.14);
}
.collab-label {
  display: block; font-family: var(--mono); font-size: 11px;
  letter-spacing: 0.26em; text-transform: uppercase; color: rgba(247,244,238,.4);
}
.collab-lockup {
  display: flex; align-items: center; justify-content: center;
  gap: clamp(24px, 5vw, 56px); margin: 26px 0 22px;
}
.collab-flow {
  display: inline-flex; align-items: center; gap: 13px;
  font-family: var(--serif); font-size: clamp(22px, 2.4vw, 30px);
  letter-spacing: -0.03em; color: var(--canvas);
}
.collab-flow img { width: clamp(28px, 3vw, 36px); height: auto; }
/* connective tissue: a gradient thread = "structured flow" between brands */
.collab-join {
  width: clamp(40px, 8vw, 96px); height: 1px; flex: none; position: relative;
  background: linear-gradient(90deg, rgba(247,244,238,.18), rgba(247,244,238,.5), rgba(247,244,238,.18));
}
.collab-join::before {
  content: ""; position: absolute; top: 50%; left: 50%;
  width: 6px; height: 6px; border-radius: 50%; transform: translate(-50%,-50%);
  background: var(--aurora);
}
.collab-luc { display: inline-flex; transition: transform .4s var(--ease), opacity .3s var(--ease); }
.collab-luc img { height: clamp(22px, 2.4vw, 30px); width: auto; opacity: .95; }
.collab-luc:hover { transform: translateY(-2px); }
.collab-luc:hover img { opacity: 1; }
.collab-sub {
  display: block; font-family: var(--mono); font-size: var(--t-body-sm);
  color: rgba(247,244,238,.5); letter-spacing: -0.01em;
}
.footer-col h4 { font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase; color: rgba(247,244,238,.45); margin-bottom: 22px; font-weight: 500; }
.footer-col a { display: block; padding: 7px 0; color: rgba(247,244,238,.78); font-size: var(--t-body-sm); transition: color .3s, padding-left .3s var(--ease); }
.footer-col a:hover { color: var(--canvas); padding-left: 6px; }
.footer-bot { display: flex; align-items: center; justify-content: space-between; padding-top: 32px; gap: 20px; flex-wrap: wrap; }
.footer-bot p { color: rgba(247,244,238,.45); font-size: var(--t-caption); letter-spacing: 0.04em; }
.footer-bot .think { font-family: var(--serif); color: rgba(247,244,238,.7); font-size: var(--t-body-sm); }

/* ----------------------------------------------------------------- reveal */
[data-reveal] { opacity: 0; transform: translateY(28px); }
.is-ready [data-reveal] { transition: opacity 1s var(--ease), transform 1s var(--ease); }
[data-reveal].in { opacity: 1; transform: none; }
[data-reveal-stagger] > * { opacity: 0; transform: translateY(30px); }
.is-ready [data-reveal-stagger] > * { transition: opacity .9s var(--ease), transform .9s var(--ease); }
[data-reveal-stagger].in > * { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  [data-reveal], [data-reveal-stagger] > *, .hero h1 .ln > span { opacity: 1 !important; transform: none !important; }
  .marquee-track, .scroll-cue .rail::after { animation: none !important; }
}

/* ----------------------------------------------------------------- responsive */
@media (max-width: 980px) {
  .hero-inner {
    grid-template-columns: 1fr; gap: 44px;
    min-height: 0; align-items: start;
  }
  .hero-copy { text-align: center; align-items: center; }
  .hero-copy h1 { max-width: 16ch; }
  .hero-actions { justify-content: center; }
  .hero-meta { justify-content: center; }
  .showcase { max-width: 760px; margin: 0 auto; }
  .hero-aura { right: 50%; transform: translate(50%, -50%); width: min(680px, 92vw); }
  @keyframes auraFloat {
    0%,100% { transform: translate(50%,-50%) translateY(0) scale(1); }
    50%     { transform: translate(50%,-50%) translateY(-14px) scale(1.04); }
  }
}
@media (max-width: 820px) {
  .sc-body { grid-template-columns: 1fr; }
  .sc-side { flex-direction: row; flex-wrap: wrap; align-items: center; gap: 8px;
    border-right: 0; border-bottom: 1px solid var(--line-soft); padding: 12px 16px; }
  .sc-logo { margin: 0 12px 0 0; }
  .sc-nav { padding: 6px 10px; font-size: 11.5px; }
  .sc-nav:nth-child(n+5), .sc-foot { display: none; }
  .sc-kpis { grid-template-columns: repeat(2, 1fr); }
  .sc-grid2 { grid-template-columns: 1fr; }
}
@media (max-width: 1080px) {
  .bento { grid-template-columns: 1fr; }
  .faq-grid { grid-template-columns: 1fr; gap: 32px; }
  .voices-grid { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr 1fr; gap: 40px; }
}
@media (max-width: 860px) {
  .wrap { padding: 0 22px; }
  .nav-links { display: none; }
  .nav-toggle {
    display: grid; place-items: center; width: 44px; height: 44px;
    border: 1px solid var(--line); border-radius: var(--r-pill);
  }
  .nav-toggle span { width: 18px; height: 1.5px; background: var(--ink); display: block; position: relative; }
  .nav-toggle span::before, .nav-toggle span::after { content:""; position:absolute; left:0; width:18px; height:1.5px; background:var(--ink); }
  .nav-toggle span::before { top: -6px; } .nav-toggle span::after { top: 6px; }
  .pillars-grid { grid-template-columns: 1fr; }
  .metric-grid { grid-template-columns: repeat(2, 1fr); }
  .metric:nth-child(2) { border-right: none; }
  .metric { border-bottom: 1px solid rgba(247,244,238,.16); }
  .hero-meta { gap: 28px; }
}
@media (max-width: 560px) {
  .envrow { flex-wrap: wrap; }
  .bc-art { padding: 24px 22px 4px; }
  .metric-grid { grid-template-columns: 1fr; }
  .metric { border-right: none; }
  .footer-top { grid-template-columns: 1fr; }
  .hero-actions .btn { width: 100%; justify-content: center; }
}
