/* ============================================================
   KRON — алмазное бурение · Москва
   Палитра: KRON Red #D2051E · Asphalt #0E0E0F · Concrete #F1F0EC
   Шрифты: Unbounded (дисплей) · Manrope (текст) · IBM Plex Mono (техника)
   ============================================================ */

:root {
  --red: #D2051E;
  --red-hover: #F5142E;
  --black: #0E0E0F;
  --graphite: #1A1B1D;
  --graphite-2: #232427;
  --steel: #9DA1A6;
  --concrete: #F1F0EC;
  --concrete-2: #E2E0D9;
  --ink: #141517;
  --white: #FFFFFF;

  --font-display: 'Unbounded', system-ui, sans-serif;
  --font-body: 'Manrope', system-ui, sans-serif;
  --font-mono: 'IBM Plex Mono', ui-monospace, monospace;

  --container: 1200px;
  --radius: 4px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--concrete);
  -webkit-font-smoothing: antialiased;
}

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}
.container--narrow { max-width: 860px; }

.mono {
  font-family: var(--font-mono);
  font-size: 0.78em;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.accent { color: var(--red); }

/* ---------- Кнопки ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 18px 32px;
  border-radius: var(--radius);
  transition: transform .15s ease, background .2s ease, box-shadow .2s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px) scale(0.99); }

.btn--red {
  background: var(--red);
  color: var(--white);
  box-shadow: 0 8px 24px rgba(210, 5, 30, 0.35);
}
.btn--red:hover { background: var(--red-hover); box-shadow: 0 10px 32px rgba(210, 5, 30, 0.5); }

.btn--ghost {
  background: transparent;
  color: var(--white);
  border: 1.5px solid rgba(255, 255, 255, 0.25);
}
.btn--ghost:hover { border-color: var(--white); background: rgba(255, 255, 255, 0.06); }

.btn--sm { padding: 12px 22px; font-size: 12px; }

/* ---------- Header ---------- */
.header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  padding: 18px 0;
  transition: background .3s ease, padding .3s ease, box-shadow .3s ease;
}
.header.is-scrolled {
  background: rgba(14, 14, 15, 0.92);
  backdrop-filter: blur(14px);
  padding: 10px 0;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.08);
}
.header__inner {
  display: flex;
  align-items: center;
  gap: 32px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--white);
}
.logo__mark { width: 34px; height: 34px; }
.logo__word {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 22px;
  letter-spacing: 0.08em;
  color: inherit;
}

.nav { display: flex; gap: 26px; margin-left: auto; }
.nav__link {
  font-size: 14px;
  font-weight: 600;
  color: var(--steel);
  text-decoration: none;
  letter-spacing: 0.02em;
  transition: color .2s;
}
.nav__link:hover { color: var(--white); }

.header__contacts { display: flex; align-items: center; gap: 20px; }
.header__phone {
  font-family: var(--font-mono);
  font-size: 15px;
  font-weight: 500;
  color: var(--white);
  text-decoration: none;
}
.header__phone:hover { color: var(--red-hover); }

.burger { display: none; }
.nav__close-hint { display: none; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  background: var(--black);
  color: var(--white);
  padding: 170px 0 0;
  overflow: hidden;
}
.hero__grid-bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.035) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(ellipse 90% 80% at 50% 20%, #000 40%, transparent 100%);
}
.hero__inner {
  position: relative;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 48px;
  align-items: center;
  padding-bottom: 90px;
}

.hero__label {
  color: var(--red-hover);
  margin-bottom: 28px;
  font-size: 13px;
}

.hero__title {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(44px, 6.4vw, 88px);
  line-height: 1.02;
  letter-spacing: -0.01em;
  margin-bottom: 28px;
  /* блок по ширине самой длинной строки, поэтому «БЕТОН» центрируется
     относительно «НЕ ПРЕГРАДА», а не относительно всего экрана */
  display: inline-block;
  text-align: center;
}

.hero__sub {
  font-size: 19px;
  line-height: 1.65;
  color: var(--steel);
  max-width: 520px;
  margin-bottom: 40px;
}
.hero__sub b { color: var(--white); }

