/* ============================================================
   «Гарнизон» — юридическая помощь военнослужащим
   Светлый дружелюбный стиль солидной юридической фирмы
   ============================================================ */

:root {
  --bg: #F8F6F1;            /* тёплая слоновая кость */
  --bg-2: #F1EDE4;
  --card: #FFFFFF;
  --line: #E7E1D4;
  --ink: #1F2D3D;           /* чернильный тёмно-синий */
  --ink-2: #3A4C61;
  --muted: #6E7E90;
  --accent: #23577E;        /* глубокий спокойный синий */
  --accent-dark: #1B4566;
  --accent-dim: rgba(35, 87, 126, 0.08);
  --gold: #B9862E;          /* спокойное золото */
  --gold-2: #D8AE5A;
  --gold-dim: rgba(185, 134, 46, 0.1);
  --red: #C4453C;
  --radius: 18px;
  --container: 1200px;
  --font-body: 'Manrope', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-display: 'Playfair Display', Georgia, serif;
  --shadow-soft: 0 18px 40px -24px rgba(31, 45, 61, 0.28);
  --shadow-lift: 0 26px 50px -26px rgba(31, 45, 61, 0.38);
}

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

html { scroll-behavior: smooth; overflow-x: clip; }

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

::selection { background: rgba(216, 174, 90, 0.4); color: var(--ink); }

img, svg { display: block; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }
input, textarea { font: inherit; }

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

section { scroll-margin-top: 92px; }

