:root {
  --paper: #ffffff;
  --paper-soft: #f1f0ea;
  --ink: #0a0a0a;
  --ink-2: #4a4a45;
  --ink-3: #8b8a84;
  --line: #dedbd1;
  --line-strong: #0a0a0a;
  --accent: #0a0a0a;
  --radius: 22px;
  font-family: "Noto Sans SC", Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: #fff;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }

.home-page {
  min-height: 100vh;
  overflow-x: hidden;
  background: #fff;
}

.home-page.is-loading {
  max-height: 100vh;
}

.page-container {
  width: min(1160px, calc(100% - 36px));
  margin: 0 auto;
}

.page-header {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
}

.header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 64px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
}

.page-header.scrolled .header-row {
  background: transparent;
  border-color: transparent;
}

.brand, .header-nav, .page-nav {
  display: flex;
  align-items: center;
}

.brand {
  gap: 8px;
  font-weight: 900;
}

.brand-mark {
  display: none;
  width: 0;
  height: 0;
  place-items: center;
  border: 0;
  border-radius: 0;
  background: transparent;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 12px;
  letter-spacing: 0;
}

.brand-name {
  font-family: "Noto Serif SC", serif;
  font-size: 25px;
  font-weight: 900;
}

.header-nav {
  gap: 30px;
  color: var(--ink-2);
  font-size: 14px;
}

.header-nav a:hover, .nav-link:hover {
  color: var(--ink);
}

.page-nav {
  gap: 10px;
}

.nav-link, .nav-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 18px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  cursor: pointer;
  font-weight: 700;
  transform: translateY(0) scale(1);
  transition:
    color .18s ease,
    background .18s ease,
    transform .16s cubic-bezier(.2, 1.4, .35, 1),
    box-shadow .18s ease;
}

.nav-cta, .cta-primary {
  background: var(--ink);
  color: #fff;
}

.nav-link:hover,
.nav-cta:hover {
  transform: translateY(-2px) scale(1.02);
}

.nav-link:hover {
  background: rgba(10, 10, 10, .05);
}

.nav-cta:hover {
  box-shadow: 0 12px 28px rgba(10, 10, 10, .16);
}

.nav-link:active,
.nav-cta:active {
  transform: translateY(2px) scale(.96);
}

.nav-cta:active {
  box-shadow: inset 0 2px 8px rgba(255, 255, 255, .14);
}

.hero-section {
  position: relative;
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 142px 0 82px;
  overflow: hidden;
}

.hero-block {
  position: relative;
  z-index: 2;
  text-align: center;
  width: min(1060px, calc(100% - 28px));
  opacity: 0;
  transform: translateY(18px) scale(.985);
  transition: opacity .8s ease, transform .8s cubic-bezier(.2, 1, .2, 1);
}

