/* ==========================================================================
   DNSKit 鈥?encrypted DNS profile generator
   ========================================================================== */

*,
*::before,
*::after { box-sizing: border-box; }

[hidden] { display: none !important; }

:root {
  color-scheme: light;

  --bg: #f5f6f8;
  --surface: #ffffff;
  --surface-2: #f8f9fc;
  --surface-3: #f1f3f8;
  --ink: #0c1120;
  --ink-2: #343c4f;
  --muted: #6b7385;
  --faint: #98a0b2;
  --line: #e5e8ef;
  --line-strong: #d3d8e3;
  --grid: rgba(12, 17, 32, 0.045);

  --brand: #2b59ff;
  --brand-strong: #1d45e0;
  --brand-soft: #eef2ff;
  --brand-wash: rgba(43, 89, 255, 0.14);
  --brand-ink: #1a3fd0;

  --mint: #0a9b6c;
  --mint-soft: #e8f7f1;
  --amber: #b45309;
  --amber-soft: #fff4e6;
  --amber-line: #f3d3ae;

  --code-bg: #0a0f1e;
  --code-bg-soft: #0e1528;
  --code-line: #1b2540;

  --shadow-sm: 0 1px 2px rgba(16, 24, 40, 0.05);
  --shadow-md: 0 18px 38px -24px rgba(16, 24, 40, 0.3);
  --shadow-lg: 0 40px 90px -50px rgba(16, 24, 40, 0.5);

  --radius-lg: 26px;
  --radius-md: 18px;
  --radius-sm: 12px;

  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  --font-mono: "SFMono-Regular", ui-monospace, "Cascadia Code", "Roboto Mono", Menlo,
    Consolas, "Liberation Mono", monospace;

  --header-h: 64px;
}

html[data-theme="dark"] {
  color-scheme: dark;

  --bg: #080b14;
  --surface: #0e1422;
  --surface-2: #0a101c;
  --surface-3: #151d30;
  --ink: #eef2ff;
  --ink-2: #c4cce0;
  --muted: #8d97ae;
  --faint: #68738b;
  --line: #1e2738;
  --line-strong: #2c3852;
  --grid: rgba(255, 255, 255, 0.045);

  --brand: #6b8cff;
  --brand-strong: #86a1ff;
  --brand-soft: #141d38;
  --brand-wash: rgba(107, 140, 255, 0.18);
  --brand-ink: #a9bcff;

  --mint: #4ade9b;
  --mint-soft: #0d2a21;
  --amber: #f5b66b;
  --amber-soft: #2a1e0e;
  --amber-line: #4a3418;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 18px 38px -24px rgba(0, 0, 0, 0.7);
  --shadow-lg: 0 40px 90px -50px rgba(0, 0, 0, 0.9);
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(900px 480px at 10% -10%, rgba(43, 89, 255, 0.1), transparent 62%),
    radial-gradient(720px 420px at 92% -4%, rgba(10, 155, 108, 0.07), transparent 66%);
}

html[data-theme="dark"] body::before {
  background:
    radial-gradient(900px 480px at 10% -10%, rgba(64, 105, 255, 0.18), transparent 62%),
    radial-gradient(720px 420px at 92% -4%, rgba(10, 155, 108, 0.1), transparent 66%);
}

::selection {
  background: var(--brand);
  color: #fff;
}

h1, h2, h3, h4, p, ul, ol { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
code, kbd, pre { font-family: var(--font-mono); }

:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
  border-radius: 4px;
}

.sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.icon {
  width: 18px;
  height: 18px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.shell {
  width: min(1180px, calc(100% - 48px));
  margin-inline: auto;
}

.shell--wide {
  width: min(1240px, calc(100% - 48px));
}

.skip-link {
  position: fixed;
  top: 10px;
  left: 50%;
  z-index: 200;
  padding: 9px 16px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--bg);
  font-size: 13px;
  transform: translate(-50%, -160%);
  transition: transform 0.2s ease;
}

.skip-link:focus-visible { transform: translate(-50%, 0); }

