:root {
  --bg: #faf9f4;
  --panel: #fffefb;
  --ink: #243c32;
  --text: #304238;
  --muted: #667467;
  --line: #e7ebe2;
  --sage: #e9f1e4;
  --peach: #fdeee2;
  --lilac: #eeeafb;
  --sky: #e6f1fa;
  --orange: #f6a96b;
  --green: #7fc66f;
  --violet: #7760d8;
  --accent: #365e46;
  --code-bg: #1d2b24;
  --code-fg: #e4ece5;
  --radius: 22px;
  --shadow: 0 18px 40px rgba(36, 60, 50, .07);
  --wrap: min(calc(100% - 32px), 1120px);
}

* { box-sizing: border-box; }
html { color-scheme: light; scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; color: var(--text); background: var(--bg); font: 400 1rem/1.6 "DM Sans", system-ui, sans-serif; overflow-x: hidden; }
a { color: inherit; }
img, svg { display: block; max-width: 100%; }
h1, h2, h3 { margin: 0; color: var(--ink); font-family: Manrope, system-ui, sans-serif; font-weight: 800; letter-spacing: -.035em; line-height: 1.05; }
h1 { font-size: clamp(2.6rem, 6.4vw, 4.6rem); }
h2 { font-size: clamp(2rem, 4.2vw, 3rem); }
h3 { font-size: 1.2rem; letter-spacing: -.02em; line-height: 1.25; }
p { margin: 0; }
code, pre { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: .86em; }
:not(pre) > code { padding: .1em .4em; border-radius: 6px; background: var(--sage); color: var(--ink); }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 16px; top: 16px; z-index: 10; padding: 8px 12px; background: var(--panel); border-radius: 8px; }
:focus-visible { outline: 3px solid var(--violet); outline-offset: 3px; border-radius: 6px; }

