/* Akela Labs — akelalabs.ru, app.akelalabs.ru */
:root {
  --bg: #f5f3ef;
  --surface: #ffffff;
  --ink: #121418;
  --ink-2: #2a2e35;
  --muted: #5b5f67;
  --line: #e2ddd5;
  --accent: #ff5a1f;
  --accent-ink: #b33a0c;
  --accent-soft: #ffe7dc;
  --dark: #121418;
  --dark-2: #1b1e24;
  --dark-line: #2c3038;
  --on-dark: #f2efea;
  --on-dark-muted: #a9acb3;
  --ok: #18a34a;
  --bad: #e5484d;
  --radius: 20px;
  --radius-sm: 12px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  --wrap: 1200px;
  --pad: clamp(20px, 4vw, 40px);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 88px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { transition: none !important; animation: none !important; } }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
body { min-height: 100vh; display: flex; flex-direction: column; }
body > main, body > .portal { flex: 1 0 auto; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--accent-ink); }
h1, h2, h3, h4 { margin: 0; line-height: 1.12; letter-spacing: -0.025em; font-weight: 800; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

.wrap { width: 100%; max-width: calc(var(--wrap) + 2 * var(--pad)); margin: 0 auto; padding: 0 var(--pad); }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 10px; text-decoration: none; }
.skip:focus { top: 12px; color: #fff; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(245, 243, 239, 0.86);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid transparent;
}
.site-header.is-solid, .site-header { border-bottom-color: rgba(18, 20, 24, 0.06); }
.header-row { display: flex; align-items: center; gap: 28px; height: 72px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 800; font-size: 19px; letter-spacing: -0.02em; color: var(--ink); }
.brand:hover { color: var(--ink); }
.brand svg { width: 34px; height: 34px; flex: none; }
.brand small { font-family: var(--mono); font-weight: 500; font-size: 12px; letter-spacing: 0; color: var(--muted); padding: 2px 8px; border: 1px solid var(--line); border-radius: 999px; }
.nav { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.nav a { text-decoration: none; font-size: 15px; font-weight: 550; color: var(--ink-2); padding: 8px 12px; border-radius: 10px; }
.nav a:hover { background: rgba(18, 20, 24, 0.06); color: var(--ink); }
.nav a.btn-dark, .nav a.btn-dark:hover { color: #fff; background: var(--ink); margin-left: 8px; }
.nav a.btn-dark:hover { background: #2a2e35; }
.nav-toggle { display: none; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 0 22px;
  font: inherit; font-size: 16px; font-weight: 700; letter-spacing: -0.01em;
  text-decoration: none; cursor: pointer;
  border: 0; border-radius: 999px;
  transition: transform .15s ease, background-color .15s ease, box-shadow .15s ease;
}
.btn:active { transform: translateY(1px); }
.btn-accent { background: var(--accent); color: var(--ink); box-shadow: 0 1px 0 rgba(0,0,0,.08), 0 8px 24px -10px rgba(255, 90, 31, .7); }
.btn-accent:hover { background: #ff6c35; color: var(--ink); }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: #24272e; color: #fff; }
.btn-ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px rgba(18,20,24,.18); }
.btn-ghost:hover { box-shadow: inset 0 0 0 1.5px var(--ink); color: var(--ink); }
.btn-sm { min-height: 40px; padding: 0 16px; font-size: 15px; }
.btn svg { width: 18px; height: 18px; }
.btn[disabled] { opacity: .65; cursor: progress; }

/* ---------- hero ---------- */
.hero { padding: clamp(40px, 7vw, 96px) 0 clamp(56px, 7vw, 88px); overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr); gap: clamp(32px, 5vw, 72px); align-items: center; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font-family: var(--mono); font-size: 13px; letter-spacing: 0.02em; color: var(--muted); text-transform: uppercase; }
.eyebrow::before { content: ""; width: 8px; height: 8px; border-radius: 2px; background: var(--accent); transform: rotate(45deg); }
.hero h1 { font-size: clamp(44px, 6.6vw, 88px); line-height: 0.98; letter-spacing: -0.045em; margin: 22px 0 26px; }
.hero h1 em { font-style: normal; position: relative; white-space: nowrap; }
.hero h1 em::after { content: ""; position: absolute; left: -0.04em; right: -0.04em; bottom: 0.06em; height: 0.2em; background: var(--accent); z-index: -1; border-radius: 3px; }
.hero .lead { font-size: clamp(18px, 1.6vw, 21px); line-height: 1.55; color: var(--ink-2); max-width: 36em; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }
.hero-facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; margin-top: 48px; padding-top: 28px; border-top: 1px solid var(--line); list-style: none; }
.hero-facts b { display: block; font-size: 15px; font-weight: 750; letter-spacing: -0.01em; margin-bottom: 4px; }
.hero-facts span { display: block; font-size: 14px; line-height: 1.45; color: var(--muted); }

/* chat mock */
.chat {
  position: relative;
  width: 100%; max-width: 420px; margin: 0 0 0 auto;
  background: var(--surface);
  border-radius: 28px;
  box-shadow: 0 1px 0 rgba(18,20,24,.04), 0 30px 60px -28px rgba(18, 20, 24, .35), 0 0 0 1px rgba(18,20,24,.06);
  overflow: hidden;
}
.chat-head { display: flex; align-items: center; gap: 12px; padding: 16px 18px; border-bottom: 1px solid #eee9e2; background: #fff; }
.chat-ava { width: 40px; height: 40px; border-radius: 50%; background: var(--ink); display: grid; place-items: center; flex: none; }
.chat-ava svg { width: 26px; height: 26px; }
.chat-head b { display: block; font-size: 15px; line-height: 1.2; }
.chat-head small { display: block; font-size: 13px; color: var(--muted); }
.chat-head .online { margin-left: auto; font-family: var(--mono); font-size: 11px; color: var(--ok); display: inline-flex; align-items: center; gap: 6px; }
.chat-head .online::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--ok); }
.chat-body {
  display: flex; flex-direction: column; gap: 10px;
  padding: 18px 16px 44px;
  background:
    radial-gradient(circle at 20% 10%, rgba(255, 90, 31, .07), transparent 40%),
    radial-gradient(circle at 90% 80%, rgba(24, 163, 74, .06), transparent 45%),
    #f3efe8;
  font-size: 14.5px; line-height: 1.45;
}
.msg { position: relative; max-width: 88%; padding: 10px 14px 18px; border-radius: 16px; background: #fff; box-shadow: 0 1px 1px rgba(0,0,0,.05); }
.msg time { position: absolute; right: 10px; bottom: 4px; font-size: 11px; color: #8b8f96; }
.msg.me { align-self: flex-end; background: #e4f6d9; border-bottom-right-radius: 6px; }
.msg.bot { border-bottom-left-radius: 6px; }
.msg-title { font-weight: 700; margin-bottom: 4px; }
.msg ul { list-style: none; display: grid; gap: 2px; }
.msg ul li::before { content: "—"; color: #9a9ea5; margin-right: 6px; }
.msg .kb { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin: 10px -6px -10px; }
.msg .kb span { display: block; text-align: center; padding: 7px 8px; border-radius: 10px; background: #f1ede6; font-size: 13px; font-weight: 600; color: var(--ink-2); }
.msg.alert { display: flex; align-items: flex-start; gap: 8px; padding-right: 48px; padding-bottom: 10px; }
.msg.alert time { bottom: auto; top: 11px; }
.dot { width: 9px; height: 9px; border-radius: 50%; flex: none; margin-top: 6px; }
.dot-red { background: var(--bad); box-shadow: 0 0 0 3px rgba(229,72,77,.15); }
.dot-green { background: var(--ok); box-shadow: 0 0 0 3px rgba(24,163,74,.15); }
.hero-visual { position: relative; }
.hero-visual .badge {
  position: absolute; right: -18px; bottom: -26px; z-index: 2;
  display: flex; align-items: center; gap: 10px;
  padding: 12px 16px; border-radius: 16px;
  background: var(--ink); color: var(--on-dark);
  font-size: 14px; line-height: 1.3;
  box-shadow: 0 20px 40px -18px rgba(18,20,24,.6);
}
.hero-visual .badge b { display: block; font-size: 15px; }
.hero-visual .badge span { color: var(--on-dark-muted); font-size: 13px; }
.hero-visual .badge svg { width: 30px; height: 30px; color: var(--accent); flex: none; }

.stack-strip { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 22px 0; }
.stack-row { display: flex; align-items: center; gap: 18px 28px; flex-wrap: wrap; }
.stack-row p { font-size: 14px; color: var(--muted); margin-right: 8px; }
.stack-row ul { display: flex; flex-wrap: wrap; gap: 10px 26px; list-style: none; }
.stack-row li { font-weight: 700; font-size: 15px; color: var(--ink-2); letter-spacing: -0.01em; }

/* ---------- sections ---------- */
.section { padding: clamp(64px, 9vw, 120px) 0; }
.section-head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px 64px; align-items: end; margin-bottom: clamp(36px, 5vw, 56px); }
.section-head h2 { font-size: clamp(34px, 4.4vw, 56px); letter-spacing: -0.035em; margin-top: 16px; }
.section-head p { color: var(--muted); font-size: 18px; max-width: 34em; }
.num { font-family: var(--mono); font-size: 13px; color: var(--muted); letter-spacing: .04em; text-transform: uppercase; }
.num i { font-style: normal; color: var(--accent-ink); }

/* services */
.services { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; list-style: none; }
.service {
  position: relative; display: flex; flex-direction: column;
  padding: 28px 28px 26px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid #ebe6de;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.service:hover { transform: translateY(-3px); box-shadow: 0 24px 40px -28px rgba(18,20,24,.35); border-color: #ddd6cb; }
.service-icon { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent-ink); margin-bottom: 22px; }
.service-icon svg { width: 24px; height: 24px; }
.service h3 { font-size: 22px; letter-spacing: -0.02em; margin-bottom: 10px; }
.service p { color: var(--ink-2); font-size: 16px; line-height: 1.55; }
.service .eg { margin-top: auto; padding-top: 18px; font-size: 14px; color: var(--muted); line-height: 1.5; }
.service .eg b { color: var(--ink-2); font-weight: 650; }

/* cases (dark) */
.dark { background: var(--dark); color: var(--on-dark); }
.dark a:hover { color: #ffb08f; }
.dark .section-head p, .dark .num { color: var(--on-dark-muted); }
.dark .num i { color: #ff8a5e; }
.cases { display: grid; gap: 18px; list-style: none; }
.case { background: var(--dark-2); border: 1px solid var(--dark-line); border-radius: 24px; padding: clamp(24px, 3.4vw, 40px); }
.case-top { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px 24px; align-items: start; margin-bottom: 28px; }
.case-for { font-family: var(--mono); font-size: 13px; color: #ff8a5e; letter-spacing: 0.01em; margin-bottom: 12px; }
.case h3 { font-size: clamp(24px, 2.6vw, 32px); letter-spacing: -0.03em; max-width: 24em; }
.case-n { font-family: var(--mono); font-size: 13px; color: var(--on-dark-muted); border: 1px solid var(--dark-line); padding: 4px 10px; border-radius: 999px; }
.case-cols { display: grid; grid-template-columns: 1fr 1.35fr 1fr; gap: 28px; }
.case-cols h4 { font-size: 13px; font-family: var(--mono); font-weight: 500; letter-spacing: .04em; text-transform: uppercase; color: var(--on-dark-muted); margin-bottom: 10px; }
.case-cols p, .case-cols li { font-size: 15.5px; line-height: 1.6; color: #dcd9d3; }
.case-cols ul { list-style: none; display: grid; gap: 8px; }
.case-cols li { padding-left: 18px; position: relative; }
.case-cols li::before { content: ""; position: absolute; left: 0; top: .72em; width: 7px; height: 2px; background: var(--accent); }
.case-result p { color: #fff; font-weight: 550; }
.case-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 24px; margin-top: 28px; padding-top: 22px; border-top: 1px solid var(--dark-line); }
.sample { display: flex; align-items: center; gap: 12px; min-width: 0; font-size: 14px; }
.sample span { font-family: var(--mono); font-size: 12px; color: var(--on-dark-muted); white-space: nowrap; }
.sample code { font-family: var(--mono); font-size: 13.5px; color: #f6e7df; background: rgba(255, 90, 31, .1); border: 1px solid rgba(255, 90, 31, .25); padding: 6px 10px; border-radius: 8px; overflow-wrap: anywhere; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; }
.tags li { font-size: 13px; padding: 4px 10px; border-radius: 999px; background: rgba(255,255,255,.06); color: #cfccc6; }

/* process */
.steps { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 14px; list-style: none; counter-reset: step; }
.step { position: relative; padding: 24px 22px 22px; border-radius: var(--radius); background: var(--surface); border: 1px solid #ebe6de; display: flex; flex-direction: column; }
.step-n { font-family: var(--mono); font-size: 13px; color: var(--accent-ink); margin-bottom: 18px; display: flex; align-items: center; gap: 8px; }
.step-n::after { content: ""; flex: 1; height: 1px; background: linear-gradient(90deg, var(--line), transparent); }
.step h3 { font-size: 19px; letter-spacing: -0.02em; margin-bottom: 8px; }
.step p { font-size: 15px; line-height: 1.55; color: var(--ink-2); }
.step .when { margin-top: auto; padding-top: 16px; font-size: 13px; color: var(--muted); font-family: var(--mono); }
.principles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px; margin-top: 56px; padding-top: 40px; border-top: 1px solid var(--line); list-style: none; }
.principles b { display: block; font-size: 17px; letter-spacing: -0.01em; margin-bottom: 6px; }
.principles span { display: block; font-size: 15px; color: var(--muted); line-height: 1.55; }

/* faq */
.faq-grid { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: 48px 80px; align-items: start; }
.faq-grid .section-head { display: block; margin: 0; position: sticky; top: 104px; }
.faq-grid .section-head p { margin-top: 18px; }
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 22px 0; font-size: 19px; font-weight: 700; letter-spacing: -0.015em; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; flex: none; width: 28px; height: 28px; border-radius: 50%; background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23121418' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M12 6v12M6 12h12'/%3E%3C/svg%3E") center / 16px no-repeat; border: 1px solid var(--line); transition: transform .2s ease; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq summary:hover { color: var(--accent-ink); }
.faq .answer { padding: 0 48px 24px 0; color: var(--ink-2); font-size: 16.5px; }
.faq .answer p + p { margin-top: 10px; }

/* contact */
.contact { background: var(--surface); border-top: 1px solid var(--line); }
.contact-grid { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.contact h2 { font-size: clamp(34px, 4.4vw, 56px); letter-spacing: -0.035em; margin: 16px 0 20px; }
.contact .intro { color: var(--ink-2); font-size: 18px; }
.next-steps { list-style: none; display: grid; gap: 18px; margin-top: 36px; counter-reset: ns; }
.next-steps li { display: grid; grid-template-columns: 36px 1fr; gap: 14px; align-items: start; counter-increment: ns; font-size: 15.5px; color: var(--ink-2); }
.next-steps li::before { content: counter(ns); width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--bg); border: 1px solid var(--line); font-family: var(--mono); font-size: 14px; color: var(--ink); }
.next-steps b { display: block; color: var(--ink); }
.form-card { background: var(--bg); border: 1px solid var(--line); border-radius: 28px; padding: clamp(24px, 3.5vw, 40px); }
.field { display: grid; gap: 8px; margin-bottom: 20px; }
.field label { font-weight: 650; font-size: 15px; }
.field .hint { font-weight: 400; color: var(--muted); }
.field input, .field textarea {
  width: 100%; font: inherit; font-size: 16px; color: var(--ink);
  background: var(--surface); border: 1.5px solid #d9d3c9; border-radius: 14px;
  padding: 13px 16px; transition: border-color .15s ease, box-shadow .15s ease;
}
.field textarea { min-height: 156px; resize: vertical; line-height: 1.5; }
.field input::placeholder, .field textarea::placeholder { color: #8e9198; }
.field input:hover, .field textarea:hover { border-color: #bfb7ab; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 4px rgba(255, 90, 31, .22); }
.field [aria-invalid="true"] { border-color: var(--bad); }
.field-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: 0 16px; }
.field-meta { display: flex; justify-content: space-between; gap: 12px; }
.counter { font-family: var(--mono); font-size: 12px; color: var(--muted); margin-left: auto; }
.counter.is-over { color: var(--bad); }
.err { color: #c4282d; font-size: 14px; font-weight: 550; }
.check { display: grid; grid-template-columns: 22px 1fr; gap: 12px; align-items: start; margin: 4px 0 6px; font-size: 15px; color: var(--ink-2); }
.check input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--ink); }
.check-wrap { margin-bottom: 22px; }
.check-wrap .err { margin-left: 34px; display: block; }
.hp { position: absolute !important; left: -10000px !important; width: 1px; height: 1px; overflow: hidden; }
.form-status { margin: 0 0 18px; padding: 12px 16px; border-radius: 12px; font-size: 15px; font-weight: 550; }
.form-status.is-error { background: #fdecec; color: #9f1c20; border: 1px solid #f5c2c4; }
.form-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 20px; }
.form-foot p { font-size: 14px; color: var(--muted); }
.form-success { text-align: left; }
.form-success .ok-mark { width: 56px; height: 56px; border-radius: 50%; background: var(--ok); color: #fff; display: grid; place-items: center; margin-bottom: 22px; }
.form-success .ok-mark svg { width: 28px; height: 28px; }
.form-success h3 { font-size: 30px; letter-spacing: -0.03em; margin-bottom: 10px; }
.form-success h3:focus { outline: none; }
.form-success p { color: var(--ink-2); margin-bottom: 24px; }
.noscript { padding: 12px 16px; border-radius: 12px; background: var(--accent-soft); margin-bottom: 18px; font-size: 15px; }

/* footer */
.site-footer { background: var(--dark); color: var(--on-dark-muted); padding: 56px 0 40px; font-size: 15px; }
.site-footer .brand { color: var(--on-dark); }
.site-footer .brand small { border-color: var(--dark-line); color: var(--on-dark-muted); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 32px; }
.footer-grid p { margin-top: 14px; max-width: 26em; }
.footer-grid h2 { font-size: 13px; font-family: var(--mono); font-weight: 500; color: var(--on-dark); letter-spacing: .04em; text-transform: uppercase; margin-bottom: 14px; }
.footer-grid ul { list-style: none; display: grid; gap: 8px; }
.footer-grid a { text-decoration: none; color: var(--on-dark-muted); }
.footer-grid a:hover { color: #fff; text-decoration: underline; }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--dark-line); font-size: 14px; }

/* ---------- document pages (privacy) ---------- */
.doc { padding: clamp(40px, 6vw, 80px) 0 clamp(64px, 8vw, 110px); }
.doc-grid { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 64px; align-items: start; }
.doc-toc { position: sticky; top: 104px; font-size: 14px; }
.doc-toc p { font-family: var(--mono); font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); margin-bottom: 12px; }
.doc-toc ol { margin: 0; padding: 0 0 0 26px; display: grid; gap: 6px; color: var(--muted); }
.doc-toc a { text-decoration: none; color: var(--ink-2); }
.doc-toc a:hover { color: var(--accent-ink); text-decoration: underline; }
.prose { max-width: 760px; }
.prose h1 { font-size: clamp(34px, 4.6vw, 54px); letter-spacing: -0.035em; margin: 16px 0 14px; }
.prose .meta { color: var(--muted); font-size: 15px; margin-bottom: 36px; }
.prose h2 { font-size: 24px; letter-spacing: -0.02em; margin: 44px 0 14px; scroll-margin-top: 96px; }
.prose p, .prose li { color: var(--ink-2); font-size: 16.5px; }
.prose p + p { margin-top: 12px; }
.prose ul, .prose ol { padding-left: 22px; margin: 12px 0; display: grid; gap: 6px; }
.prose .note { margin-top: 40px; padding: 20px 24px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line); }

/* ---------- 404 ---------- */
.notfound { min-height: calc(100vh - 72px - 220px); display: grid; place-items: center; padding: 72px 0; text-align: center; }
.notfound .code { font-family: var(--mono); font-size: 14px; color: var(--accent-ink); }
.notfound h1 { font-size: clamp(40px, 6vw, 72px); letter-spacing: -0.04em; margin: 14px 0 16px; }
.notfound p { color: var(--ink-2); max-width: 30em; margin: 0 auto; font-size: 18px; }
.notfound .tracks { display: flex; justify-content: center; gap: 18px; margin: 0 auto 28px; opacity: .9; }
.notfound .tracks svg { width: 28px; height: 28px; color: var(--ink); }
.notfound .tracks svg:nth-child(2) { opacity: .6; transform: translateY(10px) rotate(8deg); }
.notfound .tracks svg:nth-child(3) { opacity: .3; transform: rotate(-6deg); }
.notfound .tracks svg:nth-child(4) { opacity: .12; transform: translateY(10px) rotate(10deg); }
.notfound .hero-cta { justify-content: center; }

/* ---------- client portal (app.akelalabs.ru) ---------- */
.portal { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.portal-main { display: flex; flex-direction: column; padding: 32px clamp(24px, 5vw, 72px) 40px; }
.portal-main .brand { margin-bottom: auto; }
.portal-body { max-width: 480px; margin: 56px 0; }
.portal-body h1 { font-size: clamp(38px, 4.6vw, 58px); letter-spacing: -0.04em; margin: 18px 0 18px; }
.portal-body .lead { color: var(--ink-2); font-size: 18px; }
.invite { margin-top: 32px; padding: 22px 22px 22px 20px; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); display: grid; grid-template-columns: 40px 1fr; gap: 16px; }
.invite-icon { width: 40px; height: 40px; border-radius: 12px; background: var(--accent-soft); color: var(--accent-ink); display: grid; place-items: center; }
.invite-icon svg { width: 22px; height: 22px; }
.invite b { display: block; font-size: 17px; margin-bottom: 4px; }
.invite p { font-size: 15.5px; color: var(--ink-2); }
.invite p + p { margin-top: 8px; }
.portal-body .hero-cta { margin-top: 28px; }
.portal-small { font-size: 14px; color: var(--muted); margin-top: 28px; }
.portal-foot { display: flex; flex-wrap: wrap; gap: 8px 20px; font-size: 14px; color: var(--muted); }
.portal-foot a { color: var(--muted); }
.portal-side { position: relative; background: var(--dark); color: var(--on-dark); padding: 56px clamp(24px, 4vw, 64px); display: flex; flex-direction: column; justify-content: center; overflow: hidden; }
.portal-side::before { content: ""; position: absolute; inset: auto -20% -30% auto; width: 520px; height: 520px; border-radius: 50%; background: radial-gradient(circle, rgba(255, 90, 31, .28), transparent 65%); }
.portal-side h2 { font-size: 15px; font-family: var(--mono); font-weight: 500; letter-spacing: .04em; text-transform: uppercase; color: var(--on-dark-muted); margin-bottom: 22px; position: relative; }
.preview { position: relative; background: var(--dark-2); border: 1px solid var(--dark-line); border-radius: 22px; padding: 22px 22px 76px; box-shadow: 0 40px 80px -40px rgba(0,0,0,.8); max-width: 520px; }
.preview-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 18px; gap: 12px; }
.preview-top b { font-size: 16px; }
.pill { font-family: var(--mono); font-size: 12px; padding: 4px 10px; border-radius: 999px; background: rgba(24, 163, 74, .15); color: #6fd08f; white-space: nowrap; }
.stages { list-style: none; display: grid; gap: 10px; }
.stages li { display: grid; grid-template-columns: 22px 1fr auto; gap: 12px; align-items: center; padding: 12px 14px; border-radius: 14px; background: rgba(255,255,255,.03); border: 1px solid var(--dark-line); font-size: 14.5px; }
.stages .st { width: 18px; height: 18px; border-radius: 50%; border: 2px solid #4a4f59; }
.stages .done .st { background: var(--ok); border-color: var(--ok); }
.stages .now .st { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(255,90,31,.18); }
.stages small { font-family: var(--mono); font-size: 12px; color: var(--on-dark-muted); }
.stages .now { border-color: rgba(255,90,31,.45); }
.preview-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 10px; }
.preview-cards div { padding: 14px; border-radius: 14px; background: rgba(255,255,255,.03); border: 1px solid var(--dark-line); }
.preview-cards small { display: block; font-size: 12px; color: var(--on-dark-muted); margin-bottom: 6px; font-family: var(--mono); }
.preview-cards b { font-size: 15px; }
.lockveil { position: absolute; inset: 0; border-radius: 22px; background: linear-gradient(180deg, rgba(18,20,24,0) 45%, rgba(18,20,24,.7) 100%); display: flex; align-items: flex-end; justify-content: center; padding-bottom: 22px; }
.lockveil span { display: inline-flex; align-items: center; gap: 8px; font-size: 13.5px; padding: 8px 14px; border-radius: 999px; background: rgba(18,20,24,.9); border: 1px solid var(--dark-line); color: var(--on-dark); }
.lockveil svg { width: 16px; height: 16px; }
.portal-side ul.feat { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 14px 24px; margin-top: 34px; position: relative; max-width: 520px; }
.portal-side ul.feat li { font-size: 14.5px; color: #d6d3cd; padding-left: 18px; position: relative; }
.portal-side ul.feat li::before { content: ""; position: absolute; left: 0; top: .7em; width: 8px; height: 2px; background: var(--accent); }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .services { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .steps .step:last-child { grid-column: 1 / -1; }
  .principles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .case-cols { grid-template-columns: 1fr 1fr; }
  .case-cols .case-result { grid-column: 1 / -1; }
}
@media (max-width: 900px) {
  .nav-toggle {
    display: inline-flex; align-items: center; justify-content: center;
    width: 44px; height: 44px; margin-left: auto; border-radius: 12px;
    border: 1px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer;
    -webkit-tap-highlight-color: transparent;
  }
  .nav-toggle svg { width: 22px; height: 22px; }
  .nav-toggle .i-close { display: none; }
  .nav-open .nav-toggle .i-open { display: none; }
  .nav-open .nav-toggle .i-close { display: block; }
  .nav {
    display: none; position: absolute; left: 0; right: 0; top: 72px;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--line);
    padding: 8px var(--pad) 20px; box-shadow: 0 20px 30px -20px rgba(0,0,0,.25);
  }
  .nav-open .nav { display: flex; }
  .nav a { padding: 14px 4px; font-size: 18px; border-bottom: 1px solid var(--line); border-radius: 0; }
  .nav a.btn, .nav a.btn-dark { margin: 16px 0 0; border: 0; border-radius: 999px; justify-content: center; padding: 0 22px; }
  .header-cta { display: none; }
  .hero-grid { grid-template-columns: minmax(0, 1fr); }
  .chat { margin: 0 auto; }
  .hero-visual .badge { right: 0; }
  .section-head { grid-template-columns: 1fr; }
  .faq-grid { grid-template-columns: 1fr; gap: 28px; }
  .faq-grid .section-head { position: static; }
  .contact-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-grid > div:first-child { grid-column: 1 / -1; }
  .doc-grid { grid-template-columns: 1fr; gap: 24px; }
  .doc-toc { position: static; padding: 20px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line); }
  .portal { grid-template-columns: 1fr; }
  .portal-body { margin: 40px 0 48px; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .hero h1 { font-size: clamp(32px, 10.2vw, 56px); }
  .eyebrow { font-size: 11.5px; align-items: flex-start; }
  .eyebrow::before { margin-top: 4px; }
  .hero-facts { grid-template-columns: 1fr; gap: 14px; margin-top: 36px; }
  .hero-cta .btn { flex: 1 1 100%; }
  .services { grid-template-columns: 1fr; }
  .service { padding: 24px 22px; }
  .steps { grid-template-columns: 1fr; }
  .principles { grid-template-columns: 1fr; gap: 20px; }
  .case-top { grid-template-columns: 1fr; }
  .case-n { justify-self: start; order: -1; }
  .case-cols { grid-template-columns: 1fr; gap: 22px; }
  .sample { flex-direction: column; align-items: flex-start; gap: 6px; }
  .field-row { grid-template-columns: 1fr; }
  .faq summary { font-size: 17px; }
  .faq .answer { padding-right: 0; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-visual .badge { position: relative; left: auto; bottom: auto; margin: -28px auto 0; width: max-content; max-width: 92%; }
  .portal-side ul.feat { grid-template-columns: 1fr; }
  .chat-body { font-size: 14px; }
}
