.demo-page {
  --demo-ink: #171a2d;
  --demo-muted: #62677b;
  --demo-violet: #7038ee;
  --demo-violet-dark: #4c1d95;
  --demo-blue: #4f7fc4;
  --demo-pink: #ed4d9a;
  --demo-green: #20b979;
  --demo-amber: #f59e0b;
  overflow: hidden;
  color: var(--demo-ink);
  background: #f7f7fb;
}

.demo-page * { box-sizing: border-box; }
.demo-shell { width: min(1180px, calc(100% - 40px)); margin: 0 auto; }
.demo-page a { color: inherit; }
.demo-page a:focus-visible { outline: 3px solid #f59e0b; outline-offset: 4px; }

.demo-hero {
  position: relative;
  padding: 84px 0 76px;
  background:
    radial-gradient(circle at 82% 18%, rgba(124, 58, 237, .15), transparent 31%),
    radial-gradient(circle at 10% 70%, rgba(79, 127, 196, .12), transparent 30%),
    linear-gradient(145deg, #fbfaff 0%, #f2f0fb 54%, #f7f8fc 100%);
}
.demo-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: .45;
  pointer-events: none;
  background-image: radial-gradient(rgba(69, 54, 112, .16) .7px, transparent .7px);
  background-size: 22px 22px;
  mask-image: linear-gradient(to bottom, #000, transparent 85%);
}
.demo-hero-grid {
  position: relative;
  display: grid;
  grid-template-columns: minmax(320px, .78fr) minmax(520px, 1.22fr);
  gap: clamp(42px, 6vw, 88px);
  align-items: center;
}
.demo-eyebrow {
  margin: 0 0 16px;
  color: #6544a7;
  font-size: .77rem;
  font-weight: 850;
  letter-spacing: .16em;
  text-transform: uppercase;
}
.demo-hero h1 {
  max-width: 660px;
  margin: 0;
  color: #171827;
  font-size: clamp(3.15rem, 4.5vw, 5.75rem);
  line-height: .94;
  letter-spacing: -.065em;
}
.demo-lead {
  max-width: 620px;
  margin: 27px 0 0;
  color: #555b70;
  font-size: clamp(1.08rem, 1.55vw, 1.28rem);
  line-height: 1.66;
}
.demo-test-question {
  display: grid;
  gap: 6px;
  margin: 26px 0 0;
  padding: 16px 18px;
  border: 1px solid rgba(92, 73, 151, .18);
  border-left: 4px solid var(--demo-violet);
  border-radius: 5px 14px 14px 5px;
  background: rgba(255, 255, 255, .72);
  box-shadow: 0 10px 34px rgba(42, 30, 82, .06);
}
.demo-test-question > span { color: #777b8d; font-size: .74rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.demo-test-question strong { font-size: 1.1rem; line-height: 1.35; }
.demo-stats { display: flex; gap: 10px; margin: 20px 0 0; }
.demo-stats > div {
  display: flex;
  min-width: 104px;
  align-items: baseline;
  gap: 7px;
  padding: 10px 13px;
  border: 1px solid rgba(84, 74, 128, .13);
  border-radius: 10px;
  background: rgba(255, 255, 255, .58);
}
.demo-stats strong { color: var(--demo-violet-dark); font-size: 1.28rem; }
.demo-stats span { color: #686d80; font-size: .78rem; }
.demo-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin-top: 30px; }
.demo-btn {
  display: inline-flex;
  min-height: 50px;
  align-items: center;
  justify-content: center;
  padding: 13px 22px;
  border: 1px solid transparent;
  border-radius: 8px;
  font-weight: 800;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}
.demo-btn:hover { transform: translateY(-2px); }
.demo-btn-primary { color: #fff !important; background: var(--demo-violet); box-shadow: 0 13px 28px rgba(112, 56, 238, .24); }
.demo-btn-primary:hover { background: #5f2bd4; box-shadow: 0 16px 34px rgba(112, 56, 238, .3); }
.demo-btn-secondary { border-color: #cac6d8; background: #fff; }
.demo-btn-light { color: #171a2d !important; background: #fff; }
.demo-text-link { color: #4f396f !important; font-weight: 750; text-decoration: none; }
.demo-text-link span { display: inline-block; margin-left: 4px; transition: transform .18s ease; }
.demo-text-link:hover span { transform: translateY(3px); }

.demo-live-card {
  position: relative;
  display: block;
  overflow: hidden;
  min-width: 0;
  border: 1px solid rgba(108, 87, 169, .28);
  border-radius: 18px;
  color: #edf0ff !important;
  background: #171a2d;
  box-shadow: 0 32px 70px rgba(32, 24, 67, .26);
  text-decoration: none;
  transform: perspective(1200px) rotateY(-2deg) rotateX(1deg);
  transition: transform .25s ease, box-shadow .25s ease;
}
.demo-live-card:hover { transform: perspective(1200px) rotateY(0) rotateX(0) translateY(-4px); box-shadow: 0 40px 78px rgba(32, 24, 67, .32); }
.demo-live-head,
.demo-live-foot { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 16px 19px; }
.demo-live-head { border-bottom: 1px solid rgba(255, 255, 255, .09); color: #dfe2f5; font-size: .79rem; font-weight: 750; }
.demo-live-head b { margin-left: 5px; color: #b69afa; }
.demo-live-badge { display: inline-flex; align-items: center; gap: 8px; color: #cbd2ff; font-size: .68rem; letter-spacing: .1em; text-transform: uppercase; }
.demo-live-badge i { width: 8px; height: 8px; border-radius: 50%; background: #3ee39e; box-shadow: 0 0 0 5px rgba(62, 227, 158, .12); }
.demo-map-svg { display: block; width: 100%; height: auto; min-height: 390px; background: radial-gradient(circle at 50% 54%, #222746, #151827 70%); }
.demo-axis { stroke: rgba(255, 255, 255, .09); stroke-width: 1; stroke-dasharray: 4 6; }
.demo-edge { stroke: #9aa7df; stroke-width: 2; }
.demo-node text { fill: #d9dcef; font-family: inherit; font-size: 13px; font-style: normal; font-weight: 650; paint-order: stroke; stroke: #171a2d; stroke-width: 4px; stroke-linejoin: round; }
.demo-node-halo { fill: transparent; stroke: transparent; stroke-width: 3; }
.demo-node-dot { fill: var(--demo-blue); stroke: #c9dcff; stroke-width: 2.2; }
.demo-node.is-positive .demo-node-dot { fill: var(--demo-green); stroke: #a5f3cf; }
.demo-node.is-negative .demo-node-dot { fill: #59637b; stroke: #cbd2df; }
.demo-node.is-self .demo-node-dot { fill: var(--demo-pink); stroke: #ffc3e2; }
.demo-node.is-central .demo-node-halo { fill: rgba(245, 158, 11, .12); stroke: var(--demo-amber); }
.demo-node.is-central .demo-node-dot { fill: var(--demo-amber); stroke: #ffe3a3; }
.demo-node.is-central text { fill: #fff3cd; font-weight: 850; }
.demo-live-foot { border-top: 1px solid rgba(255, 255, 255, .09); color: #9fa6bd; font-size: .74rem; }
.demo-live-foot strong { color: #fff; font-size: .78rem; }

.demo-view-nav { border-top: 1px solid #e5e3ec; border-bottom: 1px solid #dfdde8; background: #fff; }
.demo-view-nav .demo-shell { display: grid; grid-template-columns: repeat(4, 1fr); }
.demo-view-nav a {
  display: flex;
  min-height: 72px;
  align-items: center;
  justify-content: center;
  gap: 11px;
  border-right: 1px solid #eceaf1;
  color: #272a3d;
  font-size: .9rem;
  font-weight: 800;
  text-decoration: none;
  transition: color .18s ease, background .18s ease;
}
.demo-view-nav a:first-child { border-left: 1px solid #eceaf1; }
.demo-view-nav a:hover { color: var(--demo-violet); background: #faf9fe; }
.demo-view-nav a > span { color: #9189a8; font-size: .68rem; letter-spacing: .08em; }

.demo-story {
  position: relative;
  padding: 112px 0;
  background:
    radial-gradient(circle at 7% 18%, rgba(245, 158, 11, .1), transparent 25%),
    #fff;
}
.demo-story-grid {
  display: grid;
  grid-template-columns: minmax(300px, .82fr) minmax(480px, 1.18fr);
  gap: clamp(48px, 7vw, 96px);
  align-items: center;
}
.demo-story-intro h2 {
  max-width: 560px;
  margin: 0;
  font-size: clamp(2.55rem, 4.9vw, 5rem);
  line-height: .98;
  letter-spacing: -.057em;
}
.demo-story-lead {
  max-width: 570px;
  margin: 24px 0 0;
  color: var(--demo-muted);
  font-size: 1.08rem;
  line-height: 1.72;
}
.demo-story-intro .demo-btn { margin-top: 30px; }
.demo-story-reading {
  position: relative;
  overflow: hidden;
  padding: clamp(29px, 4vw, 48px);
  border: 1px solid #303657;
  border-radius: 18px;
  color: #eef0ff;
  background:
    radial-gradient(circle at 84% 12%, rgba(112, 56, 238, .28), transparent 32%),
    linear-gradient(145deg, #242943, #171a2d 70%);
  box-shadow: 0 28px 65px rgba(31, 25, 60, .2);
}
.demo-story-reading::before {
  content: "„";
  position: absolute;
  right: 22px;
  top: -38px;
  color: rgba(255, 255, 255, .055);
  font-family: Georgia, serif;
  font-size: 13rem;
  line-height: 1;
  pointer-events: none;
}
.demo-story-reading > p {
  position: relative;
  margin: 0 0 17px;
  color: #c8cce0;
  font-size: 1.02rem;
  line-height: 1.72;
}
.demo-story-reading > p strong { color: #fff; }
.demo-story-evidence {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 27px 0;
}
.demo-story-evidence > div {
  display: grid;
  gap: 9px;
  padding: 15px 13px;
  border: 1px solid rgba(200, 193, 244, .15);
  border-radius: 10px;
  background: rgba(255, 255, 255, .055);
}
.demo-story-evidence span { color: #afb4cf; font-size: .67rem; line-height: 1.35; }
.demo-story-evidence strong { color: #fff; font-size: 1.45rem; letter-spacing: -.03em; }
.demo-story-reading blockquote {
  position: relative;
  margin: 29px 0 21px;
  padding: 0 0 0 20px;
  border-left: 3px solid #a987ff;
  color: #fff;
  font-size: clamp(1.35rem, 2.2vw, 2rem);
  font-weight: 760;
  line-height: 1.35;
  letter-spacing: -.025em;
}
.demo-story-reading .demo-story-note {
  margin: 0;
  color: #9299b4;
  font-size: .79rem;
  line-height: 1.55;
}

.demo-section { padding: 104px 0 112px; }
.demo-section-head { max-width: 760px; margin-bottom: 46px; }
.demo-section-head h2,
.demo-proof h2,
.demo-cta h2 { margin: 0; font-size: clamp(2.25rem, 4.4vw, 4.4rem); line-height: 1.02; letter-spacing: -.052em; }
.demo-section-head > p:last-child { max-width: 690px; margin: 20px 0 0; color: var(--demo-muted); font-size: 1.08rem; line-height: 1.7; }
.demo-view-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.demo-view-card {
  position: relative;
  display: flex;
  min-height: 590px;
  flex-direction: column;
  overflow: hidden;
  padding: clamp(25px, 3vw, 39px);
  border: 1px solid #dedce8;
  border-radius: 17px;
  color: var(--demo-ink) !important;
  background: #fff;
  box-shadow: 0 16px 48px rgba(39, 31, 76, .055);
  text-decoration: none;
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}
.demo-view-card:hover { z-index: 2; border-color: rgba(112, 56, 238, .4); box-shadow: 0 24px 60px rgba(39, 31, 76, .12); transform: translateY(-5px); }
.demo-card-topline { display: flex; align-items: center; gap: 11px; margin-bottom: 28px; }
.demo-card-topline > span {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid #d8d3e5;
  border-radius: 50%;
  color: #756c8e;
  font-size: .68rem;
  font-weight: 850;
}
.demo-card-topline b { color: #68518e; font-size: .7rem; letter-spacing: .11em; text-transform: uppercase; }
.demo-view-card h3 { margin: 0; font-size: clamp(1.75rem, 2.7vw, 2.7rem); line-height: 1.06; letter-spacing: -.04em; }
.demo-view-card > p { max-width: 580px; margin: 15px 0 25px; color: var(--demo-muted); line-height: 1.65; }
.demo-card-link { display: block; margin-top: auto; padding-top: 22px; color: #5d2fc9; font-weight: 850; }

.demo-reading-sheet {
  display: grid;
  gap: 0;
  overflow: hidden;
  margin: 9px 0 0;
  border: 1px solid #e4e1eb;
  border-radius: 11px;
  background: #faf9fd;
}
.demo-reading-sheet > div { display: grid; gap: 7px; padding: 19px 20px; border-bottom: 1px solid #e9e6ef; }
.demo-reading-sheet > div:last-child { border-bottom: 0; }
.demo-reading-sheet span { color: #7d778c; font-size: .72rem; font-weight: 750; letter-spacing: .06em; text-transform: uppercase; }
.demo-reading-sheet strong { font-size: 1.05rem; line-height: 1.4; }

.demo-space-card { color: #f4f5ff !important; border-color: #262a46; background: #171a2d; }
.demo-space-card .demo-card-topline > span { border-color: #555a79; color: #bec4e5; }
.demo-space-card .demo-card-topline b { color: #a99bf1; }
.demo-space-card > p { color: #adb2c9; }
.demo-space-card .demo-card-link { color: #c6b6ff; }
.demo-space-preview {
  position: relative;
  overflow: hidden;
  height: 315px;
  margin: 5px -12px 0;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 12px;
  background:
    radial-gradient(circle at 50% 25%, rgba(123, 100, 240, .25), transparent 45%),
    linear-gradient(#1c2038, #111421);
  perspective: 620px;
}
.demo-space-preview::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 30%;
  background: linear-gradient(transparent, #171a2d);
  pointer-events: none;
}
.demo-space-floor {
  position: absolute;
  left: -15%;
  right: -15%;
  bottom: -39%;
  height: 95%;
  background-image:
    linear-gradient(rgba(139, 151, 211, .2) 1px, transparent 1px),
    linear-gradient(90deg, rgba(139, 151, 211, .2) 1px, transparent 1px);
  background-size: 38px 38px;
  border-top: 1px solid rgba(181, 191, 245, .28);
  transform: rotateX(67deg);
  transform-origin: top;
}
.demo-space-node {
  --node-color: #7fa8e4;
  position: absolute;
  z-index: calc(5 + (var(--depth) * 10));
  left: var(--left);
  top: var(--top);
  width: calc(7px + var(--depth) * 8px);
  height: calc(7px + var(--depth) * 8px);
  border: 2px solid rgba(255, 255, 255, .72);
  border-radius: 50%;
  background: var(--node-color);
  box-shadow: 0 0 calc(8px + var(--depth) * 17px) var(--node-color);
  font-style: normal;
  animation: demoFloat 3.7s ease-in-out var(--delay) infinite;
}
.demo-space-node span {
  position: absolute;
  left: 50%;
  top: calc(100% + 6px);
  color: rgba(239, 241, 255, .84);
  font-size: calc(8px + var(--depth) * 2px);
  font-weight: 700;
  text-shadow: 0 2px 5px #111421;
  transform: translateX(-50%);
  white-space: nowrap;
}
.demo-space-node.is-positive { --node-color: #35cf91; }
.demo-space-node.is-negative { --node-color: #667087; }
.demo-space-node.is-self { --node-color: #ee5da5; }
.demo-space-node.is-central { --node-color: #f7ad2d; outline: 4px solid rgba(247, 173, 45, .2); }
@keyframes demoFloat { 50% { transform: translateY(-5px); } }
@media (prefers-reduced-motion: reduce) { .demo-space-node { animation: none; } }

.demo-symbol-card { grid-column: 1 / -1; min-height: 0; }
.demo-symbol-grid { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 10px; margin: 10px 0 5px; }
.demo-symbol-item {
  display: grid;
  min-width: 0;
  place-items: center;
  padding: 14px 7px 12px;
  border: 1px solid #383d60;
  border-radius: 11px;
  color: #f7f8ff;
  background: linear-gradient(145deg, #292e4b, #1b1f35);
  text-align: center;
  transition: border-color .18s ease, background .18s ease, transform .18s ease;
}
.demo-view-card:hover .demo-symbol-item { border-color: #5a5383; background: linear-gradient(145deg, #303653, #20243c); }
.demo-symbol-item:hover { transform: translateY(-3px); }
.demo-symbol-item img { width: min(72px, 72%); aspect-ratio: 1; object-fit: contain; filter: drop-shadow(0 8px 12px rgba(0, 0, 0, .35)); }
.demo-symbol-item b { overflow: hidden; max-width: 100%; margin-top: 10px; font-size: .78rem; text-overflow: ellipsis; white-space: nowrap; }
.demo-symbol-item small { margin-top: 4px; color: #bcc1d7; font-size: .64rem; }

.demo-proof { padding: 78px 0; color: #eef0ff; background: #191c31; }
.demo-proof .demo-eyebrow { color: #ad9af1; }
.demo-proof-grid { display: grid; grid-template-columns: 1.25fr 1fr auto; align-items: center; gap: clamp(30px, 5vw, 72px); }
.demo-proof h2 { max-width: 600px; font-size: clamp(2.2rem, 3.5vw, 3.55rem); }
.demo-proof-grid > p { margin: 0; color: #b8bdd2; line-height: 1.7; }
.demo-proof .demo-btn { white-space: nowrap; }

.demo-cta {
  padding: 110px 0 120px;
  background:
    radial-gradient(circle at 50% 0, rgba(112, 56, 238, .13), transparent 42%),
    #fff;
  text-align: center;
}
.demo-cta-inner { max-width: 830px; }
.demo-cta .demo-eyebrow { margin-bottom: 17px; }
.demo-cta h2 { max-width: 780px; margin: 0 auto; }
.demo-cta-inner > p:not(.demo-eyebrow) { max-width: 650px; margin: 23px auto 0; color: var(--demo-muted); font-size: 1.08rem; line-height: 1.7; }
.demo-cta .demo-actions { justify-content: center; }

@media (max-width: 1040px) {
  .demo-hero-grid { grid-template-columns: 1fr; }
  .demo-hero-copy { max-width: 760px; }
  .demo-live-card { width: min(100%, 820px); justify-self: center; transform: none; }
  .demo-live-card:hover { transform: translateY(-4px); }
  .demo-story-grid { grid-template-columns: 1fr; }
  .demo-story-intro { max-width: 760px; }
  .demo-proof-grid { grid-template-columns: 1fr 1fr; }
  .demo-proof .demo-btn { width: fit-content; }
  .demo-symbol-grid { grid-template-columns: repeat(4, 1fr); }
}

@media (max-width: 740px) {
  .demo-shell { width: min(100% - 28px, 1180px); }
  .demo-hero { padding: 62px 0 54px; }
  .demo-hero-grid { gap: 42px; }
  .demo-hero h1 { font-size: clamp(2.85rem, 14vw, 4.25rem); }
  .demo-stats { display: grid; grid-template-columns: repeat(3, 1fr); }
  .demo-stats > div { min-width: 0; flex-direction: column; gap: 1px; }
  .demo-map-svg { min-height: 0; }
  .demo-live-foot { align-items: flex-start; flex-direction: column; gap: 8px; }
  .demo-view-nav .demo-shell { grid-template-columns: repeat(2, 1fr); }
  .demo-view-nav a:nth-child(2) { border-right: 0; }
  .demo-view-nav a:nth-child(-n+2) { border-bottom: 1px solid #eceaf1; }
  .demo-section { padding: 76px 0 82px; }
  .demo-story { padding: 78px 0 84px; }
  .demo-story-grid { gap: 38px; }
  .demo-story-evidence { grid-template-columns: 1fr; }
  .demo-story-evidence > div { grid-template-columns: 1fr auto; align-items: center; }
  .demo-view-grid { grid-template-columns: 1fr; }
  .demo-symbol-card { grid-column: auto; }
  .demo-view-card { min-height: 0; }
  .demo-symbol-grid { grid-template-columns: repeat(2, 1fr); }
  .demo-proof { padding: 66px 0; }
  .demo-proof-grid { grid-template-columns: 1fr; gap: 28px; }
  .demo-cta { padding: 82px 0 92px; }
}

@media (max-width: 430px) {
  .demo-actions { align-items: stretch; flex-direction: column; }
  .demo-actions .demo-btn { width: 100%; }
  .demo-text-link { padding: 8px 0; text-align: center; }
  .demo-stats span { font-size: .7rem; }
  .demo-live-head { padding: 13px 14px; }
  .demo-live-head > span:last-child { font-size: .7rem; }
  .demo-view-card { padding: 23px 20px; }
  .demo-space-preview { margin-inline: 0; }
}
