@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700&display=swap');

@font-face {
  font-family: 'Unbounded-Black';
  src: url('/fonts/Unbounded-Black.woff2') format('woff2');
  font-weight: 900;
  font-style: normal;
  font-display: swap;
}

/* ── Переменные ─────────────────────────────────── */
:root {
  --bg:      #ffffff;
  --accent:  #1f5cff;
  --accent2: #0a3ad4;
  --text:    #0a0a0a;
  --muted:   #555555;
  --border:  rgba(0,0,0,0.09);
  --max:     1160px;
  --pad:     clamp(20px, 5vw, 64px);
  --gap:     clamp(64px, 9vw, 110px);
}

/* ── Сброс ──────────────────────────────────────── */
*, *::before, *::after { margin:0; padding:0; box-sizing:border-box; }
html { scroll-behavior: smooth; }

body {
  font-family: 'Manrope', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}

/* ════════════════════════════════════════════════
   COOKIE BANNER — справа, не на всю ширину
   Десктоп: max 40% ширины, правый нижний угол
   Мобилка: компактный блок снизу справа
════════════════════════════════════════════════ */
.cookie-banner {
  position: fixed;
  bottom: 16px;
  right: 16px;
  left: auto;             /* убираем растяжку на всю ширину */
  width: min(40vw, 480px);
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(0,0,0,0.10);
  border-radius: 12px;
  padding: 14px 16px;
  font-size: 11.5px;
  color: var(--muted);
  z-index: 9999;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.10);
}
.cookie-banner span { line-height: 1.5; flex: 1; }
.cookie-banner button {
  flex-shrink: 0;
  background: var(--text);
  color: #fff;
  border: none;
  width: 26px; height: 26px;
  border-radius: 50%;
  font-size: 12px;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background .2s;
  margin-top: 1px;
}
.cookie-banner button:hover { background: var(--accent); }

/* ── Общий центратор ────────────────────────────── */
.hero,
.section,
.discuss-container,
.footer-content,
.footer-bottom {
  max-width: var(--max);
  margin-left: auto;
  margin-right: auto;
}

/* ════════════════════════════════════════════════
   HERO
════════════════════════════════════════════════ */
.hero {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  /* FIX 1: горизонтальный padding увеличен для мобилки */
  padding: clamp(80px, 12vh, 120px) clamp(24px, 6vw, 64px) clamp(40px, 8vh, 80px);
  position: relative;
  overflow: hidden;
}

/* Логотип — большой, синий, жирный */
.logo {
  font-family: 'Unbounded', sans-serif;
  font-size: clamp(48px, 10vw, 112px);
  font-weight: 900;
  letter-spacing: -2px;
  color: var(--accent);
  text-transform: uppercase;
  line-height: 1;
  position: relative;
  display: inline-block;
  transform: none;
  text-shadow: none;
  z-index: 1;
  /* Отступы от краев экрана */
  padding: 0 clamp(10px, 2.8vw, 14px);
  max-width: 100%;
  box-sizing: border-box;
}

.logo-mark {
  position: absolute;
  top: 0.02em;
  right: -0.44em;
  display: block;
  font-size: 0.28em;
  line-height: 1;
  margin: 0;
}

.logo-last {
  position: relative;
  display: inline-block;
}

/* Убираем псевдоэлемент из старого CSS */
.logo::after { display: none !important; }

/* FIX 3: подпись «агентство системного маркетинга» */
.logo-subtitle {
  margin-top: 16px;
  font-size: clamp(11px, 1.4vw, 13px);
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
  position: relative;
  z-index: 1;
  display: inline-block; /* нужно для позиционирования SVG-подчёркивания */
}

/* Контейнер для волнистой линии под subtitle (рисует JS) */
.subtitle-underline-wrap {
  display: block;
  width: 100%;
  height: 14px;
  margin-top: 4px;
  overflow: visible;
  pointer-events: none;
}

.hero-subtitle {
  margin-top: clamp(24px, 4vw, 44px);
  font-size: clamp(16px, 2vw, 21px);
  color: #333;
  max-width: 680px;
  line-height: 1.65;
  font-weight: 400;
  position: relative;
  z-index: 1;
}

/* Анимации для SVG-элементов */
.draw-ray {
  stroke-dasharray: 80;
  stroke-dashoffset: 80;
  animation: drawRay 0.45s cubic-bezier(.4,0,.2,1) forwards;
}
@keyframes drawRay {
  to { stroke-dashoffset: 0; }
}

