/* ===== Дополнения для многостраничной версии ===== */
html { scroll-behavior: smooth; }
section[id], div[id] { scroll-margin-top: 96px; }
img { max-width: 100%; }

/* активный пункт меню */
.nav a.active { color: var(--blue-700); font-weight: 600; background: rgba(37, 99, 235, .08); }

/* заголовок внутренней страницы */
.page-hero {
  position: relative; overflow: hidden;
  padding: 116px 0 52px;
  background: radial-gradient(900px 420px at 12% -30%, rgba(37, 99, 235, .16), transparent 62%),
              radial-gradient(700px 380px at 96% 0%, rgba(34, 211, 238, .16), transparent 60%);
}
.page-hero::after {
  content: ""; position: absolute; inset: auto 0 0 0; height: 1px;
  background: linear-gradient(90deg, transparent, var(--line), transparent);
}
.breadcrumbs { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 13.5px; color: var(--gray-2); margin-bottom: 20px; }
.breadcrumbs a { color: var(--gray); text-decoration: none; }
.breadcrumbs a:hover { color: var(--blue-600); }
.breadcrumbs span.sep { opacity: .5; }

.page-title { font-size: clamp(30px, 4.1vw, 50px); font-weight: 800; letter-spacing: -.035em; line-height: 1.07; color: var(--ink); }
.page-sub { margin-top: 16px; max-width: 72ch; font-size: 17.5px; line-height: 1.6; color: var(--gray); }
.page-hero-row { display: flex; gap: 22px; align-items: flex-start; }
.page-hero-icon {
  flex: 0 0 auto; width: 64px; height: 64px; border-radius: 20px;
  display: flex; align-items: center; justify-content: center;
  font-size: 26px; color: #fff;
  background: linear-gradient(135deg, #22d3ee, #2563eb);
  box-shadow: 0 14px 34px rgba(37, 99, 235, .28);
}

.page-section { padding: 64px 0 84px; }
.page-section--tight { padding: 40px 0 60px; }

/* блок «плюс к тексту»: два столбца */
.detail-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, .85fr); gap: 26px; align-items: start; }
.detail-main { padding: 38px 40px; border-radius: var(--r-lg); }
.detail-main h2 { font-size: 26px; font-weight: 800; letter-spacing: -.02em; color: var(--ink); margin-bottom: 14px; }
.detail-main h2:not(:first-child) { margin-top: 34px; }
.detail-main h3 { font-size: 19px; font-weight: 700; color: var(--ink); margin: 26px 0 10px; }
.detail-main p { color: var(--ink-2); line-height: 1.72; margin-bottom: 12px; }
.detail-main p.muted { color: var(--gray); font-size: 15px; }

.detail-list { list-style: none; display: grid; gap: 10px; margin: 8px 0 4px; }
.detail-list li { display: flex; gap: 10px; align-items: flex-start; color: var(--ink-2); line-height: 1.6; }
.detail-list li i { color: var(--green); margin-top: 4px; font-size: 15px; }

.detail-aside { display: grid; gap: 18px; position: sticky; top: 96px; }
.price-card { padding: 26px; border-radius: var(--r-lg); }
.price-label { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--gray-2); }
.price-value { margin-top: 6px; font-size: 34px; font-weight: 800; letter-spacing: -.03em; color: var(--ink); }
.price-unit { color: var(--gray); font-size: 14px; margin-bottom: 18px; }
.price-card .btn { width: 100%; justify-content: center; }
.price-call { display: block; margin-top: 12px; text-align: center; color: var(--ink-2); font-weight: 600; text-decoration: none; }
.price-call:hover { color: var(--blue-600); }
.price-note { margin-top: 14px; font-size: 12.5px; color: var(--gray-2); line-height: 1.5; }

.aside-links { padding: 22px 24px; border-radius: var(--r-lg); }
.aside-links h3 { font-size: 15px; font-weight: 700; color: var(--ink); margin-bottom: 12px; }
.aside-links ul { list-style: none; display: grid; gap: 8px; }
.aside-links a { display: flex; justify-content: space-between; gap: 10px; color: var(--ink-2); text-decoration: none; font-size: 14.5px; }
.aside-links a:hover { color: var(--blue-600); }
.aside-links i { font-size: 11px; color: var(--gray-2); margin-top: 4px; }

/* «как работаем» — этапы */
.steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; margin-top: 8px; }
.step { padding: 24px; border-radius: var(--r-lg); }
.step-num { font-size: 13px; font-weight: 800; color: var(--blue-600); letter-spacing: .06em; }
.step h3 { margin: 8px 0 8px; font-size: 17px; font-weight: 700; color: var(--ink); }
.step p { color: var(--gray); font-size: 14.5px; line-height: 1.6; }

/* о компании */
.about-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 26px; align-items: start; }
.about-card { padding: 34px 36px; border-radius: var(--r-lg); }
.about-card p { color: var(--ink-2); line-height: 1.75; margin-bottom: 14px; }
.fact-list { list-style: none; display: grid; gap: 14px; }
.fact-list li { display: flex; gap: 12px; align-items: flex-start; color: var(--ink-2); line-height: 1.6; }
.fact-list i { color: var(--blue-600); margin-top: 3px; }

/* 404 */
.notfound { padding: 140px 0 120px; text-align: center; }
.notfound-code { font-size: clamp(72px, 14vw, 140px); font-weight: 900; letter-spacing: -.05em; line-height: 1;
  background: linear-gradient(135deg, #22d3ee, #2563eb); -webkit-background-clip: text; background-clip: text; color: transparent; }
.notfound h1 { margin: 12px 0 10px; font-size: 26px; font-weight: 800; color: var(--ink); }
.notfound p { color: var(--gray); margin-bottom: 26px; }

/* карточка услуги как ссылка */
a.service-link { text-decoration: none; }

/* адаптив */
@media (width <= 1024px) {
  .detail-grid { grid-template-columns: 1fr; }
  .detail-aside { position: static; }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .about-grid { grid-template-columns: 1fr; }
}
@media (width <= 768px) {
  .page-hero { padding: 96px 0 40px; }
  .page-section { padding: 44px 0 60px; }
  .detail-main { padding: 26px 22px; }
  .about-card { padding: 26px 22px; }
  .page-hero-row { flex-direction: column; gap: 14px; }
  .page-hero-icon { width: 54px; height: 54px; font-size: 22px; border-radius: 16px; }
  .price-value { font-size: 30px; }
  .nav a.active { background: transparent; }
}
@media (width <= 640px) {
  .steps { grid-template-columns: 1fr; }
}

/* модалка и лайтбокс по умолчанию скрыты */
.modal-overlay[hidden], .modal[hidden] { display: none !important; }

/* полировка */
.breadcrumbs > span:last-child { color: var(--ink-2); }
.price-note { text-align: center; }
.nav a.active { color: var(--blue-700); }
.nav a:hover { color: var(--blue-600); }
@media (width <= 768px) { .breadcrumbs { font-size: 12.5px; } }

/* мобильное меню: плотный фон, чтобы не просвечивал hero */
@media (width <= 768px) {
  .nav { background: #fffffffa; box-shadow: 0 24px 60px rgba(15, 23, 42, .18); }
  .nav a { color: var(--ink-2); }
  .nav a.active { color: var(--blue-700); background: rgba(37, 99, 235, .08); }
}

/* «Подробнее» — нормальная зона нажатия на телефоне */
@media (width <= 768px) {
  .service-link { min-height: 44px; width: 100%; justify-content: space-between; padding: 10px 0; }
}
