/*
Theme Name: DraCat
Theme URI: https://dracat.windchi.me
Author: Cignal / for Tatiana Lapshina
Description: Тема по ТЗ заказчицы — стартовая с триптихом + блог с шапкой, меню и сайдбаром.
Version: 0.4.15
Text Domain: dracat
*/

:root {
  --bg: #f4f2ee;
  --paper: #ffffff;
  --text: #1f1c1a;
  --muted: #5a534c;
  --border: #d9d2c8;
  --nav-bg: #ece8e2;
  --nav-text: #1f1c1a;
  --accent: #2f5d4a;
  --footer-bg: #2a2724;
  --footer-text: #d7d2cb;
  --ui: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --body: Georgia, "Times New Roman", Times, serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  line-height: 1.55;
}

a { color: #3d342c; }
a:hover { color: #111; }

img { max-width: 100%; height: auto; }

/* ===== Homepage (front-page) ===== */
body.home .site-shell,
body.page-template-front-page .site-shell { display: none; }
body.home .site-header,
body.page-template-front-page .site-header,
body.home .site-footer,
body.page-template-front-page .site-footer { display: none; }

.stage {
  min-height: 100dvh;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: clamp(16px, 3vh, 36px) clamp(12px, 3vw, 40px);
  gap: clamp(16px, 2.5vh, 28px);
}

.intro {
  text-align: center;
  font-family: var(--body);
  font-size: clamp(17px, 2vw, 22px);
  line-height: 1.5;
  color: var(--muted);
  max-width: 38em;
}

.intro p { margin: 0.18em 0; }

.gates {
  width: 100%;
  max-width: 1200px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: end;
  justify-items: center;
  gap: clamp(8px, 2vw, 32px);
}

.gates a {
  display: block;
  line-height: 0;
  width: min(100%, 280px);
  transform-origin: center bottom;
  animation: gate-in 0.85s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.gates a:nth-child(1) { animation-delay: 0.05s; }
.gates a:nth-child(2) { animation-delay: 0.18s; }
.gates a:nth-child(3) { animation-delay: 0.31s; }

.gates img {
  display: block;
  width: 100%;
  height: auto;
  border: 0;
  animation: gate-breathe 4.5s ease-in-out infinite;
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), filter 0.35s ease;
}

.gates a:nth-child(1) img { animation-delay: 0s; }
.gates a:nth-child(2) img { animation-delay: 0.55s; }
.gates a:nth-child(3) img { animation-delay: 1.1s; }

.gates a:hover img,
.gates a:focus-visible img {
  transform: translateY(-8px) scale(1.03);
  filter: drop-shadow(0 12px 18px rgba(0, 0, 0, 0.16));
  animation-play-state: paused;
}

.gates a:focus-visible {
  outline: 2px solid #666;
  outline-offset: 6px;
}

.quote { text-align: center; width: min(650px, 100%); }
.quote img { display: block; width: 100%; height: auto; margin: 0 auto; }

@keyframes gate-in {
  from { opacity: 0; transform: translateY(22px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes gate-breathe {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
}

@media (prefers-reduced-motion: reduce) {
  .gates a,
  .gates img { animation: none !important; transition: none !important; }
  .gates a:hover img,
  .gates a:focus-visible img { transform: none; filter: none; }
}

@media (max-width: 760px) {
  .stage {
    justify-content: flex-start;
    padding: 20px 10px 32px;
    gap: 14px;
  }
  .intro { font-size: clamp(13px, 3.6vw, 16px); max-width: 100%; }
  .gates {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(4px, 1.5vw, 12px);
    max-width: 100%;
  }
  .gates a { width: 100%; }
  .quote { width: min(100%, 420px); }
}

/* ===== Blog shell ===== */
.site-header {
  background: var(--paper);
}

.site-header__banner {
  position: relative;
  min-height: clamp(160px, 28vw, 280px);
  background: #2a2420 center / cover no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #fff;
}

.site-header__banner::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,.18), rgba(0,0,0,.42));
}

.site-branding {
  position: relative;
  z-index: 1;
  padding: 28px 20px;
}

.site-title {
  margin: 0;
  font-family: var(--ui);
  font-size: clamp(28px, 4.5vw, 46px);
  font-weight: 600;
  letter-spacing: 0.01em;
  line-height: 1.15;
  text-shadow: 0 1px 10px rgba(0,0,0,.35);
}

.site-title a {
  color: #fff;
  text-decoration: none;
}

.site-description {
  margin: 8px 0 0;
  font-family: var(--ui);
  font-size: 0.95rem;
  opacity: 0.92;
}

.custom-logo-link img {
  max-height: 96px;
  width: auto;
}

/* Nav */
.site-nav {
  background: var(--nav-bg);
  border-bottom: 1px solid var(--border);
}

.site-nav__inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 48px;
}

.nav-toggle {
  display: none;
  font-family: var(--ui);
  font-size: 14px;
  border: 1px solid var(--border);
  background: #fff;
  padding: 8px 12px;
  cursor: pointer;
}

.nav-search {
  margin-left: auto;
  font-size: 1.25rem;
  text-decoration: none;
  color: var(--nav-text);
  padding: 6px 4px;
  line-height: 1;
}

.primary-menu {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  font-family: var(--ui);
  font-size: 14px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.primary-menu > li {
  position: relative;
}

.primary-menu > li > a {
  display: block;
  padding: 14px 14px;
  color: var(--nav-text);
  text-decoration: none;
  white-space: nowrap;
}

.primary-menu > li > a:hover,
.primary-menu > li:hover > a,
.primary-menu > .current-menu-item > a {
  color: var(--accent);
}

.primary-menu .menu-item-has-children > a::after {
  content: " ▾";
  font-size: 0.75em;
  opacity: 0.7;
}

.primary-menu .sub-menu {
  list-style: none;
  margin: 0;
  padding: 6px 0;
  position: absolute;
  left: 0;
  top: 100%;
  min-width: 220px;
  background: #fff;
  border: 1px solid var(--border);
  box-shadow: 0 8px 20px rgba(0,0,0,.08);
  display: none;
  z-index: 20;
  text-transform: none;
  letter-spacing: 0;
  font-size: 14px;
}

.primary-menu .sub-menu .sub-menu {
  left: 100%;
  top: 0;
}

.primary-menu li:hover > .sub-menu,
.primary-menu li:focus-within > .sub-menu {
  display: block;
}

.primary-menu .sub-menu a {
  display: block;
  padding: 8px 14px;
  color: var(--text);
  text-decoration: none;
}

.primary-menu .sub-menu a:hover {
  background: #f3efe9;
  color: var(--accent);
}

/* Layout */
.layout {
  max-width: 1180px;
  margin: 0 auto;
  padding: 28px 20px 48px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 36px;
  align-items: start;
}

@media (max-width: 860px) {
  .layout { grid-template-columns: 1fr; }
  .nav-toggle { display: inline-block; }
  .primary-menu {
    display: none;
    width: 100%;
    flex-direction: column;
    text-transform: none;
    letter-spacing: 0;
    padding: 8px 0 16px;
  }
  .primary-menu.is-open { display: flex; }
  .site-nav__inner { flex-wrap: wrap; }
  .primary-menu .sub-menu {
    position: static;
    display: none;
    border: 0;
    box-shadow: none;
    padding-left: 14px;
    background: transparent;
  }
  .primary-menu li.is-open > .sub-menu { display: block; }
}

/* Entries: заголовок → дата → изображение → текст */
.entry {
  margin-bottom: 32px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--border);
}

.entry-title {
  font-family: var(--ui);
  font-size: clamp(1.35rem, 2.2vw, 1.75rem);
  margin: 0 0 6px;
  font-weight: 650;
  line-height: 1.25;
}

.entry-title a { text-decoration: none; color: inherit; }
.entry-title a:hover { color: var(--accent); }

.entry-date {
  margin: 0 0 12px;
  font-family: var(--ui);
  font-size: 0.88rem;
  color: var(--muted);
}

.entry-thumb {
  display: block;
  margin: 0 0 14px;
}

.entry-thumb__img,
.entry-thumb img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 420px;
  object-fit: contain;
  object-position: center top;
  background: #f0ebe4;
  border: 1px solid var(--border);
}

