@font-face {
  font-family: "Recall Display";
  src: url("assets/fonts/NotoSansSC-Bold.otf") format("opentype");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}

:root {
  --paper: #f9f9f9;
  --surface: #ffffff;
  --surface-soft: #f6f7f8;
  --ink: #0c0c0c;
  --ink-soft: #4b5563;
  --cobalt: #184dcf;
  --cobalt-dark: #103ba5;
  --cobalt-soft: #eef2fd;
  --teal: #006871;
  --teal-soft: #e9f3f3;
  --orange: #d9773f;
  --rule: #d8dadd;
  --rule-soft: #eceef0;
  --focus: #ed7a38;
  --container: 1200px;
  --font-ui: "Segoe UI Variable", "Segoe UI", "Microsoft YaHei UI", "Microsoft YaHei", sans-serif;
  --font-display: "Recall Display", "Microsoft YaHei UI", "Microsoft YaHei", sans-serif;
  --font-code: "Cascadia Code", "SFMono-Regular", Consolas, monospace;
  --ease-out: cubic-bezier(.16, 1, .3, 1);
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: var(--font-ui);
  font-size: 16px;
  line-height: 1.6;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

::selection {
  color: #fff;
  background: var(--cobalt);
}

:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--focus) 78%, white);
  outline-offset: 3px;
}

a {
  color: inherit;
  text-decoration-thickness: 1px;
  text-underline-offset: .22em;
}

/* ===== Navigation ===== */
.site-header {
  position: sticky;
  z-index: 50;
  top: 0;
  border-bottom: 1px solid var(--rule);
  background: color-mix(in srgb, var(--paper) 96%, transparent);
  backdrop-filter: blur(8px);
}

.nav-inner {
  display: flex;
  align-items: center;
  width: min(100%, var(--container));
  height: 64px;
  margin: 0 auto;
  padding: 0 28px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex: none;
  text-decoration: none;
  letter-spacing: -.025em;
  white-space: nowrap;
  font-size: 18px;
  font-weight: 700;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(18px, 2.2vw, 36px);
  margin-left: auto;
  font-size: 14px;
  font-weight: 560;
}

.nav-links a {
  position: relative;
  text-decoration: none;
  color: var(--ink);
  transition: color .2s ease;
}

.nav-links a:hover { color: var(--cobalt); }

.nav-cta {
  display: inline-flex;
  min-height: 38px;
  align-items: center;
  padding: 0 18px;
  border: 1px solid var(--cobalt);
  border-radius: 4px;
  color: var(--cobalt);
  background: var(--surface);
  cursor: pointer;
  transition: color .2s ease, background-color .2s ease, transform .2s var(--ease-out);
}

.nav-cta:hover {
  color: #fff;
  background: var(--cobalt);
  transform: translateY(-1px);
}

/* ===== Buttons ===== */
.btn-primary {
  display: inline-flex;
  min-height: 50px;
  align-items: center;
  justify-content: center;
  padding: 0 22px;
  border: 1px solid var(--cobalt);
  border-radius: 4px;
  color: #fff;
  background: var(--cobalt);
  font-family: var(--font-ui);
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: color .2s ease, background-color .2s ease, border-color .2s ease, transform .2s var(--ease-out), box-shadow .2s ease;
}

.btn-primary:hover {
  background: var(--cobalt-dark);
  box-shadow: 0 8px 18px rgba(24, 77, 207, .16);
  transform: translateY(-2px);
}

.btn-secondary {
  display: inline-flex;
  min-height: 50px;
  align-items: center;
  justify-content: center;
  padding: 0 22px;
  border: 1px solid var(--cobalt);
  border-radius: 4px;
  color: var(--cobalt);
  background: #fff;
  font-family: var(--font-ui);
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: color .2s ease, background-color .2s ease, transform .2s var(--ease-out);
}

.btn-secondary:hover {
  color: #fff;
  background: var(--cobalt);
  transform: translateY(-2px);
}

.btn-lg {
  min-height: 58px;
  padding: 0 34px;
  font-size: 17px;
}

/* ===== Hero ===== */
.hero-main {
  display: grid;
  grid-template-columns: minmax(360px, 1.1fr) 1fr;
  gap: 48px;
  width: min(100%, var(--container));
  min-height: calc(100vh - 64px);
  margin: 0 auto;
  padding: 58px 28px 54px;
  border-right: 1px solid var(--rule);
  border-left: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}

.hero-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.eyebrow {
  display: inline-flex;
  align-self: flex-start;
  margin: 0 0 18px;
  padding: 4px 12px;
  border: 1px solid var(--teal);
  border-radius: 3px;
  color: var(--teal);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .06em;
  background: var(--teal-soft);
}

