/* PPCNews — светлый стиль в духе отраслевых медиа (sostav-like) */
:root {
  --bg: #ffffff;
  --bg-soft: #fafafa;
  --bg-muted: #f7f3f2;
  --ink: #010101;
  --ink-2: #222222;
  --muted: #777777;
  --muted-2: #999999;
  --line: #e8e8e8;
  --line-2: #f0f0f0;
  --accent: #fe0002;
  --accent-hover: #d40002;
  --accent-soft: #fff1f1;
  --max: 1200px;
  --font: "PT Sans", Calibri, "San Francisco", Arial, sans-serif;
}

* { box-sizing: border-box; }
html { font-size: 18px; }
body.site {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  line-height: 1.45;
}

a { color: var(--ink); }
a:hover { color: var(--accent); }

.wrap { width: min(100% - 2rem, var(--max)); margin-inline: auto; }

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  min-height: 64px;
  padding: .65rem 0;
}
.logo {
  font-family: var(--font);
  font-weight: 700;
  font-size: 1.55rem;
  letter-spacing: -0.02em;
  color: var(--accent) !important;
  text-decoration: none;
  line-height: 1;
}
.logo:hover { color: var(--accent-hover) !important; }
.nav {
  display: flex;
  align-items: center;
  gap: 1.15rem;
  flex-wrap: wrap;
}
.nav a {
  text-decoration: none;
  color: var(--ink);
  font-size: .95rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .02em;
}
.nav a:hover,
.nav a.is-active { color: var(--accent); }
.nav-cta {
  background: var(--accent) !important;
  color: #fff !important;
  padding: .45rem .85rem !important;
  border-radius: .25rem;
  text-transform: uppercase;
  font-size: .82rem !important;
}
.nav-cta:hover { background: var(--accent-hover) !important; color: #fff !important; }
.nav-toggle {
  display: none;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  font: inherit;
  padding: .35rem .7rem;
  cursor: pointer;
}

.site-main { flex: 1; padding: 1.25rem 0 3rem; }

/* Home 3-col */
.home-grid {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr) 260px;
  gap: 1.5rem;
  align-items: start;
}

.home-lenta {
  border-right: 1px solid var(--line);
  padding-right: 1rem;
}
.lenta-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: .85rem;
  gap: .5rem;
}
.lenta-head h2,
.side-title,
.block-title {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 700;
}
.lenta-all,
.side-more {
  color: var(--accent);
  text-decoration: none;
  font-size: .9rem;
  font-weight: 700;
  white-space: nowrap;
}
.lenta-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.lenta-list li {
  border-bottom: 1px solid var(--line-2);
}
.lenta-list a {
  display: grid;
  gap: .2rem;
  padding: .7rem 0;
  text-decoration: none;
  color: inherit;
}
.lenta-list time {
  color: var(--muted-2);
  font-size: .78rem;
}
.lenta-list span {
  font-size: .95rem;
  line-height: 1.3;
  font-weight: 400;
}
.lenta-list a:hover span { color: var(--accent); }

.rubric {
  display: inline-block;
  color: var(--accent);
  font-size: .78rem;
  font-weight: 700;
  text-transform: lowercase;
  letter-spacing: .01em;
  margin-bottom: .25rem;
}

