/* ============================================================
   Melta: quiet neutral system
   Inter for everything you read, JetBrains Mono for small UI detail,
   grey surfaces that follow the device's light/dark setting, and the
   ghost's orange as the only accent.
   ============================================================ */

@font-face { font-family: "Inter"; src: url("/assets/fonts/InterVF.woff2") format("woff2"); font-weight: 100 900; font-style: normal; font-display: swap; }
@font-face { font-family: "JetBrains Mono"; src: url("/assets/fonts/JetBrainsMonoVF.woff2") format("woff2"); font-weight: 100 800; font-style: normal; font-display: swap; }

:root {
  color-scheme: light dark;

  /* Surfaces */
  --bg: #ffffff;
  --bg-2: #fafafa;
  --card: #f4f4f4;
  --card-hover: #eeeeee;
  --panel: #ffffff;
  --line: #e5e5e5;
  --line-2: #d4d4d4;

  /* Text */
  --fg-strong: #0a0a0a;
  --fg: #1c1c1c;
  --fg-2: #474747;
  --fg-3: #5e5e5e;   /* 6.3:1 on white, 5.8:1 on card */
  --fg-4: #8c8c8c;   /* large or decorative text only */

  /* Accent: the ghost's orange */
  --primary: #ff7a2f;
  --primary-hover: #ff8c4a;
  --primary-ink: #1a0c03;
  --primary-soft: rgba(255, 122, 47, 0.14);
  --accent-text: #b4500f; /* orange as small text: 5.1:1 on white */

  /* Agent status, as the app shows it */
  --st-blocked: #d92d20;
  --st-working: #b54708;
  --st-done: #15803d;
  --st-blocked-soft: rgba(217, 45, 32, 0.1);
  --st-working-soft: rgba(181, 71, 8, 0.1);
  --st-done-soft: rgba(21, 128, 61, 0.1);

  --radius-sm: 6px;
  --radius: 10px;
  --radius-lg: 14px;
  --radius-pill: 999px;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.04), 0 1px 3px rgba(0, 0, 0, 0.04);
  --shadow-lg: 0 12px 32px -12px rgba(0, 0, 0, 0.18);
  --shot-shadow: drop-shadow(0 22px 34px rgba(0, 0, 0, 0.22));

  --sans: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --container: 1120px;
  --header-h: 60px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #080808;
    --bg-2: #0d0d0d;
    --card: #171717;
    --card-hover: #1d1d1d;
    --panel: #0a0a0a;
    --line: #262626;
    --line-2: #333333;
    --fg-strong: #ffffff;
    --fg: #e6e6e6;
    --fg-2: #bdbdbd;
    --fg-3: #9e9e9e;
    --fg-4: #6f6f6f;
    --primary-soft: rgba(255, 122, 47, 0.18);
    --accent-text: #ff9a5c;
    --st-blocked: #ff6b5e;
    --st-working: #ffb340;
    --st-done: #3ddc84;
    --st-blocked-soft: rgba(255, 107, 94, 0.14);
    --st-working-soft: rgba(255, 179, 64, 0.13);
    --st-done-soft: rgba(61, 220, 132, 0.12);
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 16px 40px -16px rgba(0, 0, 0, 0.8);
    --shot-shadow: drop-shadow(0 26px 40px rgba(0, 0, 0, 0.7));
  }
}

* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 16px); }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  min-height: 100dvh; font-family: var(--sans); font-size: 16px; line-height: 1.6;
  color: var(--fg); background: var(--bg);
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility;
  font-feature-settings: "cv11", "ss03"; overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
a, button, label { touch-action: manipulation; }
img, video, svg { display: block; max-width: 100%; }
img { height: auto; }
button, input, select, textarea { font: inherit; color: inherit; }
::selection { background: var(--primary-soft); color: var(--fg-strong); }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; border-radius: 4px; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 200; background: var(--fg-strong); color: var(--bg); padding: 8px 12px; border-radius: 8px; }
.skip:focus { left: 8px; }
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 24px; }
.mono { font-family: var(--mono); }
code, kbd, pre { font-family: var(--mono); }

