/* «Метод тонировки» — Mini App. Тёмный глассморфизм + золото. */

:root {
  --gold: #f5b84c;
  --gold-strong: #ffce6b;
  --bg: #0d0d12;
  --card: rgba(255, 255, 255, 0.06);
  --card-border: rgba(255, 255, 255, 0.12);
  --text: #f4f1ea;
  --muted: rgba(244, 241, 234, 0.6);
  --radius: 20px;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { -webkit-tap-highlight-color: transparent; }

body {
  background: var(--bg);
  background:
    radial-gradient(1200px 600px at 80% -10%, rgba(245, 184, 76, 0.10), transparent 60%),
    radial-gradient(900px 500px at -10% 30%, rgba(120, 80, 255, 0.08), transparent 60%),
    var(--bg);
  color: var(--tg-theme-text-color, var(--text));
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  min-height: 100vh;
  overscroll-behavior: none;
}

.page {
  max-width: 520px;
  margin: 0 auto;
  padding: 0 16px calc(24px + var(--safe-bottom));
  animation: fadeIn 0.5s ease both;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  margin: 0 -16px 8px;
  padding: 40px 24px 32px;
  overflow: hidden;
}
.hero-glow {
  position: absolute;
  inset: -40% -20% auto;
  height: 320px;
  background: radial-gradient(closest-side, rgba(245, 184, 76, 0.35), transparent);
  filter: blur(20px);
  pointer-events: none;
  animation: breathe 5s ease-in-out infinite alternate;
}
.hero-inner { position: relative; text-align: center; }
.badge {
  display: inline-block;
  padding: 6px 14px;
  font-size: 12px;
  color: var(--gold-strong);
  border: 1px solid rgba(245, 184, 76, 0.4);
  border-radius: 999px;
  background: rgba(245, 184, 76, 0.08);
  margin-bottom: 16px;
}
.hero h1 {
  font-size: 36px;
  font-weight: 800;
  letter-spacing: -0.5px;
  line-height: 1.1;
}
.gold {
  background: linear-gradient(135deg, var(--gold-strong), var(--gold) 60%, #b87d1b);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.subtitle {
  margin-top: 12px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.5;
}
.hero-stats {
  display: flex;
  justify-content: center;
  gap: 26px;
  margin-top: 22px;
}
.stat { display: flex; flex-direction: column; align-items: center; }
.stat b { font-size: 17px; color: var(--gold-strong); }
.stat span { font-size: 11px; color: var(--muted); margin-top: 2px; }

/* ---------- Секции ---------- */
.section { margin-top: 28px; }
.section-title {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 14px;
}

.glass-card {
  background: var(--tg-theme-secondary-bg-color, var(--card));
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

/* ---------- Товары ---------- */
.products { display: flex; flex-direction: column; gap: 12px; }
.product {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px;
  cursor: pointer;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
  animation: slideUp 0.45s ease both;
}
.product:nth-child(2) { animation-delay: 0.07s; }
.product:nth-child(3) { animation-delay: 0.14s; }
.product:active { transform: scale(0.975); }
.product.hit {
  border-color: rgba(245, 184, 76, 0.55);
  box-shadow: 0 0 0 1px rgba(245, 184, 76, 0.25), 0 8px 30px rgba(245, 184, 76, 0.12);
}
.product-emoji {
  font-size: 30px;
  width: 54px; height: 54px;
  display: grid; place-items: center;
  background: rgba(245, 184, 76, 0.1);
  border-radius: 14px;
  flex-shrink: 0;
}
.product-info { flex: 1; min-width: 0; }
.product-info h3 { font-size: 16px; font-weight: 700; }
.product-info p {
  font-size: 12.5px;
  color: var(--muted);
  margin-top: 3px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.product-price {
  text-align: right;
  flex-shrink: 0;
}
.product-price b { font-size: 17px; color: var(--gold-strong); }
.product-price .old {
  display: block;
  font-size: 11px;
  color: var(--muted);
  text-decoration: line-through;
}
.popular-tag {
  position: relative;
  top: -10px;
  font-size: 10px;
  color: #111;
  background: linear-gradient(135deg, var(--gold-strong), var(--gold));
  border-radius: 6px;
  padding: 2px 8px;
  font-weight: 700;
}

/* ---------- Преимущества ---------- */
.features {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.feature { padding: 16px 14px; }
.feature-icon { font-size: 24px; margin-bottom: 8px; }
.feature h3 { font-size: 14px; margin-bottom: 4px; }
.feature p { font-size: 12px; color: var(--muted); line-height: 1.45; }

/* ---------- Отзывы ---------- */
.reviews { display: flex; flex-direction: column; gap: 10px; }
.review { padding: 14px 16px; }
.review-head { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.avatar {
  width: 36px; height: 36px;
  border-radius: 50%;
  display: grid; place-items: center;
  font-weight: 700;
  color: #111;
  background: linear-gradient(135deg, var(--gold-strong), var(--gold));
}
.stars { color: var(--gold); font-size: 12px; margin-left: 8px; }
.review p { font-size: 13px; color: var(--muted); line-height: 1.5; font-style: italic; }

/* ---------- FAQ ---------- */
.faq { display: flex; flex-direction: column; gap: 8px; }
.qa { padding: 0; overflow: hidden; }
.qa summary {
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 16px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  user-select: none;
}
.qa summary::-webkit-details-marker { display: none; }
.chevron {
  color: var(--gold);
  font-size: 20px;
  transition: transform 0.25s ease;
}
.qa[open] .chevron { transform: rotate(90deg); }
.qa p {
  padding: 0 16px 14px;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
  animation: fadeIn 0.25s ease;
}

/* ---------- Футер ---------- */
.footer {
  margin-top: 36px;
  text-align: center;
  font-size: 12px;
  color: var(--muted);
  line-height: 1.7;
}

/* ---------- Кнопки ---------- */
.btn-gold {
  width: 100%;
  padding: 15px;
  border: none;
  border-radius: 14px;
  font-size: 16px;
  font-weight: 700;
  color: #14100a;
  background: linear-gradient(135deg, var(--gold-strong), var(--gold));
  cursor: pointer;
  transition: transform 0.15s ease, filter 0.15s ease;
}
.btn-gold:active { transform: scale(0.97); filter: brightness(1.08); }
.btn-gold:disabled { opacity: 0.55; cursor: default; }

/* ---------- Модалка ---------- */
.modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  z-index: 50;
  animation: fadeIn 0.2s ease;
}
.modal {
  position: relative;
  width: 100%;
  max-width: 520px;
  max-height: 82vh;
  overflow-y: auto;
  padding: 22px 20px calc(20px + var(--safe-bottom));
  border-radius: 24px 24px 0 0;
  border-bottom: none;
  background: #17171f;
  animation: sheetUp 0.3s cubic-bezier(0.32, 0.72, 0, 1);
}
.modal-close {
  position: absolute;
  top: 14px; right: 14px;
  width: 32px; height: 32px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
  font-size: 14px;
  cursor: pointer;
}
.modal-emoji { font-size: 44px; text-align: center; margin-bottom: 8px; }
.modal h3 {
  text-align: center;
  font-size: 22px;
  margin-bottom: 6px;
}
.modal .modal-price {
  text-align: center;
  font-size: 26px;
  font-weight: 800;
  color: var(--gold-strong);
  margin-bottom: 14px;
}
.modal .modal-price .old {
  font-size: 14px;
  color: var(--muted);
  text-decoration: line-through;
  margin-right: 8px;
  font-weight: 400;
}
.modal ul { list-style: none; margin-bottom: 18px; }
.modal li {
  padding: 7px 0 7px 26px;
  font-size: 13.5px;
  color: var(--muted);
  position: relative;
}
.modal li::before {
  content: "✓";
  position: absolute;
  left: 4px;
  color: var(--gold);
  font-weight: 700;
}

/* ---------- Экран успеха ---------- */
.success-screen {
  position: fixed; inset: 0;
  z-index: 100;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  animation: fadeIn 0.3s ease;
}
.success-inner { padding: 24px; max-width: 340px; }
.success-check {
  width: 88px; height: 88px;
  margin: 0 auto 20px;
  border-radius: 50%;
  display: grid; place-items: center;
  font-size: 42px;
  color: #14100a;
  background: linear-gradient(135deg, var(--gold-strong), var(--gold));
  box-shadow: 0 0 60px rgba(245, 184, 76, 0.4);
  animation: pop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) 0.1s both;
}
.success-inner h2 { margin-bottom: 8px; }
.success-inner p { color: var(--muted); margin-bottom: 22px; }

.hidden { display: none !important; }
.muted { opacity: 0.6; }

/* ---------- Анимации ---------- */
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideUp { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes sheetUp { from { transform: translateY(60px); opacity: 0.5; } to { transform: none; opacity: 1; } }
@keyframes pop { from { transform: scale(0.4); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@keyframes breathe { from { opacity: 0.7; } to { opacity: 1; } }
