/* =========================
   ПАЛИТРА И ПЕРЕМЕННЫЕ
   ========================= */
:root {
  --bg-body: #f4f6f9;
  --card-bg: #ffffff;
  --text-main: #1d2125;
  --text-muted: #5a6268;

  --primary-color: #0b3b60;
  --accent-color: #1a56db;

  --cta-a: #c82333;
  --cta-b: #a71d2a;

  --radius-card: 0px;
  --radius-btn: 0px;

  --shadow-card: 0 4px 12px rgba(0, 0, 0, 0.05);
  --shadow-card-hover: 0 8px 24px rgba(0, 0, 0, 0.12);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  font-family: 'Inter', sans-serif;
  color: var(--text-main);
  background-color: var(--bg-body);
  line-height: 1.5;
  height: 100%; 
  overflow: hidden;
  padding-bottom: 7vh; /* Отступ под 7% плашку */
}

h1, h2, h3, h4, h5 {
  font-family: 'Montserrat', sans-serif;
  font-weight: 900;
  color: var(--primary-color);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.text-muted {
  color: var(--text-muted) !important;
}

.divider {
  height: 3px; 
  width: 60px; 
  background: var(--cta-a); 
  margin: 0 auto 20px;
}

.aesthetic-container {
  max-width: 1140px !important;
  margin: 0 auto;
}

/* =========================
   ПЛАВАЮЩИЙ ДИСКЛЕЙМЕР (7% ЭКРАНА)
   ========================= */
.legal-disclaimer-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  min-height: 7vh;
  background-color: #0b3b60;
  color: #ffffff;
  z-index: 900; /* Уменьшен z-index */
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 5px 15px;
  font-size: 0.75rem;
  font-weight: 600;
  border-top: 2px solid #082a45;
  box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
}

/* Выводим бейдж reCAPTCHA над дисклеймером (7vh) */
.grecaptcha-badge {
  z-index: 1000 !important;
  bottom: calc(7vh + 10px) !important;
}

/* =========================
   SCROLL SNAP РЕАЛИЗАЦИЯ
   ========================= */
.scroll-container {
  margin-top: 60px;
  height: calc(100vh - 60px - 7vh); /* Учет шапки и подвала с дисклеймером */
  overflow-y: auto;
}

@media (min-width: 992px) {
  .scroll-container {
    scroll-snap-type: y mandatory;
    scroll-behavior: smooth;
    overflow-y: scroll;
  }
  .scroll-screen {
    height: 100%;
    scroll-snap-align: start;
    scroll-snap-stop: always;
    overflow: hidden;
    box-sizing: border-box;
  }
}

/* =========================
   АНИМАЦИИ
   ========================= */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(15px); }
  to { opacity: 1; transform: translateY(0); }
}
.animate-up {
  animation: fadeInUp 0.5s ease-out forwards;
  opacity: 0;
}
.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.2s; }
.delay-3 { animation-delay: 0.3s; }

/* =========================
   ВЕРХНЯЯ ПАНЕЛЬ
   ========================= */
.sticky-top-bar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 60px;
  background-color: #fff;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  border-bottom: 2px solid var(--primary-color);
}

.header-phone {
  font-family: 'Montserrat', sans-serif;
  font-weight: 800;
  font-size: 1.05rem;
  color: var(--primary-color);
  text-decoration: none;
}

.btn-header-call {
  background-color: transparent;
  color: var(--primary-color);
  border: 1px solid rgba(0, 0, 0, 0.3);
  padding: 6px 16px;
  border-radius: var(--radius-btn);
  text-decoration: none;
  font-weight: 700;
  font-size: .85rem;
  transition: all .2s ease;
}
.btn-header-call:hover {
  background-color: var(--primary-color);
  color: #fff;
}

.header-messenger-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease;
}
.header-messenger-link:hover {
  transform: translateY(-2px);
}
.header-messenger-img {
  width: 24px;
  height: 24px;
  object-fit: contain;
}

/* =========================
   ЭКРАН 1: ГЛАВНЫЙ ЭКРАН
   ========================= */
.hero-section {
  background: linear-gradient(to left, rgba(244, 246, 249, 1) 0%, rgba(244, 246, 249, 0.8) 100%), url('../img/bg-main.png') center/cover no-repeat;
  min-height: 100%;
}

.hero-title {
  font-size: clamp(1.3rem, 2.3vw, 1.9rem) !important;
  line-height: 1.2;
}

.hero-subtitle {
  font-size: 0.95rem;
  font-weight: 500;
}

