:root {
  --bg: #fffbf6;
  --bg-alt: #fff5f8;
  --panel: #fff;
  --ink: #2b2118;
  --ink-soft: rgba(43, 33, 24, 0.52);
  --accent: #ff9db7;
  --accent-deep: #f06d94;
  --border: rgba(43, 33, 24, 0.08);
  --device-bg: rgba(255, 255, 255, 0.92);
  --device-border: rgba(43, 33, 24, 0.1);
  --device-shadow: 0 6px 28px rgba(43, 33, 24, 0.07);
  --shot-w-sm: 118px;
  --shot-w-md: 142px;
  --shot-w-lg: 168px;
  --shot-w-hero: 186px;
  --shot-ratio: 9 / 19.5;
  --font: -apple-system, BlinkMacSystemFont, "PingFang SC", sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, monospace;
  --hero-title: clamp(2rem, 5vw, 3.25rem);
  --section-title: clamp(1.5rem, 3vw, 2.25rem);
  --radius-device: 18px;
  --sticky-h: 64px;
  --content-w: 1080px;
  --header-h: 56px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 15px;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
}

/* —— Header —— */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 251, 246, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.site-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-h);
  max-width: var(--content-w);
  margin: 0 auto;
  padding: 0 clamp(16px, 4vw, 32px);
}

.site-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: -0.02em;
}

.site-brand img {
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(43, 33, 24, 0.1);
}

.site-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 18px;
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: none;
  color: #fff;
  background: var(--accent-deep);
  border-radius: 980px;
  transition: transform 0.15s, box-shadow 0.15s, background 0.15s;
  box-shadow: 0 4px 14px rgba(240, 109, 148, 0.35);
}

.site-cta--store {
  display: none;
}

@media (max-width: 720px) {
  .site-cta--anchor {
    display: none !important;
  }

  .site-cta--store {
    display: inline-flex;
  }
}

.site-cta:hover {
  background: #e85a82;
  transform: translateY(-1px);
}

.site-cta--sm {
  padding: 6px 14px;
  font-size: 0.82rem;
}

.site-cta--outline {
  color: var(--ink);
  background: var(--panel);
  border: 1px solid var(--border);
  box-shadow: none;
}

.site-cta--outline:hover {
  background: var(--bg-alt);
  transform: translateY(-1px);
}

/* —— Hero · 双栏 + 启动图 —— */
.hero {
  position: relative;
  padding: clamp(28px, 4vh, 48px) clamp(16px, 4vw, 32px) clamp(24px, 4vh, 40px);
  background: var(--bg);
  overflow: hidden;
}

.hero-inner {
  position: relative;
  max-width: var(--content-w);
  margin: 0 auto;
}

.hero-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.9fr);
  gap: clamp(24px, 4vw, 40px);
  align-items: center;
}

.hero-copy {
  padding: clamp(24px, 3vw, 32px);
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: 0 8px 32px rgba(43, 33, 24, 0.05);
}

.hero-tag {
  margin: 0 0 12px;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent-deep);
}

.hero-title {
  margin: 0 0 16px;
  font-size: var(--hero-title);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.03em;
  color: var(--ink);
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.8);
}

.hero-sub {
  margin: 0 0 24px;
  font-size: clamp(0.95rem, 2vw, 1.05rem);
  line-height: 1.65;
  color: rgba(43, 33, 24, 0.72);
}

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

.hero-showcase {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  max-width: 240px;
  margin: 0 auto;
  justify-self: center;
}

.hero-showcase--wide {
  max-width: none;
  justify-self: stretch;
}

.hero-showcase--wide img {
  width: 100%;
  max-width: 520px;
  height: auto;
}

.hero-phone {
  margin: 0 auto;
  width: 100%;
  display: flex;
  justify-content: center;
}

@media (min-width: 1100px) {
  .hero-showcase:not(.hero-showcase--wide) {
    max-width: 252px;
  }

  .hero-showcase--wide img {
    max-width: 560px;
  }
}

/* —— Bento trust strip —— */
.bento-section {
  padding: 0 clamp(16px, 4vw, 32px) clamp(32px, 5vh, 48px);
}

.bento-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  max-width: var(--content-w);
  margin: 0 auto;
}

.bento-card {
  padding: 24px 20px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 16px;
  text-align: center;
  transition: transform 0.2s, box-shadow 0.2s;
}

