/* ==========================================================================
   Ремонт квартир Житомир — стили темы.
   Значения (цвета, радиусы, тени, размеры шрифтов) — из design/redesign.html.
   Брейкпоинты: 768 (телефон → планшет), 1000 (меню в шапке), 1288 (полная ширина).
   ========================================================================== */

/* ---------- Шрифты: Manrope (текст) и Unbounded (заголовки), variable, self-hosted ---------- */
@font-face {
	font-family: "Manrope";
	font-style: normal;
	font-weight: 200 800;
	font-display: swap;
	src: url("../fonts/manrope-cyrillic.woff2") format("woff2");
	unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
	font-family: "Manrope";
	font-style: normal;
	font-weight: 200 800;
	font-display: swap;
	src: url("../fonts/manrope-latin.woff2") format("woff2");
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
	font-family: "Unbounded";
	font-style: normal;
	font-weight: 200 900;
	font-display: swap;
	src: url("../fonts/unbounded-cyrillic.woff2") format("woff2");
	unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
	font-family: "Unbounded";
	font-style: normal;
	font-weight: 200 900;
	font-display: swap;
	src: url("../fonts/unbounded-latin.woff2") format("woff2");
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---------- Токены ---------- */
:root {
	--bg: #F4F4F1;
	--surface: #FFFFFF;
	--ink: #17181A;
	--ink-2: #3D3F43;
	--muted: #5A5C60;
	--line: #E3E2DD;
	--line-2: #E6E5E0;
	--dark-2: #232427;
	--dark-line: #33353A;
	--on-dark: #C9CACD;
	--on-dark-muted: #A8AAAE;
	--accent: #F2C230;
	--ok: #2E9E5B;
	--radius: 14px;
	--radius-sm: 10px;
	--shadow: 0 1px 2px rgba(23, 24, 26, .04), 0 6px 20px rgba(23, 24, 26, .05);
	--shadow-header: 0 1px 2px rgba(23, 24, 26, .04), 0 8px 24px rgba(23, 24, 26, .06);
	--font: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
	--font-display: "Unbounded", "Manrope", system-ui, sans-serif;
	--wrap: 1240px;
	--gutter: 24px;
	--section: 96px;
}

/* ---------- База ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 24px; }
body {
	margin: 0;
	background: var(--bg);
	color: var(--ink);
	font-family: var(--font);
	font-size: 17px;
	line-height: 1.55;
	-webkit-font-smoothing: antialiased;
}
img, svg, video { max-width: 100%; height: auto; }
a { color: var(--ink); }
a:hover { color: #000; }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 2px; border-radius: 4px; }
h1, h2, h3, h4 { margin: 0; }
p { margin: 0; }
button { font: inherit; color: inherit; cursor: pointer; }

.wrap { max-width: calc(var(--wrap) + 2 * var(--gutter)); margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }
.screen-reader-text {
	position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
	overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.skip-link { position: absolute; left: 16px; top: -100px; z-index: 100; background: var(--ink); color: #fff; padding: 12px 16px; border-radius: var(--radius-sm); }
.skip-link:focus { top: 16px; color: #fff; }

/* Штрихованная заглушка из макета — там, где фото нет. */
.ph {
	display: block; width: 100%; height: 100%;
	background-color: #E3E2DD;
	background-image: repeating-linear-gradient(135deg, rgba(23, 24, 26, .06) 0 2px, transparent 2px 14px);
}

/* ---------- Анимации карточки звонка ---------- */
@keyframes ccIn { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes ccRing { 0%, 62%, 100% { transform: rotate(0); } 66% { transform: rotate(-14deg); } 70% { transform: rotate(12deg); } 74% { transform: rotate(-10deg); } 78% { transform: rotate(8deg); } 82% { transform: rotate(0); } }
@keyframes ccPulse { 0% { box-shadow: 0 0 0 0 rgba(23, 24, 26, .35); } 70% { box-shadow: 0 0 0 14px rgba(23, 24, 26, 0); } 100% { box-shadow: 0 0 0 0 rgba(23, 24, 26, 0); } }
@keyframes ccDot { 0% { box-shadow: 0 0 0 0 rgba(46, 158, 91, .5); } 70% { box-shadow: 0 0 0 8px rgba(46, 158, 91, 0); } 100% { box-shadow: 0 0 0 0 rgba(46, 158, 91, 0); } }
.cc { animation: ccIn .6s cubic-bezier(.2, .7, .2, 1) both; }
.cc-d1 { animation: ccIn .6s .15s cubic-bezier(.2, .7, .2, 1) both; }
.cc-d2 { animation: ccIn .6s .28s cubic-bezier(.2, .7, .2, 1) both; }
.cc-ring { animation: ccPulse 2.4s ease-out infinite; }
.cc-ring .icon { animation: ccRing 2.4s ease-in-out infinite; transform-origin: 50% 50%; }
.cc-dot { animation: ccDot 2s ease-out infinite; }
@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	.cc, .cc-d1, .cc-d2, .cc-ring, .cc-ring .icon, .cc-dot { animation: none; }
	.btn:hover, .call-btn:hover { transform: none !important; }
}

/* ---------- Кнопки ---------- */
.btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 8px;
	min-height: 54px; padding: 16px 26px; border-radius: var(--radius-sm); border: 1px solid transparent;
	font-weight: 800; font-size: 17px; line-height: 1.2; text-decoration: none;
	transition: transform .2s ease, box-shadow .2s ease;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(23, 24, 26, .12); }
