/* Alphamotion landing — base styles */
:root {
  --bg: #0B0B0B;
  --bg-2: #0F0F12;
  --bg-3: #15151A;
  --ink: #F5F5F7;
  --ink-2: #B4B4BD;
  --ink-3: #6E6E78;
  --line: rgba(255,255,255,0.08);
  --line-2: rgba(255,255,255,0.14);
  --accent-a: #4F8BFF;   /* electric blue */
  --accent-b: #8B5CF6;   /* violet */
  --accent-c: #C026D3;   /* deep purple */
  --grad: linear-gradient(120deg, var(--accent-a) 0%, var(--accent-b) 55%, var(--accent-c) 100%);
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; background: var(--bg); color: var(--ink); }
body {
  font-family: 'Geist', 'Inter', system-ui, sans-serif;
  font-feature-settings: 'ss01', 'cv11';
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

.mono { font-family: 'Geist Mono', 'JetBrains Mono', ui-monospace, monospace; }

/* ===================== NAV ===================== */
.nav {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 40px;
  transition: backdrop-filter .4s var(--ease), background-color .4s var(--ease), border-color .4s var(--ease);
  border-bottom: 1px solid transparent;
}
.nav.scrolled {
  background: rgba(11, 11, 11, 0.55);
  backdrop-filter: blur(12px) saturate(140%);
  -webkit-backdrop-filter: blur(12px) saturate(140%);
  border-bottom: 1px solid var(--line);
}
.nav-brand {
  display: flex; align-items: center; gap: 10px;
  font-weight: 700; letter-spacing: -0.02em; font-size: 18px;
}
.nav-brand .logo-mark {
  width: 26px; height: 26px; border-radius: 7px;
  background: var(--grad);
  position: relative; overflow: hidden;
  box-shadow: 0 0 24px -4px rgba(139, 92, 246, 0.6);
}
.nav-brand .logo-mark::after {
  content: ''; position: absolute; inset: 1px;
  border-radius: 6px;
  background: radial-gradient(circle at 30% 30%, rgba(255,255,255,0.4), transparent 60%);
}
.nav-links { display: flex; gap: 32px; align-items: center; }
.nav-links a {
  color: var(--ink-2); text-decoration: none; font-size: 14px;
  font-weight: 500;
  transition: color .2s var(--ease);
}
.nav-links a:hover { color: var(--ink); }
.nav-cta {
  padding: 9px 18px;
  border-radius: 999px;
  background: rgba(255,255,255,0.06);
  border: 1px solid var(--line-2);
  color: var(--ink); font-size: 14px; font-weight: 500;
  cursor: pointer;
  transition: background .2s var(--ease), border-color .2s var(--ease);
}
.nav-cta:hover { background: rgba(255,255,255,0.1); border-color: rgba(255,255,255,0.25); }

/* ===================== HERO ===================== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 120px 24px 80px;
  overflow: hidden;
}
.hero-laser-canvas {
  position: absolute; inset: 0; width: 100%; height: 100%;
  pointer-events: none;
}
.hero-vignette {
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 50% 100%, rgba(139, 92, 246, 0.25), transparent 60%),
    radial-gradient(ellipse 100% 50% at 50% 0%, rgba(0,0,0,0.6), transparent 70%);
  pointer-events: none;
}
.hero-grain {
  position: absolute; inset: 0;
  opacity: 0.5; mix-blend-mode: overlay; pointer-events: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/><feColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.06 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}
.hero-eyebrow {
  position: relative; z-index: 2;
  display: inline-flex; align-items: center; gap: 10px;
  padding: 6px 14px 6px 8px;
  border-radius: 999px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--line);
  font-size: 12px; letter-spacing: 0.04em;
  color: var(--ink-2);
  margin-bottom: 28px;
}
.hero-eyebrow .dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: #4ADE80;
  box-shadow: 0 0 10px #4ADE80;
}
.hero-eyebrow .pill {
  padding: 2px 8px; border-radius: 999px;
  background: var(--grad);
  font-size: 11px; font-weight: 600; color: #fff;
  letter-spacing: 0.04em;
}

.hero h1 {
  position: relative; z-index: 2;
  margin: 0;
  font-size: clamp(48px, 8vw, 112px);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 0.98;
  text-align: center;
  max-width: 1100px;
  text-wrap: balance;
}
.hero h1 .grad {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-sub {
  position: relative; z-index: 2;
  margin: 28px 0 44px;
  max-width: 640px;
  text-align: center;
  color: var(--ink-2);
  font-size: 18px; line-height: 1.5;
  text-wrap: pretty;
}

.hero-cta-row {
  position: relative; z-index: 2;
  display: flex; gap: 14px; align-items: center;
}
.btn-primary {
  position: relative;
  padding: 14px 26px;
  border-radius: 999px;
  background: var(--grad);
  color: #fff;
  font-weight: 600; font-size: 15px;
  border: none;
  cursor: pointer;
  letter-spacing: -0.005em;
  transition: transform .25s var(--ease);
  box-shadow: 0 0 0 1px rgba(255,255,255,0.12) inset, 0 10px 40px -10px rgba(139, 92, 246, 0.6);
}
.btn-primary::before {
  content: '';
  position: absolute; inset: -3px;
  border-radius: 999px;
  background: var(--grad);
  filter: blur(14px);
  opacity: 0.55;
  z-index: -1;
  animation: neonPulse 2.4s var(--ease) infinite;
}
.btn-primary:hover { transform: translateY(-1px); }
.btn-primary:hover::before { opacity: 0.85; }
@keyframes neonPulse {
  0%, 100% { opacity: 0.45; transform: scale(1); }
  50% { opacity: 0.75; transform: scale(1.06); }
}
.btn-ghost {
  padding: 14px 22px;
  border-radius: 999px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--line-2);
  color: var(--ink); font-weight: 500; font-size: 15px;
  cursor: pointer;
  transition: background .2s var(--ease), border-color .2s var(--ease);
  display: inline-flex; align-items: center; gap: 8px;
}
.btn-ghost:hover { background: rgba(255,255,255,0.08); border-color: rgba(255,255,255,0.25); }

.hero-meta {
  position: relative; z-index: 2;
  margin-top: 80px;
  display: flex; gap: 40px;
  font-size: 12px; color: var(--ink-3); letter-spacing: 0.06em;
  text-transform: uppercase;
}
.hero-meta span { display: inline-flex; align-items: center; gap: 8px; }
.hero-meta .bar {
  width: 1px; height: 12px; background: var(--line);
}

/* mask reveal */
.mask-reveal { display: inline-block; overflow: hidden; vertical-align: bottom; }
.mask-reveal > span {
  display: inline-block;
  transform: translateY(110%);
  filter: blur(12px);
  opacity: 0;
  animation: maskUp 1.1s var(--ease) forwards;
}
@keyframes maskUp {
  to { transform: translateY(0); filter: blur(0); opacity: 1; }
}

/* generic reveal-on-scroll */
.reveal {
  opacity: 0; transform: translateY(20px);
  transition: opacity .9s var(--ease), transform .9s var(--ease);
}
.reveal.in { opacity: 1; transform: translateY(0); }

/* ===================== SECTION SHELL ===================== */
section.block {
  position: relative;
  padding: 140px 40px;
  max-width: 1280px;
  margin: 0 auto;
}
.section-eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 18px;
}
.section-eyebrow::before {
  content: ''; width: 18px; height: 1px; background: var(--ink-3);
}
.section-title {
  font-size: clamp(36px, 5vw, 64px);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.02;
  margin: 0 0 20px;
  max-width: 800px;
  text-wrap: balance;
}
.section-sub {
  color: var(--ink-2); max-width: 580px; font-size: 17px; line-height: 1.5;
  margin: 0 0 56px;
}