/* ---------------- Header ---------------- */
.site-header {
  position: sticky; top: 0; z-index: 100; height: var(--header-h);
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  -webkit-backdrop-filter: saturate(160%) blur(14px); backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.header-inner { height: 100%; display: flex; align-items: center; gap: 28px; }
.brand { display: inline-flex; align-items: center; gap: 9px; font: 650 17px var(--mono); letter-spacing: -0.03em; color: var(--fg-strong); }
.brand img { width: 26px; height: 26px; border-radius: 7px; }
.nav { display: flex; align-items: center; gap: 24px; margin-left: auto; }
.nav a { font-size: 14px; color: var(--fg-3); transition: color 0.15s; }
.nav a:hover, .nav a.active { color: var(--fg-strong); }
.nav a.active { font-weight: 550; }
.header-cta { flex: none; }
.nav-toggle { display: none; }
@media (max-width: 800px) {
  .header-inner { gap: 12px; }
  .nav-toggle {
    display: inline-flex; flex-direction: column; justify-content: center; gap: 5px;
    width: 40px; height: 40px; padding: 0 11px; border: 1px solid var(--line); border-radius: var(--radius);
    background: transparent; cursor: pointer;
  }
  .nav-toggle span { display: block; height: 1.5px; background: var(--fg-strong); border-radius: 2px; transition: transform 0.25s var(--ease); }
  .site-header.open .nav-toggle span:nth-child(1) { transform: translateY(3.25px) rotate(45deg); }
  .site-header.open .nav-toggle span:nth-child(2) { transform: translateY(-3.25px) rotate(-45deg); }
  .header-cta { margin-left: auto; }
  .nav {
    position: absolute; top: var(--header-h); left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0; margin: 0;
    padding: 6px 24px 14px; background: var(--bg); border-bottom: 1px solid var(--line); box-shadow: var(--shadow-lg);
    opacity: 0; transform: translateY(-6px); pointer-events: none; visibility: hidden;
    transition: opacity 0.2s ease, transform 0.25s var(--ease), visibility 0s linear 0.25s;
  }
  .site-header.open .nav { opacity: 1; transform: none; pointer-events: auto; visibility: visible; transition: opacity 0.2s ease, transform 0.25s var(--ease); }
  .nav a { display: flex; align-items: center; min-height: 48px; font-size: 16px; color: var(--fg-2); border-bottom: 1px solid var(--line); }
  .nav a:last-child { border-bottom: 0; }
}

/* ---------------- Buttons ---------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 40px; padding: 0 16px; border-radius: 8px; border: 1px solid transparent;
  font-size: 15px; font-weight: 550; line-height: 1; white-space: nowrap; cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s, opacity 0.15s;
}
.btn svg { width: 17px; height: 17px; flex: none; }
.btn-sm { height: 34px; padding: 0 13px; font-size: 14px; border-radius: 7px; }
.btn-lg { height: 46px; padding: 0 20px; font-size: 15.5px; }
.btn-invert { background: var(--fg-strong); color: var(--bg); }
.btn-invert:hover { opacity: 0.86; }
.btn-outline { background: transparent; color: var(--fg-strong); border-color: var(--line-2); }
.btn-outline:hover { background: var(--card); }
.btn-primary { background: var(--primary); color: var(--primary-ink); }
.btn-primary:hover { background: var(--primary-hover); }
.btn:disabled { opacity: 0.5; cursor: default; }
.btn .soon { font: 500 10.5px var(--mono); letter-spacing: 0.04em; text-transform: uppercase; padding: 2px 6px; border-radius: var(--radius-pill); background: var(--card); color: var(--fg-3); }
.text-link { color: var(--fg-strong); font-weight: 550; display: inline-flex; align-items: center; gap: 6px; }
.text-link:hover { color: var(--accent-text); }

/* ---------------- Sections ---------------- */
.section { padding: 64px 0 0; }
.section:last-of-type { padding-bottom: 64px; }
.sec-num { font-family: var(--mono); font-size: 13px; color: var(--fg-4); margin-bottom: 14px; }
.sec-title { font-size: clamp(1.75rem, 3.6vw, 2.6rem); line-height: 1.12; letter-spacing: -0.028em; font-weight: 600; color: var(--fg-strong); max-width: 21em; text-wrap: balance; }
.sec-title span { color: var(--fg-4); }
.sec-lead { margin-top: 18px; max-width: 40em; font-size: 17px; line-height: 1.6; color: var(--fg-3); text-wrap: pretty; }
.sec-foot { margin-top: 24px; color: var(--fg-3); font-size: 15px; }
.sec-foot a, .inline-link { color: var(--fg-strong); text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 3px; }
.sec-foot a:hover, .inline-link:hover { text-decoration-color: currentColor; }

/* ---------------- Hero ---------------- */
.hero { padding: 56px 0 0; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr); }
.hero-title { font-size: clamp(2.5rem, 6.2vw, 4.3rem); line-height: 1.02; letter-spacing: -0.04em; font-weight: 600; color: var(--fg-strong); text-wrap: balance; max-width: 13em; }
.hero-title span { color: var(--fg-4); }
.hero-sub { margin-top: 24px; max-width: 36em; font-size: clamp(17px, 1.6vw, 19px); line-height: 1.6; color: var(--fg-3); text-wrap: pretty; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 32px; }
.hero-note { margin-top: 18px; font-size: 13.5px; color: var(--fg-3); display: flex; flex-wrap: wrap; gap: 6px 16px; }
.hero-note span { display: inline-flex; align-items: center; gap: 6px; }
.hero-note svg { width: 14px; height: 14px; color: var(--accent-text); }

/* Hero scene: your computer (Herdr in a terminal) and your phone (Melta) */
.scene { position: relative; margin-top: 52px; padding-right: 230px; }
.window { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 10px; box-shadow: var(--shadow-lg); }
.window-bar { display: flex; align-items: center; gap: 7px; padding: 4px 6px 12px; }
.window-bar i { width: 10px; height: 10px; border-radius: 50%; background: var(--line-2); }
.window-url { margin: 0 auto; font-family: var(--mono); font-size: 12px; color: var(--fg-4); padding: 4px 14px; background: var(--panel); border: 1px solid var(--line); border-radius: 7px; }
.term { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; display: grid; grid-template-columns: 210px minmax(0, 1fr); min-height: 380px; overflow: hidden; font-family: var(--mono); font-size: 12.5px; line-height: 1.6; }
.term-side { border-right: 1px solid var(--line); background: var(--bg-2); padding: 14px 0; min-width: 0; }
.term-ws { padding: 0 14px; margin: 10px 0 4px; font-size: 10.5px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--fg-4); }
.term-ws:first-child { margin-top: 0; }
.term-pane { display: flex; align-items: center; gap: 8px; padding: 4px 14px; color: var(--fg-2); white-space: nowrap; overflow: hidden; }
.term-pane .t { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.term-pane.cur { background: var(--card); color: var(--fg-strong); box-shadow: inset 2px 0 0 var(--primary); }
.term-main { padding: 16px 20px 18px; min-width: 0; color: var(--fg-2); display: flex; flex-direction: column; }
.term-main p { white-space: pre-wrap; overflow-wrap: anywhere; }
.term-main .u { color: var(--fg-strong); }
.term-main .dim { color: var(--fg-4); }
.term-main .add { color: var(--st-done); }
.term-main .del { color: var(--st-blocked); }
.term-main .acc { color: var(--accent-text); }
.term-ask { margin-top: auto; border: 1px solid var(--line-2); border-radius: 8px; padding: 12px 14px; }
.term-ask b { color: var(--fg-strong); font-weight: 600; }
.term-ask .sel { color: var(--accent-text); }
.term-status { display: flex; gap: 14px; margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--line); font-size: 11px; color: var(--fg-4); }
.scene-phone { position: absolute; right: 0; bottom: -28px; width: 256px; }
.scene-phone img { width: 100%; filter: var(--shot-shadow); }
.scene-cap { position: absolute; left: 0; right: 0; bottom: -64px; display: flex; justify-content: space-between; font: 500 12px var(--mono); color: var(--fg-4); }
.scene-cap span:last-child { width: 256px; text-align: center; }
.scene { margin-bottom: 64px; }

/* Status dots + pills (shared by the scene and the mockups) */
.dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; flex: none; background: var(--fg-4); }
.dot.blocked { background: var(--st-blocked); box-shadow: 0 0 0 3px var(--st-blocked-soft); }
.dot.working { background: var(--st-working); }
.dot.done { background: var(--st-done); }
.pill { font: 500 10.5px var(--mono); padding: 2px 7px; border-radius: var(--radius-pill); white-space: nowrap; flex: none; background: var(--card); color: var(--fg-3); }
.pill.blocked { background: var(--st-blocked-soft); color: var(--st-blocked); }
.pill.working { background: var(--st-working-soft); color: var(--st-working); }
.pill.done { background: var(--st-done-soft); color: var(--st-done); }
.pill.acc { background: var(--primary-soft); color: var(--accent-text); }

