/* Общие стили публичного сайта (посадочные и статьи).
   Токены = apps/miniapp/src/ui/tokens.css и site/index.html — единый стиль мини-аппа и сайта.
   site/index.html живёт со встроенным <style> (исторически); новые страницы подключают этот файл. */
:root {
  --navy: #17334d;
  --light: #edf1f4;
  --navy-70: #576c7f;
  --navy-40: #97a5b1;
  --navy-12: #d3dae0;
  --navy-06: #e0e6ea;
  --surface: #ffffff;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 3px rgba(23, 51, 77, 0.1);
  --shadow-lg: 0 12px 40px rgba(23, 51, 77, 0.16);
  --font: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { font-family: var(--font); background: var(--light); color: var(--navy); font-size: 16px; line-height: 1.6; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 32px; }
a { color: inherit; }

header.site { position: sticky; top: 0; background: rgba(237, 241, 244, 0.92); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--navy-12); z-index: 10; }
.bar { display: flex; align-items: center; gap: 32px; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 20px; letter-spacing: -0.01em; white-space: nowrap; text-decoration: none; }
.brand svg { width: 36px; height: 36px; }
nav.site-nav { display: flex; gap: 24px; margin-left: auto; font-size: 15px; }
nav.site-nav a { text-decoration: none; color: var(--navy-70); white-space: nowrap; }
nav.site-nav a:hover { color: var(--navy); }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: 600 16px var(--font); border-radius: var(--radius); padding: 14px 24px;
  border: none; cursor: pointer; text-decoration: none; }
.btn-primary { background: var(--navy); color: var(--light); }
.btn-secondary { background: transparent; color: var(--navy); box-shadow: inset 0 0 0 1.5px var(--navy-40); }
.btn-sm { padding: 9px 18px; font-size: 15px; border-radius: var(--radius-sm); white-space: nowrap; }

/* Статья / текстовая страница */
main.article { max-width: 800px; margin: 0 auto; padding: 48px 32px 72px; }
.crumbs { font-size: 13.5px; color: var(--navy-40); margin-bottom: 20px; }
.crumbs a { color: var(--navy-70); text-decoration: none; }
.crumbs a:hover { text-decoration: underline; }
main.article h1 { font-size: 34px; line-height: 1.15; font-weight: 800; letter-spacing: -0.02em; margin-bottom: 12px; }
.meta { font-size: 13.5px; color: var(--navy-40); margin-bottom: 28px; }
main.article .lead { font-size: 18.5px; color: var(--navy-70); margin-bottom: 28px; }
main.article h2 { font-size: 24px; line-height: 1.25; letter-spacing: -0.01em; margin: 36px 0 14px; }
main.article h3 { font-size: 18px; margin: 26px 0 10px; }
main.article p { margin-bottom: 14px; }
main.article ul, main.article ol { margin: 0 0 16px 22px; }
main.article li { margin-bottom: 8px; }
main.article table { width: 100%; border-collapse: collapse; margin: 18px 0 22px; font-size: 14.5px; background: var(--surface); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
main.article th, main.article td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--navy-06); vertical-align: top; }
main.article th { background: var(--navy-06); font-size: 13px; text-transform: uppercase; letter-spacing: .05em; color: var(--navy-70); }
main.article tr:last-child td { border-bottom: none; }
.note-box { background: var(--surface); border-left: 4px solid var(--navy-40); border-radius: var(--radius-sm); padding: 14px 18px; margin: 18px 0; font-size: 15px; color: var(--navy-70); }

/* CTA-панель в тексте (селекторы с main.article — чтобы перебить типографику статьи) */
.cta-panel { background: var(--navy); color: var(--light); border-radius: var(--radius); padding: 28px; margin: 36px 0; }
.cta-panel h2, .cta-panel h3, main.article .cta-panel h2, main.article .cta-panel h3 { color: var(--light); margin: 0 0 8px; font-size: 20px; }
.cta-panel p, main.article .cta-panel p { color: var(--navy-12); margin-bottom: 16px; font-size: 15px; }
.cta-panel .btn-primary { background: var(--light); color: var(--navy); }

/* Список статей */
.article-list { display: grid; gap: 16px; margin-top: 8px; }
.article-card { display: block; background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); padding: 22px 24px; text-decoration: none; }
.article-card:hover h2 { text-decoration: underline; }
.article-card h2, main.article .article-card h2 { font-size: 19px; margin: 0 0 6px; }
.article-card p, main.article .article-card p { font-size: 14.5px; color: var(--navy-70); margin: 0; }
.article-card .tag { display: inline-block; font: 600 12px var(--font); background: var(--navy-06); border-radius: 999px; padding: 3px 10px; margin-top: 10px; color: var(--navy-70); }

/* Посадочная: секции-карточки */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.card { background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); padding: 24px; }
.card h3 { font-size: 17px; margin-bottom: 6px; }
.card p { font-size: 14px; color: var(--navy-70); }
.card .n { width: 32px; height: 32px; border-radius: 50%; background: var(--navy); color: var(--light);
  display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 15px; margin-bottom: 14px; }
.checks { list-style: none; margin: 0 0 16px; }
.checks li { font-size: 15px; padding: 7px 0 7px 26px; position: relative; }
.checks li::before { content: ""; position: absolute; left: 0; top: 13px; width: 14px; height: 8px;
  border-left: 2.5px solid var(--navy); border-bottom: 2.5px solid var(--navy); transform: rotate(-45deg); }
.faq details { background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px 22px; margin-bottom: 12px; }
.faq summary { font-weight: 700; font-size: 16px; cursor: pointer; }
.faq details p { margin-top: 10px; font-size: 15px; color: var(--navy-70); }

footer.site { background: var(--navy-06); border-top: 1px solid var(--navy-12); padding: 48px 0; font-size: 14px; margin-top: 48px; }
.foot { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 40px; }
.foot h4 { font-size: 13px; text-transform: uppercase; letter-spacing: .07em; color: var(--navy-40); margin-bottom: 12px; }
.foot p, .foot a { color: var(--navy-70); }
.foot a { display: block; text-decoration: none; padding: 3px 0; }
.foot a:hover { color: var(--navy); text-decoration: underline; }
.disclaimer { margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--navy-12); font-size: 12.5px; color: var(--navy-40); }

@media (max-width: 900px) {
  .wrap { padding: 0 20px; }
  .bar { height: 56px; gap: 12px; justify-content: space-between; }
  .brand { font-size: 18px; }
  .brand svg { width: 30px; height: 30px; }
  nav.site-nav { display: none; }
  main.article { padding: 28px 20px 48px; }
  main.article h1 { font-size: 27px; }
  main.article .lead { font-size: 16.5px; }
  main.article h2 { font-size: 21px; }
  .grid-3, .grid-4 { grid-template-columns: 1fr; gap: 12px; }
  .card { padding: 18px; }
  .foot { grid-template-columns: 1fr; gap: 24px; }
}
