:root {
  --bg: #080910;
  --panel: rgba(255, 255, 255, 0.04);
  --panel-strong: rgba(255, 255, 255, 0.08);
  --text: #eef3f6;
  --muted: #9fb2c2;
  --primary: #4ef0d2;
  --primary-2: #8b7bff;
  --border: rgba(255, 255, 255, 0.08);
  --shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
  --radius: 18px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: radial-gradient(circle at 20% 20%, rgba(78, 240, 210, 0.08), transparent 30%),
              radial-gradient(circle at 80% 10%, rgba(139, 123, 255, 0.10), transparent 30%),
              var(--bg);
  color: var(--text);
  line-height: 1.6;
}

a {
  color: var(--text);
  text-decoration: none;
}

.bg-grid {
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 80px 80px;
  mask-image: radial-gradient(circle at 50% 30%, rgba(0, 0, 0, 0.7), transparent 70%);
  z-index: 0;
  pointer-events: none;
}

.top-bar {
  position: sticky;
  top: 0;
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 18px 48px;
  background: rgba(8, 9, 16, 0.8);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  z-index: 10;
}

.logo {
  font-weight: 700;
  letter-spacing: 0.08em;
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav {
  display: flex;
  gap: 16px;
  flex: 1;
}

.nav a {
  padding: 8px 10px;
  border-radius: 10px;
  color: var(--muted);
  transition: color 0.2s, background 0.2s;
}

.nav a:hover {
  color: var(--text);
  background: var(--panel);
}

.top-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

.burger {
  display: none;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--panel);
  position: relative;
}

.burger::before,
.burger::after {
  content: '';
  position: absolute;
  left: 10px;
  right: 10px;
  height: 2px;
  background: var(--text);
  transition: transform 0.2s, top 0.2s, bottom 0.2s;
}

.burger::before { top: 14px; }
.burger::after { bottom: 14px; }
.burger.open::before { top: 19px; transform: rotate(45deg); }
.burger.open::after { bottom: 19px; transform: rotate(-45deg); }

.primary,
.ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 16px;
  border-radius: 12px;
  font-weight: 600;
  transition: transform 0.12s ease, box-shadow 0.2s, background 0.2s, color 0.2s;
}

.primary {
  background: linear-gradient(120deg, var(--primary), var(--primary-2));
  color: #0a0b12;
  box-shadow: 0 10px 30px rgba(78, 240, 210, 0.25);
}

.primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 36px rgba(78, 240, 210, 0.35);
}

.ghost {
  border: 1px solid var(--border);
  background: var(--panel);
  color: var(--text);
}

.ghost:hover {
  border-color: rgba(255, 255, 255, 0.15);
  transform: translateY(-1px);
}

.lg {
  padding: 12px 20px;
  border-radius: 14px;
}

main {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 32px 24px 80px;
}

.hero {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 36px;
  padding: 32px;
  margin-top: 24px;
  background: linear-gradient(145deg, rgba(78, 240, 210, 0.08), rgba(139, 123, 255, 0.08));
  border: 1px solid var(--border);
  border-radius: 28px;
  box-shadow: var(--shadow);
}

.badge {
  display: inline-flex;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(78, 240, 210, 0.12);
  color: var(--primary);
  font-weight: 600;
  letter-spacing: 0.01em;
  margin-bottom: 8px;
}

h1 {
  font-size: 42px;
  line-height: 1.1;
  margin: 0 0 14px;
}

.lead {
  color: var(--muted);
  font-size: 18px;
  margin-bottom: 20px;
}

.cta-row {
  display: flex;
  gap: 12px;
  margin-bottom: 18px;
  flex-wrap: wrap;
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  color: var(--muted);
  font-size: 14px;
}

.stats span {
  display: block;
  color: var(--text);
  font-weight: 700;
  font-size: 18px;
}

.hero-card {
  position: relative;
}

.screen {
  background: var(--panel-strong);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 18px;
  min-height: 340px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}

.screen.telegram-style {
  background-color: #ffffff; /* Белый фон */
  position: relative;
}

.screen.telegram-style::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url('../images/tg-chat-bg.png');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0.4; /* 40% непрозрачности для лучшей читаемости */
  pointer-events: none;
  z-index: 0;
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(78, 240, 210, 0.14);
  color: var(--primary);
  padding: 6px 12px;
  border-radius: 12px;
  font-weight: 600;
  position: relative;
  z-index: 1;
}

.screen.telegram-style .status {
  background: rgba(255, 255, 255, 0.9);
  color: #3390ec;
  border: 1px solid rgba(51, 144, 236, 0.3);
}

.chat-bubbles {
  margin: 16px 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  position: relative;
  z-index: 1;
}

.bubble {
  max-width: 55%;
  position: relative;
  display: flex;
}

.bubble.user {
  margin-left: auto;
  margin-right: -12px;
  justify-content: flex-end;
}

.bubble.bot {
  margin-left: -12px;
  justify-content: flex-start;
}