/* ---------------- Feature cards with mini mockups ---------------- */
.fgrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 36px; }
.fcard { background: var(--card); border-radius: var(--radius-lg); padding: 28px 28px 30px; display: flex; flex-direction: column; min-width: 0; }
.fcard > h3 { font-size: 18px; line-height: 1.3; font-weight: 600; letter-spacing: -0.015em; color: var(--fg-strong); }
.fcard > p { margin-top: 8px; font-size: 15.5px; line-height: 1.55; color: var(--fg-3); }
.mock {
  position: relative; margin: 0 0 26px; height: 196px;
  background: var(--panel); border: 1px solid var(--line); border-radius: 12px;
  padding: 16px; overflow: hidden; font-size: 13px; line-height: 1.45; color: var(--fg);
}
.mock-center { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.m-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-width: 0; }
.m-mono { font-family: var(--mono); font-size: 11.5px; color: var(--fg-3); }
.m-tag { font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--fg-3); }
.m-input { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border: 1px solid var(--line-2); border-radius: 9px; font-size: 14px; color: var(--fg-strong); }
.m-input svg { width: 16px; height: 16px; color: var(--fg-3); flex: none; }
.m-caret { display: inline-block; width: 1.5px; height: 16px; background: var(--primary); margin-left: -8px; animation: caret 1.1s steps(1) infinite; }
@keyframes caret { 50% { opacity: 0; } }
.m-group { display: flex; align-items: center; gap: 8px; margin: 12px 0 6px; font: 500 10.5px var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--fg-3); }
.m-group b { font-weight: 500; color: var(--fg-4); }
.m-list { list-style: none; display: grid; }
.m-list li { display: flex; align-items: center; gap: 10px; padding: 7px 0; border-bottom: 1px solid var(--line); min-width: 0; }
.m-list li:last-child { border-bottom: 0; }
.m-list .t { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.m-list .t small { color: var(--fg-3); font-size: 12px; }
.m-chat { display: grid; gap: 8px; }
.m-bub { justify-self: end; max-width: 85%; background: var(--primary); color: var(--primary-ink); border-radius: 12px 12px 4px 12px; padding: 7px 11px; font-size: 12.5px; line-height: 1.4; }
.m-say { font-size: 12.5px; line-height: 1.45; color: var(--fg); }
.m-tool { display: flex; align-items: center; gap: 8px; font: 500 11.5px var(--mono); color: var(--fg-2); background: var(--card); border-radius: 8px; padding: 7px 10px; min-width: 0; }
.m-tool .t { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.m-tool .add { color: var(--st-done); }
.m-tool .del { color: var(--st-blocked); }
.m-ask { border: 1px solid var(--line-2); border-radius: 10px; padding: 12px; }
.m-ask p { font-size: 12.5px; color: var(--fg); margin-top: 6px; }
.m-ask code { display: block; margin-top: 8px; font-size: 11.5px; background: var(--card); border-radius: 6px; padding: 6px 8px; color: var(--fg-strong); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.m-btns { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 8px; margin-top: 12px; }
.m-btns span { display: grid; place-items: center; height: 32px; border-radius: 8px; font-size: 13px; font-weight: 600; }
.m-btns .yes { background: var(--fg-strong); color: var(--bg); }
.m-btns .no { border: 1px solid var(--line-2); color: var(--fg-strong); }
.m-notif { display: flex; gap: 10px; padding: 10px 12px; border-radius: 12px; background: var(--card); text-align: left; width: 100%; }
.m-notif img { width: 28px; height: 28px; border-radius: 7px; flex: none; }
.m-notif .b { min-width: 0; flex: 1; }
.m-notif b { font-size: 12.5px; color: var(--fg-strong); font-weight: 600; }
.m-notif p { font-size: 12.5px; line-height: 1.35; color: var(--fg-2); }
.m-acts { display: flex; gap: 6px; margin-top: 8px; }
.m-acts span { flex: 1; text-align: center; font-size: 11.5px; font-weight: 600; padding: 5px 0; border-radius: 7px; background: var(--panel); color: var(--fg-strong); }
.m-stack .m-notif + .m-notif { margin-top: 8px; transform: scale(0.95); opacity: 0.5; }
.m-keys { display: flex; gap: 5px; overflow: hidden; }
.m-key svg { width: 14px; height: 14px; }
.m-key { display: inline-grid; place-items: center; flex: none; min-width: 34px; height: 30px; padding: 0 8px; border-radius: 7px; background: var(--card); border: 1px solid var(--line); font: 500 11.5px var(--mono); color: var(--fg-2); }
.m-key.big { background: var(--primary); border-color: var(--primary); color: var(--primary-ink); font-weight: 600; }
.m-key.on { border-color: var(--primary); color: var(--accent-text); background: var(--primary-soft); }
.m-term { font: 11.5px/1.75 var(--mono); color: var(--fg-2); white-space: pre; overflow: hidden; margin-bottom: 12px; }
.m-term b { color: var(--fg-strong); font-weight: 500; }
.m-term .acc { color: var(--accent-text); }
.m-term .ok { color: var(--st-done); }
.m-swap .m-key { font-size: 16px; min-width: 38px; height: 34px; }
.m-swap { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; width: 100%; }
.m-panecard { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; text-align: left; min-width: 0; }
.m-panecard.cur { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-soft); }
.m-panecard b { display: block; font-size: 12.5px; color: var(--fg-strong); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.m-panecard span { font: 500 10.5px var(--mono); color: var(--fg-3); }
.m-cmds { list-style: none; display: grid; gap: 2px; margin-top: 10px; }
.m-cmds li { display: flex; gap: 12px; padding: 6px 8px; border-radius: 7px; font-size: 12.5px; color: var(--fg-3); min-width: 0; }
.m-cmds li code { flex: none; width: 76px; color: var(--fg-strong); font-size: 12px; }
.m-cmds li span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.m-cmds li.on { background: var(--card); }
.m-seg { display: inline-flex; padding: 3px; border-radius: 9px; background: var(--card); gap: 2px; }
.m-seg span { padding: 6px 16px; border-radius: 7px; font-size: 13px; color: var(--fg-3); }
.m-seg span.on { background: var(--panel); color: var(--fg-strong); font-weight: 600; box-shadow: var(--shadow); }
.m-link { display: flex; align-items: center; gap: 10px; width: 100%; padding: 11px 12px; border: 1px solid var(--line-2); border-radius: 10px; text-align: left; }
.m-link svg { width: 16px; height: 16px; color: var(--fg-3); flex: none; }
.m-link .t { flex: 1; min-width: 0; font: 500 12px var(--mono); color: var(--fg-strong); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.m-retry { display: flex; align-items: center; gap: 8px; font: 500 11.5px var(--mono); color: var(--fg-3); }
.m-bar { height: 4px; border-radius: 4px; background: var(--card); overflow: hidden; width: 100%; margin-top: 12px; }
.m-bar i { display: block; height: 100%; width: 62%; background: var(--primary); border-radius: 4px; }

/* ---------------- Screens gallery ---------------- */
.shots { --gut: max(24px, calc((100vw - var(--container)) / 2 + 24px)); display: flex; gap: 16px; overflow-x: auto; margin-top: 36px; padding: 0 var(--gut) 12px; scroll-padding-inline: var(--gut); scroll-snap-type: x proximity; scrollbar-width: thin; -webkit-overflow-scrolling: touch; }
.shot { flex: 0 0 min(250px, 68vw); margin: 0; scroll-snap-align: start; }
.shot-frame { background: var(--card); border-radius: 20px; padding: 18px 14px 0; display: flex; justify-content: center; overflow: hidden; aspect-ratio: 5 / 7; }
.shot-frame img { width: 100%; max-width: 214px; height: auto; align-self: flex-start; }
.shot figcaption { padding: 14px 4px 0; font-size: 14.5px; line-height: 1.5; color: var(--fg-3); }
@media (min-width: 1100px) { .shots { overflow: visible; padding-bottom: 0; } .shot { flex: 1 1 0; min-width: 0; } }
.shot figcaption b { display: block; font-weight: 600; color: var(--fg-strong); margin-bottom: 2px; }

/* ---------------- Steps ---------------- */
.steps-grid { display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 56px; margin-top: 36px; align-items: start; }
.steps { list-style: none; display: grid; gap: 12px; counter-reset: step; }
.step { background: var(--card); border-radius: var(--radius-lg); padding: 24px 26px; counter-increment: step; display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 14px; }
.step > div { min-width: 0; }
.step::before { content: counter(step, decimal-leading-zero); font: 500 13px var(--mono); color: var(--fg-4); padding-top: 3px; }
.step h3 + p { margin-top: 4px; }
.step h3 { font-size: 17px; font-weight: 600; color: var(--fg-strong); letter-spacing: -0.01em; }
.step p { font-size: 15px; color: var(--fg-3); }
.step p + p { margin-top: 8px; }
.step a { color: var(--fg-strong); text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 3px; }
.step .code { margin-top: 12px; }
.steps-shot img { width: 100%; filter: var(--shot-shadow); }
.code { display: block; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; font: 12.5px/1.6 var(--mono); color: var(--fg); overflow-x: auto; white-space: pre-wrap; word-break: break-all; }
.code .p { color: var(--fg-4); user-select: none; }

/* ---------------- Split: privacy ---------------- */
.split-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 64px; align-items: center; }
.checks { list-style: none; display: grid; gap: 18px; margin-top: 30px; }
.checks li { display: grid; grid-template-columns: 22px 1fr; gap: 12px; align-items: start; }
.checks svg { width: 18px; height: 18px; margin-top: 3px; color: var(--accent-text); }
.checks b { display: block; font-weight: 600; color: var(--fg-strong); }
.checks span { color: var(--fg-3); font-size: 15.5px; }
.checks a { color: var(--fg-strong); text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 3px; }
.flow { background: var(--card); border-radius: var(--radius-lg); padding: 28px; display: grid; gap: 14px; }
.flow-node { display: flex; align-items: center; gap: 12px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; }
.flow-node svg { width: 22px; height: 22px; color: var(--fg-2); flex: none; }
.flow-node b { display: block; font-size: 15px; font-weight: 600; color: var(--fg-strong); }
.flow-node span { font-size: 13px; color: var(--fg-3); }
.flow-node.dim { border-style: dashed; }
.flow-edge { display: flex; align-items: center; gap: 10px; padding-left: 26px; font: 500 11.5px var(--mono); color: var(--fg-3); }
.flow-edge::before { content: ""; width: 1px; height: 26px; background: var(--line-2); }
.flow-edge.main { color: var(--accent-text); }
.flow-edge.main::before { width: 2px; background: var(--primary); }

/* ---------------- Compare ---------------- */
.compare-wrap { margin-top: 36px; border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; }
.compare { width: 100%; border-collapse: collapse; font-size: 15px; }
.compare th, .compare td { padding: 14px 18px; text-align: left; vertical-align: top; line-height: 1.45; border-bottom: 1px solid var(--line); }
.compare tbody tr:last-child th, .compare tbody tr:last-child td { border-bottom: 0; }
.compare thead th { font-size: 13px; font-weight: 600; color: var(--fg-3); background: var(--bg-2); }
.compare thead th.us { color: var(--fg-strong); }
.compare tbody th[scope="row"] { font-weight: 500; color: var(--fg-strong); width: 26%; }
.compare td { color: var(--fg-2); }
.compare td.us { color: var(--fg-strong); background: color-mix(in srgb, var(--primary) 5%, transparent); }
.compare-note { margin-top: 16px; font-size: 13.5px; line-height: 1.6; color: var(--fg-3); max-width: 60em; }
.compare-note a { color: var(--fg-strong); text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 3px; }
.hub-links { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 20px; }
.hub-link { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 18px; border: 1px solid var(--line); border-radius: var(--radius-lg); font-size: 15px; font-weight: 550; color: var(--fg-strong); transition: background 0.15s, border-color 0.15s; }
.hub-link:hover { background: var(--card); border-color: var(--line-2); }
.hub-link span { color: var(--fg-4); font-weight: 400; }
@media (max-width: 720px) {
  .compare th, .compare td { padding: 10px; font-size: 13px; }
  .compare tbody th[scope="row"] { width: 30%; }
}

/* ---------------- Tools strip ---------------- */
.tool-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-top: 32px; }
.tool-card { display: flex; flex-direction: column; gap: 6px; padding: 20px; background: var(--card); border-radius: var(--radius-lg); transition: background 0.15s; min-width: 0; }
.tool-card:hover { background: var(--card-hover); }
.tool-card b { font-size: 15.5px; font-weight: 600; color: var(--fg-strong); letter-spacing: -0.01em; }
.tool-card span { font-size: 14px; color: var(--fg-3); line-height: 1.5; }
.tool-card .m-mono { margin-bottom: 6px; color: var(--fg-4); }

/* ---------------- FAQ ---------------- */
.faq { margin-top: 32px; max-width: 820px; border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-item summary { cursor: pointer; list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 20px 0; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; font-size: 20px; font-weight: 300; line-height: 1; color: var(--fg-3); flex: none; transition: transform 0.2s ease; }
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item summary h3 { font-size: 16.5px; font-weight: 550; line-height: 1.4; color: var(--fg-strong); }
.faq-item > div { padding: 0 0 18px; color: var(--fg-3); line-height: 1.65; max-width: 44em; }
.faq-item > div a { color: var(--fg-strong); text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 3px; }
.faq-item > div code { font-size: 0.88em; background: var(--card); border-radius: 5px; padding: 1px 5px; }

/* ---------------- Final CTA ---------------- */
.cta-final { text-align: center; padding: 64px 0 72px; }
.cta-final .sec-title { margin: 0 auto; }
.cta-final p { margin: 18px auto 0; max-width: 34em; color: var(--fg-3); font-size: 17px; }
.cta-final .hero-actions { justify-content: center; }
/* Waitlist form in the closing CTA */
.waitlist { margin: 26px auto 0; max-width: 520px; display: grid; gap: 12px; justify-items: center; }
.waitlist-row { display: flex; width: 100%; gap: 8px; }
.waitlist-row input { flex: 1; min-width: 0; min-height: 46px; padding: 9px 14px; border: 1px solid var(--line-2); border-radius: 10px; background: var(--panel); font-size: 16px; color: var(--fg-strong); }
.waitlist-row input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-soft); }
.waitlist-row .btn { flex: none; white-space: nowrap; }
.waitlist-platform { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 18px; margin: 0; padding: 0; border: 0; font-size: 14.5px; color: var(--fg-3); }
.waitlist-platform label { display: inline-flex; align-items: center; gap: 6px; min-height: 32px; cursor: pointer; }
.waitlist-platform input { accent-color: var(--primary); width: 16px; height: 16px; margin: 0; }
.waitlist .msg { width: 100%; text-align: left; }
.waitlist-hero { margin: 32px 0 0; max-width: 520px; justify-items: start; }
.hero-links { margin: 14px 0 0; display: flex; flex-wrap: wrap; gap: 10px; font-size: 15px; color: var(--fg-4); }
.hero-links a { color: var(--fg-2); text-decoration: none; border-bottom: 1px solid var(--line-2); }
.hero-links a:hover { color: var(--fg-strong); border-color: var(--fg-strong); }
@media (max-width: 480px) { .waitlist-row { flex-direction: column; } .waitlist-row .btn { width: 100%; } }

/* ---------------- Footer ---------------- */
.site-footer { border-top: 1px solid var(--line); padding: 56px 0 32px; font-size: 14px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr repeat(4, 1fr); gap: 28px; }
.footer-brand p { margin-top: 12px; max-width: 22em; color: var(--fg-3); line-height: 1.55; }
.footer-col h2 { font-size: 13px; font-weight: 600; color: var(--fg-strong); margin-bottom: 14px; }
.footer-col ul { list-style: none; display: grid; gap: 9px; }
.footer-col a { color: var(--fg-3); transition: color 0.15s; }
.footer-col a:hover { color: var(--fg-strong); }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; margin-top: 48px; padding-top: 22px; border-top: 1px solid var(--line); color: var(--fg-4); font-size: 13px; }
.footer-bottom a { color: var(--fg-3); }
@media (max-width: 1000px) { .footer-grid { grid-template-columns: repeat(2, 1fr); } .footer-brand { grid-column: span 2; } }