.btn--dark { background: var(--ink); color: #fff; }
.btn--dark:hover { color: #fff; }
.btn--light { background: var(--surface); color: var(--ink); border-color: var(--line); font-weight: 700; padding: 16px 24px; }

.icon-btn {
	width: 44px; height: 44px; border-radius: var(--radius-sm); border: 0; background: var(--bg);
	display: inline-flex; align-items: center; justify-content: center; color: var(--ink);
}
.icon-btn--accent { background: var(--accent); }
[data-menu-toggle] .icon-close { display: none; }
[data-menu-toggle][aria-expanded="true"] .icon-open { display: none; }
[data-menu-toggle][aria-expanded="true"] .icon-close { display: inline-flex; }
.icon-btn span { display: inline-flex; }

/* ---------- Шапка ---------- */
.site-header { padding: 20px var(--gutter) 0; position: relative; z-index: 40; }
.site-header__bar {
	max-width: var(--wrap); margin: 0 auto; height: 76px; padding: 0 12px 0 16px;
	display: flex; align-items: center; justify-content: space-between; gap: 24px;
	background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-header);
}
.site-header__tools { display: flex; align-items: center; gap: 8px; }

/* Логотип по design/assets/logo.png: знак + «РЕМОНТ (жирн.) КВАРТИР» + жёлтый штрих и подпись разрядкой. */
.logo { display: flex; align-items: center; gap: 14px; text-decoration: none; flex-shrink: 0; color: var(--ink); }
.logo__mark { width: 46px; height: 46px; flex-shrink: 0; display: block; }
.logo__text { display: flex; flex-direction: column; gap: 6px; line-height: 1; }
.logo__name { font-family: var(--font); font-weight: 400; font-size: 22px; letter-spacing: .01em; text-transform: uppercase; white-space: nowrap; }
.logo__name b { font-weight: 800; }
.logo__sub { display: flex; align-items: center; gap: 8px; font-size: 10.5px; font-weight: 800; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); white-space: nowrap; }
.logo__sub::before { content: ""; width: 22px; height: 3px; border-radius: 2px; background: var(--accent); flex-shrink: 0; }
.logo--footer { color: #fff; }
.logo--footer .logo__sub { color: var(--on-dark-muted); }

.hnav { display: flex; gap: 4px; font-weight: 600; font-size: 15px; white-space: nowrap; background: var(--bg); border-radius: var(--radius-sm); padding: 4px; }
.hnav a { text-decoration: none; padding: 10px 16px; border-radius: 7px; }
.hnav a:hover, .hnav a.is-current { background: var(--surface); box-shadow: 0 1px 2px rgba(23, 24, 26, .08); }

.lang { display: flex; gap: 2px; background: var(--bg); border-radius: var(--radius-sm); padding: 4px; font-size: 14px; font-weight: 700; }
.lang__item { min-width: 40px; min-height: 36px; padding: 0 10px; border-radius: 7px; display: inline-flex; align-items: center; justify-content: center; text-decoration: none; color: var(--muted); }
.lang__item:hover { color: var(--ink); }
.lang__item.is-current { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(23, 24, 26, .08); }

.mobile-menu {
	max-width: var(--wrap); margin: 8px auto 0; padding: 8px 16px 20px;
	background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-header);
	max-height: calc(100vh - 120px); overflow-y: auto; overscroll-behavior: contain;
}
.mobile-menu ul { list-style: none; margin: 0; padding: 0; }
.mobile-menu__main a { display: flex; align-items: center; min-height: 48px; font-weight: 700; font-size: 17px; text-decoration: none; border-bottom: 1px solid var(--line-2); }
.mobile-menu__title { margin: 18px 0 6px; font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.mobile-menu__services { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.mobile-menu__services a { display: flex; align-items: center; min-height: 44px; font-size: 15px; text-decoration: none; }
.lang--menu { margin-top: 16px; width: max-content; }

/* ---------- Секции ---------- */
.section { padding-top: var(--section); }
.section--tight { padding-top: 32px; }
.section--last { padding-bottom: var(--section); }
.section__head { display: flex; flex-wrap: wrap; gap: 16px 40px; justify-content: space-between; align-items: flex-end; margin-bottom: 40px; }
.section__head > div:first-child { display: flex; flex-direction: column; gap: 10px; }
.section__title { font-family: var(--font-display); font-weight: 700; font-size: clamp(28px, 3.4vw, 44px); letter-spacing: -.02em; line-height: 1.1; max-width: 680px; }
.section__title--solo { margin-bottom: 40px; }
.section__lead { color: var(--muted); max-width: 420px; }

/* ---------- Герой ---------- */
.hero { padding-top: 64px; padding-bottom: 56px; display: flex; flex-wrap: wrap; gap: 40px; align-items: stretch; }
.hero__main { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 28px; }
.hero__title { font-family: var(--font-display); font-weight: 700; font-size: clamp(36px, 5vw, 64px); line-height: 1.05; letter-spacing: -.03em; }
.hero__lead { font-size: 20px; color: var(--ink-2); max-width: 620px; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; }

.call-card {
	flex: 1 1 420px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow);
	border-radius: var(--radius); padding: 32px; display: flex; flex-direction: column; gap: 16px;
}
.call-card__head { display: flex; align-items: center; gap: 10px; }
.cc-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--ok); flex-shrink: 0; }
.call-card__title { font-family: var(--font-display); font-weight: 700; font-size: 22px; line-height: 1.2; }
.call-card__text { color: var(--muted); font-size: 15px; }
.call-card__note { font-size: 13px; color: var(--muted); }

