/* ============================================================
   ARTICLE DESIGN SYSTEM — «Модели Москва»
   Светлая система в духе apple.com для внутренних страниц:
   воздух, крупная типографика, спокойные поверхности.
   Используется: soderzhanka / modeling / tuskovki / webcam
   ============================================================ */

:root {
  --bg: #ffffff;
  --bg-alt: #f5f5f7;          /* фирменный светло-серый */
  --ink: #1d1d1f;             /* почти чёрный текст */
  --ink-2: #6e6e73;           /* вторичный текст */
  --ink-3: #86868b;
  --line: #d2d2d7;            /* тонкие разделители */
  --accent: #e02b2b;          /* красный бренда */
  --accent-dark: #b91f1f;
  --ok-bg: #e8f5e9; --ok-ink: #1b5e20;
  --warn-bg: #fff8e1; --warn-ink: #7a5c00;
  --info-bg: #eef3fb; --info-ink: #1d3f7a;
  --radius: 18px;
  --nav-h: 52px;
  --wrap: 1080px;
  --prose: 760px;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 16px); }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-dark); }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 22px; }

/* ---------- Прогресс чтения ---------- */
.readbar {
  position: fixed; top: 0; left: 0; height: 3px; width: 0;
  background: var(--accent); z-index: 1000; transition: width .1s linear;
}

/* ---------- Навигация (стеклянная, как у Apple) ---------- */
.nav {
  position: sticky; top: 0; z-index: 900;
  height: var(--nav-h);
  background: rgba(255,255,255,.72);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--line);
}
.nav__in {
  max-width: var(--wrap); margin: 0 auto; padding: 0 22px;
  height: 100%; display: flex; align-items: center; justify-content: space-between;
}
.logo {
  font-weight: 800; font-size: 17px; letter-spacing: -.02em; color: var(--ink);
}
.logo span { color: var(--accent); }
.nav__links { display: flex; align-items: center; gap: 26px; }
.nav__links a { color: var(--ink); font-size: 14.5px; font-weight: 600; }
.nav__links a:hover { color: var(--accent); }
.nav__cta {
  background: var(--accent); color: #fff !important;
  padding: 7px 16px; border-radius: 980px; font-size: 14px !important;
  transition: background .2s;
}
.nav__cta:hover { background: var(--accent-dark); }
@media (max-width: 560px) { .nav__links { gap: 14px; } .nav__links a.hide-m { display: none; } }

/* ---------- Хлебные крошки ---------- */
.crumbs { padding: 26px 0 0; font-size: 13.5px; color: var(--ink-3); }
.crumbs a { color: var(--ink-2); }
.crumbs a:hover { color: var(--accent); }
.crumbs .sep { margin: 0 8px; color: var(--line); }

/* ---------- Hero ---------- */
.hero { padding: 54px 0 30px; }
.hero .kicker {
  color: var(--accent); font-weight: 800; font-size: 13px;
  letter-spacing: .12em; text-transform: uppercase; margin: 0 0 14px;
}
.hero h1 {
  font-size: clamp(2rem, 5.4vw, 3.4rem);
  line-height: 1.08; letter-spacing: -.03em; font-weight: 800;
  margin: 0 0 20px; max-width: 21ch;
}
.lead {
  font-size: clamp(1.1rem, 2vw, 1.3rem); color: var(--ink-2);
  max-width: 62ch; margin: 0;
}
.meta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }
.chip {
  font-size: 13px; font-weight: 600; color: var(--ink-2);
  background: var(--bg-alt); border-radius: 980px; padding: 6px 14px;
}

/* ---------- Оглавление ---------- */
.toc {
  background: var(--bg-alt); border-radius: var(--radius);
  padding: 26px 28px; margin: 34px 0 10px;
}
.toc h2 { font-size: 13px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); margin: 0 0 12px; }
.toc ol { margin: 0; padding-left: 20px; columns: 2; column-gap: 40px; }
.toc li { margin: 5px 0; break-inside: avoid; }
.toc a { color: var(--ink); font-weight: 600; font-size: 15px; }
.toc a:hover { color: var(--accent); }
@media (max-width: 700px) { .toc ol { columns: 1; } }

