/* xIM official site (docs/16). Colours mirror skins/skins.txt, skin "blush" (浅红, the default skin; docs/09 2.1); no external fonts. */

:root {
  color-scheme: light dark;
  /* skins/skins.txt blush, light */
  --bg-page: #FFF7F7;
  --bg-card: #FFFFFF;
  --bg-pressed: #F7E8EB;
  --bg-input: #F8ECEE;
  --text-primary: #3F2D32;
  --text-secondary: #806A70;
  --text-link: #B94E5D;
  --accent: #B94E5D;
  --accent-pressed: #9C3F4D;
  --accent-soft: #FBE4E7;
  --on-accent: #FFFFFF;
  --tab-normal: #8F7B80;
  --switch-off: #EADADD;
  --danger: #D0341F;
  --online: #25A66B;
  --line: #F0DFE2;
  --chevron: #CDB9BE;
  --bubble-out: #F8DADF;
  --cs-header-top: #B94E5D;
  --cs-header-bottom: #CC6B79;
  --entry-green: #3A9A72;
  --entry-red: #C9634F;
  --entry-blue: #4A7FC1;
  --entry-yellow: #E0A93B;
  --wallet-card: #B94E5D;
  --notice-warn-bg: #FFF4DE;
  --notice-warn-text: #8A5410;
  --rp-bubble: #C8553F;
  --rp-gold: #E8C77A;

  /* site-only, derived from the tokens above for WCAG AA on the page background */
  --muted: #6E585E;
  --btn-bg: var(--accent);
  --btn-bg-hover: var(--accent-pressed);
  /* white band text: the gradient stays at or below the accent so it keeps 4.5:1 */
  --band-top: var(--accent-pressed);
  --band-bottom: var(--accent);
  --phone-frame: #2A1D21;
  --shadow-sm: 0 1px 2px rgba(63, 45, 50, .06), 0 2px 8px rgba(63, 45, 50, .05);
  --shadow-md: 0 2px 4px rgba(63, 45, 50, .05), 0 12px 32px rgba(63, 45, 50, .09);
  --shadow-phone: 0 28px 60px -18px rgba(74, 30, 40, .45), 0 10px 20px -10px rgba(74, 30, 40, .25);
  --decor-opacity: 1;
  --lattice-opacity: .5;

  --radius: 12px;
  --radius-lg: 20px;
  --wrap: 1180px;
  --gutter: 16px;
  --font: system-ui, -apple-system, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC",
    "Noto Sans SC", "Source Han Sans SC", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SFMono-Regular", "Cascadia Mono", Consolas, "Liberation Mono", Menlo, monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
    /* skins/skins.txt blush, dark */
    --bg-page: #181012;
    --bg-card: #221719;
    --bg-pressed: #2E2023;
    --bg-input: #2B1E21;
    --text-primary: #F2E6E8;
    --text-secondary: #B39FA4;
    --text-link: #E8909C;
    --accent: #C45E6E;
    --accent-pressed: #A84B5A;
    --accent-soft: #3D2228;
    --on-accent: #FFFFFF;
    --tab-normal: #8E7A80;
    --switch-off: #45343A;
    --danger: #EF6A5A;
    --online: #3FBF83;
    --line: #36272B;
    --chevron: #6E5A60;
    --bubble-out: #4A2A32;
    --cs-header-top: #8E3A48;
    --cs-header-bottom: #A84B5A;
    --wallet-card: #7E3441;
    --notice-warn-bg: #3A2E1F;
    --notice-warn-text: #E8B67A;

    --muted: var(--text-secondary);
    /* white on the dark accent #C45E6E is below 4.5:1, so buttons use the darker accent.pressed */
    --btn-bg: #A84B5A;
    --btn-bg-hover: #8E3A48;
    --band-top: #8E3A48;
    --band-bottom: #A84B5A;
    --phone-frame: #000000;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3);
    --shadow-md: 0 2px 4px rgba(0, 0, 0, .25), 0 12px 32px rgba(0, 0, 0, .35);
    --shadow-phone: 0 28px 60px -18px rgba(0, 0, 0, .8), 0 0 0 1px rgba(255, 255, 255, .08);
    --decor-opacity: .55;
    --lattice-opacity: .35;
  }
}

