/* Say It Better — "Midnight lime" landing page styles (dark only) */
:root {
  --bg: #0E0F11;
  --surface: #17181B;
  --surface-2: #1E2023;
  --border: #2A2C30;
  --text: #EDEDED;
  --muted: #8A8D94;
  --dim: #6B6E75;
  --lime: #C8F560;
  --lime-hover: #D4FA7A;
  --on-lime: #0E0F11;
  --grad: linear-gradient(90deg, #D8FB6A, #2FD39A);
  --grad-d: linear-gradient(135deg, #D8FB6A, #2FD39A);
  --grad-hover: linear-gradient(90deg, #E4FD8E, #4FE0AC);
  --warn: #F2C14E;
  --danger: #FF6B6B;
  --r: 12px;
  --font: "Instrument Sans", -apple-system, BlinkMacSystemFont, "SF Pro Text", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.6 var(--font);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, svg { display: block; }
a { color: var(--text); text-decoration: underline; text-decoration-color: var(--dim); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--lime); }
:focus-visible { outline: 2px solid var(--lime); outline-offset: 3px; border-radius: 4px; }
h1, h2, h3 { margin: 0; line-height: 1.05; font-family: var(--font); font-weight: 600; letter-spacing: -.02em; }
h1 em, h2 em {
  font-style: normal; color: var(--lime);
  background: var(--grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}
p { margin: 0; }
code { font-family: var(--mono); font-size: .85em; background: var(--surface-2); border: 1px solid var(--border); padding: 1px 5px; border-radius: 4px; }
kbd {
  font-family: var(--mono);
  font-size: .76em;
  font-weight: 500;
  padding: 1px 6px;
  border-radius: 5px;
  border: 1px solid var(--border);
  border-bottom-width: 2px;
  background: var(--surface);
  color: var(--text);
  white-space: nowrap;
}
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 100; background: var(--lime); color: var(--on-lime); padding: 8px 14px; border-radius: 999px; }
.skip:focus { left: 8px; }
.nowrap { white-space: nowrap; }

.container { width: 100%; max-width: 1160px; margin: 0 auto; padding: 0 24px; }
.container.narrow { max-width: 820px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  font: 600 15px/1 var(--font);
  padding: 12px 20px; border-radius: 999px;
  border: 1px solid transparent;
  text-decoration: none;
  transition: background .15s ease, border-color .15s ease;
  white-space: nowrap;
}
.btn:hover { text-decoration: none; }
.btn .i { width: 18px; height: 18px; margin-top: -2px; }
.btn-primary { color: var(--on-lime); background: var(--grad); }
.btn-primary:hover { background: var(--grad-hover); }
.btn-ghost { color: var(--text); background: transparent; border-color: var(--border); }
.btn-ghost:hover { background: var(--surface); }
.btn-lg { padding: 15px 24px; font-size: 16px; }
.btn-sm { padding: 8px 16px; font-size: 14px; }

/* ---------- Nav ---------- */
.nav { position: sticky; top: 0; z-index: 50; background: var(--bg); border-bottom: 1px solid var(--border); }
.nav-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); font: 600 18px var(--font); letter-spacing: -.02em; text-decoration: none; }
.brand-mark { width: 28px; height: 28px; }
.nav-links { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; }
.nav-links a { color: var(--muted); font-size: 14.5px; font-weight: 500; padding: 8px 12px; border-radius: 999px; text-decoration: none; }
.nav-links a:hover { color: var(--text); background: var(--surface); }

/* ---------- Hero ---------- */
.hero { position: relative; padding: 92px 0 88px; isolation: isolate; }
.dot-grid {
  position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image: radial-gradient(circle at 1px 1px, #1E2023 1px, transparent 1.01px);
  background-size: 24px 24px;
}
.hero-inner { position: relative; text-align: center; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font: 500 11.5px var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted);
  padding: 6px 14px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface);
}
.eyebrow .dot { width: 6px; height: 6px; background: var(--grad-d); border-radius: 1px; }
.hero h1 { margin: 28px auto 24px; font-size: clamp(46px, 7.8vw, 96px); line-height: 1; letter-spacing: -.035em; }
.lede { max-width: 640px; margin: 0 auto; font-size: clamp(16.5px, 1.6vw, 19px); color: var(--muted); }
.tagline { margin-top: 16px; font: 500 12px var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.tagline span { color: var(--dim); margin: 0 6px; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin-top: 34px; }
.fineprint { margin-top: 18px; font: 400 12px var(--mono); color: var(--dim); }
.open-note {
  display: inline-flex; align-items: flex-start; gap: 10px; max-width: 560px; margin: 16px auto 0; text-align: left;
  padding: 10px 14px; border-radius: var(--r); border: 1px solid rgba(242, 193, 78, .35); background: rgba(242, 193, 78, .07);
  font-size: 13.5px; line-height: 1.5; color: var(--muted);
}
.open-note .i { width: 18px; height: 18px; flex: none; margin-top: 1px; color: var(--warn); }
.open-note strong { color: var(--text); font-weight: 600; }

/* ---------- Stage & windows ---------- */
.stage { position: relative; min-width: 0; }
.hero-stage { max-width: 900px; margin: 60px auto 0; text-align: left; }
.auto-stage { max-width: 860px; margin: 0 auto; }
.shortcuts { margin-top: 88px; }
.shortcuts-title { text-align: center; font-size: clamp(22px, 2.6vw, 28px); letter-spacing: -.02em; margin-bottom: 28px; }
.window {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
}
.titlebar {
  position: relative; display: flex; align-items: center; justify-content: space-between;
  height: 38px; padding: 0 14px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}
.lights { display: inline-flex; gap: 8px; position: relative; z-index: 1; }
.lights i { width: 12px; height: 12px; border-radius: 50%; background: #FF5F57; }
.lights i:nth-child(2) { background: #FEBC2E; }
.lights i:nth-child(3) { background: #28C840; }
.titlebar .title { position: absolute; inset: 0; display: grid; place-items: center; font-size: 13px; font-weight: 600; color: var(--muted); pointer-events: none; }
.tb-right { position: relative; font: 500 10.5px var(--mono); text-transform: uppercase; letter-spacing: .06em; color: var(--dim); padding: 2px 7px; border: 1px solid var(--border); border-radius: 4px; }

/* hero window */
.hero-window, .final-card { border-top: 0; }
.hero-window::before, .final-card::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 1px; z-index: 2; background: var(--grad); pointer-events: none;
}
.hero-head { padding: 6px 22px 0; }
.hero-head .field { padding: 9px 0; border-bottom: 1px solid var(--border); font-size: 14.5px; }
.hero-head .field span { color: var(--dim); margin-right: 6px; }
.compose { padding: 22px 22px 26px; min-height: 230px; transition: opacity .35s; }
.compose.fade { opacity: 0; }
.hero-head[hidden] + .compose { min-height: 320px; }
.compose-title { font: 600 22px var(--font); letter-spacing: -.02em; margin-bottom: 10px; }
.compose-text { font-size: clamp(15px, 1.9vw, 18px); line-height: 1.7; white-space: pre-wrap; word-wrap: break-word; }
.typed .acc { animation: accept .9s ease-out; border-radius: 3px; }
@keyframes accept {
  0%, 60% { background-image: var(--grad); color: var(--on-lime); }
  100% { background-image: none; color: inherit; }
}
.ghost { color: var(--dim); }
.ghost.in { animation: ghostIn .3s ease-out; }
@keyframes ghostIn { from { opacity: 0; } to { opacity: 1; } }
.caret {
  display: inline-block; width: 2px; height: 1.15em; margin: 0 1px -0.2em;
  background: var(--lime); border-radius: 1px;
  animation: blink 1.1s steps(1) infinite;
}
.typing .caret { animation: none; }
@keyframes blink { 50% { opacity: 0; } }

.hint-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px 16px; border-top: 1px solid var(--border);
  font: 400 11.5px var(--mono); color: var(--dim);
}
.status { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; text-transform: uppercase; letter-spacing: .06em; font-size: 10.5px; }
.pulse-dot { position: relative; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--lime); flex: none; }
.pulse-dot::after { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 1px solid var(--lime); animation: ping 1.8s ease-out infinite; }
@keyframes ping { to { transform: scale(2.6); opacity: 0; } }
.hints { display: flex; gap: 14px; flex-wrap: wrap; justify-content: flex-end; }
.hint { display: inline-flex; align-items: center; gap: 6px; }
.key {
  display: inline-block; min-width: 28px; text-align: center; font-size: 11px; padding: 3px 7px;
  transition: background .15s, border-color .15s, color .15s, transform .12s;
}
.key.pressed, .cap.pressed { background: var(--grad-d) border-box; border-color: transparent; color: var(--on-lime); }
.key.pressed { transform: translateY(1px); }
.apps-row { list-style: none; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 26px 0 0; padding: 0; }
.apps-row li {
  font: 500 10.5px var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--dim);
  padding: 5px 11px; border-radius: 999px; border: 1px solid var(--border); background: var(--bg); transition: all .3s;
}
.apps-row li.on { color: var(--text); border-color: var(--muted); background: var(--surface-2); }
.apps-row li.more { border-style: dashed; }