/* ════════════════════════════════════════════════
   SECTIONS
════════════════════════════════════════════════ */
.section {
  padding: var(--gap) var(--pad);
  border-top: 1px solid var(--border);
}

.section-title {
  font-family: 'Unbounded', sans-serif;
  font-size: clamp(24px, 4vw, 48px);
  font-weight: 900;
  color: var(--text);
  text-align: left;
  margin-bottom: clamp(24px, 3.5vw, 44px);
  line-height: 1.05;
  letter-spacing: -1px;
  transform: none;
  position: relative;
}

.section-title::after {
  content: '';
  display: block;
  width: min(160px, 45%);
  height: 3px;
  margin-top: 10px;
  background: var(--accent);
  border-radius: 2px;
  opacity: .45;
}

.section-content {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: clamp(20px, 3vw, 44px);
  align-items: start;
}

.section-text {
  font-size: clamp(15px, 1.8vw, 17px);
  color: #222;
  line-height: 1.8;
  background: #f7f7f7;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: clamp(20px, 3vw, 30px);
}

/* ── Акцентная типографика ──────────────────────── */
.managed-text,
.understand-text,
.center-bold,
.result-text {
  font-family: 'Unbounded', sans-serif;
  color: var(--accent);
  font-weight: 700;
  display: block;
}
.managed-text   { font-size: clamp(14px, 1.8vw, 18px); margin-top: 18px; }
.understand-text{ font-size: clamp(13px, 1.6vw, 15px); margin-bottom: 6px; }
.center-bold    { font-size: clamp(14px, 1.8vw, 18px); margin-bottom: 14px; }
.result-text    { font-size: clamp(13px, 1.7vw, 16px); margin-top: 18px; }

/* ── Checkmark list ─────────────────────────────── */
.checkmark-list {
  list-style: none;
  margin-top: 12px;
  display: grid;
  gap: 8px;
}
.checkmark-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: #fff;
  border: 1.5px solid var(--border);
  border-radius: 6px;
  font-size: clamp(14px, 1.6vw, 16px);
  transition: border-color .2s;
}
.checkmark-list li:hover { border-color: rgba(31,92,255,.4); }
.checkmark-list li svg { width: 22px; height: 22px; flex-shrink: 0; }

/* ── Steps list ─────────────────────────────────── */
.steps-list {
  list-style: none;
  counter-reset: step;
  display: grid;
  gap: 8px;
}
.steps-list li {
  counter-increment: step;
  position: relative;
  padding: 13px 14px 13px 52px;
  background: #fff;
  border: 1.5px solid var(--border);
  border-radius: 6px;
  font-size: clamp(14px, 1.6vw, 16px);
  transition: border-color .2s;
}
.steps-list li:hover { border-color: rgba(31,92,255,.4); }
.steps-list li::before {
  content: counter(step);
  position: absolute;
  left: 13px; top: 50%;
  transform: translateY(-50%);
  width: 28px; height: 28px;
  background: var(--accent);
  color: #fff;
  font-family: 'Unbounded', sans-serif;
  font-size: 11px;
  font-weight: 700;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
}
.steps-list li:not(:last-child)::after { display: none; }

/* ════════════════════════════════════════════════
   DISCUSS / ФОРМА
════════════════════════════════════════════════ */
.discuss-section {
  padding: var(--gap) var(--pad);
  border-top: 1px solid var(--border);
  background: #f7f7f7;
}
.discuss-container { padding: 0; }

.discuss-question {
  font-family: 'Unbounded', sans-serif;
  font-size: clamp(18px, 2.8vw, 30px);
  font-weight: 900;
  color: var(--text);
  max-width: 820px;
  margin: 0 auto clamp(28px, 4vw, 44px);
  text-align: center;
  line-height: 1.2;
  letter-spacing: -.5px;
  transform: none;
}

.discuss-form {
  max-width: 500px;
  margin: 0 auto;
  background: #fff;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: clamp(24px, 4vw, 36px);
  box-shadow: 0 16px 48px rgba(0,0,0,.06);
}

.form-group { margin-bottom: 12px; }

.form-input {
  width: 100%;
  padding: 14px 16px;
  background: #fff;
  border: 1.5px solid rgba(0,0,0,.12);
  border-radius: 6px;
  color: var(--text);
  font-size: 15px;
  font-family: 'Manrope', sans-serif;
  transition: border-color .2s, box-shadow .2s;
}
.form-input::placeholder { color: #bbb; }
.form-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(31,92,255,.12);
}

