/* Project D.T.R landing v3 - структура референса, токены = DESIGN.md (ночная гавань). */

@font-face {
  font-family: "Unbounded Variable";
  font-style: normal;
  font-display: swap;
  font-weight: 200 900;
  src: url(/fonts/unbounded-cyrillic-wght-normal.woff2) format("woff2-variations");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Unbounded Variable";
  font-style: normal;
  font-display: swap;
  font-weight: 200 900;
  src: url(/fonts/unbounded-latin-wght-normal.woff2) format("woff2-variations");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Manrope Variable";
  font-style: normal;
  font-display: swap;
  font-weight: 200 800;
  src: url(/fonts/manrope-cyrillic-wght-normal.woff2) format("woff2-variations");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Manrope Variable";
  font-style: normal;
  font-display: swap;
  font-weight: 200 800;
  src: url(/fonts/manrope-latin-wght-normal.woff2) format("woff2-variations");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --night: #0b0f16;
  --surface: #101823;
  --surface-2: #16222f;
  --line: #20303f;
  --ink: #e9eef6;
  --ink-dim: #93a5b4;
  --ink-faint: #7e90a6;
  --cyan: #38bdf8;
  --mint: #6ee7b7;
  --teal-glow: #5eead4;
  --teal-brand: #2dd4bf;
  --teal-deep: #14b8a6;
  --r-card: 1rem;
  --r-ctl: 0.75rem;
  --sh-pop: 0 10px 32px rgba(2, 8, 14, 0.5);
  --ease-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --font-ui: "Manrope Variable", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-display: "Unbounded Variable", "Manrope Variable", sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-tap-highlight-color: transparent; scroll-behavior: smooth; }
body {
  margin: 0;
  overflow-x: clip;
  background: var(--night);
  color: var(--ink);
  font: 400 15px/1.6 var(--font-ui);
  -webkit-font-smoothing: antialiased;
}