.call-btn {
	border-radius: var(--radius); text-decoration: none; display: flex; align-items: center; justify-content: space-between; gap: 12px;
	transition: transform .2s ease, box-shadow .2s ease;
}
.call-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(23, 24, 26, .12); }
.call-btn--primary { background: var(--accent); padding: 18px 20px; }
.call-btn--outline { border: 2px solid var(--ink); padding: 16px 18px; }
.call-btn__text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.call-btn__who { font-size: 14px; font-weight: 700; }
.call-btn--outline .call-btn__who { color: var(--muted); }
.call-btn__num { font-family: var(--font-display); font-weight: 700; font-size: 22px; white-space: nowrap; }
.call-btn__ico { width: 48px; height: 48px; border-radius: 50%; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.call-btn--primary .call-btn__ico { background: var(--ink); color: #fff; }
.call-btn--outline .call-btn__ico { border: 2px solid var(--ink); color: var(--ink); }

.hero-photo { height: 420px; border-radius: var(--radius); overflow: hidden; background: #E3E2DD; }
.hero-photo__img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 50%; display: block; }

/* ---------- Виды ремонта ---------- */
.types { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; }
.type-card { background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; }
.type-card--dark { background: var(--ink); border-color: var(--ink); color: #fff; }
.type-card__media { height: 200px; background: #E3E2DD; }
.type-card__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.type-card__body { padding: 28px; display: flex; flex-direction: column; gap: 14px; flex: 1; }
.type-card__title { font-family: var(--font-display); font-weight: 700; font-size: 22px; }
.type-card__text { color: var(--ink-2); font-size: 16px; }
.type-card__points { margin: 0; padding-left: 20px; color: var(--ink-2); font-size: 15px; }
.type-card--dark .type-card__text, .type-card--dark .type-card__points { color: var(--on-dark); }

/* ---------- Услуги ---------- */
.services { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 12px; }
.service {
	background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); border-radius: var(--radius);
	padding: 20px; min-height: 96px; text-decoration: none; display: flex; justify-content: space-between; gap: 8px;
	transition: border-color .2s ease, transform .2s ease;
}
.service:hover { border-color: var(--ink); transform: translateY(-2px); }
.service__text { display: flex; flex-direction: column; gap: 4px; }
.service__title { font-weight: 800; font-size: 17px; }
.service__sub { font-size: 14px; color: var(--muted); }
.service__arrow { display: none; }
.service--accent { background: var(--accent); border-color: var(--accent); }
.service--accent .service__sub { color: var(--ink); }

/* ---------- Этапы ---------- */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); border-top: 2px solid var(--ink); }
.steps__item { padding: 24px 24px 0 0; display: flex; flex-direction: column; gap: 10px; }
.steps__num { font-family: var(--font-display); font-weight: 700; font-size: 15px; width: 40px; height: 40px; background: var(--accent); border-radius: 50%; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.steps__title { font-weight: 800; font-size: 18px; }
.steps__text { font-size: 15px; color: var(--muted); }

/* ---------- Работы ---------- */
.filter { display: flex; flex-wrap: wrap; gap: 4px; background: #E9E8E3; border-radius: var(--radius-sm); padding: 4px; }
.filter button { background: transparent; border: 0; border-radius: 7px; padding: 10px 16px; font-weight: 600; font-size: 15px; min-height: 44px; }
.filter button[aria-pressed="true"] { background: var(--surface); font-weight: 700; box-shadow: 0 1px 2px rgba(23, 24, 26, .08); }
.works { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr)); gap: 32px 20px; }
.work { text-decoration: none; display: flex; flex-direction: column; gap: 12px; }
.work[hidden] { display: none; }
.work__media { display: block; position: relative; height: 260px; border-radius: var(--radius); overflow: hidden; background: #E3E2DD; }
.work__count { position: absolute; left: 12px; top: 12px; background: rgba(23, 24, 26, .78); color: #fff; font-size: 13px; font-weight: 700; padding: 6px 10px; border-radius: 999px; backdrop-filter: blur(4px); }
.work__more { margin-top: auto; font-weight: 800; font-size: 15px; }
.work:hover .work__more { text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.works-wrap--full .works { gap: 40px 24px; }
.works-wrap--full .work { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 12px 12px 20px; transition: transform .2s ease, box-shadow .2s ease; }
.works-wrap--full .work:hover { transform: translateY(-3px); box-shadow: 0 1px 2px rgba(23, 24, 26, .04), 0 14px 32px rgba(23, 24, 26, .1); }
.works-wrap--full .work > span:not(.work__media) { padding: 0 8px; }
.works-wrap--full .work__media { height: 280px; border-radius: var(--radius-sm); }
.works-head__lead { max-width: 560px; }
.work__media img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s ease; }
.work:hover .work__media img { transform: scale(1.03); }
.work__label { font-size: 13px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.work__title { font-weight: 800; font-size: 20px; line-height: 1.3; }
.work__text { font-size: 15px; color: var(--muted); }
.works__all { display: none; }

/* ---------- Преимущества ---------- */
.advantages { background: var(--ink); color: #fff; border-radius: var(--radius); padding: 28px; display: flex; flex-direction: column; gap: 18px; }
.advantages__title { font-family: var(--font-display); font-weight: 700; font-size: 26px; }
.advantages__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 20px; }
.advantages__item { display: flex; flex-direction: column; gap: 6px; }
.advantages__name { font-weight: 800; color: var(--accent); }
.advantages__text { font-size: 15px; color: var(--on-dark); }

/* ---------- SEO-текст главной ---------- */
.about { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: clamp(24px, 4vw, 48px); }
.about .section__title--solo { margin-bottom: 24px; }
.about__text { max-width: none; }
.about__text > p, .about__text > h3, .about__text > .about-note { max-width: 860px; }
.about__text h3 { font-size: clamp(20px, 2.2vw, 26px); }
.about-lead { font-size: clamp(18px, 1.8vw, 21px); line-height: 1.55; color: var(--ink); }

/* Три вида ремонта: фото слева, текст справа. */
.about-types { display: flex; flex-direction: column; gap: 20px; margin: 2em 0 !important; }
.about-type { display: grid; grid-template-columns: 340px minmax(0, 1fr); gap: 28px; align-items: start; background: var(--bg); border-radius: var(--radius); padding: 20px; }
.about-type__media { margin: 0; }
.about-type__media a { display: block; border-radius: var(--radius-sm); overflow: hidden; }
/* 5:3 и привязка к верху: у старых фото внизу бывает белая полоса — уходит за край. */
.about-type__media img { display: block; width: 100%; height: auto; aspect-ratio: 5 / 3; object-fit: cover; object-position: 50% 0; border-radius: 0; transition: transform .35s ease; }
.about-type__media a:hover img { transform: scale(1.04); }
.about-type__text h3 { margin-top: 4px !important; }
.about-type__text p:last-child { margin-bottom: 0; }

/* Этапы капитального ремонта — нумерованная сетка в две колонки. */
.about-steps { list-style: none; padding: 0 !important; margin: 1.2em 0 !important; counter-reset: step; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 24px; }
.about-steps li { counter-increment: step; display: flex; align-items: center; gap: 14px; margin: 0 !important; padding: 10px 14px 10px 10px; background: var(--bg); border-radius: var(--radius-sm); color: var(--ink); font-weight: 600; font-size: 16px; }
.about-steps li::before { content: counter(step); flex: 0 0 34px; height: 34px; border-radius: 50%; background: var(--accent); display: flex; align-items: center; justify-content: center; font-family: var(--font-display); font-weight: 700; font-size: 14px; }
.about-note { border-left: 4px solid var(--accent); padding: 4px 0 4px 16px; color: var(--ink-2); }

/* Преимущества — три плашки с галочкой. */
.about-pros { list-style: none; padding: 0 !important; margin: 1em 0 0 !important; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 12px; }
.about-pros li { margin: 0 !important; padding: 18px 18px 18px 56px; position: relative; background: var(--ink); color: var(--on-dark); border-radius: var(--radius); font-size: 15px; }
.about-pros li strong { display: block; color: #fff; font-size: 17px; margin-bottom: 4px; }
.about-pros li::before { content: ""; position: absolute; left: 18px; top: 20px; width: 24px; height: 24px; border-radius: 50%; background: var(--accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2317181A' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 14px no-repeat; }

/* ---------- Контакты (CTA) ---------- */
.cta { background: var(--accent); border-radius: 18px; padding: clamp(28px, 5vw, 64px); display: flex; flex-wrap: wrap; gap: 40px; align-items: center; justify-content: space-between; }
.cta__main { flex: 999 1 480px; min-width: 0; display: flex; flex-direction: column; gap: 16px; }
.cta__title { font-family: var(--font-display); font-weight: 700; font-size: clamp(28px, 3.6vw, 48px); letter-spacing: -.02em; line-height: 1.08; }
.cta__text { font-size: 18px; max-width: 520px; }
.cta__phones { flex: 1 1 320px; display: flex; flex-direction: column; gap: 12px; }
.cta-phone { background: var(--surface); border-radius: var(--radius); padding: 20px 24px; text-decoration: none; display: flex; flex-direction: column; gap: 2px; transition: transform .2s ease; }
.cta-phone:hover { transform: translateY(-2px); }
.cta-phone__who { font-size: 14px; font-weight: 700; color: var(--muted); }
.cta-phone__num { font-family: var(--font-display); font-weight: 700; font-size: 24px; white-space: nowrap; }

/* ---------- Подвал ---------- */
.site-footer { padding: 0 var(--gutter) 24px; }
.site-footer__inner {
	max-width: var(--wrap); margin: 0 auto; background: var(--ink); color: var(--on-dark-muted); border-radius: var(--radius);
	padding: 40px; font-size: 15px; display: flex; flex-wrap: wrap; gap: 32px 40px; justify-content: space-between;
}
.site-footer__brand { display: flex; flex-direction: column; gap: 16px; max-width: 250px; }
.site-footer__nav, .site-footer__phones { display: flex; flex-direction: column; gap: 10px; }
.site-footer__nav a { color: var(--on-dark); text-decoration: none; }
.site-footer__nav a:hover { color: #fff; text-decoration: underline; }
/* Услуг ~20 — сеткой в 3 колонки, а не столбиком с переносом: иначе подвал разъезжается. */
.site-footer__nav--services { display: grid; grid-template-columns: repeat(3, max-content); gap: 10px 28px; align-content: start; }
.site-footer__nav--services .site-footer__title { grid-column: 1 / -1; }
.site-footer__title { color: #fff; font-weight: 700; }
.foot-phone { display: flex; flex-direction: column; gap: 2px; text-decoration: none; background: var(--dark-2); border-radius: var(--radius-sm); padding: 12px 16px; }
.foot-phone__who { font-size: 13px; color: var(--on-dark-muted); }
.foot-phone__num { font-weight: 800; font-size: 17px; color: #fff; white-space: nowrap; }
.site-footer__bottom { width: 100%; border-top: 1px solid var(--dark-line); padding-top: 20px; font-size: 14px; display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; align-items: flex-start; }

/* Партнёрские ссылки: мелко, в нижней строке подвала. */
.partners { flex: 1 1 420px; font-size: 13px; color: #8B8D91; }
.partners__title { display: none; }
.partners ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.partners a { color: var(--on-dark-muted); }
.partners a:hover { color: #fff; }

/* Нижняя панель звонка — только на телефоне. */
.callbar { display: none; }

/* ---------- Контакты ---------- */
.contacts { padding-top: 32px; display: flex; flex-direction: column; gap: 20px; }
.contacts__lead { font-size: 20px; color: var(--ink-2); }
.contacts__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); gap: 20px; }
.contact { background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); border-radius: var(--radius); padding: clamp(24px, 4vw, 40px); display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }
.contact--accent { background: var(--accent); border-color: var(--accent); }
.contact__role { font-weight: 700; color: var(--muted); }
.contact--accent .contact__role { color: var(--ink); }
.contact__name { font-family: var(--font-display); font-weight: 700; font-size: 22px; }
.contact__num { font-family: var(--font-display); font-weight: 700; font-size: clamp(28px, 3.4vw, 40px); letter-spacing: -.02em; text-decoration: none; white-space: nowrap; margin-bottom: 12px; }
.contact__btn { min-width: 220px; }
.contacts__note { color: var(--muted); font-size: 15px; }

/* ---------- Внутренние страницы ---------- */
.page-head { padding-top: 40px; display: flex; flex-direction: column; gap: 14px; }
.page-head__title { font-family: var(--font-display); font-weight: 700; font-size: clamp(30px, 4vw, 48px); line-height: 1.1; letter-spacing: -.02em; max-width: 900px; }
.page-head__lead { color: var(--muted); max-width: 680px; font-size: 18px; }
.page-head__meta { color: var(--muted); font-size: 15px; }

.crumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 8px; font-size: 14px; color: var(--muted); }
.crumbs li + li::before { content: "/"; margin-right: 8px; color: #A8AAAE; }
.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--ink); }

.layout { padding-top: 32px; display: grid; grid-template-columns: minmax(0, 1fr) 400px; gap: 24px; align-items: start; }
.layout__aside { position: sticky; top: 24px; }
.layout__aside .call-card { padding: 28px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: clamp(20px, 4vw, 44px); }

/* Текст из старого редактора: заголовки, списки, картинки, таблицы, галереи. */
.prose { font-size: 17px; line-height: 1.65; color: var(--ink-2); overflow-wrap: break-word; }
.prose::after { content: ""; display: table; clear: both; }
.prose > * + * { margin-top: 1em; }
.prose p { margin: 0 0 1em; }
.prose h2, .prose h3, .prose h4 { font-family: var(--font-display); font-weight: 700; color: var(--ink); line-height: 1.2; letter-spacing: -.01em; margin: 1.6em 0 .6em; clear: both; }
.prose h2 { font-size: clamp(22px, 2.4vw, 28px); }
.prose h3 { font-size: clamp(19px, 2vw, 22px); }
.prose h4 { font-size: 18px; }
.prose > :first-child { margin-top: 0; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1em; }
.prose li + li { margin-top: .3em; }
.prose a { color: var(--ink); text-decoration-color: var(--accent); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.prose a:hover { text-decoration-color: var(--ink); }
.prose strong, .prose b { color: var(--ink); }
.prose img { border-radius: var(--radius-sm); }
.prose .alignleft { float: left; margin: .3em 24px 16px 0; max-width: 45%; }
.prose .alignright { float: right; margin: .3em 0 16px 24px; max-width: 45%; }
.prose .aligncenter { display: block; margin: 16px auto; }
.prose table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 15px; line-height: 1.5; margin: 1.2em 0 1.6em; border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; }
.prose th, .prose td { padding: 12px 16px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line-2); }
.prose tr:last-child td { border-bottom: 0; }
.prose th { background: var(--ink); color: #fff; font-weight: 700; font-size: 14px; letter-spacing: .02em; }
.prose td:first-child { font-weight: 700; color: var(--ink); white-space: nowrap; width: 1%; }
.prose tbody tr:nth-child(even) td { background: #FAFAF8; }
.prose h2[id], .prose h3[id] { scroll-margin-top: 24px; }
.prose big { font-size: 1.25em; }
.prose [style*="justify"] { text-align: left !important; }

/* [gallery] — плотная сетка с крупными превью; по клику фото открывается во весь экран (fancybox).
   Ряды фиксированной высоты: первое фото на 2×2 клетки, остальные плотно вокруг, без дыр. */
.prose .gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); grid-auto-rows: 180px; grid-auto-flow: dense; gap: 10px; margin: 0 0 1.5em; }
.prose .gallery-item { margin: 0; min-width: 0; }
/* Крупная первая клетка — только в больших галереях (от 6 фото), иначе в сетке остаются дыры. */
.prose .gallery:has(> .gallery-item:nth-child(6)) > .gallery-item:first-child { grid-column: span 2; grid-row: span 2; }
.prose .gallery-icon, .prose .gallery-icon a { display: block; height: 100%; margin: 0; }
.prose .gallery-icon a { border-radius: var(--radius-sm); overflow: hidden; background: #E3E2DD; position: relative; }
.prose .gallery-icon img { display: block; width: 100%; height: 100%; object-fit: cover; border-radius: 0; transition: transform .35s ease; }
.prose .gallery-icon a::after { content: ""; position: absolute; inset: 0; background: rgba(23, 24, 26, 0); transition: background .25s ease; }
.prose .gallery-icon a:hover img { transform: scale(1.05); }
.prose .gallery-icon a:hover::after { background: rgba(23, 24, 26, .12); }
.prose .gallery-caption { display: none; }
.prose .gallery br { display: none; }

/* Плитки «Примеры наших работ» из старого контента. */
.prose .gallery_item { display: inline-block; vertical-align: top; width: 170px; margin: 0 12px 16px 0; text-align: center; }
.prose .gallery_item img { width: 150px; height: 150px; object-fit: cover; }
.prose .thumb_title { font-size: 15px; font-weight: 700; margin-top: 6px; }

/* Фото на страницах услуг (create-service-pages.php): во всю ширину текста. */
.prose .service-photo { margin: 1.4em 0 1.6em; }
.prose .service-photo a { display: block; border-radius: var(--radius-sm); overflow: hidden; }
.prose .service-photo img { display: block; width: 100%; height: auto; max-height: 440px; object-fit: cover; border-radius: 0; }

/* Видео YouTube в статьях — на всю ширину колонки, 16:9. */
.prose .video { position: relative; aspect-ratio: 16 / 9; margin: 1.2em 0; border-radius: var(--radius-sm); overflow: hidden; background: var(--ink); }
.prose .video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

.tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 2em !important; }
.tags a { font-size: 14px; text-decoration: none; background: var(--bg); border-radius: 999px; padding: 6px 12px; color: var(--muted); }

/* Статьи */
.posts { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); gap: 32px 20px; }
.post-card { text-decoration: none; display: flex; flex-direction: column; gap: 10px; }
.post-card__media { display: block; height: 220px; border-radius: var(--radius); overflow: hidden; background: #E3E2DD; }
.post-card__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.post-card__date { font-size: 13px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.post-card__title { font-weight: 800; font-size: 20px; line-height: 1.3; }
.post-card__text { font-size: 15px; color: var(--muted); }
.post-card:hover .post-card__title { text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: 2px; }

.pagination { margin-top: 40px; }
.pagination .nav-links { display: flex; flex-wrap: wrap; gap: 6px; }
.pagination .page-numbers { min-width: 44px; min-height: 44px; padding: 0 12px; display: inline-flex; align-items: center; justify-content: center; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--line); text-decoration: none; font-weight: 700; }
.pagination .current { background: var(--ink); color: #fff; border-color: var(--ink); }

.search-form { display: flex; flex-wrap: wrap; gap: 8px; }
.search-form input { flex: 1 1 220px; min-height: 54px; padding: 0 16px; border: 1px solid var(--line); border-radius: var(--radius-sm); font: inherit; background: var(--bg); }

/* Мозаика фото в тексте главной: 7 фото — одно крупное и шесть вокруг. */
.about__text .gallery { margin: 1.5em 0 2em; }

/* ---------- Просмотр фото (assets/js/main.js, <dialog>) ---------- */
.lightbox { padding: 0; border: 0; max-width: 100vw; max-height: 100vh; width: 100vw; height: 100vh; background: rgba(12, 13, 14, .94); color: #fff; overflow: hidden; }
.lightbox::backdrop { background: rgba(12, 13, 14, .94); }
.lightbox__figure { margin: 0; width: 100%; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 56px 72px 24px; }
.lightbox__img { max-width: 100%; max-height: calc(100vh - 120px); object-fit: contain; border-radius: 6px; background: #222; }
.lightbox__caption { font-size: 14px; color: #C9CACD; text-align: center; }
.lightbox__btn { position: absolute; border: 0; background: rgba(255, 255, 255, .1); color: #fff; width: 48px; height: 48px; border-radius: 50%; font-size: 30px; line-height: 1; display: flex; align-items: center; justify-content: center; cursor: pointer; }
.lightbox__btn:hover, .lightbox__btn:focus-visible { background: var(--accent); color: var(--ink); }
.lightbox__btn[hidden] { display: none; }
.lightbox__close { top: 16px; right: 16px; }
.lightbox__prev { left: 16px; top: 50%; transform: translateY(-50%); }
.lightbox__next { right: 16px; top: 50%; transform: translateY(-50%); }
html.has-lightbox { overflow: hidden; }
@media (max-width: 767px) {
	.lightbox__figure { padding: 56px 8px 16px; }
	.lightbox__prev, .lightbox__next { top: auto; bottom: 16px; transform: none; }
}

/* ==========================================================================
   Адаптив
   ========================================================================== */
.hide-desktop { display: none; }

@media (max-width: 1200px) {
	/* Логотип — отдельной строкой сверху, ниже в один ряд разделы, услуги и телефоны. */
	.site-footer__brand { flex-basis: 100%; max-width: none; flex-direction: row; align-items: center; gap: 24px; }
	.site-footer__brand p { max-width: 420px; }
}

@media (max-width: 1100px) {
	.layout { grid-template-columns: minmax(0, 1fr) 340px; }
	.call-btn__num { font-size: 20px; }
}

@media (max-width: 1000px) {
	.hnav { display: none; }
	.hide-desktop { display: inline-flex; }
	.layout { grid-template-columns: 1fr; }
	.layout__aside { position: static; }
}

@media (max-width: 767px) {
	:root { --gutter: 16px; --section: 48px; }
	body { font-size: 16px; line-height: 1.5; padding-bottom: 96px; }
	/* Отступ нужен только под нижнюю панель звонка; на «Контактах» её нет. */
	body:not(:has(.callbar)) { padding-bottom: 0; }

	.site-header { padding: 12px 12px 0; }
	.site-header__bar { height: 64px; padding: 0 8px 0 10px; gap: 8px; }
	.logo { gap: 10px; }
	.logo__mark { width: 38px; height: 38px; }
	.logo__text { gap: 5px; }
	.logo__name { font-size: 17px; }
	.logo__sub { font-size: 9px; letter-spacing: .14em; gap: 6px; }
	.logo__sub::before { width: 16px; }
	.site-header__tools { gap: 6px; }
	.lang--header { display: none; }

	.hero { padding-top: 28px; padding-bottom: 0; gap: 18px; }
	.hero__main { gap: 18px; }
	.hero__title { font-size: 32px; line-height: 1.08; }
	.hero__lead { font-size: 17px; }
	.hero__actions .btn { width: 100%; }
	.hero__actions .btn--light { display: none; }
	.hero .call-card { display: none; }
	.hero-photo { height: 220px; margin-top: 18px; }

	.section__head { margin-bottom: 14px; }
	.section__title { font-size: 24px; line-height: 1.15; }
	.section__title--solo { margin-bottom: 14px; }
	.section__lead { display: none; }

	/* Виды ремонта — горизонтальная лента без фото. */
	.types { display: flex; gap: 12px; overflow-x: auto; margin: 0 calc(-1 * var(--gutter)); padding: 0 var(--gutter) 4px; scroll-snap-type: x mandatory; }
	.type-card { flex: 0 0 280px; scroll-snap-align: start; }
	.type-card__media, .type-card__points { display: none; }
	.type-card__body { padding: 20px; gap: 10px; }
	.type-card__title { font-size: 18px; }
	.type-card__text { font-size: 15px; }

	/* Услуги — единый список со стрелками. */
	.services { display: block; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); border-radius: var(--radius); overflow: hidden; }
	.service { min-height: 48px; padding: 12px 16px; border: 0; border-bottom: 1px solid var(--line-2); border-radius: 0; box-shadow: none; align-items: center; }
	.service:hover { transform: none; }
	.service__title { font-weight: 700; font-size: 16px; }
	.service__sub { font-size: 13px; }
	.service__arrow { display: inline; }
	.service--accent { border-bottom: 0; }

	/* Этапы — вертикально. */
	.steps { grid-template-columns: 1fr; border-top: 0; gap: 12px; }
	.steps__item { padding: 0; flex-direction: row; align-items: center; gap: 14px; flex-wrap: wrap; }
	.steps__num { width: 36px; height: 36px; }
	.steps__title { font-size: 16px; }
	.steps__text { flex-basis: 100%; padding-left: 50px; margin-top: -10px; font-size: 14px; }

	/* Работы — три карточки и ссылка на все. */
	.filter { display: none; }
	.works { gap: 20px; }
	.work:nth-child(n+4) { display: none; }
	.work__media { height: 200px; }
	.work__label { display: none; }
	.work__title { font-size: 18px; }
	.works__all { display: inline-flex; margin-top: 16px; font-weight: 800; text-decoration: none; }

	/* Страница работ: все карточки, фильтр лентой с прокруткой, подводка видна. */
	.works-wrap--full .works-head { margin-bottom: 20px; }
	.works-wrap--full .works-head__lead { display: block; font-size: 16px; }
	.works-wrap--full .filter { display: flex; flex-wrap: nowrap; overflow-x: auto; width: 100%; scrollbar-width: none; }
	.works-wrap--full .filter button { flex: 0 0 auto; }
	.works-wrap--full .work:nth-child(n+4) { display: flex; }
	.works-wrap--full .work[hidden] { display: none; }
	.works-wrap--full .work__label { display: block; }
	.works-wrap--full .work__media { height: 220px; }
	.prose .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-rows: 130px; gap: 6px; }

	.advantages { padding: 22px; }
	.advantages__title { font-size: 22px; }
	.about { padding: 20px; }
	.about-type { grid-template-columns: 1fr; gap: 14px; padding: 14px; }
	.about-steps { grid-template-columns: 1fr; }
	.about-steps li { font-size: 15px; }

	.cta { border-radius: var(--radius); padding: 22px; gap: 18px; }
	.cta__title { font-size: 24px; }
	.cta__text { font-size: 16px; }
	.cta-phone { padding: 16px; }
	.cta-phone__num { font-size: 22px; }

	.site-footer { padding: 48px 12px 0; }
	.site-footer__inner { padding: 24px 16px; font-size: 14px; flex-direction: column; gap: 18px; }
	.site-footer__brand { flex-direction: column; align-items: flex-start; gap: 14px; }
	.site-footer__nav--services { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 16px; }
	.site-footer__bottom { flex-direction: column; }
	.partners { flex: none; }
	.logo--footer .logo__name { font-size: 17px; }

	.callbar {
		display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px;
		position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 30;
		background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 8px;
		box-shadow: 0 -4px 16px rgba(0, 0, 0, .08);
		padding-bottom: calc(8px + env(safe-area-inset-bottom, 0px));
	}
	.callbar__btn { background: var(--ink); color: #fff; text-decoration: none; border-radius: var(--radius-sm); min-height: 52px; display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1.2; }
	.callbar__btn:hover { color: #fff; }
	.callbar__btn--accent { background: var(--accent); color: var(--ink); }
	.callbar__btn--accent:hover { color: var(--ink); }
	.callbar__label { font-weight: 800; font-size: 14px; }
	.callbar__who { font-size: 12px; font-weight: 600; }
	.callbar__btn:not(.callbar__btn--accent) .callbar__who { color: var(--on-dark); }

	.page-head { padding-top: 24px; }
	.contacts { padding-top: 20px; }
	.contacts__lead { font-size: 17px; }
	.contact__btn { width: 100%; }
	.layout { padding-top: 20px; }
	.prose { font-size: 16px; }
	.prose .alignleft, .prose .alignright { float: none; margin: 0 0 16px; max-width: 100%; }
	/* Таблица на телефоне — строки карточками: подпись столбца из шапки не нужна, ячейки друг под другом. */
	.prose table, .prose tbody, .prose tr, .prose td { display: block; width: auto; }
	.prose thead { display: none; }
	.prose tr { border-bottom: 1px solid var(--line-2); padding: 10px 14px; }
	.prose tr:last-child { border-bottom: 0; }
	.prose td { padding: 2px 0; border: 0; white-space: normal; background: none !important; }
	.prose tbody tr:nth-child(even) { background: #FAFAF8; }
	.prose td[data-label]::before { content: attr(data-label) ": "; font-weight: 700; color: var(--muted); }
	.mobile-menu { position: absolute; left: 12px; right: 12px; top: 100%; margin: 8px 0 0; max-height: calc(100vh - 190px); max-height: calc(100dvh - 190px); }
}

@media (max-width: 380px) {
	.call-btn__num, .cta-phone__num { font-size: 19px; }
	.mobile-menu__services { grid-template-columns: 1fr; }
}
