/* muzhikznaet.ru — светлая редакционная тема в духе Highsnobiety/Art of Manliness/GQ/Esquire:
   светло-серый фон, почти чёрный текст, максимально жирные заголовки, один точечный
   акцент — насыщенный журнальный красный (ссылки, метки, подчёркивания при наведении). */

@import url('https://fonts.googleapis.com/css2?family=Oswald:wght@500;700;800&family=Montserrat:wght@800;900&family=PT+Sans:wght@400;700&display=swap');

:root {
  --bg: #f0f0f0;              /* светло-серый, не белоснежный и не кремовый */
  --bg-raised: #ffffff;       /* карточки/шапка — чистый белый на сером фоне */
  --bg-raised-hover: #fafafa;
  --text: #141414;            /* почти чёрный */
  --muted: #6b6b6b;           /* приглушённый серый — даты, подписи, второстепенный текст */
  --accent: #d6001c;          /* насыщенный журнальный красный — точечный акцент */
  --accent-2: #a5000f;        /* более тёмный красный — hover/pressed состояния */
  --accent-rgb: 214, 0, 28;
  --accent-2-rgb: 165, 0, 15;
  --border: #dcdcdc;
  --overlay-dark: 10, 10, 10; /* тёмный оверлей для текста поверх ярких картинок (не зависит от темы) */
  --max-width: 1120px;
  --ease: cubic-bezier(.16,.8,.24,1);
}

* { box-sizing: border-box; }

html {
  background: linear-gradient(180deg, #f8f8f7 0%, #d2cfca 100%);
  scroll-behavior: smooth;
  width: 100%;
}

body {
  margin: 0;
  padding: 0;
  background: linear-gradient(180deg, #f8f8f7 0%, #d2cfca 100%);
  background-attachment: fixed;
  color: var(--text);
  font-family: 'PT Sans', Arial, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
  /* Место под закреплённую шапку (она position: fixed и в потоке места не
     занимает). --top-h = высота РАЗВЁРНУТОЙ шапки + строки категорий, её пишет
     script.js; 172px - запасное значение, пока скрипт не отработал. */
  padding-top: var(--top-h, 172px);
}

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

a { color: var(--accent); transition: color 0.25s ease; }
a:hover { color: var(--accent-2); }

h1, h2, h3 {
  font-family: 'Oswald', Arial, sans-serif;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: var(--text);
}

h1, .hero-title, .card-title, .section-title {
  font-family: 'Montserrat', Arial, sans-serif;
  font-weight: 900;
  letter-spacing: -0.01em;
}

.tag {
  font-family: 'Montserrat', Arial, sans-serif;
  font-weight: 800;
}

/* ---------- Появление при прокрутке (базовое состояние — анимирует script.js/GSAP) ---------- */

.reveal {
  opacity: 0;
  transform: translateY(40px);
  will-change: transform, opacity;
}

.hero-card { will-change: transform; }
.hero-card .tag,
.hero-card .hero-title,
.hero-card .hero-excerpt,
.hero-card .meta {
  opacity: 0;
}

.article-grid .card {
  opacity: 0;
  transform: translateY(70px) scale(0.94);
  will-change: transform, opacity;
}

@keyframes fadeInDown {
  from { opacity: 0; transform: translateY(-14px); }
  to   { opacity: 1; transform: none; }
}

/* Без JS (или если GSAP не загрузился) — контент должен быть виден, а не спрятан навсегда */
.no-js .reveal,
.no-js .hero-card .tag,
.no-js .hero-card .hero-title,
.no-js .hero-card .hero-excerpt,
.no-js .hero-card .meta,
.no-js .article-grid .card {
  opacity: 1 !important;
  transform: none !important;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal,
  .hero-card .tag, .hero-card .hero-title, .hero-card .hero-excerpt, .hero-card .meta,
  .article-grid .card {
    opacity: 1 !important;
    transform: none !important;
  }
  .site-header { animation: none; }
}

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

/* fixed, а не sticky: сворачивание шапки при скролле не должно менять высоту
   документа. При sticky шапка и строка категорий сжимались в потоке примерно
   на 100px; на короткой странице браузер из-за этого сдвигал scrollY ниже
   порога разворота, шапка разворачивалась, привязка прокрутки (scroll
   anchoring) возвращала scrollY выше порога - и так по кругу ~20 раз в секунду
   даже без участия пользователя: шапка и капсулы мигали, страница "подвисала". */
header.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: var(--bg-raised);
  padding: 18px 20px;
  border-bottom: 2px solid var(--text);
  animation: fadeInDown 0.5s var(--ease) both;
  transition: padding 0.3s var(--ease);
}

header.site-header.is-compact { padding: 10px 20px; }

header.site-header .wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 24px;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-shrink: 0;
}