/* ---------------- Responsive (landing) ---------------- */
@media (max-width: 1060px) {
  .scene { padding-right: 190px; }
  .scene-phone { width: 220px; }
  .scene-cap span:last-child { width: 220px; }
}
@media (max-width: 980px) {
  .fgrid { grid-template-columns: repeat(2, 1fr); }
  .tool-cards { grid-template-columns: repeat(2, 1fr); }
  .split-grid { grid-template-columns: 1fr; gap: 36px; }
  .steps-grid { grid-template-columns: 1fr; gap: 36px; }
  .steps-shot { justify-self: center; width: min(260px, 70vw); }
  .hub-links { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .scene { padding-right: 0; display: flex; justify-content: center; }
  .scene .window, .scene-cap { display: none; }
  .scene { margin-bottom: 0; }
  .scene-phone { position: static; width: min(280px, 74vw); }
}
@media (max-width: 640px) {
  .container { padding: 0 16px; }
  .section { padding-top: 48px; }
  .section:last-of-type { padding-bottom: 48px; }
  .hero { padding-top: 36px; }
  .scene { margin-top: 40px; }
  .hero-actions .btn { flex: 1 1 auto; }
  .fgrid, .tool-cards { grid-template-columns: 1fr; }
  .fcard { padding: 20px 20px 24px; }
  .mock { height: auto; min-height: 150px; margin-bottom: 22px; }
  .step { padding: 20px; grid-template-columns: 1fr; gap: 6px; }
  .flow { padding: 18px; }
  .shots { padding: 0 16px 12px; }
  .cta-final { padding: 48px 0 56px; }
}
@media (prefers-reduced-motion: reduce) {
  .m-caret { animation: none; }
  .nav, .nav-toggle span, .faq-item summary::after { transition: none !important; }
}

/* ============================================================
   Inner pages: blog, docs, tools, legal
   ============================================================ */
.crumbs { display: flex; flex-wrap: wrap; gap: 6px; font-family: var(--mono); font-size: 12px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--fg-3); margin-bottom: 16px; }
.crumbs a { color: var(--fg-3); }
.crumbs a:hover { color: var(--fg-strong); }
.crumbs span[aria-hidden] { color: var(--fg-4); }