.expert-resume-card {
  flex-shrink: 0;
  background: var(--card-bg);
  border: 2px solid var(--primary-color);
  box-shadow: 6px 6px 0 var(--cta-a);
  padding: 16px;
  position: relative;
  z-index: 10;
  margin-bottom: 12px;
  max-height: 45vh;
  overflow-y: auto;
}

.expert-name {
  font-size: 1.1rem;
  margin-bottom: 2px;
  color: var(--text-main);
  text-transform: uppercase;
}
.expert-role {
  font-size: 0.8rem;
  text-transform: uppercase;
  font-weight: 900;
  color: var(--cta-a);
  letter-spacing: 0.5px;
  margin-bottom: 10px;
}
.expert-facts {
  font-size: 0.75rem;
  color: var(--text-main);
  line-height: 1.4;
}
.expert-facts li {
  margin-bottom: 6px;
  position: relative;
  padding-left: 14px;
}
.expert-facts li::before {
  content: '■';
  position: absolute;
  left: 0;
  top: 0;
  color: var(--primary-color);
  font-size: 0.55rem;
  line-height: 2;
}

.hero-image-wrapper {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  width: 100%;
  position: relative;
  overflow: hidden;
  margin-bottom: -8px;
}
.hero-silhouette-enlarged {
  display: block;
  width: auto;
  height: auto;
  max-height: 100%;
  max-width: 100%;
  object-fit: contain;
  object-position: bottom center;
  flex-shrink: 0;
  filter: drop-shadow(10px 10px 20px rgba(0, 0, 0, 0.2));
}

.compact-block {
  background: var(--card-bg);
  border: 2px solid var(--primary-color);
  box-shadow: 4px 4px 0 var(--cta-a);
  padding: 10px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  border-radius: var(--radius-card);
  height: 100%;
  transition: transform 0.2s ease;
}
.compact-block:hover {
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 var(--cta-a);
}

.c-icon {
  width: 34px;
  height: 34px;
  background: var(--primary-color);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0;
  flex-shrink: 0;
}
.c-icon svg { width: 18px; height: 18px; stroke: currentColor; stroke-width: 2; fill: none; }
.c-title { font-size: 0.8rem; font-weight: 900; color: var(--primary-color); text-transform: uppercase; }
.c-text { font-size: 0.75rem; color: var(--text-main); line-height: 1.2; margin-top: 2px; }
.c-desc { font-size: 0.65rem; color: var(--text-muted); line-height: 1.2; margin-top: 4px; }

.step-container { display: flex; flex-direction: column; }
.step-row { background: transparent; padding: 0 0 6px 0; }
.step-item { font-size: 0.8rem; font-weight: 700; color: var(--text-main); }
.step-arrow { color: var(--primary-color); font-weight: bold; user-select: none; }

.step-item-trigger {
  cursor: pointer; transition: all 0.2s ease; padding: 2px 6px; border-radius: var(--radius-btn); border: 1px solid transparent;
}
.step-item-trigger:hover { color: var(--cta-a); border-color: rgba(0, 0, 0, 0.1); }
.step-item-trigger.active { color: #fff !important; background: var(--primary-color); border-color: var(--primary-color); }

.step-desc-box {
  background: var(--card-bg);
  border: 2px solid var(--primary-color);
  border-left: 6px solid var(--cta-a);
  box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.1);
  padding: 12px;
  font-size: 0.85rem;
  line-height: 1.4;
  color: var(--text-main);
  transition: opacity 0.15s ease-in-out;
  text-align: left;
}

.btn-start-online {
  background: var(--cta-a) !important;
  color: #fff !important;
  padding: 14px 35px !important;
  border-radius: var(--radius-btn) !important;
  font-family: 'Montserrat', sans-serif !important;
  font-weight: 900 !important;
  text-transform: uppercase !important;
  border: none !important;
  font-size: 1rem !important;
  letter-spacing: 1px !important;
  transition: background 0.3s ease, transform 0.2s ease !important;
  cursor: pointer;
  display: inline-block;
  box-shadow: 4px 4px 0 var(--primary-color);
  width: 100%;
  max-width: 360px;
}
.btn-start-online:hover {
  background: var(--cta-b) !important;
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 var(--primary-color);
}

/* =========================
   ЭКРАН 2: КАРУСЕЛЬ ПРАКТИКИ + ЦЕНЫ
   ========================= */
.practice-slider-container {
  width: 100%;
  position: relative;
}
.practice-slide-item {
  transition: opacity 0.3s ease;
}
.practice-slide-item.active {
  display: flex !important;
}