.section { padding: 110px 0; }
.section-alt {
  background: var(--bg-2);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.accent {
  background: linear-gradient(120deg, #C99A3F, var(--gold) 55%, #9A6E1F);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

.section-head { max-width: 720px; margin-bottom: 56px; }
.section-head p { color: var(--muted); margin-top: 14px; font-size: 17px; }

.section-tag {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 12px;
  font-weight: 800;
  color: var(--gold);
  margin-bottom: 16px;
}
.section-tag::before {
  content: '';
  width: 26px;
  height: 2px;
  background: linear-gradient(90deg, var(--gold), transparent);
  border-radius: 2px;
}

h1, h2, h3 { font-weight: 700; line-height: 1.18; letter-spacing: -0.01em; }
h2 {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 2.9vw, 2.3rem);
  font-weight: 600;
}

/* ==================== Кнопки ==================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-weight: 800;
  font-size: 15px;
  border-radius: 14px;
  padding: 15px 28px;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease, border-color 0.25s ease;
  white-space: nowrap;
}
.btn svg { width: 18px; height: 18px; }

.btn-primary {
  background: linear-gradient(135deg, #2C648F, var(--accent) 55%, var(--accent-dark));
  color: #fff;
  box-shadow: 0 12px 26px -10px rgba(35, 87, 126, 0.55);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 18px 34px -10px rgba(35, 87, 126, 0.6); }
.btn-primary:active { transform: translateY(0); }

.btn-outline {
  border: 1px solid rgba(35, 87, 126, 0.4);
  color: var(--accent);
  background: rgba(255, 255, 255, 0.6);
}
.btn-outline:hover { background: var(--accent-dim); transform: translateY(-1px); }

.btn-block { width: 100%; }

/* ==================== Шапка ==================== */
.header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  padding: 14px 0;
  transition: background 0.3s ease, box-shadow 0.3s ease, padding 0.3s ease;
  border-bottom: 1px solid transparent;
}
.header.scrolled {
  background: rgba(248, 246, 241, 0.97);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom-color: var(--line);
  box-shadow: 0 8px 24px -18px rgba(31, 45, 61, 0.35);
  padding: 10px 0;
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 20px;
}

.logo { display: flex; align-items: center; gap: 12px; min-width: 0; }
.logo-mark { width: 38px; height: 38px; color: var(--accent); flex-shrink: 0; }
.logo-text {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 21px;
  line-height: 1.1;
  letter-spacing: 0.01em;
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.logo-text small {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 10.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 3px;
}
@media (max-width: 480px) {
  .logo-text { font-size: 19px; }
  .logo-text small { font-size: 8.5px; letter-spacing: 0.05em; white-space: normal; }
}

.nav { display: flex; align-items: center; gap: 20px; margin-left: auto; }
.nav a {
  font-size: 14px;
  font-weight: 700;
  color: var(--ink-2);
  position: relative;
  white-space: nowrap;
  transition: color 0.25s ease;
}
.nav a:hover { color: var(--accent); }
.nav a::after {
  content: '';
  position: absolute;
  left: 0; bottom: -6px;
  width: 100%;
  height: 2px;
  border-radius: 2px;
  background: var(--gold-2);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}
.nav a:hover::after { transform: scaleX(1); }

.nav-phone { display: none; }

/* Переключатель языка */
.lang-switch {
  display: flex;
  align-items: center;
  gap: 3px;
  margin-left: 4px;
  padding-left: 14px;
  border-left: 1px solid var(--line);
}
.lang-btn {
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: 0.06em;
  padding: 6px 9px;
  border-radius: 8px;
  color: var(--muted);
  border: 1px solid transparent;
  transition: color 0.25s ease, background 0.25s ease;
}
.lang-btn:hover { color: var(--accent); background: var(--accent-dim); }
.lang-btn.active { background: var(--accent); color: #fff; }

.header-phone {
  font-weight: 800;
  font-size: 15px;
  color: var(--ink);
  white-space: nowrap;
  transition: color 0.25s ease;
}
.header-phone:hover { color: var(--accent); }

.header-cta { padding: 11px 20px; font-size: 13.5px; border-radius: 11px; }

.burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.7);
  flex-shrink: 0;
}
.burger span {
  display: block;
  height: 2px;
  border-radius: 2px;
  background: var(--ink);
  transition: transform 0.3s ease, opacity 0.3s ease;
}
body.nav-open .burger span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
body.nav-open .burger span:nth-child(2) { opacity: 0; }
body.nav-open .burger span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ==================== Главный экран ==================== */
.hero {
  position: relative;
  padding: 168px 0 110px;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero-bg { position: absolute; inset: 0; z-index: 0; }
.hero-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.8;
}
.hero-glow-1 {
  width: 640px; height: 640px;
  right: -200px; top: -240px;
  background: radial-gradient(circle, rgba(35, 87, 126, 0.14), transparent 65%);
}
.hero-glow-2 {
  width: 700px; height: 700px;
  left: -280px; bottom: -320px;
  background: radial-gradient(circle, rgba(216, 174, 90, 0.2), transparent 65%);
}
.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(31, 45, 61, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(31, 45, 61, 0.045) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 90% 70% at 50% 40%, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 90% 70% at 50% 40%, #000 30%, transparent 75%);
}
.hero-pattern {
  position: absolute;
  inset: auto 0 0 0;
  width: 100%;
  height: 60%;
}

.hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) 470px;
  gap: 64px;
  align-items: center;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 9px 16px;
  border-radius: 999px;
  border: 1px solid rgba(185, 134, 46, 0.35);
  background: var(--gold-dim);
  color: #8A6420;
  font-size: 13px;
  font-weight: 800;
  margin-bottom: 26px;
}
.badge svg { width: 15px; height: 15px; fill: currentColor; }

.hero h1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.8rem, 3.7vw, 3.1rem);
  line-height: 1.16;
  margin-bottom: 22px;
}

.hero-sub {
  color: var(--muted);
  font-size: 18px;
  max-width: 520px;
  margin-bottom: 28px;
}

.hero-list { display: flex; flex-direction: column; gap: 12px; margin-bottom: 40px; }
.hero-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  font-size: 15.5px;
}
.hero-list svg {
  width: 22px; height: 22px;
  padding: 4px;
  border-radius: 50%;
  color: #fff;
  background: linear-gradient(135deg, #C99A3F, var(--gold));
  flex-shrink: 0;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(4, auto);
  gap: 14px 44px;
  padding-top: 30px;
  border-top: 1px solid var(--line);
}
.stat-value {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 25px;
  color: var(--ink);
  display: flex;
  align-items: baseline;
  gap: 6px;
  white-space: nowrap;
}
.stat-suffix { font-size: 14px; color: var(--gold); font-family: var(--font-body); font-weight: 800; }
.stat-label { font-size: 13px; color: var(--muted); margin-top: 4px; max-width: 150px; }

/* ==================== Форма обратной связи ==================== */
.lead-form {
  position: relative;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 34px;
  box-shadow: var(--shadow-lift), inset 0 1px 0 #fff;
}
.lead-form::before {
  content: '';
  position: absolute;
  top: -1px; left: 28px; right: 28px;
  height: 3px;
  border-radius: 0 0 3px 3px;
  background: linear-gradient(90deg, transparent, var(--gold-2), transparent);
}

.form-head h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 22px;
  margin-bottom: 8px;
}
.form-head p { color: var(--muted); font-size: 14px; margin-bottom: 26px; }

