/*
Theme Name: Термопанели Конструктор
Theme URI: https://example.com/termopaneli-konstruktor
Author: ТермопанелиКонструктор
Author URI: https://example.com
Description: Тема WordPress с интерактивным онлайн-конструктором фасада: 3 проекта дома, процедурные фактуры термопанелей, полный каталог цветов RAL Classic, расчёт материалов и спецификация, раздел партнёров с карточкой генерального партнёра. Поддерживает настройку через «Внешний вид → Настроить» и шорткод [termopaneli_konstruktor].
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: termopaneli-konstruktor
Tags: business, portfolio, custom-colors, custom-logo, custom-menu, featured-images, full-width-template, block-styles, wide-blocks, translation-ready
*/

/*
  Основные стили приложения лежат в assets/app.css (Tailwind, собирается из исходников).
  Этот файл нужен WordPress для распознавания темы и содержит только базовые правила
  для обычных страниц и записей.
*/

:root {
  --tpk-ink: #1c1917;
  --tpk-muted: #78716c;
  --tpk-line: #e7e5e4;
  --tpk-accent: #059669;
}

html {
  scroll-behavior: smooth;
}

body.tpk-body {
  margin: 0;
  background: #f5f5f4;
  color: var(--tpk-ink);
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

/* Служебные классы WordPress (требования темы) */
.screen-reader-text {
  border: 0;
  clip: rect(1px, 1px, 1px, 1px);
  clip-path: inset(50%);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  width: 1px;
  word-wrap: normal !important;
}

.screen-reader-text:focus {
  background-color: #fff;
  border-radius: 3px;
  box-shadow: 0 0 2px 2px rgba(0, 0, 0, 0.6);
  clip: auto !important;
  clip-path: none;
  color: #1c1917;
  display: block;
  font-size: 14px;
  font-weight: 700;
  height: auto;
  left: 5px;
  line-height: normal;
  padding: 15px 23px 14px;
  text-decoration: none;
  top: 5px;
  width: auto;
  z-index: 100000;
}

.alignleft { float: left; margin-right: 1.5rem; }
.alignright { float: right; margin-left: 1.5rem; }
.aligncenter { display: block; margin-left: auto; margin-right: auto; }
.alignwide { max-width: 1100px; }
.alignfull { max-width: none; }

.tpk-content img { max-width: 100%; height: auto; }
.tpk-content h1, .tpk-content h2, .tpk-content h3 { font-weight: 700; line-height: 1.25; }
.tpk-content h1 { font-size: 2rem; margin: 0 0 1rem; }
.tpk-content h2 { font-size: 1.5rem; margin: 2rem 0 .75rem; }
.tpk-content h3 { font-size: 1.2rem; margin: 1.5rem 0 .5rem; }
.tpk-content p, .tpk-content ul, .tpk-content ol { line-height: 1.7; margin: 0 0 1rem; }
.tpk-content a { color: var(--tpk-accent); }
.tpk-content blockquote {
  border-left: 3px solid var(--tpk-accent);
  margin: 1.5rem 0;
  padding: .25rem 0 .25rem 1rem;
  color: var(--tpk-muted);
}
.tpk-content table { border-collapse: collapse; width: 100%; }
.tpk-content th, .tpk-content td { border: 1px solid var(--tpk-line); padding: .5rem .75rem; text-align: left; }
.tpk-content code, .tpk-content pre { background: #f5f5f4; border-radius: 6px; }
.tpk-content pre { padding: 1rem; overflow: auto; }

/* =========================================================================
   Текстовый блок главной страницы (индексируемый контент)
   ====================================================================== */

.tpk-seo {
  background: #fff;
  border-top: 1px solid var(--tpk-line);
}

.tpk-seo__inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 48px 20px 64px;
}

.tpk-seo__eyebrow {
  margin: 0 0 10px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--tpk-muted);
}

.tpk-seo__title {
  margin: 0 0 16px;
  font-size: clamp(26px, 4vw, 40px);
  line-height: 1.18;
  letter-spacing: -.02em;
  font-weight: 800;
  color: var(--tpk-ink);
}

.tpk-seo__lead {
  margin: 0 0 22px;
  max-width: 74ch;
  font-size: 16px;
  line-height: 1.7;
  color: #44403c;
}

.tpk-seo__stats {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 22px;
  padding: 0;
  list-style: none;
}
.tpk-seo__stats li {
  display: flex;
  flex-direction: column;
  min-width: 132px;
  padding: 12px 16px;
  border: 1px solid var(--tpk-line);
  border-radius: 14px;
  background: #fafaf9;
}
.tpk-seo__stats b { font-size: 22px; font-weight: 800; line-height: 1; }
.tpk-seo__stats span { margin-top: 4px; font-size: 12px; color: var(--tpk-muted); }

.tpk-seo__cta { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 8px; }

