/* ==========================================================================
   Support Bot · marketing site
   Visual language follows lollipay.cc: near-black canvas, teal brand,
   Merriweather display headings, Geist UI text, Geist Mono labels,
   hairline borders, 1-2px radii, corner brackets, soft teal glows.
   ========================================================================== */

/* ---------- tokens ---------- */
:root {
  /* pastel pink theme. --brand is the FILL colour (buttons, badges, highlights): always pair it with --brand-fg.
     --brand-text is the readable pink for links, pink text, focus rings and lines. */
  --bg: #fdf8fa;
  --bg-soft: #faf1f5;
  --fg: #2a1f26;
  --card: #ffffff;
  --card-2: #fbf3f7;
  --muted: #f8ecf2;
  --muted-fg: #7d6b75;           /* a bit darker than #93838c so small text passes WCAG AA */
  --border: #f0e2e9;
  --border-strong: #e6d0db;
  --input: #f0e2e9;
  --ring: #b83a68;
  --brand: #ffd1dc;
  --brand-fg: #5a1d36;
  --brand-text: #b83a68;
  --brand-mid: #f4a3bf;          /* decorative pink: bars, meters, bullets */
  --brand-soft: #ffe8ee;
  --glow: #f9b8d566;
  --glow-btn: #f49ac1;
  --dot: #2a1f2612;
  --positive: #3d7a5c;
  --warn: #9a6a00;
  --code-bg: #1d151b;
  --code-fg: #f3eaf0;
  --shadow: 0 1px 3px #5a1d3612, 0 8px 24px -12px #5a1d3626;
  --radius: 2px;
  --header-h: 64px;
  --maxw: 1200px;
  --font-sans: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-serif: "Merriweather", ui-serif, Georgia, serif;
  --font-mono: "Geist Mono", ui-monospace, "SFMono-Regular", Consolas, monospace;
  color-scheme: light;
}

/* dark: follow the system unless the visitor picked light */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #110e11; --bg-soft: #151116; --fg: #f3eaf0; --card: #18141a; --card-2: #1d181f;
    --muted: #251e26; --muted-fg: #9b8c97; --border: #2c242d; --border-strong: #3b303c;
    --input: #3b303c; --ring: #ffb3c6; --brand: #ffd1dc; --brand-fg: #5a1d36; --brand-text: #ffb3c6;
    --brand-mid: #f49ac1; --brand-soft: #3a1f2b; --glow: #ffb3c62e; --glow-btn: #f49ac1; --dot: #ffffff0f;
    --positive: #8fd1ad; --warn: #e8c26b; --code-bg: #0b080b; --code-fg: #f3eaf0;
    --shadow: 0 0 0 1px #ffffff0d, 0 24px 60px -20px #000000b3;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #110e11; --bg-soft: #151116; --fg: #f3eaf0; --card: #18141a; --card-2: #1d181f;
  --muted: #251e26; --muted-fg: #9b8c97; --border: #2c242d; --border-strong: #3b303c;
  --input: #3b303c; --ring: #ffb3c6; --brand: #ffd1dc; --brand-fg: #5a1d36; --brand-text: #ffb3c6;
  --brand-mid: #f49ac1; --brand-soft: #3a1f2b; --glow: #ffb3c62e; --glow-btn: #f49ac1; --dot: #ffffff0f;
  --positive: #8fd1ad; --warn: #e8c26b; --code-bg: #0b080b; --code-fg: #f3eaf0;
  --shadow: 0 0 0 1px #ffffff0d, 0 24px 60px -20px #000000b3;
  color-scheme: dark;
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
  margin: 0; background: var(--bg); color: var(--fg);
  font: 400 16px/1.5 var(--font-sans); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
p a, li a, .prose a, td a { color: var(--brand-text); text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--brand-text) 40%, transparent); text-underline-offset: 3px; }
p a:hover, li a:hover, .prose a:hover { text-decoration-color: currentColor; }
h1, h2, h3, h4 { margin: 0; font-weight: 500; }
p { margin: 0; }
button { font: inherit; color: inherit; }
code, kbd, pre { font-family: var(--font-mono); }
:focus-visible { outline: 2px solid var(--ring); outline-offset: 2px; border-radius: var(--radius); }
::selection { background: var(--brand); color: var(--brand-fg); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 12px; top: -48px; z-index: 100; background: var(--brand); color: var(--brand-fg); padding: 8px 14px; font-weight: 500; }
.skip-link:focus { top: 12px; }
html.i18n-wait body { visibility: hidden; }

/* ---------- layout ---------- */
.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.guides { position: relative; }
.guides::before, .guides::after { /* dashed vertical guide lines, like lollipay */
  content: ""; position: absolute; top: 0; bottom: 0; width: 0; border-left: 1px dashed var(--border); pointer-events: none; z-index: 0;
}
.guides::before { left: max(16px, calc(50% - var(--maxw) / 2 + 8px)); }
.guides::after { right: max(16px, calc(50% - var(--maxw) / 2 + 8px)); }
.section { position: relative; padding: 112px 0; }
.section.tight { padding: 72px 0; }
.section + .section.rule { border-top: 1px solid var(--border); }
.section.alt { background: var(--bg-soft); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.grid { display: grid; gap: 16px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 64px; align-items: center; }
.stack > * + * { margin-top: 16px; }
.center { text-align: center; }
.center .lede { margin-left: auto; margin-right: auto; }
.mt-8 { margin-top: 8px; } .mt-16 { margin-top: 16px; } .mt-24 { margin-top: 24px; } .mt-32 { margin-top: 32px; } .mt-48 { margin-top: 48px; } .mt-64 { margin-top: 64px; }

/* ---------- type ---------- */
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 500; line-height: 20px; color: var(--brand-text); }
.eyebrow::before { content: ""; width: 6px; height: 6px; background: currentColor; flex: none; }
.display { font-family: var(--font-serif); font-weight: 400; font-size: clamp(40px, 6vw, 64px); line-height: 1.04; letter-spacing: -0.02em; }
.display-2 { font-family: var(--font-serif); font-weight: 400; font-size: clamp(32px, 4.4vw, 48px); line-height: 1.1; letter-spacing: -0.02em; }
.h2 { font-size: clamp(28px, 3.4vw, 36px); line-height: 1.12; letter-spacing: -0.03em; font-weight: 500; }
.h3 { font-size: 20px; line-height: 1.3; letter-spacing: -0.01em; font-weight: 500; }
.lede { font-size: clamp(17px, 1.6vw, 20px); line-height: 1.5; color: var(--muted-fg); max-width: 40em; }
.muted { color: var(--muted-fg); }
.small { font-size: 14px; line-height: 1.55; }
.mono-label { font-family: var(--font-mono); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted-fg); }
.section-head { max-width: 720px; }
.section-head .h2, .section-head .display-2 { margin-top: 16px; }
.section-head .lede { margin-top: 16px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; height: 44px; padding: 0 20px;
  border: 1px solid transparent; border-radius: 1px; font-size: 15px; font-weight: 500; letter-spacing: -0.025em;
  cursor: pointer; white-space: nowrap; transition: background-color .15s, border-color .15s, box-shadow .2s, transform .15s, color .15s;
}
.btn-sm { height: 36px; padding: 0 14px; font-size: 14px; }
.btn-primary { background: var(--brand); color: var(--brand-fg); box-shadow: inset 0 1px 0 #ffffff40, 0 10px 30px -12px var(--glow-btn); border-color: color-mix(in srgb, var(--brand) 70%, var(--brand-mid)); }
.btn-primary:hover { box-shadow: inset 0 1px 0 #ffffff40, 0 14px 36px -10px var(--glow-btn); filter: brightness(1.03); }
.btn-primary .arrow { display: grid; place-items: center; width: 28px; height: 28px; margin-right: -12px; background: #5a1d361a; }
.btn-ghost { background: transparent; color: var(--fg); border-color: var(--border-strong); box-shadow: inset 0 1px 0 #ffffff0f; }
.btn-ghost:hover { background: var(--muted); }
.btn-link { padding: 0; height: auto; color: var(--brand-text); border: 0; background: none; }
.btn-link:hover { text-decoration: underline; text-underline-offset: 3px; }
.btn:active { transform: translateY(1px); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }
.chip-link { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; font-size: 14px; font-weight: 500; background: var(--brand); color: var(--brand-fg); border-radius: 1px; }

/* ---------- cards ---------- */
.card { position: relative; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; }
.card.pad-lg { padding: 32px; }
.card.hover { transition: border-color .2s, transform .2s, background-color .2s; }
.card.hover:hover { border-color: color-mix(in srgb, var(--brand-text) 45%, var(--border)); transform: translateY(-2px); }
a.card { display: block; }
.brackets { position: relative; }
.brackets::before, .brackets::after { content: ""; position: absolute; z-index: 2; width: 10px; height: 10px; border-color: color-mix(in srgb, var(--fg) 50%, transparent); border-style: solid; pointer-events: none; transition: border-color .15s cubic-bezier(.4, 0, .2, 1); }
.brackets::before { top: 0; right: 0; border-width: 1px 1px 0 0; }
.brackets::after { bottom: 0; left: 0; border-width: 0 0 1px 1px; }
.brackets:hover::before, .brackets:hover::after { border-color: var(--brand-text); }
.icon-box { display: grid; place-items: center; width: 36px; height: 36px; border: 1px solid var(--border-strong); color: var(--fg); background: var(--bg); border-radius: var(--radius); }
.icon-box svg { width: 18px; height: 18px; }
.card .icon-box { margin-bottom: 20px; }
.card h3 { font-size: 17px; font-weight: 500; letter-spacing: -0.01em; }
.card p { margin-top: 8px; color: var(--muted-fg); font-size: 15px; line-height: 1.55; }
.card .more { display: inline-flex; gap: 6px; margin-top: 16px; font-size: 14px; color: var(--brand-text); font-weight: 500; }
.bar-item h3, .bar-item h4 { border-left: 2px solid var(--brand-text); padding-left: 10px; font-size: 15px; font-weight: 500; }
.bar-item p { margin-top: 6px; padding-left: 12px; color: var(--muted-fg); font-size: 14px; line-height: 1.6; }
.badge { display: inline-flex; align-items: center; gap: 6px; height: 22px; padding: 0 8px; border: 1px solid var(--border-strong); border-radius: 1px; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted-fg); background: var(--bg); white-space: nowrap; }
.badge.brand { color: var(--brand-text); border-color: color-mix(in srgb, var(--brand-text) 40%, transparent); background: var(--brand-soft); }
.badge.soon { color: var(--warn); border-color: color-mix(in srgb, var(--warn) 45%, transparent); }

/* ---------- glow / dot backgrounds ---------- */
.glow-bg { position: relative; isolation: isolate; }
.glow-bg::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(60% 50% at 78% 30%, var(--glow), transparent 70%),
    radial-gradient(40% 40% at 10% 90%, color-mix(in srgb, var(--glow) 50%, transparent), transparent 70%);
}
.dots { background-image: radial-gradient(var(--dot) 1px, transparent 1.2px); background-size: 14px 14px; }

/* ---------- header ---------- */
.site-header { position: sticky; top: 0; z-index: 50; height: var(--header-h); background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: saturate(140%) blur(12px); -webkit-backdrop-filter: saturate(140%) blur(12px); border-bottom: 1px solid var(--border); }
.site-header .container { display: flex; align-items: center; height: 100%; gap: 8px; }
.logo { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; font-size: 19px; letter-spacing: -0.04em; margin-right: auto; }
.logo svg { width: 28px; height: 28px; flex: none; }
.nav { display: flex; align-items: center; gap: 2px; }
.nav-link { display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 12px; font-size: 15px; font-weight: 500; border-radius: var(--radius); background: none; border: 0; cursor: pointer; }
.nav-link:hover, .nav-link[aria-expanded="true"] { background: var(--muted); }
.nav-link[aria-current="page"] { color: var(--brand-text); }
.nav-link .chev { width: 12px; height: 12px; opacity: .7; transition: transform .2s; }
.nav-link[aria-expanded="true"] .chev { transform: rotate(180deg); }
.nav-tools { display: flex; align-items: center; gap: 4px; margin-left: 8px; }
.icon-btn { display: grid; place-items: center; width: 36px; height: 36px; border: 0; background: none; cursor: pointer; border-radius: var(--radius); color: var(--fg); }
.icon-btn:hover { background: var(--muted); }
.icon-btn svg { width: 18px; height: 18px; }
.lang-toggle { display: inline-flex; align-items: center; height: 32px; border: 1px solid var(--border-strong); border-radius: 1px; overflow: hidden; font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; }
.lang-toggle button { height: 100%; padding: 0 9px; border: 0; background: none; cursor: pointer; color: var(--muted-fg); }
.lang-toggle button[aria-pressed="true"] { background: var(--brand); color: var(--brand-fg); }
.nav-cta { display: flex; align-items: center; gap: 8px; margin-left: 8px; }
.dropdown { position: relative; }
.dropdown-panel {
  position: absolute; top: calc(100% + 12px); left: -12px; width: 620px; padding: 12px; display: none;
  grid-template-columns: 1fr 1fr; gap: 4px; background: var(--card); border: 1px solid var(--border); box-shadow: var(--shadow); border-radius: var(--radius);
}
.dropdown-panel.open { display: grid; animation: drop .16s ease-out; }
@keyframes drop { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.dd-item { display: flex; gap: 12px; padding: 12px; border-radius: var(--radius); }
.dd-item:hover, .dd-item:focus-visible { background: var(--muted); }
.dd-item .icon-box { flex: none; width: 32px; height: 32px; }
.dd-item strong { display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 500; }
.dd-item span.d { display: block; font-size: 13px; color: var(--muted-fg); margin-top: 2px; line-height: 1.45; }
.menu-btn { display: none; }
.mobile-panel { display: none; }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--border); padding: 64px 0 32px; background: var(--bg); position: relative; }
.footer-grid { display: grid; grid-template-columns: 1.5fr repeat(3, 1fr); gap: 32px; }
.footer-grid h4 { font-family: var(--font-mono); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted-fg); font-weight: 400; margin-bottom: 14px; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; }
.footer-grid li + li { margin-top: 10px; }
.footer-grid li a { font-size: 14px; color: var(--fg); text-decoration: none; opacity: .85; }
.footer-grid li a:hover { opacity: 1; color: var(--brand-text); }
.footer-about p { margin-top: 14px; font-size: 14px; color: var(--muted-fg); max-width: 30em; line-height: 1.6; }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; margin-top: 56px; padding-top: 24px; border-top: 1px solid var(--border); font-size: 13px; color: var(--muted-fg); }
.footer-bottom .mono-label { letter-spacing: .1em; }

/* ---------- hero ---------- */
.hero { padding: 88px 0 96px; overflow: hidden; }
.hero .split { gap: 48px; }
.hero h1 { margin-top: 24px; }
.hero .lede { margin-top: 24px; }
.hero .btn-row { margin-top: 36px; }
.hero-note { margin-top: 20px; font-size: 13px; color: var(--muted-fg); }
.float-card { position: absolute; display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; background: color-mix(in srgb, var(--card) 88%, transparent); border: 1px solid var(--border); backdrop-filter: blur(6px); box-shadow: var(--shadow); z-index: 3; max-width: 250px; }
.float-card .icon-box { width: 30px; height: 30px; flex: none; margin: 0; }
.float-card strong { display: block; font-size: 13px; font-weight: 500; }
.float-card span { display: block; font-size: 12px; color: var(--muted-fg); margin-top: 1px; }
.float-a { top: 6px; right: -8px; animation: bob 6s ease-in-out infinite; }
.float-b { bottom: 18px; left: -28px; animation: bob 7s ease-in-out infinite reverse; }
@keyframes bob { 50% { transform: translateY(-6px); } }