.field { margin-bottom: 18px; }
.field label {
  display: block;
  font-size: 12.5px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--muted);
  margin-bottom: 8px;
}
.field input {
  width: 100%;
  background: #FDFCF9;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px 16px;
  color: var(--ink);
  font-size: 15.5px;
  transition: border-color 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}
.field input::placeholder { color: #A9B2BE; }
.field input:focus {
  outline: none;
  border-color: var(--accent);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(35, 87, 126, 0.12);
}

.field-error {
  display: none;
  font-size: 12.5px;
  color: var(--red);
  margin-top: 6px;
}
.field.is-invalid input { border-color: rgba(196, 69, 60, 0.7); }
.field.is-invalid .field-error { display: block; }

.consent {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.5;
  margin: 4px 0 20px;
  cursor: pointer;
  user-select: none;
}
.consent input {
  width: 16px; height: 16px;
  margin-top: 2px;
  accent-color: var(--accent);
  cursor: pointer;
  flex-shrink: 0;
}
.consent a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
.consent.is-invalid { color: var(--red); }

.form-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 12.5px;
  color: var(--muted);
  margin-top: 16px;
  text-align: center;
}
.form-note svg { width: 15px; height: 15px; flex-shrink: 0; color: var(--gold); }

/* Состояние успеха */
.form-success {
  text-align: center;
  padding: 26px 6px;
  animation: successIn 0.5s cubic-bezier(0.2, 0.9, 0.3, 1.2) both;
}
@keyframes successIn {
  from { opacity: 0; transform: translateY(16px) scale(0.97); }
  to { opacity: 1; transform: none; }
}
.success-icon {
  width: 74px; height: 74px;
  margin: 0 auto 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #3C7BA9, var(--accent));
  box-shadow: 0 14px 34px -8px rgba(35, 87, 126, 0.5);
}
.success-icon svg { width: 34px; height: 34px; color: #fff; }
.form-success h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 21px;
  margin-bottom: 10px;
}
.form-success p { color: var(--muted); font-size: 14.5px; margin-bottom: 22px; }
.form-success .form-warn {
  font-size: 12.5px;
  color: #8A6420;
  background: var(--gold-dim);
  border: 1px solid rgba(185, 134, 46, 0.3);
  border-radius: 10px;
  padding: 10px 14px;
  margin: -8px 0 20px;
}
.form-error-top { color: var(--red) !important; }

/* ==================== Услуги ==================== */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.service-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 28px;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-soft);
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}
.service-card:hover {
  transform: translateY(-5px);
  border-color: rgba(35, 87, 126, 0.35);
  box-shadow: var(--shadow-lift);
}

.service-icon {
  width: 54px; height: 54px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-dim);
  border: 1px solid rgba(35, 87, 126, 0.2);
  color: var(--accent);
  margin-bottom: 20px;
}
.service-icon svg { width: 26px; height: 26px; }

.service-card h3 { font-size: 17.5px; font-weight: 800; margin-bottom: 10px; }
.service-card p { color: var(--muted); font-size: 14.5px; flex-grow: 1; }

.service-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 20px;
  font-size: 13.5px;
  font-weight: 800;
  color: var(--accent);
}
.service-link svg { width: 16px; height: 16px; transition: transform 0.3s ease; }
.service-link:hover svg { transform: translateX(5px); }

/* ==================== Шаги ==================== */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.step {
  position: relative;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 26px;
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  transition: transform 0.3s ease, border-color 0.3s ease;
}
.step:hover { transform: translateY(-5px); border-color: rgba(185, 134, 46, 0.45); }

.step-num {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 52px;
  line-height: 1;
  color: var(--gold-2);
  display: block;
  margin-bottom: 18px;
}
.step h3 { font-size: 17px; font-weight: 800; margin-bottom: 10px; }
.step p { color: var(--muted); font-size: 14.5px; }

