@font-face {
  font-family: "DM Sans";
  font-weight: 300;
  font-display: swap;
  src: url("/fonts/DMSans-Light.ttf") format("truetype");
}

@font-face {
  font-family: "DM Sans";
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/DMSans-Regular.ttf") format("truetype");
}

@font-face {
  font-family: "DM Sans";
  font-weight: 500;
  font-display: swap;
  src: url("/fonts/DMSans-Medium.ttf") format("truetype");
}

/* Same tokens as apps/mobile/src/theme.ts ("Nocturne"): graphite stage, hairlines, smoked
   glass, DM Sans and one orange signal. The site is dark only, like the app. */
:root {
  color-scheme: dark;
  --bg: #0d0d10;
  --raised: #131419;
  --surface: rgba(28, 29, 34, 0.72);
  --surface-strong: rgba(36, 37, 43, 0.78);
  --surface-solid: #17171a;
  --surface-solid-strong: #1f1f23;
  --smoke: rgba(13, 13, 16, 0.5);
  --line: rgba(255, 255, 255, 0.09);
  --line-strong: rgba(255, 255, 255, 0.2);
  --control: rgba(255, 255, 255, 0.42);
  --rim: rgba(255, 255, 255, 0.17);
  --text: #f4f5f7;
  --body: #c5c8d0;
  --muted: #8d929d;
  --faint: #5e636e;
  --accent: #ff6b00;
  --accent-glow: rgba(255, 107, 0, 0.45);
  --success: #86d9a0;
  --pending: #e8c368;
  --error: #ff7a85;
  --schedule: #afc0dc;
  --stay: #b8aaee;
  --spot: 201, 206, 218;
  --orb-high: #4b4e58;
  --orb-mid: #1e1f25;
  --orb-low: #0b0b0e;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --page: min(1160px, calc(100% - 48px));
  font-family: "DM Sans", ui-sans-serif, -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}

/* Only one language shows at a time; lang.js picks it before the first paint. */
html[lang^="zh"] [data-l="en"],
html:not([lang^="zh"]) [data-l="zh"] {
  display: none !important;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 24px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

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

em {
  font-style: normal;
  color: var(--accent);
}

:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.5);
  outline-offset: 3px;
  border-radius: 6px;
}

.skip {
  position: absolute;
  left: 16px;
  top: -60px;
  z-index: 10;
  padding: 10px 16px;
  border-radius: 999px;
  background: var(--text);
  color: var(--bg);
  font-size: 13px;
}

.skip:focus {
  top: 16px;
}

/* ---------- Header ---------- */

.site-header {
  position: relative;
  z-index: 3;
  width: var(--page);
  height: 84px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.3em;
}

/* The app's ringed moon; the negative margin trims the box to the disc so the glow overflows. */
.mark {
  display: block;
  width: 40px;
  height: 40px;
  margin: -6.4px;
}

.mark.small {
  width: 28px;
  height: 28px;
  margin: -4.5px;
}

.wordmark b {
  font-weight: 500;
  opacity: 0;
  animation: letter 0.8s var(--ease) forwards;
}

.wordmark b:nth-child(2) { animation-delay: 0.06s; }
.wordmark b:nth-child(3) { animation-delay: 0.12s; }
.wordmark b:nth-child(4) { animation-delay: 0.18s; }
.wordmark b:nth-child(5) { animation-delay: 0.24s; }
.wordmark b:nth-child(6) { animation-delay: 0.3s; }
.wordmark b:nth-child(7) { animation-delay: 0.36s; }
.wordmark b:nth-child(8) { animation-delay: 0.42s; }

.nav {
  display: flex;
  gap: 34px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}

.nav a {
  transition: color 0.3s var(--ease);
}

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

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.lang-toggle {
  min-width: 42px;
  height: 42px;
  padding: 0 12px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--smoke);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  color: var(--body);
  font: inherit;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition: background-color 0.3s var(--ease), border-color 0.3s var(--ease);
}

.lang-toggle:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.34);
}