.tpk-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid #d6d3d1;
  border-radius: 12px;
  padding: 11px 18px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  color: var(--tpk-ink);
  background: #fff;
  transition: border-color .15s, background .15s;
}
.tpk-btn:hover { border-color: #a8a29e; background: #fafaf9; }
.tpk-btn--dark { background: var(--tpk-ink); border-color: var(--tpk-ink); color: #fff; }
.tpk-btn--dark:hover { background: #292524; }

.tpk-seo h2 {
  margin: 44px 0 14px;
  font-size: clamp(20px, 2.6vw, 26px);
  font-weight: 800;
  letter-spacing: -.01em;
}
.tpk-seo h3 { margin: 0 0 6px; font-size: 15px; font-weight: 700; }
.tpk-seo p { max-width: 78ch; line-height: 1.7; color: #44403c; }

.tpk-grid { display: grid; gap: 14px; }
.tpk-grid--3 { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.tpk-grid article {
  border: 1px solid var(--tpk-line);
  border-radius: 16px;
  padding: 18px;
  background: #fafaf9;
}
.tpk-grid article p { margin: 0; font-size: 13.5px; }

.tpk-list { max-width: 78ch; padding-left: 20px; line-height: 1.9; color: #44403c; }
.tpk-list b { color: var(--tpk-ink); }

.tpk-steps {
  counter-reset: tpkstep;
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 12px;
}
.tpk-steps li {
  counter-increment: tpkstep;
  position: relative;
  border: 1px solid var(--tpk-line);
  border-radius: 14px;
  padding: 16px 18px 16px 60px;
  background: #fafaf9;
}
.tpk-steps li::before {
  content: counter(tpkstep);
  position: absolute;
  left: 16px;
  top: 16px;
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: var(--tpk-ink);
  color: #fff;
  font-size: 13px;
  font-weight: 800;
}
.tpk-steps p { margin: 0; font-size: 13.5px; }

.tpk-seo__note {
  border-left: 3px solid var(--tpk-accent);
  padding: 4px 0 4px 16px;
  font-size: 15px;
  color: #292524;
}

.tpk-faq { display: grid; gap: 8px; max-width: 900px; }
.tpk-faq details {
  border: 1px solid var(--tpk-line);
  border-radius: 14px;
  background: #fafaf9;
  padding: 4px 16px;
}
.tpk-faq summary {
  cursor: pointer;
  list-style: none;
  padding: 12px 0;
  display: flex;
  align-items: center;
  gap: 10px;
}
.tpk-faq summary::-webkit-details-marker { display: none; }
.tpk-faq summary::after {
  content: '+';
  margin-left: auto;
  font-size: 18px;
  color: var(--tpk-muted);
}
.tpk-faq details[open] summary::after { content: '−'; }
.tpk-faq summary h3 { margin: 0; font-size: 14.5px; }
.tpk-faq details p { margin: 0 0 14px; font-size: 13.5px; }

.tpk-seo__small { font-size: 12.5px; color: var(--tpk-muted); }

.tpk-breadcrumbs a:hover { color: var(--tpk-ink); }

@media (max-width: 640px) {
  .tpk-seo__inner { padding: 32px 16px 48px; }
  .tpk-seo__stats li { min-width: calc(50% - 5px); }
}

/* =========================================================================
   Полоса и кнопка генерального партнёра
   ====================================================================== */

.tpk-partner-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 4px 10px;
  padding: 9px 16px;
  background: var(--tpk-ink);
  color: #fff;
  text-decoration: none;
  font-size: 12.5px;
  text-align: center;
  transition: background .15s;
}
.tpk-partner-bar:hover { background: #292524; }
.tpk-partner-bar__badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: #10b981;
  color: #0c0a09;
  padding: 2px 9px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.tpk-partner-bar b { font-weight: 800; }
.tpk-partner-bar__desc { color: rgba(255, 255, 255, .6); }
.tpk-partner-bar__link { color: #6ee7b7; font-weight: 700; }
.tpk-partner-bar:hover .tpk-partner-bar__link { text-decoration: underline; }

.tpk-partner-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--tpk-ink);
  border-radius: 12px;
  background: var(--tpk-ink);
  color: #fff;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  transition: background .15s;
}
.tpk-partner-btn:hover { background: #292524; }
.tpk-partner-btn span { color: #6ee7b7; }

/* Меню */
.tpk-menu {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 2px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.tpk-menu li { margin: 0; }
.tpk-menu a {
  display: inline-block;
  padding: 7px 11px;
  border-radius: 9px;
  color: #44403c;
  text-decoration: none;
  font-size: 14px;
  transition: background .15s, color .15s;
}
.tpk-menu a:hover { background: #f5f5f4; color: var(--tpk-ink); }
.tpk-menu__partner { font-weight: 700; color: var(--tpk-accent) !important; }

@media (max-width: 640px) {
  .tpk-partner-bar__desc { display: none; }
}

/* Фото партнёра в текстовом блоке */
.tpk-partner-photo { margin: 0 0 18px; max-width: 460px; }
.tpk-partner-photo img { display: block; width: 100%; height: auto; border-radius: 16px; }
.tpk-partner-photo figcaption { margin-top: 8px; font-size: 12px; color: var(--tpk-muted); }