/* ==================== Кейсы ==================== */
.cases-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.case-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-top: 3px solid var(--gold-2);
  border-radius: var(--radius);
  padding: 28px 26px;
  box-shadow: var(--shadow-soft);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.case-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lift); }

.case-tag {
  display: inline-block;
  font-size: 11.5px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #8A6420;
  background: var(--gold-dim);
  border: 1px solid rgba(185, 134, 46, 0.3);
  border-radius: 999px;
  padding: 6px 13px;
  margin-bottom: 20px;
}
.case-amount {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 27px;
  color: var(--ink);
  margin-bottom: 12px;
  white-space: nowrap;
}
.case-card p { color: var(--muted); font-size: 14px; }

/* ==================== Почему мы ==================== */
.why-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.why-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 28px;
  box-shadow: var(--shadow-soft);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.why-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lift); }
.why-icon {
  width: 50px; height: 50px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-dim);
  border: 1px solid rgba(35, 87, 126, 0.2);
  color: var(--accent);
  margin-bottom: 18px;
}
.why-icon svg { width: 24px; height: 24px; }
.why-card h3 { font-size: 16.5px; font-weight: 800; margin-bottom: 8px; }
.why-card p { color: var(--muted); font-size: 14.5px; }

/* ==================== FAQ ==================== */
.faq-item {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0 24px;
  margin-bottom: 14px;
  box-shadow: var(--shadow-soft);
  transition: border-color 0.25s ease;
}
.faq-item.open { border-color: rgba(35, 87, 126, 0.35); }
.faq-q {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  text-align: left;
  padding: 22px 0;
  font-size: 16.5px;
  font-weight: 800;
  transition: color 0.25s ease;
}
.faq-q:hover { color: var(--accent); }
.faq-q svg {
  width: 20px; height: 20px;
  color: var(--gold);
  flex-shrink: 0;
  transition: transform 0.35s ease;
}
.faq-item.open .faq-q svg { transform: rotate(180deg); }

.faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease;
}
.faq-a p {
  color: var(--muted);
  font-size: 15px;
  padding: 0 36px 22px 0;
}

/* ==================== Контакты / CTA ==================== */
.section-cta {
  position: relative;
  background: var(--bg-2);
  border-top: 1px solid var(--line);
  overflow: hidden;
}
.section-cta::before {
  content: '';
  position: absolute;
  width: 560px; height: 560px;
  border-radius: 50%;
  left: -200px; top: -160px;
  background: radial-gradient(circle, rgba(216, 174, 90, 0.18), transparent 65%);
  filter: blur(70px);
}

.cta-inner {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) 440px;
  gap: 64px;
  align-items: center;
  padding-top: 110px;
  padding-bottom: 110px;
}

.cta-text p { color: var(--muted); margin-top: 14px; max-width: 520px; }

.cta-contacts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-top: 36px;
}
.contact-item {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px 18px;
  box-shadow: var(--shadow-soft);
  transition: border-color 0.25s ease, transform 0.25s ease;
}
a.contact-item:hover { border-color: rgba(35, 87, 126, 0.4); transform: translateY(-2px); }
.contact-item svg { width: 22px; height: 22px; color: var(--accent); flex-shrink: 0; }
.contact-item span { display: flex; flex-direction: column; font-size: 14.5px; font-weight: 700; line-height: 1.4; }
.contact-item small {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
}

.lead-form--compact { padding: 30px; }