.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 22px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  /* Smoked like the app's outline controls, so the label holds over the lit plate. */
  background: var(--smoke);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  color: var(--text);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.2em;
  white-space: nowrap;
  transition: background-color 0.3s var(--ease), border-color 0.3s var(--ease), color 0.3s var(--ease);
}

a.pill:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.34);
}

.pill.light {
  border-color: var(--text);
  background: var(--text);
  color: var(--bg);
}

a.pill.light:hover {
  background: #d8dadf;
  border-color: #d8dadf;
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  width: 100%;
  min-height: 860px;
  margin-top: -84px;
  padding: 150px max(24px, calc((100% - 1160px) / 2)) 110px;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  align-items: center;
  gap: 48px;
  overflow: hidden;
}

/* A rendered plate from the same world as the app's page backgrounds. */
.stage {
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    linear-gradient(180deg, transparent 62%, var(--bg)),
    var(--bg) url("/scenes/hero.webp") center top / 1920px auto no-repeat;
  opacity: 0;
  transform-origin: 62% 24%;
  animation:
    stage-in 1.6s var(--ease) 0.1s forwards,
    drift 32s ease-in-out 1.7s infinite alternate;
}

.hero-copy,
.hero .device {
  position: relative;
  z-index: 1;
}

.eyebrow {
  margin: 0 0 26px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.3em;
}

.eyebrow span {
  color: var(--faint);
}

.eyebrow i {
  width: 22px;
  height: 1px;
  background: var(--line-strong);
}

h1 {
  margin: 0;
  font-size: clamp(44px, 5.6vw, 76px);
  font-weight: 300;
  line-height: 1.1;
  letter-spacing: -0.04em;
}

html:not([lang^="zh"]) h1 {
  font-size: clamp(42px, 4.9vw, 68px);
  letter-spacing: -0.045em;
}

/* Chinese headline: each clause on its own line, never split mid-phrase. */
html[lang^="zh"] h1 {
  font-size: clamp(34px, 4.4vw, 64px);
  letter-spacing: -0.02em;
}

h1 .line {
  display: inline-block;
  white-space: nowrap;
}

.lede {
  max-width: 560px;
  margin: 30px 0 36px;
  color: var(--body);
  font-size: 18px;
  line-height: 1.8;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

/* The reserved App Store entry. It is our own button, not Apple's badge: swap in the official
   "Download on the App Store" badge once the app is live (see README). */
.store {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  padding: 0 24px 0 18px;
  border-radius: 999px;
  background: var(--text);
  color: var(--bg);
  transition: background-color 0.3s var(--ease), transform 0.3s var(--ease);
}

.store:hover {
  background: #d8dadf;
}

.store:active {
  transform: scale(0.98);
}

.store svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.store > span {
  display: grid;
  line-height: 1.15;
  text-align: left;
}

.store small {
  font-size: 11px;
  letter-spacing: 0.04em;
  opacity: 0.7;
}

.store b {
  font-size: 19px;
  font-weight: 500;
  letter-spacing: -0.01em;
}

.store[aria-disabled="true"] {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--line-strong);
  background: var(--smoke);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.store[aria-disabled="true"]:hover {
  background: rgba(255, 255, 255, 0.08);
}

.store.large {
  min-height: 64px;
  padding: 0 30px 0 22px;
}

.store.large b {
  font-size: 22px;
}

.status {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 26px 0 0;
  color: var(--muted);
  font-size: 13px;
  letter-spacing: 0.04em;
}

.dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 14px var(--accent-glow);
  animation: pulse 2.6s ease-in-out infinite;
}

.hero-copy > * {
  opacity: 0;
  transform: translateY(14px);
  animation: rise 0.9s var(--ease) forwards;
}

.hero-copy > :nth-child(2) { animation-delay: 0.08s; }
.hero-copy > :nth-child(3) { animation-delay: 0.16s; }
.hero-copy > :nth-child(4) { animation-delay: 0.24s; }
.hero-copy > :nth-child(5) { animation-delay: 0.32s; }

