/* Посадочные /seo/* и /blog — оформление главной (токены, шапка, подвал).
   Источник токенов — :root в public/index.html; меняешь там — сверь здесь.
   Mobile first: база — телефон, шире — через min-width. */

:root {
  --tg: #229ED9;
  --tg-soft: #E1F2FB;
  --max: #7C3AED;
  --max-soft: #F3EEFE;
  --max-deep: #6E28DC;
  --gradient: linear-gradient(135deg, #229ED9 0%, #7C3AED 100%);
  --bg: #F8FAFC;
  --bg-alt: #F1F5F9;
  --card: #FFFFFF;
  --ink: #0F172A;
  --ink2: #1A1A2E;
  --text: #334155;
  --muted: #5E6D82;
  --line: #E2E8F0;
  --line-soft: #EEF2F7;
  --sh1: 0 1px 2px rgba(15,23,42,.04), 0 1px 1px rgba(15,23,42,.03);
  --sh2: 0 4px 12px -2px rgba(15,23,42,.06), 0 2px 4px -1px rgba(15,23,42,.04);
  --sh3: 0 24px 48px -16px rgba(15,23,42,.12), 0 8px 20px -8px rgba(15,23,42,.06);
  --sh-brand: 0 8px 24px -8px rgba(124,58,237,.4);
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  /* Имена из прежнего шаблона страниц — для блоков, оставшихся в самих страницах */
  --surface: var(--card);
  --border: var(--line);
  --accent: var(--max);
  --txt: var(--ink);
  --txt2: var(--text);
  --txt3: var(--muted);
  --r: 16px;
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg); color: var(--ink);
  font-family: var(--font); font-size: 16px; line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; }

/* === Кнопки (как на главной) === */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 14px 22px; border-radius: 12px; font-weight: 700; font-size: 15px;
  letter-spacing: -.01em; transition: all .15s ease; white-space: nowrap;
  border: 1.5px solid transparent; text-decoration: none; cursor: pointer; }
.btn-primary { background: var(--ink); color: #fff; box-shadow: var(--sh2); }
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 14px 28px -10px rgba(15,23,42,.4); }
.btn-brand { background: var(--gradient); color: #fff; box-shadow: var(--sh-brand); }
.btn-brand:hover { transform: translateY(-1px); filter: brightness(1.05); }
.btn-sm { padding: 8px 12px; font-size: 13px; gap: 6px; border-radius: 8px; }
.btn-icon { width: 14px; height: 14px; display: none; }

/* === Шапка === */
.topbar { position: sticky; top: 0; z-index: 50; backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  background: rgba(248,250,252,.85); border-bottom: 1px solid var(--line); }
.topbar-inner { display: flex; align-items: center; justify-content: space-between;
  gap: 10px; padding: 12px 16px; max-width: 1280px; margin: 0 auto; }
.topbar a { text-decoration: none; }
.topbar .logo { height: 24px; width: auto; }
.topbar-nav { display: none; }
.topbar-right { display: flex; align-items: center; gap: 10px; }
.topbar-right .login-link { font-size: 14px; color: var(--text); font-weight: 500; }
.topbar-right .login-link:hover, .topbar-nav a:hover { color: var(--max); }

/* === Статья === */
.container { max-width: 800px; margin: 0 auto; padding: 20px 16px 48px; }
.crumbs { color: var(--muted); font-size: 13px; margin: 4px 0 16px; }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--max); }

article { background: var(--card); border: 1px solid var(--line); border-radius: 20px;
  padding: 24px 20px; box-shadow: var(--sh2); color: var(--text); }
article h1 { font-size: 30px; line-height: 1.12; letter-spacing: -.03em; font-weight: 700;
  color: var(--ink); margin: 0 0 14px; }
article .lead { font-size: 17px; line-height: 1.55; color: var(--text); margin: 0 0 28px;
  padding-bottom: 24px; border-bottom: 1px solid var(--line); }
article h2 { font-size: 22px; line-height: 1.25; letter-spacing: -.02em; font-weight: 700;
  color: var(--ink); margin: 36px 0 12px; }
article h3 { font-size: 17px; font-weight: 700; color: var(--ink); margin: 22px 0 8px; }
article p { margin: 0 0 14px; }
article ul, article ol { padding-left: 22px; margin: 0 0 14px; }
article li { margin-bottom: 6px; }
article a { color: var(--max); text-decoration: underline; text-decoration-color: rgba(124,58,237,.35);
  text-underline-offset: 3px; }
article a:hover { text-decoration-color: var(--max); }
article code { font-family: var(--mono); font-size: .88em; background: var(--max-soft);
  color: var(--max-deep); padding: 1px 6px; border-radius: 6px; word-break: break-word; }
article strong { color: var(--ink); }

/* Шаги */
article .steps { counter-reset: step; list-style: none; padding-left: 0; }
article .steps li { counter-increment: step; position: relative;
  padding: 14px 16px 14px 54px; margin-bottom: 10px;
  background: var(--bg); border: 1px solid var(--line); border-radius: 12px; }
article .steps li::before { content: counter(step); position: absolute; left: 14px; top: 14px;
  width: 28px; height: 28px; border-radius: 50%; background: var(--gradient); color: #fff;
  display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 14px; }

/* Частые вопросы */
.faq details { background: var(--bg); border: 1px solid var(--line); border-radius: 12px;
  padding: 14px 16px; margin-bottom: 10px; transition: border-color .15s; }