/* ===================== BENTO ===================== */
.bento {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 16px;
}
.bento-card {
  position: relative;
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(255,255,255,0.03), rgba(255,255,255,0.01));
  border: 1px solid var(--line);
  padding: 28px;
  overflow: hidden;
  min-height: 260px;
  display: flex; flex-direction: column;
  transition: transform .4s var(--ease), border-color .4s var(--ease);
}
.bento-card::before {
  /* mouse-tracked spotlight */
  content: '';
  position: absolute; inset: 0;
  border-radius: 24px;
  background: radial-gradient(
    400px circle at var(--mx, 50%) var(--my, 50%),
    rgba(139, 92, 246, 0.18),
    transparent 40%
  );
  opacity: 0; transition: opacity .35s var(--ease);
  pointer-events: none;
}
.bento-card::after {
  /* edge highlight */
  content: '';
  position: absolute; inset: 0;
  border-radius: 24px;
  padding: 1px;
  background: radial-gradient(
    300px circle at var(--mx, 50%) var(--my, 50%),
    rgba(255, 255, 255, 0.35),
    transparent 50%
  );
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  opacity: 0; transition: opacity .35s var(--ease);
  pointer-events: none;
}
.bento-card:hover::before, .bento-card:hover::after { opacity: 1; }
.bento-card:hover { border-color: var(--line-2); }