/* ---------- chat mock (widget preview) ---------- */
.stage { position: relative; padding: 28px 12px; }
.stage-bg { position: absolute; inset: 0; z-index: 0; }
.stage-bg::after { content: ""; position: absolute; inset: 0; background: radial-gradient(closest-side, transparent 60%, var(--bg)); }
.chat {
  --wc: var(--brand); --wc-fg: var(--brand-fg);
  position: relative; z-index: 1; width: 100%; max-width: 380px; margin: 0 auto; background: var(--card); border: 1px solid var(--border-strong);
  border-radius: 14px; box-shadow: var(--shadow), 0 30px 80px -30px var(--glow); overflow: hidden; font-size: 14px;
}
.chat-head { display: flex; align-items: center; gap: 10px; padding: 14px 16px; background: var(--wc); color: var(--wc-fg); }
.chat-head .av { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, var(--wc-fg) 16%, transparent); }
.chat-head .av svg { width: 16px; height: 16px; }
.chat-head strong { display: block; font-size: 14px; font-weight: 600; letter-spacing: -0.01em; }
.chat-head span { display: block; font-size: 12px; opacity: .85; }
.chat-body { padding: 16px; display: flex; flex-direction: column; gap: 10px; min-height: 300px; background: var(--card); }
.msg { max-width: 86%; padding: 9px 12px; border-radius: 12px; line-height: 1.45; animation: pop .25s ease-out both; }
.msg.bot { align-self: flex-start; background: var(--muted); border-bottom-left-radius: 4px; }
.msg.user { align-self: flex-end; background: var(--wc); color: var(--wc-fg); border-bottom-right-radius: 4px; }
.msg.bot a { color: inherit; font-weight: 500; }
.msg .meta { display: block; margin-top: 4px; font-family: var(--font-mono); font-size: 10px; letter-spacing: .06em; color: var(--muted-fg); }
.prod { display: flex; gap: 10px; align-items: center; margin-top: 8px; padding: 8px; border: 1px solid var(--border); border-radius: 8px; background: var(--card); }
.prod i { width: 34px; height: 34px; border-radius: 6px; flex: none; background: linear-gradient(135deg, var(--wc), color-mix(in srgb, var(--wc) 40%, #000)); }
.prod b { display: block; font-size: 12.5px; font-weight: 500; }
.prod small { font-size: 11.5px; color: var(--muted-fg); }
@keyframes pop { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.typing { display: inline-flex; gap: 4px; padding: 12px; }
.typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--muted-fg); animation: blink 1s infinite; }
.typing i:nth-child(2) { animation-delay: .15s; } .typing i:nth-child(3) { animation-delay: .3s; }
@keyframes blink { 0%, 80%, 100% { opacity: .25; } 40% { opacity: 1; } }
.chat-input { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-top: 1px solid var(--border); color: var(--muted-fg); font-size: 13px; }
.chat-input .send { margin-left: auto; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--wc); color: var(--wc-fg); }
.chat-input .send svg { width: 14px; height: 14px; }
.suggest { display: flex; flex-wrap: wrap; gap: 6px; }
.suggest button { padding: 6px 10px; border: 1px solid var(--border-strong); border-radius: 999px; background: var(--card); font-size: 12.5px; cursor: pointer; }
.suggest button:hover { border-color: var(--wc); color: var(--wc); }
.launcher { position: absolute; z-index: 2; bottom: -6px; right: 0; width: 52px; height: 52px; border-radius: 50%; background: var(--wc, var(--brand)); color: #fff; display: grid; place-items: center; box-shadow: 0 10px 30px -8px var(--wc, var(--brand)); }
.launcher svg { width: 24px; height: 24px; }

/* preview playground */
.playground > * { min-width: 0; }
.playground { display: grid; grid-template-columns: 320px minmax(0, 1fr); gap: 24px; align-items: stretch; }
.controls { display: flex; flex-direction: column; gap: 22px; }
.control-label { display: block; margin-bottom: 10px; }
.swatches { display: flex; gap: 8px; flex-wrap: wrap; }
.swatch { width: 30px; height: 30px; border-radius: 50%; border: 2px solid var(--bg); outline: 1px solid var(--border-strong); cursor: pointer; padding: 0; }
.swatch[aria-pressed="true"] { outline: 2px solid var(--fg); }
.seg { display: inline-flex; border: 1px solid var(--border-strong); border-radius: 1px; }
.seg button { height: 34px; padding: 0 14px; border: 0; background: none; cursor: pointer; font-size: 14px; color: var(--muted-fg); }
.seg button[aria-pressed="true"] { background: var(--muted); color: var(--fg); }
.q-list { display: flex; flex-direction: column; gap: 6px; }
.q-list button { text-align: left; padding: 10px 12px; border: 1px solid var(--border); background: var(--card); border-radius: var(--radius); cursor: pointer; font-size: 14px; }
.q-list button:hover, .q-list button[aria-pressed="true"] { border-color: var(--brand-text); }
.q-list button small { display: block; font-family: var(--font-mono); font-size: 10px; letter-spacing: .08em; color: var(--muted-fg); text-transform: uppercase; margin-bottom: 2px; }
.browser { position: relative; border: 1px solid var(--border); background: var(--card); border-radius: var(--radius); overflow: hidden; min-height: 520px; }
.browser-bar { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-bottom: 1px solid var(--border); background: var(--card-2); }
.browser-bar i { width: 9px; height: 9px; border-radius: 50%; background: var(--border-strong); }
.browser-bar .url { margin-left: 10px; flex: 1; max-width: 340px; height: 24px; display: flex; align-items: center; padding: 0 10px; border: 1px solid var(--border); background: var(--bg); font-family: var(--font-mono); font-size: 11px; color: var(--muted-fg); overflow: hidden; white-space: nowrap; }
.browser-page { padding: 28px; display: grid; gap: 12px; }
.sk { height: 10px; background: var(--muted); border-radius: 2px; }
.sk.w60 { width: 60%; } .sk.w40 { width: 40%; } .sk.w80 { width: 80%; } .sk.h { height: 22px; width: 50%; }
.sk-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 10px; }
.sk-grid div { aspect-ratio: 1; background: var(--muted); border-radius: 2px; }
.browser .chat { position: absolute; bottom: 20px; right: 20px; max-width: 330px; margin: 0; font-size: 13px; }
.browser.left .chat { right: auto; left: 20px; }
.browser .chat-body { min-height: 250px; max-height: 300px; overflow: auto; }

/* ---------- stats strip ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid var(--border); background: var(--card); }
.stat { padding: 28px 24px; }
.stat + .stat { border-left: 1px solid var(--border); }
.stat b { display: block; font-family: var(--font-serif); font-weight: 400; font-size: 38px; letter-spacing: -0.03em; line-height: 1.1; }
.stat b em { font-style: normal; font-size: 18px; color: var(--muted-fg); margin-left: 4px; font-family: var(--font-sans); }
.stat span { display: block; margin-top: 8px; font-size: 14px; color: var(--muted-fg); line-height: 1.45; }
.footnote { margin-top: 12px; font-size: 12.5px; color: var(--muted-fg); }

/* ---------- steps ---------- */
.steps { counter-reset: step; }
.step { position: relative; padding-top: 52px; }
.step::before { counter-increment: step; content: "0" counter(step); position: absolute; top: 24px; left: 24px; font-family: var(--font-mono); font-size: 11px; letter-spacing: .12em; color: var(--brand-text); }
.step .viz { margin-top: 20px; height: 120px; border: 1px solid var(--border); background: var(--bg); position: relative; overflow: hidden; display: grid; place-items: center; }
.url-field { display: flex; align-items: center; gap: 8px; width: 86%; height: 38px; padding: 0 10px; border: 1px solid var(--border-strong); background: var(--card); font-family: var(--font-mono); font-size: 12px; }
.url-field .caret { width: 1px; height: 16px; background: var(--brand-text); animation: caret 1s steps(1) infinite; }
@keyframes caret { 50% { opacity: 0; } }
.url-field .go { margin-left: auto; padding: 3px 8px; background: var(--brand); color: var(--brand-fg); font-family: var(--font-sans); font-size: 11px; font-weight: 500; }
.crawl-grid { display: grid; grid-template-columns: repeat(14, 10px); gap: 4px; }
.crawl-grid i { width: 10px; height: 10px; background: var(--muted); animation: fill 3.2s infinite; }
@keyframes fill { 0%, 10% { background: var(--muted); } 30%, 85% { background: var(--brand-mid); } 100% { background: var(--muted); } }
.code-mini { width: 90%; padding: 12px; background: var(--code-bg); color: var(--code-fg); font-family: var(--font-mono); font-size: 11px; line-height: 1.6; border: 1px solid var(--border); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.code-mini .t { color: #ffb3c6; } .code-mini .a { color: #e8c26b; } .code-mini .s { color: #a5d6a7; }

/* ---------- use cases ---------- */
.case { display: flex; flex-direction: column; }
.case ul { list-style: none; padding: 0; margin: 18px 0 0; display: grid; gap: 10px; }
.case li { display: flex; gap: 10px; font-size: 14px; color: var(--muted-fg); line-height: 1.5; }
.case li::before { content: ""; flex: none; width: 5px; height: 5px; margin-top: 8px; background: var(--brand-mid); }
.case .note { margin-top: auto; padding-top: 18px; font-size: 13px; color: var(--muted-fg); }

/* ---------- models (Pinky / Mimi) ---------- */
.model-card { display: flex; flex-direction: column; gap: 14px; }
.model-card .name { font-family: var(--font-serif); font-size: 30px; letter-spacing: -0.02em; }
.model-card dl { margin: 6px 0 0; display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; font-size: 14px; }
.model-card dt { color: var(--muted-fg); }
.model-card dd { margin: 0; }
.meter { display: flex; gap: 3px; }
.meter i { width: 14px; height: 6px; background: var(--muted); }
.meter i.on { background: var(--brand-mid); }

/* ---------- FAQ ---------- */
.faq { border-top: 1px solid var(--border); }
.faq details { border-bottom: 1px solid var(--border); }
.faq summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 20px 0; font-size: 17px; font-weight: 500; letter-spacing: -0.01em; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-family: var(--font-mono); font-size: 20px; color: var(--brand-text); transition: transform .2s; flex: none; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq .answer { padding: 0 0 22px; color: var(--muted-fg); font-size: 15px; line-height: 1.65; max-width: 62em; }

/* ---------- CTA band ---------- */
.cta-band { position: relative; overflow: hidden; border: 1px solid var(--border); background: var(--card); padding: 72px 48px; text-align: center; isolation: isolate; }
.cta-band::before { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(50% 70% at 50% 110%, var(--glow), transparent 70%); }
.cta-band .lede { margin: 18px auto 0; }
.cta-band .btn-row { justify-content: center; margin-top: 32px; }

/* ---------- pricing ---------- */
.billing { display: inline-flex; align-items: center; gap: 12px; margin-top: 32px; }
.billing .seg button { min-width: 96px; }
.save-tag { font-size: 13px; color: var(--brand-text); font-weight: 500; }
.plans { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-top: 48px; align-items: stretch; }
.plan { display: flex; flex-direction: column; }
.plan.featured { border-color: var(--brand-mid); box-shadow: 0 30px 80px -40px var(--glow); }
.plan .top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.plan .pname { font-size: 18px; font-weight: 500; }
.plan .pdesc { margin-top: 8px; font-size: 14px; color: var(--muted-fg); min-height: 42px; line-height: 1.5; }
.plan .price { margin-top: 22px; display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 6px; }
.plan .price b { font-family: var(--font-serif); font-weight: 400; font-size: clamp(28px, 2.5vw, 36px); letter-spacing: -0.03em; line-height: 1.1; white-space: nowrap; }
.plan .price span { font-size: 14px; color: var(--muted-fg); }
.plan .billed { margin-top: 6px; font-size: 12.5px; color: var(--muted-fg); min-height: 18px; }
.plan .btn { margin-top: 22px; width: 100%; }
.plan ul { list-style: none; padding: 0; margin: 24px 0 0; display: grid; gap: 10px; font-size: 14px; border-top: 1px solid var(--border); padding-top: 20px; }
.plan li { display: flex; gap: 10px; line-height: 1.45; }
.plan li svg { flex: none; width: 16px; height: 16px; margin-top: 2px; color: var(--brand-text); }
.plan li.off { color: var(--muted-fg); }
.plan li.off svg { color: var(--muted-fg); opacity: .6; }
.table-wrap { overflow-x: auto; border: 1px solid var(--border); background: var(--card); }
table.compare { width: 100%; border-collapse: collapse; font-size: 14px; min-width: 720px; }
.compare th, .compare td { padding: 14px 18px; text-align: left; border-bottom: 1px solid var(--border); }
.compare thead th { font-weight: 500; position: sticky; top: 0; background: var(--card-2); }
.compare tbody th { font-weight: 400; color: var(--muted-fg); }
.compare tr.group th { font-family: var(--font-mono); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--brand-text); background: var(--bg-soft); }
.compare td.yes { color: var(--brand-text); }
.compare td.no { color: var(--muted-fg); }
.compare svg { display: inline-block; width: 16px; height: 16px; vertical-align: -3px; }
table.compare { table-layout: fixed; }
.compare thead th:first-child { width: 30%; }
.compare tbody th, .compare thead th:first-child { position: sticky; left: 0; z-index: 1; background: var(--card); }
.compare thead th:first-child { z-index: 2; background: var(--card-2); }
.compare tr.group th { position: static; background: var(--bg-soft); }
.compare tr.group th span { position: sticky; left: 18px; }
@media (max-width: 640px) { table.compare { min-width: 560px; } .compare thead th:first-child { width: 150px; } .compare th, .compare td { padding: 12px 12px; } }
.price-note { margin-top: 16px; font-size: 13px; color: var(--muted-fg); text-align: center; }

/* ---------- feature pages ---------- */
.feature-hero { padding: 80px 0 88px; }
.feature-hero .crumbs { font-family: var(--font-mono); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted-fg); }
.feature-hero .crumbs a:hover { color: var(--brand-text); }
.feature-hero h1 { margin-top: 18px; }
.feature-hero .lede { margin-top: 22px; }
.feature-hero .btn-row { margin-top: 32px; }
.viz-panel { position: relative; border: 1px solid var(--border); background: var(--card); padding: 24px; min-height: 340px; overflow: hidden; }
.viz-panel.dots { background-color: var(--card); }
.lang-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.lang-chip { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; border: 1px solid var(--border); background: var(--bg); font-size: 14px; animation: pop .4s ease-out both; }
.lang-chip code { font-size: 11px; color: var(--brand-text); letter-spacing: .08em; }
.lang-chip span { min-width: 0; color: var(--muted-fg); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.teach-flow { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; }
.teach-flow .row { border: 1px solid var(--border); background: var(--bg); padding: 12px 14px; font-size: 14px; }
.teach-flow .row .mono-label { display: block; margin-bottom: 6px; }
.teach-flow .row.wrong { border-left: 2px solid #d1564f; }
.teach-flow .row.fixed { border-left: 2px solid var(--brand-text); }
.teach-flow .arrowdown { text-align: center; color: var(--muted-fg); font-family: var(--font-mono); font-size: 12px; }
.chan-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.chan { border: 1px solid var(--border); background: var(--bg); padding: 16px; display: flex; flex-direction: column; gap: 10px; }
.chan .top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.chan strong { font-size: 15px; font-weight: 500; }
.chan span { font-size: 13px; color: var(--muted-fg); }
.chan.soon { opacity: .75; border-style: dashed; }
.bars { display: flex; align-items: flex-end; gap: 6px; height: 140px; padding-top: 10px; border-bottom: 1px solid var(--border); }
.bars i { flex: 1; background: var(--brand-mid); opacity: .85; transform-origin: bottom; animation: grow .8s ease-out both; position: relative; }
.bars i b { position: absolute; left: 0; right: 0; bottom: 0; background: var(--warn); opacity: .9; }
@keyframes grow { from { transform: scaleY(0); } }
.kpis { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-bottom: 18px; }
.kpi { border: 1px solid var(--border); background: var(--bg); padding: 12px; }
.kpi b { display: block; font-family: var(--font-serif); font-weight: 400; font-size: 24px; }
.kpi span { font-size: 12px; color: var(--muted-fg); }
.legend { display: flex; gap: 16px; margin-top: 10px; font-size: 12px; color: var(--muted-fg); }
.legend i { display: inline-block; width: 8px; height: 8px; margin-right: 6px; background: var(--brand-mid); }
.legend i.w { background: var(--warn); }
.inbox-list { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; }
.inbox-row { display: flex; align-items: center; gap: 12px; padding: 12px; border: 1px solid var(--border); background: var(--bg); font-size: 14px; }
.inbox-row .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--positive); flex: none; box-shadow: 0 0 0 4px var(--brand-soft); }
.inbox-row .dot.wait { background: var(--brand-text); box-shadow: 0 0 0 4px var(--brand-soft); }
.inbox-row .dot.idle { background: var(--muted-fg); box-shadow: none; }
.inbox-row .txt { min-width: 0; flex: 1; }
.inbox-row .txt span { display: block; font-size: 12.5px; color: var(--muted-fg); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sec-list { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; }
.sec-row { display: flex; gap: 12px; align-items: center; padding: 12px 14px; border: 1px solid var(--border); background: var(--bg); font-size: 14px; }
.sec-row svg { width: 16px; height: 16px; color: var(--brand-text); flex: none; }
.sec-row code { margin-left: auto; font-size: 11px; color: var(--muted-fg); }
.related { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }

/* ---------- docs ---------- */
.docs-layout { display: grid; grid-template-columns: 240px minmax(0, 1fr) 200px; gap: 48px; align-items: start; padding-top: 40px; padding-bottom: 96px; }
.docs-nav, .docs-toc { position: sticky; top: calc(var(--header-h) + 24px); max-height: calc(100vh - var(--header-h) - 48px); overflow: auto; font-size: 14px; }
.docs-nav .mono-label, .docs-toc .mono-label { display: block; margin-bottom: 12px; }
.docs-nav ol, .docs-toc ol { list-style: none; margin: 0; padding: 0; }
.docs-nav a { display: block; padding: 7px 12px; border-left: 1px solid var(--border); color: var(--muted-fg); text-decoration: none; }
.docs-nav a:hover { color: var(--fg); }
.docs-nav a[aria-current="true"] { color: var(--brand-text); border-left: 2px solid var(--brand-text); padding-left: 11px; font-weight: 500; }
.docs-toc a { display: block; padding: 4px 0; color: var(--muted-fg); text-decoration: none; font-size: 13px; line-height: 1.45; }
.docs-toc a:hover, .docs-toc a.active { color: var(--brand-text); }
.docs-mobile-nav { display: none; margin-bottom: 24px; }
.docs-mobile-nav select { width: 100%; height: 42px; padding: 0 12px; border: 1px solid var(--border-strong); background: var(--card); color: var(--fg); font: inherit; border-radius: var(--radius); }
.prose { max-width: 760px; font-size: 16px; line-height: 1.7; }
.prose section { padding-bottom: 56px; margin-bottom: 56px; border-bottom: 1px solid var(--border); }
.prose section:last-child { border-bottom: 0; }
.prose h2 { font-family: var(--font-serif); font-weight: 400; font-size: 34px; letter-spacing: -0.02em; line-height: 1.15; margin: 10px 0 18px; }
.prose h3 { font-size: 19px; font-weight: 500; letter-spacing: -0.01em; margin: 36px 0 10px; }
.prose p, .prose ul, .prose ol, .prose table, .prose .callout, .prose pre, .prose .codeblock { margin: 0 0 16px; }
.prose ul, .prose ol { padding-left: 22px; }
.prose li + li { margin-top: 6px; }
.prose li::marker { color: var(--brand-text); }
.prose :not(pre) > code { font-size: .86em; padding: 2px 6px; background: var(--muted); border: 1px solid var(--border); border-radius: 2px; overflow-wrap: anywhere; }
.prose table { width: 100%; border-collapse: collapse; font-size: 14.5px; display: block; overflow-x: auto; }
.prose th, .prose td { border: 1px solid var(--border); padding: 10px 12px; text-align: left; vertical-align: top; }
.prose th { background: var(--card-2); font-weight: 500; }
.prose td:first-child code, .prose th code { white-space: nowrap; overflow-wrap: normal; }
.callout { display: flex; gap: 12px; padding: 14px 16px; border: 1px solid var(--border); border-left: 2px solid var(--brand-text); background: var(--brand-soft); font-size: 15px; line-height: 1.6; }
.callout.warn { border-left-color: var(--warn); background: color-mix(in srgb, var(--warn) 10%, transparent); }
.callout strong { font-weight: 500; }
.codeblock { position: relative; border: 1px solid var(--border); background: var(--code-bg); border-radius: var(--radius); }
.codeblock .cb-head { display: flex; align-items: center; justify-content: space-between; padding: 6px 8px 6px 14px; border-bottom: 1px solid #ffffff14; font-family: var(--font-mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: #8a9b9f; }
.codeblock pre { margin: 0; padding: 16px; overflow-x: auto; color: var(--code-fg); font-size: 13px; line-height: 1.65; tab-size: 2; }
.copy-btn { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 8px; border: 1px solid #ffffff1f; background: #ffffff0a; color: #c9d4d6; font-family: var(--font-mono); font-size: 11px; letter-spacing: .06em; cursor: pointer; border-radius: 1px; text-transform: uppercase; }
.copy-btn:hover { background: #ffffff17; }
.copy-btn svg { width: 12px; height: 12px; }
.copy-btn.done { color: #ffb3c6; border-color: #ffb3c666; }
.tok-k { color: #ffb3c6; } .tok-s { color: #a5d6a7; } .tok-n { color: #e8c26b; } .tok-c { color: #6c7d81; }

/* ---------- reveal animation ---------- */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ---------- responsive ---------- */
@media (max-width: 1120px) {
  .docs-layout { grid-template-columns: 220px minmax(0, 1fr); }
  .docs-toc { display: none; }
  .plans { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 1000px) {
  .nav, .nav-cta .login { display: none; }
  .nav-tools .lang-toggle { display: none; }
  .menu-btn { display: grid; }
  .mobile-panel.open {
    display: block; position: fixed; inset: var(--header-h) 0 0 0; z-index: 49; overflow-y: auto; background: var(--bg); padding: 16px 24px 40px; border-top: 1px solid var(--border);
  }
  .mobile-panel .m-group { padding: 12px 0; border-bottom: 1px solid var(--border); }
  .mobile-panel .m-group > a, .mobile-panel .m-group > span { display: block; padding: 10px 0; font-size: 17px; font-weight: 500; }
  .mobile-panel .m-sub { display: grid; grid-template-columns: 1fr 1fr; gap: 2px 12px; padding-bottom: 6px; }
  .mobile-panel .m-sub a { padding: 8px 0; font-size: 15px; color: var(--muted-fg); }
  .mobile-panel .m-actions { display: grid; gap: 10px; margin-top: 24px; }
  .mobile-panel .m-actions .btn { width: 100%; }
  .mobile-panel .m-prefs { display: flex; align-items: center; justify-content: space-between; margin-top: 20px; }
  .mobile-panel .lang-toggle { display: inline-flex; }
  .split { grid-template-columns: minmax(0, 1fr); gap: 48px; }
  .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g3, .related { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-about { grid-column: 1 / -1; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .stat:nth-child(3) { border-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid var(--border); }
  .playground { grid-template-columns: minmax(0, 1fr); }
  .docs-layout { grid-template-columns: minmax(0, 1fr); gap: 0; padding-top: 24px; }
  .docs-nav { display: none; }
  .docs-mobile-nav { display: block; position: sticky; top: var(--header-h); z-index: 5; background: var(--bg); padding: 10px 0; margin: -10px 0 14px; border-bottom: 1px solid var(--border); }
  .float-b { left: 0; }
  .float-a { right: 0; }
}
@media (max-width: 640px) {
  .container { padding: 0 16px; }
  .section { padding: 72px 0; }
  .section.tight { padding: 56px 0; }
  .hero { padding: 48px 0 64px; }
  .feature-hero { padding: 48px 0 56px; }
  .g2, .g3, .g4, .related, .plans, .chan-grid { grid-template-columns: minmax(0, 1fr); }
  .lang-grid { grid-template-columns: minmax(0, 1fr); }
  .stats { grid-template-columns: 1fr 1fr; }
  .stat { padding: 20px 16px; }
  .stat b { font-size: 30px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 28px; }
  .cta-band { padding: 48px 20px; }
  .btn-row .btn { flex: 1 1 auto; }
  .float-card { position: relative; inset: auto; max-width: none; margin-top: 12px; animation: none; }
  .stage { padding: 0; }
  .browser { min-height: 560px; }
  .browser .chat { left: 12px; right: 12px; bottom: 12px; max-width: none; }
  .browser.left .chat { left: 12px; }
  .nav-cta .btn-primary { padding: 0 12px; }
  .logo span { font-size: 17px; }
  .guides::before, .guides::after { display: none; }
  .kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .kpi b { font-size: 20px; }
  .viz-panel { padding: 16px; }
  .prose h2 { font-size: 28px; }
}

/* ==========================================================================
   Effects layer (matches lollipay.cc's interactions; canvases come from fx.js)
   ========================================================================== */
:root { --ease-out: cubic-bezier(.16, 1, .3, 1); --ease: cubic-bezier(.4, 0, .2, 1); }
canvas[data-fx] { display: block; image-rendering: crisp-edges; image-rendering: pixelated; pointer-events: none; }
.fx-host { position: relative; isolation: isolate; }
.fx-layer { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.fx-layer > canvas { position: absolute; inset: 0; width: 100%; height: 100%; }

/* buttons: transition-all 150ms, hover = brand at 90%, press = 1px down, arrow chip nudges 2px */
.btn { transition: all .15s var(--ease); border-radius: 2px; }
.btn-lg { height: 48px; padding: 0 20px; font-size: 15px; }
.btn-primary, .btn-primary:hover { filter: none; box-shadow: inset 0 1px 0 rgb(255 255 255 / .25), 0 10px 30px -10px var(--glow-btn); }
.btn-primary:hover { background: color-mix(in srgb, var(--brand) 90%, transparent); }
.btn-primary .arrow { width: 32px; height: 32px; margin-right: -12px; border-radius: 2px; background: color-mix(in srgb, var(--brand-fg) 10%, transparent); }
.btn-lg.btn-primary { padding: 0 8px 0 20px; gap: 12px; }
.btn-lg.btn-primary .arrow { margin-right: 0; }
.btn .arrow svg { width: 16px; height: 16px; transition: transform .2s var(--ease); }
.btn:hover .arrow svg { transform: translateX(2px); }
.btn-ghost { border-color: var(--border); background: color-mix(in srgb, var(--bg) 30%, transparent); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); box-shadow: inset 0 1px 0 rgb(255 255 255 / .06); }
.btn-ghost:hover { border-color: color-mix(in srgb, var(--fg) 20%, transparent); background: color-mix(in srgb, var(--fg) 5%, transparent); }
.btn:active { transform: translateY(1px); }

/* nav links: no background, the text dims on hover (200ms) */
.nav-link { background: none !important; transition: color .2s var(--ease); }
.nav-link:hover, .nav-link[aria-expanded="true"] { color: var(--muted-fg); }
.nav-link[aria-current="page"]:hover { color: color-mix(in srgb, var(--brand-text) 80%, transparent); }
.dd-item { transition: background-color .15s var(--ease); }
.icon-btn { color: var(--muted-fg); transition: color .15s var(--ease); background: none !important; }
.icon-btn:hover { color: var(--fg); }

/* text links: brand ink, 80% on hover */
.more, .btn-link, .footer-grid li a, .docs-nav a, .docs-toc a, .crumbs a { transition: color .15s var(--ease), opacity .15s var(--ease); }
.more:hover, a.card:hover .more { opacity: .8; }
.footer-grid li a:hover { opacity: 1; color: var(--brand-text); }

/* bento grids: 1px hairlines between tiles */
.bento { gap: 1px !important; background: var(--border); border: 1px solid var(--border); }
.bento > .card { border: 0; border-radius: 0; background: var(--bg); }
.section.alt .bento > .card { background: var(--bg-soft); }
.bento > .card.hover:hover, .fx-card.hover:hover { transform: none; border-color: transparent; }

/* cards with pixel grain (bottom-right), cursor spotlight and hover corners */
.fx-card { position: relative; isolation: isolate; overflow: hidden; }
.fx-card-grain, .fx-card-spot { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; image-rendering: crisp-edges; image-rendering: pixelated; }
.fx-card-grain { z-index: -2; -webkit-mask-image: radial-gradient(ellipse 80% 70% at 100% 100%, #000, transparent); mask-image: radial-gradient(ellipse 80% 70% at 100% 100%, #000, transparent); }
.fx-card-spot { z-index: -1; }
:root[data-theme="dark"] .fx-card-spot { mix-blend-mode: screen; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .fx-card-spot { mix-blend-mode: screen; } }
.fx-corner { position: absolute; width: 12px; height: 12px; border: 0 solid var(--brand-text); opacity: 0; transition: opacity .15s var(--ease); pointer-events: none; }
.fx-corner.tl { top: 0; left: 0; border-top-width: 1px; border-left-width: 1px; }
.fx-corner.br { right: 0; bottom: 0; border-right-width: 1px; border-bottom-width: 1px; }
.fx-card:hover .fx-corner, .fx-card:focus-visible .fx-corner, .fx-card:focus-within .fx-corner { opacity: 1; }
.bento > .fx-card .icon-box { background: transparent; }

/* hero: dithered glow field, globe, mountains */
.hero.fx-host { overflow: hidden; }
.hero-grain { -webkit-mask-image: linear-gradient(to right, transparent, #000 18%, #000 78%, transparent), linear-gradient(to bottom, #000 70%, transparent); -webkit-mask-composite: source-in; mask-image: linear-gradient(to right, transparent, #000 18%, #000 78%, transparent), linear-gradient(to bottom, #000 70%, transparent); mask-composite: intersect; }
.hero-ground { position: absolute; left: 0; right: 0; bottom: 0; height: 224px; z-index: -1; pointer-events: none; -webkit-mask-image: linear-gradient(to bottom, transparent, #000 35%); mask-image: linear-gradient(to bottom, transparent, #000 35%); }
.hero-ground canvas { width: 100%; height: 100%; }
.hero.has-ground { padding-bottom: 200px; }
.orb-wrap { position: relative; height: clamp(420px, 44vw, 640px); }
.orb-wrap > canvas { width: 100%; height: 100%; animation: fx-fade .7s ease both; }
@keyframes fx-fade { from { opacity: 0; } }
.float-card { border-radius: 8px; padding: 12px 16px 12px 12px; background: color-mix(in srgb, var(--bg) 95%, transparent); border: 0; box-shadow: 0 0 0 1px color-mix(in srgb, var(--border) 70%, transparent), 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); animation: none; }
.float-card .icon-box { border-radius: 6px; color: var(--brand-text); border-color: var(--border); }
.orb-wrap .float-a { top: 8%; right: 2%; left: auto; bottom: auto; }
.orb-wrap .float-b { bottom: 14%; left: 0; top: auto; right: auto; }
.orb-wrap .float-c { bottom: 3%; right: 8%; top: auto; left: auto; }

/* section with pixel water behind the heading */
.water-band { position: relative; isolation: isolate; padding: 96px 0 88px; }
.water-band > canvas { position: absolute; left: 0; right: 0; top: -96px; width: 100%; height: calc(100% + 152px); z-index: -1; -webkit-mask-image: linear-gradient(to right, transparent 22%, #000 62%), linear-gradient(to bottom, #000 72%, transparent); -webkit-mask-composite: source-in; mask-image: linear-gradient(to right, transparent 22%, #000 62%), linear-gradient(to bottom, #000 72%, transparent); mask-composite: intersect; }

/* CTA + inner heroes: grain field fading in from the right */
.cta-band::before { display: none; }
.cta-band > canvas { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; -webkit-mask-image: linear-gradient(to right, transparent 10%, #000 70%); mask-image: linear-gradient(to right, transparent 10%, #000 70%); }
.feature-hero.fx-host::before, .hero.fx-host::before { display: none; }
.page-grain { -webkit-mask-image: linear-gradient(to bottom, #000 60%, transparent); mask-image: linear-gradient(to bottom, #000 60%, transparent); }

/* footer landscape */
.footer-scape { position: relative; height: 288px; margin: -64px 0 56px; overflow: hidden; border-bottom: 1px solid var(--border); }
.footer-scape canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.footer-scape .fs-grain { -webkit-mask-image: linear-gradient(to bottom, transparent, #000 35%); mask-image: linear-gradient(to bottom, transparent, #000 35%); }

/* entrance: hero copy blurs in (16px, blur 6px, 0.6s, staggered 100ms); headline words rise from a clip */
html:not(.no-js) [data-intro] { opacity: 0; transform: translateY(16px); filter: blur(6px); }
html.intro-in [data-intro] { opacity: 1; transform: none; filter: blur(0); transition: opacity .6s var(--ease-out), transform .6s var(--ease-out), filter .6s var(--ease-out); transition-delay: calc(var(--i, 0) * 100ms + 100ms); }
.words .wl { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .14em; margin-bottom: -.14em; }
html:not(.no-js) .words .w { display: inline-block; transform: translateY(110%); }
html.intro-in .words .w { transform: none; transition: transform .9s var(--ease-out); transition-delay: calc(var(--w, 0) * 70ms + 120ms); }
html:not(.no-js) .words.done .w { transform: none; transition: none; }

/* scroll reveal: 22px rise, 0.7s, siblings staggered by 70ms; section headings also un-blur */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .7s var(--ease-out), transform .7s var(--ease-out), filter .7s var(--ease-out); transition-delay: calc(var(--i, 0) * 70ms); }
.reveal.in { opacity: 1; transform: none; }
.section-head.reveal { filter: blur(6px); }
.section-head.reveal.in { filter: blur(0); }
.no-js .reveal { opacity: 1; transform: none; filter: none; }

@media (max-width: 640px) {
  .orb-wrap { height: min(92vw, 440px); }
  .orb-wrap .float-card { display: none; }
  .hero.has-ground { padding-bottom: 150px; }
  .hero-ground { height: 160px; }
  .footer-scape { height: 200px; }
  .water-band { padding: 72px 0 64px; }
  .water-band > canvas { top: 58%; height: calc(42% + 56px); }
}
@media (prefers-reduced-motion: reduce) {
  html:not(.no-js) [data-intro], html:not(.no-js) .words .w { opacity: 1; transform: none; filter: none; }
  .reveal, .section-head.reveal { filter: none; }
}

/* numbers in the serif face: always full-height lining figures, so 0 never reads as the letter o */
.display, .display-2, .stat b, .plan .price b, .kpi b, .model-card .name, .prose h2 { font-variant-numeric: lining-nums proportional-nums; }
/* docs on tablets/phones: leave room for the sticky section picker when jumping to a section */
@media (max-width: 1000px) { .prose section[id], .prose h3[id] { scroll-margin-top: 72px; } }

/* four models: "coming soon" badge next to a model name, six-up stats strip on pricing */
.model-card .name .badge { margin-left: 8px; vertical-align: middle; font-family: var(--font-mono); letter-spacing: .08em; }
.model-card.is-soon .name { color: var(--muted-fg); }
.grid.g4 > .model-card { padding: 24px; }
.stats-6 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.stats-6 .stat + .stat { border-left: 1px solid var(--border); }
.stats-6 .stat:nth-child(3n + 1) { border-left: 0; }
.stats-6 .stat:nth-child(n + 4) { border-top: 1px solid var(--border); }
.stat.is-soon b { color: var(--muted-fg); }
.stat span.badge { display: inline-flex; width: auto; margin-top: 8px; }
@media (max-width: 1000px) {
  .stats-6 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stats-6 .stat { border-left: 1px solid var(--border); border-top: 0; }
  .stats-6 .stat:nth-child(odd) { border-left: 0; }
  .stats-6 .stat:nth-child(n + 3) { border-top: 1px solid var(--border); }
}
#models table td:first-child { min-width: 124px; color: var(--muted-fg); }

/* page-to-page: cross-document view transitions; the header is its own layer so it never redraws */
@view-transition { navigation: auto; }
.site-header { view-transition-name: site-header; }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: .22s; animation-timing-function: cubic-bezier(.4, 0, .2, 1); }
::view-transition-group(site-header) { animation: none; }
@media (prefers-reduced-motion: reduce) { @view-transition { navigation: none; } }
/* canvases fade in on their first frame instead of popping */
canvas[data-fx] { opacity: 0; transition: opacity .7s cubic-bezier(.16, 1, .3, 1); }
canvas[data-fx].fx-on { opacity: 1; }

/* pricing: slimmer cards so every feature line fits on one line at 1280+ */
@media (min-width: 1120px) {
  .plans { gap: 12px; }
  .plan.card { padding: 24px 20px; }
  .plan ul { gap: 9px; font-size: 13.5px; }
  .plan .pdesc { min-height: 0; font-size: 13.5px; }
}
@media (min-width: 1200px) { .plan li, .plan .pdesc { white-space: nowrap; } }

/* ==========================================================================
   Homepage: AI-company hero, product mockups, dusk-to-night sky
   ========================================================================== */
.hp-hero .display { font-size: clamp(38px, 4.6vw, 58px); }
.hp-hero-grid { align-items: center; }

/* night sky behind the homepage: a pink dusk glow that fades as you scroll, stars appear in dark mode */
.sky, .stars { position: fixed; inset: 0; z-index: -1; pointer-events: none; }
.sky { background: radial-gradient(90% 55% at 72% -8%, color-mix(in srgb, var(--brand-mid) 22%, transparent), transparent 70%), radial-gradient(60% 40% at 8% 0%, color-mix(in srgb, var(--brand) 14%, transparent), transparent 70%); }
.stars { opacity: 0; background-image:
  radial-gradient(1px 1px at 8% 22%, #fff9, transparent 60%), radial-gradient(1px 1px at 23% 64%, #fff7, transparent 60%),
  radial-gradient(1.5px 1.5px at 37% 12%, #ffd1dccc, transparent 60%), radial-gradient(1px 1px at 52% 78%, #fff6, transparent 60%),
  radial-gradient(1px 1px at 66% 34%, #fff8, transparent 60%), radial-gradient(1.5px 1.5px at 81% 58%, #ffd1dcaa, transparent 60%),
  radial-gradient(1px 1px at 93% 16%, #fff7, transparent 60%), radial-gradient(1px 1px at 14% 88%, #fff6, transparent 60%),
  radial-gradient(1px 1px at 72% 92%, #fff6, transparent 60%), radial-gradient(1px 1px at 46% 46%, #fff5, transparent 60%); }
:root:not([data-theme="dark"]) .stars { display: none; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .stars { display: block; } }

/* --- shared mockup chrome --- */
.mk-bar { height: 36px; display: flex; align-items: center; gap: 7px; padding: 0 12px; border-bottom: 1px solid var(--border); background: var(--card-2); }
.mk-bar i { width: 9px; height: 9px; border-radius: 50%; background: var(--border-strong); }
.mk-url { margin-left: 10px; flex: 1; max-width: 260px; height: 22px; display: flex; align-items: center; padding: 0 10px; border-radius: 6px; border: 1px solid var(--border); background: var(--bg); font: 11px/1 var(--font-mono); color: var(--muted-fg); white-space: nowrap; overflow: hidden; }
.mk-thread { position: relative; display: flex; flex-direction: column; gap: 8px; padding: 14px; overflow: hidden; }
.mk-msg { position: relative; max-width: 84%; padding: 8px 11px; border-radius: 14px; font-size: 12.5px; line-height: 1.45; opacity: 0; transform: translateY(8px) scale(.98); transform-origin: bottom; transition: opacity .35s ease, transform .55s var(--ease-out); }
.mk-msg.on, .mk-sys.on, .mk-by.on { opacity: 1; transform: none; }
.mk-msg.l { align-self: flex-start; background: var(--muted); color: var(--fg); border-bottom-left-radius: 4px; }
.mk-msg.r { align-self: flex-end; background: var(--brand); color: var(--brand-fg); border-bottom-right-radius: 4px; }
.mk-msg.r.ai { background: var(--brand-soft); color: var(--fg); border: 1px solid color-mix(in srgb, var(--brand-text) 22%, transparent); }
.mk-msg.r.agent { background: var(--brand); color: var(--brand-fg); }
.mk-msg.r.ig { background: linear-gradient(135deg, #7c3aed, #db2777); color: #fff; }
.mk-msg time { display: block; margin-top: 3px; font: 10px/1 var(--font-mono); opacity: .6; }
.mk-who { display: block; margin-top: 4px; font: 10px/1 var(--font-mono); letter-spacing: .04em; opacity: .7; }
.mk-sys, .mk-by { align-self: center; font: 10.5px/1.4 var(--font-mono); letter-spacing: .04em; color: var(--muted-fg); opacity: 0; transform: translateY(6px); transition: opacity .35s ease, transform .55s var(--ease-out); text-align: center; }
.mk-sys { padding: 4px 10px; border: 1px dashed var(--border-strong); border-radius: 999px; }
.mk-by { align-self: flex-end; font-size: 9.5px; }
.mk-prod { display: flex; gap: 10px; align-items: center; margin-top: 8px; padding: 7px; border-radius: 10px; background: var(--card); border: 1px solid var(--border); color: var(--fg); }
.mk-prod i { width: 34px; height: 34px; flex: none; border-radius: 7px; background: linear-gradient(135deg, #8aa37b, #4d6b45); }
.mk-prod b { display: block; font-size: 12px; font-weight: 500; }
.mk-prod small { font-size: 11px; color: var(--muted-fg); }
.mk-chip { display: inline-flex; margin-top: 7px; padding: 3px 9px; border-radius: 999px; border: 1px solid color-mix(in srgb, var(--brand-text) 45%, transparent); color: var(--brand-text); font-size: 11.5px; font-weight: 500; }
.mk-chip.light { border-color: #ffffff80; color: #fff; }
.mk-typing { position: absolute; left: 14px; display: flex; gap: 4px; padding: 10px 12px; border-radius: 14px; border-bottom-left-radius: 4px; background: var(--muted); opacity: 0; transition: opacity .2s ease; pointer-events: none; }
.mk-typing.r { left: auto; right: 14px; border-bottom-left-radius: 14px; border-bottom-right-radius: 4px; background: var(--brand-soft); }
.mk-typing.on { opacity: 1; }
.mk-typing i { width: 5px; height: 5px; border-radius: 50%; background: var(--muted-fg); animation: blink 1s infinite; }
.mk-typing i:nth-child(2) { animation-delay: .15s; } .mk-typing i:nth-child(3) { animation-delay: .3s; }
[data-script].mk-fade .mk-msg, [data-script].mk-fade .mk-sys, [data-script].mk-fade .mk-by { opacity: 0; transform: translateY(-4px); transition-duration: .5s; }

/* --- hero stage: shop window + widget, Instagram phone, night clock --- */
.mk-stage { position: relative; height: 560px; }
.mk-par { position: absolute; inset: 0 0 48px 56px; will-change: transform; }
.mk-window { position: absolute; inset: 0; border: 1px solid var(--border-strong); border-radius: 12px; background: var(--card); overflow: hidden; box-shadow: inset 0 1px 0 rgb(255 255 255 / .04), 0 50px 100px -40px rgb(0 0 0 / .55), 0 0 0 1px rgb(0 0 0 / .02); }
.mk-shop { display: grid; grid-template-columns: 1.05fr 1fr; gap: 18px; padding: 20px; }
.mk-photo { position: relative; height: 210px; border-radius: 8px; background: radial-gradient(60% 60% at 40% 35%, #a9c19a, #5d7a54 70%), #5d7a54; }
.mk-photo-tag { position: absolute; top: 10px; left: 10px; padding: 2px 7px; border-radius: 4px; background: var(--brand); color: var(--brand-fg); font: 600 10px/1.4 var(--font-sans); }
.mk-copy { display: flex; flex-direction: column; gap: 9px; padding-top: 4px; }
.mk-line { display: block; height: 8px; border-radius: 4px; background: var(--muted); }
.mk-line.h { height: 16px; }
.mk-line.w40 { width: 40%; } .mk-line.w60 { width: 60%; } .mk-line.w70 { width: 70%; } .mk-line.w80 { width: 80%; }
.mk-price { font: 500 15px/1 var(--font-serif); color: var(--fg); margin: 4px 0; }
.mk-buy { display: block; height: 30px; width: 62%; border-radius: 6px; background: var(--fg); opacity: .85; margin-top: 4px; }
.mk-widget { position: absolute; right: 16px; bottom: 16px; top: 52px; width: 300px; display: flex; flex-direction: column; border-radius: 14px; border: 1px solid var(--border-strong); background: var(--card); overflow: hidden; box-shadow: 0 28px 60px -22px rgb(0 0 0 / .5); }
.mk-whead { display: flex; align-items: center; gap: 10px; padding: 11px 14px; background: var(--brand); color: var(--brand-fg); }
.mk-whead strong { display: block; font-size: 13px; font-weight: 600; }
.mk-whead span { display: block; font-size: 11px; opacity: .8; }
.mk-avatar svg { width: 28px; height: 28px; display: block; border-radius: 8px; box-shadow: 0 0 0 1px #5a1d3626; }
.mk-widget .mk-thread { flex: 1; }
.mk-clock { position: absolute; top: -20px; right: 12px; z-index: 3; display: flex; align-items: center; gap: 8px; padding: 8px 14px 8px 10px; border-radius: 999px; background: color-mix(in srgb, var(--card) 90%, transparent); border: 1px solid var(--border); box-shadow: 0 10px 30px -12px rgb(0 0 0 / .35); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); font-size: 12px; color: var(--muted-fg); white-space: nowrap; will-change: transform; }
.mk-clock svg { width: 15px; height: 15px; color: var(--brand-text); }
.mk-clock b { font: 500 12px/1 var(--font-mono); color: var(--fg); letter-spacing: .02em; }
.mk-phone { position: absolute; left: 0; bottom: 0; z-index: 2; width: 214px; height: 392px; padding: 7px; border-radius: 34px; background: #0d0a0c; box-shadow: inset 0 0 0 1px #ffffff1a, 0 40px 70px -24px rgb(0 0 0 / .6); will-change: transform; }
.mk-screen { height: 100%; display: flex; flex-direction: column; border-radius: 27px; background: var(--card); overflow: hidden; }
.mk-ighead { display: flex; align-items: center; gap: 9px; padding: 22px 12px 10px; border-bottom: 1px solid var(--border); }
.mk-ighead strong { display: block; font-size: 12px; font-weight: 600; }
.mk-ighead span { display: block; font-size: 10.5px; color: var(--muted-fg); }
.mk-ring { width: 28px; height: 28px; padding: 2px; border-radius: 50%; background: linear-gradient(45deg, #f59e0b, #db2777, #7c3aed); }
.mk-ring i { display: block; width: 100%; height: 100%; border-radius: 50%; border: 2px solid var(--card); background: var(--brand); }
.mk-ig { flex: 1; padding: 12px 10px; }
.mk-ig .mk-msg { font-size: 11.5px; border-radius: 16px; }
.mk-ig .mk-msg.l { border-bottom-left-radius: 16px; }
.mk-ig .mk-msg.r { border-bottom-right-radius: 16px; }

/* --- Inbox app mockup --- */
.hp-inbox { align-items: center; }
.mk-app { border: 1px solid var(--border-strong); border-radius: 12px; background: var(--card); overflow: hidden; box-shadow: inset 0 1px 0 rgb(255 255 255 / .04), 0 50px 100px -40px rgb(0 0 0 / .5); }
.mk-app-body { display: grid; grid-template-columns: 190px minmax(0, 1fr); height: 420px; }
.mk-side { display: flex; flex-direction: column; gap: 4px; padding: 12px 10px; border-right: 1px solid var(--border); background: var(--card-2); }
.mk-side-title { font: 500 11px/1 var(--font-mono); letter-spacing: .1em; text-transform: uppercase; color: var(--muted-fg); padding: 4px 6px 10px; }
.mk-row { display: flex; gap: 9px; align-items: center; padding: 8px; border-radius: 8px; font-size: 12px; }
.mk-row.hot { background: var(--brand-soft); }
.mk-row b { display: block; font-weight: 500; }
.mk-row small { display: block; font-size: 10.5px; color: var(--muted-fg); }
.mk-row .dot { width: 7px; height: 7px; border-radius: 50%; flex: none; background: var(--positive); }
.mk-row .dot.wait { background: var(--brand-text); box-shadow: 0 0 0 0 var(--brand-text); animation: ns-pulse 1.8s infinite; }
.mk-row .dot.idle { background: var(--muted-fg); }
@keyframes ns-pulse { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--brand-text) 50%, transparent); } 70% { box-shadow: 0 0 0 7px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }
.mk-pane { padding: 18px; gap: 10px; }
.mk-pane .mk-msg { font-size: 13px; max-width: 78%; }

/* --- channels strip in "how it works", languages band --- */
.hp-chans { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; padding: 0 12px; }
.hp-chans span { padding: 5px 10px; border-radius: 999px; border: 1px solid var(--border-strong); background: var(--card); font-size: 12px; }
.hp-chans span:first-child { background: var(--brand); color: var(--brand-fg); border-color: transparent; }
.hp-langchips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 28px; }
.hp-langchips span { padding: 6px 12px; border-radius: 999px; border: 1px solid var(--border); background: var(--card); font-size: 14px; transition: border-color .15s var(--ease), color .15s var(--ease); }
.hp-langchips span:hover { border-color: var(--brand-text); color: var(--brand-text); }
.hp-orb { height: clamp(360px, 38vw, 520px); }
.hp-langs .split { align-items: center; }

@media (max-width: 1000px) {
  .mk-stage { height: 560px; max-width: 620px; width: 100%; margin: 24px auto 0; }
}
@media (max-width: 640px) {
  .mk-stage { height: 520px; }
  .mk-par { inset: 0 0 0 0; }
  .mk-phone { display: none; }
  .mk-shop { grid-template-columns: 1fr; }
  .mk-photo { height: 120px; }
  .mk-copy { display: none; }
  .mk-widget { left: 12px; right: 12px; width: auto; bottom: 12px; top: 48px; }
  .mk-clock { top: -16px; right: 8px; }
  .mk-app-body { grid-template-columns: minmax(0, 1fr); height: 440px; }
  .mk-side { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .mk-row .dot.wait { animation: none; }
}

/* headings: even line lengths, no lone last word */
.display, .display-2, .h2, .section-head h2 { text-wrap: balance; }
.lede, .card p { text-wrap: pretty; }

/* ==========================================================================
   Feature pages (from docs/ROADMAP.md) + public roadmap
   ========================================================================== */
.badge.dev { color: var(--brand-text); border-color: color-mix(in srgb, var(--brand-text) 40%, transparent); background: var(--brand-soft); }
.badge.later { color: var(--muted-fg); border-style: dashed; }
.fp-hero .display { font-size: clamp(36px, 4.4vw, 56px); }
.fp-mock { position: relative; }
.fp-mock .mono-label { display: block; margin-bottom: 10px; }
.fp-kpis { margin-bottom: 12px; }
.mk-card { border: 1px solid var(--border-strong); border-radius: 12px; background: var(--card); overflow: hidden; box-shadow: inset 0 1px 0 rgb(255 255 255 / .04), 0 50px 100px -40px rgb(0 0 0 / .5); }
.fp-thread { min-height: 360px; padding: 18px; gap: 10px; }
.fp-thread .mk-msg { font-size: 13px; max-width: 82%; }
.mk-src { display: inline-block; margin: 0 6px 2px 0; padding: 1px 7px; border-radius: 999px; font: 500 10px/1.6 var(--font-mono); letter-spacing: .04em; background: var(--card); color: var(--brand-text); border: 1px solid var(--border); vertical-align: 1px; }
.mk-msg.r .mk-src { background: color-mix(in srgb, var(--card) 70%, transparent); }
.mk-code { display: block; margin-top: 8px; padding: 6px 8px; border-radius: 6px; background: var(--code-bg); color: var(--code-fg); font: 11px/1.4 var(--font-mono); overflow-wrap: anywhere; }
.fp-steps { list-style: none; margin: 0; padding: 0; counter-reset: none; }
.fp-step { padding-top: 18px; border-top: 1px solid var(--border-strong); }
.fp-n { font: 500 11px/1 var(--font-mono); letter-spacing: .12em; color: var(--brand-text); }
.fp-step h3 { margin-top: 14px; font-size: 17px; font-weight: 500; letter-spacing: -0.01em; }
.fp-step p { margin-top: 8px; font-size: 14.5px; color: var(--muted-fg); line-height: 1.6; }
.fp-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 48px; }
.fp-list li { display: flex; gap: 12px; align-items: flex-start; padding: 14px 0; border-top: 1px solid var(--border); font-size: 15px; line-height: 1.55; }
.fp-list li > span[data-icon] { flex: none; margin-top: 3px; color: var(--brand-text); }
.fp-list li > span[data-icon] svg { width: 16px; height: 16px; }
.fp-builtin { margin-top: 40px; }
.fp-builtin h3 { font-size: 15px; font-weight: 500; color: var(--muted-fg); }
.fp-builtin ol { list-style: none; margin: 14px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; counter-reset: bi; }
.fp-builtin li { counter-increment: bi; position: relative; padding: 10px 12px 10px 40px; border: 1px solid var(--border); border-radius: 8px; background: var(--card); font-size: 14px; line-height: 1.5; }
.fp-builtin li::before { content: counter(bi); position: absolute; left: 12px; top: 10px; width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-text); font: 500 10.5px/1 var(--font-mono); }
.fp-next { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.fp-next-item { padding: 18px; border: 1px dashed var(--border-strong); border-radius: 10px; background: color-mix(in srgb, var(--card) 60%, transparent); }
.fp-next-item p { margin-top: 12px; font-size: 14.5px; line-height: 1.55; }
.fp-next-note { margin-top: 20px; font-size: 13.5px; color: var(--muted-fg); }
.fp-next-note a { margin-left: 4px; }
.rm-cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; align-items: start; }
.rm-col { border: 1px solid var(--border); border-radius: 12px; background: var(--card); padding: 20px; }
.rm-head { padding-bottom: 16px; margin-bottom: 4px; border-bottom: 1px solid var(--border); }
.rm-head h2 { margin-top: 12px; font-family: var(--font-serif); font-weight: 400; font-size: 28px; letter-spacing: -0.02em; }
.rm-head p { margin-top: 6px; font-size: 13.5px; color: var(--muted-fg); }
.rm-group { padding: 14px 0 4px; }
.rm-group + .rm-group { border-top: 1px dashed var(--border); }
.rm-group h3 { font: 500 11px/1.4 var(--font-mono); letter-spacing: .1em; text-transform: uppercase; color: var(--brand-text); }
.rm-group h3 a { text-decoration: none; color: inherit; }
.rm-group h3 a:hover { text-decoration: underline; text-underline-offset: 3px; }
.rm-group ul { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 8px; }
.rm-group li { position: relative; padding-left: 14px; font-size: 14.5px; line-height: 1.5; }
.rm-group li::before { content: ""; position: absolute; left: 0; top: .6em; width: 5px; height: 5px; border-radius: 50%; background: var(--brand-mid); }
.rm-shipped b { font-weight: 500; margin-right: 6px; }
@media (max-width: 1000px) { .rm-cols { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 640px) {
  .fp-list, .fp-builtin ol { grid-template-columns: minmax(0, 1fr); }
  .fp-thread { min-height: 0; }
}

/* ==========================================================================
   Realistic mockups v2: chat rows with avatars, hero scene, widget, Instagram phone, Inbox
   Pure HTML/CSS/SVG. The hero scene is drawn at a fixed design size and scaled as one
   piece to its column (tan(atan2()) turns the length ratio into a number), so the parts
   can never collide at any width.
   ========================================================================== */
.i { width: 16px; height: 16px; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.i.fill { fill: currentColor; stroke: none; }
.i .dotfill { fill: currentColor; stroke: none; }

/* headline word reveal: clip only below the line, so Vietnamese marks and ascenders are never cut */
.words .wl { overflow: visible; clip-path: inset(-0.6em -0.3em 0 -0.3em); }

/* ---------- avatars ---------- */
.mk-av { position: relative; width: 24px; height: 24px; flex: none; border-radius: 50%; display: grid; place-items: center;
  font: 600 9px/1 var(--font-sans); letter-spacing: .02em; color: #fff; }
.mk-av.ai > span { display: block; width: 100%; height: 100%; }
.mk-av.ai svg { width: 100%; height: 100%; display: block; border-radius: 50%; }
.mk-av.shop { background: #3f4a2e url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 8h14l-1 12H6z'/%3E%3Cpath d='M9 8V6a3 3 0 0 1 6 0v2'/%3E%3C/svg%3E") center / 56% no-repeat; }
.mk-av.c1 { background: linear-gradient(135deg, #f59e0b, #e2557a); }
.mk-av.c2 { background: linear-gradient(135deg, #8b5cf6, #ec4899); }
.mk-av.c3 { background: linear-gradient(135deg, #0ea5e9, #6366f1); }
.mk-av.c4 { background: linear-gradient(135deg, #10b981, #0e7490); }
.mk-av.c5 { background: linear-gradient(135deg, #f97316, #b45309); }
.mk-av.team { background: linear-gradient(135deg, #5a1d36, #b83a68); }
.mk-ch { position: absolute; right: -3px; bottom: -3px; width: 13px; height: 13px; border-radius: 50%; display: grid; place-items: center; box-shadow: 0 0 0 2px var(--card); color: #fff; }
.mk-ch .i { width: 8px; height: 8px; stroke-width: 2.6; }
.mk-ch.web { background: #64748b; }
.mk-ch.ms { background: linear-gradient(135deg, #0a7cff, #a033ff); }
.mk-ch.ms .i { width: 9px; height: 9px; }
.mk-ch.dc { background: #5865f2; }
.mk-ch.ig { background: conic-gradient(from 200deg, #f9ce34, #ee2a7b, #6228d7, #f9ce34); }
.mk-ch.ig i { width: 6px; height: 6px; border-radius: 2px; border: 1.5px solid #fff; }

/* ---------- chat rows ---------- */
.mk-flow { position: relative; display: flex; flex-direction: column; justify-content: flex-end; gap: 7px; min-height: 0; overflow: hidden; padding: 12px;
  -webkit-mask-image: linear-gradient(to bottom, transparent, #000 26px); mask-image: linear-gradient(to bottom, transparent, #000 26px); }
.mk-flow > [data-step]:not(.on), .mk-flow > .mk-typer:not(.on) { display: none; }
.mk-flow > [data-step].on, .mk-flow > .mk-typer.on { animation: mk-in .42s var(--ease-out) both; }
.mk-flow > .mk-t { transition: opacity .45s ease; }
.mk-flow.mk-fade > .mk-t { opacity: 0; }
@keyframes mk-in { from { opacity: 0; transform: translateY(10px) scale(.97); } }
.mk-m { display: flex; align-items: flex-end; gap: 7px; max-width: 88%; flex: none; }
.mk-m.in { align-self: flex-start; }
.mk-m.out { align-self: flex-end; flex-direction: row-reverse; }
.mk-m > .mk-av { margin-bottom: 15px; }
.mk-col { display: flex; flex-direction: column; min-width: 0; }
.mk-m.out .mk-col { align-items: flex-end; }
.mk-b { display: block; padding: 7px 11px; border-radius: 16px; font-size: 12.5px; line-height: 1.45; background: var(--muted); color: var(--fg); overflow-wrap: anywhere; }
.mk-m.in .mk-b { border-bottom-left-radius: 5px; }
.mk-m.out .mk-b { border-bottom-right-radius: 5px; background: var(--brand); color: var(--brand-fg); }
.mk-m.out .mk-b.ai { background: var(--brand-soft); color: var(--fg); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--brand-text) 22%, transparent); }
.mk-m.out .mk-b.agent { background: var(--fg); color: var(--bg); }
.mk-m.out .mk-b.ig { background: linear-gradient(160deg, #a033ff, #5b51f7); color: #fff; border-bottom-right-radius: 16px; }
.mk-meta { display: flex; align-items: center; gap: 4px; margin-top: 3px; padding: 0 4px; font: 400 9.5px/1.2 var(--font-sans); color: var(--muted-fg); white-space: nowrap; }
.mk-meta b { font-weight: 600; color: var(--brand-text); }
.mk-meta b + time::before { content: "·"; margin-right: 4px; }
.mk-meta .ticks { width: 13px; height: 13px; color: #3b82f6; stroke-width: 2.2; }
.mk-note { align-self: center; flex: none; padding: 3px 10px; border-radius: 999px; background: var(--muted); color: var(--muted-fg); font: 500 10px/1.5 var(--font-sans); text-align: center; }
.mk-typer .mk-b { display: flex; gap: 4px; padding: 11px 12px; }
.mk-typer .mk-b i { width: 5px; height: 5px; border-radius: 50%; background: var(--muted-fg); animation: mk-dot 1.1s infinite; }
.mk-typer .mk-b i:nth-child(2) { animation-delay: .15s; } .mk-typer .mk-b i:nth-child(3) { animation-delay: .3s; }
.mk-typer.out .mk-b { background: var(--brand-soft); }
.mk-typer > .mk-av { margin-bottom: 0; }
@keyframes mk-dot { 0%, 60%, 100% { opacity: .3; transform: none; } 30% { opacity: 1; transform: translateY(-2px); } }

/* product / link card inside a bubble */
.mk-pcard { display: flex; gap: 9px; align-items: center; margin: 7px -4px -2px; padding: 6px; border-radius: 12px; background: var(--card); color: var(--fg); box-shadow: 0 0 0 1px var(--border); }
.mk-pcard .ph { width: 44px; height: 44px; flex: none; border-radius: 9px; }
.mk-pcard .pc { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.mk-pcard b { font-size: 11.5px; font-weight: 600; white-space: nowrap; }
.mk-pcard .pr { font-size: 11px; font-weight: 500; white-space: nowrap; }
.mk-pcard s { margin-left: 5px; font-weight: 400; color: var(--muted-fg); }
.mk-pcard .go { font-size: 10.5px; font-weight: 600; color: var(--brand-text); }

/* drawn product photos: an olive backpack and a cream linen shirt on a studio backdrop */
.mk-bp { background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 120'%3E%3Cellipse cx='50' cy='113' rx='31' ry='4' fill='%23000' opacity='.13'/%3E%3Cpath d='M38 18a12 12 0 0 1 24 0v5h-5v-5a7 7 0 0 0-14 0v5h-5z' fill='%23384228'/%3E%3Cpath d='M22 40c-6 4-7 30-5 52 1 7 4 10 8 9' fill='none' stroke='%23465234' stroke-width='5' stroke-linecap='round'/%3E%3Crect x='20' y='20' width='60' height='92' rx='22' fill='%236b7b4a'/%3E%3Cpath d='M20 46a22 22 0 0 1 22-26h16a22 22 0 0 1 22 26z' fill='%23798a55'/%3E%3Cpath d='M26 47h48' stroke='%23465234' stroke-width='2.2' stroke-linecap='round'/%3E%3Crect x='47' y='45' width='6' height='11' rx='2' fill='%23d6c18f'/%3E%3Crect x='29' y='66' width='42' height='36' rx='11' fill='%235e6c40'/%3E%3Cpath d='M35 74h30' stroke='%23404b2c' stroke-width='2' stroke-linecap='round'/%3E%3Crect x='56' y='72' width='5' height='9' rx='1.5' fill='%23d6c18f'/%3E%3Cpath d='M30 28c4-4 10-6 16-6' stroke='%23fff' stroke-opacity='.25' stroke-width='3' stroke-linecap='round' fill='none'/%3E%3C/svg%3E") center 58% / auto 78% no-repeat,
  radial-gradient(80% 70% at 50% 40%, #f6f2ea, #e5ddcd); }
.mk-shirt { background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Cpath d='M36 14l-20 10-8 22 13 5 5-10v49h48V41l5 10 13-5-8-22-20-10c-2 6-8 10-14 10s-12-4-14-10z' fill='%23f1e7d3' stroke='%23c9b893' stroke-width='2' stroke-linejoin='round'/%3E%3Cpath d='M50 24v62' stroke='%23c9b893' stroke-width='1.5'/%3E%3Ccircle cx='50' cy='38' r='1.6' fill='%23b7a47c'/%3E%3Ccircle cx='50' cy='52' r='1.6' fill='%23b7a47c'/%3E%3Ccircle cx='50' cy='66' r='1.6' fill='%23b7a47c'/%3E%3C/svg%3E") center / 78% no-repeat,
  linear-gradient(160deg, #c9d6c4, #9fb29a); }

/* composer + powered-by line (same look as the real widget) */
.mk-compose { display: flex; align-items: center; gap: 8px; margin: 0 10px 6px; padding: 5px 5px 5px 13px; border: 1px solid var(--border-strong); border-radius: 20px; background: var(--card); color: var(--muted-fg); font-size: 12px; flex: none; }
.mk-compose > span:first-child { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mk-compose .send { width: 28px; height: 28px; flex: none; border-radius: 50%; display: grid; place-items: center; background: var(--brand); color: var(--brand-fg); }
.mk-compose .send .i { width: 13px; height: 13px; }
.mk-powered { display: flex; align-items: center; justify-content: center; gap: 5px; padding: 1px 0 9px; font-size: 10px; color: var(--muted-fg); flex: none; }
.mk-powered .i { width: 10px; height: 10px; color: var(--brand-text); }
.mk-who2 { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.mk-who2 b { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mk-who2 small { display: flex; align-items: center; gap: 5px; font-size: 10.5px; color: var(--muted-fg); white-space: nowrap; }
.mk-who2 .live { width: 7px; height: 7px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 2.5px color-mix(in srgb, #22c55e 25%, transparent); }

/* ---------- hero scene ---------- */
.hp-hero .mk-stage { position: relative; height: auto; width: 100%; max-width: 660px; margin: 0 0 0 auto; aspect-ratio: 660 / 600; container-type: inline-size; }
.mk-scene { position: absolute; left: 0; top: 0; width: 660px; height: 600px; transform-origin: 0 0; transform: scale(tan(atan2(100cqw, 660px))); }
.mk-scene .mk-par { inset: 0 0 auto 170px; height: 560px; }
.mk-scene .mk-clock { top: 0; right: 0; }
.mk-scene .mk-clock b { font-size: 12.5px; }
.mk-scene .mk-window { inset: 50px 0 0 0; }
.mk-url .i { width: 11px; height: 11px; margin-right: 6px; color: var(--positive); }
.mk-site { position: absolute; top: 38px; left: 0; right: 0; bottom: 0; background: var(--card); }
.mk-nav { display: flex; align-items: center; gap: 14px; height: 40px; padding: 0 16px 0 18px; border-bottom: 1px solid var(--border); font-size: 11.5px; }
.mk-logo { display: flex; align-items: center; gap: 7px; font: 600 14px/1 var(--font-serif); letter-spacing: -0.01em; }
.mk-logo .mk-av { width: 20px; height: 20px; }
.mk-links { display: flex; gap: 12px; color: var(--muted-fg); }
.mk-navic { display: flex; gap: 10px; margin-left: auto; color: var(--fg); }
.mk-navic .i { width: 14px; height: 14px; }
.mk-pdp { display: flex; flex-direction: column; align-items: flex-start; width: 190px; padding: 14px 0 0 18px; box-sizing: content-box; }
.mk-photo { position: relative; width: 100%; height: 138px; border-radius: 10px; }
.mk-photo-tag { position: absolute; top: 8px; left: 8px; padding: 2px 7px; border-radius: 5px; background: #d9364f; color: #fff; font: 700 10px/1.4 var(--font-sans); }
.mk-fav { position: absolute; top: 7px; right: 7px; width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: #ffffffd9; color: #3b3b3b; }
.mk-fav .i { width: 12px; height: 12px; }
.mk-dots { display: flex; gap: 4px; align-self: center; margin: 7px 0 9px; }
.mk-dots i { width: 5px; height: 5px; border-radius: 50%; background: var(--border-strong); }
.mk-dots i.on { width: 14px; border-radius: 3px; background: var(--fg); }
.mk-crumb { font-size: 9.5px; color: var(--muted-fg); }
.mk-title { margin-top: 3px; font: 500 16px/1.2 var(--font-serif); letter-spacing: -0.01em; }
.mk-stars { display: flex; align-items: center; gap: 5px; margin-top: 4px; font-size: 9.5px; color: var(--muted-fg); white-space: nowrap; }
.mk-stars .st { color: #f2a93b; letter-spacing: 1px; font-size: 10.5px; }
.mk-pricing { display: flex; align-items: baseline; gap: 7px; margin-top: 7px; white-space: nowrap; }
.mk-pricing b { font-size: 14.5px; font-weight: 700; color: #c2304a; }
.mk-pricing s { font-size: 10.5px; color: var(--muted-fg); }
.mk-label { margin-top: 9px; font-size: 10px; color: var(--muted-fg); }
.mk-label b { color: var(--fg); font-weight: 600; }
.mk-swatches { display: flex; gap: 7px; margin-top: 5px; }
.mk-swatches i { width: 17px; height: 17px; border-radius: 50%; box-shadow: inset 0 0 0 1px #0000001f; }
.mk-swatches i.on { box-shadow: 0 0 0 2px var(--card), 0 0 0 3.5px var(--fg); }
.mk-swatches .olive { background: #6b7b4a; } .mk-swatches .sand { background: #d2bf98; } .mk-swatches .black { background: #26262a; } .mk-swatches .navy { background: #2c3e5c; }
.mk-sizes { display: flex; gap: 6px; margin-top: 10px; }
.mk-sizes i { font: 500 10.5px/1 var(--font-sans); padding: 6px 10px; border-radius: 7px; border: 1px solid var(--border-strong); color: var(--muted-fg); }
.mk-sizes i.on { border-color: var(--fg); color: var(--fg); box-shadow: inset 0 0 0 .5px var(--fg); }
.mk-addcart { display: flex; align-items: center; justify-content: center; gap: 7px; align-self: stretch; margin-top: 11px; height: 32px; border-radius: 8px; background: var(--fg); color: var(--bg); font-size: 12px; font-weight: 600; white-space: nowrap; }
.mk-addcart .i { width: 13px; height: 13px; }
.mk-perk { display: flex; align-items: center; gap: 5px; margin-top: 8px; font-size: 9.5px; color: var(--muted-fg); white-space: nowrap; }
.mk-perk .i { width: 11px; height: 11px; color: var(--positive); }

.mk-scene .mk-widget { top: 50px; right: 12px; bottom: 12px; width: 258px; border-radius: 18px; background: var(--card); box-shadow: 0 30px 60px -18px rgb(0 0 0 / .35), 0 0 0 1px var(--border-strong); border: 0; }
.mk-wbar { display: flex; align-items: center; gap: 9px; padding: 10px 10px 10px 8px; border-bottom: 1px solid var(--border); flex: none; color: var(--muted-fg); }
.mk-wbar .mk-av { width: 30px; height: 30px; border-radius: 10px; }
.mk-wbar .i { width: 15px; height: 15px; }
.mk-widget .mk-flow { flex: 1; }
.mk-widget .mk-b { font-size: 12px; }
.mk-widget .mk-m > .mk-av { width: 20px; height: 20px; }

.mk-toast { position: absolute; left: 0; top: 72px; width: 152px; z-index: 2; display: flex; gap: 9px; align-items: flex-start; padding: 10px 11px; border-radius: 14px;
  background: color-mix(in srgb, var(--card) 94%, transparent); box-shadow: 0 18px 40px -16px rgb(0 0 0 / .35), 0 0 0 1px var(--border-strong); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.mk-toast .mk-av { width: 26px; height: 26px; border-radius: 8px; }
.mk-toast b { font-size: 11.5px; font-weight: 600; white-space: nowrap; }
.mk-toast small { font-size: 10px; white-space: nowrap; }
.mk-toast small.dim { color: var(--muted-fg); }

/* Instagram-style phone (generic gradient ring, no logo) */
.mk-scene .mk-phone { left: 0; top: 196px; bottom: auto; width: 180px; height: 404px; padding: 6px; border-radius: 32px; }
.mk-phone .mk-screen { border-radius: 26px; }
.mk-status { display: flex; justify-content: space-between; align-items: center; padding: 7px 14px 2px 18px; font-size: 10px; flex: none; }
.mk-status b { font-weight: 600; }
.mk-status span { display: flex; gap: 3px; align-items: center; }
.mk-status .i { width: 11px; height: 11px; }
.mk-phone .mk-ighead { display: flex; align-items: center; gap: 7px; padding: 8px 9px 8px 5px; border-bottom: 1px solid var(--border); color: var(--fg); flex: none; }
.mk-ighead > .i { width: 14px; height: 14px; }
.mk-ighead > .i:first-child { width: 16px; height: 16px; }
.mk-phone .mk-ring { width: 28px; height: 28px; padding: 2px; flex: none; border-radius: 50%; background: conic-gradient(from 200deg, #f9ce34, #ee2a7b, #6228d7, #f9ce34); }
.mk-ring .mk-av { width: 100%; height: 100%; box-shadow: 0 0 0 2px var(--card); }
.mk-ighead .mk-who2 b { font-size: 11.5px; }
.mk-ighead .mk-who2 small { font-size: 9px; }
.mk-igflow { flex: 1; padding: 10px 8px; gap: 5px; }
.mk-igflow .mk-b { font-size: 11px; padding: 6px 10px; border-radius: 16px; }
.mk-igflow .mk-m.in .mk-b { border-bottom-left-radius: 16px; }
.mk-igflow .mk-m > .mk-av { width: 18px; height: 18px; margin-bottom: 0; }
.mk-igflow .mk-m.in:has(.mk-meta) > .mk-av { margin-bottom: 15px; }
.mk-igflow .mk-pcard { margin: 6px -5px -1px; padding: 5px; }
.mk-igflow .mk-pcard .ph { width: 36px; height: 36px; }
.mk-igflow .mk-pcard b { font-size: 10.5px; }
.mk-igflow .mk-meta { font-size: 8.5px; }
.mk-iginput { display: flex; align-items: center; gap: 7px; margin: 4px 7px 9px; padding: 4px 9px 4px 4px; border-radius: 999px; background: var(--muted); color: var(--fg); flex: none; }
.mk-iginput .cam { width: 24px; height: 24px; flex: none; border-radius: 50%; display: grid; place-items: center; background: linear-gradient(135deg, #3b82f6, #6366f1); color: #fff; }
.mk-iginput .cam .i { width: 12px; height: 12px; }
.mk-iginput .ph { flex: 1; font-size: 10.5px; color: var(--muted-fg); white-space: nowrap; overflow: hidden; }
.mk-iginput > .i { width: 13px; height: 13px; }

/* ---------- Inbox mockup ---------- */
.hp-inbox .mk-app-body { grid-template-columns: 228px minmax(0, 1fr); height: 450px; }
.mk-list { display: flex; flex-direction: column; border-right: 1px solid var(--border); background: var(--card-2); min-width: 0; overflow: hidden; }
.mk-list-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 12px 12px 10px; }
.mk-list-head > b { font-size: 14px; font-weight: 600; }
.mk-tabs { display: flex; gap: 4px; }
.mk-tabs i { font: 500 10px/1 var(--font-sans); padding: 5px 7px; border-radius: 999px; color: var(--muted-fg); white-space: nowrap; }
.mk-tabs i.on { background: var(--card); color: var(--fg); box-shadow: 0 0 0 1px var(--border-strong); }
.mk-conv { display: flex; gap: 9px; padding: 9px 12px; border-top: 1px solid var(--border); }
.mk-conv.sel { background: var(--brand-soft); box-shadow: inset 3px 0 0 var(--brand-text); }
.mk-conv .mk-av { width: 30px; height: 30px; font-size: 10.5px; }
.mk-cbody { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
.mk-cbody .top { display: flex; justify-content: space-between; gap: 6px; }
.mk-cbody .top b { font-size: 12px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mk-cbody time { font-size: 10px; color: var(--muted-fg); flex: none; }
.mk-cbody .prev { font-size: 11px; color: var(--muted-fg); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mk-conv.sel .prev, .mk-conv:has(.unread) .prev { color: var(--fg); }
.mk-cbody .bot { display: flex; align-items: center; justify-content: space-between; margin-top: 2px; }
.mk-cbody .unread { width: 8px; height: 8px; border-radius: 50%; background: var(--brand-text); }
.mk-chip2 { font: 600 9.5px/1 var(--font-sans); padding: 3px 7px; border-radius: 999px; white-space: nowrap; }
.mk-chip2.need { background: #d9364f; color: #fff; }
.mk-chip2.ai { background: color-mix(in srgb, var(--positive) 16%, transparent); color: var(--positive); }
.mk-chip2.closed { background: var(--muted); color: var(--muted-fg); }
.mk-pane2 { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.mk-phead { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-bottom: 1px solid var(--border); flex: none; }
.mk-phead > .mk-av { width: 32px; height: 32px; font-size: 11px; }
.mk-assign { display: flex; align-items: center; gap: 6px; padding: 3px 9px 3px 3px; border-radius: 999px; border: 1px solid var(--border-strong); font-size: 11px; white-space: nowrap; }
.mk-assign .mk-av { width: 20px; height: 20px; font-size: 9px; }
.mk-pane2 .mk-flow { flex: 1; padding: 14px 16px; }
.mk-pane2 .mk-b { font-size: 12.5px; }
.mk-pane2 .mk-m { max-width: 80%; }

/* ---------- feature-page chat cards ---------- */
.fp-flow { height: 380px; }
.mk-card .mk-wbar { padding: 10px 14px; }
.mk-card .mk-wbar .mk-av { width: 30px; height: 30px; font-size: 11px; }

/* ---------- breakpoints ---------- */
@media (min-width: 1001px) {
  .hp-hero-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1.12fr); }
}
@media (max-width: 1000px) {
  .hp-hero .mk-stage { height: auto; max-width: 660px; margin: 24px auto 0; }
}
@media (max-width: 640px) {
  .hp-hero .mk-stage { height: auto; aspect-ratio: 400 / 540; }
  .mk-scene { width: 400px; height: 540px; transform: scale(tan(atan2(100cqw, 400px))); }
  .mk-scene .mk-par { inset: 0; height: 540px; }
  .mk-toast, .mk-scene .mk-phone, .mk-site { display: none; }
  .mk-scene .mk-widget { left: 10px; right: 10px; width: auto; top: 48px; bottom: 10px; }
  .mk-scene .mk-clock { top: 0; right: 0; }
  .hp-inbox .mk-app-body { grid-template-columns: minmax(0, 1fr); height: 460px; }
  .mk-list { display: none; }
  .fp-flow { height: 340px; }
}
@media (prefers-reduced-motion: reduce) {
  .mk-flow > [data-step].on, .mk-flow > .mk-typer.on { animation: none; }
  .mk-typer .mk-b i { animation: none; }
}
.mk-chan { position: absolute; left: 6px; top: -30px; display: flex; align-items: center; gap: 6px; padding: 4px 10px 4px 5px; border-radius: 999px; background: var(--card); box-shadow: 0 0 0 1px var(--border-strong), 0 10px 24px -12px rgb(0 0 0 / .3); font-size: 11px; font-weight: 600; color: var(--fg); }
.mk-chan .mk-ch { position: static; width: 16px; height: 16px; box-shadow: none; }
.mk-chan .mk-ch i { width: 7px; height: 7px; }
.mk-ighead .mk-who2 b { font-size: 11px; }
.mk-ighead .mk-who2 small { display: block; overflow: hidden; text-overflow: ellipsis; }
.mk-pcard b { white-space: normal; }
.mk-ighead > .i { width: 12px; height: 12px; }
.mk-phone .mk-ighead { gap: 6px; }
.mk-ighead .mk-who2 b { font-size: 10.5px; }
.mk-igflow .mk-pcard { flex-direction: column; align-items: stretch; gap: 5px; width: 112px; }
.mk-igflow .mk-pcard .ph { width: auto; height: 58px; border-radius: 8px; }
.mk-igflow .mk-pcard .pc { padding: 0 2px 1px; }
.mk-scene .mk-window { top: 60px; }
@media (max-width: 640px) { .mk-scene .mk-widget { top: 46px; } }
.mk-phone .mk-ighead { padding: 8px 6px 8px 4px; }
.mk-phone .mk-ring { width: 26px; height: 26px; }
.mk-ighead .mk-who2 small { font-size: 8.5px; }
.hero-note { text-wrap: pretty; }

/* ==========================================================================
   Roadmap by quarter (/roadmap/) + quarter labels on feature pages
   ========================================================================== */
.rm-hero { padding-bottom: 40px; }
.rm-updated { display: inline-flex; align-items: center; gap: 7px; margin-top: 18px; font: 500 12px/1 var(--font-mono); letter-spacing: .04em; color: var(--muted-fg); }
.rm-updated svg { width: 14px; height: 14px; }
.rm-st { display: inline-flex; align-items: center; gap: 6px; padding: 4px 9px; border-radius: 999px; font: 600 11px/1 var(--font-sans); white-space: nowrap; flex: none; }
.rm-st svg { width: 11px; height: 11px; stroke-width: 3; }
.rm-st.shipped { background: color-mix(in srgb, var(--positive) 14%, transparent); color: var(--positive); }
.rm-st.progress { background: var(--brand-soft); color: var(--brand-text); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--brand-text) 30%, transparent); }
.rm-st.progress i { width: 6px; height: 6px; border-radius: 50%; background: var(--brand-text); animation: ns-pulse 1.8s infinite; }
.rm-st.planned { color: var(--muted-fg); box-shadow: inset 0 0 0 1px var(--border-strong); }

/* quarter rail */
.rm-rail { position: relative; margin-top: 44px; padding-top: 34px; }
.rm-rail ol { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); position: relative; }
.rm-rail ol::before, .rm-rail ol::after { content: ""; position: absolute; top: 7px; left: 10%; height: 2px; border-radius: 2px; }
.rm-rail ol::before { right: 10%; background: repeating-linear-gradient(90deg, var(--border-strong) 0 6px, transparent 6px 11px); }
.rm-rail ol::after { width: 28%; background: linear-gradient(90deg, var(--positive), var(--brand-text) 72%, color-mix(in srgb, var(--brand-text) 0%, transparent)); }
.rm-rail li { position: relative; z-index: 1; }
.rm-rail a { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; text-decoration: none; color: inherit; padding: 0 4px 6px; border-radius: 10px; transition: transform .2s var(--ease-out); }
.rm-rail a:hover { transform: translateY(-2px); }
.rm-rail a:hover b { color: var(--brand-text); }
.rm-dot { width: 16px; height: 16px; border-radius: 50%; background: var(--bg); box-shadow: inset 0 0 0 2px var(--border-strong); }
.rm-rail .shipped .rm-dot { background: var(--positive); box-shadow: 0 0 0 4px color-mix(in srgb, var(--positive) 18%, transparent); }
.rm-rail .progress .rm-dot { background: var(--brand-text); box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand-text) 20%, transparent); animation: ns-pulse 1.8s infinite; }
.rm-rail b { margin-top: 6px; font: 400 22px/1 var(--font-serif); letter-spacing: -0.01em; white-space: nowrap; transition: color .15s; }
.rm-rail small { font-size: 12.5px; color: var(--muted-fg); white-space: nowrap; }
.rm-rail .rm-st { margin-top: 2px; }
.rm-here { position: absolute; top: 0; left: 20%; transform: translateX(-50%); display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; background: var(--fg); color: var(--bg); font: 600 11px/1 var(--font-sans); white-space: nowrap; box-shadow: 0 8px 20px -10px rgb(0 0 0 / .45); }
.rm-here::after { content: ""; position: absolute; left: 50%; bottom: -4px; width: 8px; height: 8px; background: inherit; transform: translateX(-50%) rotate(45deg); border-radius: 1px; }
.rm-here i { width: 6px; height: 6px; border-radius: 50%; background: var(--brand); }

/* filters */
.rm-filterbar { position: sticky; top: var(--header-h); z-index: 20; padding: 10px 0; background: color-mix(in srgb, var(--bg) 86%, transparent); backdrop-filter: saturate(140%) blur(12px); -webkit-backdrop-filter: saturate(140%) blur(12px); border-bottom: 1px solid var(--border); }
.rm-filters { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding: 2px; }
.rm-filters::-webkit-scrollbar { display: none; }
.rm-filters button { flex: none; display: inline-flex; align-items: center; gap: 7px; height: 34px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--border-strong); background: var(--card); color: var(--fg); font: 500 13px/1 var(--font-sans); cursor: pointer; white-space: nowrap; transition: background .15s, color .15s, border-color .15s, transform .15s; }
.rm-filters button:hover { border-color: var(--brand-text); color: var(--brand-text); }
.rm-filters button:active { transform: scale(.97); }
.rm-filters button svg { width: 14px; height: 14px; }
.rm-filters .n { font: 500 11px/1 var(--font-mono); color: var(--muted-fg); }
.rm-filters button[aria-pressed="true"] { background: var(--fg); border-color: var(--fg); color: var(--bg); }
.rm-filters button[aria-pressed="true"] .n { color: color-mix(in srgb, var(--bg) 70%, transparent); }

/* cards */
.rm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); gap: 12px; }
.rm-card { position: relative; display: flex; flex-direction: column; gap: 8px; padding: 18px 18px 20px; border-radius: 14px; border: 1px solid var(--border); background: var(--card); overflow: hidden;
  transition: transform .25s var(--ease-out), border-color .2s, box-shadow .25s; }
.rm-card::before { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity .25s;
  background: radial-gradient(260px circle at var(--mx, 50%) var(--my, 0%), color-mix(in srgb, var(--brand) 22%, transparent), transparent 70%); }
.rm-card:hover { transform: translateY(-3px); border-color: color-mix(in srgb, var(--brand-text) 35%, var(--border)); box-shadow: 0 24px 50px -30px rgb(0 0 0 / .45); }
.rm-card:hover::before { opacity: 1; }
.rm-card > * { position: relative; }
.rm-card-top { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-bottom: 4px; }
.rm-card-top .rm-st { margin-left: auto; }
.rm-area { display: inline-flex; align-items: center; gap: 5px; padding: 4px 9px 4px 7px; border-radius: 999px; background: var(--muted); color: var(--fg); font: 500 11.5px/1 var(--font-sans); text-decoration: none; white-space: nowrap; transition: background .15s, color .15s; }
.rm-area:hover { background: var(--brand-soft); color: var(--brand-text); }
.rm-area svg { width: 12px; height: 12px; color: var(--brand-text); }
.rm-card h3 { font-size: 16.5px; font-weight: 500; letter-spacing: -0.01em; line-height: 1.3; text-wrap: balance; }
.rm-card p { font-size: 14px; line-height: 1.55; color: var(--muted-fg); text-wrap: pretty; }
.rm-card.progress { border-color: color-mix(in srgb, var(--brand-text) 28%, var(--border)); }
.rm-bar { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: color-mix(in srgb, var(--brand-text) 14%, transparent); overflow: hidden; }
.rm-bar::after { content: ""; position: absolute; top: 0; bottom: 0; left: -40%; width: 40%; border-radius: 3px; background: linear-gradient(90deg, transparent, var(--brand-text), transparent); animation: rm-slide 2.4s var(--ease) infinite; }
@keyframes rm-slide { to { left: 100%; } }
.rm-card[hidden] { display: none; }
::view-transition-old(*), ::view-transition-new(*) { animation-duration: .28s; }

/* shipped block (changelog) */
.rm-shipbox { padding: 28px; border-radius: 18px; border: 1px solid color-mix(in srgb, var(--positive) 30%, var(--border)); background: linear-gradient(180deg, color-mix(in srgb, var(--positive) 7%, var(--card)), var(--card) 160px); }
.rm-shiphead { display: flex; align-items: center; gap: 16px; margin-bottom: 22px; }
.rm-shiphead > div { flex: 1; min-width: 0; }
.rm-shiphead p { margin-top: 6px; color: var(--muted-fg); font-size: 14.5px; }
.rm-shipicon { width: 44px; height: 44px; flex: none; border-radius: 12px; display: grid; place-items: center; background: var(--positive); color: var(--bg); }
.rm-shipicon svg { width: 22px; height: 22px; stroke-width: 2.6; }
.rm-shipbox .rm-card { background: var(--card); }
.rm-count { font-size: 13px; color: var(--muted-fg); white-space: nowrap; }
.rm-count b { font: 500 13px/1 var(--font-mono); color: var(--fg); }

/* timeline */
.rm-timeline .container { position: relative; }
.rm-q { position: relative; display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 32px; padding: 8px 0 48px; }
.rm-q::before { content: ""; position: absolute; left: 7px; top: 16px; bottom: 0; width: 2px; background: repeating-linear-gradient(180deg, var(--border-strong) 0 6px, transparent 6px 11px); }
.rm-q:last-child::before { display: none; }
.rm-q.progress::before { background: linear-gradient(180deg, var(--brand-text), var(--border-strong)); }
.rm-qhead { position: sticky; top: calc(var(--header-h) + 76px); align-self: start; padding-left: 34px; }
.rm-node { position: absolute; left: 0; top: 8px; width: 16px; height: 16px; border-radius: 50%; background: var(--bg); box-shadow: inset 0 0 0 2px var(--border-strong); }
.rm-q.progress .rm-node { background: var(--brand-text); box-shadow: 0 0 0 5px color-mix(in srgb, var(--brand-text) 18%, transparent); }
.rm-qhead h2 { font: 400 34px/1 var(--font-serif); letter-spacing: -0.02em; white-space: nowrap; }
.rm-qhead p { margin-top: 8px; font-size: 13.5px; color: var(--muted-fg); white-space: nowrap; }
.rm-qmeta { display: flex; align-items: center; gap: 10px; margin-top: 14px; flex-wrap: wrap; }
.rm-empty { padding: 22px; border: 1px dashed var(--border-strong); border-radius: 14px; color: var(--muted-fg); font-size: 14px; text-align: center; }
.rm-q.is-empty .rm-grid { display: none; }

/* feature pages: quarter label on "Coming next" */
.fp-next-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.rm-qlabel { font: 500 12px/1 var(--font-mono); letter-spacing: .06em; color: var(--brand-text); white-space: nowrap; }
.fp-next-item b { display: block; margin-top: 14px; font-size: 15.5px; font-weight: 500; }
.fp-next-item b + p { margin-top: 6px; font-size: 14px; color: var(--muted-fg); }

@media (max-width: 900px) {
  .rm-q { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .rm-qhead { position: relative; top: auto; }
}
@media (max-width: 640px) {
  .rm-rail { overflow-x: auto; scrollbar-width: none; margin-left: -16px; margin-right: -16px; padding-left: 16px; padding-right: 16px; }
  .rm-rail::-webkit-scrollbar { display: none; }
  .rm-rail ol { min-width: 560px; }
  .rm-here { left: calc(16px + 560px * .2); }
  .rm-shipbox { padding: 18px; }
  .rm-shiphead { flex-wrap: wrap; }
  .rm-qhead h2 { font-size: 28px; }
}
@media (prefers-reduced-motion: reduce) {
  .rm-bar::after, .rm-st.progress i, .rm-rail .progress .rm-dot { animation: none; }
}
@media (max-width: 900px) { .rm-q::before { display: none; } }
@media (max-width: 640px) { .rm-rail ol { min-width: 520px; } .rm-here { left: calc(16px + 520px * .2); } }

/* ==========================================================================
   Header v2: mega menus (lollipay-style) + mobile accordion drawer
   ========================================================================== */
.site-header { --mega-ease: cubic-bezier(.22, 1, .36, 1); }
.site-header.mega-open { background: color-mix(in srgb, var(--bg) 94%, transparent); }
.nav-cta .nav-link { height: 32px; padding: 0 10px; font-size: 14.5px; }
.mm-trigger[data-active="true"] { color: var(--brand-text); }
.mega { position: absolute; left: 0; right: 0; top: 100%; pointer-events: none; }
.mega.open { pointer-events: auto; }
.mega-clip { height: 0; overflow: hidden; background: color-mix(in srgb, var(--bg) 92%, transparent); -webkit-backdrop-filter: saturate(150%) blur(18px); backdrop-filter: saturate(150%) blur(18px);
  border-bottom: 1px solid transparent; box-shadow: 0 30px 60px -30px rgb(0 0 0 / 0); transition: height .38s var(--mega-ease), border-color .2s, box-shadow .3s; }
.mega.open .mega-clip { border-bottom-color: var(--border); box-shadow: 0 30px 60px -30px rgb(0 0 0 / .28); }
.mega-inner { position: relative; }
.mm-view { display: grid; grid-template-columns: repeat(var(--cols), minmax(0, 1fr)) minmax(0, 2fr); }
.mm-view[hidden] { display: none; }
.mega.open .mm-view:not([hidden]) > .mm-col { animation: mm-in .42s var(--mega-ease) both; }
.mega.open .mm-view:not([hidden]) > .mm-col:nth-child(2) { animation-delay: .03s; }
.mega.open .mm-view:not([hidden]) > .mm-col:nth-child(3) { animation-delay: .06s; }
.mega.open .mm-view:not([hidden]) > .mm-col:nth-child(4) { animation-delay: .09s; }
.mega.open .mm-view.from-right > .mm-col { animation-name: mm-in-r; }
.mega.open .mm-view.from-left > .mm-col { animation-name: mm-in-l; }
@keyframes mm-in { from { opacity: 0; transform: translateY(-6px); } }
@keyframes mm-in-r { from { opacity: 0; transform: translateX(14px); } }
@keyframes mm-in-l { from { opacity: 0; transform: translateX(-14px); } }
.mm-col { display: flex; flex-direction: column; min-width: 0; border-right: 1px solid var(--border); }
.mm-col:last-child { border-right: 0; }
.mm-h { padding: 22px 24px 16px; border-bottom: 1px solid var(--border); font: 500 11.5px/1 var(--font-sans); letter-spacing: .14em; text-transform: uppercase; color: var(--muted-fg); white-space: nowrap; }
.mm-list { display: flex; flex-direction: column; gap: 2px; padding: 14px 12px 22px; }
.mm-item { display: flex; gap: 13px; padding: 11px 12px; border-radius: 10px; text-decoration: none; color: inherit; transition: background-color .15s; }
.mm-item:hover, .mm-item:focus-visible { background: var(--muted); }
.mm-item[aria-current="page"] { background: var(--brand-soft); }
.mm-ic { flex: none; width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center; border: 1px solid var(--border-strong); background: var(--card); color: color-mix(in srgb, var(--fg) 80%, transparent); box-shadow: 0 1px 2px rgb(0 0 0 / .05); transition: color .15s, border-color .15s; }
.mm-ic svg { width: 17px; height: 17px; }
.mm-item:hover .mm-ic, .mm-item:focus-visible .mm-ic { color: var(--brand-text); border-color: color-mix(in srgb, var(--brand-text) 35%, var(--border)); }
.mm-ic.ch .mk-ch { position: static; width: 20px; height: 20px; box-shadow: none; }
.mm-ic.ch .mk-ch .i { width: 11px; height: 11px; }
.mm-ic.ch .mk-ch.ig i { width: 9px; height: 9px; border-radius: 3px; }
.mm-tx { display: flex; flex-direction: column; min-width: 0; }
.mm-t { display: flex; align-items: center; gap: 7px; font-size: 15px; font-weight: 500; color: var(--fg); white-space: nowrap; }
.mm-t .badge { font-size: 9.5px; padding: 2px 6px; }
.mm-arrow { width: 13px; height: 13px; color: var(--brand-text); opacity: 0; transform: translateX(-4px); transition: opacity .18s, transform .18s; flex: none; }
.mm-item:hover .mm-arrow, .mm-item:focus-visible .mm-arrow, .mm-card:hover .mm-arrow, .mm-card:focus-visible .mm-arrow { opacity: 1; transform: none; }
.mm-d { margin-top: 3px; font-size: 13.5px; line-height: 1.45; color: var(--muted-fg); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.mm-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; padding: 18px 24px 24px; }
.mm-feat.one .mm-cards { grid-template-columns: minmax(0, 1fr); }
.mm-card { display: flex; flex-direction: column; gap: 4px; text-decoration: none; color: inherit; border-radius: 12px; }
.mm-card .mm-t { margin-top: 12px; font-size: 16px; }
.mm-card .mm-d { margin-top: 2px; }
.mm-tile { position: relative; display: grid; place-items: center; height: 132px; border-radius: 12px; overflow: hidden;
  background: radial-gradient(120% 90% at 90% 0%, color-mix(in srgb, var(--brand) 85%, #fff) 0%, transparent 55%), linear-gradient(150deg, var(--brand-soft), color-mix(in srgb, var(--brand-text) 45%, var(--brand)));
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--brand-text) 18%, transparent); transition: transform .3s var(--mega-ease), box-shadow .3s; }
.mm-card:hover .mm-tile, .mm-card:focus-visible .mm-tile { transform: translateY(-2px); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--brand-text) 30%, transparent), 0 18px 36px -22px rgb(0 0 0 / .45); }
.mm-feat.one .mm-tile { height: 150px; }
/* mini mockups inside the tiles */
.mm-mock { display: flex; flex-direction: column; gap: 6px; width: 78%; padding: 10px; border-radius: 10px; background: var(--card); color: var(--fg); box-shadow: 0 14px 30px -14px rgb(0 0 0 / .45), 0 0 0 1px rgb(0 0 0 / .05); transform: translateY(10px) rotate(-1.5deg); }
.mm-mock .mk-av { width: 20px; height: 20px; font-size: 7.5px; }
.mm-mock .mk-ch { width: 10px; height: 10px; right: -3px; bottom: -3px; }
.mm-mock .mk-ch .i { width: 6px; height: 6px; }
.mm-mock .mk-ch.ig i { width: 5px; height: 5px; border-width: 1.2px; }
.mm-row { display: flex; align-items: center; gap: 7px; padding: 4px; border-radius: 6px; }
.mm-row.hot { background: var(--brand-soft); }
.mm-row .l { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.mm-row b { font-size: 9.5px; font-weight: 600; white-space: nowrap; }
.mm-row .l i { height: 4px; width: 80%; border-radius: 2px; background: var(--muted); }
.mm-row .mk-chip2 { font-size: 7.5px; padding: 2px 5px; }
.mm-m-lumi { width: 62%; transform: translateY(8px) rotate(1.5deg); }
.mm-model { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 6px 8px; }
.mm-model .mk-av { width: 26px; height: 26px; }
.mm-model .n { font: 400 17px/1 var(--font-serif); display: flex; align-items: baseline; gap: 6px; }
.mm-model .n small { font: 500 10px/1 var(--font-mono); color: var(--brand-text); }
.mm-model .meter { grid-column: 1 / -1; display: grid; grid-template-columns: 52px 1fr; align-items: center; gap: 6px; font-size: 8.5px; color: var(--muted-fg); }
.mm-model .meter i { height: 5px; border-radius: 3px; background: linear-gradient(90deg, var(--brand-text) var(--w), var(--muted) var(--w)); }
.mm-model .meter i.f5 { --w: 96%; } .mm-model .meter i.f2 { --w: 38%; }
.mm-m-chat { width: 70%; gap: 5px; transform: translateY(6px); }
.mm-b { display: flex; align-items: center; gap: 6px; font-size: 9.5px; line-height: 1.3; }
.mm-b > span:not(.mk-av) { padding: 5px 8px; border-radius: 10px; background: var(--muted); white-space: nowrap; }
.mm-b.out { justify-content: flex-end; }
.mm-b.out > span:not(.mk-av) { background: var(--brand-soft); }
.mm-m-code { width: 84%; padding: 12px 14px; background: var(--code-bg); color: var(--code-fg); transform: translateY(6px); }
.mm-m-code code { font: 10.5px/1.6 var(--font-mono); white-space: pre; }
.mm-m-code .tg { color: #ff9ec0; } .mm-m-code .at { color: #c9b8ff; } .mm-m-code .st { color: #9fe3c1; }

/* mobile drawer accordion */
.m-acc { border-bottom: 1px solid var(--border); }
.m-acc-btn { display: flex; align-items: center; justify-content: space-between; width: 100%; padding: 18px 0; background: none; border: 0; font: 500 17px/1.2 var(--font-sans); color: var(--fg); cursor: pointer; }
.m-acc-btn .chev { width: 14px; height: 14px; transition: transform .25s var(--ease-out); }
.m-acc-btn[aria-expanded="true"] .chev { transform: rotate(180deg); }
.m-acc-panel { padding-bottom: 12px; }
.m-acc-panel:not([hidden]) { animation: mm-in .3s var(--ease-out) both; }
.m-acc-inner { display: grid; gap: 2px; }
.m-acc .mm-item { padding: 10px 8px; }

@media (max-width: 1220px) {
  .nav, .nav-cta .login, .nav-cta .nav-link { display: none; }
  .nav-tools .lang-toggle { display: none; }
  .menu-btn { display: grid; }
  .mega { display: none; }
  .mobile-panel.open {
    display: block; position: fixed; inset: var(--header-h) 0 0 0; z-index: 49; overflow-y: auto; overscroll-behavior: contain; background: var(--bg); padding: 4px 24px 40px; border-top: 1px solid var(--border);
  }
  .mobile-panel .m-group { padding: 6px 0; border-bottom: 1px solid var(--border); }
  .mobile-panel .m-group > a { display: block; padding: 12px 0; font-size: 17px; font-weight: 500; }
  .mobile-panel .m-actions { display: grid; gap: 10px; margin-top: 24px; }
  .mobile-panel .m-actions .btn { width: 100%; }
  .mobile-panel .m-prefs { display: flex; align-items: center; justify-content: space-between; margin-top: 20px; }
  .mobile-panel .lang-toggle { display: inline-flex; }
}
@media (min-width: 1221px) and (max-width: 1320px) {
  .mm-h { padding-left: 18px; padding-right: 18px; }
  .mm-cards { padding-left: 18px; padding-right: 18px; gap: 12px; }
  .nav-link { padding: 0 9px; }
}
@media (prefers-reduced-motion: reduce) {
  .mega-clip { transition: none; }
  .mega.open .mm-view > .mm-col, .m-acc-panel:not([hidden]) { animation: none !important; }
}
.mega-clip { background: color-mix(in srgb, var(--bg) 97%, transparent); }
.mega-inner { max-width: 1400px; }
.mm-view { grid-template-columns: repeat(var(--cols), minmax(0, 1fr)) minmax(0, 1.75fr); }
.mm-model .meter i { display: block; }
.mm-list { padding: 12px 8px 20px; }
.mm-item { position: relative; gap: 11px; padding: 10px; }
.mm-item .mm-arrow { position: absolute; top: 14px; right: 10px; }
.mm-item .mm-t { padding-right: 16px; }
.mega-clip { background: var(--bg); -webkit-backdrop-filter: none; backdrop-filter: none; }

/* ==========================================================================
   Docs v2 (multi-page): sidebar · article · "On this page"; calm, no canvas effects
   ========================================================================== */
.d2 { display: grid; grid-template-columns: 236px minmax(0, 1fr) 200px; gap: 56px; padding-top: 36px; padding-bottom: 96px; align-items: start; }
.d2-side { position: sticky; top: calc(var(--header-h) + 24px); max-height: calc(100vh - var(--header-h) - 40px); overflow-y: auto; overscroll-behavior: contain; padding-right: 6px; scrollbar-width: thin; }
.d2-search { display: flex; align-items: center; gap: 8px; width: 100%; height: 36px; padding: 0 8px 0 10px; margin-bottom: 22px; border: 1px solid var(--border-strong); border-radius: 9px; background: var(--card); color: var(--muted-fg); font: 400 13.5px/1 var(--font-sans); cursor: pointer; transition: border-color .15s, color .15s; }
.d2-search:hover { border-color: var(--brand-text); color: var(--fg); }
.d2-search .i, .d2-msearch .i { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.d2-search span { flex: 1; text-align: left; white-space: nowrap; }
.d2-search kbd, .d2-sm-in kbd { font: 500 10.5px/1 var(--font-mono); padding: 4px 6px; border-radius: 5px; border: 1px solid var(--border-strong); background: var(--muted); color: var(--muted-fg); white-space: nowrap; }
.d2-group { margin-bottom: 20px; }
.d2-group p { margin: 0 0 6px 10px; font: 500 11px/1.4 var(--font-sans); letter-spacing: .12em; text-transform: uppercase; color: var(--muted-fg); white-space: nowrap; }
.d2-group ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 1px; }
.d2-group a { display: block; padding: 6px 10px; border-radius: 7px; font-size: 14px; color: color-mix(in srgb, var(--fg) 82%, transparent); text-decoration: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: background-color .12s, color .12s; }
.d2-group a:hover { background: var(--muted); color: var(--fg); }
.d2-group a[aria-current="page"] { background: var(--brand-soft); color: var(--brand-text); font-weight: 500; box-shadow: inset 2px 0 0 var(--brand-text); }

.d2-main { min-width: 0; max-width: 760px; }
.d2-crumbs { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted-fg); margin-bottom: 14px; }
.d2-crumbs a { color: var(--muted-fg); text-decoration: none; }
.d2-crumbs a:hover { color: var(--brand-text); }
.d2-main h1 { font: 400 clamp(32px, 3.4vw, 44px)/1.1 var(--font-serif); letter-spacing: -0.02em; text-wrap: balance; }
.d2-lede { margin-top: 14px; font-size: 18px; line-height: 1.6; color: var(--muted-fg); text-wrap: pretty; }
.prose2 { font-size: 15.5px; line-height: 1.7; }
.prose2 > h2 { margin: 52px 0 14px; padding-top: 28px; border-top: 1px solid var(--border); font-size: 23px; font-weight: 500; letter-spacing: -0.015em; line-height: 1.3; scroll-margin-top: calc(var(--header-h) + 24px); }
.prose2 > h3 { margin: 30px 0 10px; font-size: 17px; font-weight: 600; scroll-margin-top: calc(var(--header-h) + 24px); }
.prose2 > p, .prose2 > ul, .prose2 > .table-wrap, .prose2 > .d2-code, .prose2 > .d2-callout, .prose2 > .d2-shot, .prose2 > dl { margin: 0 0 18px; }
.prose2 p, .prose2 li, .prose2 dd { text-wrap: pretty; }
.prose2 ul { padding-left: 20px; }
.prose2 li { margin: 6px 0; }
.prose2 a { color: var(--brand-text); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.prose2 code { font: 500 .86em/1.4 var(--font-mono); padding: 2px 5px; border-radius: 5px; background: var(--muted); }
.prose2 pre code { padding: 0; background: none; font-weight: 400; }
.prose2 table { width: 100%; border-collapse: collapse; font-size: 14px; }
.prose2 th { text-align: left; font-weight: 600; font-size: 13px; color: var(--muted-fg); padding: 10px 12px; border-bottom: 1px solid var(--border-strong); white-space: nowrap; }
.prose2 td { padding: 10px 12px; border-bottom: 1px solid var(--border); vertical-align: top; line-height: 1.55; }
.prose2 td:first-child { white-space: nowrap; }
.prose2 .table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: 12px; }
.prose2 .table-wrap tr:last-child td { border-bottom: 0; }

/* numbered steps */
.d2-steps { list-style: none; margin: 8px 0 26px; padding: 0; counter-reset: st; }
.d2-steps li { position: relative; counter-increment: st; padding: 0 0 22px 48px; }
.d2-steps li::before { content: counter(st); position: absolute; left: 0; top: -2px; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-text); font: 600 13px/1 var(--font-sans); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--brand-text) 28%, transparent); }
.d2-steps li::after { content: ""; position: absolute; left: 14.5px; top: 34px; bottom: 4px; width: 1px; background: var(--border-strong); }
.d2-steps li:last-child::after { display: none; }
.d2-steps h3 { margin: 0 0 4px; font-size: 16px; font-weight: 600; }
.d2-steps p { margin: 0; color: color-mix(in srgb, var(--fg) 80%, transparent); }

/* callouts */
.d2-callout { display: flex; gap: 12px; padding: 14px 16px; border-radius: 12px; border: 1px solid var(--border); background: var(--card); }
.d2-callout p { margin: 0; }
.d2-cl { flex: none; align-self: flex-start; margin-top: 2px; padding: 3px 8px; border-radius: 6px; font: 600 11px/1.3 var(--font-sans); letter-spacing: .04em; white-space: nowrap; }
.d2-callout.note .d2-cl { background: var(--muted); color: var(--fg); }
.d2-callout.tip { border-color: color-mix(in srgb, var(--positive) 35%, var(--border)); background: color-mix(in srgb, var(--positive) 6%, var(--card)); }
.d2-callout.tip .d2-cl { background: color-mix(in srgb, var(--positive) 16%, transparent); color: var(--positive); }
.d2-callout.important { border-color: color-mix(in srgb, var(--brand-text) 35%, var(--border)); background: color-mix(in srgb, var(--brand) 12%, var(--card)); }
.d2-callout.important .d2-cl { background: var(--brand-text); color: var(--bg); }

/* code with tabs */
.d2-code { border-radius: 12px; overflow: hidden; border: 1px solid var(--border-strong); background: var(--code-bg); }
.d2-code .codeblock { border: 0; border-radius: 0; }
.d2-code-bar { display: flex; align-items: center; gap: 2px; padding: 6px 6px 0 8px; border-bottom: 1px solid #ffffff14; }
.d2-code-bar [role=tab], .d2-code-label { height: 32px; padding: 0 12px; border: 0; background: none; color: #9b9aa6; font: 500 12.5px/1 var(--font-sans); cursor: pointer; border-bottom: 2px solid transparent; white-space: nowrap; display: inline-flex; align-items: center; }
.d2-code-label { cursor: default; font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; }
.d2-code-bar [role=tab]:hover { color: #e8e6ee; }
.d2-code-bar [role=tab][aria-selected="true"] { color: #fff; border-bottom-color: var(--brand); }
.d2-copy { margin-left: auto; display: inline-flex; align-items: center; gap: 6px; height: 28px; margin-bottom: 4px; padding: 0 9px; border: 1px solid #ffffff1f; border-radius: 7px; background: none; color: #c9c7d1; font: 500 12px/1 var(--font-sans); cursor: pointer; }
.d2-copy:hover { color: #fff; border-color: #ffffff40; }
.d2-copy.done { color: #9fe3c1; border-color: #9fe3c155; }
.d2-copy svg { width: 13px; height: 13px; }
.d2-code pre { margin: 0; }

/* quick start cards + definitions */
.d2-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin: 4px 0 18px; }
.prose2 .d2-card { display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; gap: 2px 13px; padding: 16px; border-radius: 12px; border: 1px solid var(--border); background: var(--card); color: inherit; text-decoration: none; transition: border-color .15s, transform .2s var(--ease-out), box-shadow .2s; }
.prose2 .d2-card:hover { border-color: color-mix(in srgb, var(--brand-text) 40%, var(--border)); transform: translateY(-2px); box-shadow: 0 16px 34px -24px rgb(0 0 0 / .4); }
.d2-card .mm-ic { grid-row: 1 / 3; }
.d2-card b { font-size: 15px; font-weight: 600; }
.d2-card span:last-child { font-size: 13.5px; line-height: 1.5; color: var(--muted-fg); }
.d2-dl { display: grid; grid-template-columns: 170px 1fr; border: 1px solid var(--border); border-radius: 12px; overflow: hidden; }
.d2-dl dt, .d2-dl dd { margin: 0; padding: 12px 14px; border-bottom: 1px solid var(--border); }
.d2-dl dt { font-weight: 600; background: var(--card-2); }
.d2-dl dt:nth-last-of-type(1), .d2-dl dd:last-of-type { border-bottom: 0; }
.d2-builtin { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; list-style: none; padding: 0 !important; counter-reset: bi; }
.d2-builtin li { counter-increment: bi; position: relative; margin: 0 !important; padding: 10px 12px 10px 40px; border: 1px solid var(--border); border-radius: 9px; background: var(--card); font-size: 14px; line-height: 1.5; }
.d2-builtin li::before { content: counter(bi); position: absolute; left: 12px; top: 10px; width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-text); font: 600 10.5px/1 var(--font-sans); }
.d2-faq { margin-top: 8px; }

/* screenshot-style mockups */
.d2-shot { margin: 6px 0 22px; padding: 22px; border-radius: 14px; background: linear-gradient(150deg, var(--brand-soft), color-mix(in srgb, var(--brand) 55%, var(--card))); }
.d2-win { max-width: 440px; margin: 0 auto; border-radius: 12px; background: var(--card); border: 1px solid var(--border-strong); overflow: hidden; box-shadow: 0 24px 50px -30px rgb(0 0 0 / .45); font-size: 13px; }
.d2-shot-body { display: grid; gap: 12px; padding: 16px; }
.d2-shot-h { margin: 0; font-size: 14px; }
.d2-input { position: relative; height: 36px; display: flex; align-items: center; padding: 0 12px; border: 1px solid var(--brand-text); border-radius: 8px; box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand-text) 15%, transparent); font-family: var(--font-mono); font-size: 12.5px; }
.d2-caret { width: 1px; height: 16px; margin-left: 2px; background: var(--fg); animation: blink 1s steps(1) infinite; }
.d2-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.d2-row.sb { justify-content: space-between; }
.d2-btn { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 14px; border-radius: 8px; background: var(--fg); color: var(--bg); font-weight: 600; font-size: 12.5px; white-space: nowrap; }
.d2-btn.ghost { height: 28px; padding: 0 8px; background: var(--muted); color: var(--fg); }
.d2-btn svg { width: 13px; height: 13px; }
.d2-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.d2-stats div { padding: 10px 12px; border-radius: 9px; background: var(--muted); }
.d2-stats b { display: block; font: 400 22px/1.1 var(--font-serif); }
.d2-stats small { font-size: 11.5px; color: var(--muted-fg); }
.d2-progress { height: 6px; border-radius: 4px; background: var(--muted); overflow: hidden; }
.d2-progress i { display: block; height: 100%; border-radius: 4px; background: linear-gradient(90deg, var(--brand-text), var(--brand)); }
.d2-tabs { display: flex; gap: 4px; padding: 3px; border-radius: 8px; background: var(--muted); width: max-content; }
.d2-tabs span { padding: 5px 10px; border-radius: 6px; font-size: 12px; color: var(--muted-fg); }
.d2-tabs span.on { background: var(--card); color: var(--fg); box-shadow: 0 1px 2px rgb(0 0 0 / .08); }
.d2-kv { display: flex; align-items: center; gap: 8px; padding: 8px 8px 8px 10px; border-radius: 8px; border: 1px dashed var(--border-strong); min-width: 0; }
.d2-kv small { font: 600 10.5px/1 var(--font-mono); color: var(--muted-fg); }
.d2-kv code { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11.5px !important; }
.d2-shot-chat { min-height: 0; padding: 14px; gap: 8px; -webkit-mask-image: none; mask-image: none; }
.d2-shot-chat .mk-chip { display: inline-flex; margin-top: 7px; }
.d2-widget .mk-wbar { color: var(--muted-fg); }
.d2-widget .mk-compose { margin: 0 10px 10px; }

/* pager + toc */
.d2-pager { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 56px; padding-top: 24px; border-top: 1px solid var(--border); }
.prose2 .d2-pager a { display: flex; flex-direction: column; gap: 4px; padding: 14px 16px; border: 1px solid var(--border); border-radius: 12px; text-decoration: none; color: inherit; transition: border-color .15s; }
.prose2 .d2-pager a:hover { border-color: var(--brand-text); }
.d2-pager .next { text-align: right; }
.d2-pager small { font-size: 12.5px; color: var(--muted-fg); }
.d2-pager b { font-size: 15px; font-weight: 600; color: var(--brand-text); }
.d2-toc { position: sticky; top: calc(var(--header-h) + 28px); font-size: 13px; }
.d2-toc p { margin: 0 0 10px; font: 500 11px/1.4 var(--font-sans); letter-spacing: .12em; text-transform: uppercase; color: var(--muted-fg); }
.d2-toc ol { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--border); }
.d2-toc a { display: block; margin-left: -1px; padding: 5px 0 5px 12px; border-left: 2px solid transparent; color: var(--muted-fg); text-decoration: none; line-height: 1.4; transition: color .15s, border-color .15s; }
.d2-toc a:hover { color: var(--fg); }
.d2-toc a.on { color: var(--brand-text); border-left-color: var(--brand-text); }

/* search modal */
.d2-search-modal { position: fixed; inset: 0; z-index: 200; display: grid; justify-items: center; align-items: start; padding: 12vh 16px 16px; background: rgb(12 8 12 / .45); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
.d2-search-modal[hidden] { display: none; }
.d2-sm-box { width: min(620px, 100%); border-radius: 14px; background: var(--bg); border: 1px solid var(--border-strong); box-shadow: 0 40px 80px -30px rgb(0 0 0 / .6); overflow: hidden; animation: mm-in .2s var(--ease-out); }
.d2-sm-in { display: flex; align-items: center; gap: 10px; padding: 0 14px; border-bottom: 1px solid var(--border); }
.d2-sm-in .i { width: 18px; height: 18px; fill: none; stroke: var(--muted-fg); stroke-width: 2; stroke-linecap: round; flex: none; }
.d2-sm-in input { flex: 1; min-width: 0; height: 54px; border: 0; outline: 0; background: none; color: var(--fg); font: 400 16px/1 var(--font-sans); }
.d2-sm-list { list-style: none; margin: 0; padding: 8px; max-height: min(60vh, 440px); overflow-y: auto; }
.d2-sm-list li a { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 9px; color: inherit; text-decoration: none; }
.d2-sm-list li[aria-selected="true"] a, .d2-sm-list li a:hover { background: var(--brand-soft); }
.d2-sm-list .k { width: 26px; height: 26px; flex: none; border-radius: 7px; display: grid; place-items: center; background: var(--muted); color: var(--muted-fg); font: 600 12px/1 var(--font-mono); }
.d2-sm-list b { display: block; font-size: 14.5px; font-weight: 500; }
.d2-sm-list small { display: block; font-size: 12px; color: var(--muted-fg); }
.d2-sm-list .empty { padding: 20px; text-align: center; color: var(--muted-fg); }

/* mobile bar + drawer */
.d2-mbar { display: none; }
@media (max-width: 1180px) {
  .d2 { grid-template-columns: 220px minmax(0, 1fr); gap: 40px; }
  .d2-toc { display: none; }
}
@media (max-width: 860px) {
  .d2 { grid-template-columns: minmax(0, 1fr); padding-top: 20px; }
  .d2-mbar { display: block; position: sticky; top: var(--header-h); z-index: 30; background: color-mix(in srgb, var(--bg) 92%, transparent); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); border-bottom: 1px solid var(--border); }
  .d2-mbar .container { display: flex; gap: 8px; padding-top: 8px; padding-bottom: 8px; }
  .d2-menu-btn, .d2-msearch { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 12px; border: 1px solid var(--border-strong); border-radius: 9px; background: var(--card); color: var(--fg); font: 500 14px/1 var(--font-sans); cursor: pointer; }
  .d2-msearch { flex: 1; color: var(--muted-fg); font-weight: 400; }
  .d2-menu-btn svg { width: 16px; height: 16px; }
  .d2-side { position: fixed; z-index: 60; inset: var(--header-h) 0 0 0; max-height: none; padding: 20px 20px 40px; background: var(--bg); transform: translateX(-100%); visibility: hidden; transition: transform .3s var(--ease-out), visibility 0s .3s; }
  .d2-side.open { transform: none; visibility: visible; transition: transform .3s var(--ease-out); }
  .d2-side .d2-search { display: none; }
  .d2-group a { font-size: 15.5px; padding: 9px 10px; }
  .d2-cards, .d2-builtin { grid-template-columns: minmax(0, 1fr); }
  .d2-dl { grid-template-columns: minmax(0, 1fr); }
  .d2-dl dt { border-bottom: 0; padding-bottom: 2px; }
  .d2-shot { padding: 14px; }
  .prose2 > h2 { margin-top: 40px; }
}
@media (prefers-reduced-motion: reduce) { .d2-side { transition: none !important; } .d2-caret { animation: none; } }
@media (max-width: 860px) { .prose2 .table-wrap table { min-width: 540px; } }

/* ==========================================================================
   Hero scene v3: larger, readable mockups (design 780×680, ~1:1 at 1440), iPhone-proportioned phone,
   floating labels with clear gaps. Text sizes are design px; at 1440 the scene renders at ~1.0×.
   ========================================================================== */
@media (min-width: 1001px) {
  .hp-hero > .container { max-width: 1400px; }
  .hp-hero-grid { grid-template-columns: minmax(0, .82fr) minmax(0, 1.18fr); gap: 40px; }
}
.hp-hero .mk-stage { max-width: 780px; aspect-ratio: 780 / 680; }
.mk-scene { width: 780px; height: 680px; transform: scale(tan(atan2(100cqw, 780px))); }
/* layout */
.mk-scene .mk-par { inset: 0 0 auto 256px; height: 620px; }
.mk-scene .mk-clock { top: 0; right: 0; padding: 9px 16px 9px 12px; font-size: 13px; }
.mk-scene .mk-clock b { font-size: 13.5px; }
.mk-scene .mk-clock svg { width: 16px; height: 16px; }
.mk-scene .mk-window { inset: 60px 0 0 0; }
.mk-toast { left: 0; top: 36px; width: 206px; gap: 10px; padding: 12px 13px; }
.mk-toast .mk-av { width: 30px; height: 30px; }
.mk-toast b { font-size: 13.5px; }
.mk-toast small { font-size: 12px; line-height: 1.45; }
.mk-scene .mk-phone { left: 0; top: 180px; width: 240px; height: 500px; padding: 5px; border-radius: 40px; }
.mk-phone .mk-screen { border-radius: 35px; }
.mk-chan { left: 4px; top: -38px; padding: 5px 12px 5px 6px; font-size: 12.5px; }
.mk-chan .mk-ch { width: 18px; height: 18px; }
/* browser + shop page */
.mk-bar { height: 40px; }
.mk-url { font-size: 12px; height: 24px; }
.mk-site { top: 40px; }
.mk-nav { height: 48px; gap: 18px; font-size: 13px; padding: 0 18px; }
.mk-logo { font-size: 16px; }
.mk-logo .mk-av { width: 24px; height: 24px; }
.mk-links { gap: 16px; white-space: nowrap; }
.mk-navic { gap: 14px; }
.mk-navic .i { width: 17px; height: 17px; }
.mk-pdp { width: 200px; padding: 12px 0 0 18px; }
.mk-photo { height: 138px; }
.mk-photo-tag { font-size: 11.5px; padding: 3px 8px; }
.mk-dots { margin: 8px 0 8px; }
.mk-crumb { font-size: 12px; }
.mk-title { font-size: 19px; }
.mk-stars { font-size: 12px; margin-top: 5px; }
.mk-stars .st { font-size: 12.5px; }
.mk-pricing { margin-top: 7px; }
.mk-pricing b { font-size: 17px; }
.mk-pricing s { font-size: 12.5px; }
.mk-label { font-size: 12.5px; margin-top: 8px; }
.mk-swatches { gap: 8px; margin-top: 6px; }
.mk-swatches i { width: 20px; height: 20px; }
.mk-sizes { margin-top: 9px; }
.mk-sizes i { font-size: 12.5px; padding: 7px 11px; }
.mk-addcart { height: 38px; margin-top: 10px; font-size: 14px; }
.mk-addcart .i { width: 15px; height: 15px; }
.mk-perk { white-space: normal; font-size: 12.5px; line-height: 1.4; margin-top: 8px; align-items: flex-start; }
.mk-perk .i { width: 13px; height: 13px; margin-top: 2px; flex: none; }
/* widget (now below the shop nav, so the nav is never covered) */
.mk-scene .mk-widget { top: 98px; right: 14px; bottom: 14px; width: 282px; }
.mk-wbar { padding: 11px 12px 11px 9px; gap: 10px; }
.mk-wbar .mk-av { width: 34px; height: 34px; border-radius: 11px; }
.mk-wbar .i { width: 17px; height: 17px; }
.mk-who2 b { font-size: 15px; }
.mk-who2 small { font-size: 12.5px; }
.mk-widget .mk-b { font-size: 14.5px; line-height: 1.42; padding: 8px 12px; }
.mk-widget .mk-m > .mk-av { width: 24px; height: 24px; margin-bottom: 18px; }
.mk-widget .mk-flow { gap: 8px; }
.mk-meta { font-size: 11.5px; margin-top: 4px; }
.mk-meta .ticks { width: 15px; height: 15px; }
.mk-note { font-size: 11.5px; padding: 4px 12px; }
.mk-widget .mk-pcard .ph { width: 48px; height: 48px; }
.mk-pcard b { font-size: 13px; }
.mk-pcard .pr { font-size: 12.5px; }
.mk-pcard .go { font-size: 12px; }
.mk-compose { font-size: 13.5px; padding: 6px 6px 6px 14px; margin: 0 12px 6px; }
.mk-compose .send { width: 32px; height: 32px; }
.mk-compose .send .i { width: 15px; height: 15px; }
.mk-powered { font-size: 12px; padding: 2px 0 10px; }
.mk-powered .i { width: 11px; height: 11px; }
.mk-typer .mk-b i { width: 6px; height: 6px; }
/* phone (Instagram-style) */
.mk-status { padding: 9px 18px 3px 24px; font-size: 12px; }
.mk-status .i { width: 13px; height: 13px; }
.mk-phone .mk-ighead { gap: 8px; padding: 9px 10px 10px 8px; }
.mk-phone .mk-ring { width: 32px; height: 32px; }
.mk-ighead > .i { width: 16px; height: 16px; }
.mk-ighead > .i:first-child { width: 18px; height: 18px; }
.mk-ighead .mk-who2 b { font-size: 13.5px; }
.mk-ighead .mk-who2 small { font-size: 11.5px; }
.mk-igflow { padding: 10px 10px; gap: 6px; }
.mk-igflow .mk-m { max-width: 92%; }
.mk-igflow .mk-b { font-size: 14px; line-height: 1.38; padding: 7px 12px; border-radius: 19px; }
.mk-igflow .mk-m > .mk-av { width: 22px; height: 22px; }
.mk-igflow .mk-meta { font-size: 11px; }
.mk-igflow .mk-pcard { width: 140px; }
.mk-igflow .mk-pcard .ph { height: 70px; }
.mk-igflow .mk-pcard b { font-size: 12.5px; }
.mk-iginput { margin: 4px 9px 12px; padding: 5px 11px 5px 5px; gap: 9px; }
.mk-iginput .cam { width: 28px; height: 28px; }
.mk-iginput .cam .i { width: 14px; height: 14px; }
.mk-iginput .ph { font-size: 13px; }
.mk-iginput > .i { width: 16px; height: 16px; }
/* phones: simpler 400×560 scene (widget only) */
@media (max-width: 640px) {
  .hp-hero .mk-stage { aspect-ratio: 400 / 560; max-width: none; }
  .mk-scene { width: 400px; height: 560px; transform: scale(tan(atan2(100cqw, 400px))); }
  .mk-scene .mk-par { inset: 0; height: 560px; }
  .mk-scene .mk-window { top: 54px; }
  .mk-scene .mk-widget { left: 10px; right: 10px; width: auto; top: 50px; bottom: 10px; }
}
.mk-igflow .mk-b { font-size: 14.5px; }
.mk-powered { font-size: 12.5px; }
.mk-widget .mk-b { font-size: 14.8px; }
.mk-meta { font-size: 11.8px; }
/* mid widths: give the mockup more of the row; below 1100 the hero stacks so the mockup can render near 1:1 */
@media (min-width: 1101px) and (max-width: 1380px) {
  .hp-hero-grid { grid-template-columns: minmax(0, .76fr) minmax(0, 1.24fr); gap: 32px; }
  .hp-hero .display { font-size: clamp(38px, 4.2vw, 54px); }
}
@media (max-width: 1100px) {
  .hp-hero-grid { grid-template-columns: minmax(0, 1fr); }
  .hp-hero .mk-stage { margin: 28px auto 0; }
}
.hp-hero .mk-stage { margin-bottom: 36px; }
@media (max-width: 1100px) { .hp-hero .mk-stage { margin-bottom: 56px; } }

/* decorative guide lines always sit behind content (never across a mockup, text or button) */
.guides { isolation: isolate; }
.guides::before, .guides::after { z-index: -1; }
/* widget: inner margin like the shop column; prices can wrap instead of running past the card */
.mk-scene .mk-widget { right: 18px; width: 276px; }
.mk-pcard .pc { flex: 1; min-width: 0; }
.mk-pcard .pr { display: flex; flex-wrap: wrap; column-gap: 6px; white-space: normal; }
.mk-pcard s { margin-left: 0; }
.mk-powered { white-space: nowrap; }
/* JS fallback for browsers without tan(atan2()): site.js sets --mk-s */
.mk-scene[style*="--mk-s"] { transform: scale(var(--mk-s)); }

/* channel badges: one shared glyph set, white on the coloured tile, sized by the tile */
.mk-ch { color: #fff; overflow: hidden; }
.mk-ch > svg { display: block; width: 70%; height: 70%; }
.mk-ch.zl { background: #0068ff; }
.mk-ch.tg { background: linear-gradient(160deg, #37aee2, #1e96c8); }
.mk-ch.ig { background: radial-gradient(130% 130% at 20% 100%, #f9ce34 0%, #ee2a7b 45%, #6228d7 95%); }
.mm-ic.ch .mk-ch { width: 24px; height: 24px; border-radius: 7px; }
.mm-ic.ch .mk-ch > svg { width: 72%; height: 72%; }
.mk-chan .mk-ch { border-radius: 6px; }
.site-header .mega-inner { display: block; height: auto; }   /* not the header bar's flex row: each menu spans the full width */
.mm-mock .mk-ch { width: 13px; height: 13px; right: -4px; bottom: -4px; }
.mm-mock .mk-ch > svg { width: 74%; height: 74%; }

/* Inbox mockup: drawn at 640 px wide (380 on phones, one pane) and scaled as one piece to its column */
.ib-stage { position: relative; width: 100%; max-width: 640px; margin-left: auto; aspect-ratio: 640 / 492; container-type: inline-size; }
.ib-stage > .mk-app { position: absolute; left: 0; top: 0; width: 640px; transform-origin: 0 0; transform: scale(tan(atan2(100cqw, 640px))); }
.ib-stage > .mk-app[style*="--mk-s"] { transform: scale(var(--mk-s)); }
.ib-stage .mk-bar { height: 40px; }
.hp-inbox .ib-stage .mk-app-body { grid-template-columns: 236px minmax(0, 1fr); height: 450px; }
.ib-stage .mk-list { display: flex; }
@media (max-width: 1100px) {
  .hp-inbox { grid-template-columns: minmax(0, 1fr); }
  .ib-stage { margin: 8px auto 0; }
}
@media (max-width: 640px) {
  .ib-stage { aspect-ratio: 380 / 492; max-width: none; }
  .ib-stage > .mk-app { width: 380px; transform: scale(tan(atan2(100cqw, 380px))); }
  .hp-inbox .ib-stage .mk-app-body { grid-template-columns: minmax(0, 1fr); }
  .ib-stage .mk-list { display: none; }
}
@media (min-width: 1101px) { .hp-inbox { grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); } }
/* readable at the scaled size (design px) */
.ib-stage .mk-list-head > b { font-size: 16px; }
.ib-stage .mk-tabs i { font-size: 11.5px; padding: 5px 8px; }
.ib-stage .mk-conv { gap: 10px; padding: 10px 12px; }
.ib-stage .mk-conv .mk-av { width: 34px; height: 34px; font-size: 11.5px; }
.ib-stage .mk-conv .mk-ch { width: 15px; height: 15px; }
.ib-stage .mk-cbody .top b { font-size: 14px; }
.ib-stage .mk-cbody time { font-size: 11.5px; }
.ib-stage .mk-cbody .prev { font-size: 12.5px; }
.ib-stage .mk-chip2 { font-size: 11px; padding: 3px 8px; }
.ib-stage .mk-phead .mk-who2 b { font-size: 15px; }
.ib-stage .mk-phead .mk-who2 small { font-size: 12px; }
.ib-stage .mk-phead > .mk-av { width: 36px; height: 36px; font-size: 12px; }
.ib-stage .mk-assign { font-size: 12px; }
.ib-stage .mk-pane2 .mk-b { font-size: 14px; }
.ib-stage .mk-note { font-size: 11.5px; }
.ib-stage .mk-meta { font-size: 11.5px; }
.ib-stage .mk-compose { font-size: 13px; }
.ib-stage .mk-url { font-size: 12px; }
@media (max-width: 640px) { .ib-stage { max-width: 440px; margin: 8px auto 0; } }
.ib-stage { aspect-ratio: 640 / 512; }
.hp-inbox .ib-stage .mk-app-body { height: 470px; }   /* all five conversations fit */
.ib-stage .mk-conv { padding: 9px 12px; }
.ib-stage .mk-cbody { gap: 1px; }
@media (max-width: 640px) { .ib-stage { aspect-ratio: 380 / 512; } }
