/* Дизайн-слой автомедиа НеЛимон.
   Палитра — ровно та же, что в роликах: бумага, тушь, лимон как акцент.
   Тёмно-золотая тема осталась в pages.css для продуктовых страниц. */

:root {
  --paper: #f2efe6;
  --paper-2: #fbfaf5;
  --ink: #1e2117;
  --ink-soft: #4a4f40;
  --lemon: #e8c766;
  --signal: #d94f3d;
  --truth: #3e7c5a;
  --asphalt: #4a5a66;
  --smoke: #a8a192;
  --line: rgba(30, 33, 23, 0.14);
  --line-soft: rgba(30, 33, 23, 0.07);
  --radius: 14px;
  --wrap: 1140px;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Onest", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* Зерно бумаги — тот же приём, что последним слоем в кадрах роликов */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23n)'/%3E%3C/svg%3E");
}

.wrap { width: min(var(--wrap), 100% - 40px); margin-inline: auto; position: relative; z-index: 1; }

h1, h2, h3, .brandfont {
  font-family: "Unbounded", "Onest", system-ui, sans-serif;
  letter-spacing: -0.015em;
  line-height: 1.18;
  margin: 0;
}

a { color: inherit; }

/* ---------- Шапка ---------- */

.top {
  border-bottom: 1px solid var(--line);
  background: rgba(242, 239, 230, 0.9);
  backdrop-filter: saturate(140%) blur(8px);
  position: sticky;
  top: 0;
  z-index: 20;
}

.top-in {
  display: flex;
  align-items: center;
  gap: 26px;
  height: 68px;
}

.logo { display: flex; align-items: center; gap: 11px; text-decoration: none; margin-right: auto; }
.logo img { width: 40px; height: 40px; border-radius: 50%; display: block; }
.logo b { font-family: "Unbounded", sans-serif; font-weight: 800; font-size: 19px; letter-spacing: -0.02em; }
.logo span { display: block; font-size: 9.5px; letter-spacing: 0.22em; color: var(--smoke); text-transform: uppercase; margin-top: 1px; }

.nav { display: flex; gap: 22px; align-items: center; }
.nav a { text-decoration: none; font-weight: 500; font-size: 15px; color: var(--ink-soft); padding: 6px 0; border-bottom: 2px solid transparent; }
.nav a:hover { color: var(--ink); border-bottom-color: var(--signal); }

.btn {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--ink); color: var(--paper);
  text-decoration: none; font-weight: 600; font-size: 15px;
  padding: 11px 20px; border-radius: 999px; border: 0; cursor: pointer;
  transition: transform 0.12s ease, background 0.12s ease;
}
.btn:hover { transform: translateY(-1px); background: #2b3020; }
.btn-lemon { background: var(--lemon); color: var(--ink); }
.btn-lemon:hover { background: #f0d47f; }
.btn-ghost { background: transparent; color: var(--ink); border: 1.5px solid var(--line); }
.btn-ghost:hover { background: rgba(30,33,23,0.05); }

.burger { display: none; background: none; border: 0; padding: 8px; cursor: pointer; }
.burger span { display: block; width: 22px; height: 2px; background: var(--ink); margin: 4px 0; border-radius: 2px; }

/* ---------- Заголовок раздела ---------- */

.sec { margin-top: 64px; }
.sec-head { display: flex; align-items: baseline; gap: 16px; margin-bottom: 22px; }
.sec-head h2 { font-size: clamp(1.15rem, 1rem + 0.7vw, 1.5rem); }
.sec-head .rule { flex: 1; height: 2px; background: var(--signal); opacity: 0.5; }
.sec-head a { text-decoration: none; font-size: 14px; color: var(--ink-soft); white-space: nowrap; font-weight: 500; }
.sec-head a:hover { color: var(--signal); }

/* ---------- Герой: свежее расследование ---------- */

.hero { padding: 48px 0 0; }

.kicker {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 11.5px; letter-spacing: 0.16em; text-transform: uppercase;
  font-weight: 600; color: var(--signal); margin-bottom: 14px;
}
.kicker::before { content: ""; width: 22px; height: 2px; background: var(--signal); }

.hero-grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: 44px; align-items: center; }
.hero h1 { font-size: clamp(1.75rem, 1.25rem + 2.2vw, 2.85rem); margin-bottom: 16px; }
.hero p { font-size: 18px; color: var(--ink-soft); margin: 0 0 24px; max-width: 46ch; }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; }