.submit-btn {
  width: 100%;
  padding: 15px 24px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 50px;
  font-size: 15px;
  font-family: 'Manrope', sans-serif;
  font-weight: 700;
  letter-spacing: .04em;
  cursor: pointer;
  margin-top: 8px;
  transition: background .2s, transform .1s, box-shadow .2s;
}
.submit-btn:hover {
  background: var(--accent2);
  box-shadow: 0 8px 28px rgba(31,92,255,.3);
}
.submit-btn:active { transform: scale(.985); }
.submit-btn.inactive { opacity: .42; cursor: not-allowed; }

.consent {
  margin-top: 16px;
  font-size: 12px;
  color: var(--muted);
  line-height: 1.6;
}
.consent br { display: none; }
.consent label {
  display: block;
  position: relative;
  padding-left: 30px;
  cursor: pointer;
}
.consent label:not(:first-of-type) { margin-top: 12px; }
.consent input[type="checkbox"] {
  position: absolute;
  top: 2px;
  left: 0;
  margin-top: 0;
  flex-shrink: 0;
  accent-color: var(--accent);
}
.consent a {
  display: inline;
  color: var(--accent);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
  word-break: break-word;
}
.consent-error {
  color: #c00;
  margin-top: 10px;
  display: none;
  font-size: 12px;
  font-weight: 600;
}

/* ════════════════════════════════════════════════
   FOOTER
════════════════════════════════════════════════ */
footer {
  background: var(--bg);
  border-top: 1px solid var(--border);
  padding: clamp(40px, 6vw, 72px) var(--pad);
}

.footer-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(24px, 4vw, 48px);
  align-items: start;
}

.footer-brand {
  font-family: 'Unbounded', sans-serif;
  font-size: clamp(18px, 2.4vw, 26px);
  font-weight: 900;
  color: var(--text);
  letter-spacing: -1px;
  text-transform: uppercase;
  display: block;
  margin-bottom: 6px;
}
.footer-brand::after {
  content: '';
  display: block;
  width: 70%;
  height: 3px;
  margin-top: 8px;
  background: var(--accent);
  border-radius: 2px;
  opacity: .4;
}

.footer-info { font-size: 13px; line-height: 2; color: var(--muted); margin-top: 4px; }
.footer-info p { color: var(--muted); }
.footer-info a { color: var(--accent); text-decoration: none; border-bottom: 1px solid rgba(31,92,255,.25); }
.footer-info a:hover { border-bottom-color: var(--accent); }

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: flex-start;
  padding-top: 4px;
}
.footer-links a {
  font-size: 13px;
  color: var(--muted);
  text-decoration: none;
  border-bottom: 1px solid rgba(0,0,0,.12);
  transition: color .2s, border-color .2s;
}
.footer-links a:hover { color: var(--accent); border-bottom-color: var(--accent); }

.footer-bottom {
  margin-top: 36px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  text-align: center;
  font-size: 13px;
  color: #aaa;
}

/* ════════════════════════════════════════════════
   АДАПТИВ
════════════════════════════════════════════════ */
@media (max-width: 980px) {
  .section-content { grid-template-columns: 1fr; }
  .section-title { text-align: left; }

  /* Мобильная/планшетная правка блока согласий в форме */
  .discuss-form {
    padding: 20px 16px;
  }
  .consent {
    font-size: 13px;
    line-height: 1.5;
  }
}

/* FIX 2: Cookie мобилка — не более 80vw, правый угол */
@media (max-width: 640px) {
  .hero {
    padding-left: 16px;
    padding-right: 16px;
  }

  .cookie-banner {
    width: min(80vw, 340px);
    bottom: 10px;
    right: 10px;
    font-size: 11px;
    padding: 12px 14px;
  }
  .footer-content { grid-template-columns: 1fr; }

  /* FIX 1: логотип не вплотную к краям */
  .logo {
    font-size: clamp(34px, 11vw, 56px);
    letter-spacing: -0.8px;
    padding: 0 10px;
  }

  .logo-mark {
    top: 0.01em;
    right: -0.40em;
    font-size: 0.26em;
  }

}

/* ── Scroll-reveal ──────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .6s cubic-bezier(.22,1,.36,1),
              transform .6s cubic-bezier(.22,1,.36,1);
}
.reveal.visible { opacity: 1; transform: none; }
