:root {
  color-scheme: light;
  --background: #ffffff;
  --ink: #242329;
  --muted: #62636f;
  --subtle: #7a7c88;
  --rule: #dddde3;
  --brand: #793cf2;
  --hero-height: 678px;
  --art-size: 424px;
  font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
  letter-spacing: 0;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--background); }
a { color: inherit; text-decoration: none; }
a:focus-visible { outline: 2px solid var(--brand); outline-offset: 6px; border-radius: 3px; }
img { display: block; max-width: 100%; }
p, h1, h2 { margin: 0; }
.container { width: calc(100% - 80px); max-width: 1328px; margin-inline: auto; }

.site-header { height: 80px; border-bottom: 1px solid var(--rule); }
.header-inner { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 12px; flex-shrink: 0; font-size: 30px; font-weight: 650; line-height: 1.3; }
.brand img { width: 56px; height: 56px; object-fit: contain; }
nav { display: flex; align-items: center; gap: 56px; color: var(--muted); font-size: 20px; line-height: 1.4; }
nav a { display: inline-flex; align-items: center; gap: 12px; white-space: nowrap; transition: color 160ms ease; }
nav a:hover { color: var(--ink); }
.app-link img { width: 24px; height: 24px; }

.hero { position: relative; height: var(--hero-height); overflow: hidden; text-align: center; isolation: isolate; }
.hero-copy { position: relative; z-index: 1; padding: 48px 24px 0; }
.hero h1 { font-size: 92px; font-weight: 700; line-height: 1.13; }
.hero-copy p { margin-top: 10px; color: var(--muted); font-size: 36px; line-height: 1.5; }
.primary-action { display: inline-flex; align-items: center; justify-content: center; gap: 18px; width: 258px; height: 56px; margin-top: 24px; border: 1px solid var(--ink); border-radius: 6px; background: #2b2b33; color: #ffffff; font-size: 22px; font-weight: 500; line-height: 1.3; transition: background 160ms ease, transform 160ms ease; }
.primary-action:hover { background: #15151b; transform: translateY(-2px); }
.primary-action:active { transform: translateY(0); }
.primary-action img { width: 24px; height: 24px; filter: invert(1); }
.hero-art { position: absolute; bottom: -34px; left: 50%; width: var(--art-size); aspect-ratio: 1; transform: translateX(-50%); pointer-events: none; }
.hero-art img { width: 100%; height: 100%; object-fit: contain; }

.products { border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); scroll-margin-top: 24px; }
.product-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); width: calc(100% - 64px); max-width: 1472px; padding-block: 34px; }
.product { min-height: 102px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding-inline: 16px; text-align: center; }
.product + .product { border-left: 1px solid var(--rule); }
.product h2 { font-size: 34px; font-weight: 650; line-height: 1.4; }
.product p { color: var(--muted); font-size: 22px; line-height: 1.6; }

.footer-inner { display: grid; grid-template-columns: 1fr auto; gap: 6px 24px; padding-block: 18px 22px; color: var(--subtle); font-size: 16px; line-height: 1.5; }
.company { grid-column: 1; }
.icp { grid-column: 2; grid-row: 1; justify-self: end; }
.icp:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
.copyright { grid-column: 1; font-size: 14px; }
.legal-links { grid-column: 2; grid-row: 2; justify-self: end; gap: 20px; font-size: 14px; line-height: 1.5; }
.legal-links a:hover { text-decoration: underline; text-underline-offset: 4px; }

@media (max-width: 1100px) {
  .container { width: calc(100% - 64px); }
  .product h2 { font-size: 28px; }
  .product p { font-size: 17px; }
}

@media (min-width: 641px) and (max-height: 850px) {
  :root { --hero-height: min(600px, calc(100svh - 156px)); --art-size: 330px; }
  .hero-copy { padding-top: 32px; }
  .hero h1 { font-size: 64px; }
  .hero-copy p { margin-top: 6px; font-size: 28px; }
  .primary-action { margin-top: 18px; height: 50px; font-size: 20px; }
  .hero-art { bottom: -26px; }
}

@media (min-width: 641px) and (max-height: 650px) {
  :root { --hero-height: min(520px, calc(100svh - 124px)); --art-size: 244px; }
  .hero-copy { padding-top: 24px; }
  .hero h1 { font-size: 48px; }
  .hero-copy p { font-size: 22px; }
  .primary-action { margin-top: 16px; height: 44px; font-size: 18px; }
  .hero-art { bottom: -20px; }
}

@media (min-width: 641px) and (max-height: 450px) {
  :root { --art-size: 144px; }
  .hero-copy { padding-top: 12px; }
  .hero h1 { font-size: 36px; }
  .hero-copy p { margin-top: 4px; font-size: 18px; }
  .primary-action { margin-top: 12px; height: 40px; font-size: 16px; }
  .hero-art { bottom: -12px; }
}

@media (max-width: 640px) {
  :root { --hero-height: min(650px, calc(100svh - 144px)); --art-size: min(420px, calc(100% - 16px)); }
  .container { width: calc(100% - 36px); }
  .site-header { height: 68px; }
  .header-inner { gap: 12px; }
  .brand { gap: 4px; font-size: 22px; }
  .brand img { width: 36px; height: 36px; }
  nav { gap: 22px; font-size: 14px; }
  nav a { gap: 4px; }
  .app-link img { width: 18px; height: 18px; }
  .hero-copy { padding: 46px 18px 0; }
  .hero h1 { font-size: 56px; }
  .hero-copy p { margin-top: 12px; font-size: 24px; }
  .primary-action { width: 224px; height: 52px; margin-top: 24px; font-size: 19px; gap: 14px; }
  .primary-action img { width: 22px; height: 22px; }
  .hero-art { bottom: -30px; }
  .product-grid { width: calc(100% - 36px); grid-template-columns: 1fr; padding-block: 0; }
  .product { min-height: 132px; padding: 22px 4px; gap: 8px; }
  .product + .product { border-left: 0; border-top: 1px solid var(--rule); }
  .product h2 { font-size: 26px; }
  .product p { font-size: 17px; }
  .footer-inner { grid-template-columns: 1fr; padding-block: 24px; gap: 10px; text-align: center; font-size: 14px; }
  .company, .icp, .copyright { grid-column: 1; grid-row: auto; }
  .icp { justify-self: center; }
  .copyright { font-size: 12px; }
  .legal-links { grid-column: 1; grid-row: auto; justify-self: center; flex-wrap: wrap; justify-content: center; }
}

@media (max-width: 360px) {
  .brand { font-size: 20px; }
  .brand img { width: 32px; height: 32px; }
  nav { gap: 16px; font-size: 12px; }
}

@media (max-width: 640px) and (max-height: 680px) {
  :root { --art-size: 244px; }
  .hero-copy { padding-top: 24px; }
  .hero h1 { font-size: 46px; }
  .hero-copy p { margin-top: 6px; font-size: 20px; }
  .primary-action { margin-top: 18px; height: 48px; font-size: 18px; }
  .hero-art { bottom: -20px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  a { transition: none !important; }
  .primary-action:hover { transform: none; }
}