.play {
  display: block; position: relative; border-radius: var(--radius); overflow: hidden;
  border: 1.5px solid var(--line); background: var(--paper-2); aspect-ratio: 16/9;
  text-decoration: none;
}
.play img { width: 100%; height: 100%; object-fit: cover; display: block; }
.play::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle at 50% 50%, rgba(30,33,23,0.06), rgba(30,33,23,0.22));
  opacity: 0; transition: opacity 0.2s ease;
}
.play:hover::after { opacity: 1; }
.play-badge {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%,-50%);
  width: 66px; height: 66px; border-radius: 50%;
  background: var(--signal); border: 3px solid var(--paper);
  display: grid; place-items: center; z-index: 2;
  transition: transform 0.16s ease;
}
.play:hover .play-badge { transform: translate(-50%,-50%) scale(1.08); }
.play-badge::after { content: ""; border-left: 17px solid var(--paper); border-top: 11px solid transparent; border-bottom: 11px solid transparent; margin-left: 5px; }
.play-time {
  position: absolute; right: 10px; bottom: 10px; z-index: 2;
  background: rgba(30,33,23,0.82); color: var(--paper);
  font-size: 12px; font-weight: 600; padding: 3px 8px; border-radius: 5px;
}

/* ---------- Карточки материалов ---------- */

.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.cards.two { grid-template-columns: repeat(2, 1fr); }

.card {
  display: flex; flex-direction: column;
  background: var(--paper-2); border: 1.5px solid var(--line);
  border-radius: var(--radius); padding: 22px; text-decoration: none;
  transition: transform 0.14s ease, border-color 0.14s ease;
}
.card:hover { transform: translateY(-3px); border-color: rgba(30,33,23,0.32); }
.card h3 { font-size: 17px; margin-bottom: 9px; }
.card p { margin: 0; font-size: 14.5px; color: var(--ink-soft); line-height: 1.55; }
.card .meta { margin-top: auto; padding-top: 16px; font-size: 12.5px; color: var(--smoke); display: flex; gap: 10px; align-items: center; }

