/* Блог Aversum: шапка, подвал и страница статьи. Цвета и шрифты — из /assets/aversum-theme.css */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 64px; }
body { margin: 0; color: var(--text); font: 400 17px/1.6 var(--font); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
a { color: inherit; }
img { max-width: 100%; }
h1, h2, h3 { margin: 0; letter-spacing: -.03em; }
.kicker { margin: 0 0 12px; font: 600 14px/1.2 var(--font); letter-spacing: .02em; color: var(--em); }

.nav { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--bg) 72%, transparent); backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px); border-bottom: 1px solid transparent; transition: border-color .2s; }
.nav.scrolled { border-bottom-color: var(--line); }
.nav-in { max-width: 1080px; margin: 0 auto; padding: 0 22px; height: 52px; display: flex; align-items: center; gap: 28px; }
.brand { display: flex; align-items: center; gap: 8px; margin-right: 14px; font: 700 19px/1 var(--font); letter-spacing: -.02em; text-decoration: none; }
.brand img { width: 28px; height: auto; } .brand b { color: var(--em); }
.nav-links { flex: 1; display: flex; gap: 26px; justify-content: center; }
.nav-links a { font-size: 16px; font-weight: 700; color: var(--em); text-decoration: none; white-space: nowrap; transition: color .15s; } .nav-links a:hover { color: var(--em-hover); }
.pill-btn { white-space: nowrap; flex: none; display: inline-flex; align-items: center; justify-content: center; padding: 12px 24px; border-radius: 999px; background: var(--em); color: var(--em-ink); font: 600 17px/1 var(--font); text-decoration: none; transition: background .15s; border: 0; }
.pill-btn:hover { background: var(--em-hover); }
.pill-btn.sm { padding: 7px 15px; font-size: 13px; }

.foot { background: var(--bg); padding: 44px 22px 36px; font-size: 13px; color: var(--muted); border-top: 1px solid var(--line); margin-top: 72px; }
.foot-in { max-width: 1080px; margin: 0 auto; display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 28px; }
.foot h4 { margin: 0 0 10px; color: var(--text); font-size: 13px; font-weight: 600; }
.foot a { display: block; color: var(--muted); text-decoration: none; padding: 3px 0; } .foot a:hover { color: var(--text); text-decoration: underline; }
.foot p { margin: 6px 0 0; max-width: 280px; line-height: 1.45; }
.foot .copy { max-width: 1080px; margin: 28px auto 0; padding-top: 18px; border-top: 1px solid var(--line); }