.bg-backdrop {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-color: var(--night);
  background-image:
    radial-gradient(ellipse 90% 38% at 50% -6%, rgba(45, 212, 191, 0.1), transparent),
    linear-gradient(rgba(147, 165, 180, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(147, 165, 180, 0.05) 1px, transparent 1px);
  background-size: 100% 100%, 44px 44px, 44px 44px;
}

::selection { background: rgba(94, 234, 212, 0.85); color: #06201c; }
a { text-underline-offset: 3px; }
a:focus-visible, button:focus-visible {
  outline: 2px solid var(--teal-glow);
  outline-offset: 3px;
  border-radius: var(--r-ctl);
}
html { scrollbar-width: thin; scrollbar-color: #20303f transparent; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: #20303f; border-radius: 999px; border: 2px solid var(--night); }
[hidden] { display: none !important; }

.tnum { font-feature-settings: "tnum"; }
/* Якоря под липкой шапкой: заголовок секции прятался под неё */
.scene[id] { scroll-margin-top: 84px; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }

/* ---------- Шапка ---------- */
.mast {
  position: sticky;
  top: 0;
  z-index: 40;
  border-bottom: 1px solid rgba(32, 48, 63, 0.6);
  background: rgba(11, 15, 22, 0.88);
  backdrop-filter: blur(10px);
}
.mast-in { display: flex; align-items: center; gap: 20px; padding-top: 14px; padding-bottom: 14px; }
.brand { display: flex; align-items: center; gap: 9px; text-decoration: none; color: var(--ink); }
.brand-bust { filter: drop-shadow(0 2px 8px rgba(45, 212, 191, 0.4)); }
.brand-name { font: 700 16px var(--font-display); letter-spacing: 0.02em; }
.brand-name b { color: var(--teal-glow); font-weight: 700; }
.mast-nav { display: none; gap: 26px; margin: 0 auto; }
.mast-nav a {
  color: var(--ink-dim);
  text-decoration: none;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  transition: color 0.2s;
}
.mast-nav a:hover { color: var(--teal-glow); }

/* ---------- Кнопки ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 50px;
  padding: 0 26px;
  border-radius: var(--r-ctl);
  font: 700 15px var(--font-ui);
  text-decoration: none;
  border: 1px solid transparent;
  transition: transform 0.15s var(--ease-expo), box-shadow 0.25s, border-color 0.2s, background 0.2s;
}
.btn:active { transform: scale(0.97); }
.btn-primary {
  background: linear-gradient(135deg, var(--teal-brand), var(--teal-deep));
  color: #06201c;
  box-shadow: 0 6px 20px rgba(45, 212, 191, 0.25);
}
.btn-primary:hover { box-shadow: 0 8px 28px rgba(45, 212, 191, 0.4); }
.btn-ghost { border-color: var(--line); color: var(--ink); background: var(--surface); }
.btn-ghost:hover { border-color: var(--teal-deep); color: var(--teal-glow); }
.btn-s { min-height: 40px; padding: 0 18px; font-size: 15px; }
.btn-full { width: 100%; margin-top: 16px; }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: clip; text-align: center; padding-top: 88px; }
.hero-mark {
  position: absolute;
  right: -40px;
  top: 10px;
  width: 340px;
  opacity: 0.2;
  pointer-events: none;
  /* статуя - водяной знак: маска гасит низ (канал маски, не цвет) */
  -webkit-mask-image: linear-gradient(180deg, #000 55%, transparent 92%);
  mask-image: linear-gradient(180deg, #000 55%, transparent 92%);
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 22px;
  padding: 7px 16px;
  border: 1px solid rgba(45, 212, 191, 0.5);
  border-radius: 999px;
  background: rgba(45, 212, 191, 0.08);
  color: var(--teal-glow);
  font-size: 15px;
  font-weight: 600;
}
.chip-dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--teal-brand);
  box-shadow: 0 0 8px var(--teal-glow);
  animation: dot-pulse 2.4s ease-in-out infinite;
}
@keyframes dot-pulse { 50% { opacity: 0.45; } }
h1 {
  margin: 0;
  font: 600 clamp(34px, 6.4vw, 64px)/1.1 var(--font-display);
  letter-spacing: -0.02em;
  text-wrap: balance;
}
h1 em { font-style: normal; color: var(--teal-glow); }
.lead { margin: 20px auto 0; max-width: 58ch; color: var(--ink-dim); font-size: 16.5px; }
.cta-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 32px; }
.cta-center { justify-content: center; }

/* ---------- Метрики ---------- */
.metrics {
  margin-top: 64px;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.metric { padding: 22px 18px; }
.metric b {
  display: block;
  font: 500 clamp(19px, 2.6vw, 26px)/1.15 var(--font-display);
  letter-spacing: -0.01em;
}
.metric span { display: block; margin-top: 6px; color: var(--ink-dim); font-size: 12px; }

/* ---------- Сцены ---------- */
.scene { margin-top: 104px; }
.sec-label {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0 0 18px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--teal-glow);
}
.sec-label::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.h2 {
  margin: 0;
  font: 500 clamp(23px, 3.4vw, 32px)/1.22 var(--font-display);
  letter-spacing: -0.01em;
  text-wrap: balance;
}
.scene-sub { margin: 12px 0 0; max-width: 58ch; color: var(--ink-dim); }

/* Возможности */
.features { display: grid; gap: 14px; margin-top: 36px; grid-template-columns: 1fr; }
.feature {
  padding: 22px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  transition: border-color 0.2s, transform 0.3s var(--ease-expo);
}
.feature:hover { border-color: rgba(45, 212, 191, 0.4); transform: translateY(-2px); }
.feature svg { color: var(--teal-brand); }
.feature h3 { margin: 14px 0 6px; font: 600 17px var(--font-ui); }
.feature p { margin: 0; color: var(--ink-dim); font-size: 15px; }

/* Тарифы */
.plans { display: grid; gap: 16px; margin-top: 36px; }
.plan {
  display: flex;
  flex-direction: column;
  padding: 24px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-card);
}
.plan-hot { border-color: rgba(45, 212, 191, 0.45); box-shadow: 0 10px 32px rgba(2, 8, 14, 0.5), 0 0 40px rgba(45, 212, 191, 0.08); }
.plan-name { margin: 0; font: 500 clamp(18px, 5vw, 22px) var(--font-display); }
.plan-dev { margin: 6px 0 10px; color: var(--ink-faint); font-size: 12px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; }
.plan-rows { flex: 1; margin-top: 4px; }
.row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 0;
  border-top: 1px solid var(--line);
}
.plan-rows .row:first-child { border-top: 0; }
.row span { color: var(--ink-dim); }
.row b { font-weight: 600; text-align: right; white-space: nowrap; }

/* Подключение: табы + шаги */
.tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 30px; }
.tab {
  padding: 10px 20px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: none;
  color: var(--ink-dim);
  font: 700 15px var(--font-ui);
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s, background 0.2s;
}
.tab:hover { color: var(--ink); }
.tab[aria-selected="true"] {
  background: var(--surface);
  border-color: rgba(45, 212, 191, 0.55);
  color: var(--teal-glow);
}
.panel { margin-top: 10px; }
.steps { list-style: none; margin: 0; padding: 0; counter-reset: step; }
.step {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-areas: "n t" "n p";
  column-gap: 20px;
  padding: 22px 0;
  border-top: 1px solid var(--line);
}
.step:last-child { border-bottom: 1px solid var(--line); }
.step-n { grid-area: n; font: 500 30px/1 var(--font-display); color: var(--teal-deep); }
.step h3 { grid-area: t; margin: 2px 0 0; font: 600 17px var(--font-ui); }
.step p { grid-area: p; margin: 6px 0 0; color: var(--ink-dim); max-width: 56ch; }

