:root {
  --bg: #0b0f16;
  --bg-alt: #0e141f;
  --surface: #121821;
  --surface-2: #1f2833;
  --border: #33414f;
  --text: #edf1f7;
  --muted: #aeb9c6;
  --accent: #e58baa;
  --accent-strong: #f2b8ce;
  --radius: 14px;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: "Segoe UI", "Inter", system-ui, -apple-system, Roboto, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
}

/* Фон */
.bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  background: url("../assets/bg.jpg") center/cover no-repeat;
  filter: brightness(0.32) saturate(0.85);
}
.bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(11,15,22,0.55) 0%, rgba(11,15,22,0.82) 55%, rgba(11,15,22,0.96) 100%);
}

/* Навигация */
.nav {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(11, 15, 22, 0.75);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.brand { display: flex; align-items: center; gap: 10px; }
.brand-logo { height: 34px; width: auto; }
.brand-name { font-weight: 700; font-size: 20px; color: var(--accent-strong); letter-spacing: 0.3px; }
.nav-links { display: flex; gap: 22px; }
.nav-links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
  transition: color 0.15s;
}
.nav-links a:hover { color: var(--accent-strong); }

/* Hero */
.hero {
  min-height: 82vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 70px 20px 60px;
}
.hero-logo { height: 120px; width: auto; margin-bottom: 18px; filter: drop-shadow(0 8px 24px rgba(229,139,170,0.25)); }
.hero-title { font-size: clamp(42px, 7vw, 68px); font-weight: 800; letter-spacing: 1px; color: var(--accent-strong); text-shadow: 0 4px 30px rgba(0,0,0,0.5); }
.hero-subtitle { font-size: clamp(15px, 2vw, 19px); color: var(--muted); margin-top: 10px; }
.badges { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin: 26px 0 34px; }
.badge {
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--accent-strong);
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 13px;
}
.hero-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; }

.btn {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  text-decoration: none;
  padding: 14px 30px;
  border-radius: var(--radius);
  font-size: 16px;
  font-weight: 700;
  transition: transform 0.15s, box-shadow 0.15s, background 0.15s;
}
.btn small { font-weight: 500; font-size: 12px; opacity: 0.8; }
.btn:hover { transform: translateY(-2px); }