.page-head { max-width: 760px; }
.page-head h1 { font-size: clamp(32px, 5vw, 46px); line-height: 1.1; letter-spacing: -0.032em; font-weight: 600; color: var(--fg-strong); text-wrap: balance; }
.page-head .lead { margin-top: 16px; font-size: clamp(17px, 2vw, 19px); line-height: 1.55; color: var(--fg-3); text-wrap: pretty; }
.page-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; margin-top: 20px; font-size: 13.5px; color: var(--fg-3); }
.page-meta .sep { color: var(--fg-4); }

/* Blog index */
.blog-main { padding-top: 48px; padding-bottom: 88px; }
.blog-masthead { margin: 0 0 28px; padding: 0 0 28px; border-bottom: 1px solid var(--line); }
.blog-masthead h1 { font-size: clamp(34px, 5vw, 50px); line-height: 1.05; letter-spacing: -0.035em; font-weight: 600; color: var(--fg-strong); margin: 0 0 14px; }
.blog-masthead p { margin: 0; max-width: 34em; font-size: 17.5px; line-height: 1.55; color: var(--fg-3); }
.blog-masthead p a { color: var(--fg-strong); text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 3px; }
.hub-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 24px; }
.hub-tabs button, .hub-tabs a { font-size: 13.5px; font-weight: 500; color: var(--fg-3); padding: 6px 12px; border-radius: 7px; border: 1px solid var(--line); background: transparent; cursor: pointer; transition: color 0.15s, background 0.15s, border-color 0.15s; }
.hub-tabs button:hover, .hub-tabs a:hover { color: var(--fg-strong); border-color: var(--line-2); }
.hub-tabs .on { color: var(--fg-strong); background: var(--card); border-color: var(--card); }
.post-rows { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 0; padding: 0; list-style: none; }
.post-rows > li { display: flex; min-width: 0; }
.post-rows > li:has(.post-row-featured) { grid-column: span 2; }
.post-row { display: flex; flex-direction: column; width: 100%; padding: 22px 22px 24px; background: var(--card); border-radius: var(--radius-lg); transition: background 0.15s; }
.post-row:hover { background: var(--card-hover); }
.post-row h2 { margin: 0 0 8px; font-size: 17.5px; line-height: 1.32; letter-spacing: -0.018em; font-weight: 600; color: var(--fg-strong); text-wrap: balance; transition: color 0.15s; }
.post-row p { margin: 0; font-size: 14.5px; line-height: 1.55; color: var(--fg-3); }
.post-row:hover h2 { color: var(--accent-text); }
.post-row p.post-row-meta { display: flex; flex-wrap: wrap; gap: 4px 10px; font-size: 12.5px; line-height: 1.4; color: var(--fg-3); margin: 0 0 10px; max-width: none; }
.post-row-meta .kicker { font-family: var(--mono); font-size: 11.5px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent-text); }
.post-row-featured { justify-content: flex-end; min-height: 220px; }
.post-row-featured h2 { font-size: clamp(22px, 2.8vw, 28px); line-height: 1.2; letter-spacing: -0.026em; }
.post-row-featured p { font-size: 15.5px; max-width: 40em; }
.chip { display: inline-flex; align-items: center; height: 32px; padding: 0 13px; border-radius: var(--radius-pill); border: 1px solid var(--line); background: transparent; font-size: 13.5px; color: var(--fg-2); cursor: pointer; transition: background 0.15s, border-color 0.15s, color 0.15s; }
.chip:hover { border-color: var(--line-2); color: var(--fg-strong); }
.chip.on { border-color: var(--primary); color: var(--accent-text); background: var(--primary-soft); }
@media (max-width: 980px) { .post-rows { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .post-rows { grid-template-columns: 1fr; } .post-rows > li:has(.post-row-featured) { grid-column: span 1; } .post-row-featured { min-height: 0; } .blog-main { padding-top: 32px; } }

/* Article (blog posts, legal pages) */
.article-main { padding-top: 56px; padding-bottom: 88px; }
.article { max-width: 720px; margin: 0 auto; }
.article .page-meta { padding-bottom: 24px; border-bottom: 1px solid var(--line); }
.article-head { margin: 0 0 32px; }
.article-head h1 { font-size: clamp(32px, 5vw, 46px); line-height: 1.1; letter-spacing: -0.032em; font-weight: 600; color: var(--fg-strong); margin: 0 0 16px; text-wrap: balance; }
.article-dek { font-size: clamp(17px, 2vw, 19.5px); line-height: 1.55; color: var(--fg-3); margin: 0 0 22px; text-wrap: pretty; }
.article-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; font-size: 13.5px; color: var(--fg-3); padding-bottom: 24px; border-bottom: 1px solid var(--line); }
.article-meta strong { color: var(--fg-strong); font-weight: 550; }
.article-meta .dot { color: var(--fg-4); }
.article-toc { margin: 0 0 40px; padding: 20px 22px; background: var(--card); border-radius: var(--radius-lg); }
.article-toc-title { margin: 0 0 10px; font: 500 11.5px var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--fg-3); }
.article-toc ol { margin: 0; padding-left: 20px; columns: 2; column-gap: 32px; font-size: 14.5px; line-height: 1.45; }
.article-toc li { margin: 0 0 7px; break-inside: avoid; }
.article-toc li::marker { color: var(--fg-4); font-size: 12.5px; }
.article-toc a { color: var(--fg-2); }
.article-toc a:hover { color: var(--fg-strong); text-decoration: underline; text-underline-offset: 3px; }
.article-body { margin-top: 0; }
.article-body .table-wrap { border: 0; border-radius: 0; margin: 1.6em 0 2em; }
.article-body table { font-size: 14.5px; line-height: 1.45; }
.article-body th, .article-body td { padding: 11px 14px 11px 0; background: none; }
.article-body thead th { font: 500 11.5px var(--mono); letter-spacing: 0.04em; text-transform: uppercase; color: var(--fg-3); border-bottom: 1px solid var(--line-2); padding-top: 0; background: none; }
.article-body tr:last-child td { border-bottom: 1px solid var(--line); }
.article-cta { margin: 56px 0 0; padding: 28px 28px 26px; background: var(--card); border-radius: var(--radius-lg); }
.article-cta h2 { margin: 0 0 6px; font-size: 20px; line-height: 1.3; letter-spacing: -0.015em; font-weight: 600; color: var(--fg-strong); }
.article-cta p { margin: 0 0 18px; color: var(--fg-3); font-size: 15.5px; line-height: 1.55; }
.article-cta-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.article-cta-actions a { display: inline-flex; align-items: center; height: 40px; padding: 0 16px; border-radius: 8px; font-weight: 550; font-size: 15px; }
.article-cta-actions .primary { background: var(--fg-strong); color: var(--bg); }
.article-cta-actions .secondary { border: 1px solid var(--line-2); color: var(--fg-strong); }
.article-cta-actions .primary:hover { opacity: 0.86; }
.article-cta-actions .secondary:hover { background: var(--card-hover); }
.article-related { margin: 56px 0 0; }
.article-related h2 { margin: 0 0 4px; font: 500 12px var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--fg-3); }
.article-related ul { list-style: none; border-top: 1px solid var(--line); margin-top: 10px; }
.article-related li { border-bottom: 1px solid var(--line); }
.article-related a { display: block; padding: 18px 0; }
.article-related a strong { display: block; font-size: 17px; line-height: 1.35; letter-spacing: -0.012em; font-weight: 600; color: var(--fg-strong); margin-bottom: 4px; }
.article-related a span { display: block; font-size: 14.5px; line-height: 1.5; color: var(--fg-3); }
.article-related a:hover strong { color: var(--accent-text); }
@media (max-width: 640px) { .article-toc ol { columns: 1; } .article-cta { padding: 22px 20px; } .article-body tr { padding: 12px 0; } }
.toc { margin: 32px 0 0; padding: 20px 22px; background: var(--card); border-radius: var(--radius-lg); }
.toc-title { font: 500 11.5px var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--fg-3); margin-bottom: 10px; }
.toc ol { padding-left: 20px; columns: 2; column-gap: 32px; font-size: 14.5px; line-height: 1.45; }
.toc li { margin: 0 0 7px; break-inside: avoid; }
.toc li::marker { color: var(--fg-4); font-size: 12.5px; }
.toc a { color: var(--fg-2); }
.toc a:hover { color: var(--fg-strong); text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 640px) { .toc ol { columns: 1; } .article-main { padding-top: 40px; } }

