/* Главная (шиномонтаж): состояния, ховеры, адаптив. Базовая вёрстка — инлайн в шаблонах (как в макете). */
.hm{font-family:'Montserrat',system-ui,sans-serif;color:#1C2620;line-height:1.45}
.hm *{box-sizing:border-box}
.hm a{text-decoration:none}
.hm button{font-family:inherit;cursor:pointer}
.hm button:focus,.hm button:focus-visible{outline:none}
.hm input:focus{outline:none}
.no-sb::-webkit-scrollbar{display:none}
.no-sb{scrollbar-width:none}
@keyframes hmblink{0%,100%{opacity:1}50%{opacity:.35}}
@keyframes hmping{0%{box-shadow:0 0 0 0 rgba(26,163,75,.5)}70%,100%{box-shadow:0 0 0 9px rgba(26,163,75,0)}}

/* сегмент-кнопки (табы hero, чипы калькулятора, табы) */
.hm-seg{background:#F1F5F2;color:#1C2620}
.hm-seg.on{background:#0E7A3B;color:#fff}
.hm-captab{background:transparent;color:#6B7770}
.hm-captab.on{background:#fff;color:#1C2620}

/* ховеры */
.hm-svc-card:hover{transform:translateY(-3px);box-shadow:0 18px 40px rgba(15,30,20,.14)}
.hm-svc-card{transition:transform .2s,box-shadow .2s}
.hm-case-card{transition:transform .2s,box-shadow .2s}
.hm-case-card:hover{transform:translateY(-2px);box-shadow:0 14px 34px rgba(15,30,20,.1)}
.hm-case-card:hover img{transform:scale(1.05)}
.hm-art-card{transition:transform .2s,box-shadow .2s}
.hm-art-card:hover{transform:translateY(-2px);box-shadow:0 14px 34px rgba(15,30,20,.1)}
.hm-scroll-card:hover .hm-scroll-img{border-color:#0E7A3B}
.hm-circ">a:hover,.hm-round:hover{background:#F1F5F2}
.hm-linkgreen:hover{color:#0A5E2D}
a.hm-linkgreen{color:#0E7A3B}
.hm-msg a{transition:transform .15s}
.hm-msg a:hover{transform:scale(1.08)}

/* скрытие/раскрытие */
.hm-hidden{display:none!important}
.hm-extras-body{display:none}
.hm-extras.open .hm-extras-body{display:grid}
.hm-extras.open .hm-plus{transform:rotate(45deg)}
.hm-q-body{display:none}
.hm-q.open .hm-q-body{display:block}
.hm-q.open .hm-plus{transform:rotate(45deg)}
.hm-seo-more{display:none}
.hm-seo.open .hm-seo-more{display:block}
.hm-seo.open .hm-chev{transform:rotate(180deg)}
.hm-plus,.hm-chev{transition:transform .2s}

/* лайтбокс */
.hm-lightbox{position:fixed;inset:0;z-index:120;background:rgba(9,18,13,.92);display:none;flex-direction:column;align-items:center;justify-content:center;gap:18px;padding:44px 24px}
.hm-lightbox.open{display:flex}


/* ---- Попап заказа из калькулятора ---- */
.hm-modal{position:fixed;inset:0;z-index:9999;display:none;place-items:center;padding:18px;background:rgba(9,18,13,.55);-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px);overflow:auto}
.hm-modal.open{display:grid}
.hm-modal-card{position:relative;width:100%;max-width:440px;background:#fff;border-radius:20px;padding:28px 26px;box-shadow:0 30px 80px rgba(0,0,0,.35);animation:hmpop .2s ease}
@keyframes hmpop{from{opacity:0;transform:translateY(12px)}to{opacity:1;transform:none}}
.hm-modal-x{position:absolute;top:14px;right:14px;width:34px;height:34px;border:none;background:#F1F5F2;border-radius:9px;display:flex;align-items:center;justify-content:center;cursor:pointer;transition:background .15s}
.hm-modal-x:hover{background:#E7EDE9}
.hm-modal-sum{background:#F5F8F6;border:1px solid #EEF2F0;border-radius:13px;padding:12px 14px;margin-bottom:16px}
.hm-modal-row{display:flex;align-items:baseline;justify-content:space-between;gap:12px;padding:4px 0;font-size:13px;color:#6B7770}
.hm-modal-row+.hm-modal-row{border-top:1px solid #EEF2F0}
.hm-modal-row b{color:#1C2620;font-weight:700;text-align:right}
.hm-modal-row:last-child b{color:#0E7A3B;font-size:16px}
.hm-modal-inp{width:100%;border:1.5px solid #E2E9E4;background:#fff;border-radius:12px;padding:14px 16px;font-size:16px;color:#1C2620;margin-bottom:12px;transition:border-color .15s;box-sizing:border-box}
.hm-modal-inp:focus{outline:none;border-color:#0E7A3B}
.hm-modal-inp::placeholder{color:#9AA6A0}
.hm-modal-btn{width:100%;border:none;background:#15B85A;color:#fff;font-weight:800;font-size:16px;padding:16px;border-radius:13px;cursor:pointer;transition:background .15s}
.hm-modal-btn:hover{background:#0E7A3B}
@media(max-width:600px){.hm-modal-card{padding:24px 18px;border-radius:18px}}

/* ---------- Адаптив ---------- */
@media(max-width:960px){
  .hm-grid-hero{grid-template-columns:1fr!important}
  .hm-hero-promo{order:-1}                 /* на мобиле картинка/заголовок выше формы */
  .hm-grid-2{grid-template-columns:1fr!important}
  .hm-grid-3{grid-template-columns:repeat(2,1fr)!important}
  .hm-calc-grid{grid-template-columns:1fr!important}
  .hm-faq-grid{grid-template-columns:1fr!important}
  .hm-faq-side{position:static!important}
  .hm-b2b-grid{grid-template-columns:1fr!important}
  .hm-rev-head{grid-template-columns:1fr!important;gap:22px!important;padding:28px 26px!important}
  .hm-cta-grid{grid-template-columns:1fr!important}
  .hm-stats{grid-template-columns:repeat(2,1fr)!important}
}

@media(max-width:760px){
  .hm h1{font-size:38px!important}
  [data-cta-card]{padding:44px 40px!important}
  .hm-hero-promo{padding:40px!important}
}

/* Телефон (≤600) */
@media(max-width:600px){
  .hm-in{padding-left:16px!important;padding-right:16px!important}
  .hm h1{font-size:30px!important;letter-spacing:-.6px!important}
  .hm h2{font-size:23px!important;letter-spacing:-.4px!important}
  .hm h3{font-size:19px!important}
  /* герой */
  .hm-hero-promo{padding:26px 22px!important;min-height:260px!important}
  .hm-hero-promo h1{font-size:29px!important}
  .hm-hero-promo p{font-size:15px!important}
  /* Статы (преимущества) — 1 в ряд, горизонтальные на всю ширину */
  .hm-stats{grid-template-columns:1fr!important;gap:10px!important}
  .hm-stat{flex-direction:row!important;align-items:center!important;gap:14px!important;padding:16px!important}
  .hm-stat-ic{width:46px!important;height:46px!important}
  .hm-stat-v{font-size:23px!important}
  .hm-stat-suf{font-size:14px!important}
  .hm-stat-l{font-size:13px!important;line-height:1.3!important}
  /* услуги: 1 колонка; работы (фото): 2 в ряд */
  .hm-grid-3{grid-template-columns:1fr!important}
  #hmCases{grid-template-columns:repeat(2,1fr)!important;gap:10px!important}
  .hm-case-img{height:150px!important}
  .hm-extras-body{grid-template-columns:1fr!important}
  /* калькулятор */
  .hm-calc-opts{grid-template-columns:1fr!important;gap:16px 0!important}
  .hm-chips{grid-template-columns:repeat(2,1fr)!important}
  .hm-seg{height:auto!important;min-height:52px!important;display:flex!important;align-items:center!important;justify-content:center!important;text-align:center!important;line-height:1.2!important;padding:8px!important;font-size:13px!important}
  [data-calc-card]{padding:20px 16px!important}
  #hmCalc [data-total]{font-size:32px!important}
  /* CTA */
  [data-cta-card]{padding:28px 18px!important;border-radius:20px!important}
  [data-cta-card] h2{font-size:26px!important}
  [data-cta-card] p{font-size:15px!important}
  .hm-cta-phone{width:100%!important;font-size:24px!important}
  .hm-cta-contact{gap:10px 12px!important}
  /* скроллеры: карточки под экран */
  .hm-art-card{width:284px!important}
  /* оборудование: картинка ниже */
  .hm-grid-2 img{min-height:220px!important}
  /* отзывы */
  .hm-rev-head{padding:24px 20px!important}
  .hm-rev-score{font-size:40px!important}
  .hm-rev-right{flex-wrap:wrap;gap:14px 16px!important}
  .hm-rev-sub{white-space:normal!important;font-size:13px!important}
  .hm-rev-div{display:none!important}
  .hm-rev-row{flex-wrap:wrap}
  .hm-rev-row>div{min-width:0}
  .hm-rev-meta{width:100%!important;flex-direction:row!important;align-items:center!important;justify-content:space-between!important;margin-top:8px!important;order:3}
  .hm-rev-row>img,.hm-rev-row>span:first-child{width:46px!important;height:46px!important}
  /* прячем декоративное */
  .hm-hide-sm{display:none!important}
}

/* Узкий телефон (≤360) */
@media(max-width:360px){
  .hm h1,.hm-hero-promo h1{font-size:26px!important}
  .hm h2{font-size:21px!important}
  .hm-chips{grid-template-columns:repeat(2,1fr)!important}
  .hm-art-card{width:260px!important}
  .hm-case-img{height:128px!important}
}

/* красивый перенос строк как в макете */
.hm h1,.hm h2,.hm h3{text-wrap:balance}
.hm p{text-wrap:pretty}