.bento-card .card-head {
  display: flex; align-items: center; gap: 10px;
  font-family: 'Geist Mono', monospace;
  font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 24px;
}
.bento-card h3 {
  margin: 0; font-size: 22px; font-weight: 600; letter-spacing: -0.02em;
  line-height: 1.2;
}
.bento-card p {
  margin: 8px 0 0; color: var(--ink-2); font-size: 14px; line-height: 1.55;
  max-width: 420px;
}
.bento-card .card-vis {
  margin-top: auto; padding-top: 24px;
  position: relative;
  min-height: 80px;
}

/* card sizes */
.bento-card.col-3 { grid-column: span 3; }
.bento-card.col-2 { grid-column: span 2; }
.bento-card.col-4 { grid-column: span 4; }
.bento-card.col-6 { grid-column: span 6; }
.bento-card.tall { min-height: 320px; }

/* card visualisations */
.vis-bars {
  display: flex; align-items: flex-end; gap: 6px; height: 80px;
}
.vis-bars .bar {
  flex: 1; border-radius: 4px;
  background: linear-gradient(180deg, var(--accent-b), rgba(139, 92, 246, 0.2));
  transition: transform .6s var(--ease);
}
.bento-card:hover .vis-bars .bar { animation: barGrow 1.5s var(--ease); }
@keyframes barGrow {
  0% { transform: scaleY(0.3); transform-origin: bottom; }
  60% { transform: scaleY(1.05); transform-origin: bottom; }
  100% { transform: scaleY(1); transform-origin: bottom; }
}

.vis-chat {
  position: relative; height: 100px;
}
.vis-chat .bubble {
  position: absolute;
  padding: 8px 12px; border-radius: 14px;
  background: rgba(255,255,255,0.06);
  border: 1px solid var(--line);
  font-size: 12px; color: var(--ink-2);
  opacity: 0; transform: translateY(8px) scale(0.95);
  transition: opacity .4s var(--ease), transform .4s var(--ease);
}
.vis-chat .bubble.b1 { left: 0; bottom: 50px; }
.vis-chat .bubble.b2 { left: 90px; bottom: 20px; background: rgba(79, 139, 255, 0.15); border-color: rgba(79, 139, 255, 0.3); color: #fff; }
.vis-chat .bubble.b3 { left: 30px; bottom: -10px; }
.bento-card:hover .vis-chat .bubble { opacity: 1; transform: translateY(0) scale(1); }
.bento-card:hover .vis-chat .b1 { transition-delay: 0s; }
.bento-card:hover .vis-chat .b2 { transition-delay: .15s; }
.bento-card:hover .vis-chat .b3 { transition-delay: .3s; }

.vis-orbit {
  position: relative; height: 140px; display: grid; place-items: center;
}
.vis-orbit .ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid var(--line-2);
}
.vis-orbit .ring.r1 { width: 70px; height: 70px; }
.vis-orbit .ring.r2 { width: 120px; height: 120px; opacity: 0.6; }
.vis-orbit .core {
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--grad);
  box-shadow: 0 0 30px -2px rgba(139, 92, 246, 0.7);
}
.vis-orbit .sat {
  position: absolute;
  width: 8px; height: 8px; border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 12px #fff;
}
.bento-card:hover .vis-orbit .sat { animation: orbit 2.5s linear infinite; }
@keyframes orbit {
  from { transform: rotate(0deg) translateX(60px) rotate(0deg); }
  to { transform: rotate(360deg) translateX(60px) rotate(-360deg); }
}