.hero .device {
  opacity: 0;
  transform: translateY(24px);
  animation: rise 1.2s var(--ease) 0.3s forwards;
}

/* ---------- Phone mock-ups ---------- */

.device {
  display: grid;
  place-items: center;
}

.phone {
  position: relative;
  width: 336px;
  max-width: 100%;
  padding: 10px;
  border-radius: 56px;
  background: linear-gradient(160deg, #3a3c44, #17181c 40%, #24252b);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.16),
    0 50px 100px rgba(0, 0, 0, 0.6),
    0 0 0 1px rgba(0, 0, 0, 0.6);
}

.screen {
  position: relative;
  height: 684px;
  padding: 0 20px 14px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 46px;
  background:
    linear-gradient(180deg, rgba(13, 13, 16, 0) 0, rgba(13, 13, 16, 0.25) 110px, rgba(13, 13, 16, 0.86) 300px, var(--bg) 420px),
    var(--bg) var(--plate) center top / 100% auto no-repeat;
  font-size: 14px;
  text-align: left;
}

.statusbar {
  height: 48px;
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 10px;
  font-size: 13px;
  font-weight: 500;
}

.island {
  width: 92px;
  height: 27px;
  border-radius: 999px;
  background: #000;
}

.bars {
  width: 24px;
  height: 11px;
  border: 1px solid rgba(255, 255, 255, 0.6);
  border-radius: 3px;
  position: relative;
}

.bars::after {
  content: "";
  position: absolute;
  inset: 1px 5px 1px 1px;
  border-radius: 1px;
  background: var(--text);
}

.app-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 8px 0 18px;
  min-height: 34px;
}

.icons {
  display: flex;
  gap: 8px;
}

/* Small round icon buttons, drawn with borders so the mock-up needs no images. */
.ico {
  position: relative;
  width: 34px;
  height: 34px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: var(--smoke);
}

.ico::before,
.ico::after {
  content: "";
  position: absolute;
}

.ico.search::before {
  left: 10px;
  top: 9px;
  width: 10px;
  height: 10px;
  border: 1.4px solid var(--text);
  border-radius: 50%;
}

.ico.search::after {
  left: 20px;
  top: 20px;
  width: 5px;
  height: 1.4px;
  background: var(--text);
  transform: rotate(45deg);
  transform-origin: left;
}

.ico.list::before {
  left: 10px;
  top: 11px;
  width: 13px;
  height: 1.4px;
  background: var(--text);
  box-shadow: 0 5px 0 var(--text), 0 10px 0 var(--text);
}

.ico.plus::before,
.ico.plus::after {
  left: 50%;
  top: 50%;
  width: 13px;
  height: 1.4px;
  background: var(--text);
  transform: translate(-50%, -50%);
}

.ico.plus::after {
  transform: translate(-50%, -50%) rotate(90deg);
}

.ico.more::before {
  left: 50%;
  top: 50%;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--text);
  transform: translate(-50%, -50%);
  box-shadow: -6px 0 0 var(--text), 6px 0 0 var(--text);
}

.back {
  width: 34px;
  height: 34px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: var(--smoke);
  position: relative;
}

.back::before {
  content: "";
  position: absolute;
  left: 14px;
  top: 12px;
  width: 8px;
  height: 8px;
  border-left: 1.4px solid var(--text);
  border-bottom: 1.4px solid var(--text);
  transform: rotate(45deg);
}

.app-title {
  margin: 0;
  font-size: 40px;
  font-weight: 300;
  line-height: 1.1;
  letter-spacing: -0.035em;
}

.app-title.small {
  font-size: 32px;
}

.app-sub {
  margin: 6px 0 18px;
  color: var(--muted);
  font-size: 12px;
}

