/* =========================================================================
   PREMIUM — глубокий сапфир, янтарная медь, слоновая кость.
   Без «паутинки» и Диги: вместо них медленный объёмный свет за страницей.
   ========================================================================= */
:root {
  --ink-0: #04060c;
  --ink-1: #06080f;
  --ink-2: #0b0e18;
  --sapphire: #2443f0;
  --sapphire-deep: #1a32c8;
  --sapphire-hi: #7088ff;
  --sapphire-glow: #3b5bff;
  --amber: #ea6a25;
  --ivory: #f4f2ed;
  --blue: var(--sapphire);
  --blue-hi: var(--sapphire-hi);
  --orange: var(--amber);
  --cloud: var(--ivory);
}

body.flow, html { background: var(--ink-1) !important; }

/* ---- Атмосфера: два крупных пятна света, плывут со скроллом ---------------- */
.flow-layers::before,
.flow-layers::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  will-change: transform;
  transition: transform 1.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.flow-layers::before {
  width: 95vmax; height: 95vmax;
  right: -38vmax; top: -42vmax;
  background: radial-gradient(circle at 50% 50%, rgba(36, 67, 240, 0.30) 0%, rgba(26, 50, 200, 0.12) 34%, transparent 62%);
  transform: translate3d(calc(var(--drift, 0) * -18vw), calc(var(--drift, 0) * 22vh), 0);
}
.flow-layers::after {
  width: 80vmax; height: 80vmax;
  left: -40vmax; bottom: -46vmax;
  background: radial-gradient(circle at 50% 50%, rgba(234, 106, 37, 0.13) 0%, rgba(120, 60, 160, 0.06) 38%, transparent 64%);
  transform: translate3d(calc(var(--drift, 0) * 14vw), calc(var(--drift, 0) * -16vh), 0);
}
/* мягкий виньет и тонкое зерно — убирают «плоскость» экрана */
.flow-layers > .premium-grain {
  pointer-events: none;
  background:
    radial-gradient(120% 80% at 50% 40%, transparent 55%, rgba(2, 3, 8, 0.55) 100%),
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 .035 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  opacity: 1;
}

