/* Стили серверных подстраниц (услуги, блог, объекты, города, дом).
   Токены взяты с главной страницы, чтобы разделы не отличались от неё:
   фон 0 0% 98%, текст 0 0% 4%, акцент 221 83% 53%, Inter для текста,
   Manrope для заголовков, контейнер 1152. */

:root {
  --bg: hsl(0 0% 98%);
  --fg: hsl(0 0% 4%);
  --surface: hsl(0 0% 100%);
  --surface-alt: hsl(240 5% 96%);
  --primary: hsl(221 83% 53%);
  --primary-fg: hsl(0 0% 100%);
  --muted: hsl(220 4% 38%);
  --border: hsl(240 6% 90%);
  --radius: 16px;
  --head-h: 64px;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body.sub {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 400 16px/1.6 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }

a { color: inherit; }

.container {
  width: 100%;
  max-width: 1152px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- шапка ---------- */

.site-head {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--head-h);
  display: flex;
  align-items: center;
  background: hsl(0 0% 100% / 0.85);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
}

.head-inner {
  display: flex;
  align-items: center;
  gap: 24px;
}

.head-logo {
  font: 600 18px/1 'Manrope', 'Inter', sans-serif;
  letter-spacing: -0.4px;
  text-decoration: none;
  white-space: nowrap;
}

.pix { color: var(--primary); }

.head-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  margin-left: auto;
}

.head-nav a {
  font-size: 14px;
  color: var(--muted);
  text-decoration: none;
  transition: color .15s;
}

.head-nav a:hover { color: var(--fg); }

.head-phone {
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  white-space: nowrap;
}

.head-burger {
  display: none;
  width: 40px;
  height: 40px;
  margin-left: auto;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  cursor: pointer;
  position: relative;
}

.head-burger span,
.head-burger::before,
.head-burger::after {
  content: '';
  position: absolute;
  left: 11px;
  width: 18px;
  height: 2px;
  background: var(--fg);
  border-radius: 2px;
  transition: transform .2s, opacity .2s;
}

.head-burger::before { top: 14px; }
.head-burger span { top: 19px; }
.head-burger::after { top: 24px; }

.head-burger[aria-expanded="true"]::before { transform: translateY(5px) rotate(45deg); }
.head-burger[aria-expanded="true"] span { opacity: 0; }
.head-burger[aria-expanded="true"]::after { transform: translateY(-5px) rotate(-45deg); }

.mobile-menu {
  display: none;
  flex-direction: column;
  gap: 2px;
  padding: 12px 24px 20px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}

.mobile-menu.is-open { display: flex; }

.mobile-menu a {
  padding: 12px 0;
  font-size: 16px;
  text-decoration: none;
  border-bottom: 1px solid var(--border);
}

.mobile-menu a:last-child { border-bottom: 0; }

.mobile-phone { font-weight: 600; color: var(--primary); }

/* ---------- страница ---------- */

.sub-page { padding: 40px 0 72px; }

.sub-inner { max-width: 880px; }

.crumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
  font-size: 13px;
  color: var(--muted);
}

.crumbs a { text-decoration: none; color: var(--muted); }
.crumbs a:hover { color: var(--fg); }
.crumbs span + span::before { content: '/'; margin-right: 8px; color: var(--border); }

.eyebrow {
  margin: 0 0 10px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2.1px;
  text-transform: uppercase;
  color: var(--primary);
}

.sub-title {
  margin: 0 0 16px;
  font: 600 40px/1.08 'Manrope', 'Inter', sans-serif;
  letter-spacing: -1px;
}

.sub-lead {
  margin: 0 0 24px;
  font-size: 18px;
  line-height: 1.55;
  color: var(--muted);
}

.sub-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 28px;
  font-size: 14px;
  color: var(--muted);
}

.tag {
  display: inline-flex;
  align-items: center;
  height: 28px;
  padding: 0 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  font-size: 13px;
  color: var(--fg);
}

.tag--solid {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--primary-fg);
  font-weight: 500;
}

/* ---------- текст ---------- */

.prose { margin: 0 0 32px; }

.prose h2 {
  margin: 36px 0 14px;
  font: 600 28px/1.2 'Manrope', 'Inter', sans-serif;
  letter-spacing: -0.6px;
}

.prose h3 {
  margin: 26px 0 10px;
  font: 600 20px/1.3 'Manrope', 'Inter', sans-serif;
}

.prose p { margin: 0 0 16px; }

.prose ul, .prose ol { margin: 0 0 16px; padding-left: 22px; }
.prose li { margin-bottom: 8px; }

.prose a { color: var(--primary); text-decoration: none; }
.prose a:hover { text-decoration: underline; }

.prose blockquote {
  margin: 0 0 16px;
  padding: 12px 18px;
  border-left: 3px solid var(--primary);
  background: var(--surface-alt);
  border-radius: 0 12px 12px 0;
  color: var(--muted);
}

.prose img { border-radius: 12px; margin: 0 0 16px; }

.prose table { width: 100%; border-collapse: collapse; margin: 0 0 16px; font-size: 15px; }
.prose th, .prose td { padding: 10px 12px; border: 1px solid var(--border); text-align: left; }
.prose th { background: var(--surface-alt); font-weight: 600; }

