/* ── Дизайн-токены ──────────────────────────────────────────────────────── */
:root {
  --bg: #0a0f0d;
  --bg-elev: #111a15;
  --bg-elev-2: #1c2b22;
  --primary: #2d6a4f;
  --primary-hover: #348062;
  --primary-light: #40916c;
  --accent: #d4a017;
  --accent-light: #f0c14b;
  --connected: #52b788;
  --error: #e63946;
  --error-bg: rgba(230,57,70,.10);
  --text: #f1f8f4;
  --text-2: #a8c5b0;
  --text-3: #5a7a65;
  --border: rgba(255,255,255,.08);
  --border-strong: rgba(255,255,255,.16);
  --radius-lg: 18px;
  --radius-md: 14px;
  --radius-sm: 10px;
  --shadow-1: 0 8px 24px rgba(0,0,0,.35);
  --shadow-2: 0 18px 48px rgba(0,0,0,.45);
  --grad-primary: linear-gradient(135deg, #2d6a4f, #40916c);
  --grad-accent:  linear-gradient(135deg, #d4a017, #f0c14b);
  --glass: rgba(255,255,255,.04);
  --glass-strong: rgba(255,255,255,.06);
  --container: 1180px;
  --transition: .25s cubic-bezier(.4,.0,.2,1);
}

/* ── Сброс / база ───────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font: 16px/1.55 -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
       'Helvetica Neue', Arial, 'Noto Sans', sans-serif;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img, svg { max-width: 100%; display: block; }
a { color: var(--primary-light); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--accent); }

input, button, select, textarea {
  font: inherit;
  color: inherit;
}

input[type=email], input[type=password], input[type=text] {
  width: 100%;
  padding: 13px 16px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: rgba(255,255,255,.03);
  color: var(--text);
  transition: border-color var(--transition), background var(--transition);
}
input::placeholder { color: var(--text-3); }
input:focus {
  outline: none;
  border-color: var(--primary-light);
  background: rgba(255,255,255,.05);
}

/* ── Кнопки ─────────────────────────────────────────────────────────────── */
button, .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border: 0;
  border-radius: var(--radius-sm);
  background: var(--grad-primary);
  color: #fff;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition), filter var(--transition);
  position: relative;
  overflow: hidden;
}
button:hover, .btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-1);
  filter: brightness(1.05);
}
button:active, .btn:active { transform: translateY(0); }
button:disabled { opacity: .55; cursor: not-allowed; transform: none; box-shadow: none; }
.btn-accent { background: var(--grad-accent); color: #221908; }
.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border-strong);
}
.btn-ghost:hover { background: var(--glass-strong); color: var(--text); border-color: var(--primary-light); }
.btn-lg { padding: 14px 28px; font-size: 16px; }

/* ── Контейнер / layout ─────────────────────────────────────────────────── */
.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
  width: 100%;
}

/* ── Декоративный задник ────────────────────────────────────────────────── */
.bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}
.bg-glow {
  position: absolute;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  filter: blur(120px);
  opacity: .18;
}
.bg-glow-1 {
  background: var(--primary-light);
  top: -200px;
  left: -200px;
  animation: float-1 20s ease-in-out infinite;
}
.bg-glow-2 {
  background: var(--accent);
  bottom: -200px;
  right: -200px;
  animation: float-2 22s ease-in-out infinite;
}
.bg-grid {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(255,255,255,.06) 1px, transparent 1px);
  background-size: 32px 32px;
  mask-image: radial-gradient(ellipse at center, black 30%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse at center, black 30%, transparent 80%);
}
@keyframes float-1 {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(60px, 80px); }
}
@keyframes float-2 {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(-60px, -50px); }
}

/* ── Хедер ──────────────────────────────────────────────────────────────── */
.hdr {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10,15,13,.7);
  backdrop-filter: blur(14px) saturate(160%);
  -webkit-backdrop-filter: blur(14px) saturate(160%);
  border-bottom: 1px solid var(--border);
}
.hdr-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 14px 24px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 18px;
  color: var(--text);
  letter-spacing: -.01em;
}
.brand:hover { color: var(--text); }
.brand-mark { width: 28px; height: 28px; flex-shrink: 0; }
.nav {
  margin-left: auto;
  display: flex;
  gap: 8px;
  align-items: center;
}
.nav > a:not(.btn-ghost) {
  color: var(--text-2);
  font-weight: 500;
  font-size: 15px;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  transition: color var(--transition), background var(--transition);
}
.nav > a:not(.btn-ghost):hover { color: var(--text); background: var(--glass); }