/* Первый / sticky: превью слева, текст справа (как в макете) */
.entry--featured .entry-body {
  display: grid;
  grid-template-columns: minmax(140px, 220px) minmax(0, 1fr);
  grid-template-areas:
    "thumb title"
    "thumb date"
    "thumb content"
    "thumb more"
    "thumb meta";
  column-gap: 20px;
  row-gap: 4px;
  align-items: start;
}

.entry--featured .entry-title { grid-area: title; margin: 0; }
.entry--featured .entry-date { grid-area: date; margin: 0; }
.entry--featured .entry-thumb {
  grid-area: thumb;
  margin: 0;
}
.entry--featured .entry-thumb__img,
.entry--featured .entry-thumb img {
  max-height: none;
  width: 100%;
  object-fit: cover;
  aspect-ratio: 3 / 4;
}
.entry--featured .entry-content { grid-area: content; }
.entry--featured .entry-more { grid-area: more; margin: 8px 0 0; }
.entry--featured .entry-meta { grid-area: meta; margin-top: 10px; }

@media (max-width: 640px) {
  .entry--featured .entry-body {
    grid-template-columns: 1fr;
    grid-template-areas:
      "title"
      "date"
      "thumb"
      "content"
      "more"
      "meta";
  }
  .entry--featured .entry-thumb {
    margin: 8px 0 12px;
  }
  .entry--featured .entry-thumb__img,
  .entry--featured .entry-thumb img {
    aspect-ratio: auto;
    max-height: 320px;
    object-fit: contain;
  }
}

