/* ==================================================
   ekb.postroymat.ru — фирменное оформление ПСТ
   палитра жёлтый #F5B100 + графит #2B2B2B (по design-spec founder)
   Montserrat 400-900
   ================================================== */

:root {
  --pst-dark:       #2B2B2B;
  --pst-dark-2:     #3a3a3a;
  --pst-yellow:     #F5B100;
  --pst-yellow-h:   #ffc726;
  --pst-yellow-soft:#fff4d6;
  --pst-text:       #1a1a1a;
  --pst-muted:      #6e6e74;
  --pst-bg:         #f7f8fa;
  --pst-border:     #e3e3e7;
  --pst-radius:     10px;
  --pst-radius-lg:  16px;
}

/* Typography */
body, .entry-content, .post-content {
  font-family: 'Montserrat', -apple-system, BlinkMacSystemFont, sans-serif !important;
  color: var(--pst-text);
}
h1, h2, h3, h4, h5, .wp-block-heading {
  font-family: 'Montserrat', sans-serif !important;
  font-weight: 800;
  color: var(--pst-dark);
  letter-spacing: -0.01em;
}

/* =========== HEADER (две вариации) =========== */

/* Базовая структура */
.ekb-header {
  position: sticky;
  top: 0;
  z-index: 999;
}
.ekb-header__in {
  max-width: 1280px;
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  gap: 24px;
}

/* Лого — никаких filter + пропорции сохраняются */
.ekb-logo { display: inline-flex; align-items: center; }
.ekb-logo img {
  filter: none !important;
  max-width: none !important;
  width: auto !important;
  height: 56px;
  display: block;
  aspect-ratio: 1079 / 380;
}
@media (max-width: 768px) {
  .ekb-logo img { height: 44px !important; }
}
@media (max-width: 480px) {
  .ekb-logo img { height: 38px !important; }
}