.noscript {
  width: min(1180px, calc(100% - 48px));
  margin: 16px auto 0;
  padding: 11px 14px;
  border: 1px solid var(--amber-line);
  border-radius: 10px;
  background: var(--amber-soft);
  color: var(--amber);
  font-size: 12.5px;
  line-height: 1.6;
}

/* --------------------------------------------------------------------------
   Header
   -------------------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(245, 246, 248, 0.78);
  border-bottom: 1px solid transparent;
  backdrop-filter: blur(16px) saturate(1.4);
  -webkit-backdrop-filter: blur(16px) saturate(1.4);
  transition: border-color 0.2s ease, background 0.2s ease;
}

html[data-theme="dark"] .site-header {
  background: rgba(8, 11, 20, 0.76);
}

.site-header.is-scrolled {
  border-bottom-color: var(--line);
}

.site-header__inner {
  height: var(--header-h);
  display: flex;
  align-items: center;
  gap: 20px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  flex: none;
}

.brand__mark {
  width: 31px;
  height: 31px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  color: #fff;
  background: linear-gradient(160deg, #4a73ff, var(--brand-strong));
  box-shadow: 0 6px 14px -6px rgba(43, 89, 255, 0.8);
}

.brand__mark .icon { width: 19px; height: 19px; stroke-width: 2; }

.brand__text {
  font-size: 16.5px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.brand__badge {
  margin-left: 2px;
  padding: 2px 6px;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 8.5px;
  font-weight: 600;
  letter-spacing: 0.1em;
  line-height: 1.3;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 2px;
}

.site-nav a {
  padding: 7px 11px;
  border-radius: 8px;
  color: var(--muted);
  font-size: 13.5px;
  transition: color 0.15s ease, background 0.15s ease;
}

.site-nav a:hover {
  color: var(--ink);
  background: var(--surface-3);
}

.header-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 8px;
}

.icon-btn {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
  color: var(--ink-2);
  cursor: pointer;
  transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease,
    transform 0.15s ease;
}

.icon-btn:hover {
  color: var(--ink);
  border-color: var(--line-strong);
  transform: translateY(-1px);
}

.icon-btn--sm {
  width: 30px;
  height: 30px;
  border-radius: 8px;
}

.icon-btn--sm .icon { width: 15px; height: 15px; }

.theme-toggle__sun { display: none; }
html[data-theme="dark"] .theme-toggle__sun { display: block; }
html[data-theme="dark"] .theme-toggle__moon { display: none; }

.ghost-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 36px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
  color: var(--ink-2);
  font-size: 12.5px;
  transition: border-color 0.15s ease, color 0.15s ease, transform 0.15s ease;
}

.ghost-btn:hover {
  color: var(--ink);
  border-color: var(--line-strong);
  transform: translateY(-1px);
}

.ghost-btn .icon { width: 14px; height: 14px; color: var(--muted); }

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero {
  position: relative;
  padding: 54px 0 62px;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, var(--grid) 1px, transparent 1px),
    linear-gradient(to bottom, var(--grid) 1px, transparent 1px);
  background-size: 62px 62px;
  -webkit-mask-image: radial-gradient(ellipse 78% 78% at 46% 8%, #000 12%, transparent 72%);
  mask-image: radial-gradient(ellipse 78% 78% at 46% 8%, #000 12%, transparent 72%);
  pointer-events: none;
}

.hero__inner {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.88fr);
  align-items: center;
  gap: 48px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.eyebrow--small { font-size: 10px; letter-spacing: 0.14em; }

.pulse-dot {
  position: relative;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--mint);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--mint) 15%, transparent);
}

.hero h1 {
  margin-top: 18px;
  font-size: clamp(42px, 5.1vw, 66px);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.035em;
}

.mark {
  position: relative;
  color: var(--brand);
  white-space: nowrap;
  background: linear-gradient(180deg, transparent 64%, var(--brand-wash) 64%);
  padding: 0 0.06em;
}

.lede {
  max-width: 580px;
  margin-top: 20px;
  color: var(--ink-2);
  font-size: 15.5px;
  line-height: 1.75;
}

.hero__facts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 20px;
  margin-top: 24px;
}

.hero__facts li {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 12.5px;
}

.hero__facts .icon {
  width: 14px;
  height: 14px;
  color: var(--mint);
  stroke-width: 2.4;
}

.hero__visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 430px;
}

.hero__visual::before {
  content: "";
  position: absolute;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  background: conic-gradient(
    from 210deg,
    rgba(43, 89, 255, 0.18),
    rgba(10, 155, 108, 0.14),
    rgba(43, 89, 255, 0.02),
    rgba(43, 89, 255, 0.18)
  );
  filter: blur(46px);
  opacity: 0.9;
}

.signal-card {
  position: relative;
  width: min(356px, 100%);
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background:
    radial-gradient(120% 100% at 0% 0%, rgba(74, 115, 255, 0.2), transparent 55%),
    linear-gradient(180deg, #101830, #0a1022);
  color: #e8eeff;
  box-shadow:
    0 50px 80px -40px rgba(10, 20, 60, 0.75),
    0 2px 0 rgba(255, 255, 255, 0.06) inset;
  transform: rotate(-2.2deg);
  transition: transform 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.signal-card:hover { transform: rotate(0deg) translateY(-3px); }

.signal-card__head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.win-dots { display: inline-flex; gap: 5px; }

.win-dots i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
}

.win-dots i:first-child { background: #ff6b6b; }
.win-dots i:nth-child(2) { background: #f5c451; }
.win-dots i:nth-child(3) { background: #45d483; }

.signal-card__file {
  flex: 1;
  color: rgba(232, 238, 255, 0.5);
  font-family: var(--font-mono);
  font-size: 10.5px;
}

.live-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 7px;
  border: 1px solid rgba(74, 222, 155, 0.28);
  border-radius: 999px;
  background: rgba(74, 222, 155, 0.1);
  color: #7bf0b6;
  font-family: var(--font-mono);
  font-size: 8.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.live-pill i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #4ade9b;
  box-shadow: 0 0 8px #4ade9b;
}

.signal-card__body {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 22px 18px 18px;
}

.signal-card__icon {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(150deg, rgba(74, 115, 255, 0.9), rgba(43, 89, 255, 0.5));
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: 0 12px 24px -12px rgba(74, 115, 255, 0.9);
  color: #fff;
}

.signal-card__icon .icon { width: 26px; height: 26px; stroke-width: 1.7; }

.signal-card__body strong {
  display: block;
  font-size: 19px;
  font-weight: 650;
  letter-spacing: -0.02em;
}

.signal-card__body span {
  display: block;
  margin-top: 2px;
  color: rgba(232, 238, 255, 0.5);
  font-family: var(--font-mono);
  font-size: 10.5px;
}

.signal-rows {
  margin: 0 18px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
}

.signal-rows > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 12px;
  font-size: 11.5px;
}

.signal-rows > div + div { border-top: 1px solid rgba(255, 255, 255, 0.06); }
.signal-rows span { color: rgba(232, 238, 255, 0.48); }

.signal-rows strong {
  color: rgba(232, 238, 255, 0.92);
  font-size: 11.5px;
  font-weight: 550;
}

.signal-rows .is-ok {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #7bf0b6;
}

.signal-rows .is-ok .icon { width: 13px; height: 13px; stroke-width: 2.4; }

.signal-card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px 16px;
  color: rgba(232, 238, 255, 0.4);
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.04em;
}

.signal-bars { display: inline-flex; align-items: flex-end; gap: 2px; height: 12px; }

.signal-bars i {
  width: 3px;
  border-radius: 1px;
  background: #4ade9b;
  opacity: 0.9;
}

.signal-bars i:nth-child(1) { height: 4px; }
.signal-bars i:nth-child(2) { height: 7px; }
.signal-bars i:nth-child(3) { height: 9px; }
.signal-bars i:nth-child(4) { height: 12px; }

.float-chip {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  box-shadow: var(--shadow-md);
  color: var(--ink-2);
  font-size: 11.5px;
  font-weight: 550;
  backdrop-filter: blur(8px);
  animation: float 7s ease-in-out infinite;
}

.float-chip .icon { width: 14px; height: 14px; color: var(--mint); }

.float-chip--top { top: 0; right: 0; }

.float-chip--bottom {
  bottom: 0;
  left: 0;
  animation-delay: -3.5s;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

/* --------------------------------------------------------------------------
   Workbench shell
   -------------------------------------------------------------------------- */

