/* Шапка в одну строку, логотип, выпадающие меню, формы заявок, окно «Заказать звонок» */

/* ---------- шапка ---------- */
.hdr { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.97); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.hdr__in { display: flex; align-items: center; gap: 32px; min-height: 76px; }
.caret { display: inline-block; width: 6px; height: 6px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg) translateY(-2px); margin-left: 8px; transition: transform .2s; }

.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; flex: none; color: var(--ink); }
.logo__mark { width: 40px; height: 40px; }
.logo__name { font-size: 20px; font-weight: 800; letter-spacing: .02em; line-height: 1; }

.hdr__nav { flex: 1; display: flex; justify-content: center; }
.mnu { display: flex; align-items: center; gap: 36px; list-style: none; margin: 0; padding: 0; }
.mnu > li { position: relative; }
.mnu > li > a { display: inline-flex; align-items: center; height: 76px; text-decoration: none; font-size: 13px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: #2b2a27; white-space: nowrap; }
.mnu > li > a:hover, .mnu > li > a.is-cur { color: #000; }
.mnu > li > a.is-cur { box-shadow: inset 0 -2px 0 var(--ink); }
.mnu__open { display: none; }
.mnu__sub { position: absolute; top: 100%; left: -20px; min-width: 260px; list-style: none; margin: 0; padding: 10px; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 18px 50px rgba(0,0,0,.08);
  opacity: 0; visibility: hidden; transform: translateY(6px); transition: opacity .15s, transform .15s, visibility .15s; }
.mnu__dd:hover .mnu__sub, .mnu__dd:focus-within .mnu__sub { opacity: 1; visibility: visible; transform: none; }
.mnu__dd:hover > a .caret { transform: rotate(-135deg) translateY(-1px); }
.mnu__sub a { display: flex; justify-content: space-between; gap: 16px; padding: 10px 12px; border-radius: 8px; text-decoration: none; font-size: 14px; font-weight: 500; }
.mnu__sub a:hover { background: var(--tint); }
.mnu__sub small { color: var(--muted); }
.mnu__all a { font-weight: 700; border-top: 1px solid var(--line); border-radius: 0 0 8px 8px; margin-top: 4px; padding-top: 12px; }
.hdr__navfoot { display: none; }

.hdr__act { display: flex; align-items: center; gap: 22px; flex: none; }
.hdr__sbtn { width: 40px; height: 40px; border: 0; background: none; display: grid; place-items: center; cursor: pointer; color: #2b2a27; padding: 0; }
.hdr__sbtn:hover, .hdr__sbtn[aria-expanded="true"] { color: #000; }
.hdr__sbtn svg { width: 21px; height: 21px; }

.hdr__tel { position: relative; display: flex; align-items: center; }
.hdr__phone { font-size: 15px; font-weight: 600; text-decoration: none; white-space: nowrap; letter-spacing: .01em; }
.hdr__telbtn { border: 0; background: none; cursor: pointer; padding: 8px 4px 8px 2px; color: #2b2a27; }
.hdr__telbtn .caret { margin-left: 6px; }
.hdr__teldd { position: absolute; top: calc(100% + 18px); right: -10px; width: 260px; padding: 10px; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 18px 50px rgba(0,0,0,.08);
  display: grid; gap: 2px; opacity: 0; visibility: hidden; transform: translateY(6px); transition: opacity .15s, transform .15s, visibility .15s; }
.hdr__teldd::before { content: ""; position: absolute; left: 0; right: 0; top: -20px; height: 20px; }
.hdr__tel:hover .hdr__teldd, .hdr__tel:focus-within .hdr__teldd, .hdr__tel.is-open .hdr__teldd { opacity: 1; visibility: visible; transform: none; }
.hdr__tel:hover .hdr__telbtn .caret, .hdr__tel.is-open .hdr__telbtn .caret { transform: rotate(-135deg) translateY(-1px); }
.hdr__teldd a, .hdr__teldd button { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 8px; text-decoration: none; font: inherit; font-size: 14px; font-weight: 500; color: var(--ink); border: 0; background: none; cursor: pointer; text-align: left; }
.hdr__teldd a:hover, .hdr__teldd button:hover { background: var(--tint); }
.hdr__teldd svg { width: 18px; height: 18px; flex: none; }
.hdr__teldd .js-wa svg { color: var(--wa); }
.hdr__hours { font-size: 12px; color: var(--muted); padding: 10px 12px 4px; border-top: 1px solid var(--line); margin-top: 4px; line-height: 1.5; }

.hdr__spop { border-top: 1px solid var(--line); background: #fff; padding: 14px 0; }
.hdr__spop .hdr__search { display: flex; width: 100%; max-width: 720px; margin: 0 auto; height: 50px; }
.hdr__spop .hdr__search input { font-size: 16px; }
.hdr__spop .sdrop { width: auto; left: 0; right: 0; }
.filters { top: 77px; }
html { scroll-padding-top: 96px; }

@media (max-width: 1280px) {
  .hdr__in { gap: 24px; }
  .mnu { gap: 24px; }
}
@media (max-width: 1140px) {
  .mnu { gap: 18px; }
  .mnu > li > a { font-size: 12px; letter-spacing: .04em; }
  .hdr__act { gap: 12px; }
}
@media (max-width: 1040px) {
  .hdr__tel { display: none; }
}
@media (max-width: 960px) {
  /* backdrop-filter делает шапку «контейнером» для fixed-меню и ломает его: на телефоне фон без размытия */
  .hdr { backdrop-filter: none; -webkit-backdrop-filter: none; background: #fff; }
  .hdr__nav { top: var(--hdr-top, 64px); }
  .hdr__in { min-height: 64px; gap: 12px; }
  .logo__mark { width: 36px; height: 36px; }
  .logo__name { font-size: 17px; }
  .hdr__act { margin-left: auto; gap: 4px; }
  .hdr__nav { position: fixed; inset: var(--hdr-top, 64px) 0 0 0; display: block; background: #fff; padding: 20px 16px 32px; transform: translateX(100%); transition: transform .25s; overflow-y: auto; }
  .hdr__nav.is-open { transform: none; }
  .mnu { flex-direction: column; align-items: stretch; gap: 0; }
  .mnu > li { border-bottom: 1px solid var(--line); }
  .mnu > li > a { height: auto; padding: 16px 0; font-size: 15px; }
  .mnu > li > a.is-cur { box-shadow: none; }
  .mnu > li > a .caret { display: none; }
  .mnu__open { display: grid; place-items: center; position: absolute; right: 0; top: 6px; width: 44px; height: 44px; border: 0; background: none; cursor: pointer; }
  .mnu__dd.is-open .mnu__open .caret { transform: rotate(-135deg); }
  .mnu__sub { position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; border: 0; padding: 0 0 10px; display: none; min-width: 0; }
  .mnu__dd.is-open .mnu__sub { display: block; }
  .hdr__navfoot { display: grid; gap: 10px; margin-top: 24px; }
  .hdr__navphone { font-size: 20px; font-weight: 800; text-decoration: none; margin-bottom: 4px; }
  .hdr__navfoot .btn svg { width: 20px; height: 20px; }
  .filters { top: 65px; }
  .nav__search { display: flex; margin-bottom: 8px; height: 48px; }
  .nav__search input { font-size: 16px; }
  .nav__search .sdrop { position: static; box-shadow: none; margin-top: 8px; min-width: 0; }
}

/* ---------- подвал: логотип ---------- */
.logo--white { color: #fff; margin-bottom: 16px; }

/* ---------- форма заявки ---------- */
.lead { display: grid; gap: 12px; }
.lead__row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.lead__f { display: grid; gap: 6px; font-size: 13px; font-weight: 600; color: var(--muted); }
.lead__f input, .lead__f textarea { font: inherit; font-size: 16px; color: var(--ink); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 14px; background: #fff; outline: 0; width: 100%; }
.lead__f input:focus, .lead__f textarea:focus { border-color: var(--ink); }
.lead__f textarea { resize: vertical; min-height: 84px; }
.lead input.is-err { border-color: #c0392b; background: #fff6f5; }
.lead__btn { justify-self: start; min-width: 220px; }
.lead__btn:disabled { opacity: .6; cursor: wait; }
.lead__note { margin: 0; font-size: 12px; color: var(--muted); }
.lead__note a { color: inherit; }
.lead__msg { margin: 0; font-size: 14px; }
.lead__msg.is-err { color: #c0392b; }
.lead__hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.lead__done { display: grid; gap: 6px; padding: 24px; border-radius: var(--r); background: #eef8f1; color: #1d5e37; }
.lead__done b { font-size: 18px; }

/* ---------- блок с формой внизу страниц ---------- */
.cta2 { background: var(--tint); }
.cta2__in { display: grid; grid-template-columns: 1fr 1.1fr; gap: 48px; align-items: start; }
.cta2__txt p { color: var(--muted); font-size: 17px; max-width: 46ch; }
.cta2__alt { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; margin-top: 24px; }
.cta2__phone { font-weight: 800; font-size: 18px; text-decoration: none; }
.cta2__form { background: #fff; border-radius: 14px; padding: 28px; box-shadow: 0 10px 40px rgba(0,0,0,.06); }

/* ---------- окно «Заказать звонок» ---------- */
.dlg { border: 0; border-radius: 16px; padding: 32px; width: min(520px, calc(100vw - 32px)); box-shadow: 0 30px 80px rgba(0,0,0,.25); }
.dlg::backdrop { background: rgba(20,20,20,.55); backdrop-filter: blur(2px); }
.dlg h3 { font-size: 24px; margin: 0 0 6px; }
.dlg__sub { color: var(--muted); margin: 0 0 6px; }
.dlg__item { font-weight: 600; margin: 0 0 14px; }
.dlg__item:empty { display: none; }
.dlg__x { position: absolute; top: 12px; right: 12px; width: 40px; height: 40px; border: 0; background: none; font-size: 28px; line-height: 1; cursor: pointer; color: var(--muted); }
.dlg__x:hover { color: var(--ink); }
.dlg .lead__row { grid-template-columns: 1fr; }
.dlg .lead__btn { justify-self: stretch; }

@media (max-width: 960px) {
  .cta2__in { grid-template-columns: 1fr; gap: 24px; }
}
@media (max-width: 640px) {
  .lead__row { grid-template-columns: 1fr; }
  .lead__btn { justify-self: stretch; }
  .cta2__form { padding: 20px; }
  .dlg { padding: 24px 20px; }
}
.menu-open .fab { display: none !important; }

/* шапка шире текста страницы: логотип у левого края, меню по центру, телефон у правого (как у APROFIL) */
.hdr .wrap.hdr__in { max-width: 1560px; padding: 0 48px; }
.hdr__nav { justify-content: center; }
@media (max-width: 1280px) { .hdr .wrap.hdr__in { padding: 0 24px; } }
@media (max-width: 960px) { .hdr .wrap.hdr__in { padding: 0 16px; } }

/* контент той же ширины, что шапка: края страниц совпадают с логотипом и телефоном */
.wrap { max-width: 1560px; padding-left: 48px; padding-right: 48px; }
.wrap.narrow { max-width: 900px; }
@media (max-width: 1280px) { .wrap { padding-left: 24px; padding-right: 24px; } }
@media (max-width: 960px) { .wrap { padding-left: 16px; padding-right: 16px; } }