.capture {
  padding: 14px 14px 12px;
  border: 1px solid var(--line);
  border-top-color: var(--rim);
  border-radius: 22px;
  background: var(--surface);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

.capture-text {
  margin: 0 0 14px;
  font-size: 16px;
  font-weight: 300;
}

.capture-text::after {
  content: "";
  display: inline-block;
  width: 1.5px;
  height: 17px;
  margin-left: 2px;
  vertical-align: -3px;
  background: var(--accent);
  animation: caret 1.1s steps(1) infinite;
}

.capture-foot {
  display: flex;
  align-items: center;
  gap: 8px;
}

.switch {
  display: inline-flex;
  padding: 3px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  font-size: 11px;
}

.switch > * {
  padding: 5px 10px;
  border-radius: 999px;
  color: var(--muted);
}

.switch b {
  font-weight: 500;
  background: var(--text);
  color: var(--bg);
}

.chip {
  padding: 6px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  color: var(--body);
  font-size: 11px;
}

.save {
  position: relative;
  width: 32px;
  height: 32px;
  margin-left: auto;
  border-radius: 50%;
  background: var(--text);
}

.save::before {
  content: "";
  position: absolute;
  left: 11px;
  top: 9px;
  width: 6px;
  height: 11px;
  border-right: 1.6px solid var(--bg);
  border-bottom: 1.6px solid var(--bg);
  transform: rotate(45deg);
}

.app-section {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 22px 0 2px;
  color: var(--body);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.24em;
}

.app-section .count {
  color: var(--faint);
  letter-spacing: 0.1em;
}

.focus {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 10px var(--accent-glow);
}

.rows {
  margin: 0;
  padding: 0;
  list-style: none;
}

.rows li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}

.rows li::before {
  content: "";
  flex: none;
  width: 17px;
  height: 17px;
  border: 1px solid var(--control);
  border-radius: 50%;
}

.rows li.done {
  color: var(--muted);
  text-decoration: line-through;
}

.rows li.done::before {
  border-color: var(--text);
  background: var(--text) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4.5 8.2l2.3 2.3 4.7-5' fill='none' stroke='%230d0d10' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 100% no-repeat;
}

.tag {
  margin-left: auto;
  color: var(--muted);
  font-size: 11px;
}

.tabbar {
  margin-top: auto;
  padding: 4px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--surface-solid-strong);
  text-align: center;
  font-size: 10px;
  letter-spacing: 0.12em;
  color: var(--muted);
}

.tabbar > span {
  padding: 11px 0;
  border-radius: 999px;
}

.tabbar .active {
  background: var(--text);
  color: var(--bg);
  font-weight: 500;
}

.segmented {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  margin: 0 0 6px;
  padding: 3px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--smoke);
  font-size: 11px;
  text-align: center;
  color: var(--muted);
}

.segmented.four {
  grid-template-columns: repeat(4, 1fr);
  margin: 16px 0 14px;
}

.segmented > * {
  padding: 7px 0;
  border-radius: 999px;
}

.segmented b {
  font-weight: 500;
  background: rgba(255, 255, 255, 0.11);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.26);
  color: var(--text);
}

.day-head {
  display: flex;
  justify-content: space-between;
  margin: 18px 0 2px;
  color: var(--body);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.14em;
}

.day-head .count {
  color: var(--faint);
}

.entries {
  margin: 0;
  padding: 0;
  list-style: none;
}

.entries li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
  font-size: 13.5px;
}

.tone {
  flex: none;
  width: 7px;
  height: 7px;
  border-radius: 50%;
}

.tone.schedule { background: var(--schedule); }
.tone.stay { background: var(--stay); }

.state {
  margin-left: auto;
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--muted);
  font-size: 10.5px;
}

.state::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
}

.state.ok::before { background: var(--success); }
.state.wait::before { background: var(--pending); }

.stock {
  margin-bottom: 10px;
  padding: 14px 16px 12px;
  border: 1px solid var(--line);
  border-top-color: var(--rim);
  border-radius: 20px;
  background: var(--surface);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

.stock-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}

.stock-top > div {
  display: grid;
  gap: 2px;
}