/* Hero */
.hero-story {
  display: block;
  text-decoration: none;
  color: inherit;
  margin-bottom: 1.25rem;
  border: 1px solid var(--line);
  overflow: hidden;
  background: var(--bg-muted);
  min-height: 280px;
  position: relative;
}
.hero-story.has-cover {
  background:
    linear-gradient(180deg, rgba(0,0,0,.15) 0%, rgba(0,0,0,.72) 100%),
    var(--hero-img) center/cover no-repeat;
  color: #fff;
}
.hero-story-body {
  padding: 1.35rem 1.4rem 1.5rem;
  max-width: 42rem;
  position: relative;
  z-index: 1;
}
.hero-story.has-cover .rubric { color: #ffb3b3; }
.hero-story h1 {
  margin: .15rem 0 .55rem;
  font-size: clamp(1.45rem, 2.6vw, 2rem);
  line-height: 1.15;
  font-weight: 700;
}
.hero-story p {
  margin: 0;
  color: var(--muted);
  font-size: 1rem;
  max-width: 38rem;
}
.hero-story.has-cover p { color: rgba(255,255,255,.88); }
.hero-story:hover h1 { color: var(--accent); }
.hero-story.has-cover:hover h1 { color: #fff; text-decoration: underline; }

/* Feed rows */
.feed-stack { display: grid; gap: 0; }
.feed-row {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 1rem;
  padding: 1rem 0;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
  color: inherit;
}
.feed-row:first-child { border-top: 1px solid var(--line); }
.feed-thumb {
  width: 180px;
  height: 118px;
  overflow: hidden;
  background: var(--bg-muted);
  flex-shrink: 0;
}
.feed-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.feed-thumb.is-placeholder {
  display: grid;
  place-items: center;
  color: var(--accent);
  font-size: 2rem;
  font-weight: 700;
  border: 1px solid var(--line);
}
.feed-body { min-width: 0; }
.feed-body h2 {
  margin: 0 0 .35rem;
  font-size: 1.15rem;
  line-height: 1.25;
  font-weight: 700;
}
.feed-body p {
  margin: 0 0 .4rem;
  color: var(--muted);
  font-size: .95rem;
  line-height: 1.35;
}
.feed-body time {
  color: var(--muted-2);
  font-size: .8rem;
}
.feed-row:hover h2 { color: var(--accent); }

/* Side */
.home-side { display: grid; gap: 1.1rem; }
.side-block {
  border: 1px solid var(--line);
  padding: 1rem;
  background: var(--bg);
}
.side-cats,
.side-list,
.topic-list {
  list-style: none;
  margin: .75rem 0 0;
  padding: 0;
}
.side-cats li { border-bottom: 1px solid var(--line-2); }
.side-cats a {
  display: block;
  padding: .55rem 0;
  text-decoration: none;
  font-weight: 700;
}
.side-list li { padding: .65rem 0; border-bottom: 1px solid var(--line-2); }
.side-list a { text-decoration: none; display: grid; gap: .15rem; }
.side-list strong {
  font-size: .95rem;
  font-weight: 700;
  line-height: 1.25;
}
.side-list a:hover strong { color: var(--accent); }
.side-more { display: inline-block; margin-top: .75rem; }
.side-promo {
  background: var(--bg-muted);
  border: 1px solid var(--line);
  padding: 1rem;
}
.side-promo p { margin: .35rem 0 .85rem; color: var(--ink-2); font-size: .95rem; }
.btn-red {
  display: inline-block;
  background: var(--accent);
  color: #fff !important;
  text-decoration: none;
  padding: .5rem .9rem;
  border-radius: .25rem;
  font-weight: 700;
  font-size: .9rem;
}
.btn-red:hover { background: var(--accent-hover); }

.topics-section { margin-top: 2.5rem; padding-top: 1.5rem; border-top: 1px solid var(--line); }
.topics-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
  margin-top: 1rem;
}
.topic-col { border-top: 2px solid var(--accent); padding-top: .75rem; }
.topic-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: .75rem;
  margin-bottom: .5rem;
}
.topic-head h3 { margin: 0; font-size: 1.05rem; }
.topic-head a { color: var(--accent); text-decoration: none; font-size: .9rem; font-weight: 700; }
.topic-list li { border-bottom: 1px solid var(--line-2); }
.topic-list a {
  display: block;
  padding: .55rem 0;
  text-decoration: none;
  font-size: .95rem;
  line-height: 1.3;
}
.topic-list a:hover { color: var(--accent); }

.empty-state {
  color: var(--muted);
  border: 1px dashed var(--line);
  padding: 1rem 1.15rem;
  background: var(--bg-soft);
}
.empty-state.compact { font-size: .9rem; padding: .75rem; }

