/* Форма заявки (th2_lead_form) и блок «Оставить заявку» перед подвалом (th2_lead_block).
   Токены --th-* — из v2/inner.css или home-v2/home.css (на главной). */

/* Форма */
.th-root .th-lf__title{font-family:var(--th-serif);font-weight:400;font-size:24px;line-height:1.15;color:var(--th-ink)}
.th-root .th-lf__sub{margin:6px 0 20px;font-size:14px;line-height:1.5;color:var(--th-muted)}
.th-lf__f{display:grid;gap:16px}
.th-lf__row{display:grid;gap:16px;min-width:0}
.th-lf__field{display:grid;gap:6px;min-width:0}
.th-lf__field label,.th-lf__when legend{font-size:14px;font-weight:500;color:var(--th-ink)}
.th-lf__field input,.th-lf__field select{display:block;width:100%;min-width:0;min-height:48px;margin:0;padding:0 14px;border:1px solid var(--th-line);border-radius:10px;background:#FFFFFF;font-family:var(--th-sans);font-size:16px;color:var(--th-ink);outline:none;box-shadow:none;transition:border-color .15s,box-shadow .15s}
.th-lf__field select{padding:0 12px}
.th-lf__field input[type="tel"]{font-variant-numeric:tabular-nums}
.th-lf__field input:hover,.th-lf__field select:hover{border-color:#D9CCC7}
.th-lf__field input:focus,.th-lf__field select:focus{border-color:var(--th-action);box-shadow:0 0 0 3px rgba(161,99,102,.18)}
.th-lf__field [aria-invalid="true"]{border-color:#B5646A;background:#FDF6F5}
.th-lf__err{display:flex;gap:6px;align-items:center;font-size:13px;line-height:1.4;color:#8A3B40}
.th-lf__err[hidden]{display:none}
.th-lf__err .th-ico{width:14px;height:14px;stroke-width:1.8}
.th-lf__when{display:grid;gap:8px;min-width:0;margin:0;padding:0;border:0}
.th-lf__when legend{margin-bottom:6px;padding:0}
.th-lf__when > div{display:flex;flex-wrap:wrap;gap:8px}
.th-lf__when label{position:relative;cursor:pointer}
.th-lf__when input{position:absolute;opacity:0;width:1px;height:1px;margin:0}
.th-lf__when label span{display:inline-flex;align-items:center;min-height:44px;padding:0 18px;border:1px solid var(--th-line);border-radius:999px;background:#FFFFFF;font-size:14px;transition:border-color .15s,background-color .15s}
.th-lf__when label:hover span{border-color:var(--th-action)}
.th-lf__when input:checked + span{border-color:var(--th-action);background:var(--th-blush);color:var(--th-deep,#663C42);font-weight:500}
.th-lf__when input:focus-visible + span{outline:2px solid var(--th-focus);outline-offset:2px}
.th-lf__agree{display:flex;gap:12px;align-items:flex-start;font-size:14px;line-height:1.5;cursor:pointer}
.th-lf__agree input{width:20px;height:20px;flex:none;margin:1px 0 0;accent-color:var(--th-action)}
.th-lf__agree a{color:var(--th-link)}
.th-lf__agree .th-lf__err{margin-top:2px}
.th-root .th-lf__send{width:100%;min-height:52px;border:0;font-family:var(--th-sans);font-size:15px;cursor:pointer}
.th-lf__send:disabled{background:#B98A8C;cursor:progress}
.th-lf__spin{display:none;width:16px;height:16px;border-radius:50%;border:2px solid rgba(255,255,255,.5);border-top-color:#FFFFFF;animation:th-lf-spin .8s linear infinite}
.is-busy .th-lf__spin{display:inline-block}
@keyframes th-lf-spin{to{transform:rotate(360deg)}}
.th-lf__msg{font-size:14px;line-height:1.5}
.th-lf__msg:empty{display:none}
.th-lf__msg.is-err{padding:12px 14px;border-radius:12px;background:#F5EBD8;color:#3E2E14}
.th-lf__msg a{color:var(--th-link)}
.th-lf-hp{position:absolute!important;left:-10000px;top:auto;width:1px;height:1px;overflow:hidden}
.th-lf__body[hidden],.th-lf__ok[hidden]{display:none}
.th-lf__ok{display:grid;gap:12px;justify-items:start;outline:none}
.th-lf__ok-ico{display:grid;place-items:center;width:56px;height:56px;border-radius:50%;background:#E6EEE3;color:#3E5A3C}
.th-lf__ok-ico .th-ico{width:28px;height:28px;stroke-width:1.8}
.th-root .th-lf__ok p{font-size:15px;line-height:1.55;color:var(--th-muted)}
.th-lf__ok .th-btn{width:auto}

/* Блок «Оставить заявку» перед подвалом */
.th-lead{padding:32px 0;background:var(--th-blush);scroll-margin-top:72px}
.th-lead__in{width:var(--th-cont);margin:0 auto;display:grid;grid-template-columns:minmax(0,1fr);gap:16px;align-items:start}
.th-lead__card{min-width:0;padding:22px 20px;border:1px solid var(--th-line);border-radius:20px;background:#FFFFFF}
.th-lead__tg{min-width:0;display:grid;gap:10px;padding:4px 4px 0}
.th-root .th-lead__tg-t{font-family:var(--th-serif);font-weight:400;font-size:22px;line-height:1.2;color:var(--th-ink)}
.th-root .th-lead__tg p{font-size:15px;line-height:1.55;color:#4A2C31}
.th-root .th-lead__tg .th-btn{min-height:50px;font-size:15px}
.th-lead__tg .th-ico{width:18px;height:18px}

@media (min-width:768px){
  .th-root .th-lf__title{font-size:28px}
  .th-lf--wide .th-lf__row{grid-template-columns:repeat(2,minmax(0,1fr))}
  .th-lead{padding:56px 0}
  .th-lead__card{padding:32px}
  .th-root .th-lead__tg .th-btn{justify-self:start;width:auto}
}
@media (min-width:1024px){
  .th-lead__in{grid-template-columns:minmax(0,1.6fr) minmax(0,1fr);gap:40px}
  .th-lead__tg{padding:32px 0 0}
}
@media (prefers-reduced-motion:reduce){.th-lf__spin{animation:none}}

/* Липкие плашки внизу экрана (услуга, статья) не закрывают форму, пока блок на экране. */
.th-lead.is-in ~ .th-svc-bar,.th-lead.is-in ~ .th-bar{display:none!important}