.workbench-section {
  position: relative;
  padding-bottom: 8px;
  scroll-margin-top: 84px;
}

.workbench {
  display: grid;
  grid-template-columns: minmax(0, 0.99fr) minmax(0, 1.01fr);
  gap: 18px;
  align-items: start;
}

.generator-form {
  min-width: 0;
  padding: 28px 30px 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
}

.form-intro {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 22px;
}

.form-intro h2 {
  margin-top: 8px;
  font-size: 22px;
  font-weight: 680;
  letter-spacing: -0.025em;
}

.local-stamp {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  flex: none;
  padding: 5px 9px;
  border: 1px solid color-mix(in srgb, var(--mint) 30%, transparent);
  border-radius: 999px;
  background: var(--mint-soft);
  color: var(--mint);
  font-family: var(--font-mono);
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.local-stamp .icon { width: 11px; height: 11px; stroke-width: 2.2; }

.form-section {
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.form-section + .form-section { margin-top: 24px; }

.section-head {
  display: flex;
  align-items: flex-start;
  gap: 11px;
}

.section-num {
  flex: none;
  margin-top: 1px;
  padding: 2px 7px;
  border-radius: 6px;
  background: var(--brand-soft);
  color: var(--brand-ink);
  font-family: var(--font-mono);
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 1.7;
}

.section-head h3 {
  font-size: 14.5px;
  font-weight: 650;
  letter-spacing: -0.01em;
}

.section-head p {
  margin-top: 2px;
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.55;
}


/* Protocol */

.protocol-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
  margin-top: 13px;
}

.protocol {
  position: relative;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  cursor: pointer;
  text-align: left;
  transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.protocol:hover { border-color: var(--line-strong); }

.protocol[aria-checked="true"] {
  border-color: var(--brand);
  background: color-mix(in srgb, var(--brand) 5%, var(--surface));
  box-shadow: 0 0 0 3px var(--brand-soft);
}

.protocol__glyph {
  flex: none;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--surface-3);
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
}

.protocol[aria-checked="true"] .protocol__glyph {
  background: var(--brand);
  color: #fff;
}

.protocol__text { min-width: 0; }

.protocol__text strong {
  display: block;
  font-size: 13px;
  font-weight: 650;
  line-height: 1.3;
}

.protocol__text small {
  display: block;
  margin-top: 1px;
  overflow: hidden;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 8.5px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.protocol__check {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 15px;
  height: 15px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--brand);
  color: #fff;
  opacity: 0;
  transform: scale(0.6);
  transition: opacity 0.15s ease, transform 0.15s ease;
}

.protocol__check .icon { width: 9px; height: 9px; stroke-width: 3; }
.protocol[aria-checked="true"] .protocol__check { opacity: 1; transform: scale(1); }


.field { display: block; }

.field__label {
  display: block;
  margin-bottom: 5px;
  color: var(--ink-2);
  font-size: 11.5px;
  font-weight: 550;
}

.field input,
.field textarea {
  width: 100%;
  padding: 9px 11px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--surface);
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 11.5px;
  line-height: 1.5;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.field textarea { min-height: 62px; resize: vertical; }

.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-soft);
}