.btn-primary {
  background: linear-gradient(135deg, var(--accent) 0%, #c96d8f 100%);
  color: #1a0d13;
  box-shadow: 0 10px 28px rgba(229, 139, 170, 0.35);
}
.btn-primary:hover { box-shadow: 0 14px 34px rgba(229, 139, 170, 0.5); }

.btn-ghost {
  background: var(--surface-2);
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-ghost:hover { background: #283343; }

.hero-note { margin-top: 26px; font-size: 13px; color: var(--muted); }

/* Секции */
.section { padding: 74px 20px; }
.section-alt { background: var(--bg-alt); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.container { max-width: 1080px; margin: 0 auto; }
.section-title { font-size: clamp(26px, 4vw, 34px); font-weight: 800; margin-bottom: 34px; text-align: center; color: var(--accent-strong); }

.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 18px; }
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 24px;
}
.card h3 { color: var(--accent-strong); font-size: 18px; margin-bottom: 8px; }
.card p { color: var(--muted); font-size: 14px; }

/* Шаги */
.steps { list-style: none; counter-reset: step; max-width: 720px; margin: 0 auto; display: grid; gap: 16px; }
.steps li {
  counter-increment: step;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px 16px 58px;
  position: relative;
  color: var(--muted);
  font-size: 15px;
}
.steps li::before {
  content: counter(step);
  position: absolute;
  left: 18px;
  top: 50%;
  transform: translateY(-50%);
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--accent);
  color: #1a0d13;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
}
code {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1px 7px;
  font-family: Consolas, monospace;
  font-size: 13px;
  color: var(--accent-strong);
  word-break: break-all;
}

/* Чейнджлог */
.changelog { max-width: 720px; margin: 0 auto; display: grid; gap: 14px; }
.change { display: flex; gap: 18px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px 20px; }
.change-version {
  flex-shrink: 0;
  align-self: flex-start;
  background: var(--accent);
  color: #1a0d13;
  font-weight: 800;
  font-size: 13px;
  padding: 4px 12px;
  border-radius: 999px;
  white-space: nowrap;
}
.change p { color: var(--muted); font-size: 14px; margin-bottom: 6px; }
.change p:last-child { margin-bottom: 0; }

/* FAQ */
.faq { max-width: 720px; margin: 0 auto; display: grid; gap: 12px; }
.faq details { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 18px; }
.faq summary { cursor: pointer; font-weight: 600; color: var(--text); }
.faq summary:hover { color: var(--accent-strong); }
.faq p { color: var(--muted); font-size: 14px; margin-top: 10px; }

/* Цены */
.sale-banner {
  max-width: 520px;
  margin: 0 auto 18px;
  text-align: center;
  background: linear-gradient(135deg, rgba(229, 139, 170, 0.18) 0%, rgba(201, 109, 143, 0.18) 100%);
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  color: var(--accent-strong);
  font-weight: 700;
  font-size: 15px;
  padding: 12px 18px;
  box-shadow: 0 6px 24px rgba(229, 139, 170, 0.15);
}
.pricing-note { text-align: center; color: var(--muted); font-size: 14px; margin-bottom: 30px; }
.pricing-note a { color: var(--accent-strong); }
.pricing-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 18px; max-width: 900px; margin: 0 auto; }
.price-card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  transition: transform 0.15s, box-shadow 0.15s, border-color 0.15s;
}
.price-card:hover { transform: translateY(-4px); }
.price-card.price-hit { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent), 0 14px 34px rgba(229, 139, 170, 0.18); }
.price-tag {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, var(--accent) 0%, #c96d8f 100%);
  color: #1a0d13;
  font-size: 12px;
  font-weight: 800;
  padding: 4px 14px;
  border-radius: 999px;
  white-space: nowrap;
}
.price-name { font-size: 19px; font-weight: 800; color: var(--accent-strong); }
.price-old { color: #5a6572; font-size: 14px; margin-top: 8px; }
.price-old s { color: #7a8491; }
.price-value { font-size: 38px; font-weight: 800; color: var(--text); margin: 4px 0 16px; }
.price-value::after { content: " ₽"; font-size: 22px; }
.price-btn { padding: 12px 34px; width: 100%; max-width: 200px; }

/* Профиль */
.profile-panel {
  max-width: 720px;
  margin: 0 auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px 24px;
  text-align: center;
}
.profile-hint { color: var(--muted); font-size: 14px; margin-bottom: 18px; }
.profile-row { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; }
.profile-input {
  flex: 1 1 260px;
  max-width: 380px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  padding: 14px 18px;
  font-size: 16px;
  font-weight: 600;
  text-align: center;
  transition: border-color 0.15s;
}
.profile-input:focus { outline: none; border-color: var(--accent); }
.profile-btn { padding: 14px 30px; }
.profile-status { margin-top: 16px; font-size: 14px; color: var(--muted); }
.profile-status.ok { color: var(--accent-strong); }

/* Дашборд */
.dash-body { min-height: 100vh; display: flex; flex-direction: column; }
.dash-body .nav { flex-shrink: 0; }
.nav-links a.active { color: var(--accent-strong); font-weight: 700; }
.dash-layout { flex: 1; display: flex; max-width: 1080px; margin: 0 auto; width: 100%; padding: 26px 20px 60px; gap: 26px; align-items: flex-start; }

.dash-sidebar {
  flex-shrink: 0;
  width: 230px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 12px;
  position: sticky;
  top: 86px;
}
.sidebar-title { font-size: 13px; text-transform: uppercase; letter-spacing: 0.8px; color: var(--muted); padding: 0 10px 10px; }
.sidebar-menu { display: flex; flex-direction: column; gap: 2px; }
.sidebar-link {
  display: block;
  padding: 9px 12px;
  border-radius: 9px;
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
  transition: background 0.15s, color 0.15s;
}
.sidebar-link:hover:not(.disabled) { background: var(--surface-2); color: var(--text); }
.sidebar-link.active { background: linear-gradient(135deg, var(--accent) 0%, #c96d8f 100%); color: #1a0d13; font-weight: 700; }
.sidebar-link.disabled { color: #5a6572; cursor: not-allowed; }

.dash-content { flex: 1; min-width: 0; display: grid; gap: 20px; }
.dash-tab[hidden] { display: none; }
.download-actions { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 4px; }
.download-note { margin-top: 16px; }
.breadcrumbs { font-size: 13px; color: var(--muted); display: flex; gap: 8px; flex-wrap: wrap; }
.breadcrumbs a { color: var(--muted); text-decoration: none; }
.breadcrumbs a:hover { color: var(--accent-strong); }
.breadcrumbs .current { color: var(--accent-strong); }
.dash-greeting { font-size: clamp(24px, 3.5vw, 32px); font-weight: 800; color: var(--accent-strong); }

.dash-section { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px 24px; }
.dash-card-title { font-size: 17px; font-weight: 700; color: var(--text); margin-bottom: 16px; }
.dash-hint { color: var(--muted); font-size: 14px; margin-bottom: 14px; }

.info-list { display: grid; gap: 12px; }
.info-row { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding-bottom: 12px; border-bottom: 1px solid var(--border); }
.info-row:last-child { border-bottom: none; padding-bottom: 0; }
.info-label { color: var(--muted); font-size: 14px; }
.info-value { color: var(--text); font-size: 14px; font-weight: 600; word-break: break-all; text-align: right; }
.info-value.muted { color: var(--muted); font-weight: 400; }

.role-badge {
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--accent-strong);
  padding: 3px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}
.link-btn {
  background: none;
  border: none;
  color: var(--accent);
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  padding: 0;
}
.link-btn:hover { color: var(--accent-strong); text-decoration: underline; }

.key-row { display: flex; gap: 12px; flex-wrap: wrap; align-items: stretch; }
.form-input {
  flex: 1 1 260px;
  max-width: 320px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  padding: 14px 18px;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.5px;
  transition: border-color 0.15s;
}
.form-input:focus { outline: none; border-color: var(--accent); }
.key-btn { padding: 14px 26px; white-space: nowrap; }
.key-status { margin-top: 14px; font-size: 14px; color: var(--muted); }
.key-status.ok { color: var(--accent-strong); }
.key-status.err { color: #ff8080; }

@media (max-width: 820px) {
  .dash-layout { flex-direction: column; }
  .dash-sidebar { position: static; width: 100%; }
  .sidebar-menu { flex-direction: row; flex-wrap: wrap; }
  .sidebar-link { flex: 1 1 30%; text-align: center; }
}

/* Модалка */
.modal-overlay[hidden] { display: none !important; }
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 50;
  background: rgba(5, 8, 12, 0.75);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 30px;
  max-width: 420px;
  width: 100%;
  text-align: center;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}
.modal-title { font-size: 20px; font-weight: 800; color: var(--accent-strong); margin-bottom: 10px; }
.modal-text { color: var(--muted); font-size: 14px; margin-bottom: 22px; }
.modal-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* Футер */
.footer { border-top: 1px solid var(--border); padding: 26px 20px; text-align: center; }
.footer p { font-size: 13px; color: var(--muted); }
.footer-muted { margin-top: 6px; color: #6b7682; font-size: 12px; }

@media (max-width: 640px) {
  .nav-inner { flex-direction: column; }
  .nav-links { flex-wrap: wrap; justify-content: center; gap: 14px; }
  .hero { min-height: 72vh; padding-top: 40px; }
  .hero-logo { height: 90px; }
  .change { flex-direction: column; }
}
