/* ==========================================================================
   StrelFlow — визуальная система основного лендинга strelflow.ru
   Одноэкранный лид-магнит: весь контент помещается в один экран
   ========================================================================== */

:root {
  /* Палитра */
  --ink: #0a0a0b;
  --coal: #101011;
  --panel: #16161a;
  --float: #1d1d22;
  --line: #26262b;
  --chalk: #f4f2ec;
  --ash: #9a988f;
  --acid: #c9f23a;
  --acid-soft: #d9f77a;
  --danger: #ef6a6a;
  --danger-soft: #ef8a8a;

  /* Типографика */
  --font-display: "Bricolage Grotesque", "Manrope", system-ui, sans-serif;
  --font-sans: "Manrope", system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, monospace;

  --ease-spring: cubic-bezier(0.16, 1, 0.3, 1);
  --content: 1200px;
  --gutter: clamp(20px, 4vw, 40px);
}

*,
*::before,
*::after {
  box-sizing: border-box;
  -webkit-font-smoothing: antialiased;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--chalk);
  font-size: 16px;
  line-height: 1.55;
  background:
    radial-gradient(60rem 40rem at 85% -10%, rgba(201, 242, 58, 0.1), transparent 60%),
    radial-gradient(48rem 38rem at -5% 12%, rgba(201, 242, 58, 0.05), transparent 55%),
    radial-gradient(70rem 50rem at 50% 120%, rgba(201, 242, 58, 0.06), transparent 60%),
    var(--ink);
  background-attachment: fixed;
}

::selection {
  background: var(--acid);
  color: var(--ink);
}

/* Плёночное зерно поверх всего */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 100;
  pointer-events: none;
  opacity: 0.05;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* --------------------------------------------------------------------------
   Примитивы
   -------------------------------------------------------------------------- */

.display {
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.03;
  margin: 0;
}

.acid {
  color: var(--acid);
}

.mono-label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ash);
}

.mono-label--acid {
  color: var(--acid);
}

.elev-1 {
  background: linear-gradient(180deg, #16161a 0%, #121215 100%);
  border: 1px solid var(--line);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.03) inset,
    0 24px 50px -24px rgba(0, 0, 0, 0.8);
}

.elev-2 {
  background: linear-gradient(180deg, #1d1d22 0%, #161619 100%);
  border: 1px solid #2e2e34;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.05) inset,
    0 30px 70px -30px rgba(0, 0, 0, 0.9),
    0 0 0 1px rgba(201, 242, 58, 0.04);
}

/* --------------------------------------------------------------------------
   Кнопки
   -------------------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  border-radius: 12px;
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
}

.btn__inner {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn--acid {
  background: linear-gradient(165deg, #d6f658 0%, #c2ec33 100%);
  color: var(--ink);
  box-shadow:
    0 12px 30px -10px rgba(201, 242, 58, 0.5),
    0 1px 0 rgba(255, 255, 255, 0.5) inset;
  transition:
    transform 0.35s var(--ease-spring),
    box-shadow 0.35s var(--ease-spring),
    filter 0.2s ease;
}

.btn--acid:hover {
  transform: translateY(-3px);
  filter: brightness(1.04);
  box-shadow:
    0 20px 44px -12px rgba(201, 242, 58, 0.65),
    0 1px 0 rgba(255, 255, 255, 0.6) inset;
}

.btn--acid:active {
  transform: translateY(-1px) scale(0.99);
}

.btn--acid:focus-visible {
  outline: 2px solid var(--acid-soft);
  outline-offset: 4px;
}

.btn--acid:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.btn--ghost {
  background: transparent;
  color: var(--chalk);
  border: 1px solid var(--line);
  transition:
    transform 0.35s var(--ease-spring),
    border-color 0.25s ease,
    background 0.25s ease;
}

.btn--ghost:hover {
  transform: translateY(-3px);
  border-color: var(--acid);
  background: rgba(201, 242, 58, 0.06);
}

.btn--ghost:focus-visible {
  outline: 2px solid var(--acid);
  outline-offset: 4px;
}

.btn--lg {
  padding: 15px 28px;
  font-size: 15px;
}

.btn--block {
  width: 100%;
}

/* --------------------------------------------------------------------------
   Экран
   -------------------------------------------------------------------------- */

.hero {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  opacity: 0;
  transform: translateY(18px);
  animation: rise 0.7s var(--ease-spring) 0.05s forwards;
}

@keyframes rise {
  to {
    opacity: 1;
    transform: none;
  }
}

.hero__inner {
  width: 100%;
  max-width: var(--content);
  margin: 0 auto;
  padding: clamp(24px, 4vh, 40px) var(--gutter);
}

.hero__brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: clamp(20px, 4vh, 44px);
}

