/* ============================================================
   «Ориентир» — стили приложения
   Один файл без фреймворков. Порядок: токены → база → компоненты.
   ============================================================ */

:root {
  --ink: #0f172a;
  --ink-soft: #334155;
  --muted: #64748b;
  --line: #e2e8f0;
  --line-strong: #cbd5e1;
  --bg: #ffffff;
  --soft: #f8fafc;
  --soft-2: #f1f5f9;
  --brand: #4f46e5;
  --brand-dark: #4338ca;
  --brand-soft: #eef2ff;
  --accent: #0ea5e9;
  --ok: #12b76a;
  --ok-soft: #ecfdf3;
  --warn: #f79009;
  --warn-soft: #fffaeb;
  --danger: #d92d20;
  --danger-soft: #fef3f2;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06);
  --shadow: 0 10px 30px -12px rgba(15, 23, 42, 0.18);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.55;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

img { max-width: 100%; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 {
  margin: 0 0 0.5em;
  line-height: 1.2;
  letter-spacing: -0.02em;
  font-weight: 700;
}
h1 { font-size: clamp(1.9rem, 1.2rem + 2.4vw, 3rem); }
h2 { font-size: clamp(1.4rem, 1.1rem + 1.1vw, 1.95rem); }
h3 { font-size: 1.1rem; }

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9em;
  background: var(--soft-2);
  padding: 0.1em 0.35em;
  border-radius: 5px;
}

.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}
.container-wide { max-width: 1280px; }

.muted { color: var(--muted); }
.small { font-size: 0.86rem; }
.center { text-align: center; margin-top: 28px; }
.inline { display: inline; }

/* ---------- шапка ---------- */

.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.topbar-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  height: 66px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-weight: 700;
  letter-spacing: -0.02em;
}
.brand:hover { text-decoration: none; }
.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 11px;
  background: linear-gradient(140deg, #6366f1, #4f46e5 60%, #7c3aed);
  color: #fff;
  box-shadow: 0 6px 16px -6px rgba(79, 70, 229, 0.8);
}
.brand-name { font-size: 1.06rem; }

.nav { display: flex; gap: 4px; margin-left: 8px; }
.nav-link {
  padding: 8px 12px;
  border-radius: 9px;
  color: var(--ink-soft);
  font-size: 0.94rem;
  font-weight: 500;
}
.nav-link:hover { background: var(--soft-2); text-decoration: none; }
.nav-link.is-active { background: var(--brand-soft); color: var(--brand-dark); }

.nav-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 10px;
}
.nav-user {
  font-size: 0.88rem;
  color: var(--muted);
  max-width: 180px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.nav-toggle {
  display: none;
  margin-left: auto;
  width: 40px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
  padding: 8px 9px;
  flex-direction: column;
  justify-content: space-between;
}
.nav-toggle span { display: block; height: 2px; background: var(--ink); border-radius: 2px; }

/* ---------- кнопки ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 10px;
  border: 1px solid transparent;
  font: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.12s ease, background 0.15s ease, box-shadow 0.15s ease;
  white-space: nowrap;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

.btn-primary {
  background: linear-gradient(135deg, #6366f1, #4f46e5);
  color: #fff;
  box-shadow: 0 10px 22px -12px rgba(79, 70, 229, 0.9);
}
.btn-primary:hover { background: linear-gradient(135deg, #5457e5, #4338ca); }

.btn-ghost {
  background: #fff;
  border-color: var(--line-strong);
  color: var(--ink);
}
.btn-ghost:hover { background: var(--soft); }

.btn-danger { background: var(--danger-soft); color: var(--danger); border-color: #fecdca; }
.btn-danger:hover { background: #fee4e2; }

.btn-sm { padding: 6px 12px; font-size: 0.85rem; border-radius: 8px; }
.btn-lg { padding: 13px 24px; font-size: 1.02rem; border-radius: 12px; }
.btn-block { width: 100%; }

/* ---------- страница ---------- */

.page { padding-top: 36px; padding-bottom: 72px; flex: 1 0 auto; }
.page-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 26px;
  flex-wrap: wrap;
}
.page-head h1 { margin-bottom: 6px; }
.page-head-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }

.eyebrow {
  display: inline-block;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--brand);
  margin-bottom: 10px;
}

.pill {
  display: inline-block;
  padding: 5px 12px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand-dark);
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 18px;
}

.lead { font-size: 1.12rem; color: var(--ink-soft); }
.fineprint { font-size: 0.8rem; color: var(--muted); margin-top: 18px; }

/* ---------- лендинг ---------- */