.home-page.is-revealed .hero-block {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.hero-eyebrow {
  display: inline-flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 0 0 22px;
  padding: 10px 22px;
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  background: rgba(255, 255, 255, .74);
  font-family: "Noto Sans SC", Inter, sans-serif;
  color: var(--ink);
  font-size: 16px;
  font-weight: 900;
  text-transform: none;
  white-space: nowrap;
  text-align: center;
}

.hero-title {
  position: relative;
  z-index: 0;
  isolation: isolate;
  margin: 0;
  text-align: center;
}

.hero-zh {
  display: block;
  position: relative;
  z-index: 1;
  justify-content: center;
  font-family: "Noto Serif SC", serif;
  font-size: clamp(58px, 7.4vw, 96px);
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0;
  white-space: nowrap;
}

.hz-mid {
  font-style: italic;
  font-weight: 700;
}

.hero-en {
  display: block;
  margin-top: 16px;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: clamp(24px, 3.4vw, 44px);
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero-slogan {
  max-width: 720px;
  margin: 30px auto 0;
  color: var(--ink-2);
  font-size: 17px;
  line-height: 1.9;
}

.hero-ctas {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 34px;
}

.cta-primary, .cta-text, .cta-text-large {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 26px;
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  font-weight: 900;
  cursor: pointer;
  transition: transform .2s ease, box-shadow .2s ease;
}

.cta-primary:hover, .cta-text:hover, .cta-text-large:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 38px rgba(10, 10, 10, .12);
}

.cta-text, .cta-text-large {
  background: rgba(255, 255, 255, .44);
}

.active-on {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 15px;
  margin: 30px auto 0;
  padding: 0;
  color: var(--ink-3);
  list-style: none;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 12px;
  font-weight: 600;
}

.active-on li::before {
  content: "·";
  margin-right: 14px;
}

.home-page section:not(.hero-section) {
  padding: 96px 0;
  opacity: 0;
  filter: blur(10px);
  transform: translateY(48px) scale(.985);
  transition:
    opacity .9s ease,
    filter .9s ease,
    transform .9s cubic-bezier(.18, 1, .22, 1);
  will-change: opacity, filter, transform;
}

.home-page section.in-view {
  opacity: 1;
  filter: blur(0);
  transform: translateY(0);
}

.home-page section:not(.hero-section) :is(.section-tag, h2, .section-head p, .image-showcase, .why-ledger, .onboard-grid, .pricing-block > p, .pricing-block ul),
.closer-section > .cta-primary {
  opacity: 0;
  transform: translateY(18px);
  transition:
    opacity .72s ease,
    transform .72s cubic-bezier(.18, 1, .22, 1);
}

.home-page section.in-view :is(.section-tag, h2, .section-head p, .image-showcase, .why-ledger, .onboard-grid, .pricing-block > p, .pricing-block ul),
.closer-section.in-view > .cta-primary {
  opacity: 1;
  transform: translateY(0);
}

.home-page section.in-view .section-tag { transition-delay: .04s; }
.home-page section.in-view h2 { transition-delay: .1s; }
.home-page section.in-view .section-head p,
.home-page section.in-view .pricing-block > p { transition-delay: .16s; }
.home-page section.in-view .image-showcase,
.home-page section.in-view .why-ledger,
.home-page section.in-view .onboard-grid,
.home-page section.in-view .pricing-block ul { transition-delay: .22s; }
.home-page section.in-view.closer-section > .cta-primary { transition-delay: .28s; }

.section-block, .pricing-block {
  border-top: 1.5px solid var(--ink);
  padding-top: 36px;
}

.section-tag {
  display: inline-block;
  margin: 0 0 18px;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.section-head {
  max-width: 830px;
  margin-bottom: 42px;
}

.section-head h2, .pricing-block h2 {
  margin: 0;
  font-family: "Noto Serif SC", serif;
  font-size: clamp(38px, 6vw, 76px);
  line-height: 1.08;
  letter-spacing: 0;
}

.section-head p, .pricing-block p {
  color: var(--ink-2);
  font-size: 18px;
  line-height: 1.9;
}


.image-showcase, .onboard-grid {
  display: grid;
  grid-template-columns: minmax(0, .76fr) minmax(430px, 1fr);
  gap: 34px;
  align-items: center;
}

.img-info {
  position: relative;
}

.chc-rule {
  display: block;
  width: 82px;
  height: 1.5px;
  margin-bottom: 28px;
  background: var(--ink);
}

.img-model-line {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-bottom: 18px;
}

.img-model-line span, .img-model-line em {
  padding: 8px 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, .56);
  font-size: 13px;
  font-style: normal;
}

.img-info p p {
  color: var(--ink-2);
  line-height: 1.85;
}

.img-demo {
  position: relative;
  overflow: hidden;
  padding: 18px;
  border: 1.5px solid var(--ink);
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 18px 44px rgba(10, 10, 10, .08);
  transform:
    perspective(900px)
    rotateX(var(--tilt-x, 0deg))
    rotateY(var(--tilt-y, 0deg))
    translateY(var(--tilt-rise, 0));
  transition: transform .16s ease, box-shadow .16s ease;
  will-change: transform;
}

.img-demo:hover {
  --tilt-rise: -4px;
  box-shadow: 0 26px 58px rgba(10, 10, 10, .14);
}

.img-demo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at var(--spot-x, 50%) var(--spot-y, 50%), rgba(255,255,255,.38), transparent 28%);
  opacity: 0;
  pointer-events: none;
  transition: opacity .18s ease;
}