.logo {
  text-decoration: none;
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  flex-shrink: 0;
  transition: transform 0.3s var(--ease);
}

.logo:hover { transform: scale(1.04); }

.site-logo {
  height: 52px;
  width: auto;
  display: block;
  transition: height 0.3s var(--ease);
}

header.site-header.is-compact .site-logo { height: 32px; }

.site-slogan {
  margin-top: 4px;
  font-family: 'Oswald', Arial, sans-serif;
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  max-height: 20px;
  overflow: hidden;
  opacity: 1;
  transition: opacity 0.25s ease, max-height 0.3s ease, margin 0.3s ease;
}

header.site-header.is-compact .site-slogan {
  opacity: 0;
  max-height: 0;
  margin-top: 0;
}

/* ---------- Бегущая строка анонсов в шапке ---------- */

.header-ticker {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  position: relative;
  -webkit-mask-image: linear-gradient(to right, transparent, #000 24px, #000 calc(100% - 24px), transparent);
  mask-image: linear-gradient(to right, transparent, #000 24px, #000 calc(100% - 24px), transparent);
}

.header-ticker-track {
  display: flex;
  align-items: center;
  gap: 28px;
  width: max-content;
  padding: 10px 0;
  animation: header-ticker-scroll 28s linear infinite;
}

.header-ticker:hover .header-ticker-track { animation-play-state: paused; }

.header-ticker-track a {
  display: inline-block;
  white-space: nowrap;
  font-family: 'Oswald', Arial, sans-serif;
  font-weight: 700;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--muted);
  text-decoration: none;
  transform: scale(1) translateY(0);
  transition: color 0.25s ease, transform 0.3s var(--ease), text-shadow 0.3s ease;
}

.header-ticker-track a:hover {
  color: var(--accent);
  transform: scale(1.22) translateY(-3px);
  text-shadow: 0 6px 18px rgba(214, 0, 28, 0.35);
  position: relative;
  z-index: 1;
}

.header-ticker-sep {
  color: var(--border);
  font-size: 13px;
}

@keyframes header-ticker-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ---------- Правая часть шапки: гамбургер общей панели меню ---------- */

.header-actions {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-shrink: 0;
}

.header-cta {
  display: inline-flex;
  align-items: center;
  color: var(--text);
  text-decoration: none;
  font-family: 'Oswald', Arial, sans-serif;
  font-weight: 700;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 12px 24px;
  border: 1.5px solid var(--text);
  border-radius: 999px;
  white-space: nowrap;
  transition: background 0.3s var(--ease), color 0.3s var(--ease), border-color 0.3s var(--ease);
}

.header-cta:hover {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

/* ---------- Кнопка-гамбургер (единая на компьютере и телефоне) ---------- */

.menu-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  flex-shrink: 0;
}

.menu-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.35s var(--ease), opacity 0.35s var(--ease);
}

body.nav-open .menu-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
body.nav-open .menu-toggle span:nth-child(2) { opacity: 0; }
body.nav-open .menu-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Боковая панель меню слева (разделы + доп. ссылки) — компьютер и телефон ---------- */

.mobile-nav-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(10, 10, 10, 0.18);
  z-index: 240;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s ease, visibility 0s linear 0.35s;
}

body.nav-open .mobile-nav-backdrop {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.35s ease, visibility 0s linear 0s;
}

