:root {
  /* Палитра визитки FeedMer: тёмный графит + синий акцент на белом */
  --ink: #111827;
  --ink-soft: #4b5563;
  --navy: #1e3a8a;
  --navy-deep: #0f172a;
  --teal: #2563eb;          /* основной акцент (синий) */
  --teal-bright: #3b82f6;
  --teal-pale: #e8f0fe;
  --blue-pale: #eff6ff;
  --orange: #f59e0b;
  --orange-pale: #fef3c7;
  --green: #059669;
  --green-pale: #d1fae5;
  --paper: #ffffff;
  --surface: #f8fafc;
  --line: #e5e7eb;
  --shadow: 0 24px 60px rgba(17, 24, 39, 0.10);
  --shadow-soft: 0 10px 30px rgba(17, 24, 39, 0.06);
  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 24px;
  --container: 1200px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
/* Скрытое мобильное меню (translateX(100%)) не должно расширять страницу */
html, body { overflow-x: clip; }
[id] { scroll-margin-top: 96px; }

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.58;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

body.nav-open { overflow: hidden; }

img, svg { max-width: 100%; }
button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-underline-offset: 3px; }

h1, h2, h3, h4, p, ul, ol, blockquote, dl { margin-top: 0; }
h1, h2, h3, strong { letter-spacing: -0.025em; }
h1 { font-size: clamp(2.45rem, 5vw, 4.4rem); line-height: 1.03; }
h2 { font-size: clamp(1.9rem, 3.5vw, 3rem); line-height: 1.08; }
h3 { font-size: 1.25rem; line-height: 1.25; }

