/* ===== Tokens ===== */
:root {
  --bg: #0A0A0F;
  --bg-elevated: #14141C;
  --text: #FFFFFF;
  --text-dim: #B6B6C5;
  --text-mute: #74748B;
  --accent: #7B61FF;
  --accent-dim: #6451DA;
  --success: #10B981;
  --warning: #FBBF24;
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.16);
  --card: rgba(255, 255, 255, 0.03);
  --card-hover: rgba(255, 255, 255, 0.05);
  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 24px;
  --shadow-glow: 0 0 0 1px rgba(123, 97, 255, 0.2), 0 8px 32px -8px rgba(123, 97, 255, 0.4);
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* ===== Reset ===== */
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }
ul, ol { list-style: none; }

/* ===== Layout ===== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}
.container.narrow { max-width: 880px; }

/* ===== Typography ===== */
.h1 {
  font-size: clamp(38px, 5.5vw, 64px);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.02em;
  background: linear-gradient(180deg, #FFFFFF 0%, #B6B6C5 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.h2 {
  font-size: clamp(28px, 3.4vw, 44px);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.015em;
  margin-bottom: 0;
}
.h2.center { text-align: center; }
.lead {
  font-size: clamp(16px, 1.4vw, 19px);
  color: var(--text-dim);
  margin-top: 20px;
  max-width: 640px;
}
.lead.center { margin: 20px auto 0; text-align: center; }
.lead b { color: var(--text); font-weight: 600; }
.microcopy {
  color: var(--text-mute);
  font-size: 14px;
  margin-top: 16px;
}

/* ===== NAV ===== */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 10, 15, 0.7);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 18px;
  text-decoration: none;
  color: inherit;
  white-space: nowrap;
}
.brand-icon {
  width: 30px;
  height: 30px;
  flex-shrink: 0;
  filter: drop-shadow(0 6px 18px rgba(123, 97, 255, 0.5));
}
.brand-name {
  background: linear-gradient(120deg, #FFFFFF, var(--accent));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

/* Иконки-ссылки в навбаре (TG, MAX) — фирменные SVG со своими градиентами */
.nav-cta {
  display: flex;
  align-items: center;
  gap: 10px;
}
.icon-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  transition: transform 0.2s ease, filter 0.2s ease;
}
.icon-link svg {
  width: 32px;
  height: 32px;
  display: block;
}
.icon-link:hover {
  transform: translateY(-2px);
  filter: brightness(1.1) drop-shadow(0 6px 16px rgba(56, 176, 227, 0.4));
}

/* Иконка внутри кнопки CTA — фирменные градиенты */
.btn-icon {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 22px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 16px;
  transition: all 0.2s ease;
  border: 1px solid transparent;
  white-space: nowrap;
  cursor: pointer;
}
.btn-sm { padding: 9px 16px; font-size: 14px; }
.btn-block { display: flex; width: 100%; }
.btn-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-dim));
  color: white;
  box-shadow: 0 8px 30px -8px rgba(123, 97, 255, 0.6);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 40px -8px rgba(123, 97, 255, 0.8);
}
.btn-secondary {
  background: var(--card);
  color: var(--text);
  border-color: var(--border-strong);
  backdrop-filter: blur(10px);
}
.btn-secondary:hover {
  background: var(--card-hover);
  border-color: rgba(255, 255, 255, 0.3);
}

/* ===== HERO ===== */
.hero {
  position: relative;
  padding: clamp(60px, 9vw, 120px) 0 clamp(40px, 6vw, 100px);
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  top: -200px;
  left: 50%;
  transform: translateX(-50%);
  width: 1000px;
  height: 600px;
  background: radial-gradient(ellipse, rgba(123, 97, 255, 0.25), transparent 70%);
  pointer-events: none;
}
.hero-grid {
  position: relative;
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 60px;
  align-items: center;
}
.hero-text { animation: fadeUp 0.8s ease both; }
.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 36px;
}
.hero-ctas.center { justify-content: center; }
.hero-visual {
  position: relative;
  animation: fadeUp 0.8s 0.15s ease both;
}
.hero-img {
  width: 100%;
  border-radius: var(--radius-lg);
  box-shadow: 0 30px 80px -20px rgba(123, 97, 255, 0.4);
}
.hero-glow {
  position: absolute;
  inset: -40px;
  background: radial-gradient(circle, rgba(123, 97, 255, 0.2), transparent 60%);
  z-index: -1;
  filter: blur(40px);
}

/* ===== SECTIONS ===== */
.section {
  padding: clamp(60px, 8vw, 120px) 0;
  position: relative;
}
.section-alt { background: linear-gradient(180deg, transparent, rgba(123, 97, 255, 0.03), transparent); }
.section-head {
  text-align: center;
  margin-bottom: clamp(40px, 5vw, 70px);
}
.tag {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(123, 97, 255, 0.12);
  color: var(--accent);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

/* ===== GRID ===== */
.grid {
  display: grid;
  gap: 24px;
}
.grid-3 { grid-template-columns: repeat(3, 1fr); }

/* ===== CARDS / FEATURES ===== */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  backdrop-filter: blur(20px);
  transition: all 0.3s ease;
}
.card:hover {
  background: var(--card-hover);
  border-color: var(--border-strong);
  transform: translateY(-4px);
}
.feature h3 {
  font-size: 19px;
  font-weight: 600;
  margin: 18px 0 10px;
}
.feature p {
  color: var(--text-dim);
  font-size: 15px;
}
.feature-icon {
  width: 56px;
  height: 56px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-strong);
  color: var(--glow);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 30px -10px var(--glow);
}