/* ==================== Футер ==================== */
.footer {
  background: var(--ink);
  color: #EDEAE2;
  padding: 70px 0 30px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1.3fr;
  gap: 40px;
  padding-bottom: 44px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
}
.footer .logo-mark { color: var(--gold-2); }
.footer .logo-text { color: #fff; }
.footer .logo-text small { color: rgba(237, 234, 226, 0.6); }
.footer-brand p { color: rgba(237, 234, 226, 0.65); font-size: 14px; margin-top: 18px; max-width: 300px; }

.footer-nav { display: flex; flex-direction: column; gap: 11px; }
.footer-nav h4, .footer-contacts h4 {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #fff;
  margin-bottom: 8px;
}
.footer-nav a { color: rgba(237, 234, 226, 0.65); font-size: 14.5px; transition: color 0.25s ease; }
.footer-nav a:hover { color: var(--gold-2); }

.footer-contacts { display: flex; flex-direction: column; gap: 11px; }
.footer-contacts a { color: var(--gold-2); font-weight: 700; font-size: 15px; transition: color 0.25s ease; }
.footer-contacts a:hover { color: #fff; }
.footer-contacts p { color: rgba(237, 234, 226, 0.65); font-size: 14px; }

.footer-bottom {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-top: 26px;
  color: rgba(237, 234, 226, 0.6);
  font-size: 12.5px;
}
.footer-disclaimer { opacity: 0.75; }

/* ==================== Мессенджеры ==================== */
.messenger-float {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 90;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.msgr {
  width: 54px; height: 54px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--card);
  border: 1px solid rgba(35, 87, 126, 0.3);
  color: var(--accent);
  box-shadow: var(--shadow-lift);
  transition: transform 0.25s ease, background 0.25s ease, color 0.25s ease;
}
.msgr:hover { transform: translateY(-3px); background: var(--accent); color: #fff; }
.msgr svg { width: 25px; height: 25px; }

/* ==================== Анимации появления ==================== */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s cubic-bezier(0.22, 0.7, 0.3, 1), transform 0.7s cubic-bezier(0.22, 0.7, 0.3, 1);
}
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  * { animation-duration: 0.001s !important; transition-duration: 0.001s !important; }
}

/* ==================== Адаптив ==================== */
@media (max-width: 1280px) {
  .header-phone { display: none; }
}

@media (max-width: 1120px) {
  .hero-inner { grid-template-columns: 1fr; gap: 52px; }
  .hero-form-wrap { max-width: 560px; }
  .hero { padding-top: 140px; min-height: 0; }
  .services-grid { grid-template-columns: repeat(2, 1fr); }
  .why-grid { grid-template-columns: repeat(2, 1fr); }
  .steps-grid { grid-template-columns: repeat(2, 1fr); }
  .cases-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 1024px) {
  .nav {
    position: fixed;
    top: 0; right: 0;
    height: 100dvh;
    width: min(360px, 86vw);
    background: rgba(248, 246, 241, 0.98);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border-left: 1px solid var(--line);
    box-shadow: -20px 0 50px -30px rgba(31, 45, 61, 0.4);
    flex-direction: column;
    align-items: flex-start;
    padding: 96px 34px 34px;
    gap: 22px;
    transform: translateX(100%);
    visibility: hidden; /* закрытое меню: не переполняет экран и не ловит фокус */
    transition: transform 0.35s cubic-bezier(0.22, 0.7, 0.3, 1), visibility 0s 0.35s;
    z-index: 95;
  }
  body.nav-open .nav {
    transform: none;
    visibility: visible;
    transition: transform 0.35s cubic-bezier(0.22, 0.7, 0.3, 1);
  }
  .nav a { font-size: 17px; }
  .nav a::after { display: none; }
  .nav-phone {
    display: block;
    color: var(--accent);
    font-weight: 800;
    margin-top: 6px;
  }
  .lang-switch {
    margin: 14px 0 0;
    padding: 0;
    border-left: none;
  }
  .burger { display: flex; z-index: 96; }
  .header-phone { display: none; }
}

@media (max-width: 720px) {
  .section { padding: 80px 0; }
  .cta-inner { padding-top: 80px; padding-bottom: 80px; }
  .hero { padding: 128px 0 80px; }
  .hero-stats { grid-template-columns: repeat(2, 1fr); gap: 22px 20px; }
  .stat-label { max-width: none; }
  .services-grid, .why-grid, .steps-grid, .cases-grid { grid-template-columns: 1fr; }
  .cta-inner { grid-template-columns: 1fr; gap: 48px; }
  .cta-contacts { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 34px; }
  .header-cta { display: none; }
  .lead-form { padding: 26px 22px; }
  .faq-q { font-size: 15.5px; }
  .messenger-float { right: 16px; bottom: 16px; }
}

@media (max-width: 420px) {
  .hero-stats { grid-template-columns: repeat(2, 1fr); }
  .stat-value { font-size: 21px; }
  .badge { font-size: 12px; padding: 8px 13px; }
}