.img-demo:hover::after {
  opacity: 1;
}

.img-demo img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  margin: 14px 0;
  border-radius: 18px;
  object-fit: cover;
  filter: grayscale(.8) contrast(1.05);
}

.demo-prompt, .demo-foot {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  color: var(--ink-2);
  font-size: 13px;
}

.demo-prompt strong {
  color: var(--ink);
}

.demo-status i {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 6px;
  border-radius: 50%;
  background: var(--ink);
}


.why-ledger {
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1.5px solid var(--ink);
  position: relative;
}

.why-ledger li {
  display: grid;
  grid-template-columns: 70px minmax(160px, .5fr) 160px minmax(0, 1fr);
  gap: 24px;
  align-items: center;
  padding: 26px 0;
  border-bottom: 1.5px solid var(--line);
  transition: background .2s ease, padding-left .2s ease, border-color .2s ease;
}

.why-ledger li:hover {
  padding-left: 18px;
  border-color: var(--ink);
  background: rgba(255,255,255,.52);
}

.hover-card {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 40;
  width: min(310px, calc(100vw - 28px));
  padding: 16px 17px;
  border: 1.5px solid var(--ink);
  border-radius: 18px;
  background: rgba(255, 255, 255, .94);
  box-shadow: 0 20px 52px rgba(10, 10, 10, .16);
  pointer-events: none;
  opacity: 0;
  transform: translate3d(var(--hc-x, 0), var(--hc-y, 0), 0) scale(.96);
  transition: opacity .12s ease, transform .12s ease;
}

.hover-card.is-visible {
  opacity: 1;
  transform: translate3d(var(--hc-x, 0), var(--hc-y, 0), 0) scale(1);
}

.hover-card strong {
  display: block;
  margin-bottom: 8px;
  font-family: "Noto Serif SC", serif;
  font-size: 22px;
}

.hover-card p {
  margin: 0;
  color: var(--ink-2);
  line-height: 1.65;
  font-size: 14px;
}

.why-ledger span, .why-ledger em {
  color: var(--ink-3);
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-style: normal;
  font-size: 12px;
}

.why-ledger h3 {
  margin: 0;
  font-family: "Noto Serif SC", serif;
  font-size: 28px;
}

.why-ledger p {
  margin: 0;
  color: var(--ink-2);
  line-height: 1.75;
}

.onboard-steps {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.onboard-steps li {
  display: flex;
  gap: 18px;
  padding: 20px;
  border: 1.5px solid var(--ink);
  border-radius: 18px;
  background: #fff;
}

.onboard-steps span {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1.5px solid var(--ink);
  border-radius: 50%;
  flex-shrink: 0;
}

.onboard-steps h3 { margin: 0 0 6px; }
.onboard-steps p { margin: 0; color: var(--ink-2); line-height: 1.65; }

pre {
  overflow: auto;
  min-height: 310px;
  margin: 0;
  padding: 24px;
  border: 1.5px solid var(--ink);
  border-radius: 22px;
  background: #0d0d0d;
  color: #fff;
}

code {
  font-family: "JetBrains Mono", Consolas, monospace;
  font-size: 14px;
  line-height: 1.8;
}

.pricing-block {
  max-width: 900px;
}

.pricing-block ul {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 28px 0;
  padding: 0;
  list-style: none;
}

.pricing-block li {
  padding: 12px 15px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255,255,255,.56);
}

.cta-text-large {
  min-height: 60px;
  padding: 0 30px;
  font-size: 18px;
}

.closer-section {
  display: flex;
  justify-content: center;
}

.page-footer {
  padding: 36px 0 48px;
}