.field input::placeholder,
.field textarea::placeholder { color: var(--faint); }

.field__hint {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 10.5px;
  line-height: 1.5;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  color: var(--brand);
  font-size: 11.5px;
  font-weight: 550;
  white-space: nowrap;
}

.text-link:hover {
  color: var(--brand-strong);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.text-link .icon {
  width: 11px;
  height: 11px;
  stroke-width: 2;
}

.server-fields {
  margin-top: 13px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background-color: var(--surface-2);
}

.server-fields .field + .field { margin-top: 12px; }
#dot-fields .field + .field { margin-top: 12px; }

.server-note {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  margin-top: 13px;
  padding-top: 11px;
  border-top: 1px dashed var(--line);
  color: var(--muted);
  font-size: 10.5px;
  line-height: 1.55;
}

.server-note .icon {
  width: 13px;
  height: 13px;
  margin-top: 1px;
}

.field__hint code {
  padding: 1px 4px;
  border-radius: 4px;
  background: var(--surface-3);
  font-size: 10px;
}

.field__hint .text-link { display: inline; font-size: 10.5px; }

.field-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 13px;
}

.advanced {
  margin-top: 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface-2);
}

.advanced summary {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  list-style: none;
  cursor: pointer;
  user-select: none;
}

.advanced summary::-webkit-details-marker { display: none; }