/* ---------- Текст статьи ---------- */
.prose { max-width: var(--prose); margin: 0 auto; padding: 26px 0 10px; }

.chapter { padding: 34px 0 6px; }
.chapter__num {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 40px; height: 40px; padding: 0 6px; border-radius: 12px;
  background: var(--accent); color: #fff;
  font-weight: 800; font-size: 17px; margin-bottom: 14px;
}
.chapter h2 {
  font-size: clamp(1.5rem, 3vw, 2.1rem); letter-spacing: -.025em;
  line-height: 1.15; margin: 0 0 18px; font-weight: 800;
}
.chapter h3 { font-size: 1.18rem; letter-spacing: -.015em; margin: 30px 0 10px; }
.prose p { margin: 0 0 18px; }
.prose ul, .prose ol { margin: 0 0 18px; padding-left: 24px; }
.prose li { margin: 7px 0; }
.prose strong { font-weight: 700; }
.chapter-sec { padding-bottom: 34px; border-bottom: 1px solid var(--bg-alt); margin-bottom: 34px; }
.chapter:last-of-type .chapter-sec { border-bottom: none; }

/* ---------- Врезки ---------- */
.callout {
  border-radius: var(--radius); padding: 20px 24px; margin: 24px 0;
  font-size: 15.5px;
}
.callout p:last-child { margin-bottom: 0; }
.callout .co-t { font-weight: 800; display: block; margin-bottom: 6px; }
.callout--info { background: var(--info-bg); color: var(--info-ink); }
.callout--warn { background: var(--warn-bg); color: var(--warn-ink); }
.callout--good { background: var(--ok-bg); color: var(--ok-ink); }
.callout--quote {
  background: var(--bg-alt); color: var(--ink); font-style: italic;
}

/* ---------- Карточки-статистика ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 14px; margin: 26px 0; }
.stat {
  background: var(--bg); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 22px;
}
.stat b { display: block; font-size: 1.55rem; letter-spacing: -.02em; font-weight: 800; }
.stat span { font-size: 13.5px; color: var(--ink-2); }

/* ---------- Шаги ---------- */
.steps { counter-reset: step; margin: 10px 0 8px; padding: 0; list-style: none; }
.steps li {
  counter-increment: step; position: relative;
  padding: 0 0 22px 58px; margin: 0;
}
.steps li::before {
  content: counter(step);
  position: absolute; left: 0; top: -2px;
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--bg-alt); color: var(--accent);
  font-weight: 800; display: flex; align-items: center; justify-content: center;
  font-size: 16px;
}
.steps li:not(:last-child)::after {
  content: ""; position: absolute; left: 19px; top: 42px; bottom: 6px;
  width: 1.5px; background: var(--line);
}
.steps b { display: block; margin-bottom: 4px; }

/* ---------- Таблица ---------- */
.tbl-scroll { overflow-x: auto; margin: 24px 0; border-radius: var(--radius); border: 1px solid var(--line); }
table.tbl { width: 100%; border-collapse: collapse; font-size: 15px; background: var(--bg); min-width: 560px; }
.tbl th { text-align: left; font-weight: 700; background: var(--bg-alt); }
.tbl th, .tbl td { padding: 13px 18px; border-bottom: 1px solid var(--bg-alt); vertical-align: top; }
.tbl tr:last-child td { border-bottom: none; }
.tbl td:first-child { font-weight: 600; }