.footer-row {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding-top: 24px;
  border-top: 1.5px solid var(--ink);
  color: var(--ink-2);
}

.contact-page {
  min-height: 100vh;
  padding: 22px 0 90px;
  background: #fff;
}

.docs-page {
  min-height: 100vh;
  padding: 22px 0 90px;
  background: #fff;
}

.models-page {
  min-height: 100vh;
  padding: 22px 0 90px;
  background: #fff;
}

.back-home {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: max(30px, calc((100vw - 860px) / 2));
  color: var(--ink-2);
  font-size: 14px;
  transition: color .18s ease, transform .18s ease;
}

.back-home span {
  font-size: 24px;
  line-height: 1;
}

.back-home:hover {
  color: var(--ink);
  transform: translateX(-3px);
}

.contact-hero,
.contact-grid {
  width: min(860px, calc(100% - 44px));
  margin: 0 auto;
}

.contact-hero {
  padding-top: 88px;
}

.contact-kicker {
  margin: 0 0 20px;
  color: var(--ink-2);
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .08em;
}

.contact-hero h1 {
  margin: 0;
  font-family: "Noto Serif SC", serif;
  font-size: clamp(56px, 8vw, 78px);
  line-height: 1;
  letter-spacing: 0;
}

.contact-hero > p:last-child {
  max-width: 720px;
  margin: 22px 0 0;
  color: var(--ink-2);
  font-size: 16px;
  line-height: 1.9;
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 48px;
}

.contact-card {
  min-height: 258px;
  display: flex;
  flex-direction: column;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 12px 34px rgba(10, 10, 10, .06);
  transition:
    border-color .18s ease,
    box-shadow .18s ease,
    transform .18s cubic-bezier(.2, 1.2, .35, 1);
}

.contact-card:hover {
  border-color: var(--ink);
  transform: translateY(-5px);
  box-shadow: 0 20px 46px rgba(10, 10, 10, .1);
}

.contact-icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-bottom: 20px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fbfbf8;
}

.contact-icon svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: var(--ink);
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.contact-card h2 {
  margin: 0 0 5px;
  font-family: "Noto Serif SC", serif;
  font-size: 24px;
  line-height: 1.15;
}

.contact-id {
  margin: 0;
  color: var(--ink-3);
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 12px;
}

.contact-desc {
  min-height: 48px;
  margin: 18px 0 24px;
  color: var(--ink-2);
  font-size: 14px;
  line-height: 1.75;
}

.contact-action {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-weight: 900;
  transition: gap .18s ease;
}

.contact-action:hover {
  gap: 13px;
}

.docs-shell {
  width: min(1040px, calc(100% - 44px));
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  gap: 44px;
  margin: 78px auto 0;
}

.docs-sidebar {
  position: sticky;
  top: 26px;
  align-self: start;
  display: grid;
  gap: 4px;
  padding: 12px 0;
  border-right: 1px solid var(--line);
}

.docs-sidebar a {
  display: flex;
  align-items: center;
  min-height: 38px;
  padding: 0 14px;
  color: var(--ink-2);
  border-radius: 999px 0 0 999px;
  font-size: 14px;
  font-weight: 700;
  transition: color .18s ease, background .18s ease, transform .18s ease;
}

.docs-sidebar a:hover,
.docs-sidebar a.active {
  color: var(--ink);
  background: rgba(10, 10, 10, .05);
  transform: translateX(3px);
}

.docs-content {
  min-width: 0;
}

.docs-hero {
  padding-bottom: 38px;
  border-bottom: 1.5px solid var(--ink);
}

.docs-kicker {
  margin: 0 0 20px;
  color: var(--ink-2);
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .08em;
}

.docs-hero h1 {
  margin: 0;
  font-family: "Noto Serif SC", serif;
  font-size: clamp(56px, 8vw, 78px);
  line-height: 1;
  letter-spacing: 0;
}

.docs-hero p,
.docs-section p {
  color: var(--ink-2);
  font-size: 16px;
  line-height: 1.9;
}