.bento-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(43, 33, 24, 0.08);
}

.bento-icon {
  font-size: 1.75rem;
  margin-bottom: 10px;
  line-height: 1;
}

.bento-card h3 {
  margin: 0 0 6px;
  font-size: 0.95rem;
  font-weight: 700;
}

.bento-card p {
  margin: 0;
  font-size: 0.82rem;
  line-height: 1.5;
  color: var(--ink-soft);
}

/* —— Feature sections —— */
.feature-section {
  padding: clamp(36px, 6vh, 56px) clamp(16px, 4vw, 32px);
}

.feature-section--alt {
  background: var(--bg-alt);
}

.feature-section--text-only .feature-split {
  grid-template-columns: 1fr;
  max-width: 640px;
  text-align: center;
}

.feature-section--text-only .feature-copy {
  margin: 0 auto;
}

.feature-section--text-only .feature-points li {
  text-align: left;
}

.feature-split {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.72fr);
  gap: clamp(20px, 3vw, 36px);
  align-items: center;
  max-width: var(--content-w);
  margin: 0 auto;
}

.feature-split--reverse .feature-copy {
  order: 2;
}

.feature-split--reverse .feature-visual {
  order: 1;
}

.feature-eyebrow {
  display: inline-block;
  margin: 0 0 10px;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-deep);
}

.feature-copy h2 {
  margin: 0 0 16px;
  font-size: var(--section-title);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

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

.feature-points li {
  position: relative;
  padding-left: 16px;
  margin-bottom: 12px;
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--ink-soft);
}

.feature-points li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
}

.feature-points strong {
  display: block;
  color: var(--ink);
  font-weight: 600;
  margin-bottom: 2px;
}

.feature-visual {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  min-width: 0;
}

.feature-split--reverse .feature-visual {
  justify-content: flex-start;
}

.feature-visual--wide {
  justify-content: flex-start;
}

.feature-visual--wide img {
  width: 100%;
  max-width: 560px;
  height: auto;
}

.feature-split--reverse .feature-visual--wide {
  justify-content: flex-start;
}

/* —— Device frames · 浅色轮廓 + 固定比例裁切 —— */
.device-frame {
  position: relative;
  flex-shrink: 0;
  margin: 0;
  padding: 3px;
  background: var(--device-bg);
  border: 1px solid var(--device-border);
  border-radius: calc(var(--radius-device) + 4px);
  box-shadow: var(--device-shadow);
  overflow: hidden;
  aspect-ratio: var(--shot-ratio);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.device-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.65);
  pointer-events: none;
}

.device-frame:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 32px rgba(43, 33, 24, 0.1);
}

.device-frame--sm {
  width: var(--shot-w-sm);
}

.device-frame--md {
  width: var(--shot-w-md);
}

.device-frame--lg {
  width: var(--shot-w-lg);
}

.device-frame--hero {
  width: var(--shot-w-hero);
  max-width: 240px;
  margin-inline: auto;
  overflow: hidden;
  aspect-ratio: auto;
}

.device-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  border-radius: var(--radius-device);
}

.device-frame--hero img {
  display: block;
  height: auto;
  aspect-ratio: var(--shot-ratio);
  max-height: 520px;
}

.device-duo {
  display: flex;
  justify-content: flex-end;
  align-items: flex-end;
  max-width: calc(var(--shot-w-md) + var(--shot-w-sm) - 28px);
}

.feature-split--reverse .device-duo {
  justify-content: flex-start;
}

.device-duo .device-frame--sm {
  z-index: 0;
  margin-left: -28px;
  transform: translateY(10px) scale(0.94);
  opacity: 0.88;
}

.device-duo .device-frame--md {
  z-index: 1;
}

.device-single {
  display: flex;
  justify-content: flex-end;
}

.feature-split--reverse .device-single {
  justify-content: flex-start;
}

/* —— How it works —— */
.steps-section {
  padding: clamp(36px, 6vh, 56px) clamp(16px, 4vw, 32px);
  background: var(--bg);
}

.steps-inner {
  max-width: var(--content-w);
  margin: 0 auto;
  text-align: center;
}

.steps-inner h2 {
  margin: 0 0 40px;
  font-size: var(--section-title);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  text-align: left;
}

.step-card {
  padding: 28px 24px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 16px;
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  margin-bottom: 14px;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--accent-deep);
  background: var(--bg-alt);
  border-radius: 50%;
}