.brand__mark {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 9px;
  background: var(--acid);
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 16px;
  line-height: 1;
}

.brand__name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: -0.02em;
}

.hero__grid {
  display: grid;
  gap: clamp(24px, 4vh, 44px);
  align-items: center;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border-radius: 99px;
  border: 1px solid var(--line);
  background: rgba(16, 16, 17, 0.6);
  padding: 7px 15px;
  color: var(--acid);
}

.badge__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--acid);
  flex: none;
}

.hero__title {
  margin-top: clamp(16px, 2.6vh, 26px);
  font-size: clamp(2rem, 3.9vw, 3.6rem);
  max-width: 17ch;
}

.hero__text {
  margin: clamp(14px, 2.4vh, 24px) 0 0;
  color: var(--ash);
  line-height: 1.65;
  font-size: clamp(14px, 1.05vw, 16px);
  max-width: 56ch;
}

.hero__result {
  margin: clamp(12px, 1.8vh, 18px) 0 0;
  color: var(--ash);
  line-height: 1.65;
  font-size: clamp(14px, 1.05vw, 16px);
  max-width: 56ch;
}

.hero__result strong {
  color: var(--chalk);
  font-weight: 700;
}

.hero__cta {
  margin-top: clamp(20px, 3.4vh, 34px);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
}

.hero__note {
  margin: 0;
  font-size: 13px;
  color: var(--ash);
  line-height: 1.55;
  max-width: 28ch;
}

/* Карточка чек-листа */
.checks {
  border-radius: 22px;
  padding: clamp(20px, 2.6vw, 30px);
}

.checks__head {
  padding-bottom: clamp(14px, 2vh, 20px);
  margin-bottom: clamp(14px, 2vh, 20px);
  border-bottom: 1px solid var(--line);
}

.checks__title {
  margin: 10px 0 0;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.15;
  font-size: clamp(1.15rem, 1.7vw, 1.5rem);
}

.checks__list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: clamp(12px, 2vh, 18px);
}

.checks__item {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 14px;
  align-items: start;
}

.checks__num {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--acid);
  background: rgba(201, 242, 58, 0.1);
  border-radius: 8px;
  padding: 5px 8px;
  line-height: 1;
}

.checks__name {
  margin: 0 0 3px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(14px, 1.1vw, 16px);
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.checks__text {
  margin: 0;
  font-size: clamp(13px, 1vw, 14.5px);
  color: var(--ash);
  line-height: 1.5;
}

/* --------------------------------------------------------------------------
   Модалка
   -------------------------------------------------------------------------- */

#leadModal {
  position: fixed;
  inset: 0;
  z-index: 110;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition:
    opacity 0.28s ease,
    visibility 0.28s;
}

#leadModal.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10, 10, 11, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.modal__scroll {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 20px;
  overflow-y: auto;
}

.modal__card {
  position: relative;
  width: 100%;
  max-width: 440px;
  border-radius: 24px;
  padding: clamp(24px, 3vw, 32px);
  margin: auto;
  transform: translateY(16px) scale(0.98);
  transition: transform 0.45s var(--ease-spring);
}