.docs-hero p {
  max-width: 700px;
  margin: 22px 0 0;
}

.docs-section {
  padding: 44px 0;
  border-bottom: 1px solid var(--line);
}

.docs-section h2 {
  margin: 0 0 16px;
  font-family: "Noto Serif SC", serif;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.1;
}

.docs-section pre {
  margin-top: 22px;
}

.docs-table {
  display: grid;
  margin-top: 24px;
  border-top: 1.5px solid var(--ink);
}

.docs-table > div {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 20px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}

.docs-table b {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 13px;
}

.docs-table span {
  color: var(--ink-2);
  line-height: 1.7;
}

.docs-note {
  margin-top: 20px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--ink);
  border-radius: 8px;
  color: var(--ink-2);
  line-height: 1.75;
}

.docs-section details {
  padding: 18px 0;
  border-top: 1px solid var(--line);
}

.docs-section details:last-child {
  border-bottom: 1px solid var(--line);
}

.docs-section summary {
  cursor: pointer;
  font-weight: 900;
}

.docs-section details p {
  margin-bottom: 0;
}

.models-empty {
  min-height: calc(100vh - 150px);
  display: grid;
  place-items: center;
  align-content: center;
  justify-items: center;
  width: min(760px, calc(100% - 44px));
  margin: 0 auto;
  text-align: center;
}

.models-kicker {
  margin: 0 0 28px;
  color: var(--ink-3);
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .32em;
}

.models-empty h1 {
  margin: 0;
  font-family: "Noto Serif SC", serif;
  font-size: clamp(66px, 9vw, 94px);
  line-height: 1;
  letter-spacing: 0;
}

.models-empty p:not(.models-kicker) {
  margin: 28px 0 34px;
  color: var(--ink-2);
  font-size: 17px;
  line-height: 2;
}

@media (max-width: 920px) {
  .header-nav { display: none; }
  .hero-section { padding-top: 126px; }
  .image-showcase, .onboard-grid {
    grid-template-columns: 1fr;
  }
  .why-ledger li {
    grid-template-columns: 48px 1fr;
  }
  .why-ledger em, .why-ledger p {
    grid-column: 2;
  }
}

@media (max-width: 640px) {
  .page-container { width: min(100% - 24px, 1160px); }
  .page-header { top: 10px; }
  .header-row { min-height: 58px; }
  .page-nav .nav-link { display: none; }
  .brand-mark { width: 36px; height: 36px; }
  .hero-zh {
    display: block;
    font-size: clamp(34px, 10.8vw, 46px);
  }
  .hero-eyebrow {
    max-width: 100%;
    padding-inline: 16px;
    font-size: 13px;
  }
  .hero-slogan { font-size: 16px; }
  .cta-primary, .cta-text { width: 100%; }
  .home-page section:not(.hero-section) { padding: 68px 0; }
  .section-head h2, .pricing-block h2 {
    font-size: 40px;
  }
  .gamepad { width: 250px; right: -54px; top: -84px; }
  .footer-row { flex-direction: column; }

  .contact-hero {
    padding-top: 68px;
  }

  .contact-grid {
    grid-template-columns: 1fr;
  }

  .docs-shell {
    grid-template-columns: 1fr;
    gap: 26px;
    margin-top: 52px;
  }

  .docs-sidebar {
    position: static;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding-bottom: 18px;
  }

  .docs-sidebar a {
    border-radius: 999px;
    background: rgba(10, 10, 10, .035);
  }

  .back-home {
    margin-left: 22px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: .001ms !important;
  }

  .home-page.is-loading {
    max-height: none;
  }

  .hero-block,
  .home-page section:not(.hero-section) {
    opacity: 1;
    filter: none;
    transform: none;
  }

  .home-page section:not(.hero-section) :is(.section-tag, h2, .section-head p, .image-showcase, .why-ledger, .onboard-grid, .pricing-block > p, .pricing-block ul),
  .closer-section > .cta-primary {
    opacity: 1;
    transform: none;
  }
}