body.nav-open { overflow: hidden; }

.mobile-nav-overlay {
  display: flex;
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: 340px;
  max-width: 88vw;
  z-index: 250;
  background: rgba(240, 240, 240, 0.1);
  flex-direction: column;
  align-items: stretch;
  overflow-y: auto;
  padding: 90px 24px 40px;
  visibility: hidden;
  transform: translateX(-100%);
  box-shadow: 10px 0 40px rgba(0, 0, 0, 0.12);
  transition: transform 0.4s var(--ease), visibility 0s linear 0.4s;
}

body.nav-open .mobile-nav-overlay {
  visibility: visible;
  transform: translateX(0);
  transition: transform 0.4s var(--ease), visibility 0s linear 0s;
}

.mobile-nav-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 48px;
  height: 48px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
  border: 1.5px solid var(--border);
  border-radius: 50%;
  color: var(--text);
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  transition: border-color 0.3s ease, color 0.3s ease;
}

.mobile-nav-close:hover { border-color: var(--accent); color: var(--accent); }

.mobile-nav-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  width: 100%;
}

.mobile-nav-list li { margin: 0; }

.mobile-nav-list .category-nav-link {
  display: block;
  width: 100%;
  box-sizing: border-box;
  text-align: center;
  white-space: normal;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
}

/* доп. ссылки (поиск, о проекте, популярное, контакты) — второй, более
   спокойный уровень меню под основным списком разделов */
.mobile-nav-extra {
  list-style: none;
  padding: 22px 0 0;
  margin: 22px 0 0;
  border-top: 1px solid var(--border);
  text-align: center;
}

.mobile-nav-extra li { margin: 10px 0; }

.mobile-nav-extra a,
.mobile-nav-extra button {
  display: inline-block;
  background: rgba(255, 255, 255, 0.92);
  border: none;
  border-radius: 20px;
  font-family: 'Oswald', Arial, sans-serif;
  font-weight: 700;
  font-size: 16px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text);
  text-decoration: none;
  cursor: pointer;
  padding: 10px 24px;
  transition: color 0.25s ease, background 0.25s ease;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
}

.mobile-nav-extra a:hover,
.mobile-nav-extra button:hover { color: var(--accent); }

.inline-search {
  text-align: left;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  margin-top: 0;
  transition: max-height 0.3s var(--ease), opacity 0.25s ease, margin-top 0.3s var(--ease);
}

.inline-search.is-open {
  max-height: 260px;
  opacity: 1;
  margin-top: 14px;
}

#site-search {
  width: 100%;
  padding: 12px 14px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-family: 'PT Sans', Arial, sans-serif;
  font-size: 15px;
  transition: border-color 0.3s ease;
}

#site-search::placeholder { color: var(--muted); }
#site-search:focus { outline: none; border-color: var(--accent); }

.search-results {
  list-style: none;
  padding: 0;
  margin: 10px 0 0;
}

.search-results li { margin-bottom: 6px; }

.search-results a {
  display: block;
  color: var(--text);
  text-decoration: none;
  font-size: 14.5px;
  padding: 9px 10px;
  border-radius: 4px;
  background: var(--bg);
  transition: background 0.25s ease, color 0.25s ease;
}