/* ---------- Sections ---------- */
.section { position: relative; padding: 112px 0; border-top: 1px solid var(--border); }
.section-head { text-align: center; max-width: 760px; margin: 0 auto 56px; }
.kicker {
  display: inline-flex; align-items: center; gap: 10px;
  font: 500 11.5px var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 16px;
}
.kicker::before { content: ""; width: 7px; height: 7px; background: var(--grad-d); border-radius: 1px; }
.section h2 { font-size: clamp(34px, 4.8vw, 58px); letter-spacing: -.03em; }
.sub { margin-top: 18px; color: var(--muted); font-size: 17.5px; }

.card { position: relative; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); }

/* features */
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.features.features-4 { grid-template-columns: repeat(2, 1fr); max-width: 980px; margin: 0 auto; }
.feature { padding: 28px; transition: background .2s; }
.feature:hover, .faq details:target {
  border-color: transparent;
  background: linear-gradient(var(--surface-2), var(--surface-2)) padding-box, var(--grad-d) border-box;
}
.feature h3 { font-size: 18.5px; margin: 20px 0 10px; }
.feature p { color: var(--muted); font-size: 15px; }
.tile { width: 42px; height: 42px; border-radius: 10px; display: grid; place-items: center; background: var(--surface-2); border: 1px solid var(--border); }
.tile svg { width: 22px; height: 22px; fill: none; stroke: var(--text); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.tile svg .accent { stroke: var(--lime); }

/* split layout */
.split { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 64px; align-items: center; }
.split-rev { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
.split-rev .split-copy { order: 2; }
.menubar-split { margin-top: 112px; padding-top: 112px; border-top: 1px solid var(--border); }
.checks { list-style: none; padding: 0; margin: 28px 0 0; display: grid; gap: 14px; }
.checks li { position: relative; padding-left: 28px; color: var(--muted); }
.checks li strong { color: var(--text); font-weight: 600; }
.checks li::before { content: "✓"; position: absolute; left: 0; top: 0; width: 18px; text-align: center; font: 500 14px var(--mono); color: var(--text); }

/* ---------- Hero: the real panel (mirrors ContentView.swift) ---------- */
.ap-window { background: var(--bg); }
.ap-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px 10px; }
.ap-tools { display: inline-flex; align-items: center; gap: 10px; min-width: 0; }
.ap-scope { display: inline-flex; padding: 2px; border-radius: 999px; background: var(--surface); border: 1px solid var(--border); }
.ap-scope b { padding: 3px 11px; border-radius: 999px; font: 600 11.5px var(--font); color: var(--muted); }
.ap-scope b.on { background: var(--grad); color: var(--on-lime); }
.ap-model { display: inline-flex; align-items: center; gap: 6px; padding: 4px 9px; border-radius: 999px; background: var(--surface); border: 1px solid var(--border); font: 400 10.5px var(--mono); color: var(--text); white-space: nowrap; }
.ap-model i { width: 6px; height: 6px; border-radius: 50%; background: var(--lime); }
.ap-model svg { width: 9px; height: 9px; color: var(--dim); }
.ap-icon { display: grid; place-items: center; width: 22px; height: 22px; color: var(--muted); }
.ap-icon svg { width: 13px; height: 13px; }
.ap-body { padding: 4px 16px 0; display: grid; gap: 14px; }
.ap-editor { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 12px 14px; min-height: 76px; }
/* Tone chips, like the app's row under the editor */
.ap-tones {
  display: flex; gap: 6px; margin: 0 -16px; padding: 2px 16px; overflow: hidden; white-space: nowrap;
  mask-image: linear-gradient(90deg, transparent, #000 14px, #000 calc(100% - 28px), transparent);
}
.ap-tone { flex: none; padding: 4px 11px; border-radius: 999px; font: 500 12px var(--font); color: var(--muted); background: var(--surface); border: 1px solid var(--border); transition: all .25s ease; }
.ap-tone.on { color: var(--on-lime); background: var(--grad); border-color: transparent; font-weight: 600; box-shadow: 0 3px 12px -3px rgba(200, 245, 96, .45); }
.ap-tone.press { transform: scale(.94); }
.ap-pop .ap-tones { margin: 0 -12px; padding: 2px 12px; }
/* Soft glow like the app: behind the editor (stronger while thinking) and the corrected card */
.ap-editor { box-shadow: 0 8px 18px -10px rgba(200, 245, 96, .10); transition: box-shadow .4s ease; }
.ap-editor.thinking { box-shadow: 0 8px 26px -8px rgba(200, 245, 96, .22); }
.ap-corrected { box-shadow: 0 8px 20px -10px rgba(200, 245, 96, .14); }
[data-rw-alt] { transition: opacity .25s ease; }
[data-rw-alt].swap { opacity: 0; }
.ap-results { display: grid; min-height: 318px; }
.ap-results > * { grid-area: 1 / 1; }
.ap-empty { display: flex; flex-direction: column; align-items: center; gap: 10px; padding-top: 40px; font-size: 12.5px; color: var(--muted); text-align: center; transition: opacity .3s; }
.ap-empty.thinking .ap-tile { color: var(--on-lime); background: var(--grad-d); border-color: transparent; animation: pulse 1s ease-in-out infinite; }
.ap-empty.hide { opacity: 0; }
.ap-tile { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 10px; background: var(--surface); border: 1px solid var(--border); color: var(--text); }
.ap-tile svg { width: 18px; height: 18px; }
@keyframes pulse { 50% { opacity: .55; } }
.ap-out { display: grid; gap: 14px; align-content: start; }
[data-rw-step], [data-rw-row] { transition: opacity .4s ease, transform .4s cubic-bezier(.2, .8, .2, 1); }
[data-rw-step]:not(.show), [data-rw-row]:not(.show) { opacity: 0; transform: translateY(6px); }
.ap-kicker { display: inline-flex; align-items: center; gap: 7px; font: 500 10.5px var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.ap-kicker::before { content: ""; width: 7px; height: 7px; border-radius: 1.5px; background: var(--grad-d); }
.ap-corrected { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 14px; display: grid; gap: 10px; }
.ap-row-head { display: flex; justify-content: space-between; align-items: center; }
.ap-key { font: 600 11px var(--mono); color: var(--text); padding: 3px 7px; border-radius: 5px; background: var(--surface); border: 1px solid var(--border); box-shadow: inset 0 -2px 0 var(--border); }
.ap-corrected p { margin: 0; font-size: 15px; line-height: 1.55; }
.ap-corrected em { font-style: normal; color: var(--lime); background: rgba(200, 245, 96, .13); border-radius: 3px; padding: 0 2px; }
.ap-btns { display: flex; gap: 8px; }
.ap-btn { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border-radius: 999px; font: 500 12px var(--font); color: var(--text); background: var(--surface); border: 1px solid var(--border); }
.ap-btn svg { width: 12px; height: 12px; }
.ap-btn-primary { color: var(--on-lime); background: var(--grad); border-color: transparent; }
.ap-alts { display: grid; gap: 8px; }
.ap-list { list-style: none; margin: 0; padding: 0; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; overflow: hidden; }
.ap-list li { display: flex; align-items: center; gap: 10px; padding: 9px 12px; transition: background .15s, opacity .4s ease, transform .4s cubic-bezier(.2, .8, .2, 1); }
.ap-list li { position: relative; }
.ap-list li + li::before { content: ""; position: absolute; top: 0; left: 36px; right: 0; height: 1px; background: var(--border); }
.ap-list li.hover { background: var(--surface-2); }
.ap-n { width: 14px; flex: none; font: 600 10.5px var(--mono); color: var(--dim); }
.ap-list li.hover .ap-n { color: var(--lime); }
.ap-t { flex: 1; min-width: 0; font-size: 14px; line-height: 1.5; }
.ap-copy { position: relative; flex: none; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; color: var(--dim); border: 1px solid transparent; transition: all .15s; }
.ap-list li.hover .ap-copy { color: var(--text); background: var(--surface); border-color: var(--border); }
.ap-copy svg { width: 12px; height: 12px; grid-area: 1 / 1; transition: opacity .2s, transform .25s; }
.ap-copy .ok { opacity: 0; transform: scale(.5); }
.ap-list li .ap-copy.done { color: var(--on-lime); background: var(--grad-d); border-color: transparent; }
.ap-copy.done svg:first-child { opacity: 0; transform: scale(.5); }
.ap-copy.done .ok { opacity: 1; transform: none; }
.ap-copy.press { transform: scale(.88); }
.ap-status { display: flex; align-items: center; gap: 8px; margin: 14px 16px 0; padding: 12px 0 14px; border-top: 1px solid var(--border); font: 400 10.5px var(--mono); color: var(--muted); }
.ap-status i { width: 6px; height: 6px; border-radius: 50%; background: var(--dim); }
.ap-status span:first-of-type { flex: 1; }
.ap-window .toast { bottom: 62px; }
.ap-switch { position: relative; width: 26px; height: 15px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--border); }
.ap-switch::after { content: ""; position: absolute; top: 2px; left: 2px; width: 9px; height: 9px; border-radius: 50%; background: var(--muted); }
@media (max-width: 560px) {
  .ap-hide { display: none; }
  .ap-head, .ap-body { padding-left: 12px; padding-right: 12px; }
  .ap-status { margin: 12px 12px 0; }
  .ap-results { min-height: 360px; }
}

/* ---------- Shared demo bits ---------- */
.rw-line { font-size: 15.5px; min-height: 1.6em; }
.typo { text-decoration: underline wavy var(--danger); text-decoration-thickness: 1.5px; text-decoration-skip-ink: none; text-underline-offset: 4px; }

mark { background: var(--grad); color: var(--on-lime); border-radius: 3px; padding: 0 2px; }
.toast {
  position: absolute; left: 50%; bottom: 18px; z-index: 5;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 16px; border-radius: 999px;
  background: var(--surface-2); border: 1px solid var(--border);
  color: var(--text); font: 500 11.5px var(--mono); text-transform: uppercase; letter-spacing: .06em;
  opacity: 0; transform: translate(-50%, 10px); transition: all .3s cubic-bezier(.2, .8, .2, 1);
  pointer-events: none;
}
.toast svg { width: 14px; height: 14px; color: var(--lime); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.fake-cursor {
  position: absolute; left: 0; top: 0; z-index: 10; width: 20px; height: 24px;
  opacity: 0; pointer-events: none;
  transition: transform .9s cubic-bezier(.45, .05, .25, 1), opacity .3s;
}
.fake-cursor.show { opacity: 1; }
.fake-cursor.click { animation: click .25s ease; }
@keyframes click { 50% { scale: .82; } }

/* ---------- Menu bar demo ---------- */
.desk {
  position: relative; height: 566px; border-radius: 12px; overflow: hidden;
  border: 1px solid var(--border); background: var(--bg);
}
.menubar {
  position: relative; z-index: 3; display: flex; justify-content: space-between; align-items: center;
  height: 30px; padding: 0 12px; font-size: 13px; color: var(--text);
  background: var(--surface); border-bottom: 1px solid var(--border);
}
.mb-left, .mb-right { display: flex; align-items: center; gap: 16px; white-space: nowrap; }
.mb-apple { width: 15px; height: 15px; margin-top: -2px; }
.mb-left b { font-weight: 600; }
.mb-right { gap: 12px; }
.mb-sys { width: 18px; height: 16px; }
.mb-icon { display: grid; place-items: center; width: 28px; height: 22px; border-radius: 5px; transition: background .2s, color .2s; }
.mb-icon svg { width: 17px; height: 17px; }
.mb-icon.active { background: var(--surface-2); color: var(--lime); }
.mb-time { font-variant-numeric: tabular-nums; }
.desk-window {
  position: absolute; left: 7%; top: 70px; width: 58%; height: 280px; border-radius: 12px;
  background: var(--surface); border: 1px solid var(--border);
}
.dw-bar { height: 32px; display: flex; align-items: center; padding: 0 12px; border-bottom: 1px solid var(--border); }
.dw-bar .lights i { width: 10px; height: 10px; }
/* Chat app behind the popover */
.desk-window.chat { left: 5%; top: 50px; width: 60%; height: calc(100% - 74px); display: flex; flex-direction: column; overflow: hidden; }
.chat .dw-bar { gap: 14px; }
.chat-name { display: inline-flex; align-items: center; gap: 8px; font: 600 13px var(--font); }
.chat-name i { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--surface-2); border: 1px solid var(--border); font: 600 11px var(--font); font-style: normal; color: var(--muted); }
.chat-body { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; gap: 8px; padding: 16px; }
.bubble { margin: 0; max-width: 78%; padding: 8px 12px; border-radius: 16px; font-size: 13.5px; line-height: 1.45; }
.bubble.in { align-self: flex-start; background: var(--surface-2); border-bottom-left-radius: 5px; }
.bubble.out { align-self: flex-end; background: var(--grad); color: var(--on-lime); border-bottom-right-radius: 5px; transition: opacity .3s ease, transform .35s cubic-bezier(.2, .8, .2, 1); }
.bubble.out:not(.show) { opacity: 0; transform: translateY(8px) scale(.96); }
.chat-input { position: relative; margin: 0 12px 12px; min-height: 36px; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--border); background: var(--bg); font-size: 13.5px; }
.chat-input.focus { border-color: #3d4a24; box-shadow: 0 0 0 3px rgba(200, 245, 96, .06); }
.chat-ph { position: absolute; left: 14px; top: 8px; color: var(--dim); }
.ap-copy.done { color: var(--on-lime); background: var(--grad-d); border-color: transparent; }
.dw-lines { padding: 22px; display: grid; gap: 14px; }
.dw-lines i { display: block; height: 8px; border-radius: 4px; background: var(--surface-2); }
.dw-lines i:nth-child(1) { width: 60%; }
.dw-lines i:nth-child(2) { width: 88%; }
.dw-lines i:nth-child(3) { width: 72%; }
.dw-lines i:nth-child(4) { width: 40%; }
.popover {
  position: absolute; z-index: 4; top: 38px; right: 70px; width: 400px; max-width: calc(100% - 20px);
  border-radius: 12px; overflow: hidden;
  background: var(--bg); border: 1px solid var(--muted);
  transform-origin: 85% 0;
  opacity: 0; transform: translateY(-6px) scale(.97); transition: opacity .25s, transform .3s cubic-bezier(.2, .8, .2, 1);
}
.popover.open { opacity: 1; transform: none; }
.ap-pop .ap-head { padding: 10px 12px; }
.ap-pop .ap-body { padding: 4px 12px 0; gap: 12px; }
.ap-pop .ap-editor { min-height: 64px; padding: 10px 12px; }
.ap-pop .rw-line { font-size: 14px; }
.ap-pop .ap-results { min-height: 280px; }
.ap-pop .ap-empty { padding-top: 24px; }
.ap-pop .ap-corrected { padding: 12px; gap: 8px; }
.ap-pop .ap-corrected p { font-size: 14px; }
.ap-pop .ap-t { font-size: 13px; }
.ap-pop .ap-list li { padding: 8px 12px; }
.ap-pop .ap-status { margin: 10px 12px 0; padding: 10px 0; }
.ap-brand { display: inline-flex; align-items: center; gap: 8px; font: 600 13px var(--font); white-space: nowrap; }
.ap-brand svg { width: 22px; height: 22px; }
[data-mb-sug] { transition: opacity .4s ease, transform .4s cubic-bezier(.2, .8, .2, 1); }
[data-mb-sug]:not(.show) { opacity: 0; transform: translateY(6px); }

/* ---------- Steps ---------- */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.step { padding: 30px 28px; }
.step-n {
  display: grid; place-items: center; width: 34px; height: 34px; border-radius: 8px;
  font: 500 13px var(--mono); color: var(--text); background: var(--surface-2); border: 1px solid var(--border);
}
.step h3 { font-size: 19px; margin: 20px 0 10px; }
.step p { color: var(--muted); font-size: 15px; }
.step p strong { color: var(--text); font-weight: 600; }
.mini-steps { margin: 0; padding-left: 20px; display: grid; gap: 8px; color: var(--muted); font-size: 15px; }
.mini-steps li::marker { color: var(--dim); font: 500 13px var(--mono); }
.mini-steps strong { color: var(--text); font-weight: 600; }
.step-foot { margin: 14px 0 0; font-size: 13.5px !important; color: var(--dim) !important; }
.dl-steps kbd, .mini-steps kbd { font: 500 12px var(--mono); padding: 1px 6px; border-radius: 5px; border: 1px solid var(--border); background: var(--surface-2); color: var(--text); }
.step-required { scroll-margin-top: 96px; border-color: rgba(242, 193, 78, .55); box-shadow: 0 0 0 1px rgba(242, 193, 78, .25) inset; }
.step-required .step-n { color: var(--warn); border-color: rgba(242, 193, 78, .55); }
.req-badge {
  position: absolute; top: 30px; right: 28px; padding: 4px 10px; border-radius: 999px;
  font: 600 11px var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--on-lime); background: var(--warn);
}
@media (max-width: 1100px) and (min-width: 761px) { .steps { grid-template-columns: repeat(2, 1fr); } }

/* ---------- Share ---------- */
.share { max-width: 560px; margin: 36px auto 0; padding-top: 28px; border-top: 1px solid var(--border); }
.share-title { margin: 0; font-weight: 600; }
.share-msg { margin: 12px 0 0; padding: 12px 14px; border-radius: var(--r); background: var(--surface-2); border: 1px solid var(--border); color: var(--muted); font-size: 14px; line-height: 1.55; text-align: left; overflow-wrap: anywhere; }
.share-btns { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 14px; }
.share-btns .btn { gap: 8px; }
.share-btns .i { width: 16px; height: 16px; margin-top: 0; }
.share-btns [hidden] { display: none; }
.share-btns .btn.done { color: var(--on-lime); background: var(--grad); border-color: transparent; }

/* ---------- Download guide ---------- */
.dl-guide {
  width: min(520px, calc(100% - 32px)); max-height: calc(100% - 32px); padding: 0; color: var(--text);
  background: var(--surface); border: 1px solid var(--border); border-radius: 18px; box-shadow: 0 30px 80px rgba(0, 0, 0, .6);
}
.dl-guide::backdrop { background: rgba(0, 0, 0, .6); }
.dl-guide-inner { padding: 28px; }
.dl-guide h2 { margin: 0; font-size: 28px; letter-spacing: -.02em; }
.dl-guide .sub { margin-top: 10px; font-size: 15px; }
.dl-steps { list-style: none; margin: 22px 0 0; padding: 0; display: grid; gap: 16px; }
.dl-steps li { display: flex; gap: 14px; align-items: flex-start; font-size: 15px; color: var(--muted); }
.dl-steps strong { color: var(--text); font-weight: 600; }
.dl-steps .step-n { flex: none; }
.mock-alert { display: flex; gap: 8px; margin-top: 10px; }
.mock-btn { padding: 6px 14px; border-radius: 8px; font-size: 13px; background: var(--surface-2); border: 1px solid var(--border); color: var(--dim); text-decoration: line-through; }
.mock-ok { color: var(--on-lime); background: var(--lime); border-color: var(--lime); text-decoration: none; font-weight: 600; box-shadow: 0 0 0 3px rgba(200, 245, 96, .3); }
.dl-guide-actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: flex-end; margin-top: 26px; }
@media (max-width: 480px) { .dl-guide-inner { padding: 22px 18px; } .dl-guide-actions .btn { flex: 1; justify-content: center; } }