.stock-top b {
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.stock-top small {
  color: var(--muted);
  font-size: 11px;
}

.pl {
  text-align: right;
  font-size: 15px;
  font-weight: 300;
}

.pl.rise { color: var(--success); }
.pl.fall { color: var(--error); }

.spark {
  display: block;
  width: 100%;
  height: 30px;
  margin: 8px 0 6px;
}

.spark path {
  fill: none;
  stroke: var(--body);
  stroke-width: 1.2;
  vector-effect: non-scaling-stroke;
}

.spark path.wash {
  fill: rgba(244, 245, 247, 0.07);
  stroke: none;
}

.tier {
  display: flex;
  align-items: center;
  gap: 7px;
  margin: 0;
  color: var(--muted);
  font-size: 11px;
}

.signal-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 10px var(--accent-glow);
}

.stock.savings {
  padding-bottom: 14px;
}

/* ---------- Sections ---------- */

.section-head {
  max-width: 720px;
  margin-bottom: 56px;
}

h2 {
  margin: 0;
  font-size: clamp(32px, 3.8vw, 48px);
  font-weight: 300;
  line-height: 1.18;
  letter-spacing: -0.03em;
}

h3 {
  margin: 0;
  font-weight: 300;
}

.section-lede {
  margin: 22px 0 0;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.8;
}

.number {
  color: var(--faint);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.3em;
}

.ticks {
  margin: 22px 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 12px;
  color: var(--body);
  font-size: 15px;
  line-height: 1.55;
}

.ticks li {
  display: flex;
  gap: 12px;
}

.ticks li::before {
  content: "";
  flex: none;
  width: 5px;
  height: 5px;
  margin-top: 9px;
  border-radius: 50%;
  background: var(--body);
}

.modules,
.details,
.ecosystem {
  width: var(--page);
  margin: 0 auto;
  padding: 120px 0;
  border-top: 1px solid var(--line);
}

.module-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
}

.module-grid article {
  padding: 8px 36px 12px;
  border-left: 1px solid var(--line);
}

.module-grid article:first-child {
  padding-left: 0;
  border-left: 0;
}

.module-grid svg,
.detail-grid svg {
  display: block;
  width: 28px;
  height: 28px;
  fill: none;
  stroke: var(--body);
  stroke-width: 1.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.module-grid svg {
  margin-top: 44px;
}

.module-grid h3 {
  margin: 24px 0 12px;
  font-size: 30px;
  letter-spacing: -0.02em;
}

.module-grid p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.8;
}

.module-grid .ticks {
  font-size: 14px;
}

/* Copy beside a phone; .flip puts the phone first. */
.showcase {
  position: relative;
  width: var(--page);
  margin: 0 auto;
  padding: 120px 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
  border-top: 1px solid var(--line);
}

.showcase::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: 10%;
  right: 0;
  width: 60%;
  height: 80%;
  background: radial-gradient(closest-side, rgba(var(--spot), 0.07), transparent);
  pointer-events: none;
}

.showcase.flip::before {
  right: auto;
  left: 0;
}

.showcase.flip .device {
  order: -1;
}

.showcase-copy > p {
  margin: 26px 0 0;
  color: var(--body);
  font-size: 17px;
  line-height: 1.85;
}