/* ===== HOW ===== */
.how-grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 60px;
  align-items: center;
}
.steps { display: flex; flex-direction: column; gap: 28px; }
.step {
  display: flex;
  gap: 20px;
  padding: 24px;
  border-radius: var(--radius);
  background: var(--card);
  border: 1px solid var(--border);
  transition: all 0.3s ease;
}
.step:hover { border-color: rgba(123, 97, 255, 0.4); }
.step-num {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent-dim));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 18px;
  box-shadow: 0 6px 20px -4px rgba(123, 97, 255, 0.5);
}
.step h3 { font-size: 18px; margin-bottom: 6px; }
.step p { color: var(--text-dim); font-size: 15px; }
.how-visual {
  position: relative;
}
.how-visual img {
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
}
.how-glow {
  position: absolute;
  inset: -30px;
  background: radial-gradient(circle at 30% 50%, rgba(16, 185, 129, 0.15), transparent 60%);
  z-index: -1;
  filter: blur(40px);
}

/* ===== MP ===== */
.mp-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.mp-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  text-align: center;
  transition: all 0.3s ease;
}
.mp-card:hover { border-color: var(--border-strong); transform: translateY(-4px); }
.mp-logo {
  display: inline-block;
  padding: 12px 22px;
  border-radius: var(--radius);
  font-weight: 700;
  color: white;
  margin-bottom: 16px;
  font-size: 16px;
  letter-spacing: 0.02em;
}
.mp-card p {
  color: var(--text-dim);
  font-size: 15px;
}

/* ===== PRICING ===== */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  max-width: 880px;
  margin: 0 auto;
}
.pricing {
  position: relative;
  padding: 36px;
}
.pricing-featured {
  border-color: rgba(123, 97, 255, 0.4);
  box-shadow: var(--shadow-glow);
}
.badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  padding: 6px 14px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), var(--accent-dim));
  color: white;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
}
.pricing-name {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-dim);
}
.pricing-price {
  font-size: 42px;
  font-weight: 800;
  margin: 8px 0 28px;
  letter-spacing: -0.02em;
}
.pricing-price span {
  font-size: 18px;
  color: var(--text-mute);
  font-weight: 500;
}
.pricing-features {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 32px;
}
.pricing-features li {
  display: flex;
  gap: 10px;
  color: var(--text-dim);
  font-size: 15px;
}
.check {
  color: var(--success);
  font-weight: 700;
  flex-shrink: 0;
}

/* ===== FAQ ===== */
.faq {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.faq-item {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 26px;
  transition: all 0.2s ease;
}
.faq-item[open] {
  background: var(--card-hover);
  border-color: var(--border-strong);
}
.faq-item summary {
  font-weight: 600;
  font-size: 17px;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: '+';
  font-size: 22px;
  color: var(--accent);
  font-weight: 400;
  transition: transform 0.2s ease;
}
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item p {
  color: var(--text-dim);
  font-size: 15px;
  margin-top: 14px;
  line-height: 1.65;
}

/* ===== FINAL CTA ===== */
.final-cta {
  text-align: center;
  background: linear-gradient(180deg, transparent, rgba(123, 97, 255, 0.06));
  border-top: 1px solid var(--border);
  padding-top: clamp(80px, 9vw, 140px);
}

/* ===== FOOTER ===== */
.footer {
  padding: 50px 0;
  border-top: 1px solid var(--border);
  background: rgba(10, 10, 15, 0.5);
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 30px;
  flex-wrap: wrap;
}
.footer-brand { font-weight: 600; }
.footer-copy {
  font-size: 13px;
  color: var(--text-mute);
  font-weight: 400;
  margin-top: 6px;
  max-width: 320px;
}
.footer-links {
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-align: right;
}
.footer-links a {
  color: var(--text-dim);
  font-size: 14px;
  transition: color 0.2s;
}
.footer-links a:hover { color: var(--text); }

/* ===== ANIMATIONS ===== */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Reveal анимация работает ТОЛЬКО когда JS добавит .js-ready на body —
   иначе всё видно по умолчанию (graceful degradation, без JS контент не теряется). */
body.js-ready .reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
body.js-ready .reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 980px) {
  .hero-grid,
  .how-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .mp-grid { grid-template-columns: 1fr; }
}

@media (max-width: 680px) {
  .grid-3 { grid-template-columns: 1fr; }
  .pricing-grid { grid-template-columns: 1fr; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
  .footer-links { text-align: left; }
  .nav-cta .btn { padding: 7px 12px; font-size: 13px; }
  .hero-ctas { flex-direction: column; }
  .hero-ctas .btn { width: 100%; }
}
