/* Wicket landing — 原创视觉：深青 + 琥珀（钥匙孔）。系统字体，无外部资源。 */
:root {
  --bg: #f6f8f7;
  --bg-elev: #ffffff;
  --bg-tint: #ecf4f2;
  --ink: #0d1f1d;
  --ink-2: #3c4f4c;
  --ink-3: #6b7d7a;
  --line: #d9e3e0;
  --brand: #0f766e;
  --brand-ink: #ffffff;
  --brand-deep: #0b3b37;
  --accent: #d97706;
  --accent-soft: #fef3c7;
  --code-bg: #0e1d1b;
  --code-ink: #d7e6e2;
  --code-c: #7f9893;
  --code-k: #f0a35e;
  --code-f: #6fd3c2;
  --code-s: #f3d27a;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(13, 31, 29, .06), 0 8px 24px rgba(13, 31, 29, .06);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif;
  --mono: ui-monospace, SFMono-Regular, "JetBrains Mono", Menlo, Consolas, "Liberation Mono", monospace;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0a1312;
    --bg-elev: #0f1c1a;
    --bg-tint: #0d1917;
    --ink: #e6efed;
    --ink-2: #b2c3bf;
    --ink-3: #7f928e;
    --line: #1f302d;
    --brand: #2bb3a3;
    --brand-ink: #04211e;
    --brand-deep: #071a18;
    --accent: #fbbf24;
    --accent-soft: rgba(251, 191, 36, .12);
    --code-bg: #071110;
    --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 8px 24px rgba(0, 0, 0, .3);
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.7;
  color: var(--ink);
  background: var(--bg);
  overflow-x: hidden;
}
img { display: block; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
code { font-family: var(--mono); font-size: .9em; }
p code, li code, dd code, .lead code {
  background: var(--bg-tint);
  border: 1px solid var(--line);
  padding: .05em .35em;
  border-radius: 6px;
}
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

.wrap { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 720px) { .wrap { padding: 0 28px; } }

.skip { position: absolute; left: -9999px; top: 8px; }
.skip:focus { left: 16px; z-index: 100; background: var(--bg-elev); padding: 8px 12px; border-radius: 8px; }

/* Nav */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(1.4) blur(10px);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 60px; gap: 12px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; font-size: 18px; color: var(--ink); letter-spacing: .01em; }
.brand:hover { text-decoration: none; }
.nav nav { display: flex; align-items: center; gap: 4px; }
.nav nav a { color: var(--ink-2); font-size: 15px; padding: 6px 10px; border-radius: 8px; }
.nav nav a:hover { color: var(--ink); background: var(--bg-tint); text-decoration: none; }
.nav nav a.gh { border: 1px solid var(--line); }
@media (max-width: 640px) {
  .nav nav a[href^="#"] { display: none; }
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  height: 44px; padding: 0 20px; border-radius: 10px;
  font-weight: 600; font-size: 15px; border: 1px solid transparent;
  transition: transform .15s ease, background .15s ease, border-color .15s ease;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn.primary { background: var(--brand); color: var(--brand-ink); }
.btn.primary:hover { background: color-mix(in srgb, var(--brand) 88%, #000); }
.btn.ghost { border-color: var(--line); color: var(--ink); background: var(--bg-elev); }
.btn.ghost:hover { border-color: var(--brand); }
.btn.small { height: 38px; padding: 0 16px; font-size: 14px; margin-top: 8px; }
@media (prefers-reduced-motion: reduce) { .btn { transition: none; } .btn:hover { transform: none; } }

/* Hero */
.hero {
  padding: 56px 0 64px;
  background:
    radial-gradient(1000px 420px at 85% -10%, color-mix(in srgb, var(--brand) 16%, transparent), transparent 70%),
    radial-gradient(600px 300px at -10% 20%, color-mix(in srgb, var(--accent) 10%, transparent), transparent 70%);
}
.hero-grid { display: grid; gap: 40px; align-items: center; }
@media (min-width: 960px) { .hero { padding: 88px 0 96px; } .hero-grid { grid-template-columns: 1fr 1.05fr; gap: 56px; } }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--mono); font-size: 13px; color: var(--ink-2);
  border: 1px solid var(--line); background: var(--bg-elev);
  padding: 4px 12px; border-radius: 999px; margin: 0 0 20px;
}
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
h1 {
  font-size: clamp(34px, 6vw, 56px);
  line-height: 1.15; letter-spacing: -.01em; margin: 0 0 20px; font-weight: 800;
}
h1 em { font-style: normal; color: var(--brand); position: relative; white-space: nowrap; }
h1 em::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: .06em; height: .14em;
  background: var(--accent); opacity: .55; border-radius: 4px; z-index: -1;
}
.lead { font-size: 18px; color: var(--ink-2); margin: 0 0 28px; max-width: 34em; }
.cta { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 20px; }
.install {
  display: flex; align-items: center; gap: 8px; max-width: 100%;
  border: 1px dashed var(--line); border-radius: 10px; padding: 6px 6px 6px 14px;
  background: var(--bg-elev); width: fit-content;
}
.install code { font-size: 14px; color: var(--ink-2); overflow-x: auto; white-space: nowrap; }
.copy {
  flex: none; font: inherit; font-size: 13px; cursor: pointer;
  border: 1px solid var(--line); background: var(--bg-tint); color: var(--ink-2);
  border-radius: 8px; padding: 4px 10px;
}
.copy:hover { color: var(--ink); border-color: var(--brand); }