.hero-main h1 {
  margin: 0 0 26px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(36px, 3.5vw, 52px);
  line-height: 1.14;
  letter-spacing: -.035em;
  text-wrap: balance;
}

.hero-sub {
  margin: 0 0 18px;
  color: #232b39;
  font-size: clamp(16px, 1.35vw, 19px);
  font-weight: 500;
  line-height: 1.8;
}

.hero-sub strong {
  color: var(--cobalt);
  font-weight: 700;
}

.hero-points {
  display: grid;
  gap: 10px;
  margin: 6px 0 0;
  padding: 0;
  list-style: none;
}

.hero-points li {
  position: relative;
  padding-left: 22px;
  color: var(--ink-soft);
  font-size: 14px;
}

.hero-points li::before {
  position: absolute;
  top: .58em;
  left: 2px;
  width: 8px;
  height: 8px;
  content: "";
  background: var(--teal);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 32px;
}

/* ===== Hero Card ===== */
.hero-card {
  align-self: center;
  border: 1px solid var(--rule);
  border-radius: 6px;
  background: var(--surface);
  overflow: hidden;
  box-shadow: 0 12px 32px rgba(0, 0, 0, .05);
}

.card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--rule);
  background: var(--surface-soft);
}

.card-badge {
  color: var(--cobalt);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .04em;
}

.card-status {
  display: inline-flex;
  padding: 3px 10px;
  border-radius: 3px;
  font-size: 11px;
  font-weight: 700;
}

.card-status.ok {
  border: 1px solid var(--teal);
  color: var(--teal);
  background: var(--teal-soft);
}

.card-status.warn {
  border: 1px solid var(--orange);
  color: var(--orange);
  background: #fef3e8;
}

.card-body {
  margin: 0;
  padding: 8px 18px 18px;
}

.card-body > div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 0;
  border-bottom: 1px solid var(--rule-soft);
  font-size: 13px;
}

.card-body > div:last-child { border-bottom: 0; }

.card-body dt {
  flex-shrink: 0;
  color: var(--ink-soft);
  font-weight: 600;
}

.card-body dd {
  margin: 0;
  text-align: right;
  word-break: break-word;
}

.card-body small {
  display: block;
  margin-top: 2px;
  color: var(--ink-soft);
  font-size: 11px;
}

/* ===== Stat Strip ===== */
.stat-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  width: min(100%, var(--container));
  margin: 0 auto;
  border-right: 1px solid var(--rule);
  border-left: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  background: var(--surface);
}

.stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 36px 20px;
  border-right: 1px solid var(--rule);
  text-align: center;
}

.stat:last-child { border-right: 0; }

.stat strong {
  color: var(--cobalt);
  font-family: var(--font-code);
  font-size: clamp(28px, 3vw, 42px);
  font-weight: 700;
  letter-spacing: -.035em;
  line-height: 1.1;
}

.stat:nth-child(2n) strong { color: var(--teal); }

.stat span {
  margin-top: 10px;
  font-size: 14px;
  font-weight: 650;
  color: var(--ink-soft);
}

/* ===== Sections ===== */
main { width: 100%; }

.section-block {
  width: min(100%, var(--container));
  margin: 0 auto;
  padding: 100px 28px;
  border-right: 1px solid var(--rule);
  border-left: 1px solid var(--rule);
}

.section-head {
  max-width: 72ch;
  margin-bottom: 48px;
}

.section-head h2 {
  margin: 0 0 16px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(32px, 3.5vw, 48px);
  line-height: 1.14;
  letter-spacing: -.035em;
  text-wrap: balance;
}

.section-head p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 17px;
  line-height: 1.8;
}

/* ===== API Features ===== */
.api-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.api-feature {
  display: flex;
  flex-direction: column;
  padding: 32px;
  border: 1px solid var(--rule);
  border-radius: 6px;
  background: var(--surface);
  transition: border-color .2s ease, box-shadow .2s ease, transform .2s var(--ease-out);
}

.api-feature:hover {
  border-color: var(--cobalt);
  box-shadow: 0 8px 24px rgba(0, 0, 0, .06);
  transform: translateY(-2px);
}

.api-feature h3 {
  margin: 0 0 12px;
  font-size: 21px;
  font-weight: 700;
  letter-spacing: -.02em;
}

.api-feature p {
  margin: 0 0 20px;
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.75;
}

.path {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  padding: 9px 14px;
  border: 1px solid var(--rule);
  border-radius: 4px;
  color: var(--ink);
  background: var(--surface-soft);
  font-family: var(--font-code);
  font-size: 13px;
  font-weight: 600;
  word-break: break-all;
}