.search-results a:hover { background: var(--accent); color: #fff; }

.search-empty {
  color: var(--muted);
  font-size: 14px;
  font-style: italic;
  padding: 4px 2px;
}

/* ---------- Постоянная строка капсул-категорий под шапкой ---------- */

/* Запасной вариант (скрипт ещё не отработал или в кэше браузера старый
   script.js): строка закреплена под шапкой по --header-h. */
.category-nav {
  position: fixed;
  top: var(--header-h, 112px);
  left: 0;
  right: 0;
  z-index: 90;
  display: flex;
  /* justify-content:center один центрирует список капсул, когда он
     помещается целиком - но если список ШИРЕ экрана (много категорий
     на узком телефоне), центрирование уводит начало и конец списка в
     отрицательную/недостижимую скроллом область - капсулы обрезаны
     И их нельзя докрутить. "safe center" - тот же центр, когда контент
     помещается, и откат на выравнивание по началу, когда не помещается,
     чтобы всё оставалось доступным через скролл. Строка выше - fallback для
     браузеров без поддержки safe/unsafe (просто не поймут вторую
     строку и останутся на flex-start). */
  justify-content: flex-start;
  justify-content: safe center;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
  -ms-overflow-style: none;
  background: var(--bg-raised);
  width: 100%;
  box-sizing: border-box;
  padding: 14px 20px;
  max-height: 60px;
  /* opacity сюда специально не добавляем: полупрозрачность во время сворачивания
     давала эффект "текст просвечивает сквозь панель" - сворачиваем только
     высотой/отступами, без затемнения-исчезновения */
  transition: max-height 0.3s var(--ease), padding 0.3s var(--ease);
}

.category-nav::-webkit-scrollbar { display: none; }

/* Основной вариант: script.js переносит строку внутрь шапки - она висит сразу
   под нижней границей шапки (2px) и едет вместе с ней в том же кадре анимации. */
header.site-header > .category-nav {
  position: absolute;
  top: calc(100% + 2px);
}

header.site-header.is-compact ~ .category-nav,
header.site-header.is-compact .category-nav {
  max-height: 0;
  padding-top: 0;
  padding-bottom: 0;
  pointer-events: none;
}

.category-nav-list {
  position: relative;
  list-style: none;
  display: flex;
  gap: 8px;
  margin: 0;
  padding: 0;
  width: max-content;
}

/* Капсулы категорий (также переиспользуются в боковой панели меню) */

.category-nav-link {
  position: relative;
  display: inline-block;
  white-space: nowrap;
  color: var(--muted);
  text-decoration: none;
  font-family: 'Oswald', Arial, sans-serif;
  font-weight: 700;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 7px 14px;
  border: 1px solid var(--border);
  border-radius: 20px;
  transition: color 0.25s var(--ease), border-color 0.25s var(--ease), background 0.25s var(--ease), transform 0.25s var(--ease);
}

.category-nav-link:hover {
  color: var(--accent);
  border-color: var(--accent);
  transform: translateY(-2px) scale(1.06);
}

.category-nav-link.is-current {
  color: #fff;
  background: var(--accent);
  border-color: var(--accent);
}

/* Отключает transition на первую (мгновенную) простановку is-compact при
   загрузке уже прокрученной страницы - см. script.js. Без этого при
   восстановлении browser-ом позиции скролла на 0.3с проигрывалась анимация
   сворачивания шапки/панели категорий поверх уже видимого контента. */
.no-anim,
.no-anim * {
  transition: none !important;
}

/* ---------- Заголовки / текст ---------- */

h1 {
  font-size: 44px;
  text-transform: uppercase;
  line-height: 1.02;
  margin: 0 0 14px;
}

h2 { font-size: 22px; margin: 0; }

p { font-weight: 400; }

.placeholder-note {
  background: var(--bg-raised);
  border: 1px dashed var(--border);
  border-left: 4px solid var(--accent);
  padding: 18px 22px;
  font-size: 15px;
  color: var(--muted);
  border-radius: 4px;
  margin-bottom: 48px;
}

/* ---------- Тег-плашка (категория) ---------- */

.tag {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 5px 11px;
  border-radius: 3px;
  line-height: 1;
  text-decoration: none;
}

a.tag { transition: background 0.3s var(--ease); }
a.tag:hover { background: var(--accent-2); }

/* ---------- Секции на главной (по разделам) ---------- */

.content-section { margin-bottom: 72px; }

.section-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 28px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
}

.section-eyebrow {
  display: block;
  font-size: 12px;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
  margin-bottom: 8px;
}

.section-title {
  font-size: 30px;
  margin: 0;
  text-transform: uppercase;
  line-height: 1.05;
}

.section-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text);
  text-decoration: none;
  font-family: 'Oswald', Arial, sans-serif;
  font-weight: 700;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 8px 4px;
  transition: color 0.3s var(--ease), gap 0.3s var(--ease);
  white-space: nowrap;
}