.showcase-copy .note {
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.facts {
  margin: 32px 0 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.facts div {
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.facts dt {
  color: var(--faint);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}

.facts dd {
  margin: 8px 0 0;
  color: var(--body);
  font-size: 15px;
}

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

.detail-grid > div {
  padding: 30px 28px 32px;
  border: 1px solid var(--line);
  border-top-color: var(--rim);
  border-radius: 26px;
  background: var(--surface);
  transition: background-color 0.4s var(--ease), border-color 0.4s var(--ease);
}

.detail-grid > div:hover {
  background: var(--surface-strong);
  border-color: var(--line-strong);
}

.detail-grid h3 {
  margin: 26px 0 8px;
  font-size: 21px;
  letter-spacing: -0.01em;
}

.detail-grid p {
  margin: 0;
  color: var(--muted);
  font-size: 14.5px;
  line-height: 1.7;
}

.principle {
  position: relative;
  padding: 130px 24px;
  text-align: center;
  background: radial-gradient(60% 80% at 50% 0%, rgba(var(--spot), 0.08), transparent);
}

.principle p,
.principle strong {
  display: block;
  margin: 0;
  font-size: clamp(28px, 4.4vw, 56px);
  font-weight: 300;
  line-height: 1.35;
  letter-spacing: -0.03em;
}

.principle p {
  color: var(--faint);
}

.panel {
  width: var(--page);
  margin: 0 auto;
  padding: 52px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: end;
  border: 1px solid var(--line);
  border-top-color: var(--rim);
  border-radius: 34px;
  background: var(--surface);
}

.panel h2 {
  font-size: clamp(30px, 3.2vw, 40px);
}

.panel .ticks {
  margin-top: 0;
}

.text-link {
  display: inline-block;
  margin-top: 26px;
  color: var(--text);
  font-size: 14px;
  letter-spacing: 0.04em;
  border-bottom: 1px solid var(--line-strong);
  padding-bottom: 3px;
  transition: border-color 0.3s var(--ease);
}

.text-link:hover {
  border-color: var(--text);
}

.download {
  position: relative;
  margin-top: 120px;
  padding: 130px 24px 140px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  overflow: hidden;
  background:
    linear-gradient(180deg, var(--bg), rgba(13, 13, 16, 0.7) 30%, rgba(13, 13, 16, 0.7) 70%, var(--bg)),
    var(--bg) url("/scenes/hero.webp") center 30% / 1600px auto no-repeat;
}

.mark.large {
  width: 96px;
  height: 96px;
  margin: 0 0 30px;
}

.download p {
  max-width: 520px;
  margin: 22px 0 34px;
  color: var(--body);
  font-size: 17px;
  line-height: 1.8;
}

.download .fine {
  margin: 18px 0 0;
  color: var(--faint);
  font-size: 12px;
  letter-spacing: 0.12em;
}

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

.eco-card {
  display: flex;
  flex-direction: column;
  min-height: 260px;
  padding: 30px 30px 28px;
  border: 1px solid var(--line);
  border-top-color: var(--rim);
  border-radius: 26px;
  background: var(--surface);
  transition: background-color 0.4s var(--ease), border-color 0.4s var(--ease), transform 0.4s var(--ease);
}

a.eco-card:hover {
  background: var(--surface-strong);
  border-color: var(--line-strong);
  transform: translateY(-3px);
}

.eco-card h3 {
  margin: 36px 0 10px;
  font-size: 24px;
  letter-spacing: -0.02em;
}

.eco-card p {
  margin: 0;
  color: var(--muted);
  font-size: 14.5px;
  line-height: 1.7;
}

.eco-card .go {
  margin-top: auto;
  padding-top: 26px;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.2em;
}

.eco-card .go.here {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
}

.eco-card .go.here::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 10px var(--accent-glow);
}

.eco-card.current {
  background: transparent;
  border-style: dashed;
}

/* ---------- Footer ---------- */

.site-footer {
  width: var(--page);
  margin: 0 auto;
  padding: 30px 0 44px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-top: 1px solid var(--line);
  color: var(--faint);
  font-size: 12px;
  letter-spacing: 0.08em;
}

.foot-brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
}

.site-footer a {
  color: var(--muted);
  transition: color 0.3s var(--ease);
}

.site-footer a:hover {
  color: var(--text);
}

/* ---------- Long-form pages (privacy, 404) ---------- */

.doc {
  width: min(720px, calc(100% - 48px));
  margin: 0 auto;
  padding: 48px 0 80px;
  color: var(--body);
  line-height: 1.75;
}

.doc h1 {
  font-size: clamp(36px, 7vw, 56px);
  margin: 12px 0 4px;
}

.doc h2 {
  color: var(--text);
  font-size: 18px;
  font-weight: 500;
  letter-spacing: 0;
  line-height: 1.4;
  margin: 36px 0 8px;
}

.doc a {
  color: var(--text);
  border-bottom: 1px solid var(--line-strong);
}

.doc a:hover {
  border-color: var(--text);
}

.doc hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 64px 0 48px;
}