/* ---------- Provider demo ---------- */
.prov { padding: 22px; }
.seg {
  position: relative; display: grid; grid-template-columns: 1fr 1fr; padding: 3px; border-radius: 999px;
  background: var(--bg); border: 1px solid var(--border); max-width: 460px; margin: 0 auto;
}
.seg-btn {
  position: relative; z-index: 1; border: 0; background: none; color: var(--muted); cursor: pointer;
  font: 500 11.5px var(--mono); letter-spacing: .06em; text-transform: uppercase; padding: 9px 10px; border-radius: 999px; transition: color .25s;
}
.seg-btn[aria-pressed="true"] { color: var(--on-lime); }
.seg-thumb {
  position: absolute; top: 3px; bottom: 3px; left: 3px; width: calc(50% - 3px); border-radius: 999px;
  background: var(--grad); transition: transform .4s cubic-bezier(.3, .9, .3, 1);
}
.prov[data-mode="cloud"] .seg-thumb { transform: translateX(100%); }
.prov-stage { display: grid; grid-template-columns: minmax(0, 1fr) 104px minmax(0, 1fr); align-items: center; margin-top: 26px; }
.node { padding: 16px; border-radius: 10px; border: 1px solid var(--border); background: var(--bg); transition: all .4s; }
.node-top { display: flex; align-items: center; gap: 10px; }
.node-top b { display: block; font-size: 14.5px; font-weight: 600; }
.node-top small { display: block; font: 400 11px var(--mono); color: var(--dim); }
.node-logo { width: 32px; height: 32px; flex: none; }
.cloud-ico { width: 32px; height: 32px; flex: none; display: grid; place-items: center; border-radius: 8px; border: 1px solid var(--border); background: var(--surface); }
.cloud-ico svg { width: 20px; height: 20px; }
.node-row { margin-top: 12px; font: 400 11.5px var(--mono); color: var(--muted); overflow-wrap: anywhere; }
.onchip {
  display: inline-flex; align-items: center; gap: 8px; margin-top: 14px;
  font: 500 10.5px var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--on-lime);
  padding: 4px 10px; border-radius: 999px; background: var(--grad);
  transition: all .4s;
}
.onchip .ring { position: relative; width: 6px; height: 6px; border-radius: 50%; background: var(--on-lime); }
.onchip .ring::after { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 1px solid var(--on-lime); animation: ping 1.6s ease-out infinite; }
.prov[data-mode="local"] .node-mac, .prov[data-mode="cloud"] .node-cloud {
  border-color: transparent;
  background: linear-gradient(var(--bg), var(--bg)) padding-box, var(--grad-d) border-box;
}
.prov[data-mode="local"] .node-cloud { opacity: .4; border-style: dashed; }
.prov[data-mode="cloud"] .onchip { background: var(--surface-2); color: var(--dim); }
.prov[data-mode="cloud"] .onchip .ring { background: var(--dim); }