/* ВАРИАНТ A: ТЁМНАЯ-полупрозрачная шапка (главная, над hero) */
.ekb-header--transparent {
  background: rgba(43,43,43,.78);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border-bottom: 3px solid var(--pst-yellow);
  color: #fff;
}
.ekb-header--transparent .ekb-nav a { color: #fff; }
.ekb-header--transparent .ekb-nav a:hover { color: var(--pst-yellow); }
.ekb-header--transparent .ekb-tel { color: var(--pst-yellow) !important; }
.ekb-header--transparent .ekb-cta--secondary { color: #fff !important; border-color: var(--pst-yellow); }
.ekb-header--transparent .ekb-cta--secondary:hover { background: var(--pst-yellow); color: var(--pst-dark) !important; border-color: var(--pst-yellow); }
.ekb-header--transparent .ekb-burger i { background: #fff; }

/* ВАРИАНТ B: СВЕТЛАЯ шапка (внутренние страницы) */
.ekb-header--light {
  background: #fff;
  border-bottom: 3px solid var(--pst-yellow);
  color: var(--pst-dark);
  box-shadow: 0 2px 12px rgba(43,43,43,.06);
}
.ekb-header--light .ekb-nav a { color: var(--pst-dark); }
.ekb-header--light .ekb-nav a:hover { color: var(--pst-yellow); }
.ekb-header--light .ekb-tel { color: var(--pst-dark) !important; }
.ekb-header--light .ekb-cta--secondary { color: var(--pst-dark) !important; border-color: var(--pst-dark); }
.ekb-header--light .ekb-cta--secondary:hover { background: var(--pst-dark); color: #fff !important; }
.ekb-header--light .ekb-burger i { background: var(--pst-dark); }

/* Общие элементы nav */
.ekb-nav { display: flex; gap: 22px; margin-left: 20px; flex: 1; }
.ekb-nav a {
  font-weight: 700;
  text-decoration: none;
  font-size: 14.5px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  white-space: nowrap;
  transition: color .15s;
}
.ekb-header__right {
  display: flex;
  align-items: center;
  gap: 12px;
}
.ekb-tel {
  font-weight: 800;
  text-decoration: none;
  font-size: 15px;
  white-space: nowrap;
}
.ekb-tel--big { font-size: 1.6em; }
.ekb-cta {
  background: var(--pst-yellow);
  color: var(--pst-dark) !important;
  font-weight: 800;
  padding: 10px 20px;
  border-radius: 8px;
  text-decoration: none;
  transition: .15s;
  display: inline-block;
  font-family: 'Montserrat', sans-serif;
  font-size: 14px;
  white-space: nowrap;
}
.ekb-cta:hover { background: var(--pst-yellow-h); transform: translateY(-1px); }
.ekb-cta--secondary { background: transparent; color: var(--pst-dark) !important; border: 2px solid var(--pst-dark); padding: 8px 18px; }
.ekb-cta--secondary:hover { background: var(--pst-dark); color: #fff !important; }
.ekb-cta--lg { padding: 16px 32px; font-size: 16px; }
.ekb-cta--ghost-lg { background: transparent; color: #fff !important; border: 2px solid var(--pst-yellow); padding: 14px 30px; font-size: 16px; }
.ekb-cta--ghost-lg:hover { background: var(--pst-yellow); color: var(--pst-dark) !important; }
.ekb-cta--block { display: block; width: 100%; text-align: center; }

/* Burger */
.ekb-burger {
  display: none;
  width: 40px; height: 40px;
  background: transparent;
  border: 0;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  padding: 0;
  cursor: pointer;
}
.ekb-burger i {
  display: block;
  width: 22px; height: 2px;
  background: var(--pst-dark);
  border-radius: 2px;
}

/* Mobile drawer */
.ekb-drawer { position: fixed; inset: 0; z-index: 1000; visibility: hidden; }
.ekb-drawer.open { visibility: visible; }
.ekb-drawer__overlay { position: absolute; inset: 0; background: rgba(43,43,43,.55); opacity: 0; transition: .25s; }
.ekb-drawer.open .ekb-drawer__overlay { opacity: 1; }
.ekb-drawer__panel {
  position: absolute; top: 0; right: 0; height: 100%;
  width: 300px; max-width: 86vw;
  background: #2B2B2B !important;  /* непрозрачный графит — НЕ налезает текст hero */
  color: #fff;
  transform: translateX(100%);
  transition: .26s cubic-bezier(.4,0,.2,1);
  display: flex; flex-direction: column;
  padding: 24px 20px; gap: 14px;
  z-index: 2;
  opacity: 1 !important;
  box-shadow: -8px 0 24px rgba(0,0,0,.4);
}
.ekb-drawer.open .ekb-drawer__panel { transform: translateX(0); }
.ekb-drawer__close {
  align-self: flex-end;
  width: 40px; height: 40px;
  background: transparent; border: 2px solid var(--pst-yellow); border-radius: 8px;
  color: var(--pst-yellow); font-size: 18px; cursor: pointer;
}
.ekb-drawer__nav { display: flex; flex-direction: column; gap: 4px; margin-top: 10px; }
.ekb-drawer__nav a { color: #fff; text-decoration: none; padding: 12px 8px; border-radius: 8px; font-weight: 700; font-size: 16px; }
.ekb-drawer__nav a:hover { background: var(--pst-dark-2); color: var(--pst-yellow); }

/* =========== HERO (с фото-фоном) =========== */
.ekb-hero {
  background:
    linear-gradient(120deg, rgba(43,43,43,.85) 0%, rgba(43,43,43,.55) 60%, rgba(43,43,43,.30) 100%),
    url('/wp-content/uploads/branding/hero-spec-1.png') center/cover no-repeat,
    var(--pst-dark);
  color: #fff;
  padding: 140px 24px 90px;  /* +50px сверху чтобы прозрачная шапка не наплывала */
  position: relative;
  overflow: hidden;
  min-height: 560px;
  margin-top: -88px;  /* hero под прозрачной шапкой */
  z-index: 1;
}
.ekb-hero::after {
  content: ""; position: absolute; right: -100px; top: -100px;
  width: 400px; height: 400px; border-radius: 50%;
  background: radial-gradient(circle, rgba(245,177,0,.30), transparent 70%);
  pointer-events: none;
}
.ekb-hero__in { max-width: 1280px; margin: 0 auto; position: relative; z-index: 2; }
.ekb-eyebrow {
  display: inline-block;
  font-size: 12.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--pst-yellow);
  background: rgba(245,177,0,.12);
  padding: 6px 14px;
  border-radius: 99px;
  margin-bottom: 18px;
}
.ekb-eyebrow.on-dark { background: rgba(245,177,0,.18); }
.ekb-hero h1 {
  color: #fff !important;
  font-size: clamp(28px, 5vw, 52px);
  line-height: 1.08;
  margin: 0 0 18px;
  font-weight: 900;
  max-width: 920px;
}
.ekb-hero p {
  color: #d0d0d4;
  font-size: 1.1em;
  max-width: 760px;
  margin: 0 0 28px;
  line-height: 1.55;
}
.ekb-hero__btns { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 40px; }
.ekb-hero__feats { display: grid; grid-template-columns: repeat(4,1fr); gap: 28px; max-width: 880px; }
.ekb-hero__feats > div { display: flex; flex-direction: column; }
.ekb-hero__feats b { font-size: 1.95em; color: var(--pst-yellow); font-weight: 900; line-height: 1; }
.ekb-hero__feats span { font-size: .9em; color: #c7cbd3; margin-top: 6px; }

/* =========== SECTION HEADS =========== */
.ekb-sec-head { margin-bottom: 36px; max-width: 760px; }
.ekb-sec-head h2 {
  font-size: clamp(24px, 3vw, 36px);
  line-height: 1.15;
  margin: 12px 0 10px;
  font-weight: 800;
  color: var(--pst-dark);
  position: relative;
  padding-bottom: 14px;
}
.ekb-sec-head h2::after {
  content: ""; position: absolute; left: 0; bottom: 0;
  width: 70px; height: 4px; background: var(--pst-yellow); border-radius: 2px;
}
.ekb-sec-head p { color: var(--pst-muted); font-size: 1em; line-height: 1.55; }

/* =========== CATALOG =========== */
.ekb-catalog { background: var(--pst-bg); padding: 70px 24px; }
.ekb-catalog__in { max-width: 1280px; margin: 0 auto; }
.ekb-catalog__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.ekb-cat-card {
  background: #fff;
  border: 1px solid var(--pst-border);
  border-radius: var(--pst-radius-lg);
  padding: 24px 22px;
  text-decoration: none;
  color: var(--pst-text);
  transition: .2s;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.ekb-cat-card:hover {
  border-color: var(--pst-yellow);
  transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(43,43,43,.08);
}
.ekb-cat-card__icon { font-size: 32px; margin-bottom: 4px; }
.ekb-cat-card h3 { font-size: 16px; font-weight: 700; margin: 0; color: var(--pst-dark); }
.ekb-cat-card__price { color: var(--pst-yellow); font-weight: 800; font-size: 15px; margin-top: auto; }
.ekb-cat-card__cta { color: var(--pst-muted); font-size: 13px; font-weight: 600; }

.ekb-catalog__geo { margin-top: 50px; padding-top: 40px; border-top: 1px solid var(--pst-border); }
.ekb-catalog__geo-grid { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 18px; }
.ekb-geo-card {
  background: #fff;
  border: 1px solid var(--pst-border);
  border-radius: var(--pst-radius);
  padding: 14px 24px;
  text-decoration: none;
  color: var(--pst-dark);
  font-weight: 700;
  font-size: 15px;
  transition: .15s;
}
.ekb-geo-card:hover { background: var(--pst-yellow); color: var(--pst-dark); border-color: var(--pst-yellow); }

/* =========== ABOUT / FEATURES =========== */
.ekb-about { padding: 80px 24px; background: #fff; }
.ekb-about__in { max-width: 1280px; margin: 0 auto; }
.ekb-about__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.ekb-feat {
  background: var(--pst-bg);
  border-radius: var(--pst-radius-lg);
  padding: 28px;
  border-left: 4px solid var(--pst-yellow);
}
.ekb-feat__n {
  font-weight: 900;
  font-size: 14px;
  color: var(--pst-yellow);
  background: var(--pst-yellow-soft);
  padding: 4px 10px;
  border-radius: 4px;
  display: inline-block;
  margin-bottom: 12px;
}
.ekb-feat h3 { font-size: 18px; margin-bottom: 8px; color: var(--pst-dark); }
.ekb-feat p { color: var(--pst-muted); font-size: 14.5px; line-height: 1.55; margin: 0; }

/* =========== CTA SECTION (form) =========== */
.ekb-cta-section { background: var(--pst-dark); color: #fff; padding: 70px 24px; }
.ekb-cta-section__in {
  max-width: 1100px; margin: 0 auto;
  display: grid; grid-template-columns: 1fr 1fr; gap: 50px;
  align-items: center;
}
.ekb-cta-section__t h2 { color: #fff !important; font-size: clamp(24px,3vw,34px); margin: 12px 0 14px; }
.ekb-cta-section__t h2::after { background: var(--pst-yellow); }
.ekb-cta-section__t p { color: #d0d0d4; font-size: 1.05em; line-height: 1.55; }
.ekb-cta-section__form {
  background: #fff;
  border-radius: var(--pst-radius-lg);
  padding: 32px;
  color: var(--pst-text);
}

/* CF7 styling */
.ekb-cta-section .wpcf7 form p,
.ekb-cta-section .wpcf7 form label { color: var(--pst-text); margin: 0 0 14px; display: block; }
.ekb-cta-section .wpcf7 form input,
.ekb-cta-section .wpcf7 form textarea,
.ekb-cta-section .wpcf7 form select {
  width: 100% !important;
  max-width: 100% !important;
  box-sizing: border-box !important;
  font-size: 16px;
  padding: 12px 14px;
  border: 1px solid var(--pst-border);
  border-radius: 8px;
  font-family: inherit;
}
.ekb-cta-section .wpcf7 form input:focus,
.ekb-cta-section .wpcf7 form textarea:focus { outline: none; border-color: var(--pst-yellow); }
.ekb-cta-section .wpcf7 form input[type="submit"],
.ekb-cta-section .wpcf7-submit {
  background: var(--pst-yellow) !important;
  color: var(--pst-dark) !important;
  border: 0 !important;
  font-weight: 800 !important;
  padding: 14px 28px !important;
  cursor: pointer;
  font-family: 'Montserrat', sans-serif !important;
}
.ekb-cta-section .wpcf7 form input[type="submit"]:hover { background: var(--pst-yellow-h) !important; }
.ekb-cta-section .wpcf7-response-output {
  margin: 10px 0 0 !important;
  padding: 10px 14px !important;
  border-radius: 8px !important;
}

/* =========== CONTACTS =========== */
.ekb-contacts { background: var(--pst-bg); padding: 70px 24px; }
.ekb-contacts__in { max-width: 1280px; margin: 0 auto; }
.ekb-contacts__grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 24px; }
.ekb-contact-card {
  background: #fff;
  border: 1px solid var(--pst-border);
  border-radius: var(--pst-radius-lg);
  padding: 28px;
}
.ekb-contact-card h3 { font-size: 14px; text-transform: uppercase; color: var(--pst-muted); font-weight: 700; letter-spacing: 0.08em; margin-bottom: 14px; }
.ekb-contact-card .ekb-tel { display: block; margin-bottom: 8px; }
.ekb-contact-card p { color: var(--pst-muted); font-size: 14px; line-height: 1.55; margin: 0; }

/* =========== FOOTER =========== */
.ekb-footer { background: var(--pst-dark); color: #c7cbd3; padding: 50px 24px 22px; margin-top: 60px; }
.ekb-footer__in {
  max-width: 1280px; margin: 0 auto;
  display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 36px;
}
.ekb-footer .ekb-logo img { height: 56px; }
.ekb-footer__col h5 { color: #fff; font-size: 14px; font-weight: 800; margin-bottom: 14px; text-transform: uppercase; letter-spacing: 0.08em; }
.ekb-footer__col a { color: #c7cbd3; text-decoration: none; display: block; margin-bottom: 8px; font-size: 14.5px; transition: .15s; }
.ekb-footer__col a:hover { color: var(--pst-yellow); }
.ekb-footer__col p { color: #8a8e96; font-size: 14px; margin: 6px 0; }
.ekb-footer__col .ekb-cta { color: var(--pst-dark) !important; margin-top: 8px; display: inline-block; }
.ekb-footer__col .ekb-tel--big { font-size: 1.4em; color: var(--pst-yellow) !important; }
.ekb-footer__bot {
  max-width: 1280px; margin: 30px auto 0;
  padding-top: 22px;
  border-top: 1px solid #3a3a3a;
  display: flex; justify-content: space-between;
  color: #8a8e96; font-size: 13px; flex-wrap: wrap; gap: 12px;
}

/* =========== Hide old brand-headcta if mu-plugin still active =========== */
.brand-headcta { display: none !important; }
/* Hide Kadence default header/footer to avoid duplicates */
#wrapper > header.site-header,
.site-footer,
#colophon { display: none !important; }

/* =========== Mobile =========== */
@media (max-width: 1024px) {
  .ekb-nav { display: none; }
  .ekb-burger { display: flex; }
  .ekb-cta--secondary { display: none; }
}
@media (max-width: 768px) {
  .ekb-header__in { padding: 10px 16px; gap: 10px; }
  .ekb-cta { padding: 8px 14px; font-size: 13px; }
  .ekb-hero { padding: 50px 18px 50px; }
  .ekb-hero__feats { grid-template-columns: repeat(2,1fr); gap: 22px; }
  .ekb-catalog__grid { grid-template-columns: repeat(2,1fr); }
  .ekb-about__grid { grid-template-columns: repeat(2,1fr); }
  .ekb-cta-section__in { grid-template-columns: 1fr; }
  .ekb-contacts__grid { grid-template-columns: 1fr; }
  .ekb-footer__in { grid-template-columns: 1fr 1fr; gap: 24px; }
}
@media (max-width: 480px) {
  .ekb-tel:not(.ekb-tel--big) { display: none; }
  .ekb-hero__feats { grid-template-columns: 1fr 1fr; }
  .ekb-catalog__grid { grid-template-columns: 1fr; }
  .ekb-about__grid { grid-template-columns: 1fr; }
  .ekb-footer__in { grid-template-columns: 1fr; }
}

/* ============ ПОПАП «Рассчитать стоимость» ============ */
.ekbpm-modal {
  position: fixed; inset: 0; z-index: 10000;
  visibility: hidden; opacity: 0;
  transition: opacity .2s ease, visibility .2s ease;
}
.ekbpm-modal.open { visibility: visible; opacity: 1; }
.ekbpm-modal__overlay {
  position: absolute; inset: 0;
  background: rgba(43,31,27,.6);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
}
.ekbpm-modal__panel {
  position: relative;
  max-width: 460px;
  width: calc(100% - 32px);
  margin: 0 auto;
  top: 50%;
  transform: translateY(-50%);
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 30px 80px rgba(0,0,0,.4);
  padding: 36px 32px 28px;
  max-height: calc(100vh - 32px);
  overflow-y: auto;
  box-sizing: border-box;
  font-family: 'Montserrat', sans-serif;
}
.ekbpm-modal__close {
  position: absolute; top: 14px; right: 14px;
  width: 38px; height: 38px;
  border: 0; background: transparent;
  font-size: 20px; line-height: 1; color: var(--pst-muted);
  cursor: pointer; border-radius: 50%;
  transition: .15s;
}
.ekbpm-modal__close:hover { background: var(--pst-yellow-soft); color: var(--pst-dark); }
.ekbpm-modal__title {
  font-family: 'Montserrat', sans-serif;
  font-weight: 800;
  font-size: 24px;
  margin: 0 0 6px;
  color: var(--pst-dark);
}
.ekbpm-modal__sub {
  color: var(--pst-muted);
  font-size: 14.5px;
  margin: 0 0 22px;
}
.ekbpm-modal .wpcf7 form p { margin: 0 0 14px; }
.ekbpm-modal .wpcf7 form label {
  display: block;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--pst-dark);
  margin-bottom: 6px;
}
.ekbpm-modal .req { color: var(--pst-yellow); margin-left: 2px; }
.ekbpm-modal .wpcf7 form input {
  width: 100% !important;
  max-width: 100% !important;
  box-sizing: border-box !important;
  font-size: 16px;
  padding: 12px 14px;
  border: 1px solid var(--pst-border);
  border-radius: 8px;
  background: #fff;
  color: var(--pst-text);
  font-family: inherit;
}
.ekbpm-modal .wpcf7 form input:focus { outline: none; border-color: var(--pst-yellow); }
.ekbpm-modal .wpcf7 form input[type="submit"],
.ekbpm-modal .ekbpm-popup-submit {
  background: var(--pst-yellow) !important;
  color: var(--pst-dark) !important;
  border: 0 !important;
  font-family: 'Montserrat', sans-serif !important;
  font-weight: 800 !important;
  padding: 14px !important;
  cursor: pointer;
  margin-top: 6px;
}
.ekbpm-modal .wpcf7 form input[type="submit"]:hover { background: var(--pst-yellow-h) !important; }
.ekbpm-modal .wpcf7-response-output {
  margin: 12px 0 0 !important;
  padding: 10px 14px !important;
  border-radius: 8px !important;
  font-size: 13.5px !important;
}
@media (max-width: 560px) {
  .ekbpm-modal__panel { padding: 30px 22px 22px; }
  .ekbpm-modal__title { font-size: 21px; }
}