.vis-lines {
  position: relative; height: 100px;
}
.vis-lines svg { width: 100%; height: 100%; }
.vis-lines path {
  fill: none; stroke: var(--accent-a); stroke-width: 1.5;
  stroke-dasharray: 200; stroke-dashoffset: 200;
}
.bento-card:hover .vis-lines path { animation: drawLine 1.4s var(--ease) forwards; }
.bento-card:hover .vis-lines path:nth-child(2) { animation-delay: .15s; stroke: var(--accent-b); }
.bento-card:hover .vis-lines path:nth-child(3) { animation-delay: .3s; stroke: var(--accent-c); }
@keyframes drawLine { to { stroke-dashoffset: 0; } }

.vis-grid-mat {
  height: 110px;
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 24px 24px;
  background-position: -1px -1px;
  border: 1px solid var(--line);
  border-radius: 12px;
  position: relative; overflow: hidden;
}
.vis-grid-mat .node {
  position: absolute; width: 8px; height: 8px; border-radius: 50%;
  background: var(--accent-a);
  box-shadow: 0 0 10px var(--accent-a);
}
.bento-card:hover .vis-grid-mat .node { animation: nodePop .6s var(--ease) forwards; }
@keyframes nodePop {
  0% { transform: scale(0); }
  60% { transform: scale(1.4); }
  100% { transform: scale(1); }
}

/* ===================== VIRTUAL OFFICE ===================== */
.office-stage {
  position: relative;
  height: 560px;
  border-radius: 32px;
  background:
    radial-gradient(ellipse at 30% 20%, rgba(79, 139, 255, 0.18), transparent 50%),
    radial-gradient(ellipse at 70% 80%, rgba(192, 38, 211, 0.18), transparent 50%),
    linear-gradient(180deg, var(--bg-2), var(--bg));
  border: 1px solid var(--line);
  overflow: hidden;
}
.office-stage .floor-grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.04) 1px, transparent 1px);
  background-size: 60px 60px;
  transform: perspective(800px) rotateX(60deg) translateY(40%) scale(2);
  transform-origin: bottom center;
  mask-image: linear-gradient(180deg, transparent, #000 60%, transparent);
  -webkit-mask-image: linear-gradient(180deg, transparent, #000 60%, transparent);
}
.avatar {
  position: absolute;
  width: 56px; height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, #1a1a22, #0c0c10);
  border: 1px solid var(--line-2);
  display: grid; place-items: center;
  font-family: 'Geist Mono', monospace;
  font-size: 13px; font-weight: 600; letter-spacing: 0.02em;
  color: var(--ink);
  cursor: pointer;
  animation: float 3.4s var(--ease) infinite;
  transition: transform .3s var(--ease-spring);
}
.avatar:hover { transform: translateY(-3px) scale(1.08); }
.avatar::after {
  content: '';
  position: absolute; right: 2px; bottom: 2px;
  width: 12px; height: 12px;
  border-radius: 50%;
  background: var(--status, #4ADE80);
  border: 2px solid var(--bg-2);
  box-shadow: 0 0 8px var(--status, #4ADE80);
}
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

.tooltip {
  position: absolute;
  pointer-events: none;
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(20, 20, 24, 0.7);
  backdrop-filter: blur(20px) saturate(140%);
  -webkit-backdrop-filter: blur(20px) saturate(140%);
  border: 1px solid var(--line-2);
  white-space: nowrap;
  transform: translate(-50%, -120%) scale(0.8);
  opacity: 0;
  transition: opacity .2s var(--ease), transform .35s var(--ease-spring);
  z-index: 5;
}
.tooltip.show { opacity: 1; transform: translate(-50%, -120%) scale(1); }
.tooltip .name { font-size: 13px; font-weight: 600; }
.tooltip .role { font-family: 'Geist Mono', monospace; font-size: 11px; color: var(--ink-3); }

/* office stat strip */
.office-stat-row {
  position: absolute; bottom: 24px; left: 24px; right: 24px;
  display: flex; gap: 8px;
  padding: 14px 20px;
  border-radius: 16px;
  background: rgba(15, 15, 18, 0.55);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--line);
  font-family: 'Geist Mono', monospace;
  font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--ink-3);
  flex-wrap: wrap; row-gap: 4px;
}
.office-stat-row strong { color: var(--ink); font-weight: 600; }
.office-stat-row span { display: inline-flex; gap: 6px; align-items: center; }
.office-stat-row .sep { color: var(--ink-3); opacity: .5; }

/* ===================== METABRAIN / NARRATIVE ===================== */
.narrative {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: 56px;
  align-items: start;
}
.narrative-rail {
  position: sticky; top: 110px;
  display: flex; flex-direction: column; gap: 4px;
}
.rail-item {
  position: relative;
  padding: 14px 18px 14px 32px;
  border-radius: 12px;
  cursor: pointer;
  transition: background .25s var(--ease);
  font-size: 14px;
}
.rail-item:hover { background: rgba(255,255,255,0.03); }
.rail-item.active { background: rgba(255,255,255,0.04); }
.rail-item::before {
  content: ''; position: absolute; left: 14px; top: 50%;
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--ink-3);
  transform: translateY(-50%);
  transition: background .25s var(--ease), box-shadow .25s var(--ease);
}
.rail-item.active::before {
  background: var(--accent-b);
  box-shadow: 0 0 12px var(--accent-b);
}
.rail-item .num {
  font-family: 'Geist Mono', monospace;
  font-size: 11px; color: var(--ink-3); letter-spacing: 0.1em;
}
.rail-item .label {
  font-weight: 500; color: var(--ink-2); margin-top: 2px;
}
.rail-item.active .label { color: var(--ink); }