.practice-card {
  background: #fff;
  border: 2px solid var(--primary-color);
  box-shadow: 6px 6px 0 var(--cta-a);
  display: flex;
  flex-direction: row;
  align-items: stretch;
  width: 100%;
  height: 420px;
  flex-shrink: 0;
}

.practice-img {
  width: 50%;
  background: #e9ecef;
  border-right: 2px solid var(--primary-color);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  overflow: hidden;
}
.practice-img img {
  width: 100%;
  height: 100%;
  object-fit: contain; 
  object-position: center; 
  box-shadow: 2px 4px 12px rgba(0,0,0,0.15);
  background: #fff;
  border-radius: 0;
}

.zoomable-image {
  cursor: zoom-in;
}
.zoomable-image::after {
  content: '🔍';
  position: absolute;
  bottom: 25px;
  right: 25px;
  background: var(--primary-color);
  color: #fff;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  border-radius: 50%;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
  opacity: 0.8;
  transition: transform 0.2s ease, opacity 0.2s ease;
  pointer-events: none;
}
.zoomable-image:hover::after {
  transform: scale(1.1);
  opacity: 1;
}

.lightbox-overlay {
  position: fixed;
  inset: 0;
  background: rgba(11, 59, 96, 0.9);
  backdrop-filter: blur(4px);
  z-index: 3000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  cursor: zoom-out;
}
.lightbox-overlay.active {
  display: flex;
}
.lightbox-overlay img {
  max-width: 90vw;
  max-height: 90vh;
  border: 4px solid #fff;
  box-shadow: 0 10px 40px rgba(0,0,0,0.5);
  border-radius: 2px;
}
.lightbox-close {
  position: absolute;
  top: 20px;
  right: 30px;
  color: #fff;
  font-size: 40px;
  cursor: pointer;
  text-shadow: 0 2px 4px rgba(0,0,0,0.5);
  transition: color 0.2s;
}
.lightbox-close:hover {
  color: var(--cta-a);
}


.practice-content {
  width: 50%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow-y: auto;
  padding: 20px 24px;
}

.case-number {
  font-weight: 900;
  color: var(--cta-a);
  font-size: 0.75rem; 
  margin-bottom: 2px;
  letter-spacing: 0.5px;
}
.case-title {
  color: var(--primary-color);
  font-size: 0.9rem; 
  margin-bottom: 4px;
  line-height: 1.2;
}
.case-desc {
  color: var(--text-main);
  font-size: 0.75rem; 
  margin-bottom: 4px;
  line-height: 1.3;
}
.case-list {
  padding-left: 16px;
  font-weight: 600;
  color: var(--text-main);
  font-size: 0.7rem; 
  margin-bottom: 0;
}
.case-list li {
  margin-bottom: 2px;
  line-height: 1.3;
}

.slider-arrow-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background-color: var(--primary-color);
  color: #fff;
  border: none;
  width: 32px;
  height: 32px;
  font-size: 1.4rem;
  font-weight: bold;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  transition: background 0.2s ease;
}
.slider-arrow-btn:hover { background-color: var(--accent-color); }
.slider-arrow-btn.prev { left: -10px; }
.slider-arrow-btn.next { right: -10px; }

.sync-header {
  height: auto; 
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  text-align: center;
}
.sync-header h2 {
  font-size: 1.1rem;
  margin-bottom: 2px;
}
.sync-header .divider {
  margin-bottom: 4px;
  width: 40px;
}
.sync-header p {
  font-size: 0.75rem;
  margin-bottom: 0;
}

@media (min-width: 992px) {
  .sub-column-gap {
    gap: 16px !important;
  }
  .main-pricing-block {
    height: 420px !important;
    min-height: 420px !important;
    border: 2px solid var(--primary-color);
    box-shadow: 4px 4px 0 var(--primary-color);
    margin-bottom: 0 !important;
    flex-shrink: 0;
  }
  .sub-block-height {
    height: 115px !important;
    min-height: 115px !important;
    flex-shrink: 0;
  }
  .practice-slider-container {
    height: 420px !important;
    min-height: 420px !important;
    flex-shrink: 0;
  }
}

.stats-card {
  background: var(--primary-color);
  border: 2px solid var(--primary-color);
  box-shadow: 4px 4px 0 var(--cta-a);
  border-radius: var(--radius-card);
}