/* FAQ */
.faq-list { margin-top: 28px; border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-q {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  width: 100%;
  padding: 19px 4px;
  background: none;
  border: 0;
  color: var(--ink);
  font: 600 16px var(--font-ui);
  text-align: left;
  cursor: pointer;
}
.faq-q svg { flex-shrink: 0; color: var(--ink-dim); transition: transform 0.3s var(--ease-expo); }
.faq-q[aria-expanded="true"] svg { transform: rotate(180deg); color: var(--teal-glow); }
.faq-a { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 0.32s var(--ease-expo); visibility: hidden; }
.faq-item.open .faq-a { grid-template-rows: 1fr; visibility: visible; }
.faq-a p { overflow: hidden; margin: 0; padding: 0 4px; color: var(--ink-dim); font-size: 15px; min-height: 0; }
.faq-item.open .faq-a p { padding-bottom: 20px; }
.lnk { color: var(--teal-glow); text-decoration: none; border-bottom: 1px dashed rgba(94, 234, 212, 0.5); }
.lnk:hover { border-bottom-style: solid; }

/* Финал */
.final { position: relative; text-align: center; padding: 8px 0 4px; }
.halo {
  position: absolute;
  left: 50%;
  top: -30px;
  width: 320px;
  aspect-ratio: 1;
  transform: translateX(-50%);
  background: radial-gradient(circle, rgba(45, 212, 191, 0.16), rgba(45, 212, 191, 0.05) 45%, transparent 70%);
  border-radius: 999px;
  pointer-events: none;
}
.halo::after {
  content: "";
  position: absolute;
  inset: 18%;
  border: 1px solid rgba(94, 234, 212, 0.3);
  border-radius: 50%;
  animation: orbit-ring 3.2s ease-in-out infinite;
}
@keyframes orbit-ring {
  0%, 100% { transform: scale(0.94); opacity: 0.35; }
  50% { transform: scale(1.05); opacity: 0.7; }
}
.final-bust {
  position: relative;
  filter: drop-shadow(0 10px 28px rgba(45, 212, 191, 0.35));
  animation: bust-float 5.2s ease-in-out infinite;
}
@keyframes bust-float { 50% { transform: translateY(-7px); } }
.final .h2 { margin-top: 20px; }
.final .scene-sub { margin-left: auto; margin-right: auto; }

/* Подвал */
.foot { margin-top: 104px; border-top: 1px solid var(--line); padding: 40px 0 30px; }
.foot-in { display: grid; gap: 26px; }
.foot-brand { display: flex; align-items: center; gap: 8px; }
.foot-desc { margin: 12px 0 0; color: var(--ink-faint); font-size: 12px; max-width: 240px; }
.foot-h { margin: 0 0 10px; font-size: 12px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-faint); }
.foot-col a {
  display: block;
  padding: 5px 0;
  color: var(--ink-dim);
  text-decoration: none;
  font-size: 15px;
  transition: color 0.2s;
}
.foot-col a:hover { color: var(--teal-glow); }
.foot-copy { margin: 26px auto 0; color: var(--ink-faint); font-size: 12px; }

/* ---------- Появление ---------- */
.rv { opacity: 0; transform: translateY(18px); transition: opacity 0.7s var(--ease-expo), transform 0.7s var(--ease-expo); }
.rv.in { opacity: 1; transform: none; }
.d1 { transition-delay: 0.08s; }
.d2 { transition-delay: 0.16s; }
.d3 { transition-delay: 0.24s; }
.d4 { transition-delay: 0.32s; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .rv { opacity: 1; transform: none; transition: none; }
  .final-bust, .halo::after, .chip-dot { animation: none; }
  .faq-a { transition: none; }
  .feature:hover { transform: none; }
}

/* ---------- Адаптив ---------- */
@media (min-width: 720px) {
  .mast-nav { display: flex; }
  .mast .btn { margin-left: auto; }
  .metrics { grid-template-columns: repeat(4, 1fr); }
  .metric + .metric { border-left: 1px solid var(--line); }
  .features { grid-template-columns: repeat(3, 1fr); }
  .plans { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .plan { grid-column: span 2; }
  .plan:nth-child(n+4) { grid-column: span 3; }
  .foot-in { grid-template-columns: 1.4fr 1fr 1fr 1fr; }
}
@media (max-width: 719px) {
  .mast .btn { margin-left: auto; }
  .hero { padding-top: 60px; }
  .hero-mark { width: 220px; right: -30px; opacity: 0.16; }
  .metric:nth-child(2n) { border-left: 1px solid var(--line); }
  .metric:nth-child(n + 3) { border-top: 1px solid var(--line); }
  .scene { margin-top: 80px; }
}
