
:root {
  color-scheme: dark;
  --bg: #0d1122;
  --surface: #151a32;
  --ink: #f7f7ff;
  --muted: #b4bdd9;
  --line: #343e60;
  --violet: #c3b2ff;
  --accent: #ddcfff;
  --accent-ink: #20133e;
  --wrap: 1160px;
}
* { box-sizing: border-box; }
html { min-width: 0; scroll-behavior: smooth; }
body {
  margin: 0; min-height: 100vh; color: var(--ink);
  background:
    radial-gradient(ellipse at 52% -18%, #303269 0, transparent 56%),
    radial-gradient(ellipse at 84% 46%, #22264e 0, transparent 47%),
    var(--bg);
  font-family: Inter, system-ui, -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif;
}
[lang="ar"] body { font-family: "Noto Sans Arabic", "Geeza Pro", Tahoma, system-ui, sans-serif; }
a { color: inherit; text-decoration: none; }
a:focus-visible { outline: 2px solid #ede4ff; outline-offset: 4px; border-radius: 4px; }
.wrap { width: min(var(--wrap), calc(100% - 40px)); margin-inline: auto; }
.top {
  min-height: 76px; display: flex; align-items: center; justify-content: space-between;
  gap: 12px 24px; border-bottom: 1px solid var(--line);
}
.brand { display: inline-flex; align-items: center; gap: 10px; line-height: 1.2; font-size: 1.06rem; font-weight: 730; letter-spacing: -.025em; }
.brand img { display: block; border-radius: 9px; }
.nav { display: flex; align-items: center; gap: 20px; }
.nav .quiet { font-size: .88rem; color: var(--muted); }
.nav .quiet:hover, .foot a:hover { color: var(--ink); text-decoration: underline; }
.language { display: flex; align-items: center; gap: 2px; padding: 3px; border: 1px solid var(--line); border-radius: 9px; }
.language a { display: inline-grid; place-items: center; padding: 0 9px; min-height: 34px; font-size: .79rem; color: var(--muted); white-space: nowrap; }
.language a[aria-current="page"] { background: #33315b; color: #f9f6ff; border-radius: 6px; font-weight: 650; }
.hero { display: grid; gap: 40px; padding: 50px 0 48px; align-items: center; }
.hero-content { min-width: 0; }
.eyebrow { margin: 0 0 16px; color: var(--violet); font-size: .82rem; font-weight: 640; }
h1 { margin: 0; max-width: 11ch; font-size: clamp(2.5rem, 7.7vw, 5.45rem); line-height: .99; letter-spacing: -.062em; font-weight: 760; }
h1 span { display: block; color: var(--violet); }
[lang="zh"] h1 { max-width: none; line-height: 1.18; letter-spacing: -.055em; font-size: clamp(2.45rem, 6vw, 4.6rem); }
[lang="ar"] h1 { max-width: none; line-height: 1.24; letter-spacing: normal; font-size: clamp(2.5rem, 6.2vw, 4.8rem); }
.lede { max-width: 44ch; margin: 21px 0 0; color: var(--muted); font-size: clamp(1rem, 2vw, 1.11rem); line-height: 1.75; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 27px 0 0; }
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  min-height: 46px; padding: 10px 15px; border: 1px solid var(--line);
  border-radius: 9px; font-size: .9rem; font-weight: 680;
}
.button.primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.button.primary:hover { background: #eee5ff; }
.button.secondary:hover { border-color: var(--violet); }
[dir="rtl"] .arrow { transform: scaleX(-1); }
.example {
  margin: 0; min-width: 0; position: relative; border: 1px solid #4e5180; border-radius: 16px;
  background: #11162a; box-shadow: 0 24px 60px #07091660;
}
.example figcaption {
  padding: 15px 18px; display: flex; justify-content: space-between; align-items: center;
  gap: 10px 15px; flex-wrap: wrap; background: #1d2341; border-bottom: 1px solid #424c73;
  border-radius: 15px 15px 0 0; font-size: .84rem; font-weight: 660;
}
.example figcaption code { color: #d4c6ff; font-size: .75rem; }
code { font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace; }
.console {
  margin: 0; padding: 19px 18px; color: #e6eafa; line-height: 1.65;
  font-size: clamp(.72rem, 1.6vw, .9rem); overflow-wrap: anywhere; white-space: pre-wrap;
  tab-size: 2; text-align: left;
}
.console .cmd { color: #d3bdff; }
.console .value { color: #9ed7ff; }
.endpoint {
  display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: 6px 14px;
  border-top: 1px solid var(--line); padding: 14px 18px; color: var(--muted); font-size: .78rem;
}
.endpoint code { color: #e1dcfb; overflow-wrap: anywhere; }
.flow {
  display: grid; grid-template-columns: 1fr; border-block: 1px solid var(--line);
}
.flow article { padding: 22px 0; }
.flow article + article { border-top: 1px solid var(--line); }
.flow h2 { margin: 0 0 7px; font-size: 1rem; }
.flow p { margin: 0; color: var(--muted); line-height: 1.6; font-size: .91rem; max-width: 31ch; }
.foot { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px 20px; padding: 20px 0 28px; font-size: .82rem; color: var(--muted); }
@media (max-width: 600px) {
  .wrap { width: calc(100% - 32px); }
  .top { min-height: 66px; flex-wrap: wrap; padding-block: 12px; }
  .nav { gap: 10px; }
  .nav .quiet { display: none; }
}
@media (min-width: 650px) {
  .flow { grid-template-columns: repeat(3, 1fr); }
  .flow article { padding: 23px 24px; }
  .flow article:first-child { padding-inline-start: 0; }
  .flow article + article { border-top: 0; border-inline-start: 1px solid var(--line); }
}
@media (min-width: 850px) {
  .wrap { width: min(var(--wrap), calc(100% - 88px)); }
  .hero { grid-template-columns: 1fr .97fr; gap: clamp(42px, 6.3vw, 92px); padding: 76px 0 70px; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
