/* DSH Evolution — GitHub Pages landing site
   Light/dark, responsive, reduced-motion aware. */

:root {
  color-scheme: light dark;
  --bg: #f7f7fb;
  --bg-elevated: #fbfaff;
  --surface: #ffffff;
  --surface-2: #f1eff8;
  --surface-3: #e9e6f4;
  --text: #16151f;
  --muted: #5f5c73;
  --faint: #8b87a0;
  --border: #e5e1ef;
  --border-strong: #d4cfe4;
  --accent: #6d5efc;
  --accent-strong: #5546e8;
  --accent-2: #a78bfa;
  --accent-soft: rgba(109, 94, 252, 0.1);
  --accent-softer: rgba(109, 94, 252, 0.055);
  --success: #0f9f6e;
  --success-soft: rgba(15, 159, 110, 0.1);
  --warning: #b45309;
  --warning-soft: rgba(180, 83, 9, 0.09);
  --danger: #d92d20;
  --danger-soft: rgba(217, 45, 32, 0.08);
  --shadow-sm: 0 1px 2px rgba(22, 21, 31, 0.04), 0 8px 24px rgba(44, 30, 94, 0.06);
  --shadow: 0 18px 50px rgba(44, 30, 94, 0.12);
  --shadow-lg: 0 30px 80px rgba(44, 30, 94, 0.18);
  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 22px;
  --max: 1120px;
  --header-h: 70px;
  --font: "Inter", "SF Pro Text", -apple-system, BlinkMacSystemFont, "Segoe UI",
    "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  --mono: "SFMono-Regular", "Cascadia Code", "JetBrains Mono", Menlo, Consolas,
    "Liberation Mono", monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b0a12;
    --bg-elevated: #100e19;
    --surface: #14121f;
    --surface-2: #1b1829;
    --surface-3: #242035;
    --text: #f5f3ff;
    --muted: #aaa4c0;
    --faint: #7f7a95;
    --border: #2a263a;
    --border-strong: #3a3450;
    --accent: #8b7cff;
    --accent-strong: #a294ff;
    --accent-2: #c4b5fd;
    --accent-soft: rgba(139, 124, 255, 0.14);
    --accent-softer: rgba(139, 124, 255, 0.075);
    --success: #34d399;
    --success-soft: rgba(52, 211, 153, 0.12);
    --warning: #fbbf24;
    --warning-soft: rgba(251, 191, 36, 0.1);
    --danger: #f87171;
    --danger-soft: rgba(248, 113, 113, 0.1);
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3), 0 8px 24px rgba(0, 0, 0, 0.22);
    --shadow: 0 18px 50px rgba(0, 0, 0, 0.38);
    --shadow-lg: 0 30px 80px rgba(0, 0, 0, 0.5);
  }
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 24px);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

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

button {
  font: inherit;
  color: inherit;
}

code,
pre {
  font-family: var(--mono);
}

::selection {
  background: var(--accent);
  color: #fff;
}

:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--accent) 55%, transparent);
  outline-offset: 3px;
  border-radius: 6px;
}

.container {
  width: min(calc(100% - 40px), var(--max));
  margin-inline: auto;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 200;
  padding: 10px 14px;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  transform: translateY(-160%);
  transition: transform 0.2s ease;
}

.skip-link:focus {
  transform: translateY(0);
}

/* Language panels: only one language is laid out at a time. */
[data-lang-panel] {
  display: none;
}

html[data-lang="zh"] [data-lang-panel="zh"],
html[data-lang="en"] [data-lang-panel="en"] {
  display: block;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  height: var(--header-h);
  border-bottom: 1px solid color-mix(in srgb, var(--border) 80%, transparent);
  background: color-mix(in srgb, var(--bg) 84%, transparent);
  backdrop-filter: saturate(160%) blur(18px);
  -webkit-backdrop-filter: saturate(160%) blur(18px);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 22px;
  height: 100%;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex: none;
  font-weight: 800;
  letter-spacing: -0.025em;
  font-size: 16px;
}

.brand img {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  box-shadow: 0 4px 14px rgba(109, 94, 252, 0.28);
}