.pricing-card {
  border: 2px solid var(--primary-color);
  box-shadow: 4px 4px 0 var(--primary-color);
  padding: 1.2rem !important;
}
.pricing-card h3 {
  font-size: 1rem;
  margin-bottom: 0.5rem;
}
.price-stage {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  border-bottom: 1px dashed #ccc;
  padding-bottom: 8px;
  margin-bottom: 8px;
}
.price-stage.last {
  border-bottom: none;
  padding-bottom: 0;
  margin-bottom: 0;
}
.stage-amount {
  background: #f4f6f9;
  border: 2px solid var(--primary-color);
  font-weight: 900;
  color: var(--primary-color);
  text-align: center;
  padding: 2px 8px;
  min-width: 70px;
  font-size: 0.8rem;
  flex-shrink: 0;
}
.stage-amount.highlight {
  background: var(--cta-a);
  color: #fff;
  border-color: var(--cta-a);
}
.stage-info strong {
  display: block;
  color: var(--text-main);
  font-size: 0.8rem;
}
.stage-info span {
  color: var(--text-muted);
  font-size: 0.7rem;
  line-height: 1.2;
}

.costs-card {
  background: var(--primary-color);
  border: 2px solid #fff;
  box-shadow: 4px 4px 0 var(--cta-a);
  padding: 0.8rem !important;
}
.costs-card h4 {
  font-size: 0.75rem;
  margin-bottom: 2px;
}
.costs-card .fw-bold {
  font-size: 1rem;
}
.costs-card .text-white-50 {
  font-size: 0.65rem;
  line-height: 1.2;
}

.guarantee-box {
  background: #fff;
  border: 2px solid var(--cta-a);
  box-shadow: 4px 4px 0 var(--primary-color);
  padding: 0.8rem !important;
}
.guarantee-box h4 {
  font-size: 0.75rem;
  margin-bottom: 2px;
}
.guarantee-box p {
  font-size: 0.65rem;
  line-height: 1.2;
  margin-bottom: 0;
}

/* =========================
   ЭКРАН 3: КАРТА, РЕГИОНЫ И АУДИТ
   ========================= */
.contact-audit-card {
  border: 2px solid var(--primary-color);
  border-left: 6px solid var(--cta-a);
  box-shadow: 6px 6px 0 var(--cta-a);
}
.border-primary-custom {
  border: 2px solid var(--primary-color);
  box-shadow: 6px 6px 0 var(--primary-color);
  border-radius: var(--radius-card);
}

.sharp-btn {
  border-radius: var(--radius-btn) !important;
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.8rem !important;
  padding: 0.6rem 1rem !important;
}

.map-container-snap {
  height: 300px;
  position: relative;
  /* Добавлено для устранения нахлеста карты на футер */
  margin-bottom: 20px; 
}

@media (min-width: 992px) {
  .nowrap-lg { white-space: nowrap; }
}

/* =========================
   ФУТЕР
   ========================= */
.footer-social-img {
  filter: grayscale(100%);
  transition: filter 0.3s ease;
  width: 28px;
  height: 28px;
  display: block;
}
.social-link:hover .footer-social-img { filter: grayscale(0%); }
.social-link { display: inline-flex; transition: transform .2s ease; }
.social-link:hover { transform: translateY(-2px); }
.footer-link { text-decoration: none; color: var(--text-muted); font-weight: 600; }
.footer-link:hover { color: var(--primary-color); }

/* =========================
   МОДАЛЬНОЕ ОКНО КВИЗА
   ========================= */
.quiz-overlay {
  position: fixed;
  inset: 0;
  background: rgba(11, 59, 96, 0.9);
  backdrop-filter: blur(6px);
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  visibility: hidden;
  display: flex !important;
  z-index: -1;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}