/* ── Main ──────────────────────────────────────────────────────────────── */
main {
  flex: 1;
  padding: 40px 0 60px;
}

/* ── Hero ──────────────────────────────────────────────────────────────── */
.hero {
  padding: 60px 24px 48px;
  text-align: center;
  max-width: 880px;
  margin: 0 auto;
}
.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--glass);
  border: 1px solid var(--border-strong);
  font-size: 13px;
  color: var(--text-2);
  margin-bottom: 18px;
  animation: fade-in .8s ease-out both;
}
.hero-eyebrow .dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--connected);
  box-shadow: 0 0 12px var(--connected);
  animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: .55; transform: scale(.85); }
}
.hero h1 {
  font-size: clamp(36px, 6vw, 56px);
  line-height: 1.05;
  margin: 0 0 18px;
  letter-spacing: -.025em;
  font-weight: 700;
  background: linear-gradient(180deg, #fff 30%, rgba(255,255,255,.65));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: fade-in .8s ease-out .1s both;
}
.hero p {
  color: var(--text-2);
  font-size: 19px;
  max-width: 620px;
  margin: 0 auto 32px;
  animation: fade-in .8s ease-out .2s both;
}
.hero-cta {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  animation: fade-in .8s ease-out .3s both;
}
@keyframes fade-in {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Features ──────────────────────────────────────────────────────────── */
.features {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  margin: 56px 0;
}
.feature {
  background: var(--glass);
  border: 1px solid var(--border);
  padding: 24px;
  border-radius: var(--radius-lg);
  transition: border-color var(--transition), transform var(--transition), background var(--transition);
}
.feature:hover {
  border-color: var(--border-strong);
  background: var(--glass-strong);
  transform: translateY(-2px);
}
.feature .ico {
  width: 44px; height: 44px;
  border-radius: var(--radius-sm);
  background: var(--grad-primary);
  display: flex; align-items: center; justify-content: center;
  color: #fff;
  margin-bottom: 14px;
}
.feature .ico svg { width: 22px; height: 22px; }
.feature h3 { margin: 0 0 6px; font-size: 17px; font-weight: 600; }
.feature p { margin: 0; color: var(--text-2); font-size: 14.5px; line-height: 1.5; }

/* ── Section ───────────────────────────────────────────────────────────── */
.section { margin: 60px 0; }
.section-head { text-align: center; max-width: 640px; margin: 0 auto 36px; }
.section-head h2 {
  font-size: clamp(28px, 4vw, 40px);
  margin: 0 0 12px;
  letter-spacing: -.02em;
  font-weight: 700;
}
.section-head p { color: var(--text-2); font-size: 17px; margin: 0; }

/* ── Locations grid ────────────────────────────────────────────────────── */
.locations {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}
.loc-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  border-radius: var(--radius-md);
  background: var(--glass);
  border: 1px solid var(--border);
  transition: var(--transition);
  cursor: default;
}
.loc-card:hover {
  background: var(--glass-strong);
  border-color: var(--primary-light);
  transform: translateY(-2px);
}
.loc-flag {
  width: 44px; height: 32px;
  border-radius: 6px;
  overflow: hidden;
  flex-shrink: 0;
  border: 1px solid var(--border-strong);
  display: flex; align-items: center; justify-content: center;
  background: var(--bg-elev-2);
}
.loc-flag svg { width: 100%; height: 100%; }
.loc-info { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.loc-info .name { font-weight: 600; font-size: 15px; }
.loc-info .city { font-size: 12px; color: var(--text-3); }
.loc-info .ping { font-size: 11px; color: var(--connected); margin-top: 2px; }

/* ── Tariffs ───────────────────────────────────────────────────────────── */
.tariffs-tabs {
  display: inline-flex;
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 4px;
  margin: 0 auto 32px;
  gap: 4px;
}
.tariffs-tabs > div { display: flex; gap: 4px; }
.tariffs-tabs button {
  padding: 8px 18px;
  background: transparent;
  color: var(--text-2);
  font-size: 14px;
  border-radius: 999px;
  font-weight: 500;
  box-shadow: none;
}
.tariffs-tabs button:hover { color: var(--text); transform: none; box-shadow: none; }
.tariffs-tabs button.active {
  background: var(--text);
  color: var(--bg);
}

.tariffs-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}
.tariff {
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: var(--transition);
  overflow: hidden;
}
.tariff::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(180deg, rgba(212,160,23,.05), transparent 40%);
  opacity: 0;
  transition: opacity var(--transition);
  pointer-events: none;
}
.tariff:hover { transform: translateY(-4px); border-color: var(--primary-light); box-shadow: var(--shadow-1); }
.tariff:hover::before { opacity: 1; }
.tariff.popular { border-color: var(--accent); }
.tariff.popular::after {
  content: "Хит";
  position: absolute;
  top: 16px; right: 16px;
  background: var(--grad-accent);
  color: #221908;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 999px;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.tariff h3 { margin: 0 0 6px; font-size: 14px; color: var(--text-3); font-weight: 500; text-transform: uppercase; letter-spacing: .04em; }
.tariff .price-line { display: flex; align-items: baseline; gap: 4px; margin-bottom: 4px; }
.tariff .price { font-size: 38px; font-weight: 700; letter-spacing: -.02em; line-height: 1; }
.tariff .currency { font-size: 18px; color: var(--text-3); font-weight: 500; }
.tariff .per-month { font-size: 13px; color: var(--text-3); margin-bottom: 16px; }
.tariff ul { list-style: none; padding: 0; margin: 16px 0 22px; color: var(--text-2); font-size: 14px; }
.tariff ul li { padding: 5px 0; display: flex; align-items: center; gap: 8px; }
.tariff ul li svg { width: 16px; height: 16px; color: var(--connected); flex-shrink: 0; }
.tariff button { margin-top: auto; width: 100%; }

/* ── Cards / forms ─────────────────────────────────────────────────────── */
.card {
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  backdrop-filter: blur(8px);
}
.card + .card { margin-top: 16px; }
h2 { letter-spacing: -.01em; }

form .row { margin-bottom: 16px; }
form label { display: block; font-size: 13px; color: var(--text-2); margin-bottom: 6px; }
form button { width: 100%; }

.notice {
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  margin-bottom: 16px;
  font-size: 14px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.notice.error { background: var(--error-bg); color: var(--error); border: 1px solid rgba(230,57,70,.3); }
.notice.success { background: rgba(82,183,136,.10); color: var(--connected); border: 1px solid rgba(82,183,136,.3); }
.notice.info { background: rgba(212,160,23,.10); color: var(--accent-light); border: 1px solid rgba(212,160,23,.3); }

/* ── Key reveal ────────────────────────────────────────────────────────── */
.key-display {
  font-family: ui-monospace, 'SF Mono', 'Cascadia Mono', monospace;
  font-size: 24px;
  letter-spacing: .15em;
  background: var(--bg-elev-2);
  padding: 18px 20px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--primary);
  text-align: center;
  word-break: break-all;
  font-weight: 600;
  color: var(--accent-light);
}

/* ── Subscriptions list ────────────────────────────────────────────────── */
.subs-list { display: flex; flex-direction: column; gap: 10px; }
.sub-item {
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px 18px;
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}
.sub-item .key-pref { font-family: ui-monospace, monospace; font-size: 16px; color: var(--accent); font-weight: 600; }
.sub-item .meta { color: var(--text-2); font-size: 13px; }
.sub-item .badge { font-size: 11px; padding: 3px 10px; border-radius: 999px; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; }
.badge.active { background: rgba(82,183,136,.15); color: var(--connected); }
.badge.expired { background: rgba(230,57,70,.15); color: var(--error); }
.badge.revoked { background: rgba(90,122,101,.15); color: var(--text-3); }

/* ── Legal ─────────────────────────────────────────────────────────────── */
.legal { max-width: 760px; margin: 0 auto; }
.legal h1 { font-size: 32px; letter-spacing: -.02em; margin-bottom: 4px; }
.legal h2 { margin-top: 32px; font-size: 22px; }
.legal h3 { margin-top: 22px; font-size: 16px; color: var(--text-2); }
.legal p, .legal ul { color: var(--text-2); font-size: 15.5px; line-height: 1.7; }
.legal ul li { margin-bottom: 8px; }

/* ── Footer ────────────────────────────────────────────────────────────── */
.ftr {
  border-top: 1px solid var(--border);
  padding: 48px 0 24px;
  margin-top: 80px;
  background: rgba(0,0,0,.2);
}
.ftr-inner {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1.4fr 1.4fr;
  gap: 32px;
  margin-bottom: 32px;
}
.ftr-col h4 { margin: 0 0 14px; font-size: 14px; color: var(--text); font-weight: 600; }
.ftr-col a {
  display: block;
  color: var(--text-3);
  font-size: 14px;
  padding: 4px 0;
}
.ftr-col a:hover { color: var(--accent); }
.ftr-col p { color: var(--text-3); font-size: 14px; margin: 0; }
.brand-ftr { font-size: 16px; margin-bottom: 12px; }
.muted { color: var(--text-3); font-size: 14px; }
.ftr-bottom {
  border-top: 1px solid var(--border);
  padding-top: 20px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 13px;
  color: var(--text-3);
}

/* ── Helpers ───────────────────────────────────────────────────────────── */
.kv {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 10px 14px;
  font-size: 14px;
  align-items: center;
}
.kv .k { color: var(--text-2); }
.kv .v { color: var(--text); font-weight: 500; }
table.simple { width: 100%; border-collapse: collapse; font-size: 14px; }
table.simple thead th { text-align: left; color: var(--text-3); padding: 10px 14px; font-weight: 500; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; border-bottom: 1px solid var(--border); }
table.simple tbody td { padding: 12px 14px; border-bottom: 1px solid var(--border); }

/* ── Анимация появления для сеток ──────────────────────────────────────── */
.fade-list > * {
  opacity: 0;
  transform: translateY(8px);
  animation: fade-in .55s ease-out both;
}
.fade-list > *:nth-child(1) { animation-delay: .05s; }
.fade-list > *:nth-child(2) { animation-delay: .10s; }
.fade-list > *:nth-child(3) { animation-delay: .15s; }
.fade-list > *:nth-child(4) { animation-delay: .20s; }
.fade-list > *:nth-child(5) { animation-delay: .25s; }
.fade-list > *:nth-child(6) { animation-delay: .30s; }
.fade-list > *:nth-child(7) { animation-delay: .35s; }
.fade-list > *:nth-child(8) { animation-delay: .40s; }
.fade-list > *:nth-child(n+9) { animation-delay: .45s; }

/* ── Mobile ────────────────────────────────────────────────────────────── */
@media (max-width: 720px) {
  .hero { padding: 40px 16px 32px; }
  .hero h1 { font-size: 32px; }
  .hero p { font-size: 16px; }
  .hdr-inner { gap: 12px; padding: 12px 16px; }
  .nav { gap: 4px; }
  .nav > a { font-size: 13px; padding: 6px 10px; }
  .container { padding: 0 16px; }
  main { padding: 24px 0 40px; }
  .ftr-inner { grid-template-columns: 1fr; gap: 24px; }
  .section { margin: 40px 0; }
  .feature, .card { padding: 20px; }
  .tariff { padding: 22px 18px; }
}

@media (max-width: 480px) {
  .nav > a:not(.btn-ghost) { display: none; }
}


/* ── Payment return loader ───────────────────────────────────────────── */
.loader {
  width: 36px;
  height: 36px;
  border: 3px solid rgba(255, 255, 255, 0.12);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}


/* ── Download page ───────────────────────────────────────────────────── */
.downloads {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 18px;
  margin: 8px 0 56px;
}
.dl-card {
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: relative;
  transition: var(--transition);
}
.dl-card:hover { border-color: var(--primary-light); transform: translateY(-2px); box-shadow: var(--shadow-1); }
.dl-card.recommended { border-color: var(--accent); }
.dl-card.recommended::after {
  content: "Рекомендуем";
  position: absolute;
  top: 16px; right: 16px;
  background: var(--grad-accent);
  color: #221908;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 999px;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.dl-card.dl-card-soon { opacity: .65; }
.dl-card.dl-card-soon:hover { transform: none; box-shadow: none; border-color: var(--border); }
.dl-icon {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
}
.dl-icon svg { width: 30px; height: 30px; }
.dl-icon-android { background: linear-gradient(135deg, #3DDC84, #2db567); }
.dl-icon-windows { background: linear-gradient(135deg, #00a4ef, #0078d4); }
.dl-icon-ios     { background: linear-gradient(135deg, #555, #2a2a2a); }
.dl-card h3 { margin: 0; font-size: 22px; }
.dl-os { color: var(--text-3); font-size: 13px; margin: -8px 0 0; }
.dl-features {
  list-style: none;
  padding: 0;
  margin: 6px 0 14px;
  font-size: 14px;
  color: var(--text-2);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.dl-features li { display: flex; align-items: center; gap: 8px; }
.dl-features svg { width: 14px; height: 14px; color: var(--connected); flex-shrink: 0; }
.dl-card .btn, .dl-card button { width: 100%; }
.dl-hint { font-size: 12px; margin: 4px 0 0; }

.dl-howto { margin-top: 32px; }
.howto-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}
.howto-step {
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 22px 20px;
  position: relative;
}
.howto-step .step-num {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--grad-primary);
  color: #fff;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  margin-bottom: 10px;
}
.howto-step h4 { margin: 0 0 6px; font-size: 16px; }
.howto-step p { margin: 0; color: var(--text-2); font-size: 14.5px; line-height: 1.5; }