.brand span {
  white-space: nowrap;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 2px;
  margin-left: auto;
}

.site-nav a {
  padding: 8px 10px;
  border-radius: 8px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--muted);
  transition: color 0.18s ease, background 0.18s ease;
}

.site-nav a:hover {
  color: var(--text);
  background: var(--surface-2);
}

.nav-backdrop {
  position: fixed;
  inset: var(--header-h) 0 0;
  z-index: 50;
  background: rgba(11, 10, 18, 0.32);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}

.nav-backdrop[hidden] {
  display: none;
}

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

.lang-switch {
  display: inline-flex;
  align-items: center;
  padding: 3px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
}

.lang-switch a {
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.3;
  color: var(--muted);
  transition: color 0.18s ease, background 0.18s ease;
}

.lang-switch a[aria-pressed="true"] {
  color: #fff;
  background: var(--accent);
  box-shadow: 0 4px 12px rgba(109, 94, 252, 0.3);
}

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

.lang-switch a[aria-pressed="true"]:hover {
  color: #fff;
}

.nav-toggle {
  display: none;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  cursor: pointer;
}

.nav-toggle svg {
  width: 19px;
  height: 19px;
  margin: auto;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 18px;
  border: 1px solid transparent;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 750;
  line-height: 1.2;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease,
    border-color 0.18s ease;
  white-space: nowrap;
}

.btn svg {
  width: 16px;
  height: 16px;
  flex: none;
}

.btn-primary {
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  box-shadow: 0 12px 26px rgba(109, 94, 252, 0.3);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 34px rgba(109, 94, 252, 0.38);
}

.btn-secondary {
  color: var(--text);
  background: var(--surface);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-sm);
}

.btn-secondary:hover {
  transform: translateY(-1px);
  border-color: var(--accent);
}

.btn-ghost {
  color: var(--text);
  background: transparent;
  border-color: var(--border);
}

.btn-ghost:hover {
  background: var(--surface-2);
}

.btn-sm {
  padding: 8px 12px;
  font-size: 13px;
  border-radius: 10px;
}

/* Hero */
.hero {
  position: relative;
  overflow: hidden;
  padding: 76px 0 54px;
}

.hero::before {
  content: "";
  position: absolute;
  inset: -220px -10% auto;
  height: 680px;
  background:
    radial-gradient(42% 55% at 18% 42%, rgba(109, 94, 252, 0.2), transparent 70%),
    radial-gradient(36% 50% at 82% 18%, rgba(45, 212, 191, 0.13), transparent 72%),
    radial-gradient(30% 45% at 60% 80%, rgba(167, 139, 250, 0.12), transparent 70%);
  pointer-events: none;
  z-index: -1;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(to right, color-mix(in srgb, var(--border) 40%, transparent) 1px, transparent 1px),
    linear-gradient(to bottom, color-mix(in srgb, var(--border) 40%, transparent) 1px, transparent 1px);
  background-size: 64px 64px;
  mask: linear-gradient(to bottom, rgba(0, 0, 0, 0.45), transparent 78%);
  -webkit-mask: linear-gradient(to bottom, rgba(0, 0, 0, 0.45), transparent 78%);
  pointer-events: none;
  opacity: 0.55;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(0, 0.98fr);
  gap: 54px;
  align-items: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--accent);
}

.eyebrow .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 0 4px var(--success-soft);
}

h1 {
  margin: 16px 0 18px;
  font-size: clamp(38px, 5.2vw, 64px);
  line-height: 1.04;
  letter-spacing: -0.045em;
  font-weight: 850;
}

.grad {
  background: linear-gradient(115deg, var(--accent) 8%, #28b8a7 92%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lead {
  max-width: 58ch;
  margin: 0;
  font-size: 17.5px;
  line-height: 1.7;
  color: var(--muted);
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 28px 0 18px;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.pill {
  display: inline-flex;
  align-items: center;
  padding: 5px 10px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-size: 11.5px;
  font-weight: 750;
  line-height: 1.35;
}

.pill-accent {
  color: var(--accent);
  border-color: color-mix(in srgb, var(--accent) 35%, var(--border));
  background: var(--accent-soft);
}

.install-mini {
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: 590px;
  margin-top: 24px;
  padding: 7px 7px 7px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.install-mini code {
  flex: 1;
  min-width: 0;
  overflow-x: visible;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-size: 11.5px;
  color: var(--muted);
}

.copy-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  flex: none;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface-2);
  color: var(--muted);
  cursor: pointer;
  transition: color 0.18s ease, background 0.18s ease, border-color 0.18s ease;
}

.copy-btn:hover {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--accent-soft);
}