/* ---- base ---- */

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

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

body {
  margin: 0;
  background: var(--bg-page);
  color: var(--text-primary);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* language: html[data-lang] picks one of the two spans {{t:..|..}} produced */
html[data-lang="zh"] body [lang="en"],
html[data-lang="en"] body [lang="zh-CN"] { display: none !important; }

img, svg { max-width: 100%; }
img { display: block; height: auto; }
h1, h2, h3, h4 { line-height: 1.25; margin: 0; letter-spacing: -.01em; }
p { margin: 0; }
a { color: var(--text-link); text-underline-offset: .18em; }
a:hover { text-decoration-thickness: 2px; }
button { font: inherit; color: inherit; }

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
  border-radius: 6px;
}

.i {
  width: 1.25em;
  height: 1.25em;
  flex: none;
  vertical-align: -.25em;
}

.wrap {
  width: 100%;
  max-width: calc(var(--wrap) + 2 * var(--gutter));
  margin: 0 auto;
  padding: 0 var(--gutter);
}

@media (min-width: 768px) {
  :root { --gutter: 32px; }
}

.skip {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 100;
  background: var(--btn-bg);
  color: #fff;
  padding: 10px 16px;
  border-radius: 10px;
  text-decoration: none;
}
.skip:focus { top: 12px; }

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* ---- buttons ---- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5em;
  min-height: 48px;
  padding: 0 22px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: background-color .15s, border-color .15s, transform .15s, box-shadow .15s;
}
.btn:active { transform: translateY(1px); }
.btn-primary {
  background: var(--btn-bg);
  color: #fff;
  box-shadow: 0 6px 16px -8px rgba(156, 63, 77, .6);
}
.btn-primary:hover { background: var(--btn-bg-hover); }
.btn-ghost {
  background: var(--bg-card);
  color: var(--text-primary);
  border-color: var(--line);
}
.btn-ghost:hover { border-color: var(--chevron); background: var(--bg-pressed); }
.btn-soon {
  background: var(--bg-input);
  color: var(--muted);
  border: 1px dashed var(--chevron);
  cursor: not-allowed;
  font-weight: 500;
}
.btn-sm { min-height: 40px; padding: 0 14px; font-size: 15px; border-radius: 10px; }

/* ---- header ---- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--bg-page) 86%, transparent);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid color-mix(in srgb, var(--line) 70%, transparent);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 64px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text-primary);
  text-decoration: none;
  font-weight: 700;
  font-size: 20px;
  letter-spacing: .02em;
  margin-right: auto;
}
.brand img { width: 38px; height: 38px; }
.nav {
  display: flex;
  align-items: center;
  gap: 4px;
}
.nav a {
  color: var(--text-primary);
  text-decoration: none;
  font-size: 15px;
  padding: 8px 12px;
  border-radius: 10px;
}
.nav a:hover { background: var(--bg-pressed); }
.nav a[aria-current="page"] { color: var(--accent); font-weight: 600; }
.nav .nav-dl { display: none; }
.lang-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 40px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--bg-card);
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
}
.lang-btn:hover { border-color: var(--chevron); }
.lang-btn .i { width: 18px; height: 18px; color: var(--accent); }

@media (max-width: 719px) {
  .nav a:not(.nav-dl) { display: none; }
  .nav .nav-dl {
    display: inline-flex;
    background: var(--btn-bg);
    color: #fff;
    font-weight: 600;
    padding: 8px 14px;
  }
  .nav .nav-dl:hover { background: var(--btn-bg-hover); }
  .brand { font-size: 18px; }
  .brand img { width: 34px; height: 34px; }
}

/* ---- hero ---- */