.shell { width: var(--wrap); margin-inline: auto; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 5; background: rgba(250, 249, 244, .86); backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px); border-bottom: 1px solid transparent; }
.site-header.scrolled { border-bottom-color: var(--line); }
.site-header .shell { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); font: 800 1.2rem/1 Manrope, sans-serif; letter-spacing: -.04em; }
.brand svg { width: 30px; height: 30px; }
.brand b { font-weight: 800; color: var(--accent); }
.nav { display: flex; align-items: center; gap: 4px; }
.nav a { padding: 8px 12px; border-radius: 999px; text-decoration: none; font-size: .92rem; font-weight: 600; color: var(--muted); }
.nav a:hover { color: var(--ink); background: var(--sage); }
.nav a.cta { color: #fffdf8; background: var(--ink); }
.nav a.cta:hover { background: var(--accent); color: #fffdf8; }
.nav-ask { display: inline-flex; align-items: center; gap: 7px; padding: 8px 12px; border: 0; border-radius: 999px; background: none; font: inherit; font-size: .92rem; font-weight: 600; color: var(--muted); cursor: pointer; white-space: nowrap; }
.nav-ask:hover { color: var(--ink); background: var(--sage); }
.nav-ask:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
@media (max-width: 640px) { .nav a:not(.cta):not(.keep) { display: none; } }
.brand, .nav a { white-space: nowrap; }
@media (max-width: 420px) { .nav { gap: 0; } .nav a { padding: 8px 10px; } .brand { gap: 8px; font-size: 1.05rem; } .brand svg { width: 26px; height: 26px; } }

/* Buttons */
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 50px; padding: 12px 22px; border-radius: 999px; border: 1px solid transparent; font: 700 1rem/1 Manrope, sans-serif; text-decoration: none; cursor: pointer; transition: transform .15s ease, background .15s ease; }
.button:hover { transform: translateY(-1px); }
.button.primary { color: #fffdf8; background: var(--ink); }
.button.primary:hover { background: var(--accent); }
.button.secondary { color: var(--ink); background: var(--panel); border-color: var(--line); }
.button.secondary:hover { border-color: #cfd8c9; }
.button.block { width: 100%; }

.eyebrow { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 18px; color: var(--accent); font-size: .74rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.eyebrow .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 4px rgba(127, 198, 111, .25); }
.lede { margin-top: 22px; max-width: 590px; color: var(--muted); font-size: clamp(1.05rem, 1.6vw, 1.2rem); line-height: 1.65; }
.fine { margin-top: 14px; color: var(--muted); font-size: .86rem; }

/* Hero */
.hero { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: clamp(32px, 5vw, 64px); align-items: center; padding: clamp(48px, 8vw, 96px) 0 clamp(56px, 8vw, 96px); }
@media (max-width: 900px) { .hero { grid-template-columns: minmax(0, 1fr); } }
.hero h1 em { font-style: normal; color: var(--accent); }

/* Call demo card */
.demo { position: relative; margin: 0; padding: 22px; border: 1px solid var(--line); border-radius: 28px; background: var(--panel); box-shadow: var(--shadow); }
.demo-head { display: flex; align-items: center; justify-content: space-between; padding-bottom: 14px; border-bottom: 1px solid var(--line); font-size: .8rem; color: var(--muted); }
.demo-head strong { color: var(--ink); font: 800 1.05rem Manrope, sans-serif; letter-spacing: -.01em; }
.live { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; color: var(--accent); }
.live::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--green); animation: pulse 1.6s infinite; }
.steps { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 10px; }
.steps li { display: grid; grid-template-columns: 38px 1fr auto; gap: 12px; align-items: center; padding: 12px; border-radius: 16px; background: var(--bg); opacity: 0; transform: translateY(6px); animation: rise .5s ease forwards; }
.steps li:nth-child(1) { animation-delay: .2s; }
.steps li:nth-child(2) { animation-delay: 1.1s; }
.steps li:nth-child(3) { animation-delay: 2s; }
.steps li:nth-child(4) { animation-delay: 2.9s; }
.ico { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 12px; font-size: 1.05rem; }
.ico svg { width: 20px; height: 20px; }
.ico.peach { background: var(--peach); color: #9a5332; }
.ico.sage { background: var(--sage); color: var(--accent); }
.ico.lilac { background: var(--lilac); color: var(--violet); }
.ico.sky { background: var(--sky); color: #2d6a96; }
.steps b { display: block; color: var(--ink); font-size: .93rem; }
.steps li > div > span { display: block; color: var(--muted); font-size: .8rem; line-height: 1.4; }
.steps time { color: var(--muted); font-size: .75rem; font-variant-numeric: tabular-nums; }
.demo pre { margin: 12px 0 0; padding: 14px 16px; border-radius: 16px; background: var(--code-bg); color: var(--code-fg); font-size: .76rem; line-height: 1.55; overflow-x: auto; opacity: 0; animation: rise .5s ease 3.6s forwards; }
.k { color: #9cc9eb; } .s { color: #b9e0a5; } .n { color: #f6c08f; } .c { color: #8aa093; }
@keyframes rise { to { opacity: 1; transform: none; } }
@keyframes pulse { 50% { opacity: .35; } }
@media (prefers-reduced-motion: reduce) { .steps li, .demo pre { animation: none; opacity: 1; transform: none; } .live::before { animation: none; } html { scroll-behavior: auto; } }

/* Sections */
.section { padding: clamp(64px, 9vw, 110px) 0; }
.section.alt { background: var(--panel); border-block: 1px solid var(--line); }
.section-head { max-width: 720px; margin-bottom: clamp(32px, 5vw, 52px); }
.section-head p:not(.eyebrow) { margin-top: 16px; color: var(--muted); font-size: 1.08rem; }
.center { text-align: center; margin-inline: auto; }

.strip { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px 28px; padding: 22px 0; border-block: 1px solid var(--line); color: var(--muted); font-size: .9rem; font-weight: 600; }
.strip span::before { content: "✓"; margin-right: 8px; color: var(--accent); font-weight: 800; }

.how { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; counter-reset: step; }
@media (max-width: 860px) { .how { grid-template-columns: minmax(0, 1fr); } }
.how article { position: relative; padding: 28px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--panel); }
.section.alt .how article { background: var(--bg); }
.how article::before { counter-increment: step; content: counter(step); display: grid; place-items: center; width: 40px; height: 40px; margin-bottom: 18px; border-radius: 12px; background: var(--ink); color: #fffdf8; font: 800 1rem Manrope, sans-serif; }
.how p { margin-top: 10px; color: var(--muted); }

.grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 960px) { .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .grid { grid-template-columns: 1fr; } }
.feature { padding: 26px; border-radius: var(--radius); background: var(--panel); border: 1px solid var(--line); }
.feature .ico { margin-bottom: 16px; }
.feature p { margin-top: 8px; color: var(--muted); font-size: .96rem; }

/* Code split */
.split { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(28px, 5vw, 56px); align-items: start; }
@media (max-width: 900px) { .split { grid-template-columns: minmax(0, 1fr); } }
.checks { list-style: none; margin: 24px 0 0; padding: 0; display: grid; gap: 12px; }
.checks li { display: flex; gap: 12px; color: var(--text); }
.checks li::before { content: ""; flex: 0 0 22px; height: 22px; margin-top: 1px; border-radius: 50%; background: var(--sage) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23365e46' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4 8-9'/%3E%3C/svg%3E") center / 14px no-repeat; }
.code { border-radius: var(--radius); background: var(--code-bg); color: var(--code-fg); box-shadow: var(--shadow); overflow: hidden; }
.tabs { display: flex; gap: 4px; padding: 10px 10px 0; border-bottom: 1px solid rgba(255, 255, 255, .08); overflow-x: auto; }
.tabs button { padding: 9px 14px; border: 0; border-radius: 10px 10px 0 0; background: transparent; color: #a8b8ad; font: 600 .84rem "DM Sans", sans-serif; cursor: pointer; white-space: nowrap; }
.tabs button[aria-selected="true"] { background: rgba(255, 255, 255, .07); color: #fff; }
.code pre { margin: 0; padding: 20px 22px; overflow-x: auto; line-height: 1.65; font-size: .82rem; }
.code [hidden] { display: none; }

/* Use cases */
.cases { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
@media (max-width: 960px) { .cases { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .cases { grid-template-columns: 1fr; } }
.case { padding: 24px; border-radius: var(--radius); }
.case.sage { background: var(--sage); } .case.peach { background: var(--peach); } .case.lilac { background: var(--lilac); } .case.sky { background: var(--sky); }
.case p { margin-top: 8px; color: var(--text); font-size: .94rem; }

/* Pricing */
.plans { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; max-width: 900px; margin-inline: auto; }
@media (max-width: 760px) { .plans { grid-template-columns: 1fr; } }
.plan { display: flex; flex-direction: column; padding: clamp(26px, 4vw, 36px); border-radius: 26px; border: 1px solid var(--line); background: var(--panel); }
.plan.featured { border: 2px solid var(--ink); box-shadow: var(--shadow); }
.plan .tag { align-self: flex-start; margin-bottom: 16px; padding: 5px 11px; border-radius: 999px; background: var(--sage); color: var(--accent); font-size: .72rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.plan .tag.peach { background: var(--peach); color: #9a5332; }
.price { display: flex; align-items: baseline; gap: 6px; margin: 14px 0 6px; }
.price strong { color: var(--ink); font: 800 3.4rem/1 Manrope, sans-serif; letter-spacing: -.05em; }
.price span { color: var(--muted); font-weight: 600; }
.price strong.custom { font-size: 2.6rem; line-height: 3.4rem; }
.plan > p { color: var(--muted); }
.plan .checks { margin: 24px 0 28px; flex: 1; }
.plan .checks li { font-size: .95rem; }

/* FAQ */
.faq { max-width: 820px; margin-inline: auto; display: grid; gap: 10px; }
.faq details { border: 1px solid var(--line); border-radius: 18px; background: var(--panel); }
.faq summary { display: flex; justify-content: space-between; gap: 16px; padding: 20px 22px; cursor: pointer; list-style: none; color: var(--ink); font: 700 1.05rem/1.35 Manrope, sans-serif; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; flex: 0 0 auto; color: var(--accent); font-size: 1.4rem; line-height: 1; transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details > div { padding: 0 22px 20px; color: var(--muted); }
.faq details > div p + p { margin-top: 10px; }

/* Final CTA */
.final { margin: clamp(56px, 8vw, 96px) auto; padding: clamp(40px, 7vw, 72px) clamp(24px, 5vw, 64px); border-radius: 32px; background: var(--ink); color: #dfe8e1; text-align: center; }
.final h2 { color: #fffdf8; }
.final p { max-width: 560px; margin: 16px auto 0; }
.final .actions { justify-content: center; }
.final .button.primary { background: var(--orange); color: var(--ink); }
.final .button.primary:hover { background: #f8bb88; }
.final .button.secondary { background: transparent; color: #fffdf8; border-color: rgba(255, 255, 255, .25); }

/* Footer */
.site-footer { padding: 40px 0 48px; border-top: 1px solid var(--line); color: var(--muted); font-size: .9rem; }
.site-footer .shell { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 20px; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 6px 20px; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { color: var(--ink); }

/* Forms (signup) */
.page { padding: clamp(40px, 7vw, 80px) 0; }
.form-wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 460px); gap: clamp(28px, 6vw, 72px); align-items: start; }
@media (max-width: 860px) { .form-wrap { grid-template-columns: minmax(0, 1fr); } }
.card { padding: clamp(24px, 4vw, 34px); border-radius: 26px; border: 1px solid var(--line); background: var(--panel); box-shadow: var(--shadow); }
.field { display: grid; gap: 6px; margin-bottom: 18px; }
.field label { color: var(--ink); font-weight: 700; font-size: .92rem; }
.field small { color: var(--muted); font-size: .82rem; }
.field input { width: 100%; min-height: 48px; padding: 10px 14px; border: 1px solid #d6ddd2; border-radius: 12px; background: #fff; color: var(--ink); font: inherit; }
.field input:focus { outline: 3px solid rgba(119, 96, 216, .35); border-color: var(--violet); }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.error { margin-bottom: 18px; padding: 12px 14px; border-radius: 12px; background: #fbe9e4; color: #8a3b22; font-size: .92rem; }
.keybox { display: flex; gap: 8px; align-items: stretch; margin: 10px 0 6px; }
.keybox code { flex: 1; min-width: 0; padding: 12px 14px; border-radius: 12px; background: var(--code-bg) !important; color: var(--code-fg) !important; overflow-wrap: anywhere; font-size: .82rem; }
.keybox button { flex: 0 0 auto; padding: 0 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); font: 700 .85rem Manrope, sans-serif; cursor: pointer; }
.timeline { list-style: none; margin: 22px 0 0; padding: 0; display: grid; gap: 14px; }
.timeline li { display: grid; grid-template-columns: 30px 1fr; gap: 12px; color: var(--muted); }
.timeline li b { display: block; color: var(--ink); }
.timeline li::before { content: attr(data-n); display: grid; place-items: center; width: 30px; height: 30px; border-radius: 10px; background: var(--sage); color: var(--accent); font: 800 .85rem Manrope, sans-serif; }

/* Docs */
.docs { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: clamp(28px, 5vw, 64px); align-items: start; padding: clamp(40px, 6vw, 72px) 0; }
@media (max-width: 860px) { .docs { grid-template-columns: minmax(0, 1fr); } .toc { display: none; } }
.toc { position: sticky; top: 92px; display: grid; gap: 2px; font-size: .9rem; }
.toc a { padding: 6px 10px; border-radius: 8px; text-decoration: none; color: var(--muted); }
.toc a:hover { background: var(--sage); color: var(--ink); }
.prose { max-width: 760px; min-width: 0; }
.prose :not(pre) > code { overflow-wrap: anywhere; }
.prose h1 { font-size: clamp(2.2rem, 5vw, 3.2rem); }
.prose h2 { margin: 56px 0 14px; font-size: 1.8rem; scroll-margin-top: 90px; }
.prose h3 { margin: 28px 0 8px; scroll-margin-top: 90px; }
.prose p, .prose ul, .prose ol { margin: 12px 0; }
.prose li { margin: 6px 0; }
.prose pre { margin: 14px 0; padding: 16px 18px; border-radius: 16px; background: var(--code-bg); color: var(--code-fg); overflow-x: auto; line-height: 1.6; }
.prose table { width: 100%; margin: 14px 0; border-collapse: collapse; font-size: .92rem; display: block; overflow-x: auto; }
.prose th, .prose td { padding: 10px 12px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.prose th { color: var(--ink); font-family: Manrope, sans-serif; }
.method { display: inline-block; min-width: 58px; margin-right: 6px; padding: 2px 8px; border-radius: 6px; background: var(--sage); color: var(--accent); font: 800 .72rem ui-monospace, monospace; text-align: center; }
.method.post { background: var(--peach); color: #9a5332; }
.method.patch { background: var(--lilac); color: var(--violet); }
.method.del { background: #fbe9e4; color: #8a3b22; }
.note { margin: 18px 0; padding: 14px 16px; border-left: 4px solid var(--green); border-radius: 0 12px 12px 0; background: var(--sage); color: var(--text); }

/* Ask Ava (workrr agent): centered in the header, plus a footer link */
.ask-slot { flex: 1; display: flex; justify-content: center; min-width: 0; }
.ask-center { display: inline-flex; align-items: center; gap: 8px; padding: 7px 15px 7px 9px; border: 1px solid var(--line); border-radius: 999px; background: var(--panel); color: var(--ink); font: inherit; font-size: .92rem; font-weight: 600; white-space: nowrap; cursor: pointer; transition: border-color .15s, background .15s; }
.ask-center:hover { border-color: var(--accent); }
.ask-center:focus-visible, .footer-ask:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.footer-ask { display: inline-flex; align-items: center; gap: 7px; padding: 0; border: 0; background: none; color: inherit; font: inherit; cursor: pointer; }
.footer-ask:hover { color: var(--ink); }
.nav-ask { display: none !important; }
@media (max-width: 640px) { .ask-slot { display: none; } .nav-ask { display: inline-flex !important; } }