.copy-btn svg {
  width: 14px;
  height: 14px;
}

.hero-side {
  min-width: 0;
}

.hero-visual {
  position: relative;
  min-height: 410px;
  padding: 6px 12px 36px 0;
}

.hero-shot-note {
  margin: 10px 0 0;
  color: var(--faint);
  font-size: 11.5px;
  line-height: 1.5;
  text-align: right;
}

.browser-frame {
  position: relative;
  z-index: 2;
  overflow: hidden;
  border: 1px solid var(--border-strong);
  border-radius: 16px;
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  transform: rotate(-1.1deg);
}

.browser-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  height: 30px;
  padding: 0 12px;
  border-bottom: 1px solid var(--border);
  background: var(--surface-2);
}

.browser-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--border-strong);
}

.browser-dot:nth-child(1) {
  background: #ff6b6b;
}

.browser-dot:nth-child(2) {
  background: #f7c948;
}

.browser-dot:nth-child(3) {
  background: #35c48a;
}

.browser-url {
  margin-left: 8px;
  padding: 2px 9px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--faint);
  font-size: 9px;
  line-height: 1.6;
  background: var(--surface);
}

.browser-frame img {
  width: 100%;
}

.phone-frame {
  position: absolute;
  right: -4px;
  bottom: 0;
  z-index: 3;
  width: 178px;
  overflow: hidden;
  border: 7px solid #1b1926;
  border-radius: 28px;
  background: #1b1926;
  box-shadow: 0 24px 55px rgba(20, 12, 55, 0.38);
}

.phone-frame::before {
  content: "";
  position: absolute;
  top: 6px;
  left: 50%;
  z-index: 2;
  width: 48px;
  height: 5px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.2);
  transform: translateX(-50%);
}

.phone-frame img {
  width: 100%;
  border-radius: 21px;
}

/* Stats */
.stats {
  padding: 6px 0 0;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--border);
  gap: 1px;
  box-shadow: var(--shadow-sm);
}

.stats-grid > div {
  padding: 20px 16px;
  background: var(--surface);
  text-align: center;
}

.stats-grid strong {
  display: block;
  font-size: 27px;
  line-height: 1.15;
  letter-spacing: -0.035em;
  font-weight: 850;
}

.stats-grid span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

/* Sections */
.section {
  padding: 86px 0;
}

.section-alt {
  border-block: 1px solid var(--border);
  background: var(--surface-2);
}

.section-head {
  max-width: 760px;
  margin-bottom: 34px;
}

.section-head h2 {
  margin: 10px 0 12px;
  font-size: clamp(28px, 3.8vw, 43px);
  line-height: 1.12;
  letter-spacing: -0.04em;
  font-weight: 850;
}

.section-head p {
  max-width: 68ch;
  margin: 0;
  color: var(--muted);
  font-size: 16.5px;
}

.section-head .eyebrow {
  margin-bottom: 2px;
}

/* Cards */
.card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.card {
  position: relative;
  padding: 23px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.card:hover {
  transform: translateY(-3px);
  border-color: color-mix(in srgb, var(--accent) 32%, var(--border));
  box-shadow: var(--shadow);
}

.card .icon {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  margin-bottom: 15px;
  border-radius: 12px;
  color: var(--accent);
  background: var(--accent-soft);
}

.card .icon svg {
  width: 20px;
  height: 20px;
}

.card h3 {
  margin: 0 0 7px;
  font-size: 16.5px;
  line-height: 1.35;
  letter-spacing: -0.015em;
}

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

/* Comparison */
.compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 26px 0 18px;
}