.prose { margin-top: 36px; font-size: 17.5px; line-height: 1.75; color: var(--fg); }
.prose > :first-child { margin-top: 0; }
.prose p { margin: 0 0 1.15em; text-wrap: pretty; }
.prose h2 { font-size: clamp(23px, 2.8vw, 27px); line-height: 1.25; letter-spacing: -0.022em; font-weight: 600; color: var(--fg-strong); margin: 2.1em 0 0.6em; scroll-margin-top: calc(var(--header-h) + 24px); text-wrap: balance; }
.prose h3 { font-size: 19px; line-height: 1.35; letter-spacing: -0.012em; font-weight: 600; color: var(--fg-strong); margin: 1.7em 0 0.5em; scroll-margin-top: calc(var(--header-h) + 24px); }
.prose a { color: var(--fg-strong); text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--primary) 55%, transparent); text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
.prose a:hover { text-decoration-color: var(--primary); }
.prose strong { font-weight: 600; color: var(--fg-strong); }
.prose ul, .prose ol { margin: 0 0 1.2em; padding-left: 1.3em; }
.prose li { margin: 0 0 0.5em; padding-left: 0.2em; }
.prose li::marker { color: var(--fg-4); }
.prose blockquote { margin: 1.5em 0; padding: 2px 0 2px 20px; border-left: 2px solid var(--primary); color: var(--fg-2); }
.prose hr { border: 0; border-top: 1px solid var(--line); margin: 2.4em 0; }
.prose code { font-size: 0.84em; background: var(--card); border-radius: 5px; padding: 1px 6px; overflow-wrap: anywhere; }
.prose kbd { font-size: 0.8em; padding: 1px 6px; border: 1px solid var(--line-2); border-bottom-width: 2px; border-radius: 5px; background: var(--panel); color: var(--fg-strong); white-space: nowrap; }
.prose pre.code, .prose pre { margin: 0 0 1.3em; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; font-size: 13.5px; line-height: 1.65; overflow-x: auto; white-space: pre-wrap; word-break: break-word; }
.prose pre code { background: none; padding: 0; font-size: inherit; }
.prose .tldr, .prose .note { margin: 0 0 1.6em; padding: 16px 18px; background: var(--card); border-radius: var(--radius); font-size: 16px; line-height: 1.6; }
.prose .note { border-left: 2px solid var(--primary); border-radius: 0 var(--radius) var(--radius) 0; }
.prose .tldr p:last-child, .prose .note p:last-child { margin-bottom: 0; }
.prose .table-wrap { margin: 0 0 1.5em; overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); }
.prose table { width: 100%; border-collapse: collapse; font-size: 15px; line-height: 1.5; }
.prose th, .prose td { padding: 11px 14px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.prose th { font-size: 13px; font-weight: 600; color: var(--fg-3); background: var(--bg-2); }
.prose tr:last-child td { border-bottom: 0; }
.prose td:first-child { color: var(--fg-strong); font-weight: 550; }
.prose td { color: var(--fg-2); }
.prose .sources { font-size: 15px; }
.prose .sources li { color: var(--fg-3); overflow-wrap: anywhere; }
p.sources { font-size: 15px; color: var(--fg-3); }
@media (max-width: 640px) {
  .prose { font-size: 17px; }
  /* Tables stack: first cell as a heading, then one line per column. */
  .prose .table-wrap { overflow: visible; }
  .prose thead { display: none; }
  .prose table, .prose tbody, .prose tr, .prose td { display: block; width: 100%; }
  .prose tr { padding: 12px 14px; border-bottom: 1px solid var(--line); }
  .prose tr:last-child { border-bottom: 0; }
  .prose td { padding: 2px 0; border: 0; }
  .prose td:first-child { margin-bottom: 4px; }
  .prose td[data-label]::before { content: attr(data-label) ": "; color: var(--fg-3); font-weight: 600; }
}

.related { margin-top: 56px; padding-top: 28px; border-top: 1px solid var(--line); }
.related h2 { font-size: 13px; font-weight: 600; color: var(--fg-strong); margin-bottom: 14px; }
.related-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.related-grid a { display: block; padding: 16px 18px; background: var(--card); border-radius: var(--radius-lg); font-size: 15px; font-weight: 550; line-height: 1.4; color: var(--fg-strong); transition: background 0.15s; }
.related-grid a:hover { background: var(--card-hover); }
.related-grid a span { display: block; margin-top: 4px; font: 500 11px var(--mono); letter-spacing: 0.04em; text-transform: uppercase; color: var(--fg-4); }
@media (max-width: 640px) { .related-grid { grid-template-columns: 1fr; } }
.app-note { margin-top: 40px; display: flex; gap: 16px; align-items: center; padding: 18px 20px; border: 1px solid var(--line); border-radius: var(--radius-lg); }
.app-note img { width: 40px; height: 40px; border-radius: 10px; flex: none; }
.app-note p { font-size: 15px; color: var(--fg-3); line-height: 1.5; }
.app-note b { color: var(--fg-strong); font-weight: 600; }
.app-note a { color: var(--fg-strong); text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--line-2); }

