/* 小渐变 / Gradient — site styles (2026-11 redesign).
   A calm paper surface; the four wallpapers on the landing page carry all the
   color. One accent, for links only. No backdrop, no blur, no cards. */

:root {
  --paper: #F6F7F8;
  --ink: #0C1013;
  --muted: #56626B;          /* 5.8:1 on paper */
  --line: rgba(12, 16, 19, 0.08);
  --accent: #0E6683;         /* 6.0:1 on paper, 5.5:1 on the tinted block */
  --tint: color-mix(in srgb, var(--accent) 7%, var(--paper));
  --tile-shadow: 0 18px 40px -18px rgba(0, 0, 0, 0.35);
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #0E1113;
    --ink: #EEF1F3;
    --muted: #9AA6AF;        /* 7.6:1 on paper */
    --line: rgba(238, 241, 243, 0.10);
    --accent: #5FC3E4;       /* 9.4:1 on paper */
  }
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 17px/1.6 -apple-system, "SF Pro Text", "PingFang SC", "Hiragino Sans",
        "Segoe UI", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

.wrap {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 clamp(20px, 5vw, 48px);
}

a { color: var(--accent); text-decoration: none; }
a:hover, a:focus-visible { text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
/* Links inside running text keep an underline, so they do not rely on color alone. */
.doc p a { text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }

/* ---------- brand line ---------- */

.brand {
  display: flex;
  align-items: center;
  height: 56px;
}
.brand a {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-weight: 600;
  font-size: 1rem;
}
.brand a:hover { text-decoration: none; }
.brand img { display: block; width: 28px; height: 28px; border-radius: 22%; }

/* ---------- landing ---------- */

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 48px;
  margin-top: clamp(32px, 6vw, 72px);
}

h1 {
  margin: 0 0 20px;
  font-size: clamp(2.5rem, 5.2vw, 4rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.08;
  text-wrap: balance;
}

/* The text column is only 5/12 wide: cap the headline by the column width so
   it keeps two or three whole lines (en: "Turn one photo / into a gradient /
   wallpaper."; zh: each 8-character line whole; ja: whole phrases) instead of
   five ragged ones or one character alone on a line. The clamp stays the
   upper bound. */
.hero-text { container-type: inline-size; }
.hero h1 { font-size: min(clamp(2.5rem, 5.2vw, 4rem), 11.5cqi); }
html[lang^="zh"] .hero h1 { font-size: min(clamp(2.5rem, 5.2vw, 4rem), 12cqi); }
html[lang="ja"] .hero h1 { font-size: min(clamp(2.5rem, 5.2vw, 4rem), 13cqi); word-break: auto-phrase; }

.sub {
  margin: 0;
  max-width: 30em;
  font-size: 1.1875rem;
  line-height: 1.55;
  color: var(--muted);
  text-wrap: pretty;
}

/* Store badges: same height, App Store first; ≥ 12 px clear space all round. */
.stores {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin: 32px 0 0;
}
.store { display: block; line-height: 0; }
.store:hover { text-decoration: none; }
.store img { display: block; height: 48px; width: auto; }

.platforms {
  margin: 16px 0 0;
  font-size: 0.9375rem;
  color: var(--muted);
}

/* The four styles as finished wallpapers. */
.walls {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  align-items: start;
}
/* All four tiles top-aligned in one even row, names on one baseline: the
   planned stagger was removed as the "one decoration" (it read as messy). */

.wallpaper {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 440 / 956;
  /* ≈ 9 % of the width on both axes (956/440 → 4.14 % of the height). */
  border-radius: 9% / 4.142%;
  overflow: hidden;
  box-shadow: var(--tile-shadow);
}

.wall-name {
  display: block;
  margin-top: 12px;
  font-size: 0.8125rem;
  line-height: 1.3;
  color: var(--muted);
}

.points {
  list-style: none;
  margin: 64px 0 0;
  padding: 0;
  display: grid;
  gap: 28px;
}
.points h3 {
  margin: 0 0 6px;
  font-size: 1.125rem;
  font-weight: 650;
  line-height: 1.35;
}
.points p { margin: 0; color: var(--muted); text-wrap: pretty; }

/* ---------- support & privacy ---------- */

.doc {
  max-width: 680px;
  margin-top: clamp(32px, 6vw, 64px);
}

.doc h1 {
  font-size: clamp(2rem, 4vw, 2.5rem);
  margin-bottom: 12px;
}

.meta {
  margin: 0 0 16px;
  font-size: 0.875rem;
  color: var(--muted);
}

.lede {
  margin: 0 0 28px;
  text-wrap: pretty;
  font-size: 1.1875rem;
  line-height: 1.55;
  color: var(--muted);
}

.doc h2 {
  margin: 36px 0 8px;
  font-size: 1.125rem;
  font-weight: 650;
  line-height: 1.4;
}

.doc p { margin: 0 0 12px; text-wrap: pretty; }

.contact {
  padding: 18px 20px;
  border-radius: 14px;
  background: var(--tint);
  overflow-wrap: anywhere;
}
.doc p.contact { margin-bottom: 0; }

.doc h2 + .faq { margin-top: 16px; }
.faq .qa + .qa { margin-top: 28px; }
.faq h3 {
  margin: 0 0 6px;
  font-size: 1.0625rem;
  font-weight: 650;
  line-height: 1.4;
}
.faq p { margin: 0; }
.faq p + p { margin-top: 8px; }

.doc p.note {
  margin: 40px 0 0;
  font-size: 0.875rem;
  color: var(--muted);
}

/* ---------- footer ---------- */

footer {
  margin-top: 96px;
  padding: 24px 0 40px;
  border-top: 1px solid var(--line);
  font-size: 0.9375rem;
}

.foot-row {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

footer nav a[aria-current="page"] { color: var(--ink); text-decoration: none; cursor: default; }
footer .sep { color: var(--muted); }

.langs {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 18px;
}
.langs a { color: var(--muted); }
.langs a[aria-current="true"] { color: var(--ink); font-weight: 650; }

.fine {
  margin: 16px 0 0;
  font-size: 0.8125rem;
  color: var(--muted);
}

/* ---------- breakpoints ---------- */

@media (max-width: 639px) {
  .walls { gap: 8px; }
  .wall-name { margin-top: 8px; font-size: 0.75rem; }
}

@media (min-width: 640px) {
  .foot-row { flex-direction: row; justify-content: space-between; align-items: baseline; gap: 24px; }
}

@media (min-width: 760px) {
  .points { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px; margin-top: 96px; }
}

@media (min-width: 960px) {
  /* The art gets about two thirds, so each tile is ~150 px wide at 1440 px
     (1024 px of content); the text column is centered against the row. */
  .hero {
    grid-template-columns: minmax(0, 34fr) minmax(0, 66fr);
    gap: 40px;
    align-items: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}
