:root {
  --bg: #E9EEF3;
  --bg-muted: #DEE6EE;
  --card: #FFFFFF;
  --ink: #16233D;
  --ink-soft: #5B6B80;
  --line: #D3DCE5;
  --accent: #2E7BC4;
  --accent-dark: #1F5E9C;
  --accent-tint: #D9E9F7;
  --green: #2E9E5B;
  --radius-card: 16px;
  --radius-sm: 10px;
  --sans: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation: none !important; transition: none !important; }
}
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--sans); font-size: 17px; line-height: 1.6; -webkit-font-smoothing: antialiased; }
h1, h2, h3 { font-family: var(--sans); font-weight: 800; line-height: 1.18; margin: 0 0 0.5em; color: var(--ink); }
h1 { font-size: clamp(2.1rem, 5vw, 3rem); }
h2 { font-size: clamp(1.5rem, 3.4vw, 2rem); }
h3 { font-size: 1.25rem; margin-bottom: 0.4em; font-weight: 700; }
p { margin: 0 0 1em; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
ul, ol { padding-left: 0; margin: 0; list-style: none; }
:focus-visible { outline: 2px solid var(--accent-dark); outline-offset: 2px; }
.badge { display: inline-flex; align-items: center; gap: 10px; background: var(--accent-tint); color: var(--accent-dark); font-size: 1rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.03em; padding: 14px 26px; border-radius: var(--radius-sm); margin-bottom: 20px; }
.badge-icon { font-size: 1.2rem; line-height: 1; text-transform: none; }
.badge-muted { background: transparent; color: var(--ink-soft); padding-left: 0; padding-top: 0; padding-bottom: 0; margin-top: 28px; font-size: 0.85rem; font-weight: 600; text-transform: none; letter-spacing: normal; }
.topic-tags { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.topic-tags li { background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 11px 20px; font-size: 0.98rem; color: var(--ink); }
.btn { display: inline-block; padding: 0.85em 1.6em; border-radius: var(--radius-sm); font-weight: 700; font-size: 0.95rem; text-decoration: none; border: 1px solid transparent; line-height: 1.2; cursor: pointer; transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, transform 0.1s ease; }
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }
/* свой, более мягкий фокус для кнопок — иначе глобальное кольцо :focus-visible
   (строка выше) накладывается на собственную рамку .btn-outline и даёт
   "двойной контур", который на мобильном остаётся виден и после обычного тапа */
.btn:focus-visible { outline: none; box-shadow: 0 0 0 3px var(--accent-tint); }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-dark); }
.btn-ghost { background: var(--card); color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--accent); }
.btn-outline { background: transparent; color: var(--accent); border-color: var(--accent); }
.btn-outline:hover { background: var(--accent); color: #fff; }
.btn-full { display: block; text-align: center; width: 100%; margin-top: 0.5em; }
.btn-large { font-size: 1.1rem; padding: 1em 2.2em; }
.btn-small { padding: 0.55em 1.1em; font-size: 0.85rem; }
.topbar { position: sticky; top: 0; z-index: 50; background: rgba(233, 238, 243, 0.9); backdrop-filter: blur(6px); border-bottom: 1px solid var(--line); }
.topbar-inner { max-width: 1120px; margin: 0 auto; padding: 14px 24px; display: flex; align-items: center; gap: 24px; }
.brand { font-weight: 800; color: var(--ink); font-size: 1.05rem; margin-right: auto; }
.brand:hover { text-decoration: none; }
.topnav { display: flex; gap: 20px; }
.topnav a { color: var(--ink-soft); font-size: 0.92rem; font-weight: 600; }
.topnav a:hover { color: var(--ink); text-decoration: none; }
.topnav a.is-active { color: var(--accent-dark); }
.page-hero { padding: 56px 0 40px; max-width: 640px; }
.page-hero h1 { margin-bottom: 0.4em; }
.page-hero .lead-small { margin-bottom: 20px; }
.nav-toggle { display: none; flex-direction: column; justify-content: center; gap: 4px; width: 32px; height: 32px; background: none; border: none; cursor: pointer; padding: 0; }
.nav-toggle span { display: block; height: 2px; background: var(--ink); border-radius: 1px; }
.page { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.hero { padding: 64px 0 40px; display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 40px; align-items: start; }
.hero-content { min-width: 0; }
.hero-photo { aspect-ratio: 4 / 5; }
.hero-photo-img { width: 100%; height: 100%; object-fit: cover; display: block; }
.role { font-size: 1.3rem; color: var(--accent); font-weight: 700; margin-bottom: 38px; }
.lead { font-size: 1.18rem; color: var(--ink-soft); max-width: 60ch; margin-bottom: 41px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 87px; }
.hero-stats { display: flex; flex-wrap: wrap; gap: 28px; margin-top: 40px; padding-top: 28px; border-top: 1px solid var(--line); }
.hero-stat { display: flex; flex-direction: column; }
.hero-stat strong { font-size: 1.3rem; font-weight: 800; color: var(--ink); }
.hero-stat span { font-size: 0.85rem; color: var(--ink-soft); }
.hub { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-bottom: 56px; }
.hub-card { display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-card); padding: 22px; color: inherit; transition: transform 0.15s ease, box-shadow 0.15s ease; }
.hub-card:hover { text-decoration: none; transform: translateY(-3px); box-shadow: 0 8px 24px rgba(22, 35, 61, 0.08); }
.hub-icon { font-size: 2.2rem; margin-bottom: 14px; }
.hub-card h3 { margin-bottom: 6px; }
.hub-card p { font-size: 0.92rem; color: var(--ink-soft); margin-bottom: 14px; flex-grow: 1; }
.hub-link { font-size: 0.85rem; font-weight: 700; color: var(--accent); }
.section { padding: 48px 0; border-top: 1px solid var(--line); }
.section-muted { background: var(--bg-muted); margin: 0 -24px; padding-left: 24px; padding-right: 24px; border-radius: var(--radius-card); border-top: none; }
.lead-small { color: var(--ink-soft); max-width: 60ch; }
.format-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin-top: 28px; }
.format-card { border: 1px solid var(--line); border-radius: var(--radius-card); padding: 26px; background: var(--card); display: flex; flex-direction: column; }
.price-list { margin: 20px 0; border-top: 1px solid var(--line); padding-top: 16px; }
.price-row { display: flex; justify-content: space-between; gap: 12px; font-size: 0.95rem; padding: 4px 0; }
.price-row dt { color: var(--ink-soft); }
.price-row dd { margin: 0; font-weight: 800; }
.problem-list { display: flex; flex-direction: column; gap: 14px; margin-top: 20px; max-width: 700px; }
.problem-list li { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-card); padding: 18px 22px; }
.problem-list li p { color: var(--ink-soft); margin: 0; }
.check-list { display: flex; flex-direction: column; gap: 14px; margin: 24px 0; max-width: 700px; }
.check-list li { position: relative; padding-left: 30px; color: var(--ink-soft); }
.check-list li::before { content: "✓"; position: absolute; left: 0; top: -1px; width: 20px; height: 20px; background: var(--green); color: #fff; border-radius: 50%; font-size: 0.7rem; font-weight: 800; display: flex; align-items: center; justify-content: center; }
.timeline { margin-top: 28px; border-left: 2px solid var(--line); max-width: 700px; }
.timeline li { position: relative; padding: 0 0 26px 26px; }
.timeline li::before { content: ""; position: absolute; left: -6px; top: 4px; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); }
.timeline-date { display: block; font-weight: 800; color: var(--ink); margin-bottom: 4px; }
.timeline li p { color: var(--ink-soft); margin: 0; }
.process-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px; margin-top: 28px; }
.steps { counter-reset: step; display: flex; flex-direction: column; gap: 16px; }
.steps li { counter-increment: step; position: relative; padding-left: 34px; color: var(--ink-soft); }
.steps li::before { content: counter(step); position: absolute; left: 0; top: 0; width: 22px; height: 22px; border-radius: 50%; background: var(--accent); color: #fff; font-weight: 800; font-size: 0.8rem; display: flex; align-items: center; justify-content: center; }
.note-box { margin-top: 24px; padding: 18px 20px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-card); }
.note-box p { margin-bottom: 8px; }
.note-box ul { display: flex; flex-direction: column; gap: 6px; }
.note-box li { color: var(--ink-soft); font-size: 0.92rem; }
.note-box li::before { content: "— "; }
.principles-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin-top: 28px; }
.principle-card { border: 1px solid var(--line); border-radius: var(--radius-card); padding: 22px; background: var(--card); }
.principle-card p { color: var(--ink-soft); margin: 0; font-size: 0.92rem; }
.doc-grid { display: flex; gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch; padding-bottom: 10px; margin-top: 26px; }
.doc-card { flex: 0 0 200px; scroll-snap-align: start; display: block; border: 1px solid var(--line); border-radius: var(--radius-card); padding: 16px; background: var(--card); color: inherit; transition: transform 0.15s ease, box-shadow 0.15s ease; }
a.doc-card:hover { text-decoration: none; transform: translateY(-2px); box-shadow: 0 8px 24px rgba(22, 35, 61, 0.08); }
.doc-thumb { display: block; width: 100%; aspect-ratio: 3 / 4; object-fit: cover; object-position: top; border-radius: 10px; margin-bottom: 12px; border: 1px solid var(--line); }
.doc-card h3 { font-size: 1rem; margin-bottom: 6px; }
.doc-card p { font-size: 0.85rem; color: var(--ink-soft); margin: 0; }
.doc-note { margin-top: 20px; font-size: 0.85rem; font-style: italic; }
.review-scroll { margin-top: 28px; overflow-x: auto; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch; padding-bottom: 10px; }
.review-track { display: flex; gap: 16px; }
.review-shot { height: 340px; width: auto; flex-shrink: 0; border-radius: var(--radius-card); border: 1px solid var(--line); scroll-snap-align: start; display: block; }
.review-more { margin-top: 22px; }
.cta-group { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin-top: 24px; }
.topbar-actions { display: flex; align-items: center; gap: 10px; }
.doc-grid, .review-scroll { scrollbar-width: none; -ms-overflow-style: none; }
.doc-grid::-webkit-scrollbar, .review-scroll::-webkit-scrollbar { display: none; }
.disclaimer { padding: 22px 24px; margin: 40px 0; max-width: 700px; background: #FCEFEA; border: 1px solid #F0CFC0; border-radius: var(--radius-card); font-size: 0.92rem; color: var(--ink-soft); }
.disclaimer p { margin: 0; }
.disclaimer strong { color: var(--ink); }
.final-cta { padding: 44px 0 64px; }
.footer { border-top: 1px solid var(--line); background: var(--bg-muted); }
.footer-inner { max-width: 1120px; margin: 0 auto; padding: 32px 24px; }
.footer-name { font-weight: 800; margin-bottom: 12px; }
.footer-contacts { display: flex; gap: 20px; flex-wrap: wrap; margin-bottom: 16px; font-size: 0.92rem; }
.footer-max { color: var(--ink-soft); }
.footer-legal { display: flex; flex-wrap: wrap; gap: 16px; margin-bottom: 12px; font-size: 0.85rem; }
.footer-legal a { color: var(--ink-soft); }
.footer-legal a:hover { color: var(--accent); }
.footer-copy { font-size: 0.85rem; color: var(--ink-soft); margin: 0; }
@media (max-width: 760px) {
  .hero { grid-template-columns: 1fr; text-align: center; gap: 24px; }
  .hero-photo { order: -1; max-width: 300px; aspect-ratio: 4 / 5; margin: 0 auto; }
  .hero .lead { margin-left: auto; margin-right: auto; }
  .hero-actions { justify-content: center; }
  .hero-stats { justify-content: center; }
  .hub { grid-template-columns: 1fr; }
  .format-grid, .principles-grid, .formats-layout { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .topnav { position: absolute; top: 100%; left: 0; right: 0; background: var(--bg); border-bottom: 1px solid var(--line); flex-direction: column; padding: 8px 24px 16px; display: none; gap: 4px; }
  .topnav.is-open { display: flex; }
  .nav-toggle { display: flex; }
  .btn-small { display: none; }
  .review-shot { height: 240px; }
}


/* карточка цены и шаги "как это происходит" — рядом, в два столбца */
.formats-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: start;
  margin-top: 28px;
}
#formats .format-grid {
  grid-template-columns: 1fr;
  margin-top: 0;
}
.process-heading {
  margin: 0 0 20px;
}