.hero {
  padding: 36px 0 0;
  background:
    radial-gradient(900px 420px at 12% -10%, #eef2ff 0%, rgba(238, 242, 255, 0) 70%),
    radial-gradient(700px 380px at 92% 4%, #ecfeff 0%, rgba(236, 254, 255, 0) 70%);
  border-bottom: 1px solid var(--line);
}
.hero-inner {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 48px;
  align-items: center;
  padding-bottom: 48px;
}
.hero h1 { margin-bottom: 18px; }
.grad {
  background: linear-gradient(100deg, #4f46e5, #7c3aed 45%, #0ea5e9);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 24px; }

.hero-panel {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--shadow);
  padding: 20px;
}
.panel-head {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 0.92rem;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 14px;
}
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.dot-green { background: var(--ok); box-shadow: 0 0 0 3px var(--ok-soft); }
.panel-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.9rem;
  padding: 7px 0;
  color: var(--muted);
}
.panel-row strong { color: var(--ink); font-weight: 600; }
.panel-progress {
  height: 8px;
  border-radius: 999px;
  background: var(--soft-2);
  overflow: hidden;
  margin: 14px 0 6px;
}
.panel-progress span {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #6366f1, #0ea5e9);
}
.panel-note { font-size: 0.8rem; color: var(--muted); margin-bottom: 16px; }
.panel-msg {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px;
  font-size: 0.86rem;
}
.msg-avatar {
  flex: 0 0 auto;
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background: var(--brand-soft);
  color: var(--brand-dark);
  font-size: 0.66rem;
  font-weight: 700;
  display: grid;
  place-items: center;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--line);
  border-top: 1px solid var(--line);
}
.metrics > div {
  background: #fff;
  padding: 22px 24px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.metrics strong { font-size: 1.7rem; letter-spacing: -0.03em; }
.metrics span { font-size: 0.85rem; color: var(--muted); }

.section { padding: 64px 0; }
.section-muted { background: var(--soft); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section-head { max-width: 660px; margin: 0 auto 34px; text-align: center; }
.section-head-left { margin-left: 0; text-align: left; }

/* ---------- сетки и карточки ---------- */

.grid { display: grid; gap: 18px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow-sm);
}
.card-tight { padding: 18px; }
.card h3 { margin-bottom: 6px; }
.card-material { display: flex; flex-direction: column; gap: 4px; }
.card-material .card-foot { margin-top: auto; padding-top: 14px; }
.card-material.is-locked { background: var(--soft); }
.card-kicker {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
}
.card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}
.card-head h2 { margin: 0; font-size: 1.2rem; }
.card-flush { padding: 0; overflow: hidden; }

.num {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--brand);
  margin-bottom: 10px;
}

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  align-items: start;
}
.split-wide { grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr); }

.aside { display: flex; flex-direction: column; gap: 16px; }

.checklist { list-style: none; padding: 0; margin: 18px 0 0; display: grid; gap: 10px; }
.checklist li {
  position: relative;
  padding-left: 30px;
  color: var(--ink-soft);
}
.checklist li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 1px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--ok-soft);
  color: var(--ok);
  font-size: 0.75rem;
  font-weight: 700;
  display: grid;
  place-items: center;
}