.node-idle { margin-top: 10px; font: 500 10px var(--mono); color: var(--dim); text-transform: uppercase; letter-spacing: .08em; transition: opacity .3s; }
.prov[data-mode="cloud"] .node-idle { opacity: 0; }
.wire { position: relative; height: 0; margin: 0 8px; border-top: 1px dashed var(--border); }
.wire i { position: absolute; top: -4px; left: 0; width: 7px; height: 7px; border-radius: 50%; background: var(--text); opacity: 0; }
.prov[data-mode="cloud"] .wire { border-top: 1px solid var(--muted); }
.prov[data-mode="cloud"] .wire i { animation: packet 1.6s linear infinite; }
.prov[data-mode="cloud"] .wire i:nth-child(2) { animation-delay: .53s; }
.prov[data-mode="cloud"] .wire i:nth-child(3) { animation-delay: 1.06s; }
@keyframes packet { 0% { left: 0; opacity: 0; } 15% { opacity: 1; } 85% { opacity: 1; } 100% { left: calc(100% - 7px); opacity: 0; } }
.wire-off {
  position: absolute; left: 50%; top: 0; transform: translate(-50%, -50%);
  font: 500 9.5px var(--mono); text-transform: uppercase; letter-spacing: .06em; white-space: nowrap;
  color: var(--muted); background: var(--surface); padding: 2px 6px; border-radius: 4px; border: 1px solid var(--border);
  transition: opacity .3s;
}
.prov[data-mode="cloud"] .wire-off { opacity: 0; }
.prov-caption { margin-top: 22px; text-align: center; font-size: 14px; color: var(--muted); min-height: 2.9em; }