.entry-single .entry-thumb img {
  max-height: none;
  object-fit: contain;
}

.entry-content { font-size: 1.02rem; }
.entry-content p:first-child { margin-top: 0; }

.entry-more {
  margin: 10px 0 0;
  font-family: var(--ui);
  font-size: 0.95rem;
}

.entry-more a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
}

.entry-more a:hover { text-decoration: underline; }

.entry-meta {
  font-family: var(--ui);
  font-size: 0.86rem;
  color: var(--muted);
  margin-top: 14px;
}

.entry-meta a { color: inherit; }

.navigation.pagination {
  font-family: var(--ui);
  margin-top: 8px;
}

.navigation.pagination .nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.navigation.pagination a,
.navigation.pagination span {
  display: inline-block;
  padding: 6px 10px;
  border: 1px solid var(--border);
  background: #fff;
  text-decoration: none;
}

.navigation.pagination .current {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

/* Sidebar — блоки с жирной чертой над заголовком */
.sidebar {
  --sidebar-rule: #2a2724;
  font-family: var(--ui);
  font-size: 0.92rem;
}

.sidebar-stack,
.sidebar-split__col {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.widget {
  margin: 0;
  padding: 14px 0 18px;
  border: 0;
  border-top: 4px solid var(--sidebar-rule);
}

.widget-title {
  font-family: var(--ui);
  font-size: 0.92rem;
  margin: 0 0 12px;
  padding: 0;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text);
  border: 0;
}

.widget ul {
  margin: 0;
  padding-left: 1.1em;
}

.widget ul ul { margin-top: 4px; }

.widget li { margin: 0.25em 0; }

.widget a { text-decoration: underline; text-underline-offset: 2px; }

.widget_search .search-form {
  display: flex;
  gap: 6px;
  align-items: stretch;
}

.widget_search .search-form > label {
  flex: 1;
  min-width: 0;
  margin: 0;
}

.widget_search .screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.widget_search input[type="search"] {
  display: block;
  width: 100%;
  min-width: 0;
  padding: 8px 10px;
  border: 1px solid #bdb6ad;
  font: inherit;
  background: #fff;
}

.widget_search input[type="submit"] {
  padding: 8px 14px;
  border: 0;
  background: #3d5a40;
  color: #fff;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

/* Закладки — облако: топ-20, размер по числу записей */
.widget_tag_cloud .tagcloud {
  line-height: 1.65;
}

.bookmarks-cloud {
  line-height: 1.7;
  font-family: var(--ui);
  text-align: left;
  word-wrap: break-word;
}

.bookmarks-cloud .tag-cloud-link {
  display: inline-block;
  margin: 0 7px 2px 0;
  color: #3d342c;
  text-decoration: none;
  vertical-align: baseline;
  transition: color 140ms ease;
}

.bookmarks-cloud .tag-cloud-link:hover {
  color: var(--accent);
  text-decoration: underline;
}

.tagcloud-more {
  margin: 10px 0 0;
  font-size: 0.82rem;
}

.tagcloud-more a {
  text-decoration: underline;
}

.archive-header {
  margin-bottom: 28px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border);
}

.archive-title {
  font-family: var(--ui);
  font-size: clamp(1.4rem, 2.4vw, 1.85rem);
  margin: 0 0 12px;
  line-height: 1.25;
}

.entry--category-feature {
  margin: 0 0 36px;
  padding-bottom: 28px;
  border-bottom: 3px solid var(--sidebar-rule, #2a2724);
}

.entry--category-feature .entry-title {
  font-size: 1.55rem;
}

.entry--category-feature .entry-title a {
  text-decoration: none;
}

.entry--category-feature .entry-title a:hover {
  text-decoration: underline;
}

.archive-description,
.term-description {
  font-size: 1.02rem;
}

.archive-description img,
.term-description img {
  max-width: 100%;
  height: auto;
}

/* Юзерпики 1:1 как upics.htm — без ужимания картинок темой */
body.page-template-page-upics .layout,
body.page-slug-upics .layout {
  display: block;
  max-width: none;
  padding: 16px 8px 40px;
}

body.page-template-page-upics .content,
body.page-slug-upics .content {
  max-width: none;
}

body.page-template-page-upics .entry-upics-exact,
body.page-slug-upics .entry-upics-exact {
  border-bottom: 0;
  margin: 0;
  padding: 0;
}

body.page-template-page-upics .upics-exact-content,
body.page-slug-upics .upics-exact-content {
  max-width: none;
  overflow-x: auto;
}

body.page-template-page-upics .upics-exact-content img,
body.page-slug-upics .upics-exact-content img {
  max-width: none;
  height: auto;
}

.popular-posts {
  margin: 0;
  padding-left: 1.25em;
}

.popular-posts li { margin: 0.55em 0; }
.popular-posts a {
  color: #2b6cb0;
  text-decoration: underline;
}
.popular-posts time {
  display: block;
  margin-top: 2px;
  font-size: 0.8rem;
  font-style: italic;
  color: #7a8794;
}

/* Нижняя зона: 2 колонки × 2 ряда (Промо|Вишлист, Донаты|HTML) */
.sidebar-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 16px;
  align-items: start;
}

.sidebar-split .widget {
  border-top: 4px solid var(--sidebar-rule);
  padding: 12px 0 16px;
}

.sidebar-split .widget-title {
  font-size: 0.82rem;
}

.sidebar img {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 0 auto;
}

.sidebar .textwidget,
.sidebar .custom-html-widget {
  line-height: 1.4;
  text-align: center;
}

/* Внутренние разделители внутри Промо (как на примере) */
.sidebar .textwidget hr,
.sidebar .custom-html-widget hr {
  border: 0;
  border-top: 4px solid var(--sidebar-rule);
  margin: 14px 0;
  height: 0;
}

.sidebar .custom-html {
  margin: 0;
  padding: 12px 10px;
  background: #f0ebe4;
  border: 1px dashed #bdb6ad;
  font-size: 0.78rem;
  text-align: left;
  word-break: break-word;
}

#vk_groups {
  max-width: 100% !important;
}

