/* RemontDom.by — макет редизайна (статичный HTML + CSS, без фреймворков) */
:root {
  --ink: #1b2827;
  --muted: #53625f;
  --line: #e3e0d9;
  --bg: #ffffff;
  --stone: #f5f3ee;
  --deep: #123430;
  --deep-2: #0c2522;
  --brand: #4d7a0b;        /* фирменный зелёный, затемнён под контраст текста (AA) */
  --brand-fill: #77a818;   /* фирменный зелёный из логотипа, только для заливок и акцентов */
  --brand-soft: #eef5dc;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(18, 52, 48, .06), 0 8px 24px rgba(18, 52, 48, .08);
  --font: "Manrope", "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
}
@media (prefers-color-scheme: dark) {
  /* сайт остаётся светлым: плиточный сайт читается лучше на светлом фоне */
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scroll-padding-top: 92px; }
body {
  margin: 0;
  font: 400 18px/1.65 var(--font);
  color: var(--ink);
  background: var(--bg);
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--brand); text-underline-offset: 3px; }
a:hover { color: var(--deep); }
:focus-visible { outline: 3px solid var(--brand-fill); outline-offset: 3px; border-radius: 4px; }

.wrap { width: min(1240px, 100% - 32px); margin-inline: auto; }
.section { padding: 72px 0; }
.section--stone { background: var(--stone); }
.section--deep { background: var(--deep); color: #fff; }
.eyebrow { font-weight: 700; font-size: 14px; letter-spacing: .08em; text-transform: uppercase; color: var(--brand); margin: 0 0 10px; }
.section--deep .eyebrow { color: #b8dc6a; }
h1, h2, h3 { line-height: 1.2; letter-spacing: -.01em; margin: 0 0 .5em; font-weight: 800; }
h1 { font-size: clamp(32px, 5vw, 52px); }
h2 { font-size: clamp(26px, 3.4vw, 38px); }
h3 { font-size: 21px; }
.lead { font-size: clamp(18px, 2vw, 21px); color: var(--muted); max-width: 62ch; }
.section--deep .lead { color: #cfe0dc; }

/* ---------- кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 52px; padding: 12px 26px; border-radius: 14px; text-align: center;
  font: 700 17px/1.25 var(--font); text-decoration: none; cursor: pointer;
  border: 2px solid transparent; transition: transform .15s, background .15s, color .15s, border-color .15s;
}
.btn:hover { transform: translateY(-1px); }
.btn--primary { background: var(--brand); color: #fff; }
.btn--primary:hover { background: #3d6208; color: #fff; }
.btn--ghost { border-color: rgba(255, 255, 255, .55); color: #fff; }
.btn--ghost:hover { background: #fff; color: var(--deep); }
.btn--outline { border-color: var(--brand); color: var(--brand); }
.btn--outline:hover { background: var(--brand); color: #fff; }

/* ---------- шапка ---------- */
.topbar { background: var(--deep-2); color: #cfe0dc; font-size: 15px; }
.topbar .wrap { display: flex; flex-wrap: wrap; gap: 4px 24px; justify-content: space-between; padding: 8px 0; }
.topbar a { color: #fff; text-decoration: none; }
.tb-right { display: inline-flex; align-items: center; gap: 18px; }
.social { display: inline-flex; gap: 8px; align-items: center; }
.soc { width: 30px; height: 30px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; color: #fff; background: rgba(255, 255, 255, .08); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .22); transition: background .18s, box-shadow .18s, transform .18s; }
.soc svg { width: 15px; height: 15px; fill: currentColor; display: block; }
.soc:hover { transform: translateY(-1px); box-shadow: none; }
.soc--ig:hover { background: #e4405f; }
.soc--tg:hover { background: #26a5e4; }
.soc--vb:hover { background: #7360f2; }
.soc--wa:hover { background: #25d366; }
.social--footer { margin-top: 18px; gap: 10px; }
.social--footer .soc { width: 38px; height: 38px; border-radius: 12px; }
.social--footer .soc svg { width: 18px; height: 18px; }
.nav-social { display: none; }
.header { position: -webkit-sticky; position: sticky; top: 0; z-index: 50; background: rgba(255, 255, 255, .96); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.header .wrap { display: flex; align-items: center; gap: 16px; min-height: 76px; position: relative; }
.logo { flex: none; }
.logo img { height: 46px; width: auto; max-width: none; }
@media (max-width: 1180px) {
  .header .wrap { gap: 12px; }
  .nav a { padding: 10px 9px; font-size: 15px; }
}
.nav { margin-left: auto; align-self: stretch; display: flex; align-items: stretch; }
.nav ul { align-items: stretch; }
.nav li { display: flex; align-items: center; }
.nav ul { display: flex; gap: 2px; list-style: none; margin: 0; padding: 0; }
.nav a { display: block; padding: 10px 8px; border-radius: 10px; color: var(--ink); text-decoration: none; font-weight: 700; font-size: 15.5px; white-space: nowrap; }
.nav a:hover, .nav a[aria-current="page"] { background: var(--brand-soft); color: var(--brand); }
.header .call { flex: none; margin-left: 8px; padding: 10px 18px; border-radius: 14px; background: var(--brand-soft); font-weight: 800; text-decoration: none; color: var(--brand); font-size: 18px; white-space: nowrap; }
.header .call:hover { background: var(--brand); color: #fff; }
.call-icon { display: none; margin-left: auto; width: 48px; height: 48px; border-radius: 14px; background: var(--brand); color: #fff; align-items: center; justify-content: center; flex: none; }
.call-icon:hover { background: #3d6208; color: #fff; }
.burger { display: none; margin-left: 0; width: 48px; height: 48px; border: 1px solid var(--line); background: #fff; border-radius: 12px; cursor: pointer; }

.burger { position: relative; }
.burger__bars { position: absolute; left: 50%; top: 50%; width: 22px; height: 16px; margin: -8px 0 0 -11px; display: block; }
.burger__bars i { position: absolute; left: 0; width: 22px; height: 2px; border-radius: 2px; background: var(--ink); transition: transform .3s cubic-bezier(.2, .65, .2, 1), top .3s cubic-bezier(.2, .65, .2, 1), opacity .2s; }
.burger__bars i:nth-child(1) { top: 0; }
.burger__bars i:nth-child(2) { top: 7px; }
.burger__bars i:nth-child(3) { top: 14px; }
.burger[aria-expanded="true"] .burger__bars i:nth-child(1) { top: 7px; transform: rotate(45deg); }
.burger[aria-expanded="true"] .burger__bars i:nth-child(2) { opacity: 0; transform: scaleX(.2); }
.burger[aria-expanded="true"] .burger__bars i:nth-child(3) { top: 7px; transform: rotate(-45deg); }

/* ---------- подменю «Услуги» ---------- */
.has-sub { position: relative; display: flex; align-items: center; }
.sub-toggle { width: 24px; height: 36px; margin-left: -6px; padding: 0; border: 0; background: none; color: var(--ink); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; border-radius: 8px; }
.sub-toggle svg { transition: transform .25s; }
.has-sub.is-open .sub-toggle svg, .has-sub:hover .sub-toggle svg { transform: rotate(180deg); }
.has-sub.is-current > a { color: var(--brand); }
.submenu { position: absolute; top: 100%; left: -14px; right: auto; z-index: 70; width: 310px; padding: 10px; margin-top: 4px; background: #fff; border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 18px 44px rgba(18, 52, 48, .16); display: grid; gap: 2px; opacity: 0; visibility: hidden; transform: translateY(8px); transition: opacity .2s, transform .2s, visibility .2s; }
.submenu::before { content: ""; position: absolute; left: 0; right: 0; top: -6px; height: 6px; } /* мостик, чтобы меню не закрывалось при движении мыши */
.has-sub:hover .submenu, .has-sub.is-open .submenu { opacity: 1; visibility: visible; transform: none; }
.submenu__title { margin: 6px 10px 4px; font-size: 12.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.submenu a { display: block; padding: 11px 14px; border-radius: 10px; font-size: 16.5px; font-weight: 600; white-space: normal; }
.submenu a:hover, .submenu a[aria-current="page"] { background: var(--brand-soft); color: var(--brand); }
.submenu .submenu__all { margin-top: 6px; color: var(--brand); font-weight: 800; border-top: 1px solid var(--line); border-radius: 0 0 10px 10px; padding-top: 14px; }

/* ---------- hero ---------- */
.hero { position: relative; color: #fff; background: var(--deep); overflow: hidden; }
.hero__bg { position: absolute; inset: 0; }
.hero__bg img { width: 100%; height: 100%; object-fit: cover; }
.hero__bg::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(10, 33, 30, .94) 0%, rgba(10, 33, 30, .78) 46%, rgba(10, 33, 30, .25) 100%); }
.hero .wrap { position: relative; padding: 96px 0 88px; }
.hero__text { max-width: 660px; }
.hero h1 { color: #fff; margin-bottom: 20px; }
.hero p { font-size: 20px; color: #e3efec; margin: 0 0 32px; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 14px; }
.chips { display: flex; flex-wrap: wrap; gap: 10px; margin: 36px 0 0; padding: 0; list-style: none; }
.chips li { background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .25); padding: 8px 16px; border-radius: 12px; font-weight: 600; font-size: 16px; }

/* ---------- карточки услуг ---------- */
.grid { display: grid; gap: 24px; }
.grid--4 { grid-template-columns: repeat(4, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; box-shadow: var(--shadow); transition: transform .2s, box-shadow .2s; text-decoration: none; color: inherit; }
.card:hover { transform: translateY(-3px); box-shadow: 0 2px 4px rgba(18, 52, 48, .08), 0 16px 36px rgba(18, 52, 48, .14); color: inherit; }
.card__img { aspect-ratio: 4 / 3; overflow: hidden; background: var(--stone); }
.card__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.card:hover .card__img img { transform: scale(1.04); }
.card__body { padding: 22px 22px 24px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.card__body h3 { margin: 0; }
.card__body p { margin: 0; color: var(--muted); font-size: 16.5px; }
.price { margin-top: auto; padding-top: 10px; font-weight: 800; color: var(--brand); font-size: 19px; }
.more { font-weight: 700; color: var(--brand); }
.more::after { content: " →"; }

.card--article .card__img { aspect-ratio: 16 / 10; }
.card--article .card__body h3 { font-size: 19px; line-height: 1.35; }
.card--article .more { margin-top: auto; padding-top: 6px; }

/* ---------- таблица цен ---------- */
.pricebox { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.pricebox table { width: 100%; border-collapse: collapse; }
.pricebox caption { text-align: left; padding: 20px 24px; font-weight: 800; font-size: 22px; border-bottom: 1px solid var(--line); }
.pricebox th, .pricebox td { padding: 16px 24px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.pricebox thead th { background: var(--stone); font-size: 14px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.pricebox tbody tr:last-child td { border-bottom: 0; }
.pricebox tbody tr:hover { background: #fbfaf7; }
.pricebox td:nth-child(2) { color: var(--muted); white-space: nowrap; }
.pricebox td:last-child { font-weight: 800; white-space: nowrap; color: var(--brand); text-align: right; }
.pricebox th:last-child { text-align: right; }
.note { color: var(--muted); font-size: 15px; margin: 14px 4px 0; }

/* ---------- split ---------- */
.split { display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; align-items: center; }
.split img { border-radius: var(--radius); box-shadow: var(--shadow); width: 100%; }
.checks { list-style: none; padding: 0; margin: 24px 0 0; display: grid; gap: 12px; }
.checks li { position: relative; padding-left: 36px; font-weight: 600; }
.checks li::before { content: ""; position: absolute; left: 0; top: 4px; width: 22px; height: 22px; border-radius: 50%; background: var(--brand-fill) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12.5l4 4 8-9' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/16px no-repeat; }

/* ---------- галерея ---------- */
.gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.gallery figure { margin: 0; border-radius: var(--radius); overflow: hidden; aspect-ratio: 4 / 5; position: relative; }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.gallery figure:hover img { transform: scale(1.05); }
.gallery figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 36px 16px 14px; color: #fff; font-weight: 700; font-size: 16px; background: linear-gradient(transparent, rgba(8, 28, 25, .85)); }

/* ---------- отзывы (Elfsight) ---------- */
.reviews { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow); min-height: 140px; }
.keep { display: inline-flex; gap: 10px; align-items: center; background: #fff7d6; border: 1px dashed #c9a300; color: #5c4a00; padding: 8px 14px; border-radius: 10px; font-size: 14px; font-weight: 600; margin-bottom: 14px; }
/* на боевой странице отступ под виджетом остаётся (как в текущей версии сайта) */
div[class^="elfsight-app"], div[class*=" elfsight-app"] { padding-bottom: 24px; }

/* ---------- статьи ---------- */
.article-link { display: flex; flex-direction: column; gap: 6px; padding: 22px 24px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; color: var(--ink); transition: border-color .2s, transform .2s; }
.article-link:hover { border-color: var(--brand-fill); transform: translateY(-2px); color: var(--ink); }
.article-link b { font-size: 19px; line-height: 1.35; }
.article-link span { color: var(--muted); font-size: 15.5px; }

/* ---------- CTA и подвал ---------- */
.cta { text-align: center; }
.cta .lead { margin: 0 auto 28px; }
.cta .hero__cta { justify-content: center; }
.footer { background: var(--deep-2); color: #b9cdc9; padding: 56px 0 28px; font-size: 16px; }
.footer a { color: #fff; text-decoration: none; }
.footer a:hover { text-decoration: underline; }
.footer h4 { color: #fff; margin: 0 0 12px; font-size: 17px; }
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 36px; }
.footer__bottom { border-top: 1px solid rgba(255, 255, 255, .12); margin-top: 36px; padding-top: 20px; font-size: 14.5px; }

/* ---------- внутренняя страница ---------- */
.crumbs { font-size: 15px; color: var(--muted); padding: 22px 0 0; }
.crumbs a { color: var(--muted); }
.page-hero { padding: 18px 0 40px; }
.layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 48px; align-items: start; padding-bottom: 72px; }
.prose { font-size: 18.5px; line-height: 1.75; }
.prose h2 { margin-top: 1.6em; }
.prose h3 { margin-top: 1.4em; }
.prose p { margin: 0 0 1.1em; }
.prose ul { padding-left: 1.2em; }
.prose li { margin-bottom: .4em; }
.prose .cover { border-radius: var(--radius); box-shadow: var(--shadow); margin: 0 0 32px; width: 100%; aspect-ratio: 2 / 1; object-fit: cover; }
.aside { position: sticky; top: 100px; display: grid; gap: 20px; }
.box { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); }
.box--accent { background: var(--deep); color: #fff; border-color: var(--deep); }
.box--accent h3 { color: #fff; }
.box--accent p { color: #cfe0dc; margin: 0 0 18px; }
.box--accent .btn { width: 100%; }
.box ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.box li a { font-weight: 600; }
.phone-big { display: block; font-size: 26px; font-weight: 800; color: #fff; text-decoration: none; margin-bottom: 4px; }

/* ---------- форма заявки ---------- */
.lead-grid { display: grid; grid-template-columns: 1fr 1.05fr; gap: 56px; align-items: center; }
.contacts-list { list-style: none; margin: 28px 0 0; padding: 0; display: grid; gap: 14px; font-weight: 600; }
.contacts-list a { color: #fff; text-decoration: none; }
.contacts-list a:hover { text-decoration: underline; }
.contacts-list small { display: block; font-weight: 500; color: #a9c0bb; font-size: 14px; }
.form-card { background: #fff; color: var(--ink); border-radius: 18px; padding: 32px; box-shadow: 0 20px 50px rgba(0, 0, 0, .25); }
.form-card h3 { margin: 0 0 6px; font-size: 24px; }
.form-card .sub { margin: 0 0 22px; color: var(--muted); font-size: 16px; }
.field { display: grid; gap: 6px; margin-bottom: 16px; }
.field label { font-weight: 700; font-size: 15px; }
.field input, .field textarea, .field select {
  width: 100%; font: 500 18px/1.4 var(--font); color: var(--ink);
  padding: 14px 16px; min-height: 54px; background: #fff;
  border: 2px solid #cfd6d3; border-radius: 12px; transition: border-color .15s, box-shadow .15s;
}
.field textarea { min-height: 110px; resize: vertical; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 4px rgba(119, 168, 24, .25); }
.field.has-error input, .field.has-error textarea { border-color: #b3261e; }
.field .err { color: #b3261e; font-size: 14.5px; font-weight: 600; min-height: 0; display: none; }
.field.has-error .err { display: block; }
.form-card .btn { width: 100%; margin-top: 6px; }
.form-card .consent { margin: 14px 0 0; font-size: 13.5px; color: var(--muted); line-height: 1.5; }
.form-card .ok { display: none; text-align: center; padding: 28px 8px; }
.form-card .ok b { display: block; font-size: 24px; margin-bottom: 8px; color: var(--brand); }
.form-card.is-sent form { display: none; }
.form-card.is-sent .ok { display: block; }
.box--accent .field label { color: #fff; }
.box--accent .field input, .box--accent .field textarea { border-color: transparent; }
.box--accent .field .err { color: #ffb4ab; }
.box--accent .consent { color: #a9c0bb; font-size: 13px; margin: 12px 0 0; }
.box--accent .ok { display: none; text-align: center; padding: 8px 0; }
.box--accent .ok b { display: block; font-size: 20px; color: #b8dc6a; margin-bottom: 4px; }
.box--accent.is-sent form { display: none; }
.box--accent.is-sent .ok { display: block; }

/* ---------- анимации ---------- */
/* первый экран: мягкое появление текста и лёгкое «приближение» фото */
@keyframes rd-fade-up { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
@keyframes rd-hero-zoom { from { transform: scale(1.07); } to { transform: scale(1); } }
.hero__bg img { animation: rd-hero-zoom 2s cubic-bezier(.2, .65, .2, 1) backwards; }
.hero__text > * { animation: rd-fade-up .8s cubic-bezier(.2, .65, .2, 1) backwards; }
.hero__text > :nth-child(2) { animation-delay: .08s; }
.hero__text > :nth-child(3) { animation-delay: .16s; }
.hero__text > :nth-child(4) { animation-delay: .24s; }
.hero__text > :nth-child(5) { animation-delay: .32s; }
/* остальные блоки: появляются при прокрутке (класс .reveal ставит app.js) */
.js .reveal { opacity: 0; transform: translateY(28px); transition: opacity .7s cubic-bezier(.2, .65, .2, 1), transform .7s cubic-bezier(.2, .65, .2, 1); }
.js .reveal.is-visible { opacity: 1; transform: none; }

/* ---------- мобильная версия ---------- */
@media (max-width: 1080px) {
  .grid--4 { grid-template-columns: repeat(2, 1fr); }
  .gallery { grid-template-columns: repeat(2, 1fr); }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .layout { grid-template-columns: 1fr; }
  .aside { position: static; }
}
@media (max-width: 1300px) {
  .header .call { display: none; }
}
@media (min-width: 1301px) {
  .tb-phone { display: none; }
}
@media (max-width: 1100px) {
  .burger { display: block; }
  .call-icon { display: inline-flex; }
  .nav { position: absolute; left: 0; right: 0; top: 100%; background: #fff; border-bottom: 1px solid var(--line); display: none; padding: 8px 16px 16px; box-shadow: var(--shadow); margin-left: 0; max-height: calc(100vh - 170px); max-height: calc(100dvh - 170px); overflow-y: auto; overscroll-behavior: contain; align-self: auto; }
  .nav.is-open { display: block; }
  .nav ul { flex-direction: column; }
  .nav a { padding: 14px 12px; font-size: 18px; }
  .has-sub { flex-wrap: wrap; }
  .has-sub > a { flex: 1; }
  .sub-toggle { width: 48px; height: 48px; margin-left: 0; color: var(--muted); }
  .submenu { position: static; width: auto; max-width: none; margin: 0 0 6px; padding: 4px 0 8px 12px; border: 0; border-left: 3px solid var(--brand-soft); border-radius: 0; box-shadow: none; display: none; opacity: 1; visibility: visible; transform: none; flex-basis: 100%; grid-template-columns: 1fr; gap: 0; }
  .submenu::before { display: none; }
  .has-sub:hover .submenu { display: none; }
  .has-sub.is-open .submenu { display: grid; }
  .has-sub:hover .sub-toggle svg { transform: none; }
  .has-sub.is-open .sub-toggle svg { transform: rotate(180deg); }
  .submenu a { padding: 11px 10px; font-size: 17px; font-weight: 600; }
  .submenu__title { margin: 10px 10px 2px; }
}
@media (max-width: 860px) {
  .nav-social { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 12px 4px; margin-top: 8px; border-top: 1px solid var(--line); }
  .nav-social__label { font-weight: 700; color: var(--muted); font-size: 15px; }
  .nav-social .social { gap: 10px; }
  .nav-social .soc { width: 42px; height: 42px; border-radius: 12px; color: var(--deep); background: var(--stone); box-shadow: none; }
  .nav-social .soc svg { width: 20px; height: 20px; }
  .nav-social .soc:hover { color: #fff; }
  .split, .grid--3, .grid--2, .lead-grid { grid-template-columns: 1fr; }
  .split, .lead-grid { gap: 28px; }
  .form-card { padding: 24px 20px; }
  .section { padding: 52px 0; }
  .hero .wrap { padding: 64px 0 60px; }
  .hero__bg::after { background: linear-gradient(180deg, rgba(10, 33, 30, .86), rgba(10, 33, 30, .9)); }
  /* верхняя полоса с адресом: одна строка, размер шрифта подстраивается под ширину экрана;
     она стоит под закреплённой шапкой (отступ даёт padding-top у body) и уезжает при прокрутке */
  .topbar .wrap { flex-wrap: nowrap; justify-content: center; padding: 7px 0; gap: 0; }
  .topbar .wrap > :first-child { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; font-size: clamp(10.5px, 3.1vw, 14px); line-height: 1.3; }
  .topbar .wrap > :last-child { display: none; }
  .header { position: fixed; top: 0; left: 0; right: 0; width: 100%; background: #fff; -webkit-backdrop-filter: none; backdrop-filter: none; }
  body { padding-top: 77px; }
  .nav { max-height: calc(100vh - 96px); max-height: calc(100dvh - 96px); }
}
@media (max-width: 600px) {
  body { font-size: 17.5px; }
  .grid--4 { grid-template-columns: 1fr; }
  .pricebox th, .pricebox td { padding: 14px 16px; }
  .pricebox td:nth-child(2), .pricebox th:nth-child(2) { display: none; }
  .footer__grid { grid-template-columns: 1fr; }
  .btn { width: 100%; }
  }
@media (max-width: 360px) {
  .logo img { height: 34px; }
  .header .wrap { gap: 10px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }

/* ---------- обязательные поля ---------- */
.field .req { color: #b3261e; font-weight: 800; }
.box--accent .field .req { color: #ffd2cc; }
.box--accent .field { margin-bottom: 12px; }
.box--accent .field textarea { min-height: 64px; }
.box--accent > p { margin-bottom: 16px; }

/* ---------- видео + Instagram ---------- */
.media-row { display: grid; grid-template-columns: 1.8fr 1fr; gap: 28px; align-items: stretch; }
.video { position: relative; display: block; min-height: 320px; border-radius: 18px; overflow: hidden; background: #0f2a22; color: #fff; text-decoration: none; box-shadow: 0 14px 36px rgba(16, 42, 34, .18); }
.video img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .5s cubic-bezier(.2, .65, .2, 1); }
.video img { transform: scale(1.34); } /* обрезаем чёрные полосы превью YouTube */
.video:hover img { transform: scale(1.4); }
.video::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(8, 24, 18, .78), rgba(8, 24, 18, 0) 55%); }
.video__play { position: absolute; z-index: 2; left: 50%; top: 50%; width: 68px; height: 48px; margin: -24px 0 0 -34px; border-radius: 14px; background: #f00; color: #fff; display: flex; align-items: center; justify-content: center; box-shadow: 0 6px 20px rgba(0, 0, 0, .35); transition: transform .2s, background .2s; }
.video:hover .video__play { transform: scale(1.08); background: #cc0000; }
.video__cap { position: absolute; z-index: 2; left: 22px; right: 22px; bottom: 18px; font-size: 16px; line-height: 1.4; }
.video__cap b { display: block; font-size: 20px; margin-bottom: 2px; }
.video--live { border: 0; width: 100%; height: 100%; min-height: 320px; background: #000; }
.ig-card { background: #fff; border-radius: 18px; padding: 22px; box-shadow: 0 14px 36px rgba(16, 42, 34, .12); border: 1px solid var(--line); display: flex; flex-direction: column; min-width: 0; }
.ig-card h3 { margin: 0 0 14px; font-size: 22px; line-height: 1.25; }
.ig-word { display: inline-flex; align-items: center; gap: 6px; background: linear-gradient(45deg, #f9a43e, #e4405f 50%, #7b3fbf); -webkit-background-clip: text; background-clip: text; color: transparent; -webkit-text-fill-color: transparent; font-weight: 800; }
.ig-word svg { width: 22px; height: 22px; fill: #e4405f; }
.ig-slider { position: relative; border-radius: 14px; overflow: hidden; flex: 1 1 auto; min-height: 0; }
.ig-track { list-style: none; margin: 0; padding: 0; display: flex; height: 100%; overflow-x: auto; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.ig-track::-webkit-scrollbar { display: none; }
.ig-track li { flex: 0 0 100%; scroll-snap-align: start; }
.ig-track img { width: 100%; height: 100%; object-fit: cover; display: block; aspect-ratio: 10 / 11; }
.ig-btn { position: absolute; top: 50%; margin-top: -19px; width: 38px; height: 38px; border: 0; border-radius: 12px; background: rgba(255, 255, 255, .92); color: var(--deep); cursor: pointer; display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 14px rgba(0, 0, 0, .25); }
.ig-btn:hover { background: #fff; color: var(--brand); }
.ig-btn--prev { left: 10px; }
.ig-btn--next { right: 10px; }
.ig-link { margin-top: 14px; font-weight: 700; color: var(--brand); text-decoration: none; }
.ig-link:hover { text-decoration: underline; }
@media (max-width: 860px) {
  .media-row { grid-template-columns: 1fr; gap: 20px; }
  .video { min-height: 0; aspect-ratio: 16 / 9; }
  .video img, .video:hover img { transform: none; }
  .video--live { min-height: 0; aspect-ratio: 16 / 9; height: auto; }
  .video__play { width: 60px; height: 42px; margin: -21px 0 0 -30px; border-radius: 12px; }
  .video__cap { left: 16px; right: 16px; bottom: 12px; font-size: 14px; }
  .video__cap b { font-size: 16px; }
  .ig-card { padding: 18px; }
  .ig-slider { flex: none; }
  .ig-track img { aspect-ratio: 4 / 5; }
}
.soc--tg svg { transform: translate(.8px, -.5px) scale(1.3); }

/* ---------- попап ---------- */
.modal { position: fixed; inset: 0; z-index: 200; display: flex; align-items: center; justify-content: center; padding: 16px; overflow-y: auto; }
.modal[hidden] { display: none; }
.modal__overlay { position: fixed; inset: 0; background: rgba(8, 24, 18, .62); animation: rd-modal-fade .25s ease-out; }
.modal__card { position: relative; width: 100%; max-width: 480px; margin: auto; animation: rd-modal-in .3s cubic-bezier(.2, .65, .2, 1); }
.modal__close { position: absolute; top: 12px; right: 12px; width: 40px; height: 40px; border: 1px solid var(--line); border-radius: 12px; background: #fff; color: var(--ink); cursor: pointer; display: flex; align-items: center; justify-content: center; }
.modal__close:hover { background: var(--stone); }
.modal__card h3 { padding-right: 44px; }
.modal-open, .modal-open body { overflow: hidden; }
@keyframes rd-modal-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes rd-modal-in { from { opacity: 0; transform: translateY(16px) scale(.98); } to { opacity: 1; transform: none; } }
@media (max-width: 860px) { .modal { align-items: flex-start; } .modal__card { padding: 22px 18px; } }

.contacts-note { margin: 22px 0 0; color: rgba(255, 255, 255, .75); font-size: 16px; }
.contacts-note + .social--footer { margin-top: 10px; }

/* иконки соцсетей в мобильном меню: правила «.nav a» (отступы, block) не должны сдвигать значок */
.nav .nav-social .soc { display: inline-flex; align-items: center; justify-content: center; padding: 0; font-size: 0; line-height: 0; }
.nav .nav-social .soc:hover { color: #fff; }
.nav .nav-social .soc--ig:hover { background: #e4405f; }
.nav .nav-social .soc--tg:hover { background: #26a5e4; }
.nav .nav-social .soc--vb:hover { background: #7360f2; }
.nav .nav-social .soc--wa:hover { background: #25d366; }

/* страховка от «плавания» страницы вправо на телефонах: ничего не должно расширять страницу за экран */
.hero__bg { overflow: hidden; }
.reviews { overflow: hidden; }
@media (max-width: 860px) {
  html { overflow-x: hidden; }
  body { overflow-x: clip; max-width: 100%; } /* clip не создаёт отдельную прокрутку (в отличие от hidden) */
}

/* видео в такой же карточке, как блок Instagram */
.video-card { background: #fff; border-radius: 18px; padding: 22px; box-shadow: 0 14px 36px rgba(16, 42, 34, .12); border: 1px solid var(--line); display: flex; flex-direction: column; min-width: 0; }
.video-card h3 { margin: 0 0 14px; font-size: 22px; line-height: 1.25; }
.video-card .video, .video-card .video--live { flex: 1 1 auto; border-radius: 14px; box-shadow: none; }
@media (max-width: 860px) { .video-card { padding: 18px; } .video-card h3 { font-size: 20px; } .video-card .video, .video-card .video--live { flex: none; } }

/* ---------- карусель «Наши работы»: по 2 фото, листается по 2 ---------- */
.works { position: relative; }
.works__track { list-style: none; margin: 0; padding: 0; display: flex; gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.works__track::-webkit-scrollbar { display: none; }
.works__track li { flex: 0 0 calc((100% - 16px) / 2); scroll-snap-align: start; min-width: 0; }
.works figure { margin: 0; position: relative; border-radius: var(--radius); overflow: hidden; aspect-ratio: 4 / 3; background: #0f2a22; }
.works img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .5s; }
.works figure:hover img { transform: scale(1.04); }
.works figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 44px 18px 16px; color: #fff; background: linear-gradient(transparent, rgba(8, 28, 25, .88)); display: flex; flex-direction: column; gap: 3px; }
.works figcaption b { font-size: 18px; }
.works figcaption span { font-size: 14.5px; color: #d3e4de; }
.works__btn { position: absolute; top: 50%; margin-top: -24px; width: 48px; height: 48px; border: 0; border-radius: 14px; background: rgba(255, 255, 255, .94); color: var(--deep); cursor: pointer; display: flex; align-items: center; justify-content: center; box-shadow: 0 6px 18px rgba(0, 0, 0, .3); }
.works__btn:hover { background: #fff; color: var(--brand); }
.works__btn--prev { left: -10px; }
.works__btn--next { right: -10px; }
@media (max-width: 860px) { .works__btn--prev { left: 8px; } .works__btn--next { right: 8px; } .works__btn { width: 42px; height: 42px; margin-top: -21px; } }
@media (max-width: 560px) { .works__track li { flex-basis: 100%; } .works figcaption b { font-size: 16px; } }

/* =====================================================================
   Внутренние страницы: оформление контента старого сайта в новом дизайне
   ===================================================================== */
.hide { display: none !important; }
.clearfix::after { content: ""; display: table; clear: both; }
.pull-right { float: right; } .pull-left { float: left; }
.text-center { text-align: center; } .text-right { text-align: right; }
.text-nowrap { white-space: nowrap; } .text-uppercase { text-transform: uppercase; }
.bold { font-weight: 700; } .small { font-size: .875em; } .large { font-size: 1.12em; }
.db { display: block; width: 100%; } .dib { display: inline-block; }
.ph15 { padding: 15px 0; } .ph5 { padding: 5px 0; } .pv5 { padding: 0 5px; } .p0 { padding: 0 !important; } .p5 { padding: 5px; } .m-5 { margin-left: -5px; margin-right: -5px; }
.img-responsive { max-width: 100%; height: auto; display: block; }
.container { width: min(1200px, calc(100% - 32px)); margin: 0 auto; }
.h3 { font-size: clamp(22px, 2.4vw, 28px); font-weight: 800; line-height: 1.25; }
.h4 { font-size: 21px; font-weight: 800; line-height: 1.3; }
.h5 { font-size: 18px; font-weight: 800; line-height: 1.3; }
.title { font-weight: 800; }
.well { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.list-inline { list-style: none; margin: 0; padding: 0; }

/* сетка старого сайта (подмножество) */
.row { display: flex; flex-wrap: wrap; margin-left: -12px; margin-right: -12px; }
.row > [class*="col-"] { box-sizing: border-box; padding-left: 12px; padding-right: 12px; width: 100%; }
.row > .col-xs-1 { width: 8.3333%; } .row > .col-xs-2 { width: 16.6667%; } .row > .col-xs-3 { width: 25%; } .row > .col-xs-4 { width: 33.3333%; }
.row > .col-xs-5 { width: 41.6667%; } .row > .col-xs-6 { width: 50%; } .row > .col-xs-7 { width: 58.3333%; } .row > .col-xs-8 { width: 66.6667%; }
.row > .col-xs-9 { width: 75%; } .row > .col-xs-10 { width: 83.3333%; } .row > .col-xs-11 { width: 91.6667%; } .row > .col-xs-12 { width: 100%; }
@media (min-width: 768px) {
  .row > .col-sm-1 { width: 8.3333%; } .row > .col-sm-2 { width: 16.6667%; } .row > .col-sm-3 { width: 25%; } .row > .col-sm-4 { width: 33.3333%; }
  .row > .col-sm-5 { width: 41.6667%; } .row > .col-sm-6 { width: 50%; } .row > .col-sm-7 { width: 58.3333%; } .row > .col-sm-8 { width: 66.6667%; }
  .row > .col-sm-9 { width: 75%; } .row > .col-sm-10 { width: 83.3333%; } .row > .col-sm-12 { width: 100%; }
}
@media (min-width: 992px) {
  .row > .col-md-1 { width: 8.3333%; } .row > .col-md-2 { width: 16.6667%; } .row > .col-md-3 { width: 25%; } .row > .col-md-4 { width: 33.3333%; }
  .row > .col-md-5 { width: 41.6667%; } .row > .col-md-6 { width: 50%; } .row > .col-md-7 { width: 58.3333%; } .row > .col-md-8 { width: 66.6667%; }
  .row > .col-md-9 { width: 75%; } .row > .col-md-10 { width: 83.3333%; } .row > .col-md-12 { width: 100%; }
}
@media (min-width: 1200px) {
  .row > .col-lg-3 { width: 25%; } .row > .col-lg-4 { width: 33.3333%; } .row > .col-lg-6 { width: 50%; } .row > .col-lg-8 { width: 66.6667%; } .row > .col-lg-9 { width: 75%; }
}

/* страница */
.page-inner { padding-bottom: 20px; }
.crumbs { margin: 0; padding: 22px 0 8px; font-size: 15px; color: var(--muted); }
.crumbs .container { width: auto; margin: 0; }
.crumbs__list { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; }
.crumbs li { display: inline-flex; align-items: center; gap: 6px; }
.crumbs li + li::before { content: "/"; color: #b4bbb7; }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--brand); text-decoration: underline; }
.crumbs .active { color: var(--ink); font-weight: 600; }
.layout { padding-top: 12px; }
.prose h1 { margin: 6px 0 22px; }
.prose a { color: var(--brand); }
.prose img { max-width: 100%; height: auto; border-radius: 12px; }
.prose .btn { color: #fff; }
.prose .btn--outline { color: var(--brand); }
.prose .btn--outline:hover { background: var(--brand); color: #fff; }
.prose--wide { max-width: none; }
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 0 0 1.4em; border-radius: 12px; }
.prose table { border-collapse: collapse; width: 100%; min-width: 460px; background: #fff; font-size: 16.5px; line-height: 1.5; }
.prose th, .prose td { border: 1px solid var(--line); padding: 10px 14px; text-align: left; vertical-align: top; }
.prose thead th, .prose tr:first-child th { background: var(--stone); font-weight: 800; }
.prose tbody tr:nth-child(even) td { background: #fbfaf7; }
.prose ol { padding-left: 1.3em; }
.prose blockquote { margin: 1.2em 0; padding: 14px 20px; border-left: 4px solid var(--brand); background: var(--stone); border-radius: 0 12px 12px 0; }
.prose hr { border: 0; border-top: 1px solid var(--line); margin: 2em 0; }
.page-header h1 { margin: 0 0 22px; }
.image-fulltext { margin: 0 0 28px; }
.ph15:empty { display: none; }

/* видео из старых страниц */
.video-responsive { position: relative; aspect-ratio: 16 / 9; border-radius: 14px; overflow: hidden; background: #000; margin: 0 0 1.4em; }
.video-responsive iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-responsive #video-schema { position: absolute; inset: 0; }

/* слайдеры картинок */
.slider { position: relative; border-radius: var(--radius); overflow: hidden; margin: 0 0 24px; background: #0f2a22; }
.slider__track { list-style: none; margin: 0; padding: 0; display: flex; overflow-x: auto; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.slider__track::-webkit-scrollbar { display: none; }
.slider__track li { flex: 0 0 100%; scroll-snap-align: start; min-width: 0; }
.slider__track a { display: block; }
.slider__track img { display: block; width: 100%; height: auto; aspect-ratio: 2 / 1; object-fit: cover; border-radius: 0; }
.slider__btn { position: absolute; top: 50%; margin-top: -21px; width: 42px; height: 42px; border: 0; border-radius: 12px; background: rgba(255, 255, 255, .92); color: var(--deep); cursor: pointer; display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 14px rgba(0, 0, 0, .25); }
.slider__btn:hover { background: #fff; color: var(--brand); }
.slider__btn--prev { left: 10px; } .slider__btn--next { right: 10px; }

/* боковая колонка: модули старого сайта */
.aside .mod h2, .aside .mod h3, .aside .mod .h5, .aside .mod .title { margin: 0 0 14px; font-size: 20px; line-height: 1.3; }
.aside .mod h2 a, .aside .mod .title a { color: var(--ink); text-decoration: none; }
.aside .mod h2 img { display: block; max-height: 30px; width: auto; margin-top: 6px; }
.aside .mod .item { margin: 0 0 14px; padding: 0 !important; width: 100% !important; float: none; }
.aside .mod figure.row { display: flex; gap: 12px; align-items: center; margin: 0; }
.aside .mod figure.row > div { width: 84px; flex: none; padding: 0; }
.aside .mod figure.row > figcaption { flex: 1; min-width: 0; padding: 0; width: auto; }
.aside .mod figure img { width: 84px; height: 66px; object-fit: cover; border-radius: 10px; display: block; }
.aside .mod figcaption a { font-weight: 700; font-size: 15.5px; line-height: 1.35; text-decoration: none; color: var(--ink); }
.aside .mod figcaption a:hover { color: var(--brand); }
.aside .mod .info .small, .aside .mod .info .big { font-size: inherit; }
.aside .mod .slider { margin: 0; }
.aside .mod ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.aside .mod--nav a { font-weight: 600; text-decoration: none; }
.aside .mod [class*="elfsight-app"] { min-height: 120px; }
.aside { min-width: 0; }

/* категории: список карточек и шапка раздела */
.page-head { background: var(--deep); color: #fff; padding: 56px 0 44px; }
.page-head h1 { color: #fff; margin: 0 0 16px; max-width: 28ch; }
.page-head p { color: #d6e5e1; font-size: 19px; max-width: 70ch; margin: 0 0 12px; }
.page-head .preview-caption, .page-head .category-desc { max-width: 900px; }
.page-head .container { width: auto; }
.items-wrapper { display: grid !important; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 22px; margin: 0 0 30px !important; }
.items-wrapper > .item { width: auto !important; max-width: none !important; padding: 0 !important; float: none; margin: 0; min-width: 0; }
.items-wrapper figure { margin: 0; height: 100%; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); display: flex; flex-direction: column; padding: 0; }
.items-wrapper figure .img-block, .items-wrapper figure .img-block a { display: block; }
.items-wrapper figure .img-block img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 0; display: block; }
.items-wrapper figcaption, .items-wrapper .info { padding: 18px 20px 22px; display: flex; flex-direction: column; gap: 10px; flex: 1; font-size: 16px; line-height: 1.55; }
.items-wrapper figcaption h2, .items-wrapper figcaption .h4, .items-wrapper .info h2, .items-wrapper .info h3, .items-wrapper .info .h4 { margin: 0; font-size: 20px; line-height: 1.3; }
.items-wrapper h2 a, .items-wrapper h3 a, .items-wrapper .info a { color: var(--ink); text-decoration: none; font-weight: 800; }
.items-wrapper h2 a:hover, .items-wrapper h3 a:hover { color: var(--brand); }
.items-wrapper .desc p, .items-wrapper .info p { font-size: 16px; line-height: 1.55; margin: 0; color: var(--muted); }
.items-wrapper figcaption .btn, .items-wrapper .btn { margin-top: auto; min-height: 46px; color: #fff; background: var(--brand); text-decoration: none; }
.items-wrapper .btn i, .btn i { display: none; }
/* карточки статей: фото сверху, текст ниже */
.c-objects > .row { display: block; margin: 0; }
.c-objects > .row > [class*="col-"] { width: 100% !important; padding: 0 !important; }
.c-objects .info { display: flex; }
.c-objects .info .small, .c-objects .info .date { color: var(--muted); font-size: 14.5px; }
.pagination { display: flex; gap: 8px; list-style: none; padding: 0; margin: 28px 0 0; flex-wrap: wrap; }
.pagination a, .pagination span { display: inline-flex; min-width: 42px; height: 42px; align-items: center; justify-content: center; border: 1px solid var(--line); border-radius: 12px; text-decoration: none; }
.pagination .active a, .pagination .active span { background: var(--brand); color: #fff; border-color: var(--brand); }
.extra .page-header h3, .extra h3 { margin: 28px 0 14px; }
.extra .items-wrapper { margin-top: 10px !important; }

/* SEO-текст «О компании» под страницей */
.seo-about .prose, .why-us .prose { max-width: 980px; }
.seo-about .title, .seo-about .h3 { margin: 0 0 12px; }

/* лайтбокс для фото (вместо fancybox) */
.lightbox { position: fixed; inset: 0; z-index: 300; background: rgba(8, 24, 18, .92); display: flex; align-items: center; justify-content: center; padding: 20px; }
.lightbox[hidden] { display: none; }
.lightbox img { display: block; margin: auto; max-width: calc(100vw - 40px); max-height: calc(100vh - 40px); width: auto; height: auto; object-fit: contain; border-radius: 12px; box-shadow: 0 20px 60px rgba(0, 0, 0, .5); }
.lightbox button { position: fixed; z-index: 2; border: 0; width: 46px; height: 46px; border-radius: 14px; background: rgba(255, 255, 255, .92); color: var(--deep); font-size: 28px; line-height: 1; cursor: pointer; display: flex; align-items: center; justify-content: center; touch-action: manipulation; }
.lightbox button:hover { background: #fff; }
.lightbox__close { top: 16px; right: 16px; } .lightbox__prev { left: 16px; top: 50%; margin-top: -23px; } .lightbox__next { right: 16px; top: 50%; margin-top: -23px; }
a.fancybox { cursor: zoom-in; }

/* карточки статей: вся карточка кликабельна (в т.ч. надпись «Читать статью →», которая была обычным текстом) */
.card { position: relative; }
.card__body h3 a::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.card:has(.card__body h3 a) { cursor: pointer; }
.card:hover .more { text-decoration: underline; }
/* подвал: пять колонок и юридическая строка */
.footer__grid--5 { grid-template-columns: 1.5fr 1.2fr 1fr 1fr 1.3fr; gap: 28px; }
/* заголовки колонок подвала — зелёный из логотипа (#8bc01a в logo-white.svg) */
.footer h4 { color: #8bc01a; }
/* подвал: четыре колонки (бренд, услуги, компания, контакты) */
.footer__grid--4 { grid-template-columns: 1.5fr 1.3fr 1.2fr 1.4fr; gap: 32px; }
@media (max-width: 1000px) { .footer__grid--4 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .footer__grid--4 { grid-template-columns: 1fr; } }
.footer__legal { font-size: 13px; line-height: 1.5; opacity: .75; margin-top: 12px; }
.footer__legal a { color: inherit; text-decoration: underline; }
@media (max-width: 1100px) { .footer__grid--5 { grid-template-columns: 1fr 1fr 1fr; } }
@media (max-width: 700px) { .footer__grid--5 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .footer__grid--5 { grid-template-columns: 1fr; } }

body.inner { padding-top: 0; }
@media (max-width: 860px) { body.inner { padding-top: 77px; } .page-head { padding: 36px 0 30px; } }

/* уточнения специфичности */
.prose .slider__track, .aside .mod .slider__track { display: flex; padding: 0; margin: 0; list-style: none; gap: 0; }
.prose .slider__track li, .aside .mod .slider__track li { margin: 0; padding: 0; }
.prose .text-uppercase, .prose h1, .prose h2, .prose h3, .prose h4 { text-transform: none; }
.seo-about .prose, .why-us .prose { max-width: none; }
.seo-about .wrap { width: min(1200px, calc(100% - 32px)); }

/* статьи и советы: по две карточки в ряд (при боковой колонке три получаются слишком тесными) */
.layout .items-wrapper { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 640px) { .layout .items-wrapper { grid-template-columns: 1fr; } }

/* кнопки старого сайта: btn-primary / btn-default / btn-grey */
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: #3d6208; color: #fff; }
.btn-default, .btn-grey { background: var(--stone); color: var(--ink); border-color: var(--line); }
.btn-default:hover, .btn-grey:hover { background: #e9e6dd; color: var(--ink); }
.btn-primary-o { border-color: var(--brand); color: var(--brand); background: transparent; }
.prose .btn-default, .prose .btn-grey { color: var(--ink); }
.btn.db { width: 100%; }

/* логотип-кружок внутри заголовков (например, «О Ремонт ДОМ») */
.prose h1 img, .prose h2 img, .prose h3 img, .prose .h3 img { display: inline; height: .85em; width: auto; max-width: none; border-radius: 0; vertical-align: baseline; margin: 0 .1em; box-shadow: none; }

/* меню разделов в боковой колонке */
.aside .mod--nav ul { display: block; list-style: none; margin: 0; padding: 0; }
.aside .mod--nav li { margin: 0; padding: 0; }
.aside .mod--nav li a, .aside .mod--nav li > span { display: block; padding: 6px 0; font-size: 15.5px; line-height: 1.35; }
.aside .mod--nav ul ul { margin: 2px 0 6px 6px; padding-left: 12px; border-left: 2px solid var(--line); }
.aside .mod--nav .title, .aside .mod--nav h2, .aside .mod--nav .h5 { margin-bottom: 8px; }
.aside .mod--nav .nav > li > a { background: none; }

/* значки Font Awesome из старого контента (звёзды рейтинга и несколько иконок) без загрузки шрифта */
.fa { display: inline-block; font-style: normal; font-weight: 400; line-height: 1; }
.fa-2x { font-size: 2em; } .fa-4x { font-size: 4em; }
.fa-star::before { content: "\2605"; color: #f2a516; }
.fa-star-o::before { content: "\2606"; color: #f2a516; }
.fa-envelope-o::before, .fa-envelope::before { content: "\2709"; }
.fa-phone::before, .fa-volume-control-phone::before { content: "\260E"; }
.fa-clock-o::before { content: "\25F7"; }
.fa-map-marker::before { content: "\2316"; }
.fa-home::before { content: "\2302"; }
.fa-check::before { content: "\2713"; }
.fa-long-arrow-right::before { content: "\2192"; }
.fa-calendar::before { content: "\25A6"; }

/* колонки сетки страницы не распирают экран телефона */
.layout > * { min-width: 0; }
@media (max-width: 1100px) { .layout { grid-template-columns: minmax(0, 1fr); } }
.prose { min-width: 0; overflow-wrap: break-word; }
.prose iframe, .prose video { max-width: 100%; }

.row > * { min-width: 0; max-width: 100%; }

/* портфолио: карточки-фотографии в две колонки */
.portfolio-layout { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.portfolio-layout > h1, .portfolio-layout > .portfolio-description { grid-column: 1 / -1; }
.portfolio-description blockquote { margin: 0 0 8px; padding: 18px 22px; }
.portfolio-description h2, .portfolio-description h2 span { font-size: 19px !important; font-weight: 600; margin: 0; line-height: 1.5; text-transform: none; }
.portfolio-layout figure { margin: 0; display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.portfolio-layout figure > a { order: 1; display: block; overflow: hidden; }
.portfolio-layout figure > h2 { order: 2; margin: 0; padding: 18px 22px 6px; font-size: 21px; line-height: 1.3; }
.portfolio-layout figure > figcaption { order: 3; padding: 0 22px 22px; color: var(--muted); font-size: 16px; line-height: 1.6; }
.portfolio-layout figure > figcaption p { margin: 0; }
.portfolio-layout figure img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 0; display: block; transition: transform .5s; }
.portfolio-layout figure:hover img { transform: scale(1.04); }
@media (max-width: 640px) { .portfolio-layout { grid-template-columns: 1fr; } }
@media (min-width: 1000px) {
  .portfolio-layout { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .portfolio-layout figure > h2 { font-size: 18px; padding: 16px 18px 6px; }
  .portfolio-layout figure > figcaption { font-size: 15px; padding: 0 18px 18px; }
}
.portfolio-layout figure[hidden] { display: none; }
/* кнопки-фильтры портфолио */
.pf-filter { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 10px; margin: 4px 0 0; }
.pf-btn { appearance: none; border: 1px solid var(--line); background: #fff; color: var(--deep); font: inherit; font-weight: 600; font-size: 16px; line-height: 1; padding: 12px 18px; border-radius: 999px; cursor: pointer; transition: background .2s, color .2s, border-color .2s; }
.pf-btn span { margin-left: 4px; font-weight: 500; opacity: .6; }
.pf-btn:hover { border-color: var(--deep); }
.pf-btn.is-active { background: var(--deep); border-color: var(--deep); color: #fff; }
.pf-btn:focus-visible { outline: 3px solid rgba(26, 107, 82, .4); outline-offset: 2px; }
.pf-note { grid-column: 1 / -1; margin: -8px 0 0; color: var(--muted); font-size: 15px; }
.aside .mod--nav li { display: block !important; float: none !important; }
.aside .mod--nav li > span, .aside .mod--nav li > a { display: block; }
.aside .mod--nav ul ul { display: block; }

/* форма-полоса внизу страницы (вместо формы в боковой колонке) */
.layout--single { grid-template-columns: minmax(0, 1fr); }
.layout--single > .prose { max-width: none; }
.cta { padding: 44px 0; }
.cta-card { display: grid; grid-template-columns: minmax(0, 1fr); gap: 22px; }
.cta-card__text h2 { color: #fff; margin: 0 0 8px; font-size: clamp(24px, 2.6vw, 32px); }
.cta-card__text p { margin: 0; color: #cfe0dc; font-size: 17px; }
.cta-card__text a { color: #b8dc6a; font-weight: 800; text-decoration: none; white-space: nowrap; }
.cta-form { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.6fr) auto; gap: 14px; align-items: start; }
.cta-form .field { margin: 0; }
.cta-form .field label { color: #fff; }
.cta-form .field input { border-color: transparent; }
.cta-form .field .err { color: #ffb4ab; }
.cta-form .btn { width: auto; margin-top: 29px; min-height: 52px; padding: 12px 26px; }
.cta-form .consent { grid-column: 1 / -1; margin: 0; color: #a9c0bb; font-size: 13.5px; }
.cta-card .ok { display: none; text-align: center; padding: 18px 8px; color: #fff; font-size: 18px; }
.cta-card .ok b { display: block; font-size: 24px; color: #b8dc6a; margin-bottom: 6px; }
.cta-card.is-sent form { display: none; }
.cta-card.is-sent .ok { display: block; }
@media (max-width: 1100px) {
  .cta-form { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .cta-form .field--wide { grid-column: 1 / -1; }
  .cta-form .btn { grid-column: 1 / -1; width: 100%; margin-top: 4px; }
}
@media (max-width: 560px) { .cta-form { grid-template-columns: minmax(0, 1fr); } }

/* кнопки в карточках: белый текст, одинаковая высота карточек и кнопка внизу */
.items-wrapper a.btn, .items-wrapper .info a.btn, .items-wrapper figcaption a.btn { color: #fff !important; background: var(--brand); text-decoration: none; font-weight: 700; justify-content: center; }
.items-wrapper a.btn:hover { background: #3d6208; }
.items-wrapper figure { height: 100%; }
.items-wrapper figure > .row { flex: 1; display: flex !important; flex-direction: column; margin: 0; }
.items-wrapper figure > .row > [class*="col-"]:last-child { flex: 1; display: flex; flex-direction: column; }
.items-wrapper .info { flex: 1; }
.items-wrapper .info .btn, .items-wrapper figcaption .btn { margin-top: auto; }
.items-wrapper .info p { margin: 0; }

/* разделы сайта (бывшее «Главное меню» из боковой колонки) */
.site-links { padding: 40px 0; }
.site-links h2 { margin: 0 0 18px; font-size: 24px; }
.site-links__cols { columns: 3 240px; column-gap: 32px; }
.site-links__cols ul { list-style: none; margin: 0; padding: 0; break-inside: avoid; }
.site-links__cols li { margin: 0; padding: 0; break-inside: avoid; }
.site-links__cols li a, .site-links__cols li > span { display: block; padding: 5px 0; font-size: 16px; text-decoration: none; color: var(--ink); }
.site-links__cols li a:hover { color: var(--brand); }
.site-links__cols ul ul { padding-left: 14px; border-left: 2px solid var(--line); margin: 2px 0 8px; }
.site-links__cols .title, .site-links__cols h3 { display: none; }

/* отзывы клиентов: карточки */
.testimonials-intro-text { background: var(--stone); border-radius: var(--radius); padding: 18px 22px; margin: 0 0 18px; max-width: 460px; }
.testimonials-intro-text table { min-width: 0; background: transparent; font-size: 16px; }
.testimonials-intro-text th, .testimonials-intro-text td { border: 0; padding: 4px 10px 4px 0; }
.testimonials-intro-text tbody tr:nth-child(even) td { background: transparent; }
.testimonials-list { margin: 0 0 22px; }
.testimonial { display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 0; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.testimonial > .person-text { order: -1; margin: 0 !important; padding: 24px 18px !important; background: var(--stone); text-align: center; font-size: 14.5px; line-height: 1.5; color: var(--muted); z-index: auto; }
.testimonial > .person-text img { width: 96px; height: 96px; object-fit: cover; border-radius: 50% !important; box-shadow: none !important; margin: 0 auto 10px !important; display: block; }
.testimonial > .person-text [itemprop="name"] { color: var(--ink) !important; font-weight: 800; font-size: 17px !important; text-decoration: none !important; margin: 0 0 8px !important; display: block; }
.testimonial > .person-text p { margin: 0; }
.testimonial > .block-text { padding: 24px 28px; position: relative; font-size: 17px; line-height: 1.65; }
.testimonial .testim-title { display: block; font-weight: 800; font-size: 20px; margin-bottom: 10px; }
.testimonial .block-text > div { margin: 0; }
.testimonial .block-text > div:not([itemprop]) { display: inline-flex; align-items: center; gap: 6px; margin: 0 14px 6px 0; padding: 4px 12px; border-radius: 999px; background: var(--stone); font-size: 14px; font-weight: 600; }
.testimonial .tm_stars { display: inline-flex; gap: 1px; }
.testimonial [itemprop="reviewBody"] { margin-top: 12px; }
.testimonial [itemprop="reviewBody"] p { margin: 0 0 .8em; font-size: 17px !important; }
.testimonial ins { display: none; }
@media (max-width: 760px) { .testimonial { grid-template-columns: 1fr; } .testimonial > .person-text { padding: 18px !important; } }

.extra .row { margin-left: 0; margin-right: 0; }
.extra .row > [class*="col-"] { padding-left: 0; padding-right: 0; }
.cta-form .field label { text-align: left; display: block; }
.cta-card__text { text-align: left; }
.cta-form .consent { text-align: left; }

/* хлебные крошки: без отступа слева, вровень с заголовком */
.crumbs__list { list-style: none; margin: 0; padding: 0; }
.crumbs .container { padding: 0; }

/* низ страницы вместо боковой колонки */
.layout--single .prose, .layout--single .blog-list { max-width: none; }
.layout--single > article.prose > * { max-width: none; }
.layout--single .prose p, .layout--single .prose ul, .layout--single .prose ol { max-width: 980px; }
.layout--single .prose h1, .layout--single .prose h2, .layout--single .prose h3 { max-width: 980px; }
.layout--single .items-wrapper { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.page-bottom h2 { margin: 0 0 22px; }
.related-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 22px; }
.related-grid .card { display: flex; flex-direction: column; text-decoration: none; color: inherit; }
.related-grid .card__img a, .card__img > a { display: block; width: 100%; height: 100%; }
.related-grid .card__img img { width: 100%; height: 100%; object-fit: cover; display: block; border-radius: 0; }
.related-grid .card__body h3 { font-size: 18px; line-height: 1.35; margin: 0 0 8px; }
.related-grid .card__body h3 a { color: var(--ink); text-decoration: none; }
.related-more { margin: 22px 0 0; font-weight: 700; }
.proof__grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 22px; }
.proof__grid--two { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); }
.proof .box h2, .proof .box h3, .proof .box .title { margin: 0 0 14px; font-size: 22px; }
.proof .box h2 a { color: var(--ink); text-decoration: none; }
.proof .box h2 img { display: inline; height: 28px; width: auto; vertical-align: middle; }
.proof [class*="elfsight-app"] { min-height: 160px; }
.keypages__list { display: flex; flex-wrap: wrap; gap: 12px; }
.keypage { display: inline-flex; align-items: center; min-height: 48px; padding: 10px 20px; background: #fff; border: 1px solid var(--line); border-radius: 14px; font-weight: 700; text-decoration: none; color: var(--ink); transition: border-color .2s, color .2s, transform .2s; }
.keypage:hover { border-color: var(--brand); color: var(--brand); transform: translateY(-1px); }
.site-links { padding: 40px 0; }
@media (max-width: 860px) { .proof__grid--two { grid-template-columns: minmax(0, 1fr); } }
.layout--single .prose .slider__track { max-width: none; }
.layout--single .prose .table-scroll, .layout--single .prose .video-responsive { max-width: 980px; }

/* слайдеры внутри блоков .box (там по умолчанию список-сетка) */
.box .slider__track, .proof .slider__track { display: flex !important; gap: 0 !important; }
.box .slider__track li { margin: 0; padding: 0; }
.proof__insta .slider { margin: 0; }
.proof__insta .slider__track img { aspect-ratio: 4 / 5; }

.proof__grid { align-items: start; }
.proof .elfsight-app-d2a490c7-5005-4750-8b65-e4f21ab92641, .proof [class*="elfsight-app"] { display: block; width: 100%; min-height: 0; }
.proof [class*="elfsight-app"] > p { margin: 0; padding: 10px 0; font-weight: 700; }

/* отзывы: отступ между карточками */
.testimonials-list { margin: 0 0 28px !important; }
.testimonial { margin: 0 0 28px; }
.testimonials-list > .testimonial:last-child { margin-bottom: 0; }

/* статьи и советы: ровно по три карточки в ряд */
.blog-list--articles .items-wrapper, .layout--single .blog-list--articles .items-wrapper { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.items-wrapper > .item { grid-column: auto !important; grid-row: auto !important; }
@media (max-width: 960px) { .blog-list--articles .items-wrapper, .layout--single .blog-list--articles .items-wrapper { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .blog-list--articles .items-wrapper, .layout--single .blog-list--articles .items-wrapper { grid-template-columns: 1fr; } }

/* переход между нижними блоками: без белой полосы, текст «О компании» вровень с остальными блоками */
.page-inner { padding-bottom: 0; }
.seo-about .container, .seo-about .text, .seo-about .inner, .seo-about .moduletable_about-cooperation { width: auto; max-width: none; margin: 0; padding: 0; }
.seo-about .wrap { width: min(1200px, calc(100% - 32px)); margin: 0 auto; }
.seo-about { border-top: 1px solid var(--line); }

/* контакты и другие страницы: значки в строку с текстом, кнопка по размеру текста */
.prose .fa-2x, .prose .fa-4x { font-size: 1.1em; }
.prose p .fa, .prose div .fa { display: inline-block; width: 1.3em; margin-right: 6px; text-align: center; vertical-align: -0.08em; font-size: 1.1em; }
.prose .btn.db, .prose a.btn.db, .prose button.btn.db { width: auto; display: inline-flex; margin: 8px 0 18px; }
.prose p { overflow-wrap: anywhere; }
.prose iframe { max-width: 100%; border: 0; border-radius: 14px; }

/* контакты: строки без значка выровнены по тексту строк со значком */
.page-contacts p { margin: 0 0 14px; }
.page-contacts p:not(:has(.fa)) { padding-left: calc(1.3em + 6px); }
.page-contacts p .fa { color: var(--brand); }

/* карточки «Читайте также»: по три в ряд */
.related-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 960px) { .related-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .related-grid { grid-template-columns: 1fr; } }
.seo-about { border-top: 0; }
.page-bottom.keypages { padding-bottom: 52px; }

/* цены: разделы отделены друг от друга */
.prose table { border-collapse: separate; border-spacing: 0; }
.prose td[id^="prais_"] { background: var(--deep); color: #fff; text-align: left !important; padding: 18px 22px; border: 0; border-top: 36px solid #fff; scroll-margin-top: 100px; }
.prose td[id^="prais_"]:first-child { border-radius: 14px 14px 0 0; }
.prose td[id^="prais_"] > strong:first-child { font-size: 22px; vertical-align: middle; }
.prose td[id^="prais_"] p { display: inline; margin: 0; }
.prose td[id^="prais_"] p:has(img) { float: left; margin-right: 14px; }
.prose td[id^="prais_"] img { height: 46px; width: auto; border-radius: 0; background: #fff; padding: 4px; border-radius: 10px; vertical-align: middle; }
.prose td[id^="prais_"] > strong:last-child { float: right; }
.prose td[id^="prais_"] a.btn { width: auto; min-height: 40px; padding: 6px 18px; margin: 0; background: rgba(255, 255, 255, .14); color: #fff; border-color: rgba(255, 255, 255, .35); font-size: 15px; }
.prose td[id^="prais_"] a.btn:hover { background: #fff; color: var(--deep); }
.prose td[id^="prais_"]::after { content: ""; display: block; clear: both; }
.prose td.service-item { width: 62%; }

/* форма-полоса: кнопка той же высоты, что и поля */
.cta-form .field input { height: 57px; box-sizing: border-box; }
.cta-form .btn { height: 57px; min-height: 57px; box-sizing: border-box; }

/* карточки услуг: одинаковая высота, кнопки на одной линии */
.items-wrapper > .item { display: flex; }
.items-wrapper > .item > figure { width: 100%; }
.items-wrapper figure > figcaption { display: flex; flex-direction: column; flex: 1; }
.items-wrapper figure > figcaption .desc { flex: 1; }

/* переходы между блоками внизу страницы: тонкая линия */
.page-bottom, .seo-about, .why-us, .site-links { border-top: 1px solid var(--line); }

/* «Почему выбирают нас»: карточки */
.why-us .container { width: auto; margin: 0; }
.why-us header { margin: 0 0 24px; }
.why-us h2 { margin: 0; }
.why-us .yellow { color: var(--brand); }
.why-us .row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; margin: 0; }
.why-us .row > .item, .why-us .item { width: auto !important; max-width: none; padding: 0 !important; }
.why-us figure { margin: 0; height: 100%; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 24px; display: grid; grid-template-columns: 56px 1fr; grid-template-areas: "icon text" "num text"; gap: 4px 16px; align-items: center; box-shadow: var(--shadow); }
.why-us .icon { grid-area: icon; width: 56px; height: 56px; border-radius: 16px; background: var(--brand-soft); display: flex; align-items: center; justify-content: center; }
.why-us .icon .fa { font-size: 26px !important; color: var(--brand); width: auto; margin: 0; }
.why-us .num { grid-area: num; font-size: 13px; font-weight: 800; color: var(--muted); text-align: center; }
.why-us figure p { grid-area: text; margin: 0; font-size: 18px; font-weight: 700; line-height: 1.4; }
@media (max-width: 860px) { .why-us .row { grid-template-columns: 1fr; } }

.home .seo-about, body.home .seo-about { border-top: 1px solid var(--line); }

/* заголовки разделов цен: зелёный фон во всех строках (перебиваем «зебру») */
.prose tbody tr td[id^="prais_"], .prose tbody tr:nth-child(even) td[id^="prais_"], .prose tbody tr:nth-child(odd) td[id^="prais_"] { background: var(--deep) !important; color: #fff !important; }
.prose td[id^="prais_"] strong, .prose td[id^="prais_"] a.btn { color: #fff; }
.prose td[id^="prais_"] a.btn:hover { color: var(--deep); }

/* отступы вокруг картинок, слайдеров, видео и таблиц внутри текста */
.prose .clearfix > img, .prose article > img, .prose > img, .prose div > img.img-responsive, .prose span > img.img-responsive { display: block; margin: 28px 0; }
.prose p.text-center > img, .prose p > img.img-responsive { display: inline-block; margin: 14px auto; max-width: 100%; height: auto; }
.prose p.text-center { margin: 22px 0; }
.prose a.fancybox, .prose figure > a.image { display: block; }
.prose .image-fulltext, .prose .slider { margin: 28px 0; }
.prose .page-header + .image-fulltext, .prose h1 + .image-fulltext, .prose h1 + .slider { margin-top: 8px; }
.prose .video-responsive { margin: 28px 0; }
.prose .table-scroll { margin: 28px 0; }
/* таблицы шире экрана: подсказка «листайте», стрелки по краям, видимая полоса прокрутки */
.scroll-hint { display: flex; align-items: center; justify-content: flex-end; gap: 8px; margin: 22px 0 -16px; font-size: 14px; color: var(--muted); }
.scroll-hint[hidden] { display: none; }
.scroll-hint span { color: var(--brand); font-weight: 700; }
.scroll-hint + .ts-wrap > .table-scroll { margin-top: 8px; }
.ts-wrap { position: relative; }
.ts-wrap > .table-scroll { scrollbar-width: thin; scrollbar-color: #9fb3a9 transparent; }
.ts-wrap > .table-scroll::-webkit-scrollbar { height: 8px; }
.ts-wrap > .table-scroll::-webkit-scrollbar-thumb { background: #9fb3a9; border-radius: 8px; }
.ts-arrow { position: absolute; top: clamp(30px, 50%, 170px); transform: translateY(-50%); z-index: 3; width: 40px; height: 40px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .96); color: var(--deep); font-size: 30px; line-height: 1; padding: 0 0 4px; cursor: pointer; box-shadow: 0 4px 14px rgba(0, 0, 0, .28); display: flex; align-items: center; justify-content: center; }
.ts-arrow[hidden] { display: none; }
.ts-arrow--prev { left: 6px; } .ts-arrow--next { right: 6px; }
.ts-arrow:hover { background: #fff; }
/* картинки-сметы (старые) в одну линию, а не друг под другом */
.prose .text-center:has(> a.fancybox) { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 16px; text-align: left; margin: 8px 0 24px; }
.prose .text-center:has(> a.fancybox) > a { flex: 1 1 280px; max-width: 420px; }
.prose .text-center:has(> a.fancybox) > a img { width: 100%; height: auto; margin: 0 !important; }
/* «Последние сметы»: отступы и линия-разделитель между сметами */
.smety-list > h3 { margin: 64px 0 12px; padding-top: 40px; border-top: 2px solid var(--line); }
.smety-list > h2 + h3 { margin-top: 24px; padding-top: 0; border-top: 0; }
.smety-list > h3 + p { margin-top: 0; }
/* смета: фото «до и после» и таблица */
.ba { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; max-width: 720px; margin: 8px 0 24px; }
.ba__item { margin: 0; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.ba__item a { display: block; }
.ba__item img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 4; object-fit: cover; border-radius: 0; }
.ba__item figcaption { padding: 10px 16px; font-weight: 600; color: var(--deep); }
.smeta td:nth-child(n+3), .smeta th:nth-child(n+3) { white-space: nowrap; text-align: right; }
.smeta__total td { background: var(--soft, #f1f5f2); }
@media (max-width: 520px) { .ba { gap: 10px; } }
.prose [itemprop="articleBody"] > :first-child { margin-top: 0; }
.prose img + p, .prose .image-fulltext + p, .prose .slider + p, .prose .video-responsive + p, .prose .table-scroll + p { margin-top: 0; }

/* все списки карточек: по три в ряд */
.items-wrapper, .layout--single .items-wrapper, .extra .items-wrapper { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 960px) { .items-wrapper, .layout--single .items-wrapper, .extra .items-wrapper { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .items-wrapper, .layout--single .items-wrapper, .extra .items-wrapper { grid-template-columns: 1fr; } }

/* цены на телефоне: таблица по ширине экрана, заголовок раздела и кнопка друг под другом */
@media (max-width: 640px) {
  .prose table { min-width: 0; font-size: 15px; }
  .prose th, .prose td { padding: 8px 10px; }
  .prose td.service-item { width: auto; }
  .prose td[id^="prais_"] { padding: 14px 16px; border-top-width: 28px; }
  .prose td[id^="prais_"] > strong:first-child { font-size: 19px; }
  .prose td[id^="prais_"] img { height: 38px; }
  .prose td[id^="prais_"] > strong:last-child { float: none; display: block; clear: both; margin-top: 12px; }
  .prose td[id^="prais_"] a.btn { width: auto; min-height: 38px; padding: 6px 16px; }
}
/* фиксированные колонки — только у таблицы цен (3 колонки); остальные таблицы прокручиваются вбок */
@media (max-width: 640px) {
  .prose table:has(td[id^="prais_"]) { table-layout: fixed; width: 100%; }
  .prose table:has(td[id^="prais_"]) td:nth-child(1), .prose table:has(td[id^="prais_"]) th:nth-child(1) { width: 52%; overflow-wrap: anywhere; }
  .prose table:has(td[id^="prais_"]) td:nth-child(2), .prose table:has(td[id^="prais_"]) th:nth-child(2) { width: 20%; white-space: nowrap; }
  .prose table:has(td[id^="prais_"]) td:nth-child(3), .prose table:has(td[id^="prais_"]) th:nth-child(3) { width: 28%; }
  /* остальные таблицы: колонки по содержимому, при нехватке места — горизонтальная прокрутка внутри блока */
  .prose .table-scroll > table:not(:has(td[id^="prais_"])) { table-layout: auto; min-width: 540px; width: 100%; }
  .prose .table-scroll > table.smeta { min-width: 680px; }
  .prose .table-scroll { box-shadow: inset -14px 0 12px -14px rgba(0, 0, 0, .25); }
  .prose th, .prose td { overflow-wrap: break-word; hyphens: auto; }
  .prose table:has(td[id^="prais_"]) th:nth-child(2) { white-space: normal; font-size: 14px; }
  /* маленькая таблица рейтинга на странице отзывов: свои размеры, без принудительной ширины */
  .prose .testimonials-intro-text .table-scroll > table { min-width: 0 !important; width: auto !important; }
  .prose .testimonials-intro-text .table-scroll { box-shadow: none; }
  /* таблицы статей: строка = карточка, подписи колонок слева; прокрутки вбок нет */
  .prose .table-scroll:has(> table.tbl-cards) { box-shadow: none; overflow: visible; }
  .prose .table-scroll > table.tbl-cards { min-width: 0 !important; width: 100% !important; display: block; background: transparent; }
  .tbl-cards thead { display: none; }
  .tbl-cards tbody, .tbl-cards tr { display: block; }
  .tbl-cards tr { margin: 0 0 14px; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; background: #fff; }
  .prose .tbl-cards tbody tr:nth-child(even) td { background: #fff; }
  .tbl-cards td { display: flex; justify-content: space-between; gap: 14px; border: 0; border-bottom: 1px solid var(--line); padding: 10px 14px; text-align: right; }
  .tbl-cards td:last-child { border-bottom: 0; }
  .tbl-cards td::before { content: attr(data-label); flex: 0 0 34%; text-align: left; font-weight: 700; color: var(--deep); }
  .prose .tbl-cards td:first-child { display: block; text-align: left; font-weight: 700; background: var(--stone); }
  .tbl-cards td:first-child::before { display: none; }
}
/* совсем узкие экраны (320 px): цены и рейтинг отзывов без выхода за край */
@media (max-width: 360px) {
  .prose table:has(td[id^="prais_"]) { font-size: 13.5px; }
  .prose table:has(td[id^="prais_"]) td, .prose table:has(td[id^="prais_"]) th { padding: 6px 6px; }
  .prose table:has(td[id^="prais_"]) td:nth-child(1), .prose table:has(td[id^="prais_"]) th:nth-child(1) { width: 46%; }
  .prose table:has(td[id^="prais_"]) td:nth-child(2), .prose table:has(td[id^="prais_"]) th:nth-child(2) { width: 25%; white-space: normal; }
  .prose table:has(td[id^="prais_"]) td:nth-child(3), .prose table:has(td[id^="prais_"]) th:nth-child(3) { width: 29%; }
  .prose .testimonials-intro-text table, .prose .testimonials-intro-text table td, .prose .testimonials-intro-text table th { white-space: normal !important; }
  .prose .testimonials-intro-text .table-scroll > table { width: 100% !important; }
  .testimonials-intro-text .table-scroll { overflow-x: auto; }
}
/* боковое меню «Виды услуг» на странице вакансий: списком, а не в строку */
.moduletable_right-nav ul.nav { display: block; flex-direction: column; list-style: none; margin: 0 0 16px; padding: 0; }
.moduletable_right-nav ul.nav > li { display: block; float: none; margin: 0 0 6px; }
@media (max-width: 400px) {
  .pricebox table { width: 100%; table-layout: fixed; }
  .pricebox th, .pricebox td { overflow-wrap: anywhere; }
}

/* стрелка вверх в заголовках разделов цен (вместо кнопки «В разделы») и кнопка «Наверх» */
.prose td[id^="prais_"] a.price-up { display: inline-flex; align-items: center; justify-content: center; width: 42px; height: 42px; border-radius: 12px; background: rgba(255, 255, 255, .14); border: 1px solid rgba(255, 255, 255, .35); color: #fff; text-decoration: none; float: right; margin: 0; padding: 0; }
.prose td[id^="prais_"] a.price-up:hover { background: #fff; color: var(--deep); }
.prose td[id^="prais_"] a.price-up svg { display: block; }
@media (max-width: 640px) {
  .prose td[id^="prais_"] > strong:last-child { float: right; display: block; clear: none; margin-top: 0; }
  .prose td[id^="prais_"] > strong:first-child { display: inline-block; max-width: calc(100% - 120px); font-size: 19px; line-height: 1.25; }
  .prose td[id^="prais_"] p:has(img) { float: left; margin-right: 12px; }
}
.to-top { position: fixed; right: 16px; bottom: 18px; z-index: 90; width: 48px; height: 48px; border: 0; border-radius: 14px; background: var(--brand); color: #fff; cursor: pointer; display: flex; align-items: center; justify-content: center; box-shadow: 0 8px 22px rgba(0, 0, 0, .28); transition: background .18s, transform .18s; }
.to-top[hidden] { display: none; }
.to-top:hover { background: #3d6208; transform: translateY(-2px); }

/* телефон: уже боковые поля (по 12 px вместо 16), чтобы было больше места под текст */
@media (max-width: 600px) {
  .wrap, .container, .seo-about .wrap, .cta .wrap, .site-links .wrap { width: calc(100% - 24px); }
  .prose { font-size: 17.5px; }
  .box, .form-card { padding: 18px 16px; }
  .testimonial > .block-text { padding: 18px 16px; }
  .crumbs { padding-top: 16px; }
}

/* рейтинг отзывов: таблица помещается в экран телефона без прокрутки */
.testimonials-intro-text .table-scroll { overflow: visible; margin: 8px 0 0; }
.testimonials-intro-text table, .testimonials-intro-text table td { table-layout: auto; width: auto; min-width: 0; white-space: nowrap; }
.testimonials-intro-text table td:nth-child(1) { width: auto; padding-right: 14px; }
.testimonials-intro-text table td:nth-child(2) { width: auto; }
.testimonials-intro-text .tm_stars { white-space: nowrap; letter-spacing: 0; }
@media (max-width: 600px) {
  .testimonials-intro-text { max-width: none; padding: 16px; }
  .testimonials-intro-text table { width: 100%; font-size: 15px; }
  .testimonials-intro-text .fa-star::before { font-size: 17px; }
  .testimonials-intro-text table td:nth-child(2) { text-align: right; }
}

/* хлебные крошки на телефоне: одна строка, листается пальцем (текущая страница видна справа) */
@media (max-width: 700px) {
  .crumbs__list { flex-wrap: nowrap; overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; white-space: nowrap; padding-right: 24px;
    -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(to right, #000 calc(100% - 28px), transparent); }
  .crumbs__list::-webkit-scrollbar { display: none; }
  .crumbs li { flex: none; }
}

/* подвал: шесть колонок */
.footer__grid--6 { grid-template-columns: 1.5fr 1.1fr 1.2fr 1fr 1fr 1.3fr; gap: 26px; }
@media (max-width: 1200px) { .footer__grid--6 { grid-template-columns: 1fr 1fr 1fr; } }
@media (max-width: 700px) { .footer__grid--6 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .footer__grid--6 { grid-template-columns: 1fr; } }

/* зелёная плашка с заголовком на главных страницах */
.page-head__sub { margin: 0; color: #d6e5e1; font-size: 19px; max-width: 70ch; }
.page-head h1 { margin: 0 0 12px; max-width: none; }
.page-head .page-header { margin: 0; }
.page-head h1 img { display: inline; height: .8em; width: auto; vertical-align: baseline; background: none; }
.page-head + .wrap .crumbs { padding-top: 18px; }

/* «Почему выбирают нас»: значки */
.why-us .icon .fa-svg { display: flex; width: auto; margin: 0; font-size: 0; color: var(--brand); }
.why-us .icon .fa-svg svg { width: 28px; height: 28px; display: block; }

/* значки соцсетей на странице контактов (светлый фон) */
.contacts-social { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 12px; }
.contacts-social .social { margin: 0; gap: 10px; }
.page-contacts .social--contacts .soc { width: 42px; height: 42px; border-radius: 12px; color: var(--deep); background: var(--stone); box-shadow: inset 0 0 0 1px var(--line); }
.page-contacts .social--contacts .soc svg { width: 20px; height: 20px; }
.page-contacts .social--contacts .soc:hover { color: #fff; box-shadow: none; }

.page-contacts p, .page-contacts p:not(:has(.fa)) { padding-left: 0; }

.review-cta { margin: 0 0 20px; }
#review-modal .modal__card { max-width: 520px; }
#review-modal .g-recaptcha { margin: 6px 0 12px; }
#review-modal .err--captcha { color: #b3261e; font-weight: 600; margin: 0 0 10px; }
#review-modal .ok { display: none; text-align: center; padding: 8px 0; }
#review-modal .form-card.is-sent form { display: none; }
/* после отправки отзыва показываем «Спасибо!» */
#review-modal .form-card.is-sent .ok { display: block; padding: 24px 8px; line-height: 1.5; }
#review-modal .ok b { display: block; font-size: 24px; margin-bottom: 8px; color: var(--brand); }

/* соцсети на странице контактов: при наведении фон цвета сети (иначе белый значок пропадал на светлой подложке) */
.page-contacts .social--contacts .soc--ig:hover { background: #e4405f; color: #fff; }
.page-contacts .social--contacts .soc--tg:hover { background: #26a5e4; color: #fff; }
.page-contacts .social--contacts .soc--vb:hover { background: #7360f2; color: #fff; }
.page-contacts .social--contacts .soc--wa:hover { background: #25d366; color: #fff; }

/* оценки в форме отзыва */
.rates { border: 0; margin: 4px 0 14px; padding: 0; }
.rates legend { font-weight: 700; font-size: 15px; padding: 0; margin-bottom: 8px; }
.rates__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 14px; }
.rate { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 15px; font-weight: 600; }
.rate select { min-width: 68px; height: 42px; padding: 0 10px; border: 1px solid var(--line); border-radius: 10px; background: #fff; font: inherit; }

/* знак белорусского рубля: Б с горизонтальной чертой */
.byn { position: relative; display: inline-block; font-weight: inherit; }
.byn::after { content: ""; position: absolute; left: -.04em; right: -.04em; top: 54%; border-top: max(1.5px, .09em) solid currentColor; }

/* фото в новых статьях */
.prose figure.article-photo { margin: 22px 0; }
.prose figure.article-photo img { display: block; width: 100%; max-height: 520px; object-fit: cover; border-radius: 16px; }
.prose figure.article-photo figcaption { margin-top: 8px; font-size: 14px; color: var(--muted, #5b6b62); }

/* reCAPTCHA в формах заявок */
.rd-captcha { grid-column: 1 / -1; margin: 4px 0 8px; max-width: 100%; overflow: hidden; }
.rd-captcha:empty { display: none; }
.rd-captcha__err { margin: 6px 0 0; color: #c0392b; font-size: 13.5px; }
.rd-captcha__err[hidden] { display: none; }
.cta-form .rd-captcha__err { color: #ffb4ab; }

.ig-links { display: flex; flex-wrap: wrap; gap: 6px 24px; margin-top: 14px; }
.ig-links .ig-link { margin-top: 0; }
