/* ОбзорКниг — минималистичная тема. Мобильная вёрстка, без JS, быстрая. */

:root {
  --bg: #fdfcf9;
  --text: #26221c;
  --muted: #7a7264;
  --accent: #8b5a2b;
  --accent-light: #f3e9dc;
  --card-bg: #ffffff;
  --border: #e8e2d6;
  --radius: 10px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1b1917;
    --text: #e8e2d8;
    --muted: #a39a8b;
    --accent: #d9a05b;
    --accent-light: #2b241c;
    --card-bg: #24211d;
    --border: #3a352e;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.65 Georgia, "Times New Roman", serif;
}

.container {
  max-width: 760px;
  margin: 0 auto;
  padding: 0 18px;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

.muted { color: var(--muted); }
.small { font-size: 0.85rem; }

/* Шапка */
.site-header {
  border-bottom: 1px solid var(--border);
  background: var(--card-bg);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 14px;
  padding-bottom: 14px;
}
.logo {
  font-size: 1.25rem;
  font-weight: bold;
  color: var(--text);
}
.logo:hover { text-decoration: none; }
.main-nav {
  display: flex;
  gap: 16px;
  font-family: system-ui, sans-serif;
  font-size: 0.95rem;
}

/* Герой на главной */
.hero { padding: 34px 0 10px; }
.hero h1 { font-size: 1.7rem; line-height: 1.3; margin: 0 0 12px; }
.lead { color: var(--muted); font-size: 1.05rem; }

/* Секции и карточки */
.section-title { margin: 34px 0 14px; font-size: 1.35rem; }
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 14px;
}
.card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 18px;
}
.card-title { margin: 0 0 6px; font-size: 1.1rem; line-height: 1.35; }
.card-text { margin: 8px 0 0; font-size: 0.95rem; }

/* Страница поста */
.page-header { padding-top: 26px; }
.post { padding-top: 22px; }
.post-header h1 { font-size: 1.75rem; line-height: 1.3; margin: 6px 0 8px; }
.book-meta { font-size: 1.02rem; color: var(--muted); }
.rating { color: var(--accent); font-weight: bold; }

.breadcrumbs {
  font-family: system-ui, sans-serif;
  font-size: 0.85rem;
  color: var(--muted);
  margin-bottom: 14px;
}
.breadcrumbs .sep { margin: 0 6px; }

.content h2 { font-size: 1.3rem; margin: 30px 0 10px; }
.content h3 { font-size: 1.15rem; margin: 24px 0 8px; }
.content img { max-width: 100%; height: auto; border-radius: 6px; }
.content blockquote {
  margin: 18px 0;
  padding: 12px 18px;
  border-left: 3px solid var(--accent);
  background: var(--accent-light);
  border-radius: 0 var(--radius) var(--radius) 0;
}
.content ul, .content ol { padding-left: 24px; }
.content li { margin-bottom: 6px; }

.tags {
  margin-top: 26px;
  font-family: system-ui, sans-serif;
  font-size: 0.9rem;
}
.tag {
  display: inline-block;
  background: var(--accent-light);
  border-radius: 20px;
  padding: 2px 12px;
  margin: 2px 4px 2px 0;
}
.tag:hover { text-decoration: none; opacity: 0.8; }

.related { margin-top: 40px; border-top: 1px solid var(--border); padding-top: 10px; }

/* Таксономии */
.terms { list-style: none; padding: 0; font-size: 1.1rem; }
.terms li { margin-bottom: 10px; }

/* Пагинация */
.pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin: 28px 0;
  font-family: system-ui, sans-serif;
}
.pagination a, .pagination span {
  padding: 6px 12px;
  border: 1px solid var(--border);
  border-radius: 6px;
}

/* 404 и подвал */
.not-found { padding: 60px 18px; text-align: center; }
.btn {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  padding: 10px 22px;
  border-radius: 8px;
}
.btn:hover { text-decoration: none; opacity: 0.9; }

.site-footer {
  margin-top: 50px;
  border-top: 1px solid var(--border);
  padding: 22px 0 30px;
  font-family: system-ui, sans-serif;
  font-size: 0.9rem;
  color: var(--muted);
}

@media (max-width: 600px) {
  .cards { grid-template-columns: 1fr; }
  .main-nav { gap: 12px; }
}