.step-card h3 {
  margin: 0 0 8px;
  font-size: 1rem;
  font-weight: 700;
}

.step-card p {
  margin: 0;
  font-size: 0.88rem;
  line-height: 1.55;
  color: var(--ink-soft);
}

/* —— Download band —— */
.download-band {
  padding: clamp(56px, 10vh, 80px) clamp(16px, 4vw, 32px);
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
}

.download-band-inner {
  max-width: 640px;
  margin: 0 auto;
  text-align: center;
}

.download-band h2 {
  margin: 0 0 8px;
  font-size: clamp(1.35rem, 3vw, 1.75rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.download-band-lead {
  margin: 0 0 32px;
  font-size: 0.92rem;
  color: var(--ink-soft);
}

.download-options {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
}

.download-option {
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* 二维码仅桌面端展示（手机直接用 App Store） */
.download-option--qr,
.download-divider--qr {
  display: none;
}

@media (min-width: 721px) {
  .download-option--qr {
    display: flex;
  }

  .download-divider--qr {
    display: block;
    width: 1px;
    align-self: stretch;
    min-height: 120px;
    background: var(--border);
  }
}

.qr-wrap {
  padding: 8px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: 0 4px 16px rgba(43, 33, 24, 0.06);
}

.qr-wrap img {
  width: 140px;
  height: 140px;
}

.download-label {
  margin: 10px 0 2px;
  font-size: 0.88rem;
  font-weight: 600;
}

.download-hint {
  margin: 0;
  font-size: 0.78rem;
  color: var(--ink-soft);
}

.download-divider {
  width: 1px;
  align-self: stretch;
  min-height: 120px;
  background: var(--border);
}

.mac-download-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 156px;
  height: 156px;
  padding: 16px;
  font-size: 0.82rem;
  font-weight: 600;
  text-decoration: none;
  color: var(--ink);
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: 0 4px 16px rgba(43, 33, 24, 0.06);
  transition: transform 0.15s, box-shadow 0.15s;
}

.mac-download-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(43, 33, 24, 0.1);
}

.mac-download-icon {
  width: 36px;
  height: 36px;
}

.app-store-link {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 156px;
  height: 156px;
  padding: 16px;
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: none;
  color: var(--ink);
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: 0 4px 16px rgba(43, 33, 24, 0.06);
  transition: transform 0.15s, box-shadow 0.15s;
}

.app-store-link:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(43, 33, 24, 0.1);
}

.bundle-id {
  margin: 24px 0 0;
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--ink-soft);
}

/* —— Footer —— */
.site-footer {
  padding: 32px clamp(16px, 4vw, 32px) calc(32px + var(--sticky-h));
  text-align: center;
  border-top: 1px solid var(--border);
}

.site-footer-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 16px;
  margin-bottom: 12px;
}

.site-footer-nav a {
  font-size: 0.82rem;
  color: var(--ink-soft);
  text-decoration: none;
  transition: color 0.15s;
}

.site-footer-nav a:hover {
  color: var(--accent-deep);
}

.site-footer-note {
  margin: 0;
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--ink-soft);
}

/* —— Sticky mobile download bar —— */
.sticky-download {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 200;
  align-items: center;
  justify-content: space-between;
  height: var(--sticky-h);
  padding: 0 16px;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid var(--border);
  box-shadow: 0 -4px 20px rgba(43, 33, 24, 0.06);
}

.sticky-download-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 0.88rem;
}

.sticky-download-brand img {
  border-radius: 6px;
}

/* —— Scroll reveal —— */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

/* —— Legal pages —— */
.legal-body {
  overflow: auto;
  background: var(--bg);
}

.legal-body .site-footer {
  padding-bottom: 32px;
}

.legal-shell {
  max-width: 720px;
  margin: 0 auto;
  padding: 32px 24px 48px;
}

.legal-header {
  text-align: center;
  margin-bottom: 36px;
}

.legal-icon {
  border-radius: 12px;
  margin: 0 auto 12px;
  box-shadow: 0 4px 16px rgba(43, 33, 24, 0.1);
}