.narrative-canvas {
  position: relative;
  min-height: 580px;
  border-radius: 24px;
  background:
    radial-gradient(ellipse at 50% 20%, rgba(79, 139, 255, 0.12), transparent 60%),
    linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.005));
  border: 1px solid var(--line);
  padding: 48px;
  overflow: hidden;
}
.narrative-canvas .frame-tag {
  font-family: 'Geist Mono', monospace;
  font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--accent-a);
  margin-bottom: 20px;
}
.narrative-canvas h3 {
  font-size: clamp(36px, 4vw, 56px);
  font-weight: 800; letter-spacing: -0.03em; line-height: 1;
  margin: 0 0 24px;
  text-wrap: balance;
}
.narrative-canvas p {
  font-size: 17px; line-height: 1.55; color: var(--ink-2);
  max-width: 540px; margin: 0;
}
.narrative-canvas .frame-progress {
  position: absolute; right: 32px; top: 32px;
  font-family: 'Geist Mono', monospace;
  font-size: 12px; color: var(--ink-3); letter-spacing: 0.1em;
}
.narrative-canvas .frame-vis {
  position: absolute; right: 48px; bottom: 48px; left: auto;
  width: 220px; height: 220px;
  pointer-events: none;
}

/* ===================== FOOTER ===================== */
footer.foot {
  position: relative;
  margin-top: 80px;
  padding: 80px 40px 40px;
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, transparent, rgba(139, 92, 246, 0.04));
}
.foot-inner {
  max-width: 1280px; margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
}
.foot h4 { font-size: 12px; text-transform: uppercase; letter-spacing: 0.12em; color: var(--ink-3); margin: 0 0 18px; font-weight: 500; }
.foot ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.foot a { color: var(--ink-2); text-decoration: none; font-size: 14px; transition: color .2s var(--ease); }
.foot a:hover { color: var(--ink); }
.foot-tag {
  display: flex; align-items: center; gap: 12px;
  font-weight: 700; letter-spacing: -0.02em; font-size: 22px;
  margin-bottom: 18px;
}
.foot-bottom {
  max-width: 1280px; margin: 60px auto 0;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  display: flex; justify-content: space-between;
  font-family: 'Geist Mono', monospace;
  font-size: 11px; color: var(--ink-3); letter-spacing: 0.08em; text-transform: uppercase;
}

/* ===================== RESPONSIVE ===================== */
@media (max-width: 920px) {
  .nav { padding: 14px 20px; }
  .nav-links a:not(.nav-cta) { display: none; }
  section.block { padding: 80px 20px; }
  .bento { grid-template-columns: repeat(2, 1fr); }
  .bento-card.col-2, .bento-card.col-3, .bento-card.col-4, .bento-card.col-6 { grid-column: span 2; }
  .narrative { grid-template-columns: 1fr; }
  .narrative-rail { position: static; flex-direction: row; overflow-x: auto; }
  .foot-inner { grid-template-columns: 1fr 1fr; }
}