.hero__cta { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 26px; }

.hero__note { color: var(--steel); font-size: 12px; }

/* фото в hero */
.hero__visual { display: flex; justify-content: center; }
.photo-frame {
  position: relative;
  max-width: 400px;
  width: 100%;
}
.photo-frame::before {
  /* красная подложка со сдвигом */
  content: '';
  position: absolute;
  inset: 20px -20px -20px 20px;
  background: var(--red);
  border-radius: var(--radius);
  opacity: 0.9;
}
.photo-frame__img {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.55);
}
.photo-frame__bit {
  position: absolute;
  top: -34px;
  left: -34px;
  width: 92px;
  height: 92px;
  filter: drop-shadow(0 8px 20px rgba(0, 0, 0, 0.5));
}
.corebit__spin { animation: spin 18s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.photo-frame__badge {
  position: absolute;
  left: 16px;
  bottom: 16px;
  background: rgba(14, 14, 15, 0.85);
  backdrop-filter: blur(8px);
  color: var(--white);
  font-size: 11px;
  padding: 10px 14px;
  border-radius: var(--radius);
  border-left: 2px solid var(--red);
}

/* стата под hero */
.hero__stats {
  position: relative;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.02);
}
.hero__stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}
.stat {
  padding: 28px 20px;
  border-left: 1px solid rgba(255, 255, 255, 0.1);
}
.stat:first-child { border-left: none; }
.stat__num {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 26px;
  color: var(--white);
  margin-bottom: 4px;
}
.stat__label {
  font-size: 13px;
  color: var(--steel);
}

/* ---------- Ticker ---------- */
.ticker {
  background: var(--red);
  color: var(--white);
  overflow: hidden;
  padding: 14px 0;
}
.ticker__track {
  display: flex;
  width: max-content;
  animation: ticker 28s linear infinite;
}
.ticker__track span {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.12em;
  white-space: nowrap;
}
@keyframes ticker { to { transform: translateX(-50%); } }

/* ---------- Секции ---------- */
.section { padding: 110px 0; }
.section--tight { padding-top: 0; }
.section--light { background: var(--concrete); color: var(--ink); }
.section--dark { background: var(--black); color: var(--white); }

.section__head { margin-bottom: 56px; }
.section__label { color: var(--red); margin-bottom: 16px; font-size: 13px; }
.section__title {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(30px, 4vw, 52px);
  letter-spacing: -0.01em;
  line-height: 1.05;
}
.section__sub {
  margin-top: 18px;
  max-width: 560px;
  color: #6B6E73;
  font-size: 16px;
}
.section--dark .section__sub { color: var(--steel); }