/* Docs */
.docs-main { padding: 40px 0 88px; }
.docs-grid { display: grid; grid-template-columns: 220px minmax(0, 1fr) 200px; gap: 48px; align-items: start; }
.docs-nav { position: sticky; top: calc(var(--header-h) + 24px); max-height: calc(100dvh - var(--header-h) - 48px); overflow-y: auto; font-size: 14px; padding-bottom: 12px; }
.docs-nav summary { display: none; }
.docs-filter { width: 100%; height: 36px; padding: 0 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel); font-size: 14px; margin-bottom: 18px; }
.docs-filter:focus { outline: none; border-color: var(--line-2); box-shadow: 0 0 0 3px var(--primary-soft); }
.docs-group + .docs-group { margin-top: 20px; }
.docs-group h2 { font: 500 11px var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--fg-4); margin-bottom: 8px; }
.docs-group ul { list-style: none; display: grid; gap: 1px; }
.docs-group a { display: block; padding: 5px 10px; margin-left: -10px; border-radius: 7px; color: var(--fg-3); line-height: 1.4; }
.docs-group a:hover { color: var(--fg-strong); background: var(--card); }
.docs-group a[aria-current="page"] { color: var(--fg-strong); background: var(--card); font-weight: 550; }
.docs-body { min-width: 0; max-width: 720px; }
.docs-body .page-head h1 { font-size: clamp(30px, 4vw, 40px); }
.docs-tools { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.docs-toc { position: sticky; top: calc(var(--header-h) + 24px); font-size: 13.5px; }
.docs-toc p { font: 500 11px var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--fg-4); margin-bottom: 10px; }
.docs-toc ul { list-style: none; display: grid; gap: 7px; border-left: 1px solid var(--line); }
.docs-toc a { display: block; padding-left: 12px; margin-left: -1px; border-left: 1px solid transparent; color: var(--fg-3); line-height: 1.4; }
.docs-toc a:hover { color: var(--fg-strong); }
.docs-toc a.on { color: var(--fg-strong); border-left-color: var(--primary); }
.docs-pager { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 56px; }
.docs-pager a { display: block; padding: 16px 18px; border: 1px solid var(--line); border-radius: var(--radius-lg); transition: background 0.15s, border-color 0.15s; min-width: 0; }
.docs-pager a:hover { background: var(--card); border-color: var(--line-2); }
.docs-pager span { display: block; font: 500 11px var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--fg-4); }
.docs-pager b { display: block; margin-top: 4px; font-weight: 550; color: var(--fg-strong); }
.docs-pager .next { text-align: right; grid-column: 2; }
.docs-index { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 36px; }
.docs-card { background: var(--card); border-radius: var(--radius-lg); padding: 24px; }
.docs-card h2 { font-size: 17px; font-weight: 600; color: var(--fg-strong); letter-spacing: -0.01em; }
.docs-card ul { list-style: none; margin-top: 12px; display: grid; gap: 2px; }
.docs-card a { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; border-bottom: 1px solid var(--line); font-size: 15px; color: var(--fg-2); }
.docs-card li:last-child a { border-bottom: 0; }
.docs-card a:hover { color: var(--fg-strong); }
.docs-card a span { color: var(--fg-4); }
@media (max-width: 1180px) { .docs-grid { grid-template-columns: 210px minmax(0, 1fr); gap: 40px; } .docs-toc { display: none; } }
@media (max-width: 860px) {
  .docs-grid { grid-template-columns: 1fr; gap: 24px; }
  .docs-nav { position: static; max-height: none; overflow: visible; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 0; }
  .docs-nav summary { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; cursor: pointer; list-style: none; font-weight: 550; color: var(--fg-strong); }
  .docs-nav summary::-webkit-details-marker { display: none; }
  .docs-nav summary::after { content: "+"; font-weight: 300; font-size: 20px; color: var(--fg-3); }
  .docs-nav[open] summary::after { content: "−"; }
  .docs-nav .docs-nav-inner { padding: 4px 16px 16px; }
  .docs-index { grid-template-columns: 1fr; }
  .docs-pager { grid-template-columns: 1fr; }
  .docs-pager .next { grid-column: auto; }
}