.doc-date {
  color: var(--muted);
  font-size: 13px;
}

.not-found {
  min-height: calc(100vh - 200px);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* ---------- Motion ---------- */

.can-reveal .reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 1s var(--ease), transform 1s var(--ease);
}

.can-reveal .reveal.shown {
  opacity: 1;
  transform: none;
}

@keyframes rise {
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes letter {
  to {
    opacity: 1;
  }
}

@keyframes stage-in {
  to {
    opacity: 1;
  }
}

/* The far world swells so slowly that it reads as air moving rather than motion. */
@keyframes drift {
  to {
    transform: scale(1.035);
  }
}

@keyframes pulse {
  50% {
    box-shadow: 0 0 4px rgba(255, 107, 0, 0.2);
    opacity: 0.6;
  }
}

@keyframes caret {
  50% {
    opacity: 0;
  }
}

/* ---------- Responsive ---------- */

@media (max-width: 1080px) {
  .nav {
    display: none;
  }

  .module-grid article {
    padding: 8px 24px 12px;
  }

  .showcase {
    gap: 48px;
  }
}

@media (max-width: 900px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 64px;
    min-height: auto;
    padding-top: 130px;
  }

  /* Stacked layout: the moon moves to the top corner and the copy gets a dark bed. */
  .stage {
    background:
      linear-gradient(180deg, rgba(13, 13, 16, 0) 0, rgba(13, 13, 16, 0.55) 110px, rgba(13, 13, 16, 0.9) 230px, var(--bg) 440px),
      var(--bg) url("/scenes/hero.webp") right -213px top -76px / 760px auto no-repeat;
    transform-origin: 84% 6%;
  }

  .module-grid,
  .detail-grid,
  .eco-grid {
    grid-template-columns: 1fr;
  }

  .module-grid article,
  .module-grid article:first-child {
    padding: 36px 0;
    border-left: 0;
    border-top: 1px solid var(--line);
  }

  .module-grid article:first-child {
    border-top: 0;
    padding-top: 0;
  }

  .module-grid svg {
    margin-top: 28px;
  }

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

  .showcase {
    grid-template-columns: 1fr;
    gap: 64px;
  }

  .showcase.flip .device {
    order: 0;
  }

  .panel {
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 36px;
  }

  .eco-card {
    min-height: 0;
  }

  .modules,
  .details,
  .ecosystem,
  .showcase {
    padding: 88px 0;
  }

  .section-head {
    margin-bottom: 40px;
  }
}

@media (max-width: 560px) {
  :root {
    --page: calc(100% - 32px);
  }

  .site-header {
    height: 72px;
  }

  .hero {
    margin-top: -72px;
    padding: 112px 16px 72px;
  }

  h1 {
    font-size: 40px;
  }

  html[lang^="zh"] h1 {
    font-size: 34px;
  }

  .lede,
  .showcase-copy > p,
  .section-lede,
  .download p {
    font-size: 16px;
  }

  .brand {
    gap: 12px;
    letter-spacing: 0.24em;
  }

  .header-actions .pill {
    padding: 0 16px;
    letter-spacing: 0.12em;
  }

  .phone {
    width: 312px;
  }

  .screen {
    height: 640px;
    padding: 0 16px 12px;
  }

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

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

  .panel {
    padding: 28px 24px;
  }

  .principle {
    padding: 90px 20px;
  }

  .download {
    margin-top: 72px;
    padding: 96px 16px 104px;
  }

  .site-footer {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 360px) {
  .wordmark {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .stage,
  .wordmark b,
  .hero-copy > *,
  .hero .device,
  .dot,
  .capture-text::after {
    animation: none;
    opacity: 1;
    transform: none;
  }
}

/* When the user asks for less transparency, glass falls back to solid, as in the app. */
@media (prefers-reduced-transparency: reduce) {
  .capture,
  .stock,
  .detail-grid > div,
  .eco-card,
  .panel {
    background: var(--surface-solid);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
}