.hero {
  position: relative;
  overflow: hidden;
  padding: 40px 0 56px;
  isolation: isolate;
}
.hero::before {
  /* mountains (imgs/jade/decor/profile-mountains.svg) along the bottom */
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 70%;
  background: url("../img/decor/profile-mountains.svg") right bottom / auto 100% no-repeat;
  opacity: var(--decor-opacity);
  -webkit-mask-image: linear-gradient(to bottom, #000 50%, transparent 96%), linear-gradient(to right, transparent 30%, #000 70%);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(to bottom, #000 50%, transparent 96%), linear-gradient(to right, transparent 30%, #000 70%);
  mask-composite: intersect;
  z-index: -1;
}
.hero::after {
  /* window lattice in the top-right corner */
  content: "";
  position: absolute;
  top: -14px;
  right: -18px;
  width: 132px;
  height: 154px;
  background: url("../img/decor/window-lattice.svg") center / contain no-repeat;
  opacity: var(--lattice-opacity);
  z-index: -1;
}
.hero-grid {
  display: grid;
  gap: 40px;
  align-items: center;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--text-link);
  font-size: 14px;
  font-weight: 600;
}
.eyebrow .i { width: 16px; height: 16px; }
.hero h1 {
  margin-top: 18px;
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: clamp(44px, 9vw, 72px);
  font-weight: 800;
  letter-spacing: .04em;
}
.hero h1 img {
  width: clamp(64px, 12vw, 92px);
  height: auto;
  filter: drop-shadow(0 8px 16px rgba(182, 75, 64, .25));
}
.hero .tagline {
  margin-top: 10px;
  font-size: clamp(20px, 3.4vw, 28px);
  font-weight: 600;
  color: var(--text-primary);
}
.hero .lead {
  margin-top: 16px;
  max-width: 34em;
  font-size: 17px;
  color: var(--muted);
}
.hero-cta {
  margin-top: 28px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.hero-cta .btn { min-width: 156px; }
.hero-note {
  margin-top: 12px;
  font-size: 14px;
  color: var(--muted);
  min-height: 1.5em;
}
.trust {
  margin: 28px 0 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  font-size: 14px;
  color: var(--muted);
}
.trust li { display: inline-flex; align-items: center; gap: 6px; }
.trust .i { width: 18px; height: 18px; color: var(--online); }

/* three phones; --w is the front phone width */
.phones {
  --w: min(46vw, 268px);
  position: relative;
  display: grid;
  place-items: center;
  padding: 8px 0 20px;
}
.phones::before {
  content: "";
  position: absolute;
  width: calc(var(--w) * 1.9);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(closest-side, var(--accent-soft), transparent);
  z-index: -1;
}
.phones > .phone { grid-area: 1 / 1; }
.phones > .phone.side {
  --pw: calc(var(--w) * .84);
  opacity: .98;
}
.phones > .phone.left { transform: translateX(-56%) translateY(8%) rotate(-5deg); }
.phones > .phone.right { transform: translateX(56%) translateY(8%) rotate(5deg); }
.phones > .phone.front { z-index: 2; }

.phone {
  --pw: var(--w, 240px);
  width: var(--pw);
  padding: calc(var(--pw) * .032);
  border-radius: calc(var(--pw) * .15);
  background: var(--phone-frame);
  box-shadow: var(--shadow-phone);
  margin: 0;
}
.phone img {
  width: 100%;
  aspect-ratio: 1080 / 2400;
  object-fit: cover;
  border-radius: calc(var(--pw) * .12);
  background: var(--bg-page);
}

@media (min-width: 960px) {
  .hero { padding: 72px 0 96px; }
  .hero-grid { grid-template-columns: 1.05fr 1fr; gap: 24px; }
  .hero::after { width: 168px; height: 196px; top: -10px; right: 0; }
  .phones { --w: 262px; padding: 24px 0 32px; }
}

/* ---- sections ---- */

.section { padding: 64px 0; }
.section-head {
  max-width: 720px;
  margin: 0 auto 36px;
  text-align: center;
}
.section-head h2 {
  font-size: clamp(26px, 4.4vw, 36px);
  font-weight: 800;
}
.section-head p {
  margin-top: 10px;
  color: var(--muted);
  font-size: 17px;
}
.kicker {
  display: block;
  margin-bottom: 8px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--text-link);
}
@media (min-width: 960px) {
  .section { padding: 96px 0; }
  .section-head { margin-bottom: 48px; }
}