/* Footer */
.site-footer {
  background: var(--footer-bg);
  color: var(--footer-text);
  padding: 18px 20px;
  font-family: var(--ui);
  font-size: 0.88rem;
}

.site-footer__inner {
  max-width: 1180px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 12px 20px;
  justify-content: space-between;
  align-items: center;
}

.site-footer a {
  color: var(--footer-text);
  text-decoration: none;
}

.site-footer a:hover { text-decoration: underline; }

.site-footer__license {
  margin: 0;
}

.cc-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--footer-text);
  text-decoration: none !important;
  opacity: 0.92;
  transition: opacity 160ms ease;
}

.cc-badge:hover,
.cc-badge:focus-visible {
  opacity: 1;
  outline: none;
}

.cc-badge__icons {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  line-height: 0;
}

.cc-badge__icons .cc-mark {
  display: block;
  flex-shrink: 0;
}

.cc-badge__label {
  font-family: var(--ui);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  line-height: 1;
  white-space: nowrap;
}

.site-footer__links,
.site-footer__social {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
}

.site-footer__social {
  margin-left: auto;
}

.footer-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 4px;
  color: var(--footer-text);
  line-height: 0;
  text-decoration: none !important;
  opacity: 0.92;
  transition: background 160ms ease, opacity 160ms ease, border-color 160ms ease;
}