/* ---- Навигация: стекло ------------------------------------------------- */
body.flow .nav {
  background: rgba(6, 8, 15, 0.62) !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
  backdrop-filter: blur(22px) saturate(160%) !important;
  -webkit-backdrop-filter: blur(22px) saturate(160%) !important;
  box-shadow: 0 10px 40px -20px rgba(0, 0, 0, 0.8), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

/* ---- Кнопки: сапфир с бликом ------------------------------------------- */
body.flow .btn.primary, body.flow .pill.primary, body.flow .btn.wine, body.flow .dialog-cta,
body.flow #products .price-folder .folder-content a {
  background: linear-gradient(180deg, #3d5cff 0%, var(--sapphire) 48%, var(--sapphire-deep) 100%) !important;
  border-color: rgba(140, 160, 255, 0.45) !important;
  color: #fff !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.28),
    0 1px 2px rgba(0, 0, 0, 0.4),
    0 14px 34px -14px rgba(36, 67, 240, 0.85) !important;
  position: relative;
  overflow: hidden;
}
body.flow .btn.primary::after, body.flow .pill.primary::after, body.flow .btn.wine::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, 0.28) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
}
body.flow .btn.primary:hover::after, body.flow .pill.primary:hover::after, body.flow .btn.wine:hover::after { transform: translateX(120%); }
body.flow .btn.primary:hover, body.flow .pill.primary:hover, body.flow .btn.wine:hover {
  background: linear-gradient(180deg, #4a68ff 0%, #2c4cf6 48%, #1d36d2 100%) !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.32), 0 18px 44px -14px rgba(36, 67, 240, 1) !important;
}
body.flow .btn:not(.primary):not(.wine) {
  background: rgba(255, 255, 255, 0.03) !important;
  border-color: rgba(244, 242, 237, 0.22) !important;
  backdrop-filter: blur(10px);
}
body.flow .btn:not(.primary):not(.wine):hover { background: rgba(255, 255, 255, 0.07) !important; }

/* ---- Заголовки: глубокий сапфировый градиент с переливом ---------------- */
.flow-hero h1 .outline,
body.flow .cta h2 span {
  background: linear-gradient(100deg, #2443f0 0%, #6f86ff 28%, #c3ccff 46%, #6f86ff 62%, #2443f0 100%) !important;
  background-size: 220% 100% !important;
  -webkit-background-clip: text !important; background-clip: text !important;
  color: transparent !important; -webkit-text-fill-color: transparent !important;
  animation: premiumSheen 9s ease-in-out infinite;
}
@keyframes premiumSheen { 0%, 100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }
.flow-head h2 em, .flow-card h3 span { color: var(--sapphire-hi) !important; -webkit-text-fill-color: var(--sapphire-hi) !important; }

/* маркеры: янтарь вместо оранжевого */
body.flow section .section-head .eyebrow::before, .flow-eyebrow i,
.flow-card-index::before { background: var(--amber) !important; }
.flow-hero .eyebrow::before { background: var(--amber) !important; box-shadow: 0 0 14px rgba(234, 106, 37, 0.8) !important; }

/* ---- Тёмные карточки: стекло с тонкой подсветкой ------------------------ */
.flow-card {
  background: linear-gradient(160deg, rgba(20, 26, 48, 0.88), rgba(9, 12, 22, 0.92)) !important;
  border: 1px solid rgba(112, 136, 255, 0.16) !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05), 0 30px 80px -40px rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(14px);
}
.flow-card::before { background: linear-gradient(135deg, rgba(112, 136, 255, 0.9), transparent 40%, transparent 70%, rgba(234, 106, 37, 0.55)) !important; }
.flow-card-index { background: rgba(36, 67, 240, 0.14) !important; border-color: rgba(112, 136, 255, 0.35) !important; }
.flow-card-num { background: linear-gradient(180deg, #7088ff, rgba(36, 67, 240, 0) 90%) !important; -webkit-background-clip: text !important; background-clip: text !important; }

/* ---- Светлые блоки: слоновая кость вместо холодного белого --------------- */
body.flow #products, body.flow #faq {
  background:
    radial-gradient(90% 60% at 85% 0%, rgba(36, 67, 240, 0.06), transparent 60%),
    linear-gradient(180deg, #f6f4ef 0%, #f1eee7 100%) !important;
  box-shadow: 0 -30px 80px -40px rgba(0, 0, 0, 0.6), 0 30px 80px -40px rgba(0, 0, 0, 0.6);
}
body.flow #products .price-folder,
body.flow #faq .faq-item {
  background: #fffefb !important;
  border-color: #e7e2d8 !important;
  box-shadow: 0 1px 2px rgba(20, 16, 8, 0.04), 0 16px 36px -24px rgba(20, 16, 8, 0.18) !important;
}
body.flow #products .price-folder:hover, body.flow #products .price-folder[open],
body.flow #faq .faq-item[open] { border-color: rgba(36, 67, 240, 0.45) !important; }
body.flow #products .price-folder .folder-content article { background: #f7f5f0 !important; border-color: #ebe6dc !important; }
body.flow #products .price-folder .folder-number { background: rgba(36, 67, 240, 0.08) !important; }

/* ---- Портфолио: глубина и мягкое свечение ------------------------------- */
.case-cover { border-color: rgba(112, 136, 255, 0.18) !important; box-shadow: 0 40px 90px -50px rgba(0, 0, 0, 0.9), inset 0 1px 0 rgba(255, 255, 255, 0.04); }
.case-tile:hover .case-cover { border-color: rgba(112, 136, 255, 0.45) !important; }
.case-payment .case-cover { background: radial-gradient(120% 90% at 30% 10%, #3a58ff 0%, #1a32c8 55%, #0d1a78 100%) !important; }

@media (prefers-reduced-motion: reduce) {
  .flow-hero h1 .outline, body.flow .cta h2 span { animation: none; }
  .flow-layers::before, .flow-layers::after { transition: none; }
}

/* =========================================================================
   v2 — ртутная лента, плавный скролл и второй акцент: янтарный оранжевый
   ========================================================================= */
html.lenis, html.lenis body { scroll-behavior: auto !important; }
.flow-layers > .mercury-layer { width: 100% !important; height: 100% !important; }

/* ---- Hero: «БЫСТРО» — сапфир, «ДОЛГО» — янтарь ---------------------------- */
.flow-hero h1 .outline:last-of-type {
  background: linear-gradient(100deg, #c94a0e 0%, #ff8a3d 26%, #ffd2a8 46%, #ff8a3d 62%, #c94a0e 100%) !important;
  background-size: 220% 100% !important;
  -webkit-background-clip: text !important; background-clip: text !important;
  animation-delay: -4.5s;
}
/* «ЗА ПРОБЛЕМУ» — переход из сапфира в янтарь, как в ленте */
body.flow .cta h2 span {
  background: linear-gradient(100deg, #2443f0 0%, #7088ff 30%, #e9ecff 48%, #ff8a3d 66%, #ea6a25 100%) !important;
  background-size: 220% 100% !important;
  -webkit-background-clip: text !important; background-clip: text !important;
}

/* ---- Стоимость: раскрытая папка горит янтарём ---------------------------- */
body.flow #products .price-folder { position: relative; transition: border-color .4s, box-shadow .5s, transform .5s cubic-bezier(.16,1,.3,1) !important; }
body.flow #products .price-folder::before {
  background: linear-gradient(180deg, #ff8a3d, #ea6a25 55%, #2443f0) !important;
  width: 4px !important;
}
body.flow #products .price-folder:hover { border-color: rgba(234, 106, 37, 0.45) !important; transform: translateY(-2px); }
body.flow #products .price-folder[open] {
  border-color: rgba(234, 106, 37, 0.7) !important;
  box-shadow: 0 0 0 4px rgba(234, 106, 37, 0.08), 0 26px 50px -28px rgba(234, 106, 37, 0.45) !important;
}
body.flow #products .price-folder .folder-plus { color: var(--amber) !important; transition: transform .45s cubic-bezier(.16,1,.3,1), color .3s !important; }
body.flow #products .price-folder .folder-number {
  color: #c2410c !important; background: rgba(234, 106, 37, 0.10) !important;
}
body.flow #products .price-folder[open] .folder-number { color: #fff !important; background: linear-gradient(135deg, #ff8a3d, #ea6a25) !important; }
body.flow #products .price-folder[open] .folder-price { color: #d4560f !important; }
body.flow #products .price-folder .folder-content article {
  position: relative; overflow: hidden;
  transition: border-color .35s, transform .45s cubic-bezier(.16,1,.3,1), box-shadow .45s !important;
}
body.flow #products .price-folder .folder-content article::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px;
  background: linear-gradient(90deg, #ea6a25, #ff9a55 40%, #2443f0);
}
body.flow #products .price-folder .folder-content article:hover {
  border-color: rgba(234, 106, 37, 0.45) !important; transform: translateY(-3px);
  box-shadow: 0 22px 40px -26px rgba(234, 106, 37, 0.5);
}
body.flow #products .price-folder .folder-content strong { color: #d4560f !important; }
body.flow #products .price-folder .folder-content article > span { color: #2443f0 !important; font-weight: 600; }
body.flow #products .price-folder[open] .folder-content { animation: folderIn .7s cubic-bezier(.16,1,.3,1) both; }
@keyframes folderIn { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }

/* ---- FAQ: янтарный плюс и подсветка открытого ---------------------------- */
body.flow #faq .faq-item summary span { color: var(--amber) !important; transition: transform .45s cubic-bezier(.16,1,.3,1) !important; }
body.flow #faq .faq-item[open] { border-color: rgba(234, 106, 37, 0.6) !important; box-shadow: 0 0 0 4px rgba(234, 106, 37, 0.07) !important; }
body.flow #faq .faq-item:before { background: var(--amber) !important; }

/* ---- Остальные акценты: подписи проектов, роли, номера этапов ---------------- */
body.flow .project-card-caption > span { color: #ff8a3d !important; }
.member span, body.flow .member span { color: #ff8a3d !important; }
.founder-label { color: #ff8a3d !important; }
.flow-card-num {
  background: linear-gradient(180deg, #7088ff 0%, #ea6a25 55%, rgba(234, 106, 37, 0) 95%) !important;
  -webkit-background-clip: text !important; background-clip: text !important;
}
.flow-card-index { border-color: rgba(234, 106, 37, 0.4) !important; background: linear-gradient(90deg, rgba(36, 67, 240, 0.18), rgba(234, 106, 37, 0.14)) !important; }
.flow-card:hover { border-color: rgba(234, 106, 37, 0.35) !important; }
body.flow .btn:not(.primary):not(.wine):hover { border-color: rgba(255, 138, 61, 0.7) !important; }
.open-project { transition: background .35s, border-color .35s !important; }
.case-tile:hover .open-project { background: linear-gradient(135deg, #ff8a3d, #ea6a25) !important; border-color: transparent !important; color: #fff !important; }
.instagram-feature:hover .ig-arrow { color: #ff8a3d; }

/* тонкая ртутная полоска под надписями разделов */
body.flow section .section-head .eyebrow::before, .flow-eyebrow i {
  background: linear-gradient(90deg, #2443f0, #e9ecff 50%, #ea6a25) !important;
  background-size: 200% 100% !important;
  animation: premiumSheen 4s linear infinite;
  width: 34px !important; height: 2px !important;
}
@media (max-width: 700px) { .flow-layers > .mercury-layer { opacity: .72; } }