/* мобильный фикс: карточка цены и "как проходит обращение" — в один столбец,
   а не в узкую сетку 1fr 1fr (которая иначе перебивает общее mobile-правило выше) */
@media (max-width: 760px) {
  .formats-layout {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}

/* горизонтальная прокрутка карточек гайдов (как .doc-grid у документов) —
   одинаково на мобильном и десктопе, без узких "резиновых" колонок */
.guide-grid {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 10px;
  margin-top: 28px;
}
.guide-grid, .guide-grid::-webkit-scrollbar { scrollbar-width: none; -ms-overflow-style: none; }
.guide-grid::-webkit-scrollbar { display: none; }
.guide-card {
  flex: 0 0 260px;
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  background: var(--card);
  overflow: hidden;
}
.guide-cover {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-bottom: 1px solid var(--line);
}
.guide-card-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 18px;
}
.guide-card h3 {
  font-size: 1.05rem;
  margin: 0 0 8px;
}
.guide-card p {
  color: var(--ink-soft);
  font-size: 0.88rem;
  margin: 0 0 18px;
}
.guide-card .btn-full {
  margin: 0;
  margin-top: auto;
}

/* от планшета и шире — вертикальная сетка вместо горизонтальной прокрутки.
   Этот блок намеренно идёт последним в файле: на предыдущей версии такое же
   правило, добавленное раньше основного .guide-grid, перебивалось им из-за
   более позднего порядка в каскаде при равной специфичности. */
@media (min-width: 761px) {
  .guide-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    overflow-x: visible;
    scroll-snap-type: none;
    padding-bottom: 0;
  }
  .guide-card {
    flex: initial;
  }
}