/* ---------- Чек-лист ---------- */
.checklist { list-style: none; padding: 0; margin: 20px 0; }
.checklist li { padding: 12px 0 12px 38px; position: relative; border-bottom: 1px solid var(--bg-alt); }
.checklist li:last-child { border-bottom: none; }
.checklist li::before {
  content: "✓"; position: absolute; left: 4px; top: 10px;
  width: 24px; height: 24px; border-radius: 50%;
  background: var(--ok-bg); color: var(--ok-ink);
  font-size: 14px; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
}

/* ---------- CTA-панель ---------- */
.cta-panel {
  background: #0b0b0c; color: #f5f5f7;
  border-radius: 24px; padding: 46px 40px; margin: 46px 0;
  text-align: left;
}
.cta-panel h2 { font-size: clamp(1.4rem, 3vw, 2rem); letter-spacing: -.02em; margin: 0 0 12px; color: #fff; }
.cta-panel p { color: #a1a1a6; margin: 0 0 24px; max-width: 56ch; }
.btn {
  display: inline-block; background: var(--accent); color: #fff;
  font-weight: 700; font-size: 16px;
  padding: 13px 30px; border-radius: 980px;
  transition: background .2s, transform .2s;
}
.btn:hover { background: var(--accent-dark); color: #fff; transform: scale(1.02); }
.btn--ghost { background: transparent; border: 1.5px solid #48484a; color: #f5f5f7; margin-left: 12px; }
.btn--ghost:hover { background: #1c1c1e; border-color: #6e6e73; }
@media (max-width: 560px) { .cta-panel { padding: 34px 26px; } .btn--ghost { margin: 12px 0 0; } }

/* ---------- FAQ ---------- */
.faq { margin: 10px 0 0; }
.faq details {
  border: 1px solid var(--line); border-radius: 14px;
  padding: 0 22px; margin: 12px 0; background: var(--bg);
}
.faq details[open] { background: var(--bg-alt); border-color: transparent; }
.faq summary {
  cursor: pointer; list-style: none;
  font-weight: 700; font-size: 16.5px;
  padding: 18px 34px 18px 0; position: relative;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 4px; top: 50%;
  transform: translateY(-50%);
  font-size: 22px; font-weight: 400; color: var(--ink-3);
  transition: transform .25s;
}
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq .faq-a { padding: 0 0 20px; color: var(--ink-2); }
.faq .faq-a p:last-child { margin-bottom: 0; }

/* ---------- Читайте также ---------- */
.also { padding: 26px 0 60px; }
.also h2 { font-size: clamp(1.4rem, 3vw, 1.9rem); letter-spacing: -.02em; margin: 0 0 22px; }
.also-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.also-card {
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; color: var(--ink); background: var(--bg);
  transition: transform .25s, box-shadow .25s, border-color .25s;
  display: block;
}
.also-card:hover { transform: translateY(-4px); box-shadow: 0 12px 32px rgba(0,0,0,.08); border-color: transparent; color: var(--ink); }
.also-card .ac-tag { color: var(--accent); font-size: 12.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.also-card b { display: block; font-size: 17px; margin: 8px 0 6px; letter-spacing: -.01em; }
.also-card span { font-size: 14px; color: var(--ink-2); }

/* ---------- Футер ---------- */
.foot {
  border-top: 1px solid var(--line); padding: 34px 0 46px;
  color: var(--ink-3); font-size: 13.5px;
}
.foot__in { max-width: var(--wrap); margin: 0 auto; padding: 0 22px; }
.foot nav { display: flex; flex-wrap: wrap; gap: 20px; margin-bottom: 14px; }
.foot nav a { color: var(--ink-2); font-weight: 600; }
.foot nav a:hover { color: var(--accent); }
.foot .age {
  display: inline-flex; align-items: center; justify-content: center;
  border: 1.5px solid var(--ink-3); border-radius: 8px;
  font-weight: 800; font-size: 11.5px; padding: 2px 7px; margin-right: 10px;
}

/* ---------- Анимации появления ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.on { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn:hover { transform: none; }
}
