/* =========================================================
   Визуальный слой v2: тёмный герой, свет, зерно, движение
   ========================================================= */

:root {
  --night: #07080b;
  --night-soft: #0d0f14;
  --night-line: rgba(255, 255, 255, 0.1);
  --glass: rgba(255, 255, 255, 0.045);
}

/* ---------- герой ---------- */
.hero-dark {
  position: relative;
  overflow: hidden;
  background: var(--night);
  color: #f5f5f7;
  padding: 104px 24px 96px;
  isolation: isolate;
}

.hero-dark .inner { max-width: var(--max); margin: 0 auto; position: relative; z-index: 2; }

/* световые пятна: размытие заложено в сам градиент — без filter: blur() */
.aurora {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  contain: paint;
}
.aurora span {
  position: absolute;
  display: block;
  width: 78vmax;
  height: 78vmax;
  border-radius: 50%;
  will-change: transform;
  backface-visibility: hidden;
}
.aurora .a1 {
  left: -26vmax; top: -34vmax;
  background: radial-gradient(circle at center,
    rgba(0, 113, 227, 0.5) 0%,
    rgba(0, 113, 227, 0.18) 32%,
    rgba(0, 113, 227, 0) 62%);
  animation: drift-a 28s ease-in-out infinite alternate;
}
.aurora .a2 {
  right: -28vmax; top: -30vmax;
  background: radial-gradient(circle at center,
    rgba(122, 92, 255, 0.42) 0%,
    rgba(122, 92, 255, 0.14) 34%,
    rgba(122, 92, 255, 0) 64%);
  animation: drift-b 34s ease-in-out infinite alternate;
}
.aurora .a3 {
  left: 18vmax; bottom: -52vmax;
  background: radial-gradient(circle at center,
    rgba(0, 200, 180, 0.28) 0%,
    rgba(0, 200, 180, 0.1) 34%,
    rgba(0, 200, 180, 0) 64%);
  animation: drift-c 40s ease-in-out infinite alternate;
}

@keyframes drift-a { from { transform: translate3d(0, 0, 0); } to { transform: translate3d(6vmax, 4vmax, 0); } }
@keyframes drift-b { from { transform: translate3d(0, 0, 0); } to { transform: translate3d(-5vmax, 3vmax, 0); } }
@keyframes drift-c { from { transform: translate3d(0, 0, 0); } to { transform: translate3d(4vmax, -3vmax, 0); } }

/* зерно: без blend-режимов, статичное */
.grain {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.16;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/><feColorMatrix type='saturate' values='0'/></filter><rect width='160' height='160' filter='url(%23n)' opacity='0.55'/></svg>");
  background-size: 160px 160px;
}

.hero-dark h1 { color: #fff; }
.hero-dark h1 .shine {
  background: linear-gradient(92deg, #7fb2ff 0%, #b9a5ff 45%, #6ee7d0 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-dark .lead { color: rgba(245, 245, 247, 0.72); }

.hero-dark .hero-form input[type="email"] {
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #fff;
}
.hero-dark .hero-form input[type="email"]::placeholder { color: rgba(255, 255, 255, 0.45); }
.hero-dark .hero-form input[type="email"]:focus {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(122, 176, 255, 0.8);
  box-shadow: 0 0 0 4px rgba(0, 113, 227, 0.25);
}
.hero-dark .fineprint { color: rgba(245, 245, 247, 0.5); }
.hero-dark .error { color: #ff8f8f; }

/* ---------- живая лента ---------- */
.feed {
  margin: 56px auto 0;
  max-width: 780px;
  border-radius: 22px;
  border: 1px solid var(--night-line);
  background: rgba(18, 21, 28, 0.72);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.07);
  overflow: hidden;
}
.feed-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--night-line);
  font-size: 12.5px;
  color: rgba(245, 245, 247, 0.55);
  letter-spacing: 0.02em;
}
.feed-live { display: flex; align-items: center; gap: 7px; }
.pulse {
  width: 7px; height: 7px; border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.7);
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.55); }
  70% { box-shadow: 0 0 0 9px rgba(74, 222, 128, 0); }
  100% { box-shadow: 0 0 0 0 rgba(74, 222, 128, 0); }
}

.feed-list { padding: 8px 8px 12px; display: grid; gap: 8px; min-height: 236px; }
.feed-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px 16px;
  align-items: center;
  padding: 13px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(255, 255, 255, 0.06);
  animation: feed-in 0.55s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}