.footer-ico svg {
  display: block;
  flex-shrink: 0;
}

.footer-ico:hover,
.footer-ico:focus-visible {
  opacity: 1;
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.45);
  outline: none;
}

.footer-ico--mail {
  width: auto;
  padding: 0 12px 0 10px;
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0;
}

.footer-ico__text {
  line-height: 1;
}
/* Плагин cookies дублирует ссылку на политику сразу под футером — прячем только её */
body > p.privacy-policy {
  display: none !important;
}

/* Плагин privacy дублирует текст согласия после кнопки «Отправить» */
.comment-form .form-submit + p {
  display: none !important;
}

/* ===== Комментарии / форма отзыва ===== */
.comments-area {
  margin-top: 40px;
  padding-top: 28px;
  border-top: 1px solid var(--border);
  font-family: var(--ui);
}

.comments-title,
.comment-reply-title {
  margin: 0 0 18px;
  font-family: var(--body);
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text);
}

.comment-reply-title small.cancel-reply {
  margin-left: 10px;
  font-size: 0.85rem;
  font-weight: 500;
  font-family: var(--ui);
}

.comment-list {
  list-style: none;
  margin: 0 0 28px;
  padding: 0;
}

.comment-list .children {
  list-style: none;
  margin: 14px 0 0;
  padding: 0 0 0 18px;
  border-left: 2px solid var(--border);
}

.comment-body {
  padding: 14px 0 16px;
  border-bottom: 1px solid var(--border);
}

.comment-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  margin-bottom: 8px;
}

.comment-author {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.95rem;
}

.comment-author .avatar {
  border-radius: 50%;
  display: block;
}

.comment-author .fn {
  font-style: normal;
  font-weight: 650;
}

.comment-metadata {
  font-size: 0.8rem;
  color: var(--muted);
}

.comment-metadata a {
  color: var(--muted);
  text-decoration: none;
}

.comment-metadata a:hover {
  color: var(--accent);
  text-decoration: underline;
}

.comment-content {
  font-family: var(--body);
  font-size: 1rem;
  line-height: 1.55;
}