/* ---------- Round-trip comparison ---------- */
.compare { max-width: 980px; margin: 0 auto; display: grid; gap: 16px; }
.cmp-row { padding: 22px 24px 24px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); }
.cmp-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.cmp-label { font: 500 11.5px var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.cmp-timer { font: 500 22px var(--mono); color: var(--dim); font-variant-numeric: tabular-nums; transition: color .3s; }
.cmp-row.done .cmp-timer { color: var(--text); }
.is-lim .cmp-label { color: var(--text); }
.is-lim.done .cmp-timer { color: var(--lime); }
.cmp-chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 8px; min-height: 40px; }
.cmp-chips li {
  position: relative; display: inline-flex; align-items: center;
  font: 500 13px var(--font); color: var(--muted);
  padding: 8px 14px; border-radius: 999px; border: 1px solid var(--border); background: var(--bg);
  opacity: 0; transform: translateY(6px); transition: opacity .3s ease, transform .3s ease;
}
.cmp-chips li:not(:last-child) { margin-right: 20px; }
.cmp-chips li:not(:last-child)::after { content: "→"; position: absolute; right: -21px; font: 400 13px var(--mono); color: var(--dim); }
.cmp-chips li.show { opacity: 1; transform: none; }
.is-lim .cmp-chips li { color: var(--text); background: var(--surface-2); }
.is-lim .cmp-chips li.final { color: var(--on-lime); background: var(--grad); border-color: transparent; font-weight: 600; }