/* features */
.features {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.feature {
  display: grid;
  align-content: start;
  grid-template-columns: 48px 1fr;
  gap: 4px 16px;
  align-items: start;
  padding: 20px;
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: transform .2s, box-shadow .2s;
}
.feature:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.feature .ic {
  grid-row: span 2;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: var(--accent-soft);
  color: var(--accent);
}
.feature .ic .i { width: 26px; height: 26px; }
.feature h3 { font-size: 18px; font-weight: 700; padding-top: 2px; }
.feature p { color: var(--muted); font-size: 15px; }
@media (min-width: 600px) {
  .features { grid-template-columns: repeat(2, 1fr); gap: 16px; }
}
@media (min-width: 1024px) {
  .features { grid-template-columns: repeat(4, 1fr); gap: 20px; }
  .feature { grid-template-columns: 1fr; padding: 26px 24px; gap: 0; }
  .feature .ic { grid-row: auto; margin-bottom: 18px; }
  .feature h3 { margin-bottom: 8px; }
}

/* enterprise band */
.band {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  margin-top: 28px;
  padding: 32px 24px;
  border-radius: 24px;
  color: #fff;
  background: linear-gradient(135deg, var(--band-top), var(--band-bottom));
  display: grid;
  gap: 20px;
  align-items: center;
}
.band::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("../img/decor/profile-mountains.svg") right bottom / auto 120% no-repeat;
  opacity: .9;
  mix-blend-mode: screen;
  z-index: -1;
}
.band::after {
  content: "";
  position: absolute;
  right: 18px;
  top: 18px;
  width: 84px;
  height: 98px;
  background: url("../img/decor/window-lattice.svg") center / contain no-repeat;
  opacity: .45;
  filter: brightness(2.2);
  z-index: -1;
}
.band .ic {
  display: grid;
  place-items: center;
  width: 60px;
  height: 60px;
  border-radius: 18px;
  background: rgba(255, 255, 255, .14);
  border: 1px solid rgba(255, 255, 255, .22);
}
.band .ic .i { width: 32px; height: 32px; }
.band h3 { font-size: clamp(21px, 3vw, 26px); font-weight: 800; }
.band p { margin-top: 8px; color: rgba(255, 255, 255, .9); max-width: 46em; }
.band ul {
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.band li {
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .14);
  font-size: 14px;
}
@media (min-width: 768px) {
  .band { grid-template-columns: auto 1fr; padding: 40px 140px 40px 40px; gap: 28px; }
}

/* gallery: pure CSS horizontal scroll */
.gallery-sec { background: var(--bg-card); border-block: 1px solid var(--line); }
.gallery {
  --w: 210px;
  display: flex;
  gap: 28px;
  margin: 0;
  padding: 12px var(--gutter) 28px;
  list-style: none;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: var(--gutter);
  scrollbar-width: thin;
  scrollbar-color: var(--chevron) transparent;
}
.gallery li {
  flex: none;
  width: calc(var(--w) + 4px);
  scroll-snap-align: start;
  text-align: center;
}
.gallery figcaption { margin-top: 14px; font-weight: 600; }
.gallery figcaption small { display: block; font-weight: 400; color: var(--muted); font-size: 14px; }
.gallery figure { margin: 0; }
.gallery .phone { --pw: var(--w); box-shadow: 0 18px 40px -18px rgba(74, 30, 40, .45); }
.gallery-wrap { max-width: calc(var(--wrap) + 2 * var(--gutter)); margin: 0 auto; }
@media (min-width: 1240px) {
  .gallery { --w: 170px; justify-content: space-between; overflow-x: visible; }
}

/* ---- downloads ---- */

.download-sec { position: relative; }
.dl-grid {
  display: grid;
  gap: 16px;
  align-items: start;
}
@media (min-width: 680px) {
  .dl-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
  .dl-grid { grid-template-columns: repeat(3, 1fr); gap: 20px; }
}
.dl-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 22px;
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}
.dl-card.is-device {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent), var(--shadow-md);
}
.dl-head { display: flex; align-items: center; gap: 14px; }
.dl-icon {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 16px;
  background: var(--accent-soft);
  color: var(--accent);
  flex: none;
}
.dl-icon .i { width: 28px; height: 28px; }
.dl-title { flex: 1; min-width: 0; }
.dl-title h3 { font-size: 19px; font-weight: 700; }
.dl-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 2px 12px;
  margin-top: 2px;
  font-size: 14px;
  color: var(--muted);
}
.dl-rec {
  align-self: flex-start;
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--text-link);
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}
.dl-rec[hidden] { display: none; }
.dl-btn { width: 100%; }
.dl-card.soon .dl-icon { background: var(--bg-input); color: var(--tab-normal); }
.dl-card.soon .dl-title h3 { color: var(--muted); }