.bubble-content {
  padding: 6px 10px;
  word-wrap: break-word;
  position: relative;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 4px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
  min-height: fit-content;
  flex-wrap: wrap;
}

.bubble-text {
  flex: 1;
  word-wrap: break-word;
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  font-style: normal;
  font-weight: 400;
  font-size: 12px;
  line-height: 14px;
  color: #000000;
  min-width: 0;
  text-align: left;
}

.bubble-time {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  font-style: normal;
  font-weight: 400;
  font-size: 10px;
  line-height: 14px;
  color: rgba(0, 0, 0, 0.45);
  white-space: nowrap;
  flex-shrink: 0;
  text-align: right;
}

.bubble.user .bubble-time {
  color: #4a9e5f;
}

/* Отправленные сообщения (справа, зеленые) */
.bubble.user .bubble-content {
  background-color: #dcf8c6;
  color: #000000;
  /* Зеркальная версия SVG для отправленных сообщений (хвостик справа) */
  mask-image: url("data:image/svg+xml,%3Csvg width='291' height='56' viewBox='0 0 291 56' fill='none' xmlns='http://www.w3.org/2000/svg' preserveAspectRatio='none'%3E%3Cpath transform='scale(-1,1) translate(-291,0)' d='M31.0673 0H264C283.61 0 291 13.6725 291 29.2327C291 44.793 283.61 56 264 56H38C27.3473 56 21.321 54.7264 16.8824 50.5C15.107 54.022 7.10175 55.2956 0 56C3.55088 54.239 8.26138 54.9434 8.70524 47.8994C8.70496 42.9686 8.70496 46.4906 8.70496 42.9686C8.70496 40.151 8.70524 35.5724 8.70525 27.824C8.70524 16.2013 8.70527 29.2327 8.70525 19.7233C9.14911 10.2138 15.976 0 31.0673 0Z' fill='black'/%3E%3C/svg%3E");
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg width='291' height='56' viewBox='0 0 291 56' fill='none' xmlns='http://www.w3.org/2000/svg' preserveAspectRatio='none'%3E%3Cpath transform='scale(-1,1) translate(-291,0)' d='M31.0673 0H264C283.61 0 291 13.6725 291 29.2327C291 44.793 283.61 56 264 56H38C27.3473 56 21.321 54.7264 16.8824 50.5C15.107 54.022 7.10175 55.2956 0 56C3.55088 54.239 8.26138 54.9434 8.70524 47.8994C8.70496 42.9686 8.70496 46.4906 8.70496 42.9686C8.70496 40.151 8.70524 35.5724 8.70525 27.824C8.70524 16.2013 8.70527 29.2327 8.70525 19.7233C9.14911 10.2138 15.976 0 31.0673 0Z' fill='black'/%3E%3C/svg%3E");
  mask-size: 100% 100%;
  -webkit-mask-size: 100% 100%;
  mask-repeat: no-repeat;
  -webkit-mask-repeat: no-repeat;
  mask-position: center;
  -webkit-mask-position: center;
}

/* Полученные сообщения (слева, белые) */
.bubble.bot .bubble-content {
  background-color: #ffffff;
  color: #000000;
  border: 1px solid #e0e0e0;
  padding-left: 14px;
  /* Используем новый SVG для формы пузыря */
  mask-image: url("data:image/svg+xml,%3Csvg width='291' height='56' viewBox='0 0 291 56' fill='none' xmlns='http://www.w3.org/2000/svg' preserveAspectRatio='none'%3E%3Cpath d='M31.0673 0H264C283.61 0 291 13.6725 291 29.2327C291 44.793 283.61 56 264 56H38C27.3473 56 21.321 54.7264 16.8824 50.5C15.107 54.022 7.10175 55.2956 0 56C3.55088 54.239 8.26138 54.9434 8.70524 47.8994C8.70496 42.9686 8.70496 46.4906 8.70496 42.9686C8.70496 40.151 8.70524 35.5724 8.70525 27.824C8.70524 16.2013 8.70527 29.2327 8.70525 19.7233C9.14911 10.2138 15.976 0 31.0673 0Z' fill='black'/%3E%3C/svg%3E");
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg width='291' height='56' viewBox='0 0 291 56' fill='none' xmlns='http://www.w3.org/2000/svg' preserveAspectRatio='none'%3E%3Cpath d='M31.0673 0H264C283.61 0 291 13.6725 291 29.2327C291 44.793 283.61 56 264 56H38C27.3473 56 21.321 54.7264 16.8824 50.5C15.107 54.022 7.10175 55.2956 0 56C3.55088 54.239 8.26138 54.9434 8.70524 47.8994C8.70496 42.9686 8.70496 46.4906 8.70496 42.9686C8.70496 40.151 8.70524 35.5724 8.70525 27.824C8.70524 16.2013 8.70527 29.2327 8.70525 19.7233C9.14911 10.2138 15.976 0 31.0673 0Z' fill='black'/%3E%3C/svg%3E");
  mask-size: 100% 100%;
  -webkit-mask-size: 100% 100%;
  mask-repeat: no-repeat;
  -webkit-mask-repeat: no-repeat;
  mask-position: center;
  -webkit-mask-position: center;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(139, 123, 255, 0.15);
  color: #d7d3ff;
  font-weight: 600;
  font-size: 13px;
  position: relative;
  z-index: 1;
}