.comment-content p:last-child {
  margin-bottom: 0;
}

.comment-awaiting-moderation {
  margin: 0 0 8px;
  font-size: 0.88rem;
  color: var(--muted);
  font-style: italic;
}

.reply {
  margin-top: 8px;
  font-size: 0.85rem;
}

.reply a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
}

.reply a:hover {
  text-decoration: underline;
}

.comment-respond {
  margin-top: 8px;
  padding: 22px 22px 20px;
  background: #faf8f5;
  border: 1px solid var(--border);
  border-radius: 6px;
}

.comment-form .logged-in-as {
  margin: 0 0 16px;
  font-size: 0.88rem;
  color: var(--muted);
  line-height: 1.45;
}

.comment-form .logged-in-as a {
  color: var(--accent);
  text-decoration: none;
}

.comment-form .logged-in-as a:hover {
  text-decoration: underline;
}

.comment-form p {
  margin: 0 0 14px;
}

.comment-form label {
  display: block;
  margin: 0 0 6px;
  font-size: 0.82rem;
  font-weight: 650;
  letter-spacing: 0.02em;
  color: var(--muted);
}

.comment-form .required {
  color: #8a4a3a;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
  display: block;
  width: 100%;
  max-width: 100%;
  padding: 11px 12px;
  border: 1px solid var(--border);
  border-radius: 5px;
  background: #fff;
  color: var(--text);
  font-family: var(--ui);
  font-size: 0.95rem;
  line-height: 1.4;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

.comment-form textarea {
  min-height: 140px;
  resize: vertical;
  font-family: var(--body);
  line-height: 1.5;
}

.comment-form input:focus,
.comment-form textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(47, 93, 74, 0.15);
}

.comment-form-author,
.comment-form-email,
.comment-form-url {
  max-width: 420px;
}

@media (min-width: 720px) {
  .comment-form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 16px;
  }

  .comment-form .comment-notes,
  .comment-form .logged-in-as,
  .comment-form-comment,
  .comment-form-pdn,
  .comment-form .form-submit,
  .comment-form .comment-form-cookies-consent {
    grid-column: 1 / -1;
  }

  .comment-form-url {
    grid-column: 1 / -1;
    max-width: 420px;
  }
}

.comment-form-pdn__label {
  display: flex !important;
  align-items: flex-start;
  gap: 10px;
  margin: 0 !important;
  font-weight: 500 !important;
  letter-spacing: 0 !important;
  color: var(--text) !important;
  font-size: 0.86rem !important;
  line-height: 1.45;
  cursor: pointer;
}

.comment-form-pdn input[type="checkbox"] {
  flex-shrink: 0;
  width: 16px;
  height: 16px;
  margin: 2px 0 0;
  accent-color: var(--accent);
}

.comment-form-pdn__text a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.comment-form .form-submit {
  margin: 4px 0 0;
}

.comment-submit {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 22px;
  border: 0;
  border-radius: 5px;
  background: var(--accent);
  color: #fff;
  font-family: var(--ui);
  font-size: 0.92rem;
  font-weight: 650;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: background 150ms ease, transform 150ms ease;
}

.comment-submit:hover {
  background: #254a3c;
}

.comment-submit:active {
  transform: translateY(1px);
}

.comment-submit:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.no-comments {
  color: var(--muted);
  font-style: italic;
}

@media (max-width: 640px) {
  .site-footer__inner { flex-direction: column; align-items: flex-start; }
  .site-footer__social { margin-left: 0; }
  .sidebar-split { grid-template-columns: 1fr; }
}

/* ===== /tags/ — на всю ширину, без сайдбара (как на исходнике) ===== */
body.page-template-page-tags .layout,
body.page-template-full-width-page .layout,
body.page-slug-tags .layout {
  grid-template-columns: 1fr;
  max-width: 1180px;
}

body.page-template-page-tags .content,
body.page-template-full-width-page .content,
body.page-slug-tags .content {
  max-width: none;
  width: 100%;
}