.chat-demo { display: flex; flex-direction: column; gap: 10px; }
.chat-bubble {
  padding: 11px 14px;
  border-radius: 14px;
  font-size: 0.9rem;
  max-width: 92%;
  white-space: pre-line;
}
.chat-bubble p { margin: 0 0 6px; }
.chat-bubble p:last-child { margin-bottom: 0; }
.chat-user { background: var(--brand); color: #fff; align-self: flex-end; border-bottom-right-radius: 4px; }
.chat-user a { color: #fff; text-decoration: underline; }
.chat-ai { background: var(--soft-2); color: var(--ink); align-self: flex-start; border-bottom-left-radius: 4px; }

.cta { background: linear-gradient(120deg, #1e1b4b, #312e81 45%, #1e3a8a); color: #fff; padding: 46px 0; }
.cta-inner { display: flex; align-items: center; justify-content: space-between; gap: 28px; flex-wrap: wrap; }
.cta h2 { color: #fff; margin-bottom: 6px; }
.cta .muted { color: #c7d2fe; }
.cta-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.cta .btn-ghost { background: rgba(255, 255, 255, 0.1); border-color: rgba(255, 255, 255, 0.35); color: #fff; }
.cta .btn-ghost:hover { background: rgba(255, 255, 255, 0.18); }

/* ---------- формы ---------- */

.form { display: grid; gap: 14px; }
.form-inline { margin-top: 20px; }

.field { display: grid; gap: 6px; }
.field > span { font-size: 0.86rem; font-weight: 600; color: var(--ink-soft); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

input[type="text"],
input[type="email"],
input[type="password"],
input[type="url"],
input[type="file"],
textarea,
select {
  width: 100%;
  padding: 10px 13px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  font: inherit;
  font-size: 0.94rem;
  color: var(--ink);
  background: #fff;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-soft);
}
input:disabled { background: var(--soft); color: var(--muted); }
textarea { resize: vertical; min-height: 70px; }

.check { display: flex; gap: 10px; align-items: flex-start; font-size: 0.86rem; color: var(--ink-soft); }
.check input { margin-top: 3px; width: 16px; height: 16px; accent-color: var(--brand); flex: 0 0 auto; }

.auth { max-width: 440px; margin: 24px auto 0; }
.auth-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 30px;
  box-shadow: var(--shadow);
}
.auth-card h1 { font-size: 1.6rem; margin-bottom: 6px; }
.auth-footer { margin-top: 18px; text-align: center; font-size: 0.9rem; color: var(--muted); }

.demo-hint {
  margin-top: 18px;
  padding: 14px;
  border: 1px dashed var(--line-strong);
  border-radius: 12px;
  background: var(--soft);
  font-size: 0.83rem;
  color: var(--ink-soft);
  display: grid;
  gap: 4px;
}
.demo-hint-title { font-weight: 700; font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.07em; color: var(--muted); }

.alert { padding: 12px 16px; border-radius: 10px; font-size: 0.9rem; margin-bottom: 16px; }
.alert-ok { background: var(--ok-soft); color: #067647; border: 1px solid #abefc6; }
.alert-err { background: var(--danger-soft); color: #b42318; border: 1px solid #fecdca; }

/* ---------- статистика ---------- */

.stat-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 26px;
}
.stat {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.stat-label { font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); font-weight: 600; }
.stat strong { font-size: 1.35rem; letter-spacing: -0.02em; }
.stat-note { font-size: 0.8rem; color: var(--muted); }
.bar { height: 6px; background: var(--soft-2); border-radius: 999px; overflow: hidden; margin-top: 8px; }
.bar span { display: block; height: 100%; background: linear-gradient(90deg, #6366f1, #0ea5e9); }

.funnel { display: grid; gap: 10px; }
.funnel-row { display: grid; grid-template-columns: 150px 1fr 90px; align-items: center; gap: 12px; }
.funnel-label { font-size: 0.86rem; color: var(--ink-soft); }
.funnel-bar { height: 22px; background: var(--soft-2); border-radius: 6px; overflow: hidden; }
.funnel-fill { display: block; height: 100%; border-radius: 6px; }
.funnel-sent { background: #c7d2fe; }
.funnel-opened { background: #a5b4fc; }
.funnel-clicked { background: #818cf8; }
.funnel-registered { background: #6366f1; }
.funnel-purchased { background: #4338ca; }
.funnel-value { font-size: 0.86rem; font-weight: 600; text-align: right; }

/* ---------- таблицы ---------- */

.table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.table th {
  text-align: left;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
.table td { padding: 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table tr:last-child td { border-bottom: none; }
.table-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.table a { color: var(--ink); }

/* ---------- бейджи ---------- */

.badge {
  display: inline-block;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  white-space: nowrap;
}
.badge-default { background: var(--soft-2); color: var(--ink-soft); }
.badge-ok { background: var(--ok-soft); color: #067647; }
.badge-warn { background: var(--warn-soft); color: #b54708; }
.badge-lock { background: var(--brand-soft); color: var(--brand-dark); }

/* ---------- кабинет ---------- */

.next-step {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-top: 18px;
  padding: 20px 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(120deg, var(--brand-soft), #f5f3ff);
}
.next-step h3 { margin: 0 0 4px; }

.mini-chat { display: flex; flex-direction: column; gap: 8px; margin: 12px 0; }
.mini-chat .chat-bubble { font-size: 0.84rem; max-width: 100%; }

.link-list { list-style: none; padding: 0; margin: 10px 0 0; display: grid; gap: 8px; }
.link-list a { font-size: 0.9rem; }
.link-list details summary { cursor: pointer; font-size: 0.9rem; font-weight: 500; }
.link-list details p { margin: 8px 0 0; }

.upgrade {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 18px 22px;
  border-radius: var(--radius);
  background: #fffbeb;
  border: 1px solid #fde68a;
  margin-bottom: 22px;
  flex-wrap: wrap;
}

.download-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 16px 20px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--soft);
  margin: 24px 0;
  flex-wrap: wrap;
}

.reader { max-width: 760px; margin: 0 auto; }
.reader h1 { margin-bottom: 10px; }
.prose { margin-top: 28px; font-size: 1.02rem; color: var(--ink-soft); }
.prose h2 { margin-top: 34px; color: var(--ink); }
.prose h3 { margin-top: 26px; color: var(--ink); }
.prose p { margin-bottom: 1.1em; }
.prose ul, .prose ol { margin: 0 0 1.2em; padding-left: 1.3em; }
.prose li { margin-bottom: 0.45em; }
.reader-foot { display: flex; justify-content: space-between; gap: 12px; margin-top: 40px; padding-top: 22px; border-top: 1px solid var(--line); flex-wrap: wrap; }

.breadcrumb { font-size: 0.85rem; color: var(--muted); margin-bottom: 18px; display: flex; gap: 8px; }
.breadcrumb a { color: var(--muted); }

.paywall {
  max-width: 560px;
  margin: 40px auto;
  text-align: center;
  display: grid;
  gap: 16px;
  justify-items: center;
}
.paywall .btn { justify-self: center; }

.empty { max-width: 520px; margin: 60px auto; text-align: center; display: grid; gap: 14px; justify-items: center; }

/* ---------- поддержка ---------- */

.card-chat { display: flex; flex-direction: column; gap: 14px; }
.chat-log {
  display: flex;
  flex-direction: column;
  gap: 14px;
  max-height: 460px;
  overflow-y: auto;
  padding: 4px;
}
.chat-row { display: flex; flex-direction: column; gap: 4px; }
.chat-row-user { align-items: flex-end; }
.chat-row-ai { align-items: flex-start; }
.chat-time { font-size: 0.72rem; color: var(--muted); }
.chat-form { display: flex; gap: 10px; }
.chat-form input { flex: 1; }
.chat-actions { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }

.ticket-list { display: grid; gap: 8px; margin-top: 10px; }
.ticket-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--ink);
  font-size: 0.88rem;
}
.ticket-row:hover { background: var(--soft); text-decoration: none; }
.ticket-row div { display: grid; gap: 2px; }

.thread { display: grid; gap: 0; margin-bottom: 18px; }
.thread-item { padding: 16px 0; border-bottom: 1px solid var(--line); }
.thread-item:last-child { border-bottom: none; }
.thread-head { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 8px; font-size: 0.88rem; }
.thread-body { color: var(--ink-soft); font-size: 0.94rem; }

/* ---------- админка ---------- */

.subnav {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  padding: 6px;
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 12px;
  margin-bottom: 24px;
}
.subnav-link {
  padding: 7px 13px;
  border-radius: 8px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--ink-soft);
}
.subnav-link:hover { background: #fff; text-decoration: none; }
.subnav-link.is-active { background: #fff; color: var(--brand-dark); box-shadow: var(--shadow-sm); }

.mail-preview {
  font-size: 0.85rem;
  color: var(--ink-soft);
  white-space: pre-wrap;
  max-height: 240px;
  overflow-y: auto;
  background: var(--soft);
  border-radius: 8px;
  padding: 12px;
}
.mail-frame {
  width: 100%;
  height: 320px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
}
.mail-frame-full { height: 640px; border: none; border-radius: 0; }

/* ---------- подвал ---------- */

.footer { border-top: 1px solid var(--line); background: var(--soft); padding: 34px 0; }
.footer-inner { display: flex; justify-content: space-between; gap: 28px; flex-wrap: wrap; }
.footer-brand { font-weight: 700; margin-bottom: 6px; }
.footer p { max-width: 520px; font-size: 0.85rem; }
.footer-links { display: flex; gap: 18px; flex-wrap: wrap; font-size: 0.88rem; }

/* ---------- адаптив ---------- */

@media (max-width: 980px) {
  .hero-inner { grid-template-columns: 1fr; gap: 32px; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .split, .split-wide { grid-template-columns: 1fr; }
  .stat-row { grid-template-columns: repeat(2, 1fr); }
  .metrics { grid-template-columns: repeat(2, 1fr); }
  .funnel-row { grid-template-columns: 120px 1fr 76px; }
}

@media (max-width: 720px) {
  .container { padding: 0 18px; }
  .nav-toggle { display: flex; }
  .nav {
    display: none;
    position: absolute;
    top: 66px;
    left: 0;
    right: 0;
    background: #fff;
    border-bottom: 1px solid var(--line);
    flex-direction: column;
    padding: 10px 18px 16px;
    gap: 2px;
    box-shadow: var(--shadow);
  }
  .nav.is-open { display: flex; }
  .nav-actions { gap: 6px; }
  .nav-user { display: none; }
  .topbar-inner { gap: 12px; position: relative; }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .stat-row { grid-template-columns: 1fr 1fr; }
  .page { padding-top: 24px; padding-bottom: 56px; }
  .section { padding: 44px 0; }
  .cta-inner { flex-direction: column; align-items: flex-start; }
  .chat-form { flex-direction: column; }
  .chat-form .btn { width: 100%; }
  .funnel-row { grid-template-columns: 96px 1fr 64px; gap: 8px; }
  .funnel-label { font-size: 0.78rem; }
  .table { font-size: 0.82rem; }
  .table th, .table td { padding: 8px; }
}
