/* ============================================================
   Spektr Locator — стили раздела «Статьи» (поверх styles.css)
   Классы соответствуют разметке генератора (статьи/*.html)
   и сборщика каталога (статьи/index.html).
   ============================================================ */

/* ---------- Каталог статей ---------- */
.art-page { padding: 40px 0 60px; }
.art-h1 {
  font-size: clamp(28px, 5vw, 46px);
  line-height: 1.1;
  margin: 8px 0 20px;
}
.art-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 28px 0 38px;
}
.art-tabs a {
  display: inline-flex;
  align-items: center;
  padding: 10px 18px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: var(--paper);
  font-weight: 600;
  font-size: 14px;
  transition: 0.18s;
}
.art-tabs a:hover { border-color: var(--navy-600); }

.art-section { margin-bottom: 52px; }
.art-h2 {
  font-family: var(--font-display);
  font-size: clamp(22px, 3vw, 30px);
  margin-bottom: 24px;
}
.art-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
@media (max-width: 900px) { .art-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .art-grid { grid-template-columns: 1fr; } }

.art-card {
  display: flex;
  flex-direction: column;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.22s, box-shadow 0.22s;
}
.art-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-sm);
}
.art-thumb {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--bg-soft);
}
.art-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.art-thumb-null {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  font-size: 34px;
}
.art-body { display: flex; flex-direction: column; flex: 1; padding: 18px 20px 20px; }
.art-meta {
  font-size: 12px; font-weight: 800;
  letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--red); margin-bottom: 8px;
}
.art-meta.control { color: var(--navy-600); }
.art-title {
  font-family: var(--font-display);
  font-size: 16px; font-weight: 700; line-height: 1.3; margin-bottom: 8px;
}
.art-desc { font-size: 14px; color: var(--muted); flex: 1; }
.art-badges { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0 8px; }
.art-badge {
  display: inline-block; font-size: 11px; font-weight: 800;
  letter-spacing: 0.02em; padding: 3px 9px; border-radius: 999px;
}
.art-badge-len { background: rgba(46, 204, 113, 0.14); color: #1e8a4f; }
.art-badge-img { background: rgba(241, 196, 15, 0.16); color: #a07c06; }
.art-badge-date { background: rgba(52, 152, 219, 0.2); color: #1565c0; font-size: 12px; padding: 4px 10px; }

/* ---------- Layout: sidebar + content ---------- */
.art-layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 36px;
  align-items: start;
}
@media (max-width: 900px) {
  .art-layout { grid-template-columns: 1fr; }
  .art-sidebar { position: static !important; }
}

.art-sidebar {
  position: sticky;
  top: 90px;
  max-height: calc(100vh - 110px);
  overflow-y: auto;
}
.art-sidebar-inner {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px 0;
}
.art-sidebar-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 15px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 0 20px 14px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 8px;
}
.art-sidebar-nav {
  display: flex;
  flex-direction: column;
}
.art-sidebar-link {
  display: block;
  padding: 11px 20px;
  font-size: 14px;
  font-weight: 600;
  color: var(--navy-900);
  text-decoration: none;
  border-left: 3px solid transparent;
  transition: 0.15s;
}
.art-sidebar-link:hover,
.art-sidebar-link.active {
  background: var(--bg-soft);
  border-left-color: var(--red);
  color: var(--red);
}

/* ---------- Страница статьи ---------- */
.article-page { padding: 40px 0 60px; }
.a-article { max-width: 800px; margin: 0 auto; }
.a-header { margin-bottom: 26px; }
.a-cat {
  display: inline-block;
  font-size: 12px; font-weight: 800;
  letter-spacing: 0.06em; text-transform: uppercase;
  padding: 6px 12px; border-radius: 999px;
  background: var(--grad-soft); color: var(--red);
  margin-bottom: 14px;
}
.a-cat.control { background: rgba(52, 152, 219, 0.12); color: #1f6aa5; }
.a-cat.bullying { background: rgba(231, 76, 60, 0.12); color: var(--red); }
.a-header h1 {
  font-size: clamp(26px, 4.6vw, 40px);
  line-height: 1.14; margin-bottom: 16px;
}
.a-intro { font-size: 18px; color: var(--muted); line-height: 1.6; margin-bottom: 22px; }
.a-date {
  font-size: 13px; color: var(--muted);
  letter-spacing: 0.03em; margin: -6px 0 16px;
}
.a-date time { font-weight: 600; color: var(--navy-900); }
.a-hero {
  width: 100%; border-radius: var(--radius);
  box-shadow: var(--shadow-sm); margin-top: 8px;
}

.a-block { margin-bottom: 30px; }
.a-block h3 {
  font-size: 23px; margin: 0 0 14px;
  font-family: var(--font-display); color: var(--navy-900);
}
.a-block p { margin-bottom: 16px; }
.a-block ul, .a-block ol { margin: 0 0 18px 22px; }
.a-block li { margin-bottom: 8px; }
.a-block strong { font-weight: 800; }
.a-block a { color: var(--red); text-decoration: underline; }

.a-conclusion {
  background: var(--navy-900);
  color: #fff;
  border-radius: var(--radius);
  padding: 26px 30px;
}
.a-conclusion h3 { color: #fff; }
.a-conclusion li { color: rgba(255, 255, 255, 0.92); }

.a-cta {
  background: linear-gradient(135deg, #ffce5a, #ffe9b8);
  border: 1px solid #f0b429;
  border-radius: var(--radius);
  padding: 28px 30px;
  margin-top: 34px;
}
.a-cta h3 { font-family: var(--font-display); font-size: 22px; margin-bottom: 10px; color: var(--navy-900); }
.a-cta p { margin-bottom: 10px; color: var(--navy-900); }
.a-cta a { color: var(--red); font-weight: 800; text-decoration: underline; }

.a-back { margin-top: 36px; text-align: center; }
.a-back a {
  display: inline-block;
  font-weight: 700; color: var(--red);
  padding: 12px 24px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--paper);
  transition: 0.18s;
}
.a-back a:hover { background: var(--yellow); border-color: var(--yellow); color: var(--navy-900); }

@media (max-width: 620px) {
  .a-block p { font-size: 16.5px; }
  .a-intro { font-size: 17px; }
}