.code-card {
  margin: 0; min-width: 0;
  background: var(--code-bg); color: var(--code-ink);
  border-radius: var(--radius); box-shadow: var(--shadow);
  border: 1px solid color-mix(in srgb, var(--brand) 25%, transparent);
  overflow: hidden;
}
.code-card figcaption {
  display: flex; align-items: center; gap: 12px;
  font-family: var(--mono); font-size: 12px; color: var(--code-c);
  padding: 10px 14px; border-bottom: 1px solid rgba(255, 255, 255, .06);
}
.lights { display: inline-flex; gap: 6px; }
.lights i { width: 10px; height: 10px; border-radius: 50%; background: rgba(255, 255, 255, .14); }
.code-card pre { margin: 0; padding: 18px 18px 20px; overflow-x: auto; font-size: 13px; line-height: 1.65; }
.code-card code { font-size: 13px; }
.code-card .c { color: var(--code-c); }
.code-card .k { color: var(--code-k); }
.code-card .f { color: var(--code-f); }
.code-card .s { color: var(--code-s); }

/* Sections */
section { padding: 72px 0; }
.section-title { font-size: clamp(24px, 3.6vw, 34px); line-height: 1.3; margin: 0 0 12px; font-weight: 800; letter-spacing: -.005em; }
.section-lead { color: var(--ink-2); font-size: 17px; margin: 0 0 32px; max-width: 40em; }

/* Flow diagram */
.fit { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--bg-elev); }
.flow { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; align-items: stretch; }
@media (min-width: 900px) { .flow { grid-template-columns: 1fr 40px 1.5fr 40px 1fr; align-items: center; } }
.node {
  border: 1px solid var(--line); border-radius: var(--radius); padding: 18px;
  background: var(--bg); display: flex; flex-direction: column; gap: 6px;
}
.node-k { font-weight: 700; }
.node-v { color: var(--ink-3); font-size: 14px; }
.node.host { border-color: var(--brand); background: var(--bg-tint); }
.layers { display: grid; gap: 8px; margin-top: 4px; }
.layer { display: flex; flex-direction: column; border-radius: 10px; padding: 10px 12px; font-weight: 600; font-size: 15px; }
.layer small { font-weight: 400; font-size: 13px; font-family: var(--mono); opacity: .85; }
.layer.w { background: var(--brand); color: var(--brand-ink); }
.layer.a { background: var(--bg-elev); border: 1px dashed var(--line); color: var(--ink); }
.layer.a small { font-family: var(--font); color: var(--ink-3); }
.arrow { height: 24px; position: relative; }
.arrow::before {
  content: ""; position: absolute; left: 50%; top: 0; bottom: 0; width: 2px;
  background: linear-gradient(var(--line), var(--brand)); transform: translateX(-50%);
}
.arrow::after {
  content: ""; position: absolute; left: 50%; bottom: -2px; width: 8px; height: 8px;
  border-right: 2px solid var(--brand); border-bottom: 2px solid var(--brand);
  transform: translateX(-50%) rotate(45deg);
}
@media (min-width: 900px) {
  .arrow { height: 2px; }
  .arrow::before { left: 0; right: 0; top: 0; bottom: auto; width: auto; height: 2px; transform: none; background: linear-gradient(90deg, var(--line), var(--brand)); }
  .arrow::after { left: auto; right: 0; bottom: auto; top: -3px; transform: rotate(-45deg); }
}