/* ---------- Shortcuts ---------- */
.keys { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px; }
.keycard { padding: 22px 18px; text-align: center; display: flex; flex-direction: column; align-items: center; }
.keycaps { display: flex; gap: 6px; height: 58px; align-items: center; margin-bottom: 14px; }
.cap {
  display: inline-grid; place-items: center; min-width: 48px; height: 48px; padding: 0 12px;
  font: 500 14px var(--mono); border-radius: 8px; color: var(--text);
  background: var(--surface); border: 1px solid var(--border); border-bottom-width: 2px;
  transition: transform .12s, background .15s, border-color .15s, color .15s;
}
.cap-wide { min-width: 84px; font-size: 13px; }
.cap.pressed { transform: translateY(1px); }
.keycard b { font-size: 15px; font-weight: 600; }
.keycard small { display: block; margin-top: 6px; font-size: 13px; color: var(--muted); line-height: 1.45; }

/* ---------- FAQ ---------- */
.faq { display: grid; gap: 10px; }
.faq details { border: 1px solid var(--border); border-radius: 12px; background: var(--surface); }
.faq summary {
  list-style: none; cursor: pointer; padding: 18px 52px 18px 22px; position: relative;
  font-weight: 600; font-size: 16.5px; border-radius: 12px;
}
.faq summary:hover { background: var(--surface-2); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 22px; top: 50%; transform: translateY(-50%);
  font: 400 20px var(--mono); color: var(--muted); transition: transform .25s;
}
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq details p { padding: 4px 22px 22px; color: var(--muted); }
.faq details p strong { color: var(--text); }