/* Tools */
.tool-main { padding: 56px 0 88px; }
.tool-wrap { max-width: 820px; }
.tool-box { margin-top: 32px; background: var(--card); border-radius: var(--radius-lg); padding: 28px; }
.fields { display: grid; gap: 18px; }
.fields-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field { display: grid; gap: 6px; min-width: 0; align-content: start; }
.field label, .field .label { font-size: 14px; font-weight: 550; color: var(--fg-strong); }
.field input[type="text"], .field input[type="email"], .field input[type="number"], .field select, .field textarea {
  width: 100%; min-height: 42px; padding: 9px 12px; border: 1px solid var(--line-2); border-radius: 8px; background: var(--panel);
  font-size: 16px; color: var(--fg-strong);
}
.field textarea { min-height: 96px; resize: vertical; font-family: var(--mono); font-size: 13.5px; line-height: 1.55; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-soft); }
.hint { font-size: 13.5px; color: var(--fg-3); line-height: 1.5; }
.seg { display: inline-flex; flex-wrap: wrap; gap: 2px; padding: 3px; border-radius: 10px; background: var(--panel); border: 1px solid var(--line); justify-self: start; max-width: 100%; }
.seg label { display: inline-flex; align-items: center; min-height: 34px; padding: 0 14px; border-radius: 7px; font-size: 14px; color: var(--fg-3); cursor: pointer; }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg label:has(input:checked) { background: var(--card); color: var(--fg-strong); font-weight: 550; box-shadow: var(--shadow); }
.seg label:has(input:focus-visible) { outline: 2px solid var(--primary); outline-offset: 1px; }
.opts { display: grid; gap: 8px; }
.opt { display: grid; grid-template-columns: 20px minmax(0, 1fr); gap: 10px; align-items: start; padding: 10px 12px; border: 1px solid var(--line); border-radius: 9px; background: var(--panel); cursor: pointer; font-size: 14.5px; color: var(--fg-3); line-height: 1.45; }
.opt input { width: 16px; height: 16px; margin-top: 2px; accent-color: var(--primary); }
.opt b { color: var(--fg-strong); font-weight: 550; }
.opt code { font-size: 0.9em; }
.preset-row { display: flex; flex-wrap: wrap; gap: 6px; }
.tool-out { margin-top: 22px; display: grid; gap: 12px; }
.tool-url { display: flex; gap: 8px; align-items: stretch; }
.tool-url code { flex: 1; min-width: 0; display: flex; align-items: center; padding: 10px 12px; background: var(--panel); border: 1px solid var(--line-2); border-radius: 8px; font-size: 13px; color: var(--fg-strong); overflow-x: auto; white-space: nowrap; }
.tool-url .btn { height: auto; min-height: 42px; }
.tool-code { background: var(--panel); border: 1px solid var(--line-2); border-radius: 10px; overflow: hidden; }
.tool-code-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 8px 8px 14px; border-bottom: 1px solid var(--line); font: 500 12px var(--mono); color: var(--fg-3); }
.tool-code pre { padding: 14px; font-size: 13px; line-height: 1.65; color: var(--fg-strong); overflow-x: auto; white-space: pre; margin: 0; }
.tool-note { font-size: 14px; color: var(--fg-3); line-height: 1.55; }
.tool-note:empty { display: none; }
.tool-note.warn { color: var(--st-blocked); }
.tool-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.tool-help { margin-top: 48px; }
.tool-help .prose { margin-top: 0; }
@media (max-width: 640px) { .tool-box { padding: 20px 16px; } .fields-2 { grid-template-columns: 1fr; } .tool-main { padding-top: 40px; } }

/* Tools index */
.tools-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 36px; }
.tools-grid .tool-card { padding: 26px; }
@media (max-width: 640px) { .tools-grid { grid-template-columns: 1fr; } }

/* Forms on plain pages (delete account) */
.form-card { margin-top: 32px; background: var(--card); border-radius: var(--radius-lg); padding: 28px; max-width: 620px; }
.form-card .fields { gap: 18px; }
.form-card .btn { justify-self: start; }
.msg { padding: 12px 14px; border-radius: 9px; font-size: 15px; }
.msg:empty { display: none; }
.msg.ok { background: var(--st-done-soft); color: var(--st-done); }
.msg.err { background: var(--st-blocked-soft); color: var(--st-blocked); }

/* 404 */
.nf { padding: 96px 0; text-align: center; }
.nf h1 { font-size: clamp(32px, 5vw, 46px); letter-spacing: -0.03em; font-weight: 600; color: var(--fg-strong); }
.nf p { margin: 14px auto 0; max-width: 30em; color: var(--fg-3); }
.nf .hero-actions { justify-content: center; }

/* Utilities */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.block-title { font-size: clamp(23px, 2.8vw, 27px); line-height: 1.25; letter-spacing: -0.022em; font-weight: 600; color: var(--fg-strong); }
.tool-faq { margin-top: 48px; }
.tool-faq .faq { margin-top: 18px; }
.w-full { width: 100%; }
.mt-s { margin-top: 10px; }
.mt-m { margin-top: 14px; }
@media (min-width: 641px) { .prose td:first-child code { white-space: nowrap; overflow-wrap: normal; } }
