:root {
  --bg: #0b0f17;
  --bg-grad: #0c1220;
  --panel: #0f1623;
  --panel-2: #111a2b;
  --border: #1e293b;
  --border-soft: #1b2536;
  --text: #e2e8f0;
  --muted: #94a3b8;
  --muted-2: #64748b;
  --indigo: #818cf8;
  --indigo-strong: #6366f1;
  --emerald: #34d399;
  --amber: #fbbf24;
  --sky: #38bdf8;
  --radius: 14px;
  --maxw: 1120px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, system-ui, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background:
    radial-gradient(1100px 600px at 78% -8%, rgba(99, 102, 241, 0.16), transparent 60%),
    radial-gradient(900px 520px at 12% 4%, rgba(52, 211, 153, 0.10), transparent 55%),
    linear-gradient(180deg, var(--bg-grad), var(--bg));
  background-repeat: no-repeat;
  -webkit-font-smoothing: antialiased;
  line-height: 1.6;
}

a { color: inherit; text-decoration: none; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

.skip-link {
  position: absolute; left: -999px; top: 0;
  background: var(--indigo-strong); color: #fff; padding: 10px 14px; border-radius: 0 0 10px 0; z-index: 50;
}
.skip-link:focus { left: 0; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 30;
  backdrop-filter: blur(10px);
  background: rgba(11, 15, 23, 0.72);
  border-bottom: 1px solid var(--border-soft);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; letter-spacing: -0.01em; }
.brand-mark { display: block; border-radius: 8px; }
.brand-name { font-size: 1.05rem; }
.nav-links { display: flex; align-items: center; gap: 22px; color: var(--muted); font-size: 0.94rem; font-weight: 500; }
.nav-links a:hover { color: var(--text); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  font: inherit; font-weight: 600; font-size: 0.96rem;
  padding: 12px 20px; border-radius: 11px; cursor: pointer;
  border: 1px solid transparent; transition: transform .12s ease, background .15s ease, border-color .15s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary {
  background: linear-gradient(180deg, var(--indigo), var(--indigo-strong));
  color: #fff; box-shadow: 0 8px 24px -10px rgba(99, 102, 241, 0.8);
}
.btn-primary:hover { background: linear-gradient(180deg, #8f99ff, #6f72f4); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--border); }
.btn-ghost:hover { border-color: #334155; background: rgba(148, 163, 184, 0.06); }
.btn-block { width: 100%; }
.btn.is-soon { background: var(--panel-2); color: var(--muted-2); border-color: var(--border); box-shadow: none; cursor: default; }
.btn.is-soon:hover { background: var(--panel-2); }

/* ---------- hero ---------- */
.hero {
  display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; align-items: center;
  padding: 84px 24px 72px;
}
.eyebrow {
  color: var(--indigo); font-weight: 600; font-size: 0.82rem; letter-spacing: 0.06em;
  text-transform: uppercase; margin: 0 0 18px;
}
.hero h1 {
  margin: 0 0 18px; font-size: clamp(2.3rem, 4.4vw, 3.5rem); line-height: 1.05;
  letter-spacing: -0.025em; font-weight: 800;
}
.lede { margin: 0 0 28px; color: var(--muted); font-size: 1.08rem; max-width: 36ch; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; }
.micro { margin: 20px 0 0; color: var(--muted-2); font-size: 0.85rem; }

.hero-art { position: relative; }
.hero-art .glow {
  position: absolute; inset: -10% -6% -14% -6%;
  background: radial-gradient(closest-side, rgba(99,102,241,0.22), transparent 72%);
  filter: blur(8px); z-index: 0;
}
.mock {
  position: relative; z-index: 1; width: 100%; height: auto;
  border-radius: 18px;
  box-shadow: 0 40px 80px -30px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(148, 163, 184, 0.06);
}
.mock-title { fill: var(--muted); font-size: 13px; font-family: var(--font); font-weight: 600; }
.mock .ava { fill: #fff; font-size: 11px; font-weight: 700; font-family: var(--font); }
.mock .hash { fill: #475569; font-size: 11px; font-family: ui-monospace, "SF Mono", Menlo, monospace; }

/* ---------- section shells ---------- */
.section-title {
  text-align: center; font-size: clamp(1.6rem, 2.6vw, 2.1rem); font-weight: 800;
  letter-spacing: -0.02em; margin: 0 0 8px;
}
.section-sub { text-align: center; color: var(--muted); margin: 0 auto 36px; }

.features { padding: 56px 24px; }
.features .section-title { margin-bottom: 40px; }
.grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.card {
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  border: 1px solid var(--border); border-radius: var(--radius); padding: 22px;
  transition: transform .15s ease, border-color .15s ease;
}
.card:hover { transform: translateY(-3px); border-color: #2b3a52; }
.card-ico {
  width: 42px; height: 42px; border-radius: 11px; display: grid; place-items: center; margin-bottom: 14px;
}
.ico-indigo { background: rgba(129, 140, 248, 0.14); color: var(--indigo); }
.ico-emerald { background: rgba(52, 211, 153, 0.14); color: var(--emerald); }
.ico-amber { background: rgba(251, 191, 36, 0.14); color: var(--amber); }
.ico-sky { background: rgba(56, 189, 248, 0.14); color: var(--sky); }
.card h3 { margin: 0 0 8px; font-size: 1.06rem; letter-spacing: -0.01em; }
.card p { margin: 0; color: var(--muted); font-size: 0.93rem; }

/* ---------- download ---------- */
.download { padding: 40px 24px 80px; }
.os-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; max-width: 880px; margin: 0 auto; }
.os-card {
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  border: 1px solid var(--border); border-radius: var(--radius); padding: 26px 22px; text-align: center;
  color: var(--text); transition: border-color .15s ease, transform .15s ease;
}
.os-card:hover { transform: translateY(-3px); border-color: #2b3a52; }
.os-card svg { color: var(--muted); margin-bottom: 8px; }
.os-card.is-current { border-color: var(--indigo-strong); box-shadow: 0 0 0 1px rgba(99,102,241,0.35); }
.os-card.is-current svg { color: var(--indigo); }
.os-card h3 { margin: 4px 0 2px; font-size: 1.1rem; }
.os-note { color: var(--muted-2); font-size: 0.82rem; margin: 0 0 18px; }

.note-soon { text-align: center; color: var(--muted); margin: 26px auto 0; max-width: 60ch; }
.note-soon a { color: var(--indigo); text-decoration: underline; }

.unsigned {
  max-width: 760px; margin: 30px auto 0; padding: 14px 18px;
  background: rgba(251, 191, 36, 0.07); border: 1px solid rgba(251, 191, 36, 0.25);
  border-radius: 12px; color: var(--muted); font-size: 0.88rem; text-align: center;
}
.unsigned strong { color: #fcd34d; display: block; margin-bottom: 2px; }
.unsigned b { color: var(--text); }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--border-soft); padding: 34px 0 44px; margin-top: 20px; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap; }
.foot-brand { display: inline-flex; align-items: center; gap: 9px; font-weight: 700; }
.foot-links { display: flex; gap: 20px; color: var(--muted); font-size: 0.92rem; }
.foot-links a:hover { color: var(--text); }
.foot-fine { color: var(--muted-2); font-size: 0.8rem; margin-top: 16px; max-width: 80ch; }

/* ---------- responsive ---------- */
@media (max-width: 940px) {
  .hero { grid-template-columns: 1fr; gap: 40px; padding-top: 56px; }
  .hero-art { order: 2; max-width: 560px; }
  .lede { max-width: none; }
  .grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 620px) {
  .nav-links a:not(:last-child) { display: none; }
  .grid { grid-template-columns: 1fr; }
  .os-grid { grid-template-columns: 1fr; }
  .cta-row .btn { flex: 1; }
}

/* ---------- brand mark + wordmark ---------- */
.brand-mark {
  width: 30px; height: 30px; border-radius: 9px; display: block;
  animation: markGlow 5s ease-in-out infinite;
}
.brand-name {
  background: linear-gradient(100deg, #ffffff 32%, #c7d2fe);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.foot-brand img { border-radius: 7px; }
@keyframes markGlow {
  0%, 100% { filter: drop-shadow(0 0 0 rgba(129, 140, 248, 0)); }
  50% { filter: drop-shadow(0 4px 16px rgba(129, 140, 248, 0.5)); }
}

/* header M assembles on load: lanes draw up, then the merge node snaps in */
@media (prefers-reduced-motion: no-preference) {
  .brand-mark .bm-lane { stroke-dasharray: 96; stroke-dashoffset: 96; animation: bmDraw 0.75s ease forwards 0.15s; }
  .brand-mark .bm-lane-r { animation-delay: 0.3s; }
  .brand-mark .bm-tip { opacity: 0; transform-box: fill-box; transform-origin: center; animation: bmPop 0.3s ease forwards; }
  .brand-mark .bm-tip-l { animation-delay: 0.62s; }
  .brand-mark .bm-tip-r { animation-delay: 0.74s; }
  .brand-mark .bm-merge { opacity: 0; transform-box: fill-box; transform-origin: center; animation: bmPop 0.45s cubic-bezier(0.2, 0.8, 0.3, 1.4) forwards 0.95s; }
  .brand-mark .bm-halo { opacity: 0; animation: bmFade 0.6s ease forwards 0.95s; }
}
@keyframes bmDraw { to { stroke-dashoffset: 0; } }
@keyframes bmPop { to { opacity: 1; transform: scale(1); } }
@keyframes bmFade { to { opacity: 1; } }

/* ---------- pricing ---------- */
.pricing { padding: 60px 24px 24px; }
.pricing .section-title { margin-bottom: 8px; }
.price-card {
  max-width: 460px; margin: 38px auto 0; padding: 30px;
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  border: 1px solid var(--border); border-radius: 16px; text-align: center;
  box-shadow: 0 30px 60px -34px rgba(0, 0, 0, 0.85);
}
.price-head { display: flex; align-items: baseline; justify-content: center; gap: 10px; margin-bottom: 22px; }
.price-amount {
  font-size: 3rem; font-weight: 800; letter-spacing: -0.03em; line-height: 1;
  background: linear-gradient(100deg, #ffffff, #c7d2fe);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.price-per { color: var(--muted-2); font-size: 0.9rem; }
.price-list { list-style: none; margin: 0 0 24px; padding: 0; text-align: left; display: grid; gap: 11px; }
.price-list li { position: relative; padding-left: 28px; color: var(--muted); font-size: 0.94rem; }
.price-list li::before { content: "✓"; position: absolute; left: 0; top: 0; color: var(--emerald); font-weight: 700; }
.price-note { margin: 14px 0 0; color: var(--muted-2); font-size: 0.82rem; }
.js-reveal .price-card { opacity: 0; transform: translateY(20px); transition: opacity 0.6s ease, transform 0.6s ease; }
.js-reveal.is-visible .price-card { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .js-reveal .price-card { opacity: 1; transform: none; transition: none; }
}

/* ---------- beta badge + download notice ---------- */
.beta-pill {
  display: inline-block; margin-right: 8px; vertical-align: 1px;
  background: rgba(129, 140, 248, 0.16); color: var(--indigo);
  border: 1px solid rgba(129, 140, 248, 0.4); border-radius: 999px;
  padding: 1px 9px; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.05em;
}
.beta-note { text-align: center; color: var(--muted); font-size: 0.86rem; margin: 22px auto 0; max-width: 62ch; }
.beta-note a { color: var(--indigo); text-decoration: underline; }
.beta-note strong { color: #c7d2fe; }

/* ---------- legal pages ---------- */
.legal { max-width: 768px; padding: 52px 24px 80px; }
.legal h1 { font-size: clamp(1.8rem, 3vw, 2.4rem); letter-spacing: -0.02em; margin: 0 0 6px; }
.legal .legal-meta { color: var(--muted-2); font-size: 0.88rem; margin: 0 0 24px; }
.legal h2 { font-size: 1.12rem; margin: 30px 0 8px; color: var(--text); }
.legal p, .legal li { color: var(--muted); font-size: 0.95rem; line-height: 1.7; }
.legal ul { padding-left: 22px; display: grid; gap: 6px; margin: 6px 0; }
.legal a { color: var(--indigo); text-decoration: underline; }
.legal-callout {
  background: rgba(251, 191, 36, 0.07); border: 1px solid rgba(251, 191, 36, 0.25);
  border-radius: 12px; padding: 14px 18px; color: var(--muted); font-size: 0.92rem; margin: 0 0 26px;
}
.legal-callout strong { color: #fcd34d; }
.legal-foot { margin-top: 36px; padding-top: 20px; border-top: 1px solid var(--border-soft); }

/* ---------- feedback form ---------- */
.feedback { padding: 60px 24px 28px; }
.feedback .section-title { margin-bottom: 8px; }
.fb-form { max-width: 640px; margin: 34px auto 0; display: grid; gap: 16px; }
.fb-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.fb-field { display: grid; gap: 6px; }
.fb-field > span { font-size: 0.82rem; color: var(--muted); font-weight: 500; }
.fb-form input, .fb-form select, .fb-form textarea {
  width: 100%; font: inherit; color: var(--text); background: var(--panel);
  border: 1px solid var(--border); border-radius: 10px; padding: 11px 13px; outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.fb-form textarea { resize: vertical; min-height: 120px; }
.fb-form input:focus, .fb-form select:focus, .fb-form textarea:focus {
  border-color: var(--indigo); box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.25);
}
.fb-row { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.fb-status { margin: 0; font-size: 0.9rem; color: var(--muted); }
.fb-status.is-ok { color: var(--emerald); }
.fb-status.is-err { color: #fca5a5; }
.fb-fine { margin: 0; color: var(--muted-2); font-size: 0.8rem; }
.fb-fine a { color: var(--indigo); text-decoration: underline; }
.fb-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
@media (max-width: 620px) { .fb-grid { grid-template-columns: 1fr; } }

/* ---------- hero depth + graph draw-in ---------- */
.hero::before {
  content: ""; position: absolute; inset: -40px 0 20px; z-index: -1; pointer-events: none;
  background-image: radial-gradient(rgba(148, 163, 184, 0.11) 1px, transparent 1px);
  background-size: 22px 22px;
  -webkit-mask-image: radial-gradient(58% 58% at 32% 26%, #000, transparent 76%);
  mask-image: radial-gradient(58% 58% at 32% 26%, #000, transparent 76%);
}
.hero-art .glow { animation: glowPulse 6s ease-in-out infinite; }
@keyframes glowPulse { 0%, 100% { opacity: 0.7; } 50% { opacity: 1; } }

@media (prefers-reduced-motion: no-preference) {
  .mw-lanes line, .mw-lanes path {
    stroke-dasharray: 620; stroke-dashoffset: 620;
    animation: drawLane 1.5s ease forwards 0.2s;
  }
  .mw-nodes circle {
    opacity: 0; transform-box: fill-box; transform-origin: center;
    animation: popNode 0.45s cubic-bezier(0.2, 0.8, 0.3, 1.4) forwards;
  }
  .mw-nodes circle:nth-child(1) { animation-delay: 0.55s; }
  .mw-nodes circle:nth-child(2) { animation-delay: 0.66s; }
  .mw-nodes circle:nth-child(3) { animation-delay: 0.77s; }
  .mw-nodes circle:nth-child(4) { animation-delay: 0.88s; }
  .mw-nodes circle:nth-child(5) { animation-delay: 0.99s; }
  .mw-nodes circle:nth-child(6) { animation-delay: 1.10s; }
  .mw-nodes circle:nth-child(7) { animation-delay: 1.21s; }
  .mw-nodes circle:nth-child(8) { animation-delay: 1.32s; }
  .mw-nodes circle:nth-child(9) { animation-delay: 1.43s; }
  .mw-nodes circle:nth-child(10) { animation-delay: 1.54s; }
  .mw-nodes circle:nth-child(11) { animation-delay: 1.65s; }
  .mock .rows { opacity: 0; animation: fadeRows 1s ease forwards 1.05s; }
}
@keyframes drawLane { to { stroke-dashoffset: 0; } }
@keyframes popNode { to { opacity: 1; transform: scale(1); } }
@keyframes fadeRows { to { opacity: 1; } }

/* ---------- scroll reveal ---------- */
.js-reveal .section-title,
.js-reveal .section-sub,
.js-reveal .card,
.js-reveal .os-card,
.js-reveal .note-soon,
.js-reveal .unsigned {
  opacity: 0; transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.js-reveal.is-visible .section-title,
.js-reveal.is-visible .section-sub,
.js-reveal.is-visible .card,
.js-reveal.is-visible .os-card,
.js-reveal.is-visible .note-soon,
.js-reveal.is-visible .unsigned {
  opacity: 1; transform: none;
}
.js-reveal.is-visible .grid .card:nth-child(2),
.js-reveal.is-visible .os-grid .os-card:nth-child(2) { transition-delay: 0.08s; }
.js-reveal.is-visible .grid .card:nth-child(3),
.js-reveal.is-visible .os-grid .os-card:nth-child(3) { transition-delay: 0.16s; }
.js-reveal.is-visible .grid .card:nth-child(4) { transition-delay: 0.24s; }

/* ---------- focus visibility ---------- */
a:focus-visible, .btn:focus-visible {
  outline: 2px solid var(--indigo); outline-offset: 3px; border-radius: 9px;
}

/* ---------- demos / see it in action ---------- */
.demos { padding: 60px 24px 24px; }
.demos .section-title { margin-bottom: 8px; }
.demo-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 38px; }
.demo-win {
  background: #0d1422; border: 1px solid var(--border); border-radius: 12px; overflow: hidden;
  box-shadow: 0 24px 50px -28px rgba(0, 0, 0, 0.85);
}
.demo-bar { display: flex; align-items: center; padding: 9px 12px; border-bottom: 1px solid var(--border-soft); background: #0b111d; }
.demo-bar i { width: 9px; height: 9px; border-radius: 50%; margin-right: 6px; background: #2a3550; }
.demo-bar i:nth-child(1) { background: #ff5f57; }
.demo-bar i:nth-child(2) { background: #febc2e; }
.demo-bar i:nth-child(3) { background: #28c840; }
.demo-bar span { margin-left: 6px; font-size: 0.72rem; color: var(--muted-2); }
.demo-body { position: relative; height: 234px; padding: 16px; overflow: hidden; }
.demo-card > h3 { margin: 16px 0 4px; font-size: 1.02rem; letter-spacing: -0.01em; }
.demo-card > p { margin: 0; color: var(--muted); font-size: 0.9rem; }

/* demo 1 — stage & commit */
.demo-commit .dc-rows { display: flex; flex-direction: column; gap: 9px; animation: dcRows 9s ease infinite; }
.dc-row { display: flex; align-items: center; gap: 9px; }
.dc-check { width: 16px; height: 16px; border-radius: 5px; border: 1.5px solid #334155; display: grid; place-items: center; font-size: 11px; line-height: 1; color: transparent; flex: none; }
.dc-row:nth-child(1) .dc-check { animation: dcChk1 9s ease infinite; }
.dc-row:nth-child(2) .dc-check { animation: dcChk2 9s ease infinite; }
.dc-row:nth-child(3) .dc-check { animation: dcChk3 9s ease infinite; }
.dc-badge { width: 16px; height: 16px; border-radius: 4px; font-size: 10px; font-weight: 700; display: grid; place-items: center; flex: none; }
.dc-badge.m { background: rgba(251, 191, 36, 0.18); color: #fbbf24; }
.dc-badge.a { background: rgba(52, 211, 153, 0.18); color: #34d399; }
.dc-file { color: #cbd5e1; font-family: ui-monospace, Menlo, monospace; font-size: 0.74rem; }
.dc-stat { margin-left: auto; color: var(--muted-2); font-size: 0.72rem; font-family: ui-monospace, Menlo, monospace; }
.dc-commit { position: absolute; left: 16px; right: 16px; bottom: 16px; }
.dc-msg { background: #0a0f1a; border: 1px solid var(--border); border-radius: 8px; padding: 8px 10px; font-size: 0.78rem; color: #cbd5e1; margin-bottom: 8px; }
.dc-caret { display: inline-block; width: 1px; height: 12px; background: var(--indigo); margin-left: 1px; vertical-align: -2px; animation: blink 1s step-end infinite; }
.dc-btn { background: linear-gradient(180deg, var(--indigo), var(--indigo-strong)); color: #fff; text-align: center; padding: 9px; border-radius: 8px; font-size: 0.82rem; font-weight: 600; animation: dcBtn 9s ease infinite; }
.dc-toast { position: absolute; left: 16px; right: 16px; top: 16px; background: rgba(52, 211, 153, 0.12); border: 1px solid rgba(52, 211, 153, 0.3); color: #6ee7b7; font-size: 0.8rem; text-align: center; padding: 9px; border-radius: 8px; opacity: 0; animation: dcToast 9s ease infinite; }
@keyframes blink { 50% { opacity: 0; } }
@keyframes dcChk1 { 0%, 7% { background: transparent; color: transparent; border-color: #334155; } 12%, 52% { background: var(--indigo-strong); color: #fff; border-color: var(--indigo-strong); } 57%, 100% { background: transparent; color: transparent; border-color: #334155; } }
@keyframes dcChk2 { 0%, 15% { background: transparent; color: transparent; border-color: #334155; } 20%, 52% { background: var(--indigo-strong); color: #fff; border-color: var(--indigo-strong); } 57%, 100% { background: transparent; color: transparent; border-color: #334155; } }
@keyframes dcChk3 { 0%, 23% { background: transparent; color: transparent; border-color: #334155; } 28%, 52% { background: var(--indigo-strong); color: #fff; border-color: var(--indigo-strong); } 57%, 100% { background: transparent; color: transparent; border-color: #334155; } }
@keyframes dcRows { 0%, 52% { opacity: 1; transform: none; } 58%, 84% { opacity: 0; transform: translateY(-6px); } 90%, 100% { opacity: 1; transform: none; } }
@keyframes dcBtn { 0%, 40% { filter: brightness(0.82); } 46% { filter: brightness(1.12); } 50% { transform: scale(0.96); } 54% { transform: scale(1); filter: brightness(1.12); } 60%, 100% { filter: brightness(0.82); } }
@keyframes dcToast { 0%, 56% { opacity: 0; transform: translateY(6px); } 63%, 83% { opacity: 1; transform: none; } 90%, 100% { opacity: 0; } }

/* demo 2 — read the graph */
.demo-graph svg { width: 100%; height: 100%; }
.dg-ava { fill: #fff; font-size: 9px; font-weight: 700; font-family: var(--font); }
.dg-sel { transform-box: fill-box; transform-origin: center; animation: dgSel 7.5s ease-in-out infinite; }
.dg-head { transform-box: fill-box; transform-origin: center; animation: dgHead 2.2s ease-in-out infinite; }
@keyframes dgSel { 0%, 12% { transform: translateY(0); } 22%, 34% { transform: translateY(34px); } 44%, 56% { transform: translateY(68px); } 66%, 78% { transform: translateY(102px); } 88%, 100% { transform: translateY(0); } }
@keyframes dgHead { 0%, 100% { opacity: 0.45; } 50% { opacity: 1; } }

/* demo 3 — branch & merge */
.demo-merge .dm-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 14px; }
.dm-row { display: flex; align-items: center; gap: 9px; padding: 7px 10px; border-radius: 8px; border: 1px solid transparent; font-size: 0.8rem; color: #cbd5e1; font-family: ui-monospace, Menlo, monospace; }
.dm-row .dot { width: 8px; height: 8px; border-radius: 50%; }
.dm-row.main .dot { background: var(--indigo); }
.dm-row.feat .dot { background: var(--emerald); }
.dm-row.feat { animation: dmSel 7s ease infinite; }
@keyframes dmSel { 0%, 14% { background: transparent; border-color: transparent; } 20%, 84% { background: rgba(52, 211, 153, 0.1); border-color: rgba(52, 211, 153, 0.35); } 90%, 100% { background: transparent; border-color: transparent; } }
.dm-svg { width: 100%; height: 92px; display: block; }
.dm-edge { stroke-dasharray: 120; stroke-dashoffset: 120; animation: dmDraw 7s ease infinite; }
@keyframes dmDraw { 0%, 30% { stroke-dashoffset: 120; } 52%, 84% { stroke-dashoffset: 0; } 90%, 100% { stroke-dashoffset: 120; } }
.dm-node { opacity: 0; transform-box: fill-box; transform-origin: center; animation: dmNode 7s ease infinite; }
@keyframes dmNode { 0%, 52% { opacity: 0; transform: scale(0); } 60%, 84% { opacity: 1; transform: scale(1); } 90%, 100% { opacity: 0; } }
.dm-chip { display: inline-block; margin-top: 10px; padding: 5px 11px; border-radius: 999px; font-size: 0.74rem; background: rgba(52, 211, 153, 0.12); border: 1px solid rgba(52, 211, 153, 0.3); color: #6ee7b7; opacity: 0; animation: dmChip 7s ease infinite; }
@keyframes dmChip { 0%, 60% { opacity: 0; transform: translateY(4px); } 68%, 86% { opacity: 1; transform: none; } 92%, 100% { opacity: 0; } }

/* demo reveal */
.js-reveal .demo-card { opacity: 0; transform: translateY(20px); transition: opacity 0.6s ease, transform 0.6s ease; }
.js-reveal.is-visible .demo-card { opacity: 1; transform: none; }
.js-reveal.is-visible .demo-grid .demo-card:nth-child(2) { transition-delay: 0.08s; }
.js-reveal.is-visible .demo-grid .demo-card:nth-child(3) { transition-delay: 0.16s; }

@media (max-width: 940px) {
  .demo-grid { grid-template-columns: 1fr; max-width: 520px; margin-left: auto; margin-right: auto; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn, .card, .os-card { transition: none; }
  .brand-mark, .hero-art .glow { animation: none; }
  .brand-mark .bm-lane { stroke-dashoffset: 0; }
  .brand-mark .bm-tip, .brand-mark .bm-merge, .brand-mark .bm-halo { opacity: 1; }
  .js-reveal .section-title, .js-reveal .section-sub, .js-reveal .card,
  .js-reveal .os-card, .js-reveal .note-soon, .js-reveal .unsigned, .js-reveal .demo-card {
    opacity: 1; transform: none; transition: none;
  }
  /* freeze demos on a representative, readable frame */
  .demo-win *, .dc-rows, .dc-check, .dc-btn, .dc-toast, .dg-sel, .dg-head,
  .dm-row.feat, .dm-edge, .dm-node, .dm-chip { animation: none !important; }
  .dc-toast, .dm-chip { opacity: 0; }
  .dc-check { background: var(--indigo-strong); color: #fff; border-color: var(--indigo-strong); }
  .dm-edge { stroke-dashoffset: 0; }
  .dm-node { opacity: 1; transform: none; }
}
