:root {
  --bg: oklch(12% 0.018 232);
  --surface: oklch(17% 0.025 232);
  --surface-2: oklch(21% 0.032 232);
  --surface-3: oklch(26% 0.04 232);
  --ink: oklch(93% 0.012 210);
  --muted: oklch(72% 0.034 218);
  --faint: oklch(55% 0.045 222);
  --line: oklch(36% 0.045 226);
  --cyan: oklch(75% 0.15 205);
  --gold: oklch(72% 0.12 78);
  --red: oklch(58% 0.17 25);
  --blue: oklch(58% 0.13 258);
  --green: oklch(73% 0.15 156);
  --shadow: 0 24px 80px oklch(7% 0.016 232 / 0.48);
  --serif: "Songti SC", "Noto Serif CJK SC", "Noto Serif SC", SimSun, serif;
  --sans: "Avenir Next Condensed", "PingFang SC", "Hiragino Sans GB", sans-serif;
  --mono: "SF Mono", Menlo, "Cascadia Mono", "JetBrains Mono", monospace;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--bg);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  letter-spacing: 0;
  overflow-x: hidden;
}

#signalCanvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 0.92;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 32px;
  width: min(1480px, calc(100vw - 48px));
  margin: 0 auto;
  padding: 12px 0;
  background: oklch(12% 0.018 232 / 0.92);
  border-bottom: 1px solid var(--line);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 52px;
  font-family: var(--serif);
}

.brand img {
  width: 50px;
  height: 50px;
  border: 1px solid var(--line);
  background: oklch(96% 0.012 82);
}

.brand-text {
  display: grid;
  gap: 2px;
}

.brand-text strong {
  color: var(--ink);
  font-size: 23px;
  font-weight: 700;
  line-height: 1.08;
}

.brand-text small {
  color: var(--muted);
  font-family: var(--sans);
  font-size: 12px;
  line-height: 1.1;
  letter-spacing: 0.08em;
}

nav {
  display: flex;
  justify-content: flex-end;
  gap: 24px;
  color: var(--muted);
  font-size: 14px;
  white-space: nowrap;
}

nav a {
  position: relative;
  padding: 12px 0;
  transition: color 180ms ease;
}

nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 4px;
  height: 1px;
  background: var(--cyan);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 180ms ease;
}

nav a:hover {
  color: var(--ink);
}

nav a:hover::after {
  transform: scaleX(1);
}

main {
  position: relative;
  z-index: 1;
}

.strategy-hero {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(520px, 0.9fr);
  gap: 48px;
  align-items: center;
  width: min(1480px, calc(100vw - 48px));
  min-height: calc(100svh - 77px);
  margin: 0 auto;
  padding: 52px 0 64px;
}