.try-btn {
  align-self: flex-start;
  margin-top: 20px;
  padding: 9px 18px;
  border: 1px solid var(--teal);
  border-radius: 4px;
  color: var(--teal);
  background: var(--surface);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: color .2s ease, background-color .2s ease, transform .2s var(--ease-out);
}

.try-btn:hover {
  color: #fff;
  background: var(--teal);
  transform: translateY(-1px);
}

/* ===== Steps ===== */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  border-top: 1px solid var(--ink);
  border-left: 1px solid var(--rule);
}

.step {
  position: relative;
  padding: 32px 24px 28px;
  border-right: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  background: var(--surface);
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  margin-bottom: 16px;
  border: 1px solid var(--cobalt);
  border-radius: 50%;
  color: var(--cobalt);
  font-family: var(--font-code);
  font-size: 13px;
  font-weight: 700;
}

.step h3 {
  margin: 0 0 8px;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -.02em;
}

.step p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 13px;
  line-height: 1.7;
}

/* ===== Code Demo ===== */
.code-demo {
  margin-top: 40px;
  border: 1px solid var(--rule);
  border-radius: 6px;
  background: var(--surface);
  overflow: hidden;
}

.demo-label {
  padding: 14px 20px;
  border-bottom: 1px solid var(--rule);
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .04em;
  background: var(--surface-soft);
}

.code-demo pre {
  margin: 0;
  padding: 20px 24px;
  color: #dbe3e5;
  background: #111617;
  font-family: var(--font-code);
  font-size: 13px;
  line-height: 1.65;
  white-space: pre;
  overflow-x: auto;
}

.code-demo code {
  font-family: var(--font-code);
  font-size: 13px;
}

/* ===== Field Table ===== */
.field-table-wrap {
  border: 1px solid var(--rule);
  border-radius: 6px;
  background: var(--surface);
  overflow-x: auto;
}

.field-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.field-table th {
  padding: 14px 18px;
  border-bottom: 1px solid var(--rule);
  color: var(--cobalt);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .04em;
  text-align: left;
  background: var(--surface-soft);
}

.field-table td {
  padding: 12px 18px;
  border-bottom: 1px solid var(--rule-soft);
  color: var(--ink-soft);
  line-height: 1.6;
}

.field-table tr:last-child td { border-bottom: 0; }

.field-table tbody tr:nth-child(even) { background: var(--surface-soft); }

.field-table td:first-child {
  color: var(--ink);
  font-family: var(--font-code);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}

/* ===== Scenarios ===== */
.scenario-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.scenario-card {
  padding: 28px;
  border: 1px solid var(--rule);
  border-radius: 6px;
  background: var(--surface);
  transition: border-color .2s ease, box-shadow .2s ease, transform .2s var(--ease-out);
}

.scenario-card:hover {
  border-color: var(--teal);
  box-shadow: 0 8px 24px rgba(0, 0, 0, .06);
  transform: translateY(-2px);
}

.scenario-card h3 {
  margin: 0 0 10px;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -.02em;
}

.scenario-card p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.7;
}

/* ===== Pricing ===== */
.price-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  border-top: 1px solid var(--ink);
  border-left: 1px solid var(--rule);
}

.price-card {
  display: flex;
  flex-direction: column;
  padding: 32px 24px 26px;
  border-right: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  background: var(--surface);
}

.price-card.featured {
  box-shadow: inset 0 3px 0 var(--cobalt);
}

.price-card h3 {
  margin: 0 0 8px;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -.03em;
}

.price-card .price {
  display: flex;
  align-items: baseline;
  gap: 7px;
  min-height: 60px;
  padding: 14px 0;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  color: var(--ink);
  font-size: clamp(20px, 2vw, 28px);
  font-weight: 700;
  letter-spacing: -.025em;
}

.price-card .price span {
  color: var(--ink-soft);
  font-size: 13px;
  font-weight: 600;
}

.price-card ul {
  flex: 1;
  margin: 20px 0;
  padding: 0;
  list-style: none;
}

.price-card li {
  padding: 8px 0;
  border-bottom: 1px solid var(--rule-soft);
  color: var(--ink-soft);
  font-size: 14px;
}

.price-card .btn-primary {
  width: 100%;
}

/* ===== Why ===== */
.why-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.why-item {
  padding: 28px;
  border: 1px solid var(--rule);
  border-radius: 6px;
  background: var(--surface);
}

.why-item h3 {
  margin: 0 0 10px;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -.02em;
}

.why-item h3::before {
  display: inline-block;
  width: 10px;
  height: 10px;
  margin-right: 10px;
  content: "";
  background: var(--cobalt);
}