.legal-header h1 {
  margin: 0 0 8px;
  font-size: 1.75rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.legal-meta {
  margin: 0;
  font-size: 0.82rem;
  color: var(--ink-soft);
}

.legal-content h2 {
  margin: 32px 0 12px;
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.legal-content h3 {
  margin: 20px 0 8px;
  font-size: 0.95rem;
  font-weight: 600;
}

.legal-content p,
.legal-content li {
  font-size: 0.92rem;
  line-height: 1.65;
  color: var(--ink);
}

.legal-content p {
  margin: 0 0 12px;
}

.legal-content ul {
  margin: 0 0 12px;
  padding-left: 1.4em;
}

.legal-content li {
  margin-bottom: 6px;
}

.legal-content a {
  color: var(--accent-deep);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.legal-content code {
  font-family: var(--mono);
  font-size: 0.85em;
  padding: 1px 5px;
  background: rgba(43, 33, 24, 0.06);
  border-radius: 4px;
}

.legal-table-wrap {
  overflow-x: auto;
  margin: 12px 0 16px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--panel);
}

.legal-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.84rem;
}

.legal-table th,
.legal-table td {
  padding: 10px 14px;
  text-align: left;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

.legal-table th {
  font-weight: 600;
  background: rgba(43, 33, 24, 0.03);
}

.legal-table tr:last-child td {
  border-bottom: none;
}

.legal-footer-note {
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  font-size: 0.82rem;
  color: var(--ink-soft);
}

/* —— Responsive —— */
@media (max-width: 900px) {
  .hero-layout {
    grid-template-columns: 1fr;
    gap: 24px;
    justify-items: stretch;
  }

  .hero-copy {
    text-align: center;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-showcase {
    width: 100%;
    max-width: none;
    padding: 0 8px;
  }

  .hero-showcase--wide img {
    max-width: min(520px, 92vw);
    margin-inline: auto;
  }

  .device-frame--hero {
    max-width: min(210px, 56vw);
    margin-inline: auto;
  }

  .device-frame--hero img {
    max-height: min(380px, 46vh);
  }

  .feature-split {
    grid-template-columns: 1fr;
  }

  .feature-points li {
    text-align: left;
  }

  .feature-visual,
  .feature-split--reverse .feature-visual,
  .feature-visual--wide,
  .feature-split--reverse .feature-visual--wide,
  .device-duo,
  .feature-split--reverse .device-duo,
  .device-single,
  .feature-split--reverse .device-single {
    justify-content: center;
  }

  .feature-visual--wide img {
    max-width: min(520px, 92vw);
  }

  .device-duo {
    max-width: calc(var(--shot-w-md) + var(--shot-w-sm) - 20px);
  }

  .feature-split--reverse .feature-copy,
  .feature-split--reverse .feature-visual {
    order: unset;
  }

  .feature-copy {
    text-align: center;
  }

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

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

  .download-divider {
    display: none;
  }
}

@media (min-width: 901px) {
  :root {
    --shot-w-sm: 128px;
    --shot-w-md: 154px;
    --shot-w-lg: 176px;
    --shot-w-hero: 196px;
  }
}

@media (max-width: 720px) {
  :root {
    --shot-w-sm: min(108px, 28vw);
    --shot-w-md: min(132px, 34vw);
    --shot-w-lg: min(148px, 38vw);
    --shot-w-hero: min(156px, 40vw);
  }

  .sticky-download {
    display: flex;
  }

  /* 底部已有「立即下载」，隐藏顶栏重复按钮 */
  .site-header .site-cta--store {
    display: none !important;
  }

  .hero {
    padding-bottom: 12px;
  }

  .hero-copy {
    padding: 20px 18px;
  }

  .hero-title {
    font-size: clamp(1.65rem, 6.5vw, 2rem);
  }

  .hero-sub {
    margin-bottom: 20px;
    font-size: 0.92rem;
  }

  .device-frame--hero {
    max-width: min(200px, 52vw);
  }

  .device-frame--hero img {
    max-height: min(340px, 40vh);
  }

  body.has-sticky-bar {
    padding-bottom: var(--sticky-h);
  }

  .site-footer {
    padding-bottom: calc(32px + var(--sticky-h));
  }

  .device-duo {
    flex-direction: row;
    align-items: flex-end;
  }

  .device-duo .device-frame--sm {
    margin-left: -20px;
    transform: translateY(8px) scale(0.92);
  }

  .qr-wrap img {
    width: 120px;
    height: 120px;
  }

  .mac-download-btn,
  .app-store-link {
    width: 132px;
    height: 132px;
  }
}

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

  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