.stores-label { font-size: 13px; color: var(--muted); margin-bottom: 8px; }
.stores ul { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }
.store {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 12px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--bg-page);
  color: var(--text-primary);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}
.store:hover { border-color: var(--accent); color: var(--text-link); }

.hash {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 4px 10px;
  align-items: center;
  padding: 10px 12px;
  border-radius: var(--radius);
  background: var(--bg-input);
}
.hash-label { grid-column: 1 / -1; font-size: 12px; font-weight: 700; letter-spacing: .06em; color: var(--muted); }
.hash code {
  font-family: var(--mono);
  font-size: 12px;
  line-height: 1.5;
  word-break: break-all;
  color: var(--text-primary);
}
.copy {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 36px;
  padding: 0 10px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--bg-card);
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}
.copy:hover { border-color: var(--accent); color: var(--text-link); }
.copy .i { width: 16px; height: 16px; }
.copy.done { color: var(--online); border-color: var(--online); }
.copy [hidden] { display: none; }

.tips {
  border-top: 1px solid var(--line);
  padding-top: 12px;
  font-size: 14px;
}
.tips summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--text-link);
  list-style: none;
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 32px;
}
.tips summary::-webkit-details-marker { display: none; }
.tips summary::before {
  content: "";
  width: 8px;
  height: 8px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(-45deg);
  transition: transform .15s;
  margin-right: 4px;
}
.tips[open] summary::before { transform: rotate(45deg); }
.tips ol { margin: 8px 0 0; padding-left: 1.3em; color: var(--muted); }
.tips li + li { margin-top: 4px; }

.qr-card {
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 18px;
  align-items: center;
  padding: 22px;
  border-radius: var(--radius-lg);
  background: var(--accent-soft);
  border: 1px solid color-mix(in srgb, var(--accent) 22%, transparent);
  position: relative;
  overflow: hidden;
}
.qr-card .qr {
  width: 112px;
  height: 112px;
  border-radius: 10px;
  background: #fff;
  box-shadow: var(--shadow-sm);
}
.qr-card h3 { font-size: 18px; font-weight: 700; }
.qr-card p { margin-top: 4px; font-size: 14px; color: var(--muted); }
.qr-card .url { margin-top: 8px; font-family: var(--mono); font-size: 13px; word-break: break-all; color: var(--text-link); }

/* ---- page hero (download / support / legal) ---- */

.page-hero {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  padding: 44px 0 36px;
}
.page-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("../img/decor/profile-mountains.svg") right bottom / auto 150% no-repeat;
  opacity: var(--decor-opacity);
  -webkit-mask-image: linear-gradient(to bottom, #000 40%, transparent 98%), linear-gradient(to right, transparent 30%, #000 75%);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(to bottom, #000 40%, transparent 98%), linear-gradient(to right, transparent 30%, #000 75%);
  mask-composite: intersect;
  z-index: -1;
}
.page-hero h1 { font-size: clamp(30px, 5vw, 44px); font-weight: 800; }
.page-hero p { margin-top: 10px; color: var(--muted); font-size: 17px; max-width: 40em; }
@media (min-width: 960px) {
  .page-hero { padding: 72px 0 52px; }
}

/* install guide (download.html) */
.guide {
  display: grid;
  gap: 16px;
}
@media (min-width: 900px) {
  .guide { grid-template-columns: repeat(3, 1fr); gap: 20px; }
}
.guide-card {
  padding: 24px;
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
}
.guide-card h3 { display: flex; align-items: center; gap: 10px; font-size: 18px; }
.guide-card h3 .i { color: var(--accent); width: 24px; height: 24px; }
.steps { margin: 14px 0 0; padding: 0; list-style: none; counter-reset: s; }
.steps li {
  position: relative;
  padding-left: 38px;
  color: var(--muted);
  font-size: 15px;
  counter-increment: s;
}
.steps li + li { margin-top: 12px; }
.steps li::before {
  content: counter(s);
  position: absolute;
  left: 0;
  top: 0;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--text-link);
  font-size: 13px;
  font-weight: 700;
  display: grid;
  place-items: center;
}
.steps code, .cmd {
  font-family: var(--mono);
  font-size: 13px;
  background: var(--bg-input);
  padding: 1px 6px;
  border-radius: 6px;
  color: var(--text-primary);
  word-break: break-all;
}
.cmd { display: block; padding: 8px 10px; margin-top: 6px; }