.section-link:hover { color: var(--accent); gap: 10px; }

/* ---------- Хлебная крошка на странице статьи ---------- */

.breadcrumb {
  margin: 0 0 18px;
  font-size: 13px;
}

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

.category-header {
  margin-bottom: 48px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--border);
}

.category-header .tag { margin-bottom: 16px; }

.category-header h1 { margin-bottom: 12px; }

.category-header p {
  color: var(--muted);
  margin: 0;
  max-width: 640px;
  font-size: 17px;
  line-height: 1.6;
}

/* ---------- Главная карточка (герой) ---------- */

.hero-card {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 20 / 9;
  min-height: 340px;
  border-radius: 10px;
  overflow: hidden;
  text-decoration: none;
  margin-bottom: 56px;
  border: 1px solid var(--border);
  transition: box-shadow 0.4s var(--ease);
}

.hero-card:hover {
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.12);
}

.hero-thumb {
  position: absolute;
  inset: -10% 0;
  overflow: hidden;
  transition: transform 0.5s var(--ease);
  background:
    repeating-linear-gradient(135deg, rgba(0, 0, 0, 0.15) 0 14px, transparent 14px 28px),
    linear-gradient(160deg, #3c3c3c 0%, #0d0d0d 100%);
}

.hero-card:hover .hero-thumb { transform: scale(1.03); }

.hero-thumb .thumb-inner {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  will-change: transform;
}

.hero-thumb svg {
  width: 128px; height: 128px;
  fill: none; stroke: #f0f0f0; stroke-width: 1.4;
  opacity: 0.9;
}

.hero-overlay {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 36px 36px 30px;
  background: linear-gradient(180deg, transparent 0%, rgba(var(--overlay-dark), 0.6) 38%, rgba(var(--overlay-dark), 0.97) 100%);
  color: #f3f3f3;
  will-change: transform;
}

.hero-overlay .tag { margin-bottom: 14px; }

.hero-title {
  font-size: 36px;
  margin: 0 0 12px;
  text-transform: uppercase;
  line-height: 1.02;
  max-width: 760px;
  color: #f3f3f3;
}

.hero-excerpt {
  color: rgba(243, 243, 243, 0.78);
  margin: 0 0 12px;
  max-width: 640px;
  font-size: 16.5px;
  line-height: 1.6;
}

.hero-overlay .meta { margin: 0; color: rgba(243, 243, 243, 0.6); }

/* ---------- Карточки статей ---------- */

.article-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 36px;
  list-style: none;
  padding: 0;
  margin: 0;
  perspective: 1000px;
}

.card {
  position: relative;
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.35s var(--ease);
  transform-style: preserve-3d;
}

.card:hover {
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.10);
}

.card-thumb {
  aspect-ratio: 16 / 10;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.5s var(--ease);
  background:
    repeating-linear-gradient(135deg, rgba(0, 0, 0, 0.15) 0 12px, transparent 12px 24px),
    linear-gradient(160deg, #3c3c3c 0%, #0d0d0d 100%);
  position: relative;
  overflow: hidden;
}

.card:hover .card-thumb { transform: scale(1.03); }

.card-thumb .thumb-inner {
  width: 100%; height: 130%;
  display: flex; align-items: center; justify-content: center;
  will-change: transform;
}

.card-thumb svg {
  width: 64px;
  height: 64px;
  fill: none;
  stroke: #f0f0f0;
  stroke-width: 1.6;
  opacity: 0.92;
}

/* ---------- Кружок-стрелка "читать" ---------- */

.circle-arrow {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(var(--overlay-dark), 0.75);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  position: absolute;
  right: 14px;
  bottom: 14px;
  z-index: 2;
  transition: background 0.3s var(--ease);
}

.circle-arrow svg {
  position: relative;
  z-index: 1;
  width: 18px;
  height: 18px;
  fill: none;
  stroke: #fff;
  stroke-width: 2;
}

.card:hover .circle-arrow,
.hero-card:hover .circle-arrow {
  background: var(--accent);
}

.hero-card .circle-arrow {
  right: 32px;
  bottom: 26px;
  width: 52px;
  height: 52px;
}

.hero-card .circle-arrow svg { width: 20px; height: 20px; }

.card-body {
  padding: 26px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}

.card-meta-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 2px;
}