.screen.telegram-style .pill {
  background: rgba(255, 255, 255, 0.9);
  color: #3390ec;
  border: 1px solid rgba(51, 144, 236, 0.3);
}

.pill.small {
  padding: 6px 10px;
  font-weight: 600;
}

.floating-card {
  position: absolute;
  right: 24px;
  bottom: 40px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(8, 9, 16, 0.9);
  border: 1px solid var(--border);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
  font-size: 14px;
  z-index: 10;
}

.floating-card span {
  display: block;
  color: var(--primary);
  font-weight: 700;
}

.panel {
  margin-top: 52px;
  padding: 32px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 22px;
  box-shadow: var(--shadow);
}

.panel.accent {
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.03), rgba(139, 123, 255, 0.05));
}

.panel.split {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  align-items: center;
}

.section-head h2 {
  margin: 4px 0 10px;
  font-size: 28px;
}

.section-head .sub {
  color: var(--muted);
  margin: 0;
}

.cards {
  display: grid;
  gap: 18px;
}

.grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.card {
  background: var(--panel-strong);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  position: relative;
}

.card h3 {
  margin-top: 6px;
}

.card p {
  color: var(--muted);
}

.case .metrics {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--primary);
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}

.feature {
  padding: 16px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.03);
}

.timeline {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.step {
  padding: 16px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
}

.step span {
  display: inline-flex;
  width: 34px;
  height: 34px;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: rgba(78, 240, 210, 0.12);
  color: var(--primary);
  font-weight: 700;
  margin-bottom: 8px;
}

.pricing .card ul {
  padding-left: 18px;
  color: var(--muted);
  line-height: 1.5;
}

.pricing .featured {
  border-color: rgba(78, 240, 210, 0.6);
  background: linear-gradient(160deg, rgba(78, 240, 210, 0.12), rgba(139, 123, 255, 0.12));
  box-shadow: 0 12px 38px rgba(78, 240, 210, 0.2);
}

.qr-placeholder {
  min-height: 240px;
  border-radius: 18px;
  border: 1px dashed var(--border);
  background: rgba(255, 255, 255, 0.03);
  display: grid;
  place-items: center;
  text-align: center;
  gap: 8px;
  font-weight: 700;
  color: var(--muted);
}

.qr-placeholder span {
  display: inline-flex;
  width: 64px;
  height: 64px;
  border-radius: 16px;
  align-items: center;
  justify-content: center;
  background: rgba(78, 240, 210, 0.14);
  color: var(--text);
}

.accordion {
  display: grid;
  gap: 10px;
}

details {
  padding: 14px 16px;
  background: var(--panel-strong);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

summary {
  cursor: pointer;
  font-weight: 600;
}

details p {
  margin: 10px 0 0;
  color: var(--muted);
}

.contact {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.contact-info a {
  color: var(--primary);
}

.form {
  display: grid;
  gap: 12px;
  background: var(--panel-strong);
  border-radius: var(--radius);
  padding: 18px;
  border: 1px solid var(--border);
}

.form label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 14px;
}

.form input,
.form textarea {
  width: 100%;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  font-size: 15px;
}

.form textarea {
  min-height: 120px;
  resize: vertical;
}

.form button {
  border: none;
  cursor: pointer;
}

.form button:hover:not(:disabled) {
  transform: translateY(-1px);
}

.form button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.form-note {
  color: var(--muted);
  font-size: 12px;
  margin: 0;
}

.form-message {
  padding: 12px 16px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 8px;
}

.form-message.success {
  background: rgba(78, 240, 210, 0.15);
  border: 1px solid rgba(78, 240, 210, 0.4);
  color: var(--primary);
}

.form-message.error {
  background: rgba(255, 87, 87, 0.15);
  border: 1px solid rgba(255, 87, 87, 0.4);
  color: #ff5757;
}

.footer {
  margin: 50px auto 30px;
  max-width: 1200px;
  padding: 0 24px;
  color: var(--muted);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.footer .logo {
  color: var(--text);
}

.footer-links {
  display: flex;
  gap: 12px;
}

@media (max-width: 960px) {
  .top-bar { padding: 14px 18px; }
  .nav { display: none; position: absolute; top: 64px; left: 0; right: 0; flex-direction: column; padding: 12px 18px; background: rgba(8, 9, 16, 0.95); }
  .nav.open { display: flex; }
  .burger { display: block; }
  .hero { grid-template-columns: 1fr; }
  .panel.split { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); }
  .top-actions { display: none; }
  .floating-card {
    display: none;
  }
}

@media (max-width: 640px) {
  main { padding: 18px 16px 60px; }
  h1 { font-size: 32px; }
  .top-bar { position: fixed; width: 100%; }
  body { padding-top: 80px; }
  .floating-card {
    bottom: 20px;
  }
}