/* Lists on inner pages */
.page-header { margin-bottom: 1.25rem; }
.page-header h1 {
  margin: 0 0 .5rem;
  font-size: clamp(1.6rem, 3vw, 2.1rem);
  line-height: 1.15;
}
.page-header .lead { color: var(--muted); max-width: 40rem; margin: 0; }

.article-list { list-style: none; padding: 0; margin: 0; }
.article-list li { border-bottom: 1px solid var(--line); }
.article-list a {
  display: block;
  padding: .9rem 0;
  text-decoration: none;
  color: inherit;
}
.article-list .meta {
  display: block;
  color: var(--muted-2);
  font-size: .8rem;
  margin-bottom: .2rem;
}
.article-list strong {
  font-size: 1.1rem;
  line-height: 1.3;
  font-weight: 700;
}
.article-list a:hover strong { color: var(--accent); }

.category-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(12rem, 1fr));
  gap: .65rem;
}
.category-list a {
  display: block;
  padding: .85rem 1rem;
  border: 1px solid var(--line);
  text-decoration: none;
  font-weight: 700;
  background: var(--bg-soft);
}
.category-list a:hover { border-color: var(--accent); color: var(--accent); }

/* Article */
.article-page { max-width: 46rem; }
.breadcrumbs {
  font-size: .9rem;
  color: var(--muted);
  display: flex;
  gap: .45rem;
  margin-bottom: 1rem;
}
.breadcrumbs a { color: var(--muted); text-decoration: none; }
.breadcrumbs a:hover { color: var(--accent); }
.article-header .meta {
  color: var(--muted);
  font-size: .9rem;
  margin: 0 0 .65rem;
}
.article-header .meta a { color: var(--accent); text-decoration: none; font-weight: 700; }
.article-header h1 {
  margin: 0 0 .85rem;
  font-size: clamp(1.7rem, 3.4vw, 2.35rem);
  line-height: 1.15;
}
.article-lead {
  font-size: 1.1rem;
  color: var(--ink-2);
  max-width: 40rem;
  margin: 0;
}
.article-cover { margin: 1.35rem 0 1.75rem; }
.article-cover img {
  width: 100%;
  height: auto;
  display: block;
  border: 1px solid var(--line);
}
.cover-credit {
  margin: .4rem 0 0;
  font-size: .8rem;
  color: var(--muted-2);
}
.cover-credit a {
  color: var(--muted);
  text-decoration: none;
}
.cover-credit a:hover { color: var(--accent); }

.prose { max-width: 40rem; font-size: 1.05rem; }
.prose h2, .prose h3 {
  margin: 1.7rem 0 .7rem;
  line-height: 1.25;
  font-weight: 700;
}
.prose p { margin: 0 0 1rem; }
.prose ul, .prose ol { margin: 0 0 1rem; padding-left: 1.25rem; }
.prose li { margin-bottom: .35rem; }
.prose a { color: var(--accent); }
.prose blockquote {
  margin: 1.25rem 0;
  padding: .15rem 0 .15rem 1rem;
  border-left: 3px solid var(--accent);
  color: var(--muted);
}
.prose .table-wrap {
  width: 100%;
  overflow-x: auto;
  margin: 0 0 1.25rem;
  -webkit-overflow-scrolling: touch;
}
.prose table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 1.25rem;
  font-size: .95rem;
  line-height: 1.35;
  background: #fff;
  border: 1px solid var(--line);
}
.prose thead th {
  background: var(--bg-muted);
  color: var(--ink);
  font-weight: 700;
  text-align: left;
  border-bottom: 2px solid var(--accent);
}
.prose th,
.prose td {
  padding: .65rem .75rem;
  border: 1px solid var(--line);
  vertical-align: top;
}
.prose tbody tr:nth-child(even) td {
  background: var(--bg-soft);
}
.prose tbody tr:hover td {
  background: var(--accent-soft);
}