.feed-item.is-new { border-color: rgba(110, 231, 208, 0.35); background: rgba(110, 231, 208, 0.06); }
@keyframes feed-in {
  from { opacity: 0; transform: translateY(10px) scale(0.985); }
  to { opacity: 1; transform: none; }
}
.feed-title { color: #fff; font-size: 14.5px; font-weight: 500; line-height: 1.35; }
.feed-meta { color: rgba(245, 245, 247, 0.5); font-size: 12.5px; margin-top: 3px; }
.feed-sum { color: #fff; font-size: 14px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.feed-tag {
  display: inline-block;
  font-size: 11px;
  padding: 3px 9px;
  border-radius: 999px;
  color: #9ee9d6;
  background: rgba(110, 231, 208, 0.12);
  white-space: nowrap;
}

/* ---------- бегущая строка площадок ---------- */
.marquee {
  position: relative;
  overflow: hidden;
  background: var(--night-soft);
  border-top: 1px solid var(--night-line);
  border-bottom: 1px solid var(--night-line);
  padding: 18px 0;
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee-track {
  display: flex;
  gap: 56px;
  width: max-content;
  animation: marquee 38s linear infinite;
}
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee-track span {
  color: rgba(245, 245, 247, 0.45);
  font-size: 14px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
}
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---------- появление при скролле ---------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.8s cubic-bezier(0.2, 0.7, 0.2, 1),
              transform 0.8s cubic-bezier(0.2, 0.7, 0.2, 1);
}
[data-reveal].is-visible { opacity: 1; transform: none; }
[data-reveal-delay="1"] { transition-delay: 0.1s; }
[data-reveal-delay="2"] { transition-delay: 0.2s; }
[data-reveal-delay="3"] { transition-delay: 0.3s; }

/* ---------- липкие шаги ---------- */
.sticky-steps { display: grid; grid-template-columns: 320px 1fr; gap: 64px; align-items: start; }
.sticky-side { position: sticky; top: 96px; }
.step-card {
  padding: 26px 0;
  border-top: 1px solid var(--line);
  opacity: 0.45;
  transition: opacity 0.4s ease;
}
.step-card:last-child { border-bottom: 1px solid var(--line); }
.step-card.is-active { opacity: 1; }
.step-card h3 { font-size: 24px; margin-bottom: 6px; }
.step-card p { color: var(--muted); font-size: 15.5px; }

/* ---------- честность: тёмная полоса ---------- */
.dark-band {
  background: var(--night);
  color: #f5f5f7;
  padding: 96px 24px;
  position: relative;
  overflow: hidden;
}
.dark-band .inner { max-width: var(--max); margin: 0 auto; position: relative; z-index: 2; }
.dark-band h2 { color: #fff; }
.dark-band .lead { color: rgba(245, 245, 247, 0.65); }
.dark-band .eyebrow { color: #7fb2ff; }
.dark-card {
  border: 1px solid var(--night-line);
  background: rgba(255, 255, 255, 0.04);
  border-radius: var(--radius);
  padding: 26px;
  backdrop-filter: blur(10px);
}
.dark-card h3 { color: #fff; }
.dark-card p { color: rgba(245, 245, 247, 0.62); font-size: 15.5px; }
.quote-mark { font-size: 40px; line-height: 1; color: #6ee7d0; margin-bottom: 8px; }

@media (max-width: 900px) {
  .sticky-steps { grid-template-columns: 1fr; gap: 24px; }
  .sticky-side { position: static; }
}

@media (max-width: 640px) {
  .hero-dark { padding: 64px 18px 64px; }
  .aurora { filter: blur(46px); }
  .feed { margin-top: 36px; }
  .feed-item { grid-template-columns: 1fr; }
  .marquee-track { gap: 36px; }
  .dark-band { padding: 64px 18px; }
}

@media (prefers-reduced-motion: reduce) {
  .aurora span, .marquee-track, .pulse, .feed-item { animation: none !important; }
  [data-reveal] { opacity: 1 !important; transform: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}


/* анимации останавливаются, когда герой вне экрана */
.anim-paused .aurora span,
.anim-paused .marquee-track,
.anim-paused .pulse { animation-play-state: paused; }

.marquee-track { will-change: transform; }


/* =========================================================
   Отделка: глубина и аккуратные детали (без дорогих эффектов)
   ========================================================= */

.hero-dark {
  background-image: radial-gradient(120% 90% at 50% -20%, #141a2e 0%, #0a0c12 55%, #07080b 100%);
}
.hero-dark::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 140px;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(7, 8, 11, 0) 0%, rgba(7, 8, 11, 0.85) 100%);
}

/* кнопки: объём без блюра */
.btn-primary {
  background-image: linear-gradient(180deg, #0a7cff 0%, #0068d6 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.28), 0 6px 18px rgba(0, 113, 227, 0.26);
  transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}
.btn-primary:hover {
  filter: none;
  transform: translateY(-1px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3), 0 10px 26px rgba(0, 113, 227, 0.32);
}
.btn-primary:active { transform: translateY(0); }

/* карточки: тонкая грань и мягкая тень вместо плоской рамки */
.card {
  border: 1px solid rgba(0, 0, 0, 0.07);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04), 0 14px 34px rgba(16, 24, 40, 0.05);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}
.card:hover {
  transform: translateY(-3px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05), 0 22px 48px rgba(16, 24, 40, 0.08);
}

/* секции: волосяная линия сверху для ритма */
.section-alt { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

/* номера шагов: градиентный текст */
.step-num {
  background: linear-gradient(180deg, rgba(0, 113, 227, 0.55), rgba(0, 113, 227, 0.12));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* лента: верхний блик вместо размытия */
.feed { position: relative; }
.feed::before {
  content: '';
  position: absolute;
  left: 12px; right: 12px; top: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.35), transparent);
}

/* источники: аккуратный ховер */
.source { transition: border-color 0.2s ease, transform 0.2s ease; }
.source:hover { border-color: rgba(0, 0, 0, 0.16); transform: translateY(-1px); }

/* заголовок: чуть плотнее */
h1 { font-feature-settings: 'ss01'; }
.lead { text-wrap: pretty; }


/* ---------- тарифы ---------- */
.pricing {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-top: 40px;
  align-items: stretch;
}
.price-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 28px 26px 30px;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 22px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04), 0 16px 40px rgba(16, 24, 40, 0.06);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}
.price-card:hover { transform: translateY(-3px); box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06), 0 26px 60px rgba(16, 24, 40, 0.1); }
.price-card h3 { font-size: 20px; }
.price-note { color: var(--muted); font-size: 13.5px; margin: 0; }
.price-value {
  font-size: 40px;
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1;
}
.price-value span { font-size: 15px; font-weight: 500; color: var(--muted); letter-spacing: 0; }
.price-list { list-style: none; margin: 6px 0 4px; padding: 0; display: grid; gap: 9px; }
.price-list li {
  position: relative;
  padding-left: 22px;
  font-size: 14.5px;
  color: var(--ink-soft);
}
.price-list li::before {
  content: '';
  position: absolute;
  left: 2px; top: 7px;
  width: 9px; height: 5px;
  border-left: 2px solid var(--brand);
  border-bottom: 2px solid var(--brand);
  transform: rotate(-45deg);
}
.price-card .btn { margin-top: auto; }

.price-card-popular {
  border-color: rgba(0, 113, 227, 0.35);
  box-shadow: 0 2px 6px rgba(0, 113, 227, 0.1), 0 24px 60px rgba(0, 113, 227, 0.14);
}
.badge-popular {
  position: absolute;
  top: -11px;
  left: 26px;
  background: linear-gradient(180deg, #0a7cff, #0068d6);
  color: #fff;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.02em;
  padding: 4px 12px;
  border-radius: 999px;
  box-shadow: 0 6px 16px rgba(0, 113, 227, 0.35);
}

@media (max-width: 900px) {
  .pricing { grid-template-columns: 1fr; }
  .price-card-popular { order: -1; }
}

/* ---------- согласие и юридические документы ---------- */
.consent {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  width: 100%;
  margin-top: 14px;
  font-size: 12.5px;
  line-height: 1.45;
  color: rgba(245, 245, 247, 0.55);
  text-align: left;
}
.consent input {
  appearance: none;
  -webkit-appearance: none;
  flex: 0 0 16px;
  width: 16px;
  height: 16px;
  margin: 1px 0 0;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.06);
  cursor: pointer;
  position: relative;
}
.consent input:checked { background: var(--brand); border-color: var(--brand); }
.consent input:checked::after {
  content: '';
  position: absolute;
  left: 4.5px; top: 1.5px;
  width: 4px; height: 8px;
  border-right: 2px solid #fff;
  border-bottom: 2px solid #fff;
  transform: rotate(40deg);
}
.consent a { color: rgba(255, 255, 255, 0.8); }
.consent a:hover { color: #fff; }

/* на светлых страницах контраст другой */
.cta .consent { color: var(--muted); justify-content: center; max-width: 420px; margin-left: auto; margin-right: auto; }
.cta .consent a { color: var(--brand); }
.cta .consent input { border-color: var(--line-strong); background: #fff; }

.legal { max-width: 760px; }
.legal h2 { font-size: 19px; margin: 32px 0 10px; letter-spacing: -0.01em; }
.legal p { color: var(--ink-soft); font-size: 15.5px; margin-bottom: 12px; }

/* ---------- баннер cookie ---------- */
.cookie {
  position: fixed;
  left: 24px;
  bottom: 24px;
  z-index: 80;
  max-width: 420px;
  display: flex;
  gap: 16px;
  align-items: center;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 18px 50px rgba(16, 24, 40, 0.16);
}
.cookie p { margin: 0; font-size: 13px; color: var(--muted); line-height: 1.45; }
.cookie .btn { flex: 0 0 auto; }
@media (max-width: 640px) {
  .cookie { left: 12px; right: 12px; bottom: 12px; max-width: none; flex-direction: column; align-items: stretch; }
  .cookie .btn { width: 100%; }
}



/* ---------- cookie: категории и кнопки ---------- */
.cookie { flex-direction: column; align-items: stretch; gap: 12px; max-width: 480px; }
.cookie h3 { font-size: 15px; margin: 0; }
.cookie p { font-size: 13px; color: var(--muted); line-height: 1.5; }
.cookie-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.cookie-panel { max-width: 420px; }
.cookie-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 10px 0;
  border-top: 1px solid var(--line);
  cursor: pointer;
}
.cookie-row b { display: block; font-size: 13.5px; font-weight: 600; }
.cookie-row small { display: block; color: var(--muted); font-size: 12px; line-height: 1.4; margin-top: 2px; }
.cookie-row input {
  appearance: none;
  -webkit-appearance: none;
  flex: 0 0 34px;
  width: 34px;
  height: 20px;
  border-radius: 999px;
  background: #d7dbe3;
  position: relative;
  cursor: pointer;
  transition: background 0.2s ease;
}
.cookie-row input::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
  transition: transform 0.2s ease;
}
.cookie-row input:checked { background: var(--brand); }
.cookie-row input:checked::after { transform: translateX(14px); }
.cookie-row input:disabled { opacity: 0.6; cursor: default; }
@media (max-width: 640px) {
  .cookie-actions .btn { width: 100%; }
}

/* атрибут hidden должен побеждать display:flex */
.cookie[hidden] { display: none !important; }


/* ---------- пагинация ---------- */
.pager {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 24px;
  flex-wrap: wrap;
}


/* ---------- плашка срока ---------- */
.tender-head {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 8px;
}
.tender-head h2 { margin: 0; flex: 1 1 auto; }
.deadline {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
  padding: 7px 12px;
  border-radius: 12px;
  background: rgba(29, 138, 74, 0.1);
  border: 1px solid rgba(29, 138, 74, 0.25);
  white-space: nowrap;
}
.deadline-date { font-size: 13px; font-weight: 600; color: #1d8a4a; }
.deadline-days { font-size: 11.5px; color: #1d8a4a; opacity: 0.85; }
.deadline-amber { background: rgba(214, 138, 0, 0.1); border-color: rgba(214, 138, 0, 0.3); }
.deadline-amber .deadline-date, .deadline-amber .deadline-days { color: #a96a00; }
.deadline-red { background: rgba(196, 43, 28, 0.1); border-color: rgba(196, 43, 28, 0.3); }
.deadline-red .deadline-date, .deadline-red .deadline-days { color: #b42318; }
.deadline-past { background: rgba(0, 0, 0, 0.05); border-color: var(--line); }
.deadline-past .deadline-date, .deadline-past .deadline-days { color: var(--muted); }
.deadline-unknown { background: rgba(0, 0, 0, 0.04); border-color: var(--line); color: var(--muted); font-size: 12.5px; }
@media (max-width: 640px) {
  .tender-head { flex-direction: column; gap: 10px; }
  .deadline { align-items: flex-start; }
}