/* ---------- Final CTA ---------- */
.final-card {
  position: relative; text-align: center;
  padding: 80px 24px; border-radius: 16px; border: 1px solid var(--border); background: var(--surface); overflow: hidden;
}
.final-logo { width: 64px; height: 64px; margin: 0 auto 26px; }
.final-card .btn { margin-top: 32px; }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--border); padding: 36px 0; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.footer p { color: var(--dim); font-size: 14px; }
.footer-links { display: flex; gap: 18px; list-style: none; margin: 0; padding: 0; }
.footer-links a { color: var(--muted); font-size: 14px; text-decoration: none; }
.footer-links a:hover { color: var(--text); }

/* ---------- Responsive ---------- */
@media (max-width: 1020px) {
  .keys { grid-template-columns: repeat(3, 1fr); }
  .split, .split-rev { grid-template-columns: minmax(0, 1fr); gap: 44px; }
  .split-rev .split-copy { order: 0; }
  .split-copy { text-align: center; max-width: 640px; margin: 0 auto; }
  .split-copy .checks { text-align: left; max-width: 520px; margin-left: auto; margin-right: auto; }
  .features { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
  .nav-links { display: none; }
  .section { padding: 80px 0; }
  .menubar-split { margin-top: 80px; padding-top: 80px; }
  .hero { padding: 60px 0 64px; }
  .hero-stage { margin-top: 44px; }
  .features, .features.features-4, .steps { grid-template-columns: minmax(0, 1fr); }
  .seg-btn { font-size: 10.5px; letter-spacing: .03em; padding: 8px 6px; line-height: 1.3; }
  .cmp-row { padding: 18px 16px 20px; }
  .cmp-timer { font-size: 18px; }
  .cmp-chips li { font-size: 12.5px; padding: 7px 12px; }
  .shortcuts { margin-top: 64px; }
  .keys { grid-template-columns: repeat(2, 1fr); }
  .keys li:last-child { grid-column: 1 / -1; }
  .hint-l { display: none; }
  .hints { gap: 8px; }
  .mb-hide { display: none; }
  .desk-window { width: 80%; }
  .popover { right: 10px; }
  .prov-stage { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto 64px auto; }
  .wire { width: 0; height: auto; align-self: stretch; margin: 8px auto; border-top: 0; border-left: 1px dashed var(--border); }
  .prov[data-mode="cloud"] .wire { border-top: 0; border-left: 1px solid var(--muted); }
  .wire i { left: -4px; top: 0; }
  .wire-off { left: 0; top: 50%; }
  .prov[data-mode="cloud"] .wire i { animation-name: packetV; }
  @keyframes packetV { 0% { top: 0; opacity: 0; } 15% { opacity: 1; } 85% { opacity: 1; } 100% { top: calc(100% - 7px); opacity: 0; } }
}
@media (max-width: 480px) {
  .container { padding: 0 16px; }
  .btn-lg { padding: 14px 20px; font-size: 15px; }
  .cta-row .btn { width: 100%; justify-content: center; }
  .compose { padding: 18px 16px 20px; min-height: 250px; }
  .hero-head[hidden] + .compose { min-height: 340px; }
  .hero-head { padding: 4px 16px 0; }
  .hint-bar { padding: 10px 12px; }
  .status { display: none; }
  .hints { width: 100%; justify-content: space-between; }
  .desk { height: 600px; }
  .mb-left { gap: 12px; }
  .prov { padding: 16px; }
  .keycard { padding: 18px 12px; }
  .cap { min-width: 42px; height: 42px; font-size: 13px; }
  .cap-wide { min-width: 72px; font-size: 12px; }
  .final-card { padding: 56px 18px; }
  .final-card .btn { width: 100%; justify-content: center; }
  .faq summary { padding: 16px 46px 16px 18px; font-size: 15.5px; }
  .faq details p { padding: 4px 18px 18px; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  .caret { animation: none; }
}