/* ---------- кнопки ---------- */

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 0 0 36px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 44px;
  padding: 0 24px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--fg);
  font: 500 14px/1 'Inter', sans-serif;
  text-decoration: none;
  transition: background .15s, border-color .15s, transform .1s;
}

.btn:hover { background: var(--surface-alt); }
.btn:active { transform: translateY(1px); }

.btn--solid {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--primary-fg);
}

.btn--solid:hover { background: hsl(221 83% 47%); }

/* ---------- панели ---------- */

.sub-panel {
  margin: 0 0 32px;
  padding: 28px 32px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.sub-panel h2 {
  margin: 0 0 16px;
  font: 600 24px/1.25 'Manrope', 'Inter', sans-serif;
  letter-spacing: -0.5px;
}

.sub-panel h3 {
  margin: 20px 0 6px;
  font: 600 17px/1.35 'Manrope', 'Inter', sans-serif;
}

.sub-panel h3:first-of-type { margin-top: 0; }

.sub-panel p { margin: 0 0 12px; color: var(--muted); }

.steps-list {
  margin: 0;
  padding-left: 20px;
  counter-reset: step;
}

.steps-list li {
  margin-bottom: 12px;
  padding-left: 6px;
}

.steps-list li::marker { color: var(--primary); font-weight: 600; }

.specs {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px 24px;
  margin: 0 0 24px;
  padding: 0;
  list-style: none;
}

.specs li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
  font-size: 15px;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 20px;
  padding: 0;
  list-style: none;
}

.desc { color: var(--muted); }

/* ---------- карточки ---------- */

.tiles {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
  margin: 0 0 36px;
}

.tile {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: border-color .15s, transform .12s;
}

.tile:hover { border-color: hsl(221 83% 75%); transform: translateY(-2px); }

.tile-photo {
  aspect-ratio: 4 / 3;
  object-fit: cover;
  width: 100%;
}

.no-photo {
  aspect-ratio: 4 / 3;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface-alt);
  color: var(--muted);
  font-size: 14px;
}

.tile-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 1;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--primary);
  color: var(--primary-fg);
  font-size: 12px;
  font-weight: 500;
}

.tile-body { padding: 18px 20px 20px; display: flex; flex-direction: column; gap: 8px; flex: 1; }

.tile-title {
  margin: 0;
  font: 600 17px/1.35 'Manrope', 'Inter', sans-serif;
}

.tile-title a { text-decoration: none; }
.tile-title a:hover { color: var(--primary); }

.tile-price { margin: 0; font-size: 15px; font-weight: 600; color: var(--primary); }

.tile-meta { margin: 0; font-size: 14px; color: var(--muted); }

.tile-more {
  margin-top: auto;
  font-size: 14px;
  font-weight: 500;
  color: var(--primary);
  text-decoration: none;
}

.tile-more:hover { text-decoration: underline; }

.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
  margin: 0 0 28px;
}

.gallery img { border-radius: 12px; }

/* ---------- блоки ссылок ---------- */

.also { margin: 0 0 28px; }

.also-title {
  margin: 0 0 12px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2.1px;
  text-transform: uppercase;
  color: var(--muted);
}

.also-list { margin: 0; padding: 0; list-style: none; }

.also-list li { border-bottom: 1px solid var(--border); }
.also-list li:first-child { border-top: 1px solid var(--border); }

.also-list a {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px;
  padding: 14px 0;
  text-decoration: none;
  font-size: 16px;
}

.also-list a:hover { color: var(--primary); }
.also-list .pix { font-size: 14px; color: var(--muted); }

.sub-empty {
  margin: 0 0 28px;
  padding: 18px 20px;
  background: var(--surface-alt);
  border-radius: 12px;
  font-size: 15px;
  color: var(--muted);
}

.sub-empty a { color: var(--primary); text-decoration: none; }

.sub-back {
  display: inline-block;
  margin-top: 8px;
  font-size: 14px;
  color: var(--muted);
  text-decoration: none;
}

.sub-back:hover { color: var(--fg); }

/* ---------- подвал ---------- */

.site-foot {
  padding: 28px 0 40px;
  border-top: 1px solid var(--border);
  background: var(--bg);
}

.foot-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  align-items: center;
  font-size: 13px;
  color: var(--muted);
}

.foot-inner a { text-decoration: none; color: var(--muted); }
.foot-inner a:hover { color: var(--fg); }

/* ---------- адаптив ---------- */

@media (max-width: 900px) {
  .head-nav, .head-phone { display: none; }
  .head-burger { display: block; }
  .sub-title { font-size: 30px; letter-spacing: -0.7px; }
  .sub-lead { font-size: 16px; }
  .sub-panel { padding: 22px 20px; }
  .prose h2 { font-size: 23px; }
  .sub-page { padding: 28px 0 56px; }
  .container { padding: 0 18px; }
}

@media (max-width: 520px) {
  .cta-row .btn { width: 100%; }
  .tiles { grid-template-columns: 1fr; }
}