.faq details[open] { border-color: rgba(124,58,237,.35); background: #fff; }
.faq summary { cursor: pointer; font-weight: 600; font-size: 16px; color: var(--ink);
  list-style: none; position: relative; padding-right: 28px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; position: absolute; right: 0; top: -2px;
  font-size: 22px; font-weight: 500; color: var(--max); line-height: 1; }
.faq details[open] summary::after { content: '−'; }
.faq details[open] summary { margin-bottom: 8px; }
.faq details p { margin: 0; }

/* Тарифы (перенос архива) */
.pricing-grid { display: grid; grid-template-columns: 1fr; gap: 12px; margin: 12px 0 18px; }
.pricing-card { background: var(--bg); border: 1px solid var(--line); border-radius: 12px; padding: 16px; }
.pricing-card h3 { margin: 0 0 6px; color: var(--max); font-size: 15px; }
.pricing-card .lim { font-size: 22px; font-weight: 700; color: var(--ink); margin: 0 0 4px; }
.pricing-card .desc { font-size: 13px; color: var(--muted); margin: 0; }

/* Призыв к регистрации — как финальный блок главной */
.cta { position: relative; overflow: hidden; text-align: center;
  background: var(--ink); color: #fff; border-radius: 20px;
  padding: 32px 20px; margin: 36px 0 0; }
.cta::before { content: ''; position: absolute; right: -120px; top: -140px;
  width: 320px; height: 320px; border-radius: 50%; background: var(--gradient);
  filter: blur(60px); opacity: .45; pointer-events: none; }
.cta > * { position: relative; }
article .cta h3 { color: #fff; font-size: 22px; letter-spacing: -.02em; margin: 0 0 8px; }
.cta p { color: rgba(255,255,255,.78); margin: 0 auto 20px; font-size: 15px; max-width: 460px; }
article .cta a { display: flex; align-items: center; justify-content: center; width: 100%;
  background: var(--gradient); color: #fff; padding: 14px 24px; border-radius: 12px;
  text-decoration: none; font-weight: 700; font-size: 15px; box-shadow: var(--sh-brand); }
article .cta a:hover { filter: brightness(1.06); }

/* Форма заявки на посадочной */
.lead-form { display: flex; flex-direction: column; gap: 6px; margin: 8px 0 8px;
  background: var(--bg); border: 1px solid var(--line); border-radius: 16px; padding: 18px 16px; }
.lead-label { font-size: 14px; font-weight: 600; color: var(--ink); margin-top: 8px; }
.lead-opt { font-weight: 400; color: var(--muted); }
.lead-input { width: 100%; font: inherit; font-size: 16px; color: var(--ink); background: #fff;
  border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; }
.lead-input:focus { outline: 2px solid var(--max); outline-offset: 1px; border-color: var(--max); }
textarea.lead-input { resize: vertical; }
.lead-trap { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.lead-btn { margin-top: 14px; width: 100%; border: 0; cursor: pointer; font: inherit; font-weight: 700; font-size: 15px;
  color: #fff; background: var(--gradient); padding: 14px 24px; border-radius: 12px; box-shadow: var(--sh-brand); }
.lead-btn:disabled { opacity: .6; cursor: default; }
.lead-msg { margin: 10px 0 0; font-size: 14px; }
.lead-msg.is-ok { color: #047857; }
.lead-msg.is-err { color: #B91C1C; }

/* === Подвал (как на главной) === */
footer { border-top: 1px solid var(--line); padding: 40px 20px 28px; background: var(--bg); }
footer a { text-decoration: none; }
.footer-inner { max-width: 1280px; margin: 0 auto; }
.footer-grid { display: grid; grid-template-columns: 1fr; gap: 28px; margin-bottom: 32px; }
.footer-brand .logo { height: 28px; width: auto; }
.footer-brand p { font-size: 13.5px; line-height: 1.6; color: var(--muted); margin: 14px 0 0; max-width: 300px; }
.footer-grid h5 { font-size: 12px; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; color: var(--muted); margin: 0 0 14px; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; }
.footer-grid ul a { font-size: 14px; color: var(--text); }
.footer-grid ul a:hover { color: var(--max); }
.footer-bot { border-top: 1px solid var(--line); padding-top: 20px; display: flex;
  flex-direction: column; gap: 8px; font-size: 12.5px; color: var(--muted); }

/* === Шире телефона === */
@media (min-width: 420px) {
  .btn-icon { display: block; }
  .topbar .logo { height: 28px; }
}
@media (min-width: 540px) {
  .lead-form { padding: 24px; }
  .lead-btn { width: auto; align-self: flex-start; }
  .pricing-grid { grid-template-columns: 1fr 1fr 1fr; }
  article .cta a { display: inline-flex; width: auto; }
}
@media (min-width: 720px) {
  .topbar-inner { padding: 16px 32px; }
  .topbar .logo { height: 32px; }
  .topbar-right { gap: 12px; }
  .topbar-right .login-link { font-size: 14.5px; }
  .btn-sm { padding: 8px 14px; }
  .container { padding: 32px 32px 64px; }
  article { padding: 44px 48px; border-radius: 24px; }
  article h1 { font-size: 40px; }
  article h2 { font-size: 26px; }
  .cta { padding: 44px 40px; border-radius: 24px; }
  article .cta h3 { font-size: 26px; }
  footer { padding: 48px 32px 32px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .footer-bot { flex-direction: row; justify-content: space-between; align-items: center; }
}
@media (min-width: 1100px) {
  .topbar-nav { display: flex; gap: 32px; font-size: 14.5px; font-weight: 500; }
  .topbar-nav a { color: var(--text); transition: color .15s; }
  .footer-grid { grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 48px; }
}