.advanced__title {
  color: var(--ink-2);
  font-size: 11.5px;
  font-weight: 550;
}

.advanced__hint { color: var(--faint); font-size: 10.5px; }

.advanced__chevron {
  width: 14px;
  height: 14px;
  margin-left: auto;
  color: var(--muted);
  transition: transform 0.2s ease;
}

.advanced[open] .advanced__chevron { transform: rotate(180deg); }

.advanced__body {
  padding: 0 12px 12px;
  border-top: 1px solid var(--line);
  padding-top: 10px;
}

/* Form actions */

.form-actions { margin-top: 22px; }

.form-alert {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  margin-bottom: 10px;
  padding: 9px 11px;
  border: 1px solid var(--amber-line);
  border-radius: 9px;
  background: var(--amber-soft);
  color: var(--amber);
  font-size: 11.5px;
  line-height: 1.5;
}

.form-alert .icon { width: 14px; height: 14px; margin-top: 1px; }

.primary-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  width: 100%;
  height: 47px;
  padding: 0 14px;
  border: 1px solid color-mix(in srgb, #000 8%, transparent);
  border-radius: 12px;
  background: linear-gradient(180deg, #3a66ff, #2b59ff);
  color: #fff;
  font-size: 13.5px;
  font-weight: 650;
  cursor: pointer;
  box-shadow:
    0 10px 22px -12px rgba(43, 89, 255, 0.85),
    0 1px 0 rgba(255, 255, 255, 0.2) inset;
  transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
}

.primary-btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.04);
  box-shadow:
    0 14px 26px -12px rgba(43, 89, 255, 0.9),
    0 1px 0 rgba(255, 255, 255, 0.2) inset;
}

.primary-btn:active { transform: translateY(0); }
.primary-btn .icon { width: 17px; height: 17px; stroke-width: 2; }

.primary-btn__meta {
  margin-left: auto;
  padding: 3px 7px;
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.16);
  font-family: var(--font-mono);
  font-size: 9.5px;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.primary-btn[aria-disabled="true"] {
  cursor: not-allowed;
  opacity: 0.55;
  box-shadow: none;
  transform: none;
  filter: none;
}

.form-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  margin-top: 10px;
  color: var(--faint);
  font-size: 10.5px;
}

.form-note .icon { width: 12px; height: 12px; }

/* --------------------------------------------------------------------------
   Preview
   -------------------------------------------------------------------------- */

.preview-pane {
  min-width: 0;
  padding: 0;
  align-self: start;
}

.preview {
  position: sticky;
  top: calc(var(--header-h) + 22px);
  display: flex;
  flex-direction: column;
  height: calc(100vh - var(--header-h) - 46px);
  min-height: 540px;
  max-height: 880px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
  box-shadow: var(--shadow-md);
  overflow: hidden;
}

.preview__top {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  border-bottom: 1px solid var(--line);
}

.tabs {
  display: flex;
  gap: 2px;
  padding: 3px;
  border-radius: 8px;
  background: var(--surface-3);
}

.tab {
  padding: 5px 9px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  font-size: 11px;
  font-weight: 550;
  line-height: 1.4;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.tab:hover { color: var(--ink-2); }

.tab.is-active {
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 1px 2px rgba(16, 24, 40, 0.08);
}

.preview__actions {
  display: flex;
  gap: 5px;
  margin-left: auto;
}

.file-bar {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 8px 13px;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}

.file-bar__dot {
  width: 6px;
  height: 6px;
  flex: none;
  border-radius: 50%;
  background: var(--mint);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--mint) 14%, transparent);
}