.chip {
  display: inline-block; font-size: 11px; letter-spacing: 0.09em; text-transform: uppercase;
  font-weight: 700; padding: 4px 9px; border-radius: 5px; margin-bottom: 13px;
  background: rgba(74,90,102,0.12); color: var(--asphalt);
}
.chip.signal { background: rgba(217,79,61,0.13); color: var(--signal); }
.chip.truth  { background: rgba(62,124,90,0.13); color: var(--truth); }
.chip.lemon  { background: rgba(232,199,102,0.26); color: #8a6d18; }

/* ---------- Инструмент проверки ---------- */

.tool {
  border: 1.5px solid var(--line); border-radius: var(--radius);
  background: var(--paper-2); padding: 34px; margin-top: 64px;
  display: grid; grid-template-columns: 1fr auto; gap: 34px; align-items: center;
}
.tool h2 { font-size: clamp(1.2rem, 1rem + 0.8vw, 1.6rem); margin-bottom: 10px; }
.tool p { margin: 0 0 20px; color: var(--ink-soft); max-width: 52ch; }
.tool form { display: flex; gap: 10px; flex-wrap: wrap; }
.tool input {
  flex: 1 1 230px; min-width: 0;
  padding: 13px 16px; font-size: 16px; font-family: inherit;
  border: 1.5px solid var(--line); border-radius: 999px; background: var(--paper);
  color: var(--ink);
}
.tool input:focus { outline: 2px solid var(--lemon); outline-offset: 1px; border-color: transparent; }
.tool-art { width: 168px; }
.tool-art img { width: 100%; display: block; }
.tool-note { font-size: 13px; color: var(--smoke); margin-top: 12px; }

/* ---------- Подписка ---------- */

.subscribe {
  margin-top: 64px; border-radius: var(--radius); padding: 40px;
  background: var(--ink); color: var(--paper); text-align: center;
}
.subscribe h2 { font-size: clamp(1.2rem, 1rem + 0.9vw, 1.7rem); margin-bottom: 12px; }
.subscribe p { color: rgba(242,239,230,0.72); margin: 0 auto 24px; max-width: 50ch; }

/* ---------- Подвал ---------- */

.foot { margin-top: 80px; border-top: 1px solid var(--line); padding: 32px 0 48px; font-size: 14px; color: var(--ink-soft); }
.foot-in { display: flex; gap: 26px; flex-wrap: wrap; align-items: center; }
.foot a { text-decoration: none; }
.foot a:hover { color: var(--signal); }
.foot .sp { margin-left: auto; color: var(--smoke); font-size: 13px; }

/* ---------- Статья ---------- */

.article { max-width: 740px; margin-inline: auto; padding-top: 48px; }
.article h1 { font-size: clamp(1.6rem, 1.2rem + 1.9vw, 2.4rem); margin-bottom: 14px; }
.article .lead { font-size: 19px; color: var(--ink-soft); margin: 0 0 12px; }
.article .byline { font-size: 13.5px; color: var(--smoke); padding-bottom: 26px; border-bottom: 1px solid var(--line); margin-bottom: 34px; }
.article h2 { font-size: 1.35rem; margin: 42px 0 14px; }
.article h3 { font-size: 1.1rem; margin: 30px 0 10px; }
.article p { margin: 0 0 18px; }
.article ul, .article ol { margin: 0 0 20px; padding-left: 22px; }
.article li { margin-bottom: 9px; }
.article table { width: 100%; border-collapse: collapse; margin: 0 0 24px; font-size: 15px; }
.article th, .article td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.article th { font-weight: 700; background: rgba(30,33,23,0.04); }
.article blockquote {
  margin: 0 0 24px; padding: 18px 22px; border-left: 3px solid var(--signal);
  background: var(--paper-2); border-radius: 0 var(--radius) var(--radius) 0;
}
.article blockquote p:last-child { margin: 0; }
.article figure { margin: 0 0 26px; }
.article figure img { width: 100%; border-radius: var(--radius); border: 1.5px solid var(--line); display: block; }
.article figcaption { font-size: 13px; color: var(--smoke); margin-top: 8px; }
.embed { position: relative; aspect-ratio: 16/9; margin: 0 0 26px; }
.embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; border-radius: var(--radius); }

.fact {
  border: 1.5px solid var(--line); border-left: 4px solid var(--lemon);
  border-radius: 0 var(--radius) var(--radius) 0;
  background: var(--paper-2); padding: 18px 22px; margin: 0 0 24px;
}
.fact b { display: block; font-family: "Unbounded", sans-serif; font-size: 13px; letter-spacing: 0.04em; text-transform: uppercase; color: var(--smoke); margin-bottom: 6px; }

/* ---------- Адаптив ---------- */

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; gap: 26px; }
  .hero-grid .play { order: -1; }
  .cards, .cards.two { grid-template-columns: 1fr 1fr; }
  .tool { grid-template-columns: 1fr; }
  .tool-art { display: none; }
}

@media (max-width: 620px) {
  body { font-size: 16px; }
  .wrap { width: calc(100% - 32px); }
  .nav { display: none; }
  .burger { display: block; }
  .nav.open {
    display: flex; flex-direction: column; align-items: flex-start; gap: 0;
    position: absolute; top: 68px; left: 0; right: 0;
    background: var(--paper); border-bottom: 1px solid var(--line); padding: 8px 16px 16px;
  }
  .nav.open a { padding: 12px 0; width: 100%; border-bottom: 1px solid var(--line-soft); }
  .cards, .cards.two { grid-template-columns: 1fr; }
  .sec { margin-top: 48px; }
  .subscribe, .tool { padding: 26px 20px; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}