.editorial-box {
  margin: 2rem 0;
  padding: 1.1rem 1.25rem;
  background: var(--accent-soft);
  border-left: 4px solid var(--accent);
}
.editorial-box h2 { margin: 0 0 .6rem; font-size: 1.1rem; }
.takeaways ul { padding-left: 1.2rem; }
.article-toc {
  margin: 0 0 1.75rem;
  padding: 1rem 1.15rem;
  background: var(--bg-soft, #f6f6f6);
  border-left: 3px solid var(--accent);
}
.article-toc-title {
  margin: 0 0 .5rem;
  font-weight: 700;
  font-size: .95rem;
}
.article-toc ol {
  margin: 0;
  padding-left: 1.2rem;
}
.article-toc li { margin: .25rem 0; }
.article-toc a {
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid transparent;
}
.article-toc a:hover { border-bottom-color: var(--accent); color: var(--accent); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-q {
  width: 100%;
  text-align: left;
  background: none;
  border: 0;
  padding: 1rem 0;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  color: var(--ink);
  list-style: none;
}
.faq-q::-webkit-details-marker { display: none; }
.faq-item[open] .faq-q { color: var(--accent); }
.faq-a { padding: 0 0 1rem; color: var(--muted); line-height: 1.55; }
.sources ul { list-style: none; padding: 0; }
.sources a { color: var(--muted); font-size: .95rem; }
.tags { display: flex; flex-wrap: wrap; gap: .5rem; margin: 2rem 0; }
.tag {
  color: var(--accent);
  text-decoration: none;
  font-size: .9rem;
  font-weight: 700;
  border-bottom: 1px solid rgba(254, 0, 2, .35);
}
.update-note {
  background: #fff8e8;
  border: 1px solid #f0e0b8;
  padding: 1rem 1.15rem;
  margin: 1rem 0 1.4rem;
}
.pagination { display: flex; gap: .4rem; margin-top: 1.75rem; }
.pagination a, .pagination .current {
  padding: .35rem .65rem;
  text-decoration: none;
  border: 1px solid var(--line);
  color: var(--ink);
}
.pagination .current {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  font-weight: 700;
}
.pagination a:hover { border-color: var(--accent); color: var(--accent); }

/* Footer */
.site-footer {
  margin-top: auto;
  border-top: 1px solid var(--line);
  background: var(--bg-soft);
  padding: 2.25rem 0 1.25rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}
.footer-brand p { color: var(--muted); margin: .6rem 0; max-width: 28rem; }
.footer-meta { font-size: .9rem; }
.footer-label {
  display: block;
  color: var(--muted-2);
  font-size: .78rem;
  text-transform: uppercase;
  letter-spacing: .06em;
  font-weight: 700;
  margin-bottom: .55rem;
}
.footer-nav { display: grid; gap: .4rem; align-content: start; }
.footer-nav a { text-decoration: none; color: var(--ink-2); }
.footer-nav a:hover { color: var(--accent); }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  padding-top: .9rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: .85rem;
}

.error-page h1 { margin-top: 0; }
.btn-danger {
  font-family: var(--font);
  background: #b91c1c;
  color: #fff;
  border: 0;
  padding: .75rem 1.25rem;
  cursor: pointer;
  font-size: 1rem;
}
.btn-danger:hover { background: #991b1b; }
[x-cloak] { display: none !important; }

@media (max-width: 1100px) {
  .home-grid { grid-template-columns: 210px minmax(0, 1fr); }
  .home-side { display: none; }
}
@media (max-width: 820px) {
  .home-grid { grid-template-columns: 1fr; }
  .home-lenta {
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding-right: 0;
    padding-bottom: 1rem;
  }
  .lenta-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 1rem;
  }
  .topics-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  html { font-size: 17px; }
  .nav-toggle { display: inline-flex; }
  .nav {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: flex-start;
    padding: .35rem 0 .15rem;
  }
  .nav.is-open { display: flex; }
  .header-inner { flex-wrap: wrap; }
  .feed-row { grid-template-columns: 110px minmax(0, 1fr); gap: .75rem; }
  .feed-thumb { width: 110px; height: 78px; }
  .lenta-list { grid-template-columns: 1fr; }
  .hero-story { min-height: 220px; }
}