body.page-template-page-tags .sidebar,
body.page-template-full-width-page .sidebar,
body.page-slug-tags .sidebar {
  display: none !important;
}

/* ===== /tags/ — алфавитная карта тегов ===== */
.mctagmap {
  display: flex;
  flex-wrap: wrap;
  gap: 20px 24px;
  align-items: flex-start;
  margin: 1.25rem 0 2rem;
  font-family: var(--ui);
  width: 100%;
}

.mctagmap__group {
  flex: 1 1 200px;
  min-width: 180px;
  max-width: 260px;
}

body.page-template-page-tags .mctagmap__group,
body.page-template-full-width-page .mctagmap__group,
body.page-slug-tags .mctagmap__group {
  flex: 0 0 220px;
  max-width: 220px;
}

.mctagmap__letter {
  margin: 0 0 8px;
  padding-bottom: 4px;
  border-bottom: 2px solid #2a2724;
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.2;
}

.mctagmap__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.mctagmap__item {
  margin: 0.2em 0;
  font-size: 0.92rem;
  line-height: 1.35;
}

.mctagmap__item a {
  text-decoration: none;
  color: #2b6cb0;
}

.mctagmap__item a:hover {
  text-decoration: underline;
}

.mctagmap__count {
  color: var(--muted);
  font-size: 0.85em;
}

.mctagmap__divider {
  color: #999;
  margin: 0 2px;
}

.mctagmap__desc {
  color: var(--muted);
  font-size: 0.85em;
}

.mctagmap__item--hidden {
  display: none;
}

.mctagmap__list.is-open .mctagmap__item--hidden {
  display: list-item;
}

.mctagmap__more {
  margin-top: 6px;
  list-style: none;
}

.mctagmap__toggle {
  border: 0;
  background: none;
  padding: 0;
  color: var(--accent);
  font: inherit;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: underline;
}

.mctagmap__toggle:hover {
  color: #1f1c1a;
}

@media (max-width: 700px) {
  .mctagmap__group {
    flex: 1 1 100%;
    max-width: none;
  }
}

/* ===== Юзерпики — галерея ===== */
.upics-page {
  font-family: var(--ui);
}

.upics-lead {
  margin: 0 0 1.25rem;
  color: var(--muted);
  font-size: 1.05rem;
  max-width: 42em;
}

.upics-toc {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 10px;
  margin: 0 0 2rem;
  padding: 14px 0 16px;
  border-top: 4px solid #2a2724;
  border-bottom: 1px solid var(--border);
}

.upics-toc a {
  display: inline-block;
  padding: 6px 10px;
  background: #efeae3;
  color: #2a2724;
  text-decoration: none;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.upics-toc a:hover {
  background: #2f5d4a;
  color: #fff;
}

.upics-section {
  margin: 0 0 2.5rem;
  padding-top: 0.5rem;
}

.upics-section__title {
  margin: 0 0 1rem;
  padding-bottom: 8px;
  border-bottom: 4px solid #2a2724;
  font-family: var(--ui);
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.upics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 14px 12px;
  align-items: start;
}

.upics-card {
  margin: 0;
  background: #fff;
  border: 1px solid var(--border);
  padding: 8px;
}

.upics-card__link {
  display: block;
  line-height: 0;
  background: #f3efe9;
}

.upics-card img {
  display: block;
  width: 100%;
  height: 140px;
  object-fit: contain;
  object-position: center;
}

.upics-card figcaption {
  margin-top: 8px;
  font-size: 0.75rem;
  line-height: 1.35;
  color: var(--muted);
  text-align: center;
}

@media (min-width: 900px) {
  .upics-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  }
  .upics-card img { height: 160px; }
}

.dracat-qr { display: inline-block; line-height: 0; }
.dracat-qr img { display: block; border: 1px solid var(--border); background: #fff; padding: 6px; }