.compare-card {
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.compare-card.accent {
  border-color: color-mix(in srgb, var(--accent) 38%, var(--border));
  background:
    linear-gradient(145deg, var(--accent-softer), transparent 62%),
    var(--surface);
}

.compare-card h3 {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 0;
  font-size: 16px;
  letter-spacing: -0.015em;
}

.compare-card h3 .tag {
  padding: 3px 8px;
  border-radius: 999px;
  color: var(--accent);
  background: var(--accent-soft);
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.compare-card ul {
  display: grid;
  gap: 9px;
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
}

.compare-card li {
  display: flex;
  gap: 9px;
  align-items: flex-start;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.55;
}

.compare-card li .mark {
  display: grid;
  place-items: center;
  width: 18px;
  height: 18px;
  flex: none;
  margin-top: 1px;
  border-radius: 50%;
  font-size: 11px;
  font-weight: 900;
}

.compare-card li.yes .mark {
  color: var(--success);
  background: var(--success-soft);
}

.compare-card li.no .mark {
  color: var(--faint);
  background: var(--surface-2);
}

.principles {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

.principle {
  padding: 15px 16px;
  border: 1px solid var(--border);
  border-radius: 13px;
  background: var(--surface);
}

.principle strong {
  display: block;
  font-size: 13.5px;
  letter-spacing: -0.01em;
}

.principle span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

/* Table */
.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  -webkit-overflow-scrolling: touch;
}

table {
  width: 100%;
  min-width: 700px;
  border-collapse: collapse;
  text-align: left;
}

th,
td {
  padding: 13px 18px;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
  font-size: 13.5px;
}

th {
  color: var(--muted);
  background: var(--surface-2);
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  white-space: nowrap;
}

td:first-child {
  width: 190px;
  color: var(--text);
  font-weight: 750;
  white-space: nowrap;
}

tr:last-child td {
  border-bottom: 0;
}

td code,
p code,
li code,
.callout code {
  padding: 2px 6px;
  border-radius: 5px;
  background: var(--surface-2);
  font-size: 0.9em;
  overflow-wrap: anywhere;
}

.callout {
  display: flex;
  gap: 13px;
  margin-top: 18px;
  padding: 16px 18px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.6;
}

.callout .callout-icon {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  flex: none;
  border-radius: 9px;
  color: var(--accent);
  background: var(--accent-soft);
}

.callout .callout-icon svg {
  width: 17px;
  height: 17px;
}

.callout strong {
  color: var(--text);
}

.callout.warning {
  border-color: color-mix(in srgb, var(--warning) 30%, var(--border));
  background: var(--warning-soft);
}

.callout.warning .callout-icon {
  color: var(--warning);
  background: color-mix(in srgb, var(--warning) 14%, transparent);
}

/* Pipeline + steps */
.pipeline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
  margin: 22px 0 26px;
}

.pipeline span {
  padding: 6px 11px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-size: 11.5px;
  font-weight: 750;
  white-space: nowrap;
}

.pipeline .arrow {
  padding: 0;
  border: 0;
  background: none;
  color: var(--faint);
  font-size: 13px;
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.step {
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.step .num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  margin-bottom: 12px;
  border-radius: 9px;
  color: var(--accent);
  background: var(--accent-soft);
  font-size: 12px;
  font-weight: 850;
}

.step h3 {
  margin: 0 0 6px;
  font-size: 15.5px;
}

.step p {
  margin: 0;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.62;
}

.gates {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 24px;
}

.gate {
  display: flex;
  gap: 13px;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
}

.gate .gate-num {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  flex: none;
  border-radius: 9px;
  color: var(--danger);
  background: var(--danger-soft);
  font-size: 12px;
  font-weight: 850;
}

.gate h3 {
  margin: 0 0 4px;
  font-size: 14.5px;
}

.gate p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

/* Screenshots */
.shots {
  display: grid;
  grid-template-columns: minmax(0, 1.28fr) minmax(0, 0.72fr);
  gap: 18px;
  align-items: start;
}

.shot {
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.shot a {
  display: block;
  background: var(--surface-2);
}

.shot img {
  width: 100%;
}

.shot.mobile {
  max-width: 360px;
  margin-inline: auto;
}

.shot.mobile a {
  padding: 18px 18px 0;
  background:
    radial-gradient(80% 60% at 50% 0%, var(--accent-soft), transparent 70%),
    var(--surface-2);
}

.shot.mobile img {
  border: 1px solid var(--border);
  border-bottom: 0;
  border-radius: 18px 18px 0 0;
  box-shadow: 0 12px 30px rgba(20, 12, 55, 0.12);
}

.shot figcaption {
  padding: 14px 18px;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.55;
}

.shot figcaption strong {
  display: block;
  margin-bottom: 2px;
  color: var(--text);
  font-size: 13.5px;
}

.ui-points {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 18px;
}

.ui-points span {
  padding: 5px 9px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-size: 11.5px;
  font-weight: 650;
}

.shot-note {
  margin: 12px 0 0;
  color: var(--faint);
  font-size: 12px;
  line-height: 1.55;
}

/* Install */
.install-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 15px;
}

.install-card {
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.install-card.recommended {
  border-color: color-mix(in srgb, var(--accent) 45%, var(--border));
  background:
    linear-gradient(145deg, var(--accent-softer), transparent 62%),
    var(--surface);
}

.install-card .install-head {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 7px;
}

.install-card h3 {
  margin: 0;
  font-size: 15.5px;
}

.install-card .tag {
  padding: 3px 7px;
  border-radius: 999px;
  font-size: 9.5px;
  font-weight: 850;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.tag.good {
  color: var(--success);
  background: var(--success-soft);
}

.tag.pending {
  color: var(--warning);
  background: var(--warning-soft);
}

.install-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.code-block {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 13px;
  padding: 7px 7px 7px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface-2);
}

.code-block code {
  flex: 1;
  min-width: 0;
  overflow-x: auto;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  color: var(--muted);
  font-size: 11.5px;
}

.code-block .copy-btn {
  width: 28px;
  height: 28px;
}

pre.code-pre {
  overflow-x: auto;
  margin: 0;
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface-2);
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
  scrollbar-width: thin;
}

pre.code-pre code {
  padding: 0;
  background: none;
  font-size: inherit;
}

.details-stack {
  display: grid;
  gap: 10px;
  margin-top: 20px;
}

details {
  border: 1px solid var(--border);
  border-radius: 13px;
  background: var(--surface);
}

summary {
  position: relative;
  display: block;
  padding: 15px 44px 15px 18px;
  cursor: pointer;
  font-size: 13.5px;
  font-weight: 750;
  line-height: 1.55;
  list-style: none;
}

summary::-webkit-details-marker {
  display: none;
}

summary::after {
  content: "+";
  position: absolute;
  top: 50%;
  right: 18px;
  color: var(--faint);
  font-size: 17px;
  font-weight: 500;
  line-height: 1;
  transform: translateY(-50%);
}

details[open] summary::after {
  content: "−";
}

.details-body {
  padding: 0 18px 18px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

.details-body > :first-child {
  margin-top: 0;
}

.details-body > :last-child {
  margin-bottom: 0;
}

.details-body .code-pre {
  margin-top: 12px;
}

/* FAQ */
.faq {
  display: grid;
  gap: 10px;
  max-width: 860px;
}

.faq details {
  background: var(--surface);
}

.faq summary {
  font-size: 14.5px;
}

/* Footer */
.site-footer {
  padding: 56px 0 28px;
  border-top: 1px solid var(--border);
  background: var(--surface);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr repeat(3, 0.7fr);
  gap: 34px;
}

.footer-brand .brand {
  margin-bottom: 10px;
}

.footer-brand p {
  max-width: 36ch;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.footer-col h3 {
  margin: 2px 0 11px;
  color: var(--faint);
  font-size: 10.5px;
  font-weight: 850;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.footer-col a {
  display: block;
  padding: 3px 0;
  color: var(--muted);
  font-size: 13px;
  transition: color 0.18s ease;
}

.footer-col a:hover {
  color: var(--accent);
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 36px;
  padding-top: 18px;
  border-top: 1px solid var(--border);
  color: var(--faint);
  font-size: 11.5px;
}

.footer-bottom a {
  color: var(--muted);
}

.footer-bottom a:hover {
  color: var(--accent);
}

/* Toast */
.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  z-index: 120;
  padding: 9px 15px;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  background: var(--text);
  color: var(--bg);
  font-size: 12.5px;
  font-weight: 700;
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 10px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* Reveal animation */
@media (prefers-reduced-motion: no-preference) {
  .js .reveal {
    opacity: 0;
    transform: translateY(14px);
    transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
  }

  .js .reveal.is-visible {
    opacity: 1;
    transform: none;
  }
}

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

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Responsive */
@media (max-width: 1020px) {
  .hero-grid {
    gap: 34px;
  }

  .site-nav a {
    padding-inline: 8px;
    font-size: 13px;
  }

  .principles {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 880px) {
  :root {
    --header-h: 64px;
  }

  .site-nav {
    position: absolute;
    top: calc(var(--header-h) - 2px);
    left: 20px;
    right: 20px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: 14px;
    background: var(--surface);
    box-shadow: var(--shadow);
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav a {
    padding: 10px 12px;
    font-size: 14px;
  }

  .nav-toggle {
    display: inline-flex;
    margin-left: auto;
  }

  .header-actions {
    margin-left: 0;
  }

  .hero {
    padding-top: 52px;
  }

  .hero-grid {
    grid-template-columns: 1fr;
    gap: 34px;
  }

  .hero-visual {
    min-height: 0;
    padding: 0 26px 28px 0;
  }

  .hero-shot-note {
    text-align: left;
  }

  .phone-frame {
    width: 156px;
  }

  .card-grid,
  .steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .compare,
  .install-grid,
  .shots {
    grid-template-columns: 1fr;
  }

  .shot.mobile {
    max-width: 330px;
  }

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

@media (max-width: 640px) {
  .container {
    width: min(calc(100% - 28px), var(--max));
  }

  .brand span {
    display: none;
  }

  .header-actions {
    gap: 7px;
  }

  .header-inner {
    gap: 10px;
  }

  .hero {
    padding: 42px 0 36px;
  }

  h1 {
    font-size: clamp(34px, 10vw, 46px);
  }

  .lead {
    font-size: 16px;
  }

  .section {
    padding: 62px 0;
  }

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

  .section-head h2 {
    font-size: clamp(26px, 8vw, 34px);
  }

  .section-head p {
    font-size: 15.5px;
  }

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

  .stats-grid strong {
    font-size: 23px;
  }

  .card-grid,
  .steps,
  .gates,
  .principles {
    grid-template-columns: 1fr;
  }

  .card {
    padding: 20px;
  }

  .compare-card {
    padding: 20px;
  }

  .phone-frame {
    width: 132px;
    right: 0;
    border-width: 6px;
    border-radius: 23px;
  }

  .phone-frame img {
    border-radius: 17px;
  }

  .hero-visual {
    padding-right: 14px;
  }

  .pipeline {
    gap: 5px;
  }

  .pipeline span {
    font-size: 10.5px;
    padding: 5px 9px;
  }

  .install-card,
  .step,
  .gate {
    padding: 18px;
  }

  .table-wrap {
    border-radius: 13px;
  }

  th,
  td {
    padding: 11px 14px;
  }

  td:first-child {
    width: 150px;
    white-space: normal;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .footer-bottom {
    display: block;
    line-height: 1.8;
  }

  .footer-bottom span {
    display: block;
  }
}

@media (max-width: 380px) {
  .lang-switch a {
    padding-inline: 8px;
  }

  .btn {
    padding-inline: 14px;
  }

  .phone-frame {
    width: 118px;
  }
}
/* Inline SVG sprite */
.svg-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.copy-btn.is-copied {
  color: var(--success);
  border-color: var(--success);
  background: var(--success-soft);
}

/* Hero entrance */
@media (prefers-reduced-motion: no-preference) {
  .hero .lang-panel,
  .hero-visual {
    animation: hero-rise 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) both;
  }

  .hero-visual {
    animation-delay: 0.08s;
  }
}

@keyframes hero-rise {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