#leadModal.is-open .modal__card {
  transform: none;
}

.modal__close {
  position: absolute;
  top: 18px;
  right: 18px;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--ash);
  cursor: pointer;
  transition:
    color 0.2s ease,
    background 0.2s ease;
}

.modal__close:hover {
  color: var(--chalk);
  background: var(--float);
}

.modal__close:focus-visible {
  outline: 2px solid var(--acid);
  outline-offset: 2px;
}

.modal__title {
  margin: 12px 0 0;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.4rem, 3vw, 1.75rem);
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.modal__text {
  margin: 10px 0 0;
  font-size: 14.5px;
  color: var(--ash);
  line-height: 1.6;
}

/* --------------------------------------------------------------------------
   Форма
   -------------------------------------------------------------------------- */

.form {
  margin-top: 26px;
  display: grid;
  gap: 18px;
}

.field-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #c9c7bf;
  margin-bottom: 8px;
}

.field-input {
  width: 100%;
  background: #0e0e10;
  border: 1px solid #2a2a30;
  border-radius: 14px;
  padding: 13px 16px;
  color: var(--chalk);
  font-family: inherit;
  font-size: 16px;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.field-input::placeholder {
  color: #5b5b55;
}

.field-input:focus {
  outline: none;
  border-color: var(--acid);
  box-shadow: 0 0 0 3px rgba(201, 242, 58, 0.16);
}

.field-input.input-error {
  border-color: var(--danger);
  box-shadow: 0 0 0 3px rgba(239, 106, 106, 0.14);
}

.field-err {
  font-size: 12.5px;
  color: var(--danger-soft);
  margin: 7px 0 0;
}

.field-err--center {
  text-align: center;
}

.consents {
  display: grid;
  gap: 11px;
}

.consent-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.consent-box {
  position: relative;
  flex: 0 0 auto;
  width: 20px;
  height: 20px;
  margin-top: 1px;
  appearance: none;
  -webkit-appearance: none;
  background: #0e0e10;
  border: 1px solid #2a2a30;
  border-radius: 6px;
  cursor: pointer;
  transition:
    border-color 0.2s ease,
    background 0.2s ease,
    box-shadow 0.2s ease;
}

.consent-box:hover {
  border-color: #4a4a52;
}

.consent-box:focus-visible {
  outline: none;
  border-color: var(--acid);
  box-shadow: 0 0 0 3px rgba(201, 242, 58, 0.18);
}

.consent-box:checked {
  background: var(--acid);
  border-color: var(--acid);
}

.consent-box:checked::after {
  content: "";
  position: absolute;
  left: 6px;
  top: 2.5px;
  width: 5px;
  height: 9px;
  border: solid var(--ink);
  border-width: 0 2.4px 2.4px 0;
  transform: rotate(43deg);
}

.consent-box.input-error {
  border-color: var(--danger);
  box-shadow: 0 0 0 3px rgba(239, 106, 106, 0.14);
}

.consent-text {
  font-size: 12.5px;
  color: var(--ash);
  line-height: 1.55;
  cursor: pointer;
}

.link-acid {
  color: var(--acid);
  text-decoration: underline;
  text-underline-offset: 2px;
  text-decoration-color: rgba(201, 242, 58, 0.4);
  transition: text-decoration-color 0.2s ease;
}

.link-acid:hover {
  text-decoration-color: var(--acid);
}

.link-acid:focus-visible {
  outline: 2px solid var(--acid);
  outline-offset: 2px;
  border-radius: 2px;
}

.form__success {
  text-align: center;
  padding: 16px 0;
}

.form__success-icon {
  margin: 0 auto 22px;
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  border-radius: 18px;
  background: rgba(201, 242, 58, 0.12);
  color: var(--acid);
}

.form__success-title {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.5rem;
  letter-spacing: -0.03em;
  line-height: 1.2;
}

.form__success-text {
  margin: 12px 0 0;
  font-size: 15px;
  color: var(--ash);
  line-height: 1.65;
}

.spinner {
  animation: spin 0.9s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* --------------------------------------------------------------------------
   Адаптив
   -------------------------------------------------------------------------- */

@media (min-width: 900px) {
  .hero__grid {
    grid-template-columns: minmax(0, 1.15fr) minmax(320px, 0.85fr);
    gap: clamp(32px, 4vw, 64px);
  }

  .hero__title {
    max-width: 15ch;
  }
}

/* Невысокие ноутбуки — ужимаем вертикальный ритм */
@media (min-width: 900px) and (max-height: 780px) {
  .hero__title {
    font-size: clamp(1.9rem, 3.2vw, 2.9rem);
  }

  .checks {
    padding: 22px;
  }
}

/* Мобильные: всё в одну колонку и максимально компактно */
@media (max-width: 899px) {
  .hero__inner {
    padding-block: 20px;
  }

  .hero__brand {
    margin-bottom: 18px;
  }

  .hero__title {
    font-size: clamp(1.6rem, 7.2vw, 2.3rem);
    max-width: none;
  }

  .hero__text,
  .hero__result {
    font-size: 14px;
    max-width: none;
  }

  .hero__cta {
    gap: 12px;
  }

  .hero__note {
    max-width: none;
    font-size: 12.5px;
  }

  .hero__result {
    font-size: 13.5px;
  }

  .checks {
    border-radius: 18px;
    padding: 16px;
  }

  .checks__head {
    padding-bottom: 12px;
    margin-bottom: 12px;
  }

  .checks__title {
    margin-top: 8px;
    font-size: 1.05rem;
  }

  .checks__list {
    gap: 10px;
  }

  .checks__num {
    padding: 4px 7px;
    font-size: 11px;
  }

  .checks__text {
    font-size: 12.5px;
    line-height: 1.4;
  }

  .btn--lg {
    width: 100%;
    padding: 15px 22px;
  }
}

/* Невысокий десктоп — убираем необязательные пояснения */
@media (min-width: 900px) and (max-height: 680px) {
  .opt {
    display: none;
  }

  .checks {
    padding: 18px;
  }

  .checks__list {
    gap: 12px;
  }
}

/* Мобильный экран пониже — убираем необязательные части абзацев */
@media (max-width: 899px) and (max-height: 880px) {
  .opt {
    display: none;
  }
}

/* Экран ещё ниже — вводный абзац целиком не нужен */
@media (max-width: 899px) and (max-height: 780px) {
  .hero__text {
    display: none;
  }
}

/* Совсем низкие экраны — чек-лист в одну строку на пункт */
@media (max-width: 899px) and (max-height: 700px) {
  .hero__title {
    font-size: clamp(1.45rem, 6vw, 1.8rem);
  }

  .hero__brand {
    margin-bottom: 14px;
  }

  .checks__item {
    align-items: center;
  }

  .checks__text {
    display: none;
  }

  .checks__name {
    margin-bottom: 0;
  }
}

/* Телефон в альбомной ориентации — раскладываем в две колонки */
@media (max-width: 899px) and (min-width: 640px) and (orientation: landscape) {
  .hero__grid {
    grid-template-columns: minmax(0, 1.1fr) minmax(260px, 0.9fr);
    gap: 28px;
  }

  .hero__brand {
    margin-bottom: 12px;
  }

  .btn--lg {
    width: auto;
  }
}

/* Предельно низкие экраны — оставляем только суть */
@media (max-width: 899px) and (max-height: 640px) {
  .hero__inner {
    padding-block: 14px;
  }

  .hero__brand {
    display: none;
  }

  .hero__grid {
    gap: 16px;
  }

  .checks__head {
    padding-bottom: 10px;
    margin-bottom: 10px;
  }

  .checks__title {
    font-size: 0.98rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero {
    opacity: 1;
    transform: none;
    animation: none;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}