.why-item p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.7;
}

/* ===== FAQ ===== */
.faq-item {
  border-bottom: 1px solid var(--rule);
}

.faq-item:first-of-type { border-top: 1px solid var(--ink); }

.faq-item summary {
  position: relative;
  padding: 24px 48px 24px 0;
  font-size: 18px;
  font-weight: 650;
  cursor: pointer;
  list-style: none;
  transition: color .2s ease;
}

.faq-item summary:hover { color: var(--cobalt); }

.faq-item summary::-webkit-details-marker { display: none; }

.faq-item summary::before,
.faq-item summary::after {
  position: absolute;
  top: 50%;
  right: 8px;
  width: 16px;
  height: 2px;
  content: "";
  background: var(--ink);
  transition: transform .25s var(--ease-out);
}

.faq-item summary::after { transform: rotate(90deg); }

.faq-item[open] summary::after { transform: rotate(0); }

.faq-item p {
  max-width: 72ch;
  margin: -4px 0 0;
  padding: 0 48px 26px 0;
  color: var(--ink-soft);
  line-height: 1.8;
}

/* ===== CTA ===== */
.cta-block {
  width: min(100%, var(--container));
  margin: 0 auto;
  padding: 90px 28px;
  border-right: 1px solid var(--teal);
  border-left: 1px solid var(--teal);
  color: #fff;
  background: var(--teal);
  text-align: center;
}

.cta-block h2 {
  max-width: 20ch;
  margin: 0 auto 16px;
  color: #fff;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(28px, 3vw, 40px);
  line-height: 1.2;
  letter-spacing: -.03em;
  text-wrap: balance;
}

.cta-block p {
  max-width: 56ch;
  margin: 0 auto 32px;
  color: #cce4e5;
  font-size: 17px;
}

.cta-block .btn-primary {
  background: #fff;
  color: var(--teal);
  border-color: #fff;
}

.cta-block .btn-primary:hover {
  background: var(--surface-soft);
  box-shadow: 0 8px 18px rgba(0, 0, 0, .12);
}

/* ===== Footer ===== */
.site-footer {
  border-top: 1px solid var(--rule);
  background: var(--surface);
}

.site-footer {
  padding: 48px 28px;
  text-align: center;
}

.site-footer p {
  margin: 0 0 10px;
  color: var(--ink-soft);
  font-size: 13px;
  line-height: 1.7;
}

.site-footer p:last-child { margin-bottom: 0; }

.footer-meta {
  font-size: 12px !important;
}

/* ===== Modal ===== */
.modal {
  position: fixed;
  z-index: 100;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal[hidden] { display: none; }

.modal-mask {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, .45);
}

.modal-body {
  position: relative;
  z-index: 2;
  max-width: 420px;
  width: 90%;
  padding: 36px;
  border-radius: 8px;
  background: var(--surface);
  text-align: center;
  box-shadow: 0 24px 64px rgba(0, 0, 0, .18);
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 16px;
  padding: 4px 10px;
  border: 0;
  background: transparent;
  font-size: 24px;
  color: var(--ink-soft);
  cursor: pointer;
  transition: color .2s ease;
}

.modal-close:hover { color: var(--ink); }

.modal-body h3 {
  margin: 0 0 10px;
  font-size: 22px;
  font-weight: 700;
}

.modal-body p {
  margin: 0 0 20px;
  color: var(--ink-soft);
  font-size: 14px;
}

.qr-img {
  max-width: 220px;
  width: 100%;
  border-radius: 6px;
}

.qr-tip {
  margin-top: 16px !important;
  font-size: 12px !important;
  color: var(--ink-soft);
}

/* ===== Responsive ===== */
@media (max-width: 1024px) {
  .hero-main {
    grid-template-columns: 1fr;
    min-height: auto;
  }
  .hero-card { order: -1; }
  .api-grid { grid-template-columns: 1fr; }
  .scenario-grid { grid-template-columns: repeat(2, 1fr); }
  .price-grid { grid-template-columns: repeat(2, 1fr); }
  .why-grid { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
  .nav-links { display: none; }
  .hero-main { padding: 36px 20px; }
  .section-block { padding: 64px 20px; }
  .stat-strip { grid-template-columns: repeat(2, 1fr); }
  .stat { border-bottom: 1px solid var(--rule); }
  .steps { grid-template-columns: 1fr; }
  .scenario-grid { grid-template-columns: 1fr; }
  .price-grid { grid-template-columns: 1fr; }
  .why-grid { grid-template-columns: 1fr; }
  .api-feature { padding: 24px; }
  .cta-block { padding: 64px 20px; }
}