/* Статья */
.art { max-width: 740px; margin: 0 auto; padding: clamp(36px, 6vw, 72px) 22px 0; }
.crumbs { font-size: 14px; color: var(--muted); margin: 0 0 22px; } .crumbs a { color: var(--muted); text-decoration: none; } .crumbs a:hover { color: var(--text); text-decoration: underline; }
.art h1 { font-size: clamp(32px, 5.4vw, 52px); line-height: 1.08; font-weight: 700; }
.meta { margin: 18px 0 0; font-size: 14px; color: var(--muted); }
.art .lead { margin: 26px 0 0; font-size: clamp(19px, 2.3vw, 22px); line-height: 1.5; color: var(--soft); }
.body h2 { margin: 48px 0 14px; font-size: clamp(24px, 3.4vw, 32px); line-height: 1.15; font-weight: 700; }
.body h3 { margin: 30px 0 10px; font-size: 20px; font-weight: 650; letter-spacing: -.02em; }
.body p { margin: 0 0 16px; }
.body ul, .body ol { margin: 0 0 18px; padding-left: 24px; } .body li { margin: 0 0 8px; }
.body a { color: var(--em); text-decoration: none; } .body a:hover { text-decoration: underline; }
.body strong { font-weight: 650; }
.body .note { margin: 24px 0; padding: 16px 20px; border-radius: 16px; background: var(--em-soft); border: 1px solid color-mix(in srgb, var(--em) 25%, transparent); font-size: 16px; }
.body .note p:last-child { margin: 0; }
.body .warn { background: color-mix(in srgb, var(--warn) 12%, transparent); border-color: color-mix(in srgb, var(--warn) 30%, transparent); }
.tbl { margin: 22px 0; overflow-x: auto; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); }
.tbl table { width: 100%; border-collapse: collapse; font-size: 15px; min-width: 480px; }
.tbl th, .tbl td { text-align: left; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.tbl th { font-weight: 600; color: var(--muted); font-size: 13px; background: var(--surface-2); }
.tbl tr:last-child td { border-bottom: 0; } .tbl td.n, .tbl th.n { text-align: right; white-space: nowrap; } .tbl td.g { color: var(--em); font-weight: 650; }
.steps { counter-reset: s; list-style: none; padding: 0; margin: 20px 0; }
.steps li { counter-increment: s; position: relative; padding: 0 0 0 52px; margin: 0 0 18px; }
.steps li::before { content: counter(s); position: absolute; left: 0; top: 0; width: 34px; height: 34px; border-radius: 50%; background: var(--em); color: var(--em-ink); font-weight: 700; display: grid; place-items: center; font-size: 15px; }
.steps li b { display: block; margin-bottom: 2px; }
.cta-box { margin: 56px 0 0; padding: clamp(26px, 4vw, 40px); border-radius: 24px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); text-align: center; }
.cta-box h2 { font-size: clamp(24px, 3.4vw, 32px); margin: 0 0 10px; }
.cta-box p { margin: 0 auto 22px; max-width: 520px; color: var(--soft); }
.cta-box .pill-btn { margin: 0 6px 8px; }
.cta-box .ghost { background: transparent; color: var(--em); border: 2px solid var(--em); padding: 10px 22px; } .cta-box .ghost:hover { background: var(--em); color: var(--em-ink); }
.related { margin: 48px 0 0; } .related h2 { font-size: 22px; margin: 0 0 14px; }
.related a { display: block; padding: 14px 18px; margin: 0 0 10px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); text-decoration: none; font-weight: 600; transition: border-color .15s, transform .15s; } .related a:hover { border-color: var(--em); }
.related a small { display: block; font-weight: 400; color: var(--muted); margin-top: 2px; font-size: 14px; }

/* Список статей */
.blog-head { max-width: 1080px; margin: 0 auto; padding: clamp(48px, 8vw, 96px) 22px 8px; text-align: center; }
.blog-head h1 { font-size: clamp(38px, 6.4vw, 68px); line-height: 1.05; font-weight: 700; }
.blog-head .kicker { color: var(--em); margin: 0 0 12px; font-size: clamp(18px, 2.4vw, 22px); font-weight: 700; max-width: none; }
.blog-head p { margin: 18px auto 0; max-width: 640px; font-size: clamp(18px, 2.2vw, 21px); color: var(--soft); line-height: 1.45; }
.cards { max-width: 1080px; margin: 40px auto 0; padding: 0 22px; display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.card { display: flex; flex-direction: column; padding: 28px; border-radius: 24px; background: var(--surface); border: 1px solid var(--line); text-decoration: none; transition: transform .18s, box-shadow .18s, border-color .18s; }
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: color-mix(in srgb, var(--em) 40%, var(--line)); }
.card .tag { font-size: 13px; font-weight: 600; color: var(--em); margin-bottom: 10px; }
.card h2 { font-size: 22px; line-height: 1.2; letter-spacing: -.02em; margin: 0 0 10px; }
.card p { margin: 0 0 18px; color: var(--soft); font-size: 16px; line-height: 1.5; flex: 1; }
.card .more { font-size: 14px; color: var(--muted); }
@media (max-width: 1000px) { .nav-links { gap: 16px; } .nav-links a { font-size: 15px; } .nav-in { gap: 16px; } }
@media (max-width: 760px) {
  .cards { grid-template-columns: 1fr; }
  .foot-in { grid-template-columns: 1fr 1fr; }
  .nav-in { gap: 12px; height: auto; flex-wrap: wrap; padding-block: 8px; }
  .nav-links { order: 3; flex: 1 0 100%; justify-content: flex-start; gap: 18px; overflow-x: auto; scrollbar-width: none; padding-bottom: 4px; }
  .nav-links::-webkit-scrollbar { display: none; }
  .brand { flex: 1; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } .card { transition: none; } }