.hero-copy {
  display: grid;
  gap: 22px;
  min-width: 0;
  animation: heroEntry 860ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.breadcrumb,
.eyebrow {
  margin: 0;
  color: var(--cyan);
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.breadcrumb {
  color: var(--faint);
  letter-spacing: 0;
  text-transform: none;
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1 {
  max-width: 920px;
  font-family: var(--serif);
  font-size: clamp(48px, 6vw, 92px);
  line-height: 1.03;
  font-weight: 700;
}

h1 span {
  display: block;
}

.hero-lede {
  max-width: 760px;
  color: var(--muted);
  font-size: 22px;
  line-height: 1.56;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 4px;
}

.primary-action,
.secondary-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 800;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.primary-action {
  border-color: var(--cyan);
  background: oklch(75% 0.15 205 / 0.14);
}

.secondary-action {
  color: var(--muted);
}

.primary-action:hover,
.secondary-action:hover {
  transform: translateY(-2px);
  border-color: var(--cyan);
  background: oklch(75% 0.15 205 / 0.1);
}

.hero-state {
  display: grid;
  grid-template-columns: 1.15fr repeat(3, minmax(120px, 1fr));
  gap: 1px;
  max-width: 820px;
  margin-top: 8px;
  border: 1px solid var(--line);
  background: var(--line);
}

.hero-state div {
  min-height: 92px;
  padding: 16px;
  background: oklch(16% 0.024 232 / 0.86);
}

.hero-state span,
.factor-stack span,
.terminal-bar,
.strategy-switch span,
.factor-card span,
.download-item span,
.portfolio-row span,
.review-timeline span,
.collaboration-panel span {
  color: var(--faint);
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.hero-state strong {
  display: block;
  margin-top: 14px;
  font-family: var(--mono);
  font-size: 18px;
  line-height: 1.1;
  white-space: nowrap;
}

.strategy-console,
.strategy-switch,
.factor-card,
.download-item,
.nav-panel,
.portfolio-panel,
.review-timeline article,
.collaboration-panel {
  border: 1px solid var(--line);
  background: oklch(16% 0.024 232 / 0.82);
  box-shadow: var(--shadow);
}

.strategy-console {
  padding: 18px;
  animation: consoleEntry 900ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
  animation-delay: 120ms;
}

.terminal-bar,
.panel-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 12px;
  font-family: var(--mono);
  font-size: 12px;
}

.terminal-bar strong,
.panel-head strong {
  color: var(--gold);
}

.hero-flow {
  position: relative;
  margin-top: 18px;
  border: 1px solid var(--line);
  background: oklch(10% 0.016 232 / 0.68);
  overflow: hidden;
}

.hero-flow svg {
  display: block;
  width: 100%;
  height: auto;
}

.flow-grid {
  fill: none;
  stroke: oklch(36% 0.045 226 / 0.44);
  stroke-width: 1;
}

.flow-grid.vertical {
  stroke: oklch(36% 0.045 226 / 0.24);
}

.flow-path {
  fill: none;
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 16 18;
}

.flow-a {
  stroke: var(--cyan);
}

.flow-b {
  stroke: var(--gold);
}

.flow-c {
  stroke: var(--blue);
}

.flow-d {
  stroke: var(--green);
  opacity: 0.72;
}

.flow-nodes circle {
  fill: var(--cyan);
  stroke: var(--bg);
  stroke-width: 4;
  transform-origin: center;
  opacity: 0.88;
}

.flow-nodes circle:nth-child(2) { animation-delay: 160ms; fill: var(--gold); }
.flow-nodes circle:nth-child(3) { animation-delay: 320ms; fill: var(--blue); }
.flow-nodes circle:nth-child(4) { animation-delay: 480ms; fill: var(--green); }
.flow-nodes circle:nth-child(5) { animation-delay: 640ms; fill: var(--cyan); }

.scan-window {
  fill: oklch(75% 0.15 205 / 0.07);
  stroke: oklch(75% 0.15 205 / 0.28);
}

.factor-stack {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  margin-top: 16px;
  background: var(--line);
  border: 1px solid var(--line);
}

.factor-stack div {
  min-height: 86px;
  padding: 14px;
  background: var(--surface);
}

.factor-stack strong {
  display: block;
  margin-top: 12px;
  font-family: var(--mono);
  font-size: 24px;
}

.section {
  width: min(1480px, calc(100vw - 48px));
  margin: 0 auto;
  padding: 104px 0 0;
}

.section-head {
  display: grid;
  gap: 12px;
  max-width: 860px;
  margin-bottom: 30px;
}

h2 {
  font-family: var(--serif);
  font-size: clamp(36px, 4.2vw, 64px);
  line-height: 1.05;
}

.section-head p:last-child,
.strategy-switch p,
.factor-card p,
.download-item em,
.review-timeline p,
.collaboration-copy p,
.collaboration-panel strong {
  color: var(--muted);
  font-size: 17px;
  line-height: 1.62;
}

.strategy-switcher {
  display: grid;
  grid-template-columns: 1.15fr 1fr 1fr 1fr;
  gap: 16px;
}

.strategy-switch {
  min-height: 260px;
  display: grid;
  align-content: space-between;
  gap: 18px;
  padding: 24px;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.strategy-switch:hover {
  transform: translateY(-4px);
  border-color: var(--cyan);
}

.strategy-switch.active {
  background: var(--surface-2);
}

.strategy-switch h3,
.factor-card h3,
.portfolio-panel h3,
.review-timeline strong {
  font-size: 26px;
  line-height: 1.2;
}

.strategy-switch b {
  color: var(--cyan);
  font-family: var(--mono);
  font-size: 13px;
}

.factor-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.factor-card {
  min-height: 300px;
  display: grid;
  align-content: space-between;
  gap: 22px;
  padding: 24px;
}

.factor-card i,
.portfolio-row i {
  display: block;
  height: 7px;
  width: var(--w);
  background: var(--cyan);
  box-shadow: 0 0 18px oklch(75% 0.15 205 / 0.46);
  transform: scaleX(0);
  transform-origin: left;
}

.factor-card.visible i,
.portfolio-panel.visible .portfolio-row i {
  animation: barGrow 820ms cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

.download-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.download-item {
  min-height: 190px;
  display: grid;
  align-content: space-between;
  gap: 16px;
  padding: 24px;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.download-item:hover {
  transform: translateY(-4px);
  border-color: var(--gold);
  background: var(--surface-2);
}

.download-item strong {
  font-size: 22px;
  line-height: 1.3;
}

.download-item em {
  font-style: normal;
}

.validation-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 24px;
}

.nav-panel,
.portfolio-panel {
  padding: 24px;
}

#navPreview {
  display: block;
  width: 100%;
  height: 360px;
  margin-top: 18px;
  border: 1px solid var(--line);
  background: oklch(10% 0.016 232 / 0.7);
}

.portfolio-panel h3 {
  font-family: var(--serif);
  font-size: 32px;
  margin-bottom: 28px;
}

.portfolio-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 18px 0;
  border-top: 1px solid var(--line);
}

.portfolio-row b {
  color: var(--ink);
  font-family: var(--mono);
  font-size: 13px;
}

.portfolio-row i {
  grid-column: 1 / -1;
  height: 8px;
}

.holdings-tape {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.holdings-tape span {
  border: 1px solid var(--line);
  background: oklch(16% 0.024 232 / 0.82);
  padding: 10px 12px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 13px;
  transition: transform 180ms ease, border-color 180ms ease, color 180ms ease;
}

.holdings-tape span:hover {
  color: var(--ink);
  border-color: var(--cyan);
  transform: translateY(-2px);
}

.review-timeline {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.review-timeline article {
  min-height: 220px;
  display: grid;
  align-content: start;
  gap: 12px;
  padding: 24px;
}

.review-timeline span {
  color: var(--gold);
}

.collaboration-section {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 420px;
  gap: 32px;
  align-items: end;
  padding-bottom: 80px;
}

.collaboration-copy {
  display: grid;
  gap: 16px;
}

.collaboration-panel {
  display: grid;
  gap: 18px;
  padding: 28px;
}

.collaboration-panel strong {
  display: block;
  color: var(--ink);
  font-size: 24px;
}

.qr-panel {
  display: grid;
  gap: 12px;
  justify-items: center;
  margin-top: 4px;
  border: 1px solid var(--line);
  background: oklch(10% 0.016 232 / 0.72);
  padding: 18px;
  scroll-margin-top: 96px;
  transition: border-color 180ms ease, box-shadow 180ms ease;
}

.qr-panel:target {
  border-color: var(--cyan);
  box-shadow: 0 0 0 1px oklch(75% 0.15 205 / 0.34), 0 0 36px oklch(75% 0.15 205 / 0.18);
}

.qr-panel img {
  display: block;
  width: min(320px, 100%);
  height: auto;
  background: oklch(96% 0.012 82);
  padding: 8px;
}

.qr-panel p {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.5;
  text-align: center;
}

.download-confirm {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: grid;
  place-items: center;
  padding: 24px;
  background: oklch(7% 0.016 232 / 0.72);
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease;
}

.download-confirm.open {
  opacity: 1;
  pointer-events: auto;
}

.download-dialog {
  width: min(520px, 100%);
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow);
  padding: 28px;
  transform: translateY(10px);
  transition: transform 180ms ease;
}

.download-confirm.open .download-dialog {
  transform: translateY(0);
}

.download-dialog span {
  color: var(--cyan);
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.download-dialog h2 {
  margin-top: 12px;
  font-size: 34px;
}

.download-dialog p {
  margin-top: 14px;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.6;
}

.dialog-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 24px;
}

.dialog-actions button {
  cursor: pointer;
}

.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 620ms ease, transform 620ms ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

@keyframes heroEntry {
  from {
    transform: translateY(22px);
  }
  to {
    transform: translateY(0);
  }
}

@keyframes consoleEntry {
  from {
    transform: translateY(28px) scale(0.98);
  }
  to {
    transform: translateY(0) scale(1);
  }
}

@keyframes barGrow {
  to {
    transform: scaleX(1);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 1ms !important;
  }
}

@media (max-width: 1100px) {
  .site-header,
  .strategy-hero,
  .section {
    width: calc(100vw - 28px);
  }

  .strategy-hero,
  .strategy-switcher,
  .factor-grid,
  .download-grid,
  .validation-grid,
  .review-timeline,
  .collaboration-section {
    grid-template-columns: 1fr;
  }

  .strategy-hero {
    min-height: auto;
    padding-top: 34px;
  }

  .strategy-console,
  .nav-panel,
  .portfolio-panel,
  .collaboration-panel {
    min-width: 0;
  }

  nav {
    justify-content: flex-start;
    overflow-x: auto;
    gap: 18px;
    padding-bottom: 4px;
  }

  .download-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 720px) {
  .site-header {
    gap: 8px;
    padding-top: 10px;
  }

  .brand-text strong {
    font-size: 18px;
  }

  .brand img {
    width: 44px;
    height: 44px;
  }

  h1 {
    font-size: clamp(38px, 10vw, 44px);
    max-width: 100%;
  }

  .hero-lede {
    font-size: 18px;
    max-width: 100%;
  }

  .hero-state,
  .factor-stack,
  .download-grid {
    grid-template-columns: 1fr;
  }

  .terminal-bar,
  .panel-head {
    display: grid;
  }

  .section {
    padding-top: 72px;
  }

  #navPreview {
    height: 300px;
  }
}