/* Feature cards */
.grid { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .grid { grid-template-columns: repeat(4, 1fr); } .grid.three { grid-template-columns: repeat(3, 1fr); } }
.card {
  background: var(--bg-elev); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px; display: flex; flex-direction: column; gap: 8px;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.card:hover { border-color: color-mix(in srgb, var(--brand) 55%, var(--line)); box-shadow: var(--shadow); }
.card h3 { margin: 0; font-size: 17px; }
.card p { margin: 0; color: var(--ink-2); font-size: 14.5px; flex: 1; }
.card a { font-size: 14px; font-weight: 600; }

/* Split */
.split-grid { display: grid; gap: 32px; align-items: center; }
@media (min-width: 900px) { .split-grid { grid-template-columns: 1fr 1fr; gap: 56px; } }
.split.alt { background: var(--bg-elev); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.ticks { list-style: none; padding: 0; margin: 0 0 16px; display: grid; gap: 12px; }
.ticks li { position: relative; padding-left: 28px; color: var(--ink-2); }
.ticks li::before {
  content: ""; position: absolute; left: 0; top: .45em; width: 16px; height: 16px; border-radius: 50%;
  background: var(--accent-soft); border: 2px solid var(--accent);
}
.ticks strong { color: var(--ink); }
.ports { display: grid; gap: 12px; }
.port {
  display: grid; grid-template-columns: 110px 1fr; gap: 16px; align-items: center;
  background: var(--bg-elev); border: 1px solid var(--line); border-left: 4px solid var(--brand);
  border-radius: 10px; padding: 16px 18px;
}
.port-name { font-family: var(--mono); font-weight: 700; color: var(--brand); }
.port-desc { color: var(--ink-2); font-size: 14.5px; }
@media (max-width: 480px) { .port { grid-template-columns: 1fr; gap: 4px; } }

/* Defaults */
.mini { background: var(--bg-elev); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.mini h3 { margin: 6px 0 8px; font-size: 18px; }
.mini p { margin: 0; color: var(--ink-2); font-size: 15px; }
.num { font-family: var(--mono); color: var(--accent); font-weight: 700; font-size: 14px; }

/* Packages */
.pkgs { margin: 0; display: grid; gap: 12px; }
.pkgs div { border: 1px solid var(--line); border-radius: 10px; padding: 16px 18px; background: var(--bg); }
.pkgs dt { font-weight: 700; margin-bottom: 4px; }
.pkgs dt code { color: var(--brand); font-size: 15px; }
.pkgs dd { margin: 0; color: var(--ink-2); font-size: 14.5px; }

/* Status */
.status { background: var(--brand-deep); color: #e6f2ef; }
.status-inner { max-width: 760px; text-align: center; }
.status h2 { font-size: clamp(24px, 3.4vw, 32px); margin: 0 0 12px; }
.status p { color: #b9cfca; margin: 0 0 28px; font-size: 17px; }
.status strong { color: #fff; }
.status .btn.primary { background: #fbbf24; color: #1f1400; }
.status .btn.primary:hover { background: #f59e0b; }

/* Footer */
.footer { padding: 40px 0 48px; border-top: 1px solid var(--line); }
.footer-grid { display: grid; gap: 24px; }
@media (min-width: 800px) { .footer-grid { grid-template-columns: 1.4fr 1fr; align-items: start; } }
.muted { color: var(--ink-3); font-size: 14px; margin: 10px 0 0; max-width: 36em; }
.footer-links { display: flex; flex-wrap: wrap; gap: 8px 20px; justify-content: flex-start; }
@media (min-width: 800px) { .footer-links { justify-content: flex-end; } }
.footer-links a { color: var(--ink-2); font-size: 14px; }

/* 404 */
.notfound { min-height: 70vh; display: grid; place-items: center; text-align: center; padding: 48px 16px; }
.notfound .code { font-family: var(--mono); color: var(--accent); font-weight: 700; letter-spacing: .1em; }
.notfound h1 { font-size: clamp(28px, 5vw, 40px); }
.notfound p { color: var(--ink-2); margin: 0 0 24px; }
.notfound .cta { justify-content: center; }

/* Language switch */
.nav nav a.lang { font-family: var(--mono); font-size: 13px; font-weight: 700; color: var(--brand); }