.card-title {
  font-size: 22px;
  text-transform: uppercase;
  line-height: 1.05;
}

.card-title a {
  color: var(--text);
  text-decoration: none;
  transition: color 0.3s var(--ease);
}

.card:hover .card-title a { color: var(--accent); }

.meta {
  font-size: 12.5px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.excerpt {
  color: var(--muted);
  margin: 0;
  font-size: 15.5px;
  font-weight: 400;
  line-height: 1.6;
}

/* ---------- Страница статьи ---------- */

article.post h1 { margin-bottom: 8px; }
article.post .meta { margin-bottom: 28px; }
article.post p { margin: 0 0 18px; }

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 36px;
  font-size: 15px;
  color: var(--accent);
  text-decoration: none;
  font-weight: 700;
  transition: color 0.25s ease, transform 0.25s ease;
}

.back-link:hover { color: var(--accent-2); transform: translateX(-4px); }

/* ---------- Подвал / контакты ---------- */

footer.site-footer {
  background: var(--bg-raised);
  border-top: 2px solid var(--text);
  margin-top: 56px;
  padding: 28px 0;
  font-size: 13px;
  color: var(--muted);
}

.footer-columns {
  display: flex;
  flex-direction: column;
  margin-bottom: 18px;
}

.contacts { margin-bottom: 0; }

.contacts-title {
  font-family: 'Oswald', Arial, sans-serif;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin: 0 0 10px;
  color: var(--text);
  font-size: 15px;
}

.contacts-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 24px;
}

.contacts-list li { font-size: 15px; display: flex; align-items: center; }

.contacts-list a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 700;
}

.contacts-list a:hover { color: var(--accent-2); }

.contacts-soon { color: var(--muted); font-style: italic; }

/* ---------- Иконки соцсетей ---------- */

.social-icon {
  position: relative;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1.5px solid var(--muted);
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.3s var(--ease), color 0.3s var(--ease);
}

.social-icon svg {
  position: relative;
  z-index: 1;
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: stroke 0.3s var(--ease);
}

.social-icon:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* ---------- Блок каналов: Telegram / MAX / Дзен ---------- */

.contacts-channels { margin-bottom: 0; }

.contacts {
  margin-top: 22px;
  padding-top: 22px;
  border-top: 1px solid var(--border);
}

.footer-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
  margin: 12px 0;
}

.footer-logo {
  height: 46px;
  width: auto;
}

.footer-quote {
  margin: 0;
  font-family: 'PT Sans', Arial, sans-serif;
  font-style: italic;
  font-size: 14px;
  line-height: 1.4;
  color: var(--muted);
  max-width: 260px;
}

@media (min-width: 641px) {
  .footer-columns {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 36px;
    align-items: center;
  }

  .footer-logo { height: 58px; }

  .contacts {
    margin-top: 0;
    padding-top: 0;
    border-top: none;
    text-align: right;
  }

  .contacts-list {
    justify-content: flex-end;
  }
}

.channels-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.channel-link {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 9px 18px 9px 14px;
  border: 1.5px solid var(--border);
  border-radius: 999px;
  color: var(--text);
  text-decoration: none;
  font-family: 'Oswald', Arial, sans-serif;
  font-weight: 700;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  transition: border-color 0.3s var(--ease), color 0.3s var(--ease), background-color 0.3s var(--ease);
}

.channel-link svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}

.channel-link:hover {
  border-color: var(--accent);
  color: var(--accent);
  background-color: rgba(var(--accent-rgb), 0.06);
}

/* ---------- Призыв подписаться в конце статьи ---------- */

.article-cta {
  margin-top: 40px;
  padding: 26px 28px;
  background: var(--bg-raised);
  border: 1.5px solid var(--text);
  border-radius: 4px;
}