.file-bar__name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  color: var(--ink-2);
  font-family: var(--font-mono);
  font-size: 10px;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.badge {
  flex: none;
  padding: 2px 6px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--surface-3);
  color: var(--muted);
  font-size: 9px;
  font-weight: 550;
  line-height: 1.5;
}

.badge--warn {
  border-color: var(--amber-line);
  background: var(--amber-soft);
  color: var(--amber);
  font-family: var(--font-mono);
}

.file-bar__size {
  flex: none;
  color: var(--faint);
  font-family: var(--font-mono);
  font-size: 9px;
}

.code-scroll {
  flex: 1;
  min-height: 0;
  overflow: auto;
  background: var(--code-bg);
  scrollbar-width: thin;
  scrollbar-color: #2b3757 transparent;
}

.code-scroll::-webkit-scrollbar { width: 10px; height: 10px; }
.code-scroll::-webkit-scrollbar-thumb {
  border: 3px solid var(--code-bg);
  border-radius: 999px;
  background: #2b3757;
}
.code-scroll::-webkit-scrollbar-thumb:hover { background: #3b4a72; }

.code {
  margin: 0;
  padding: 16px 17px 28px;
  color: #c9d5f5;
  font-size: 12px;
  line-height: 1.72;
  tab-size: 2;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.code code { font: inherit; }

.tok-punct { color: #4f5f86; }
.tok-tag { color: #82a6ff; }
.tok-attr { color: #9fb0d0; }
.tok-key { color: #7fe0c3; }
.tok-str { color: #ffd580; }
.tok-num { color: #b7a4ff; }
.tok-comment { color: #5d6b8c; font-style: italic; }
.tok-host { color: #7fe0c3; font-weight: 600; }

.preview__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 13px;
  border-top: 1px solid var(--line);
  background: var(--surface);
}

.preview__note {
  display: flex;
  align-items: center;
  gap: 5px;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.4;
}

.preview__note .icon { width: 12px; height: 12px; flex: none; }
.preview__foot .text-link { font-size: 10.5px; flex: none; }
.preview__foot .text-link .icon { width: 12px; height: 12px; }

/* --------------------------------------------------------------------------
   Sections
   -------------------------------------------------------------------------- */

section[id] { scroll-margin-top: 84px; }

.install {
  margin-top: 84px;
  padding: 72px 0 76px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}

.section-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 40px;
  margin-bottom: 30px;
}

.section-header h2,
.why h2,
.faq h2 {
  margin-top: 10px;
  font-size: clamp(27px, 3.2vw, 36px);
  font-weight: 680;
  line-height: 1.2;
  letter-spacing: -0.03em;
}

.section-header__note {
  max-width: 390px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.step {
  position: relative;
  padding: 22px 20px 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--bg);
  overflow: hidden;
}

.step__num {
  position: absolute;
  top: 14px;
  right: 16px;
  color: var(--line-strong);
  font-family: var(--font-mono);
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1;
}

.step__icon {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 1px solid color-mix(in srgb, var(--brand) 18%, transparent);
  border-radius: 11px;
  background: var(--brand-soft);
  color: var(--brand);
}

.step__icon .icon { width: 19px; height: 19px; }

.step h3 {
  margin-top: 15px;
  font-size: 15px;
  font-weight: 650;
  letter-spacing: -0.01em;
}

.step p {
  margin-top: 7px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.65;
}

.step p code {
  padding: 1px 4px;
  border-radius: 4px;
  background: var(--surface-3);
  font-size: 10.5px;
}

.step__meta {
  display: inline-block;
  margin-top: 14px;
  color: var(--faint);
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.03em;
}

.install-note {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 16px;
  padding: 14px 16px;
  border: 1px dashed var(--line-strong);
  border-radius: 12px;
  background: var(--surface-2);
}

.install-note .icon {
  width: 15px;
  height: 15px;
  margin-top: 2px;
  color: var(--brand);
}

.install-note p {
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.7;
}

.install-note strong { color: var(--ink-2); font-weight: 600; }

/* Why */

.why { padding: 84px 0 88px; }

.why__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.92fr);
  gap: 56px;
  align-items: center;
}

.why__copy > p:not(.eyebrow) {
  max-width: 480px;
  margin-top: 16px;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.75;
}

.check-list {
  display: grid;
  gap: 9px;
  margin-top: 20px;
}

.check-list li {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  color: var(--ink-2);
  font-size: 12.5px;
}

.check-list .icon {
  width: 14px;
  height: 14px;
  margin-top: 3px;
  color: var(--mint);
  stroke-width: 2.4;
}

.privacy-compare {
  display: grid;
  gap: 10px;
}

.compare-card {
  padding: 18px 19px;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.compare-card--bad { opacity: 0.92; }

.compare-card--good {
  border-color: color-mix(in srgb, var(--mint) 28%, var(--line));
  background:
    radial-gradient(120% 130% at 100% 0%, color-mix(in srgb, var(--mint) 8%, transparent), transparent 60%),
    var(--surface);
}

.compare-card__tag {
  display: inline-block;
  padding: 2px 7px;
  border-radius: 5px;
  background: var(--surface-3);
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.06em;
}

.compare-card--good .compare-card__tag {
  background: var(--mint-soft);
  color: var(--mint);
}

.compare-card h3 {
  margin-top: 9px;
  font-size: 14.5px;
  font-weight: 650;
  letter-spacing: -0.01em;
}

.compare-card ul {
  display: grid;
  gap: 5px;
  margin-top: 9px;
}

.compare-card li {
  position: relative;
  padding-left: 13px;
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.6;
}

.compare-card li::before {
  content: "";
  position: absolute;
  top: 8px;
  left: 0;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--line-strong);
}

.compare-card--good li::before { background: var(--mint); }

/* FAQ */

.faq { padding: 0 0 96px; }

.faq__inner {
  display: grid;
  grid-template-columns: minmax(0, 0.78fr) minmax(0, 1.22fr);
  gap: 56px;
  align-items: start;
}

.faq__head { position: sticky; top: 100px; }

.faq__head > p:not(.eyebrow) {
  max-width: 320px;
  margin-top: 14px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.faq__head > .text-link { margin-top: 16px; font-size: 12px; }

.faq__list { border-top: 1px solid var(--line); }

.faq__item { border-bottom: 1px solid var(--line); }

.faq__item summary {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 17px 2px;
  list-style: none;
  cursor: pointer;
  color: var(--ink);
  font-size: 13.5px;
  font-weight: 560;
  line-height: 1.5;
  transition: color 0.15s ease;
}

.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary:hover { color: var(--brand); }

.faq__mark {
  position: relative;
  flex: none;
  width: 13px;
  height: 13px;
  margin-left: auto;
}

.faq__mark::before,
.faq__mark::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 11px;
  height: 1.5px;
  border-radius: 2px;
  background: var(--muted);
  transform: translate(-50%, -50%);
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.faq__mark::after { transform: translate(-50%, -50%) rotate(90deg); }
.faq__item[open] .faq__mark::after { transform: translate(-50%, -50%) rotate(0deg); opacity: 0; }

.faq__body { padding: 0 26px 18px 0; }

.faq__body p {
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.8;
}

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */

.site-footer {
  border-top: 1px solid var(--line);
  background: var(--surface);
}

.footer__main {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 40px;
  padding: 36px 0 26px;
}

.footer__brand p {
  max-width: 300px;
  margin-top: 10px;
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.65;
}

.footer__links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  padding-top: 4px;
}

.footer__links a {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  color: var(--muted);
  font-size: 11.5px;
}

.footer__links a:hover { color: var(--ink); }
.footer__links .icon { width: 11px; height: 11px; }

.footer__legal {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 16px 0 24px;
  border-top: 1px solid var(--line);
  color: var(--faint);
  font-size: 10.5px;
}

/* --------------------------------------------------------------------------
   Toast
   -------------------------------------------------------------------------- */

.toast {
  position: fixed;
  left: 50%;
  bottom: 26px;
  z-index: 120;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 11px 16px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  background: #0d1424;
  color: #eef2ff;
  box-shadow: 0 20px 40px -16px rgba(0, 0, 0, 0.6);
  font-size: 12px;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 14px);
  transition: opacity 0.22s ease, transform 0.22s ease;
}

.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }
.toast .icon { width: 15px; height: 15px; color: #4ade9b; stroke-width: 2.2; }

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (max-width: 1120px) {
  .hero__inner { gap: 28px; }
  .hero h1 { font-size: clamp(40px, 4.9vw, 56px); }
  .float-chip--top { right: -6px; }
  .generator-form { padding: 26px 24px 24px; }
  .preview-pane { padding: 0; }
}

@media (max-width: 980px) {
  .site-nav { display: none; }

  .hero { padding: 54px 0 60px; }
  .hero__inner { grid-template-columns: 1fr; }
  .hero__visual { display: none; }
  .lede { max-width: 620px; }

  .workbench { grid-template-columns: 1fr; gap: 14px; }
  .preview-pane { padding: 0; }
  .preview {
    position: static;
    height: auto;
    min-height: 0;
    max-height: none;
  }
  .code-scroll { height: 440px; flex: none; }

  .why__grid { gap: 34px; }
  .faq__inner { gap: 34px; }
}

@media (max-width: 860px) {
  .section-header { flex-direction: column; align-items: flex-start; gap: 14px; }
  .steps { grid-template-columns: 1fr; }
  .why__grid { grid-template-columns: 1fr; }
  .privacy-compare { grid-template-columns: 1fr 1fr; }
  .faq__inner { grid-template-columns: 1fr; }
  .faq__head { position: static; }
  .faq__head > p:not(.eyebrow) { max-width: 560px; }
}

@media (max-width: 720px) {
  .shell,
  .shell--wide { width: calc(100% - 32px); }

  :root { --header-h: 58px; }

  .ghost-btn span { display: none; }
  .ghost-btn { width: 36px; padding: 0; justify-content: center; }
  .ghost-btn .icon { width: 15px; height: 15px; }
  .brand__badge { display: none; }

  .hero { padding: 42px 0 46px; }
  .hero h1 { font-size: clamp(34px, 8.6vw, 46px); }
  .lede { margin-top: 16px; font-size: 14px; }
  .hero__facts { gap: 8px 14px; margin-top: 18px; }
  .hero__facts li { font-size: 11.5px; }

  .generator-form { padding: 20px 18px 20px; }
  .preview-pane { padding: 0; }

  .form-intro h2 { font-size: 19px; }
  .local-stamp { display: none; }
  .form-section { padding-top: 20px; }
  .form-section + .form-section { margin-top: 20px; }

  .field-grid { grid-template-columns: 1fr; }
  .server-fields { padding: 12px; }

  .preview__top { padding: 9px 10px; }
  .tab { padding: 5px 7px; font-size: 10.5px; }
  .file-bar { padding: 7px 10px; }
  .file-bar__name { font-size: 9px; }
  .code { font-size: 10.5px; padding: 14px 13px 24px; }
  .code-scroll { height: 380px; }
  .preview__foot { padding: 8px 10px; }

  .install { margin-top: 56px; padding: 52px 0 56px; }
  .why { padding: 56px 0 60px; }
  .faq { padding-bottom: 64px; }
  .privacy-compare { grid-template-columns: 1fr; }
  .section-header { margin-bottom: 22px; }

  .footer__main { flex-direction: column; gap: 22px; padding-top: 28px; }
  .footer__legal { flex-direction: column; gap: 6px; }
  .toast { bottom: 18px; width: max-content; max-width: calc(100% - 32px); }
}

@media (max-width: 420px) {
  .protocol-toggle { grid-template-columns: 1fr; }
  .preview__actions { gap: 3px; }
  .icon-btn--sm { width: 28px; height: 28px; }
  .tabs { padding: 2px; }
  .tab { padding: 5px 6px; font-size: 10px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}