body.quiz-open .quiz-overlay {
  opacity: 1;
  visibility: visible;
  z-index: 2000;
}
.quiz-card {
  width: min(500px, 100%);
  height: auto;
  min-height: 480px;
  max-height: 90vh;
  background: var(--card-bg);
  position: relative;
  display: flex;
  flex-direction: column;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
  transform: scale(0.98) translateY(10px);
  transition: transform 0.3s ease;
  border: 2px solid var(--primary-color);
  border-top: 6px solid var(--cta-a);
}
body.quiz-open .quiz-card { transform: scale(1) translateY(0); }
.btn-close-quiz {
  position: absolute; top: 8px; right: 12px; width: 32px; height: 32px;
  background: transparent; border: none; color: var(--text-muted); cursor: pointer; z-index: 3;
  display: flex; align-items: center; justify-content: center;
}
.btn-close-quiz:hover { color: var(--cta-a); }
.btn-close-quiz svg { width: 20px; height: 20px; stroke: currentColor; stroke-width: 2.5; fill: none; }
.quiz-inner { padding: 32px 24px 24px !important; display: flex; flex-direction: column; height: 100%; }
.quiz-back-btn { border: none; background: transparent; color: var(--text-muted); padding: 0; cursor: pointer; font-size: 0.85rem; font-weight: 700; text-transform: uppercase; }
.quiz-back-btn:hover { color: var(--primary-color); }
.quiz-grid-options { display: grid; grid-template-columns: 1fr; gap: 8px !important; }
.btn-quiz-option {
  border: 2px solid rgba(0, 0, 0, 0.1); background: #fff; color: var(--text-main);
  padding: 12px 16px !important; font-weight: 600; cursor: pointer; text-align: left;
  font-size: 0.9rem !important; transition: all .2s ease;
}
.btn-quiz-option:hover { border-color: var(--primary-color); }
.btn-quiz-option.selected { border-color: var(--accent-color); background: rgba(26, 86, 219, 0.05); border-left: 6px solid var(--accent-color); }
.quiz-action-area { margin-top: auto; padding-top: 24px; text-align: center; }
.quiz-submit-btn {
  display: inline-block; width: auto; min-width: 200px; border: 0; padding: 12px 24px !important;
  font-size: 0.9rem !important; font-weight: 800; text-transform: uppercase; color: #fff; background: var(--cta-a);
  cursor: pointer; transition: background 0.2s;
}
.quiz-submit-btn:hover:not(:disabled) { background: var(--cta-b); }
.quiz-submit-btn:disabled { background: #d6d6d6; cursor: not-allowed; color: #999; }
.range-value-label { font-size: 1.5rem; font-weight: 900; color: var(--primary-color); display: inline-block; margin-bottom: 15px; }
input[type="range"] { width: 100%; accent-color: var(--accent-color); }
.form-control { border: 2px solid rgba(0, 0, 0, 0.1); padding: 12px; font-weight: 500; }
.form-control:focus { border-color: var(--primary-color); outline: none; box-shadow: none; }

/* =========================
   АДАПТИВНОСТЬ / МЕДИА
   ========================= */
@media (max-width: 991.98px) {
  html, body { overflow: visible !important; height: auto !important; }
  .scroll-container { height: auto !important; margin-top: 54px; overflow: visible !important; }
  
  .mobile-expert-col { margin-bottom: 15px !important; }
  .hero-text-col { height: auto !important; padding: 0 0 20px 0 !important; }
  .price-stage { flex-direction: column; gap: 8px; }
  .slider-arrow-btn.prev { left: 4px; }
  .slider-arrow-btn.next { right: 4px; }
  
  .practice-card { flex-direction: column; height: auto; }
  
  .practice-img { width: 100%; height: 280px; border-right: none; border-bottom: 2px solid var(--primary-color); padding: 15px; }
  .practice-content { width: 100%; padding: 16px; }
  
  .sync-header { height: auto; min-height: 50px; }
  
  .sub-column-gap { gap: 12px !important; }
  .main-pricing-block { height: auto !important; min-height: 0 !important; }
  .sub-block-height { height: auto !important; min-height: 0 !important; }
  
  .map-container-snap { height: 300px; }
}

@media (max-height: 720px) and (min-width: 992px) {
  .expert-resume-card { padding: 10px; max-height: 38vh; font-size: 0.75rem; }
  .expert-name { font-size: 0.95rem; }
  .step-desc-box { padding: 10px; font-size: 0.8rem; }
  .hero-title { font-size: 1.4rem !important; }
  .compact-block { padding: 8px; }
}

@media (max-width: 767.98px) {
  .sticky-top-bar { padding: 0 12px; height: 54px; }
  .sticky-top-bar span.d-none.d-md-inline,
  .sticky-top-bar .header-phone { display: none !important; }
  .btn-header-call { font-size: 0.75rem; padding: 4px 10px; }
  .header-messenger-img { width: 20px; height: 20px; }
  .sticky-top-bar img.logo-img { height: 32px !important; }

  .hero-section { padding: 15px 0; }
  .hero-title { font-size: 1.2rem !important; text-align: center !important; }
  .hero-subtitle { font-size: 0.85rem !important; text-align: center !important; }

  .compact-block { padding: 10px; gap: 10px; box-shadow: 3px 3px 0 var(--cta-a); }
  .c-icon { width: 32px; height: 32px; }
  .c-title { font-size: 0.75rem; }
  .c-text { font-size: 0.7rem; }
  .c-desc { display: none; }

  .step-row { flex-wrap: wrap; justify-content: center; gap: 2px 6px; font-size: 0.75rem; }
  .step-item, .step-arrow { font-size: 0.75rem; }
  .step-desc-box { padding: 12px; font-size: 0.8rem; }
  .btn-start-online { padding: 14px 20px !important; font-size: 0.9rem !important; width: 100%; max-width: none; }
}