.article-cta-text {
  margin: 0 0 16px;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.4;
}

@media (max-width: 640px) {
  .article-cta { padding: 20px 18px; }
  .article-cta-text { font-size: 15px; }
  .channel-link { font-size: 13px; padding: 8px 14px 8px 12px; }
}

.copyright { margin: 0; color: var(--muted); }

.legal-links { margin: 0; }
.legal-links a {
  color: var(--muted);
  text-decoration: underline;
  font-size: 12px;
  transition: color 0.25s ease;
}
.legal-links a:hover { color: var(--accent); }

.policy-todo {
  background: rgba(214, 0, 28, 0.12);
  color: var(--accent-2);
  padding: 1px 6px;
  border-radius: 3px;
  font-weight: 700;
}

.policy-page h2 { margin-top: 36px; margin-bottom: 12px; }
.policy-page p { margin: 0 0 16px; }
.policy-page ul { margin: 0 0 20px; padding-left: 22px; }
.policy-page ul li { margin-bottom: 8px; }

/* ---------- Плашка согласия на cookie ---------- */

.cookie-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 150;
  background: var(--bg-raised);
  border-top: 2px solid var(--text);
  padding: 16px 20px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 16px;
  transform: translateY(100%);
  opacity: 0;
  visibility: hidden;
  transition: transform 0.4s var(--ease), opacity 0.3s ease, visibility 0s linear 0.4s;
}

.cookie-banner.is-visible {
  transform: translateY(0);
  opacity: 1;
  visibility: visible;
  transition: transform 0.4s var(--ease), opacity 0.3s ease, visibility 0s linear 0s;
}

.cookie-banner p {
  margin: 0;
  font-size: 14px;
  color: var(--muted);
  max-width: 720px;
}

.cookie-banner p a {
  color: var(--accent);
  text-decoration: underline;
}

.cookie-banner p a:hover { color: var(--accent-2); }

.cookie-banner-ok {
  flex-shrink: 0;
  background: var(--text);
  color: #fff;
  border: none;
  padding: 10px 24px;
  font-family: 'Oswald', Arial, sans-serif;
  font-weight: 700;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.25s ease;
}

.cookie-banner-ok:hover { background: var(--accent); }

/* ---------- Адаптив под телефон ---------- */

@media (max-width: 640px) {
  body { font-size: 16px; }
  h1 { font-size: 30px; }
  .site-logo { height: 42px; }
  .wrap { padding: 18px 16px 48px; }
  .article-grid { grid-template-columns: 1fr; gap: 20px; }
  .card-title { font-size: 19px; }
  .hero-title { font-size: 24px; }
  .hero-overlay { padding: 20px 18px 18px; }
  .hero-excerpt { font-size: 14.5px; }
  .hero-thumb svg { width: 88px; height: 88px; }
  .mobile-nav-overlay { width: 86%; max-width: 86%; }
  .header-left { gap: 8px; }
  .header-ticker-track { gap: 18px; }
  .header-ticker-track a { font-size: 11px; }
  .category-nav { padding-left: 16px; padding-right: 16px; }
  .cookie-banner { flex-direction: column; align-items: stretch; text-align: center; padding: 16px; }
  .cookie-banner-ok { width: 100%; }
  .wrap { padding-bottom: 20px; }
  footer.site-footer { margin-top: 28px; }
  .contacts-channels { order: 1; }
  .contacts { order: 2; }
  .footer-brand { order: 3; }

}

/* ---------- Добавлено для автопубликации (реальные фото статей) ---------- */

.thumb-inner img,
.hero-thumb .thumb-inner img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.article-featured-image {
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 14px;
  margin: 18px 0 24px;
}

.article-featured-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.view-count {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-left: 10px;
  opacity: 0.65;
  font-size: 0.92em;
  vertical-align: middle;
}

.view-count svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  flex-shrink: 0;
}

.view-count-num:empty::before {
  content: "";
}

.empty-note {
  opacity: 0.7;
  padding: 24px 0;
}