::selection { color: #fff; background: var(--teal); }
:focus-visible { outline: 3px solid #93c5fd; outline-offset: 3px; }

.container { width: min(calc(100% - 40px), var(--container)); margin-inline: auto; }
.container.narrow { width: min(calc(100% - 40px), 880px); }

.visually-hidden {
  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: fixed; z-index: 200; top: 10px; left: 10px; padding: 10px 16px;
  color: #fff; background: var(--navy); border-radius: 8px;
  transform: translateY(-150%); transition: transform 0.2s ease;
}
.skip-link:focus { transform: translateY(0); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; z-index: 100; top: 0; height: 72px;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}
.header-inner {
  width: min(calc(100% - 36px), 1440px); height: 100%; margin-inline: auto;
  display: flex; align-items: center; gap: 28px;
}
.brand { flex: 0 0 auto; display: flex; align-items: center; gap: 8px; text-decoration: none; }
.brand img { display: block; width: 136px; height: auto; }
.brand-tag {
  padding: 3px 9px; border-radius: 999px; font-size: 11px; font-weight: 800;
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--teal); background: var(--teal-pale);
}
.brand-tag-light { color: #dbe7fe; background: rgba(255, 255, 255, 0.14); }

.main-nav { flex: 1; display: flex; align-items: center; justify-content: center; gap: 2px; }
.main-nav a {
  padding: 10px 11px; color: #374151; border-radius: 9px; text-decoration: none;
  font-size: 13px; font-weight: 650; white-space: nowrap;
  transition: color 0.2s ease, background 0.2s ease;
}
.main-nav a:hover, .main-nav a.is-active { color: var(--navy); background: var(--surface); }

.header-cta {
  flex: 0 0 auto; padding: 10px 16px; color: #fff; background: var(--teal);
  border-radius: 999px; text-decoration: none; font-size: 13px; font-weight: 750;
  transition: background 0.2s ease;
}
.header-cta:hover { background: #1d4ed8; }

.menu-button {
  display: none; width: 44px; height: 44px; padding: 11px;
  background: var(--surface); border: 0; border-radius: 10px; cursor: pointer;
}
.menu-button > span:not(.visually-hidden) {
  display: block; width: 100%; height: 2px; margin: 4px 0;
  background: var(--ink); border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.menu-button[aria-expanded="true"] > span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.menu-button[aria-expanded="true"] > span:nth-child(2) { opacity: 0; }
.menu-button[aria-expanded="true"] > span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* ---------- Typography helpers ---------- */
.eyebrow {
  margin-bottom: 18px; color: var(--teal); font-size: 14px; font-weight: 700;
  letter-spacing: 0.02em; line-height: 1.45;
}
.eyebrow-light { color: #bfdbfe; }
.lead { font-size: 1.15rem; color: var(--ink-soft); }
.muted { color: var(--ink-soft); }
.small { font-size: 0.9rem; }
.text-link { display: inline-flex; gap: 8px; color: var(--teal); text-decoration: none; font-weight: 750; }
.text-link span { transition: transform 0.2s ease; }
.text-link:hover span { transform: translateX(4px); }

/* ---------- Buttons ---------- */
.button-row { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; }
.button-row.centered { justify-content: center; }
.button {
  min-height: 48px; display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 13px 20px; border: 1px solid transparent; border-radius: 11px;
  text-decoration: none; font-size: 14px; font-weight: 760; line-height: 1.2; cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
}
.button:hover { transform: translateY(-2px); }
.button-primary { color: #fff; background: var(--teal); box-shadow: 0 10px 26px rgba(37, 99, 235, 0.25); }
.button-primary:hover { background: #1d4ed8; box-shadow: 0 13px 30px rgba(37, 99, 235, 0.32); }
.button-dark { color: #fff; background: var(--navy); }
.button-dark:hover { background: var(--navy-deep); }
.button-outline { color: var(--navy); background: transparent; border-color: #cbd5e1; }
.button-outline:hover { background: var(--surface); }
.button-light { color: var(--navy); background: #fff; }
.button-light:hover { background: var(--teal-pale); }
.button-ghost-light { color: #fff; background: rgba(255, 255, 255, 0.08); border-color: rgba(255, 255, 255, 0.35); }
.button-ghost-light:hover { background: rgba(255, 255, 255, 0.14); }
.button-large { min-height: 58px; padding-inline: 26px; font-size: 15px; }

/* ---------- Hero (светлый, как на визитке) ---------- */
.hero {
  position: relative; min-height: 600px; display: flex; align-items: center; overflow: hidden; color: var(--ink);
  background:
    radial-gradient(circle at 85% 20%, rgba(37, 99, 235, 0.10) 0%, transparent 38%),
    linear-gradient(180deg, #ffffff 0%, var(--surface) 100%);
  border-bottom: 1px solid var(--line);
}
.hero::before {
  content: ""; position: absolute; inset: 0; opacity: 0.25;
  background-image:
    linear-gradient(rgba(17, 24, 39, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(17, 24, 39, 0.045) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: linear-gradient(to bottom, #000, transparent 90%);
  pointer-events: none;
}
.hero-grid {
  position: relative; z-index: 2; display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(360px, 0.72fr);
  gap: 72px; align-items: center; padding-block: 84px;
}
.hero-copy h1 { max-width: 760px; margin-bottom: 20px; font-size: clamp(2.2rem, 4.2vw, 3.6rem); line-height: 1.1; }
/* Главная: h1 — короткое «что это» (для поиска и ИИ), слоган с визитки — крупно под ним */
.hero-copy h1.hero-kicker { max-width: none; margin-bottom: 18px; font-size: 14px; font-weight: 700; line-height: 1.45; letter-spacing: 0.02em; }
.hero-slogan { max-width: 760px; margin: 0 0 20px; font-size: clamp(2.2rem, 4.2vw, 3.6rem); font-weight: 700; line-height: 1.1; letter-spacing: -0.025em; color: var(--ink); }
.hero-lead { max-width: 640px; margin-bottom: 18px; font-size: 1.15rem; color: var(--ink-soft); }
.hero-note {
  max-width: 640px; margin: 0 0 30px; padding: 14px 18px; font-size: 0.92rem; color: var(--ink-soft);
  border-left: 3px solid var(--teal); background: var(--blue-pale); border-radius: 0 10px 10px 0;
}
.hero-note strong { color: var(--ink); }
.hero .eyebrow-light { color: var(--teal); }
.hero.compact { min-height: 0; }
.hero.compact .hero-grid { grid-template-columns: 1fr; padding-block: 64px; }
.hero.compact h1 { font-size: clamp(2.1rem, 4vw, 3.4rem); }

/* Платформы и интеграции под заголовком */
.platforms { list-style: none; display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 0 0 14px; padding: 0; }
.platforms li {
  padding: 8px 18px; font-size: 14px; font-weight: 700; color: var(--teal);
  background: var(--teal-pale); border-radius: 999px;
}
.hero-sub { margin: 16px 0 0; font-size: 0.9rem; color: var(--ink-soft); }
.integrations { margin: 0 0 30px; }
.integrations p { margin: 0 0 10px; font-size: 0.9rem; color: var(--ink-soft); }

/* Логотипы учётных систем: исходные цвета, одинаковая высота плашек */
.integration-logos { list-style: none; display: flex; flex-wrap: wrap; gap: 10px; margin: 16px 0 0; padding: 0; }
.integration-logos li {
  height: 56px; padding: 0 20px; display: flex; align-items: center;
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
}
.integration-logos img { display: block; width: auto; height: 26px; }
/* у Хэдлайна широкий горизонтальный знак — уменьшаем, чтобы логотипы выглядели равными */
.integration-logos img[alt="Хэдлайн"] { height: 21px; }
.integration-logos.small { margin: 0; gap: 8px; }
.integration-logos.small li { height: 44px; padding: 0 14px; border-radius: 10px; }
.integration-logos.small img { height: 20px; }
.integration-logos.small img[alt="Хэдлайн"] { height: 16px; }
.integrations-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 24px; margin-top: 24px; }
.integrations-row p { margin: 0; color: var(--ink-soft); }
.integrations-row .integration-logos { margin: 0; }

/* Иконки-пиктограммы в карточках (как на визитке) */
.icon svg { width: 24px; height: 24px; display: block; }
.card-head { display: flex; align-items: center; gap: 16px; margin-bottom: 14px; }
.card-head h3 { margin: 0; }
.card-head + p { font-size: 0.98rem; }

/* Путь заказа: 4 шага в одной светлой панели */
.flow {
  list-style: none; margin: 0; padding: 28px 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
}
.flow li { padding: 0 26px; border-right: 1px solid var(--line); }
.flow li:last-child { border-right: 0; }
.flow-num { display: block; margin-bottom: 12px; font-size: 14px; font-weight: 800; color: var(--teal); }
.flow h3 { margin: 0 0 8px; font-size: 1.1rem; }
.flow p { margin: 0; font-size: 0.95rem; color: var(--ink-soft); }

/* Блок «ИИ помогает. Менеджер решает.» */
.callout {
  padding: 36px 40px; background: var(--blue-pale); border: 1px solid #dbe7fe; border-radius: var(--radius);
}
.callout h2 { margin-bottom: 12px; font-size: clamp(1.4rem, 2.4vw, 1.9rem); }
.callout p { margin: 0; color: var(--ink-soft); max-width: 820px; }
.callout p + p { margin-top: 12px; }
.callout p strong { color: var(--ink); }


/* ---------- Sections ---------- */
.section { padding-block: 96px; }
.section.tight { padding-block: 72px; }
.section.surface { background: var(--surface); }
.section-head { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr); gap: 40px; align-items: end; margin-bottom: 48px; }
.section-head h2 { margin-bottom: 0; }
.section-head p { margin: 0; color: var(--ink-soft); }
.section-head.single { grid-template-columns: 1fr; }
.section-head.single p { max-width: 760px; margin-top: 16px; }

/* Definition block (для быстрых ответов поисковиков и ИИ) */
.definition {
  padding: 28px 32px; background: var(--blue-pale); border-left: 4px solid var(--teal); border-radius: 0 var(--radius) var(--radius) 0;
}
.definition p { margin: 0; font-size: 1.08rem; }
.definition p + p { margin-top: 12px; }

/* Stats */
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.stat { padding: 26px 24px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); }
.stat strong { display: block; margin-bottom: 6px; font-size: 2.2rem; line-height: 1; color: var(--navy); }
.stat span { font-size: 0.92rem; color: var(--ink-soft); }
.stats-note { margin: 18px 0 0; font-size: 0.82rem; color: var(--ink-soft); }

/* Cards grid */
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.cards.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.cards.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.card {
  position: relative; display: flex; flex-direction: column; padding: 28px;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-soft); }
.card h3 { margin: 18px 0 10px; }
.card p { margin: 0; color: var(--ink-soft); }
.card p + p { margin-top: 10px; }
.card .text-link { margin-top: auto; padding-top: 18px; }
.card.dark { color: #fff; background: var(--navy); border-color: var(--navy); }
.card.dark p { color: #cbd5e1; }
.card.dark .icon { color: #fff; background: rgba(255, 255, 255, 0.12); }
.card.dark .text-link { color: #fff; }
.card .num { position: absolute; top: 24px; right: 26px; font-size: 12px; font-weight: 800; color: #9ca3af; }
.icon {
  width: 44px; height: 44px; display: inline-flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 800; color: var(--teal); background: var(--teal-pale); border-radius: 12px;
}
a.card { text-decoration: none; color: inherit; }

/* Steps */
.steps { counter-reset: step; list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: #fff; }
.step { counter-increment: step; position: relative; padding: 32px 28px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.step:nth-child(3n) { border-right: 0; }
.step:nth-last-child(-n+3) { border-bottom: 0; }
.step::before { content: counter(step, decimal-leading-zero); position: absolute; top: 26px; right: 26px; font-size: 12px; font-weight: 800; color: #9ca3af; }
.step h3 { margin: 18px 0 10px; font-size: 1.1rem; }
.step p { margin: 0; color: var(--ink-soft); font-size: 0.95rem; }

/* Two-column feature */
.split { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 56px; align-items: center; }
.split h2 { margin-bottom: 18px; }
.split p { color: var(--ink-soft); }
.check-list { list-style: none; padding: 0; margin: 24px 0 0; display: grid; gap: 12px; }
.check-list li { position: relative; padding-left: 34px; }
.check-list li::before {
  content: "✓"; position: absolute; left: 0; top: 1px; width: 24px; height: 24px;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 800; color: var(--green); background: var(--green-pale); border-radius: 50%;
}
.check-list strong { color: var(--ink); }

/* Compare table */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
table { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
th, td { padding: 16px 20px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
th { font-size: 0.82rem; font-weight: 800; letter-spacing: 0.03em; text-transform: uppercase; color: var(--ink-soft); background: var(--surface); }
tr:last-child td { border-bottom: 0; }
td:first-child { font-weight: 700; }
td .ok { color: var(--green); font-weight: 800; }
td .no { color: #9ca3af; }

/* Pricing */
.plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.plan { display: flex; flex-direction: column; padding: 32px 28px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); }
.plan.featured { color: #fff; background: var(--navy); border-color: var(--navy); }
.plan .plan-name { font-size: 0.85rem; font-weight: 800; letter-spacing: 0.05em; text-transform: uppercase; color: var(--teal); }
.plan.featured .plan-name { color: #bfdbfe; }
.plan .price { margin: 16px 0 6px; font-size: 2.8rem; font-weight: 800; line-height: 1; letter-spacing: -0.03em; }
.plan .price small { font-size: 1rem; font-weight: 650; letter-spacing: 0; }
.plan .price-note { margin: 0 0 20px; font-size: 0.92rem; color: var(--ink-soft); }
.plan.featured .price-note { color: #cbd5e1; }
.plan ul { list-style: none; padding: 0; margin: 0 0 26px; display: grid; gap: 10px; font-size: 0.95rem; }
.plan li { position: relative; padding-left: 26px; }
.plan li::before { content: "•"; position: absolute; left: 6px; color: var(--teal); font-weight: 800; }
.plan.featured li::before { color: #93c5fd; }
.plan .button { margin-top: auto; }

/* FAQ */
.faq { display: grid; gap: 12px; }
.faq details { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.faq summary {
  position: relative; padding: 20px 56px 20px 24px; font-weight: 750; cursor: pointer; list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 22px; top: 50%; width: 28px; height: 28px; margin-top: -14px;
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--teal); background: var(--teal-pale); border-radius: 50%; font-weight: 800;
}
.faq details[open] summary::after { content: "–"; }
.faq .answer { padding: 0 24px 22px; color: var(--ink-soft); }
.faq .answer p { margin: 0; }
.faq .answer p + p { margin-top: 10px; }
.faq-group { margin-top: 56px; }
.faq + .faq-group { margin-top: 56px; }

/* CTA band */
.cta {
  position: relative; overflow: hidden; color: #fff; border-radius: var(--radius-lg); padding: 64px 56px;
  background: linear-gradient(115deg, #0f172a 0%, #1e3a8a 70%, #2563eb 100%);
}
.cta::after { content: ""; position: absolute; right: -120px; top: -160px; width: 420px; height: 420px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, 0.14); }
.cta-grid { position: relative; z-index: 2; display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.7fr); gap: 40px; align-items: center; }
.cta h2 { margin-bottom: 14px; }
.cta p { margin: 0; color: #dbe7fe; }
.cta .eyebrow-light { color: #93c5fd; }
.cta .button-row { justify-content: flex-end; }

/* Prose pages */
.prose h2 { margin-top: 56px; margin-bottom: 18px; font-size: clamp(1.6rem, 2.6vw, 2.2rem); }
.prose h2:first-child { margin-top: 0; }
.prose h3 { margin-top: 32px; margin-bottom: 10px; }
.prose p, .prose li { color: #4b4664; }
.prose ul, .prose ol { padding-left: 22px; }
.prose li + li { margin-top: 6px; }
.prose strong { color: var(--ink); }
.prose .definition { margin: 0 0 36px; }

/* Contacts */
.contact-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.contact-card { padding: 32px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); }
.contact-card h3 { margin-bottom: 12px; }
.contact-card .big { display: block; margin: 8px 0; font-size: 1.5rem; font-weight: 800; color: var(--navy); text-decoration: none; letter-spacing: -0.02em; }
.contact-card .big:hover { color: var(--teal); }
.contact-card p { margin: 0; color: var(--ink-soft); }
.contact-card p + p { margin-top: 10px; }
.contact-card dl { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 6px 16px; font-size: 0.95rem; }
.contact-card dt { color: var(--ink-soft); }
.contact-card dd { margin: 0; font-weight: 650; }

/* Status */
.status-box { display: flex; align-items: center; gap: 16px; padding: 24px 28px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); }
.status-box .status-dot { width: 14px; height: 14px; border-radius: 50%; background: #10b981; box-shadow: 0 0 0 6px rgba(16, 185, 129, 0.12); }
.status-box .status-dot.is-down { background: #c74e43; box-shadow: 0 0 0 6px rgba(199, 78, 67, 0.12); }
.status-box strong { display: block; font-size: 1.15rem; }
.status-box span { color: var(--ink-soft); font-size: 0.92rem; }
.status-prose { margin-top: 40px; }

/* 404 */
.error-page { text-align: center; padding-block: 120px; }
.error-page .code { font-size: 6rem; font-weight: 800; line-height: 1; color: var(--teal-pale); letter-spacing: -0.04em; }
.error-page h1 { margin: -20px 0 16px; font-size: clamp(1.8rem, 3vw, 2.6rem); }

/* ---------- Footer ---------- */
.site-footer { color: #cbd5e1; background: var(--navy-deep); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 40px; padding-block: 72px 48px; }
.footer-brand p { margin: 20px 0 0; max-width: 320px; font-size: 0.92rem; color: #94a3b8; }
.footer-col h2 { margin-bottom: 16px; font-size: 0.82rem; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: #fff; }
.footer-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.footer-col a { font-size: 0.92rem; color: #cbd5e1; text-decoration: none; }
.footer-col a:hover { color: #fff; text-decoration: underline; }
.footer-col p { margin: 0 0 12px; font-size: 0.92rem; }
.footer-legal { color: #94a3b8; }
.footer-bottom {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 24px;
  padding-block: 22px 32px; border-top: 1px solid rgba(255, 255, 255, 0.1); font-size: 0.8rem; color: #64748b;
}
.footer-bottom a { color: #94a3b8; }

/* ---------- Смартфоны с записями экрана (Android и iPhone) ---------- */
.devices { display: flex; flex-wrap: wrap; justify-content: center; align-items: flex-start; gap: 48px 88px; }
.device-card { margin: 0; width: 280px; text-align: center; }
.device-card figcaption { margin-top: 24px; }
.device-card h3 { margin: 0 0 8px; font-size: 1.15rem; }
.device-card p { margin: 0; font-size: 0.95rem; color: var(--ink-soft); }

/* Все размеры рамки — в cqw от ширины карточки, чтобы островок, время и значки
   не наезжали друг на друга при любой ширине телефона */
.device-card { container-type: inline-size; }
.device { position: relative; padding: 3.6cqw; background: #111827; box-shadow: var(--shadow), inset 0 0 0 2px #374151; }
.device::before, .device::after { content: ""; position: absolute; width: 3px; background: #374151; border-radius: 2px; }
.device-screen { position: relative; overflow: hidden; background: #242e3c; }
.device-screen img, .device-screen video { display: block; width: 100%; height: auto; }
/* Строка состояния в цвет верха записи: светлый VK, чёрный мини-апп, тёмный Telegram */
.device-screen-light, .device-status-light { background: #fff; color: #111827; }
.device-screen-black, .device-status-black { background: #000; color: #fff; }
.device-screen-dark, .device-status-dark { background: #242e3c; color: #fff; }
.device-screen-light .device-home { background: rgba(17, 24, 39, 0.75); }
.device-status {
  position: relative; display: flex; align-items: center; justify-content: space-between;
  height: 10.7cqw; padding: 0 6.4cqw; font-size: 4.3cqw; font-weight: 700; line-height: 1;
  color: #fff; background: #242e3c; /* цвет шапки Telegram в тёмной теме */
}
.device-icons { width: 16.4cqw; height: 3.9cqw; fill: currentColor; }

/* Android: тонкая рамка, камера-«капля», кнопки справа */
.device-android { border-radius: 12cqw; }
.device-android .device-screen { border-radius: 9cqw; }
.device-android::before { right: -3px; top: 39cqw; height: 20cqw; }
.device-android::after { right: -3px; top: 68cqw; height: 12cqw; }
.device-camera { position: absolute; left: 50%; top: 3.2cqw; width: 4.3cqw; height: 4.3cqw; transform: translateX(-50%); background: #05070b; border-radius: 50%; }

/* iPhone: скруглённый корпус, Dynamic Island, полоска «домой», кнопки слева */
.device-iphone { padding: 3.9cqw; border-radius: 16.4cqw; }
.device-iphone .device-screen { border-radius: 12.9cqw; }
.device-iphone .device-status { height: 14.3cqw; padding: 0 8.6cqw 0 10.7cqw; font-size: 4.6cqw; }
.device-iphone::before { left: -3px; top: 43cqw; height: 16.4cqw; }
.device-iphone::after { left: -3px; top: 63cqw; height: 16.4cqw; }
.device-island { position: absolute; left: 50%; top: 3.2cqw; width: 29cqw; height: 8.6cqw; transform: translateX(-50%); background: #05070b; border-radius: 5cqw; }
.device-home { position: absolute; left: 50%; bottom: 2.5cqw; width: 34cqw; height: 1.4cqw; transform: translateX(-50%); background: rgba(255, 255, 255, 0.8); border-radius: 2px; }

/* Смартфоны в шапке страницы: два со сдвигом или один */
.hero-devices { display: flex; justify-content: center; align-items: flex-start; gap: 28px; }
.hero-devices .device-card { width: min(260px, 47%); }
.hero-devices .device-card:nth-child(2) { margin-top: 56px; }
.hero-devices .device-card figcaption { margin-top: 18px; }
.hero-devices .device-card h3 { font-size: 1rem; }
.hero-devices .device-card p { font-size: 0.88rem; }
.hero-devices.single .device-card { width: min(280px, 100%); }

.more-link { margin: 24px 0 0; }

/* Доп. услуга под тарифами */
.addon {
  display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-top: 18px;
  padding: 26px 28px; background: var(--blue-pale); border: 1px solid #dbe7fe; border-radius: var(--radius);
}
.addon .plan-name { font-size: 0.85rem; font-weight: 800; letter-spacing: 0.05em; text-transform: uppercase; color: var(--teal); }
.addon h3 { margin: 8px 0 6px; }
.addon p { margin: 0; color: var(--ink-soft); }
.addon-price { flex: 0 0 auto; font-size: 2.2rem; font-weight: 800; line-height: 1; letter-spacing: -0.03em; white-space: nowrap; text-align: right; }
.addon-price small { display: block; margin-top: 6px; font-size: 0.85rem; font-weight: 650; letter-spacing: 0; color: var(--ink-soft); }

/* ---------- Панель менеджера: слайд-шоу экранов в рамке ноутбука ---------- */
.panel-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-bottom: 28px; }
.panel-tabs button {
  display: grid; gap: 4px; padding: 16px 18px; text-align: left; cursor: pointer;
  font: inherit; color: var(--ink); background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  transition: border-color 0.2s ease, background 0.2s ease;
}
.panel-tabs button:hover { border-color: #bfdbfe; }
.panel-tabs button.is-active { background: var(--blue-pale); border-color: var(--teal); }
.panel-tab-num { font-size: 13px; font-weight: 800; color: var(--teal); }
.panel-tabs strong { font-size: 1.05rem; }
.panel-tab-text { font-size: 0.88rem; color: var(--ink-soft); }
.panel-note { margin: 14px 0 0; text-align: center; font-size: 0.82rem; color: var(--ink-soft); }

.laptop { max-width: 980px; margin-inline: auto; }
.laptop-lid { padding: 1.4% 1.4% 2%; background: #111827; border-radius: 18px 18px 4px 4px; box-shadow: var(--shadow); }
.laptop-display { container-type: inline-size; aspect-ratio: 16 / 10; overflow: hidden; background: #fff; border-radius: 6px; }
.laptop-base {
  position: relative; width: 112%; height: 14px; margin-left: -6%;
  background: #d1d5db; border-radius: 0 0 16px 16px; box-shadow: inset 0 3px 0 #e5e7eb;
}
.laptop-base::before { content: ""; position: absolute; left: 50%; top: 0; width: 16%; height: 6px; transform: translateX(-50%); background: #9ca3af; border-radius: 0 0 8px 8px; }

/* Всё внутри в em: размер шрифта привязан к ширине экрана ноутбука, интерфейс масштабируется как картинка */
.pd-app { display: grid; grid-template-columns: 10.5em minmax(0, 1fr); height: 100%; font-size: 1.42cqw; line-height: 1.35; color: #111827; }
.pd-side { padding: 1.2em 0.8em; border-right: 1px solid #eef0f3; }
.pd-logo { display: flex; align-items: center; gap: 0.4em; margin-bottom: 1.6em; font-size: 1.15em; font-weight: 800; }
.pd-logo span { display: inline-grid; place-items: center; width: 1.5em; height: 1.5em; color: #fff; background: #111827; border-radius: 0.35em; font-size: 0.9em; }
.pd-side-label { margin: 0 0 0.6em 0.5em; font-size: 0.72em; letter-spacing: 0.06em; text-transform: uppercase; color: #9ca3af; }
.pd-nav { display: flex; align-items: center; gap: 0.55em; padding: 0.55em 0.6em; margin-bottom: 0.15em; border-radius: 0.5em; color: #374151; transition: background 0.3s ease, color 0.3s ease; }
.pd-nav::before { content: ""; flex: 0 0 auto; width: 0.8em; height: 0.8em; border: 1.5px solid currentColor; border-radius: 0.2em; opacity: 0.7; }
.pd-app[data-active="0"] .pd-nav-0, .pd-app[data-active="1"] .pd-nav-1, .pd-app[data-active="2"] .pd-nav-2 { color: #fff; background: #111827; }

.pd-main { position: relative; min-width: 0; }
.pd-screen { position: absolute; inset: 0; padding: 1.4em 1.8em; opacity: 0; visibility: hidden; transform: translateY(0.6em); transition: opacity 0.45s ease, transform 0.45s ease, visibility 0s linear 0.45s; }
.pd-screen.is-active { opacity: 1; visibility: visible; transform: none; transition: opacity 0.45s ease, transform 0.45s ease, visibility 0s; }

.pd-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 1em; margin-bottom: 1.1em; }
.pd-title { font-size: 1.7em; font-weight: 800; letter-spacing: -0.02em; line-height: 1.1; }
.pd-sub { margin-top: 0.3em; font-size: 0.82em; color: #6b7280; }
.pd-pill { flex: 0 0 auto; padding: 0.45em 0.9em; font-size: 0.85em; font-weight: 650; border: 1px solid #e5e7eb; border-radius: 0.5em; }
.pd-pill-accent { color: #fff; background: #2563eb; border-color: #2563eb; }

.pd-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0.7em; margin-bottom: 1em; }
.pd-kpi { display: grid; gap: 0.15em; padding: 0.8em 0.9em; border: 1px solid #eef0f3; border-radius: 0.7em; }
.pd-kpi span { font-size: 0.75em; font-weight: 650; color: #6b7280; }
.pd-kpi b { font-size: 1.5em; line-height: 1.15; }
.pd-kpi i { font-style: normal; font-size: 0.7em; color: #9ca3af; }
.pd-chips { display: flex; gap: 0.5em; margin-bottom: 0.9em; }
.pd-chips span { padding: 0.35em 0.8em; font-size: 0.8em; font-weight: 650; border: 1px solid #e5e7eb; border-radius: 99em; }
.pd-chips span.on { color: #1d4ed8; background: #eff6ff; border-color: #bfdbfe; }

.pd-table { border: 1px solid #eef0f3; border-radius: 0.8em; overflow: hidden; }
.pd-venue { display: flex; align-items: baseline; gap: 0.8em; padding: 0.75em 1em; border-bottom: 1px solid #eef0f3; }
.pd-venue span { font-size: 0.78em; color: #9ca3af; }
.pd-venue em { margin-left: auto; font-style: normal; font-weight: 800; }
.pd-tr { display: grid; grid-template-columns: 1.6fr 0.6fr 1.3fr 1fr 1fr; gap: 0.6em; align-items: center; padding: 0.6em 1em; border-bottom: 1px solid #f3f4f6; }
.pd-tr:last-child { border-bottom: 0; }
.pd-tr > span:first-child { display: grid; }
.pd-tr i { font-style: normal; font-size: 0.75em; color: #9ca3af; }
.pd-th { padding-block: 0.45em; font-size: 0.75em; font-weight: 700; color: #6b7280; background: #f9fafb; }
.pd-badge, .pd-btn { justify-self: start; padding: 0.25em 0.65em; font-size: 0.78em; font-weight: 650; text-decoration: none; border-radius: 0.45em; white-space: nowrap; }
.pd-badge { color: #6b7280; background: #f3f4f6; }
.pd-badge.pd-ok { color: #047857; background: #d1fae5; }
.pd-btn { color: #1d4ed8; border: 1px solid #dbeafe; }
.pd-btn.pd-done { color: #6b7280; background: #f9fafb; border-color: #e5e7eb; }
.pd-swap { display: grid; justify-items: start; }
.pd-swap > s { grid-area: 1 / 1; }
.pd-swap .pd-from { opacity: 0; }

.pd-chat { display: grid; grid-template-columns: minmax(0, 1fr) 13em; gap: 1.2em; }
.pd-thread { display: flex; flex-direction: column; gap: 0.55em; min-width: 0; }
.pd-thread-head { display: flex; align-items: baseline; gap: 0.6em; padding-bottom: 0.6em; margin-bottom: 0.2em; border-bottom: 1px solid #eef0f3; }
.pd-thread-head b { font-size: 1.15em; }
.pd-thread-head span { font-size: 0.8em; color: #9ca3af; }
.pd-msg { max-width: 72%; padding: 0.6em 0.85em; font-size: 0.88em; border-radius: 0.8em; }
.pd-bot { align-self: flex-start; background: #f3f4f6; border-bottom-left-radius: 0.25em; }
.pd-guest { align-self: flex-end; color: #fff; background: #2563eb; border-bottom-right-radius: 0.25em; }
.pd-sys { align-self: center; padding: 0.3em 0.8em; font-size: 0.75em; font-weight: 650; color: #047857; background: #d1fae5; border-radius: 99em; }
.pd-mgr { align-self: flex-start; background: #eff6ff; border: 1px solid #bfdbfe; border-bottom-left-radius: 0.25em; }
.pd-mgr span { display: block; margin-bottom: 0.15em; font-size: 0.78em; font-weight: 700; color: #1d4ed8; }
.pd-input { margin-top: auto; padding: 0.65em 0.9em; font-size: 0.85em; color: #9ca3af; border: 1px solid #e5e7eb; border-radius: 0.7em; }
.pd-history { padding-left: 1.2em; border-left: 1px solid #eef0f3; }
.pd-history-title { margin-bottom: 0.6em; font-weight: 800; }
.pd-hrow { display: flex; justify-content: space-between; padding: 0.55em 0; font-size: 0.88em; border-bottom: 1px solid #eef0f3; }
.pd-hrow b::after { content: " ✓"; color: #059669; }
.pd-history-btn { margin-top: 1em; padding: 0.55em 0.8em; font-size: 0.82em; font-weight: 650; text-align: center; border: 1px solid #e5e7eb; border-radius: 0.5em; }
.pd-history-link { margin-top: 0.7em; font-size: 0.82em; color: #2563eb; }

.pd-search { display: flex; align-items: center; gap: 0.5em; padding: 0.6em 0.9em; margin-bottom: 0.9em; border: 1px solid #bfdbfe; border-radius: 0.7em; }
.pd-search::before { content: ""; width: 0.75em; height: 0.75em; border: 1.5px solid #6b7280; border-radius: 50%; }
.pd-typed { display: inline-block; overflow: hidden; white-space: nowrap; border-right: 1.5px solid #2563eb; }
.pd-stop-list { display: grid; gap: 0.25em; }
.pd-srow { display: flex; align-items: center; justify-content: space-between; padding: 0.5em 0.9em; border-radius: 0.6em; }
.pd-srow:nth-child(odd) { background: #f5f6f8; }
.pd-srow em { font-style: normal; font-weight: 650; }
.pd-srow.pd-target { box-shadow: inset 0 0 0 1.5px #93c5fd; }
.pd-toggle { position: relative; width: 2.6em; height: 1.4em; background: #86d993; border-radius: 99em; }
.pd-toggle::after { content: ""; position: absolute; top: 0.18em; left: 1.38em; width: 1.04em; height: 1.04em; background: #fff; border-radius: 50%; }
.pd-toggle.pd-off, .pd-toggle.pd-flip { background: #ef4444; }
.pd-toggle.pd-off::after, .pd-toggle.pd-flip::after { left: 0.18em; }

/* Анимации запускаются, когда экран становится активным; без них виден итоговый кадр */
@keyframes pd-row-in { from { max-height: 0; padding-block: 0; opacity: 0; } to { max-height: 5em; opacity: 1; } }
@keyframes pd-fade-out { from { opacity: 1; } to { opacity: 0; } }
@keyframes pd-pop-in { from { opacity: 0; transform: scale(0.85); } to { opacity: 1; transform: none; } }
@keyframes pd-msg-in { from { opacity: 0; transform: translateY(0.6em); } to { opacity: 1; transform: none; } }
@keyframes pd-type { from { max-width: 0; } to { max-width: 6em; } }
@keyframes pd-target-in { from { box-shadow: inset 0 0 0 1.5px transparent; } to { box-shadow: inset 0 0 0 1.5px #93c5fd; } }
@keyframes pd-flip-bg { from { background: #86d993; } to { background: #ef4444; } }
@keyframes pd-flip-knob { from { left: 1.38em; } to { left: 0.18em; } }

.is-active .pd-row-new { overflow: hidden; animation: pd-row-in 0.6s ease 0.6s both; }
.is-active .pd-swap-1 .pd-from { animation: pd-fade-out 0.3s ease 2s both; }
.is-active .pd-swap-1 .pd-to { animation: pd-pop-in 0.35s ease 2.1s both; }
.is-active .pd-swap-2 .pd-from { animation: pd-fade-out 0.3s ease 3.4s both; }
.is-active .pd-swap-2 .pd-to { animation: pd-pop-in 0.35s ease 3.5s both; }
.is-active .pd-m1 { animation: pd-msg-in 0.4s ease 0.3s both; }
.is-active .pd-m2 { animation: pd-msg-in 0.4s ease 1s both; }
.is-active .pd-m3 { animation: pd-msg-in 0.4s ease 1.7s both; }
.is-active .pd-m4 { animation: pd-msg-in 0.4s ease 2.6s both; }
.is-active .pd-m5 { animation: pd-msg-in 0.4s ease 3.1s both; }
.is-active .pd-m6 { animation: pd-msg-in 0.4s ease 4.4s both; }
.is-active .pd-typed { animation: pd-type 1.1s steps(7) 0.6s both; }
.is-active .pd-target { animation: pd-target-in 0.3s ease 1.8s both; }
.is-active .pd-flip { animation: pd-flip-bg 0.3s ease 2.8s both; }
.is-active .pd-flip::after { animation: pd-flip-knob 0.3s ease 2.8s both; }

/* Узкий экран ноутбука (телефон): крупнее шрифт, без боковой панели и второстепенных колонок */
@container (max-width: 560px) {
  .pd-app { grid-template-columns: minmax(0, 1fr); font-size: 2.9cqw; }
  .pd-side, .pd-col-pay, .pd-history, .pd-chips span:nth-child(n+3) { display: none; }
  .pd-screen { padding: 1.1em 1.1em; }
  .pd-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pd-tr { grid-template-columns: 1.5fr 0.7fr 1fr 1fr; }
  .pd-chat { grid-template-columns: minmax(0, 1fr); }
  .pd-msg { max-width: 85%; }
}
@media (max-width: 600px) {
  .laptop-display { aspect-ratio: 3 / 4; }
  .panel-tabs { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; margin-bottom: 18px; }
  .panel-tabs button { padding: 10px 8px; text-align: center; }
  .panel-tab-text { display: none; }
  .panel-tabs strong { font-size: 0.85rem; }
  /* На телефоне вместо ноутбука — iPad: ровная рамка со всех сторон, скруглённые углы, камера сверху */
  .laptop { max-width: 420px; container-type: inline-size; }
  .laptop-lid { position: relative; padding: 5.5%; border-radius: 28px; box-shadow: var(--shadow), inset 0 0 0 2px #374151; }
  .laptop-lid::before { content: ""; position: absolute; top: 2.75cqw; left: 50%; width: 7px; height: 7px; transform: translate(-50%, -50%); background: #374151; border-radius: 50%; }
  .laptop-display { border-radius: 12px; }
  .laptop-base { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .pd-app *, .pd-app *::before, .pd-app *::after { animation: none !important; }
}
.panel-demo-wrap { margin-top: 48px; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .main-nav a { padding-inline: 8px; font-size: 12.5px; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cards, .cards.four, .plans { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .flow { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 28px; }
  .flow li:nth-child(2n) { border-right: 0; }
  .step:nth-child(3n) { border-right: 1px solid var(--line); }
  .step:nth-child(2n) { border-right: 0; }
  .step:nth-last-child(-n+3) { border-bottom: 1px solid var(--line); }
  .step:nth-last-child(-n+2) { border-bottom: 0; }
}

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; gap: 48px; padding-block: 64px; }
  .section { padding-block: 72px; }
  .section-head, .split, .cta-grid, .contact-grid { grid-template-columns: 1fr; gap: 28px; }
  .cta { padding: 48px 32px; }
  .cta .button-row { justify-content: flex-start; }
  .footer-grid { grid-template-columns: 1fr 1fr; }

  .header-cta { display: none; }
  .menu-button { display: block; margin-left: auto; }
  /* backdrop-filter у .site-header делает его containing block для fixed-потомков,
     поэтому позиционируем меню от низа шапки и задаём высоту явно */
  .main-nav {
    position: fixed; top: 100%; left: 0; right: 0; height: calc(100vh - 72px); height: calc(100dvh - 72px);
    z-index: 90; flex-direction: column; justify-content: flex-start; overflow-y: auto;
    gap: 6px; padding: 24px 20px; background: #fff;
    transform: translateX(100%); transition: transform 0.25s ease;
  }
  .main-nav.is-open { transform: translateX(0); }
  .main-nav a { width: 100%; padding: 14px 16px; font-size: 16px; }
}

@media (max-width: 600px) {
  .stats, .cards, .cards.two, .cards.four, .plans, .steps, .flow { grid-template-columns: 1fr; }
  .flow { padding: 8px 0; row-gap: 0; }
  .flow li { padding: 20px 22px; border-right: 0; border-bottom: 1px solid var(--line); }
  .flow li:last-child { border-bottom: 0; }
  .callout { padding: 28px 22px; }
  .hero-devices { gap: 14px; }
  .hero-devices .device-card:nth-child(2) { margin-top: 36px; }
  .hero-devices .device-card p { display: none; }
  .addon { flex-direction: column; align-items: flex-start; padding: 22px 20px; }
  .step { border-right: 0 !important; border-bottom: 1px solid var(--line) !important; }
  .step:last-child { border-bottom: 0 !important; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .definition { padding: 22px 20px; }
  .cta { padding: 40px 24px; border-radius: var(--radius); }
  .table-wrap { border-radius: var(--radius-sm); }
  th, td { padding: 12px 14px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}
