/* The Agreement Project — общий стиль (только CSS, без JS) */
:root {
  --navy: #001158;
  --ink: #1a1a1f;
  --muted: #5d6070;
  --line: #dcdde4;
  --bg: #ffffff;
  --soft: #f3f4f8;
  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --sans: "Source Sans 3", "Helvetica Neue", Arial, sans-serif;
  --wrap: 1180px;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 18px/1.5 var(--sans); }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--navy); outline-offset: 2px; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }

/* ---------- Шапка ---------- */
.topbar { background: var(--navy); color: #fff; font-size: 14px; }
.topbar .wrap { display: flex; justify-content: flex-end; gap: 24px; padding-top: 8px; padding-bottom: 8px; }
.topbar a { color: #fff; text-decoration: none; }
.topbar a:hover { text-decoration: underline; }

.site-header { border-bottom: 1px solid var(--line); background: #fff; }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; min-height: 84px; gap: 24px; }
.logo { font: 700 26px/1.1 var(--serif); text-decoration: none; color: var(--navy); letter-spacing: -0.01em; }
.logo small { display: block; font: 400 13px var(--sans); color: var(--muted); letter-spacing: 0; margin-top: 3px; }
.nav { display: flex; gap: 28px; list-style: none; margin: 0; padding: 0; }
.nav a { text-decoration: none; font-weight: 600; font-size: 17px; padding: 30px 0; display: block; border-bottom: 3px solid transparent; }
.nav a:hover, .nav a[aria-current] { border-bottom-color: var(--navy); color: var(--navy); }
.nav-toggle, .nav-burger { display: none; }

/* ---------- Главная ---------- */
.page-title { padding: 56px 0 12px; }
.page-title h1 { font: 700 44px/1.1 var(--serif); margin: 0 0 10px; color: var(--navy); }
.page-title p { margin: 0; color: var(--muted); max-width: 620px; }

.list { list-style: none; margin: 0; padding: 24px 0 72px; }
.item { display: grid; grid-template-columns: 240px 1fr; gap: 32px; padding: 32px 0; border-top: 1px solid var(--line); }
.item:first-child { border-top: 0; }
.item .thumb { display: block; aspect-ratio: 1 / 1; width: 100%; overflow: hidden; background: var(--soft); }
.item .thumb img { width: 100%; height: 100%; object-fit: cover; }
.item .author { font-weight: 600; color: var(--navy); font-size: 16px; margin: 0 0 6px; }
.item h2 { font: 700 30px/1.2 var(--serif); margin: 0 0 10px; }
.item h2 a { text-decoration: none; }
.item h2 a:hover { text-decoration: underline; text-underline-offset: 4px; }
.item .sub { color: var(--muted); margin: 0 0 14px; font-size: 17px; max-width: 640px; }
.item time { font-size: 15px; color: var(--muted); }

/* ---------- Статья ---------- */
.article-head { max-width: 820px; margin: 0 auto; padding: 56px 24px 24px; }
.article-head .section { font-weight: 600; color: var(--navy); font-size: 16px; margin: 0 0 14px; }
.article-head h1 { font: 700 46px/1.12 var(--serif); margin: 0 0 16px; letter-spacing: -0.01em; }
.article-head .lead { font: 400 22px/1.45 var(--serif); color: var(--muted); margin: 0 0 22px; }
.article-head .meta { font-size: 15px; color: var(--muted); border-top: 1px solid var(--line); padding-top: 14px; margin: 0; }
.article-head .meta a { color: var(--navy); font-weight: 600; }

figure { margin: 0; }
figcaption { font-size: 14px; color: var(--muted); margin-top: 8px; }
.hero { max-width: 1080px; margin: 16px auto 40px; padding: 0 24px; }
.hero img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; background: var(--soft); }

.article-body { max-width: 720px; margin: 0 auto; padding: 0 24px 24px; font: 400 20px/1.7 var(--serif); }
.article-body p { margin: 0 0 1.35em; }
.article-body h2 { font: 700 30px/1.25 var(--serif); margin: 2em 0 0.6em; color: var(--navy); }
.article-body a { color: var(--navy); text-underline-offset: 3px; }

.article-body figure.inline { margin: 2.2em -100px; }
.article-body figure.inline img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; background: var(--soft); }
.article-body figure.inline figcaption { font-family: var(--sans); padding: 0 100px; }

blockquote { margin: 2em 0; padding: 4px 0 4px 28px; border-left: 4px solid var(--navy); }
blockquote p { font: italic 400 26px/1.4 var(--serif); margin: 0 0 12px; color: var(--navy); }
blockquote cite { font: normal 600 15px var(--sans); color: var(--muted); }

.author-box { max-width: 720px; margin: 24px auto 72px; padding: 28px 24px 0; border-top: 1px solid var(--line); display: grid; grid-template-columns: 96px 1fr; gap: 24px; }
.author-box img { width: 96px; height: 96px; border-radius: 50%; object-fit: cover; background: var(--soft); }
.author-box h3 { font: 700 22px/1.2 var(--serif); margin: 0 0 4px; }
.author-box .role { color: var(--muted); font-size: 15px; margin: 0 0 10px; }
.author-box p { margin: 0 0 10px; font-size: 17px; }
.author-box .links a { font-weight: 600; color: var(--navy); margin-right: 16px; font-size: 16px; }

/* ---------- Подвал ---------- */
.site-footer { background: var(--navy); color: #fff; padding: 56px 0 24px; font-size: 16px; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 40px; }
.site-footer h4 { font: 700 18px var(--serif); margin: 0 0 14px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 8px; }
.site-footer a { color: #fff; text-decoration: none; opacity: .88; }
.site-footer a:hover { opacity: 1; text-decoration: underline; }
.site-footer .about { opacity: .8; max-width: 320px; margin: 10px 0 0; }
.site-footer .logo { color: #fff; }
.footer-bottom { margin-top: 40px; padding-top: 20px; border-top: 1px solid rgba(255,255,255,.25); font-size: 14px; opacity: .8; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; }

/* ---------- Адаптив ---------- */
@media (max-width: 1000px) {
  .article-body figure.inline { margin-left: 0; margin-right: 0; }
  .article-body figure.inline figcaption { padding: 0; }
}
@media (max-width: 820px) {
  .nav-burger { display: block; cursor: pointer; font-weight: 600; padding: 10px 0; }
  .nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: #fff; flex-direction: column; gap: 0; padding: 8px 24px 16px; border-bottom: 1px solid var(--line); z-index: 10; }
  .nav a { padding: 12px 0; border-bottom: 1px solid var(--line); }
  .nav-toggle:checked ~ .nav { display: flex; }
  .site-header { position: relative; }
  .page-title h1, .article-head h1 { font-size: 34px; }
  .item { grid-template-columns: 1fr; gap: 16px; }
  .item .thumb { max-width: 360px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .article-body { font-size: 18px; }
  blockquote p { font-size: 22px; }
}
@media (max-width: 480px) {
  .footer-grid { grid-template-columns: 1fr; }
  .author-box { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

/* ---------- Логотип с картинкой ---------- */
.logo { display: flex; align-items: center; gap: 14px; }
.logo-img { width: 52px; height: 52px; object-fit: cover; background: var(--soft); flex: none; }

/* ---------- Главная статья ---------- */
.featured { display: block; text-decoration: none; padding: 40px 0 8px; }
.featured img { width: 100%; aspect-ratio: 21 / 9; object-fit: cover; background: var(--soft); }
.featured .author { font-weight: 600; color: var(--navy); font-size: 16px; margin: 20px 0 6px; }
.featured h2 { font: 700 40px/1.15 var(--serif); margin: 0 0 10px; max-width: 860px; }
.featured:hover h2 { text-decoration: underline; text-underline-offset: 5px; }
.featured .sub { color: var(--muted); font-size: 19px; margin: 0 0 12px; max-width: 760px; }
.featured time { font-size: 15px; color: var(--muted); }
.featured + .page-title { padding-top: 48px; }
@media (max-width: 820px) {
  .featured img { aspect-ratio: 16 / 9; }
  .featured h2 { font-size: 30px; }
}