/* support */
.contact-grid { display: grid; gap: 16px; }
@media (min-width: 860px) {
  .contact-grid { grid-template-columns: repeat(3, 1fr); gap: 20px; }
}
.contact {
  padding: 24px;
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}
.contact .ic {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: var(--accent-soft);
  color: var(--accent);
  margin-bottom: 16px;
}
.contact .ic .i { width: 26px; height: 26px; }
.contact h2, .contact h3 { font-size: 18px; font-weight: 700; }
.contact p { margin-top: 6px; color: var(--muted); font-size: 15px; }
.contact .mail { display: inline-block; margin-top: 12px; font-weight: 700; font-size: 17px; word-break: break-all; }
.path {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  margin-top: 12px;
  font-weight: 600;
  color: var(--text-primary);
}
.path span.sep { color: var(--chevron); }

.faq { max-width: 820px; margin: 0 auto; }
.faq details {
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 20px;
}
.faq details + details { margin-top: 12px; }
.faq summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 60px;
  font-weight: 600;
  font-size: 16px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "";
  flex: none;
  width: 9px;
  height: 9px;
  border-right: 2px solid var(--chevron);
  border-bottom: 2px solid var(--chevron);
  transform: rotate(45deg);
  transition: transform .15s;
}
.faq details[open] summary::after { transform: rotate(-135deg); }
.faq .ans { padding: 0 0 18px; color: var(--muted); }
.faq .ans p + p, .faq .ans ol { margin-top: 8px; }
.faq .ans ol { padding-left: 1.3em; }

/* legal */
.legal-wrap { max-width: 820px; margin: 0 auto; }
.legal {
  padding: 28px 22px;
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  font-size: 16px;
  line-height: 1.8;
  overflow-wrap: anywhere;
}
.legal h1 { font-size: clamp(26px, 4.4vw, 34px); font-weight: 800; margin-bottom: 12px; }
.legal h2 {
  font-size: 20px;
  font-weight: 700;
  margin: 32px 0 10px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}
.legal h3 { font-size: 17px; margin: 22px 0 8px; }
.legal p, .legal ul, .legal ol { margin: 10px 0; }
.legal ul, .legal ol { padding-left: 1.4em; }
.legal li + li { margin-top: 4px; }
.legal strong { color: var(--text-primary); }
.legal > p:first-of-type { color: var(--muted); font-size: 15px; }
@media (min-width: 768px) {
  .legal { padding: 48px 56px; }
}

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

.site-footer {
  position: relative;
  overflow: hidden;
  margin-top: 32px;
  padding: 44px 0 28px;
  background: var(--bg-card);
  border-top: 1px solid var(--line);
  font-size: 14px;
  color: var(--muted);
}
.footer-grid {
  display: grid;
  gap: 24px;
}
.footer-brand { display: flex; align-items: center; gap: 12px; color: var(--text-primary); }
.footer-brand img { width: 44px; height: 44px; }
.footer-brand strong { display: block; font-size: 18px; }
.footer-brand span { color: var(--muted); font-size: 14px; }
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.footer-links a {
  display: inline-block;
  padding: 8px 12px;
  border-radius: 8px;
  color: var(--text-primary);
  text-decoration: none;
}
.footer-links a:hover { background: var(--bg-pressed); }
.footer-legal {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 6px 20px;
}
.footer-legal a { color: var(--muted); }
@media (min-width: 768px) {
  .footer-grid { grid-template-columns: 1fr auto; align-items: center; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}

@media print {
  .site-header, .site-footer, .lang-btn { display: none; }
  .legal { border: 0; box-shadow: none; padding: 0; }
}