/* ---------- Услуги ---------- */
.services {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.service {
  position: relative;
  background: var(--white);
  border: 1px solid var(--concrete-2);
  border-radius: var(--radius);
  padding: 36px 30px 30px;
  display: flex;
  flex-direction: column;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.service:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 48px rgba(20, 21, 23, 0.1);
  border-color: transparent;
}
.service--featured { border-top: 3px solid var(--red); }

.service__num {
  color: var(--red);
  font-size: 14px;
  margin-bottom: 22px;
}
.service__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 21px;
  margin-bottom: 14px;
}
.service__text { color: #55585D; font-size: 15px; margin-bottom: 20px; }

.service__list { list-style: none; margin-bottom: 28px; }
.service__list li {
  position: relative;
  padding-left: 22px;
  font-size: 15px;
  margin-bottom: 8px;
}
.service__list li::before {
  content: '◆';
  position: absolute;
  left: 0;
  color: var(--red);
  font-size: 10px;
  top: 5px;
}

/* низ карточки услуги: цены сняты 22.08 — вместо них призыв к расчёту */
.service__cta {
  margin-top: auto;
  padding-top: 20px;
  border-top: 1px solid var(--concrete-2);
}
.service__cta .mono {
  position: relative;
  display: inline-block;
  padding-left: 20px;
  font-size: 13px;
  color: var(--red);
  font-weight: 500;
}
.service__cta .mono::before {
  content: '◆';
  position: absolute;
  left: 0;
  top: 1px;
  font-size: 9px;
}

.service__price {
  margin-top: auto;
  padding-top: 20px;
  border-top: 1px solid var(--concrete-2);
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 30px;
}
.service__price .mono { font-size: 13px; color: #8A8D92; margin-right: 6px; }
.service__unit { font-size: 16px; font-weight: 700; color: #8A8D92; }

/* ---------- Прайс (секция снята 22.08, стили оставлены на случай возврата) ---------- */
.price-table {
  background: var(--white);
  border: 1px solid var(--concrete-2);
  border-radius: var(--radius);
  overflow: hidden;
}
.price-row {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  padding: 18px 28px;
  border-bottom: 1px solid var(--concrete-2);
  font-size: 16px;
  transition: background .15s;
}
.price-row:last-child { border-bottom: none; }
.price-row:not(.price-row--head):hover { background: #FAFAF8; }
.price-row--head {
  background: var(--black);
  color: var(--white);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.price-row .mono { font-size: 14px; font-weight: 500; }

.price-note {
  display: flex;
  gap: 28px;
  flex-wrap: wrap;
  margin-top: 24px;
}
.price-note__item {
  font-size: 12px;
  color: #6B6E73;
  padding-left: 16px;
  border-left: 2px solid var(--red);
}

/* ---------- Сравнение ---------- */
.compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.compare__col {
  border-radius: var(--radius);
  padding: 40px 36px;
}
.compare__col--bad {
  background: var(--graphite);
  border: 1px solid rgba(255, 255, 255, 0.07);
}
.compare__col--good {
  background: linear-gradient(160deg, #26060B 0%, var(--graphite) 60%);
  border: 1px solid rgba(210, 5, 30, 0.45);
  box-shadow: 0 0 60px rgba(210, 5, 30, 0.12);
}
.compare__head {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 28px;
}
.compare__head h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 20px;
}
.compare__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  font-size: 18px;
  font-weight: 800;
  flex-shrink: 0;
}
.compare__badge--bad { background: rgba(255, 255, 255, 0.08); color: var(--steel); }
.compare__badge--good { background: var(--red); color: var(--white); }

.compare__col ul { list-style: none; }
.compare__col li {
  position: relative;
  padding: 14px 0 14px 26px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  color: var(--steel);
  font-size: 15.5px;
}
.compare__col li:last-child { border-bottom: none; }
.compare__col--good li { color: #E8E8E6; }
.compare__col li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 22px;
  width: 10px;
  height: 2px;
  background: currentColor;
  opacity: 0.5;
}
.compare__col--good li::before { background: var(--red); opacity: 1; }

/* ---------- Работы (галерея) ---------- */
.works-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.work-card {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--white);
  border: 1px solid var(--concrete-2);
}
.work-card img {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  transition: transform .5s ease;
}
.work-card:hover img { transform: scale(1.05); }
.work-card figcaption {
  position: absolute;
  inset: auto 0 0 0;
  padding: 34px 14px 12px;
  background: linear-gradient(transparent, rgba(14, 14, 15, 0.88));
  color: var(--white);
  font-size: 11px;
}

/* ---------- Мастер ---------- */
.master__inner {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 64px;
  align-items: center;
}
.master__photo {
  position: relative;
}
.master__photo::after {
  content: '';
  position: absolute;
  inset: 20px -20px -20px 20px;
  border: 1.5px solid var(--red);
  border-radius: var(--radius);
  pointer-events: none;
}
.master__photo img {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: var(--radius);
  z-index: 1;
}
.master__text {
  color: var(--steel);
  font-size: 18px;
  line-height: 1.7;
  margin: 26px 0 30px;
  max-width: 540px;
}
.master__list { list-style: none; margin-bottom: 36px; }
.master__list li {
  position: relative;
  padding: 13px 0 13px 30px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  color: #E8E8E6;
  font-size: 16px;
}
.master__list li:last-child { border-bottom: none; }
.master__list li::before {
  content: '◆';
  position: absolute;
  left: 0;
  top: 15px;
  color: var(--red);
  font-size: 11px;
}
.master__sign {
  display: inline-block;
  color: var(--steel);
  font-size: 12px;
  padding: 12px 18px;
  border: 1px dashed rgba(255, 255, 255, 0.25);
  border-radius: var(--radius);
}

/* ---------- Шаги ---------- */
.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.step {
  background: var(--white);
  border: 1px solid var(--concrete-2);
  border-radius: var(--radius);
  padding: 32px 26px;
}
.step__num {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 44px;
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1.5px var(--red);
  margin-bottom: 20px;
  text-align: center;
}
.step__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 18px;
  margin-bottom: 10px;
  text-align: center;
}
.step p { font-size: 15px; color: #55585D; }

/* ---------- Чипсы ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 12px; }
.chip {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.03em;
  padding: 12px 20px;
  background: var(--white);
  border: 1px solid var(--concrete-2);
  border-radius: 100px;
  transition: border-color .2s, color .2s;
  cursor: default;
}
.chip:hover { border-color: var(--red); color: var(--red); }

/* ---------- FAQ ---------- */
.faq__item {
  background: var(--white);
  border: 1px solid var(--concrete-2);
  border-radius: var(--radius);
  margin-bottom: 12px;
  overflow: hidden;
}
.faq__item summary {
  list-style: none;
  cursor: pointer;
  padding: 22px 60px 22px 28px;
  font-weight: 700;
  font-size: 17px;
  position: relative;
  user-select: none;
}
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after {
  content: '+';
  position: absolute;
  right: 24px;
  top: 50%;
  transform: translateY(-50%);
  font-family: var(--font-display);
  font-size: 22px;
  color: var(--red);
  transition: transform .25s;
}
.faq__item[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq__item p {
  padding: 0 28px 24px;
  color: #55585D;
  font-size: 15.5px;
}

/* ---------- CTA ---------- */
.cta {
  background: var(--black);
  color: var(--white);
  padding: 130px 0;
  position: relative;
  overflow: hidden;
}
.cta::before {
  content: '';
  position: absolute;
  width: 700px;
  height: 700px;
  border-radius: 50%;
  border: 90px solid rgba(210, 5, 30, 0.09);
  right: -260px;
  top: -260px;
}
.cta__inner { position: relative; text-align: center; }
.cta__label { color: var(--red-hover); margin-bottom: 20px; font-size: 13px; }
.cta__title {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(28px, 4.6vw, 58px);
  line-height: 1.1;
  margin-bottom: 40px;
}
.cta__phone {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: clamp(24px, 3.4vw, 40px);
  font-weight: 500;
  color: var(--white);
  text-decoration: none;
  margin-bottom: 40px;
  border-bottom: 2px solid var(--red);
  padding-bottom: 6px;
  transition: color .2s;
}
.cta__phone:hover { color: var(--red-hover); }
.cta__actions { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; margin-bottom: 28px; }
.cta__note { color: var(--steel); font-size: 12px; }

/* ---------- Footer ---------- */
.footer {
  background: #0A0A0B;
  color: var(--steel);
  padding: 70px 0 0;
}
.footer__inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 50px;
}
.logo--light { color: var(--white); }
.footer__tagline { margin-top: 18px; font-size: 15px; line-height: 1.7; }
.footer__head { color: var(--red-hover); font-size: 12px; margin-bottom: 18px; }
.footer__col { display: flex; flex-direction: column; }
.footer__link {
  color: var(--steel);
  text-decoration: none;
  font-size: 15px;
  margin-bottom: 10px;
  transition: color .2s;
}
a.footer__link:hover { color: var(--white); }
.footer__bottom {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding-top: 24px;
  padding-bottom: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 11px;
  color: #55585D;
}

/* ---------- FAB (мобильный звонок) ---------- */
.fab {
  display: none;
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 90;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: var(--red);
  color: var(--white);
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 30px rgba(210, 5, 30, 0.5);
  animation: pulse 2.4s ease-out infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 10px 30px rgba(210, 5, 30, 0.5), 0 0 0 0 rgba(210, 5, 30, 0.45); }
  70% { box-shadow: 0 10px 30px rgba(210, 5, 30, 0.5), 0 0 0 18px rgba(210, 5, 30, 0); }
  100% { box-shadow: 0 10px 30px rgba(210, 5, 30, 0.5), 0 0 0 0 rgba(210, 5, 30, 0); }
}

/* ---------- Лайтбокс галереи ---------- */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 24px;
  background: rgba(8, 8, 9, 0.94);
  backdrop-filter: blur(10px);
  opacity: 0;
  transition: opacity .22s ease;
}
.lightbox[hidden] { display: none; }
.lightbox.is-open { opacity: 1; }

.lightbox__figure {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  max-width: min(1100px, 100%);
  max-height: 100%;
}
.lightbox__img {
  display: block;
  max-width: 100%;
  max-height: calc(100vh - 160px);
  object-fit: contain;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
  background: var(--graphite);
}
.lightbox__caption {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: center;
  color: var(--white);
  font-size: 12px;
  text-align: center;
}
.lightbox__counter { color: var(--steel); }

.lightbox__close,
.lightbox__nav {
  position: absolute;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: var(--white);
  border-radius: 50%;
  cursor: pointer;
  transition: background .2s, border-color .2s, transform .15s;
  -webkit-tap-highlight-color: transparent;
}
.lightbox__close:hover,
.lightbox__nav:hover { background: var(--red); border-color: var(--red); }
.lightbox__close:active,
.lightbox__nav:active { transform: scale(0.94); }

.lightbox__close {
  top: 20px;
  right: 20px;
  width: 46px;
  height: 46px;
  font-size: 17px;
  line-height: 1;
}
.lightbox__nav {
  top: 50%;
  transform: translateY(-50%);
  width: 54px;
  height: 54px;
  font-size: 34px;
  line-height: 1;
  padding-bottom: 5px;
}
.lightbox__nav:active { transform: translateY(-50%) scale(0.94); }
.lightbox__nav--prev { left: 20px; }
.lightbox__nav--next { right: 20px; }

/* picture не должен ломать сетку — выпадает из потока, размеры держит img */
picture { display: contents; }

/* карточка галереи — кликабельна */
.work-card { cursor: zoom-in; }
.work-card:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }

/* ---------- Reveal-анимации ---------- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .7s ease, transform .7s ease;
}
.reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .corebit__spin, .ticker__track, .fab { animation: none; }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  /* на планшете ссылки в шапке уже не помещаются и наезжают на контент — уводим их в бургер */
  .nav { display: none; }

  .burger {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    margin-left: auto;
    width: 44px;
    height: 44px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 8px;
  }
  .burger span {
    display: block;
    height: 2px;
    background: var(--white);
    transition: transform .25s, opacity .25s;
  }
  .burger.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .burger.is-open span:nth-child(2) { opacity: 0; }
  .burger.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  .nav.is-open {
    display: flex;
    position: fixed;
    inset: 0;
    background: #0E0E0F;
    backdrop-filter: blur(6px);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 30px;
    z-index: 101;
  }
  .nav.is-open .nav__link { font-size: 24px; font-family: var(--font-display); color: var(--white); }
  .nav.is-open { animation: navIn .22s ease; }
  @keyframes navIn { from { opacity: 0; } to { opacity: 1; } }
  .nav.is-open .nav__close-hint { display: block; position: absolute; bottom: 42px; left: 0; right: 0; text-align: center;
    font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: #55585D; }

  .hero__inner { grid-template-columns: 1fr; }
  .hero__visual { margin-top: 40px; }
  .photo-frame { max-width: 320px; margin: 0 auto; }
  .photo-frame__bit { width: 68px; height: 68px; top: -24px; left: -24px; }
  .hero { padding-top: 130px; }
  .services { grid-template-columns: 1fr 1fr; }
  .steps { grid-template-columns: 1fr 1fr; }
  .works-grid { grid-template-columns: repeat(2, 1fr); }
  .master__inner { grid-template-columns: 1fr; gap: 48px; }
  .master__photo { max-width: 420px; }
  .footer__inner { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .header__contacts { display: none; }


  .hero__stats-row { grid-template-columns: 1fr 1fr; }
  .stat { border-left: none; border-top: 1px solid rgba(255,255,255,0.1); }
  .stat:nth-child(-n+2) { border-top: none; }
  .stat:nth-child(even) { border-left: 1px solid rgba(255,255,255,0.1); }

  .section { padding: 70px 0; }
  .services { grid-template-columns: 1fr; }
  .compare { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .footer__inner { grid-template-columns: 1fr; gap: 32px; }

  .price-row { grid-template-columns: 1.2fr 1fr 1fr 1fr; padding: 14px 14px; font-size: 13px; }
  .price-row .mono { font-size: 11px; }

  .fab { display: flex; }
  .cta { padding: 90px 0; }

  .lightbox { padding: 20px 12px; }
  .lightbox__img { max-height: calc(100vh - 190px); }
  .lightbox__nav { width: 44px; height: 44px; font-size: 28px; }
  .lightbox__nav--prev { left: 8px; }
  .lightbox__nav--next { right: 8px; }
  .lightbox__close { top: 12px; right: 12px; width: 42px; height: 42px; }
}

/* Узкие телефоны (iPhone 13 mini … 17 Pro, 375–430 px) —
   на этой ширине рвались стата под hero, кнопки и длинные тех-строки */
@media (max-width: 520px) {
  .container { padding: 0 18px; }

  .hero { padding-top: 116px; }
  .hero__inner { padding-bottom: 64px; }
  .hero__label { font-size: 12px; letter-spacing: 0.05em; line-height: 1.5; margin-bottom: 20px; }
  .hero__title { font-size: 40px; }
  .hero__sub { font-size: 17px; margin-bottom: 32px; }
  .hero__note { font-size: 11px; line-height: 1.6; }

  /* кнопки в столбец: иначе рваная лесенка по правому краю */
  .hero__cta { flex-direction: column; align-items: stretch; gap: 12px; }
  .hero__cta .btn { width: 100%; justify-content: center; padding: 17px 20px; }

  .hero__stats-row { grid-template-columns: 1fr 1fr; }
  .stat { padding: 20px 14px; }
  .stat__num { font-size: 21px; letter-spacing: -0.01em; }
  .stat__label { font-size: 12px; line-height: 1.4; }

  .section__title { font-size: 30px; }
  .section__head { margin-bottom: 36px; }
  .service { padding: 28px 22px 24px; }
  .service__list li,
  .service__text { font-size: 14.5px; }

  .compare__col { padding: 28px 22px; }
  .compare__col li { font-size: 15px; }

  .works-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .work-card figcaption { padding: 26px 10px 10px; font-size: 10px; letter-spacing: 0.04em; }

  /* рамка фото уходила на 20px вправо и давала горизонтальный скролл на iPhone */
  .master__photo { margin-right: 14px; }
  .master__photo::after { inset: 14px -14px -14px 14px; }
  .master__text { font-size: 16.5px; }
  .master__list li { font-size: 15px; }

  .chip { font-size: 12px; padding: 10px 16px; }

  .faq__item summary { padding: 18px 50px 18px 20px; font-size: 16px; }
  .faq__item summary::after { right: 18px; }
  .faq__item p { padding: 0 20px 20px; font-size: 15px; }

  .cta { padding: 72px 0; }
  .cta__title { font-size: 28px; }
  .cta__phone { font-size: 26px; margin-bottom: 32px; }
  .cta__actions { flex-direction: column; align-items: stretch; }
  .cta__actions .btn { width: 100%; justify-content: center; }

  .footer__bottom { flex-direction: column; gap: 8px; }
}

/* ---------- SEO-текст (блок «Где работаем») ---------- */
.seo-text {
  max-width: 900px;
  columns: 2;
  column-gap: 48px;
}
.seo-text p {
  font-size: 16px;
  line-height: 1.75;
  color: #55585D;
  margin-bottom: 18px;
  break-inside: avoid;
}
.seo-text p:last-child { margin-bottom: 0; }
.seo-text b { color: var(--ink); font-weight: 700; }
.seo-text a { color: var(--red); text-decoration: none; border-bottom: 1px solid rgba(210,5,30,.35); }
.seo-text a:hover { border-bottom-color: var(--red); }

.footer__legal { display: flex; gap: 20px; flex-wrap: wrap; }
.footer__legal a { color: #6B6E73; text-decoration: none; transition: color .2s; }
.footer__legal a:hover { color: var(--steel); }

@media (max-width: 900px) {
  .seo-text { columns: 1; }
}

/* ============================================================
   Телефон: меню — компактный пузырь в углу, а не полный экран.
   Полноэкранное на маленьком экране выглядит тяжело: человек
   хотел перейти в раздел, а получил заслонку во весь телефон.
   ============================================================ */
@media (max-width: 700px) {
  .nav.is-open {
    position: fixed;
    inset: auto 14px auto auto;      /* прижат к правому верхнему углу, под бургером */
    top: 68px;
    width: max-content;
    min-width: 208px;
    max-width: 66vw;
    height: auto;
    padding: 8px;
    gap: 0;
    align-items: stretch;
    justify-content: flex-start;
    border-radius: 24px;
    background: rgba(22, 23, 26, 0.72);
    backdrop-filter: blur(24px) saturate(1.6);
    -webkit-backdrop-filter: blur(24px) saturate(1.6);
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.6), 0 2px 8px rgba(0, 0, 0, 0.4);
    /* вылетает из-под кнопки, а не появляется ниоткуда */
    transform-origin: top right;
    animation: bubbleIn .2s cubic-bezier(.2, .9, .3, 1.1);
  }
  @keyframes bubbleIn {
    from { opacity: 0; transform: scale(.86) translateY(-6px); }
    to   { opacity: 1; transform: scale(1) translateY(0); }
  }

  /* затемняем страницу за пузырём, чтобы он читался поверх любого фона */
  .nav.is-open::before {
    content: '';
    position: fixed;
    inset: 0;
    background: rgba(8, 8, 9, 0.45);
    z-index: -1;
    animation: navIn .2s ease;
  }

  .nav.is-open .nav__link {
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 16.5px;
    text-align: left;
    padding: 13px 16px;
    border-radius: 16px;
    transition: background .15s;
  }
  .nav.is-open .nav__link + .nav__link { position: relative; }
  /* тонкие разделители, как в системных меню */
  .nav.is-open .nav__link + .nav__link::before {
    content: '';
    position: absolute;
    left: 16px; right: 16px; top: 0;
    height: 1px;
    background: rgba(255, 255, 255, 0.07);
  }
  .nav.is-open .nav__link:active { background: rgba(255, 255, 255, 0.08); }

  /* в пузыре подсказка не нужна — он и так очевидно закрывается тапом мимо */
  .nav.is-open .nav__close-hint { display: none; }
}

/* ---------- Уведомление о cookie ---------- */
/* Позиция РКН: аналитика с идентификатором посетителя = обработка ПД,
   значит нужно согласие ДО начала сбора, а не постфактум. */
.cookie {
  position: fixed;
  left: 20px; right: 20px; bottom: 20px;
  z-index: 150;
  max-width: 720px;
  margin: 0 auto;
  display: none;
  gap: 18px;
  align-items: center;
  padding: 18px 22px;
  background: rgba(22, 23, 26, 0.96);
  backdrop-filter: blur(18px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
  animation: cookieIn .3s ease;
}
.cookie.is-shown { display: flex; }
@keyframes cookieIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.cookie__text { flex: 1; font-size: 13.5px; line-height: 1.55; color: #C4C8CC; }
.cookie__text a { color: var(--red-hover); text-decoration: none; border-bottom: 1px solid rgba(245,20,46,.4); }
.cookie__actions { display: flex; gap: 10px; flex-shrink: 0; }
.cookie .btn { padding: 12px 20px; font-size: 11.5px; }
.cookie .btn--ghost { color: var(--steel); border-color: rgba(255,255,255,.18); }

@media (max-width: 640px) {
  .cookie { left: 12px; right: 12px; bottom: 12px; flex-direction: column; align-items: stretch; padding: 16px 18px; gap: 14px; }
  .cookie__text { font-size: 13px; }
  .cookie__actions { display: grid; grid-template-columns: 1fr 1fr; }
  .cookie .btn { width: 100%; justify-content: center; }
}
