/* NUMO VPN — публичный сайт. Тёмный футуристичный стиль, стекло + неон. */

/* ---------- Переменные ---------- */

:root {
  --bg: #07090f;
  --bg-2: #0b0e17;
  --card: rgba(255, 255, 255, 0.04);
  --card-strong: rgba(13, 17, 28, 0.92);
  --border: rgba(255, 255, 255, 0.08);
  --border-hover: rgba(255, 255, 255, 0.16);
  --accent-1: #22d3ee;
  --accent-2: #8b5cf6;
  --ok: #34d399;
  --warn: #fbbf24;
  --danger: #f87171;
  --text: #e7ecf5;
  --muted: #8b93a7;
  --grad: linear-gradient(135deg, var(--accent-1), var(--accent-2));
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, monospace;
  --radius: 18px;
  --nav-h: 64px;
}

/* ---------- База ---------- */

* { 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.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

body.modal-open { overflow: hidden; }

.container { max-width: 1100px; margin-inline: auto; padding-inline: 20px; }

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

h1, h2, h3 { line-height: 1.25; }
h2 { font-size: clamp(26px, 4vw, 36px); margin-bottom: 12px; }

.mono { font-family: var(--mono); }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.hidden { display: none !important; }

/* Якоря не прячутся под липким навбаром */
section[id] { scroll-margin-top: calc(var(--nav-h) + 16px); }

/* ---------- Стекло ---------- */

.glass {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

/* ---------- Кнопки ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 22px;
  border: 1px solid transparent;
  border-radius: 12px;
  font-family: var(--font);
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  text-align: center;
  transition: transform 0.2s ease, box-shadow 0.25s ease, border-color 0.2s ease, background 0.2s ease;
}

.btn:disabled { opacity: 0.55; cursor: default; }

.btn-primary {
  background: var(--grad);
  color: #07101d;
}
.btn-primary:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 6px 28px rgba(34, 211, 238, 0.35), 0 2px 14px rgba(139, 92, 246, 0.3);
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--border);
}
.btn-ghost:hover:not(:disabled) {
  border-color: var(--border-hover);
  box-shadow: 0 4px 20px rgba(34, 211, 238, 0.12);
}

.btn-big { padding: 14px 28px; font-size: 16px; border-radius: 14px; }
.btn-sm { padding: 8px 16px; font-size: 14px; }

/* ---------- Навбар ---------- */

.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid transparent;
  transition: background 0.3s ease, border-color 0.3s ease, backdrop-filter 0.3s ease;
}
.nav.scrolled {
  background: rgba(7, 9, 15, 0.72);
  border-bottom-color: var(--border);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.nav-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  min-height: var(--nav-h);
}

.logo { display: inline-flex; align-items: center; gap: 10px; color: var(--text); }
.logo-text { font-weight: 800; letter-spacing: 0.06em; font-size: 16px; white-space: nowrap; }

.nav-links { display: flex; gap: 22px; margin-left: auto; }
.nav-links a {
  color: var(--muted);
  font-size: 14.5px;
  font-weight: 500;
  transition: color 0.2s ease;
}
.nav-links a:hover { color: var(--text); }

.nav-auth { display: flex; align-items: center; }
.nav-user { display: flex; align-items: center; gap: 10px; }

.user-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  font-size: 14px;
  font-weight: 600;
  max-width: 180px;
}
/* Многоточие не работает на flex-контейнере — усечение на самом тексте */
#nav-user-name {
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.user-dot {
  width: 8px; height: 8px; flex: none;
  border-radius: 50%;
  background: var(--ok);
  box-shadow: 0 0 8px rgba(52, 211, 153, 0.8);
}

/* ---------- Hero: фон с сеткой и орбами ---------- */

.hero, .cabinet { position: relative; overflow: hidden; }

.hero-bg { position: absolute; inset: 0; pointer-events: none; }
.hero-bg::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(130, 150, 255, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(130, 150, 255, 0.06) 1px, transparent 1px);
  background-size: 44px 44px;
  -webkit-mask-image: radial-gradient(ellipse 85% 75% at 50% 25%, #000 25%, transparent 75%);
  mask-image: radial-gradient(ellipse 85% 75% at 50% 25%, #000 25%, transparent 75%);
}

.orb { position: absolute; border-radius: 50%; filter: blur(72px); opacity: 0.4; }
.orb-1 {
  width: 460px; height: 460px; top: -140px; left: -120px;
  background: radial-gradient(circle, rgba(34, 211, 238, 0.55), transparent 65%);
  animation: drift-a 19s ease-in-out infinite alternate;
}
.orb-2 {
  width: 520px; height: 520px; top: 60px; right: -180px;
  background: radial-gradient(circle, rgba(139, 92, 246, 0.5), transparent 65%);
  animation: drift-b 23s ease-in-out infinite alternate;
}
.orb-3 {
  width: 340px; height: 340px; bottom: -160px; left: 35%;
  background: radial-gradient(circle, rgba(34, 211, 238, 0.3), transparent 65%);
  animation: drift-a 27s ease-in-out infinite alternate-reverse;
}

@keyframes drift-a { to { transform: translate(70px, 45px) scale(1.08); } }
@keyframes drift-b { to { transform: translate(-60px, 50px) scale(0.94); } }

/* ---------- Hero: контент ---------- */

.hero-inner {
  position: relative;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  align-items: center;
  gap: 48px;
  padding-top: 72px;
  padding-bottom: 96px;
}

.hero-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; }
.chip {
  padding: 5px 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--accent-1);
  font-size: 12.5px;
  letter-spacing: 0.04em;
}

.hero-title {
  font-size: clamp(32px, 5.4vw, 54px);
  font-weight: 800;
  letter-spacing: -0.015em;
  margin-bottom: 18px;
}

/* Бегущий градиент в заголовке */
.grad-text {
  background: linear-gradient(90deg, var(--accent-1), var(--accent-2), var(--accent-1));
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  animation: grad-shift 6s linear infinite;
}
@keyframes grad-shift { to { background-position: 200% center; } }

.hero-sub {
  color: var(--muted);
  font-size: 17px;
  max-width: 520px;
  margin-bottom: 30px;
}

.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; }

/* Плавное появление hero при загрузке */
.hero-copy, .hero-panel { animation: rise-in 0.7s ease both; }
.hero-panel { animation-delay: 0.15s; }
@keyframes rise-in {
  from { opacity: 0; transform: translateY(22px); }
  to { opacity: 1; transform: none; }
}

/* ---------- Псевдотерминал ---------- */

.hero-panel { box-shadow: 0 24px 70px -30px rgba(34, 211, 238, 0.25); }

.term-head {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 13px 16px;
  border-bottom: 1px solid var(--border);
}
.term-dot { width: 11px; height: 11px; border-radius: 50%; }
.td-r { background: #f87171; } .td-y { background: #fbbf24; } .td-g { background: #34d399; }
.term-title { margin-left: 8px; color: var(--muted); font-size: 12px; }

.term-body { padding: 18px 20px 22px; font-size: 13.5px; line-height: 1.9; }
.t-dim { color: var(--muted); }
.t-ok { color: var(--ok); }
.t-cyan { color: var(--accent-1); }

.t-cursor::after {
  content: "▌";
  color: var(--accent-1);
  animation: blink 1.1s steps(2) infinite;
}
@keyframes blink { 50% { opacity: 0; } }

/* ---------- Секции ---------- */

.section { padding: 84px 0; position: relative; }
.section:nth-of-type(even) { background: var(--bg-2); }

.kicker {
  color: var(--accent-1);
  font-size: 12.5px;
  letter-spacing: 0.12em;
  text-transform: lowercase;
  margin-bottom: 10px;
}
.section-sub { color: var(--muted); margin-bottom: 8px; max-width: 560px; }

/* Reveal через IntersectionObserver */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.visible { opacity: 1; transform: none; }

/* ---------- Возможности ---------- */

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 36px;
}

.feature-card {
  padding: 26px 24px;
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.3s ease;
}
.feature-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-hover);
  box-shadow: 0 14px 44px -18px rgba(34, 211, 238, 0.35);
}
.feature-icon {
  width: 46px; height: 46px;
  display: flex; align-items: center; justify-content: center;
  font-size: 22px;
  border-radius: 13px;
  background: rgba(34, 211, 238, 0.08);
  border: 1px solid rgba(34, 211, 238, 0.18);
  margin-bottom: 16px;
}
.feature-card h3 { font-size: 17px; margin-bottom: 6px; }
.feature-card p { color: var(--muted); font-size: 14.5px; }

/* ---------- Тарифы ---------- */

.plans-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 36px;
  align-items: stretch;
}

.plans-loading, .plans-error { grid-column: 1 / -1; color: var(--muted); text-align: center; padding: 36px 0; }
.plans-error { display: flex; flex-direction: column; align-items: center; gap: 14px; }

.plan {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 28px 24px 24px;
  transition: transform 0.25s ease, box-shadow 0.3s ease, border-color 0.25s ease;
}
.plan:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 50px -20px rgba(139, 92, 246, 0.45);
}

/* Популярный тариф — градиентная рамка */
.plan.popular {
  border: 1px solid transparent;
  background:
    linear-gradient(var(--card-strong), var(--card-strong)) padding-box,
    var(--grad) border-box;
  box-shadow: 0 12px 50px -18px rgba(139, 92, 246, 0.5);
}

.plan-tag {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  padding: 4px 14px;
  border-radius: 999px;
  background: var(--grad);
  color: #07101d;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.plan-badge {
  position: absolute;
  top: 16px;
  right: 16px;
  padding: 3px 10px;
  border-radius: 999px;
  background: rgba(52, 211, 153, 0.12);
  border: 1px solid rgba(52, 211, 153, 0.3);
  color: var(--ok);
  font-size: 12.5px;
  font-weight: 700;
}

.plan-title { font-size: 17px; font-weight: 700; }
.plan-days { color: var(--muted); font-size: 13.5px; }

.plan-price {
  font-family: var(--mono);
  font-size: 36px;
  font-weight: 700;
  margin-top: 14px;
  letter-spacing: -0.02em;
}
.plan-price small { font-size: 16px; color: var(--muted); font-weight: 500; }
.plan-price .plan-old {
  display: block;
  font-size: 15px;
  font-weight: 500;
  color: var(--muted);
  text-decoration: line-through;
  margin-bottom: -4px;
}
.plan-permonth { color: var(--muted); font-size: 13.5px; }
.plan-devices { color: var(--muted); font-size: 13px; margin-bottom: 18px; }

.plan .btn { margin-top: auto; width: 100%; }

.pricing-note { margin-top: 26px; text-align: center; color: var(--muted); }

/* ---------- Подключение ---------- */

.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 36px;
}

.step-card { padding: 26px 24px; }
.step-num {
  font-size: 13px;
  color: var(--accent-1);
  letter-spacing: 0.14em;
  margin-bottom: 12px;
}
.step-card h3 { font-size: 17px; margin-bottom: 8px; }
.step-card p { color: var(--muted); font-size: 14.5px; }

.store-links { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; }
.store-link {
  display: flex;
  flex-direction: column;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font-size: 14px;
  font-weight: 600;
  transition: border-color 0.2s ease, box-shadow 0.25s ease;
}
.store-link:hover {
  border-color: var(--border-hover);
  box-shadow: 0 4px 18px rgba(34, 211, 238, 0.12);
}
.store-link small { color: var(--muted); font-weight: 400; font-size: 12.5px; }

/* ---------- FAQ ---------- */

.faq { display: flex; flex-direction: column; gap: 12px; margin-top: 32px; max-width: 760px; }

.faq details { overflow: hidden; }
.faq summary {
  list-style: none;
  cursor: pointer;
  padding: 18px 22px;
  font-weight: 600;
  font-size: 15.5px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  transition: color 0.2s ease;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  font-family: var(--mono);
  font-size: 20px;
  color: var(--accent-1);
  flex: none;
  transition: transform 0.25s ease;
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details[open] summary { color: var(--accent-1); }
.faq details p { padding: 0 22px 18px; color: var(--muted); font-size: 14.5px; }

/* ---------- Футер ---------- */

.footer { border-top: 1px solid var(--border); padding: 40px 0; background: var(--bg-2); }
.footer-inner {
  display: flex;
  align-items: center;
  gap: 22px;
  flex-wrap: wrap;
}
.footer-tagline { color: var(--muted); font-size: 14px; flex: 1; min-width: 220px; }
.footer-bot { font-size: 14.5px; font-weight: 600; }
.footer-bot:hover { text-decoration: underline; }
.footer-legal { display: flex; gap: 18px; flex-wrap: wrap; font-size: 14px; }
.footer-legal a { color: var(--muted); }
.footer-legal a:hover { color: var(--text); text-decoration: underline; }

/* ---------- Личный кабинет ---------- */

.cabinet-inner {
  position: relative;
  padding-top: 56px;
  padding-bottom: 72px;
  display: flex;
  flex-direction: column;
  gap: 22px;
  max-width: 720px;
}

.cab-hello { font-size: clamp(26px, 4vw, 36px); }

.status-card { padding: 24px; display: flex; flex-direction: column; gap: 18px; }

.status-row { display: flex; align-items: center; gap: 16px; }
.status-dot {
  width: 14px; height: 14px; flex: none;
  border-radius: 50%;
  background: var(--muted);
}
.status-title { font-size: 18px; font-weight: 700; }
.status-sub { color: var(--muted); font-size: 14px; }
.status-actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* Состояния подписки: свечение карточки и точки */
.status-card.st-ok {
  border-color: rgba(52, 211, 153, 0.3);
  box-shadow: 0 0 56px -16px rgba(52, 211, 153, 0.4);
}
.status-card.st-ok .status-dot { background: var(--ok); box-shadow: 0 0 12px rgba(52, 211, 153, 0.9); }

.status-card.st-warn {
  border-color: rgba(251, 191, 36, 0.3);
  box-shadow: 0 0 56px -16px rgba(251, 191, 36, 0.35);
}
.status-card.st-warn .status-dot { background: var(--warn); box-shadow: 0 0 12px rgba(251, 191, 36, 0.9); }

.btn-trial { align-self: flex-start; }

.cab-connect { padding: 24px; display: flex; flex-direction: column; gap: 12px; }
.cab-connect h3 { font-size: 18px; }
.cab-connect .btn-primary { align-self: flex-start; }

.copy-row { display: flex; gap: 8px; }
.copy-row input {
  flex: 1;
  min-width: 0;
  padding: 11px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.3);
  color: var(--text);
  font-size: 13px;
}
.copy-row input:focus { outline: none; border-color: var(--accent-1); }
.copy-row .btn { flex: none; white-space: nowrap; }

.cab-history h3 { margin-bottom: 12px; font-size: 18px; }
.history-list { display: flex; flex-direction: column; gap: 8px; }

.h-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 13px 16px;
  border: 1px solid var(--border);
  border-radius: 13px;
  background: var(--card);
}
.h-amount { font-family: var(--mono); font-weight: 700; font-size: 15px; }
.h-meta { color: var(--muted); font-size: 12.5px; }
.h-status { font-size: 12.5px; font-weight: 700; padding: 3px 10px; border-radius: 999px; flex: none; }
.h-status.paid { color: var(--ok); background: rgba(52, 211, 153, 0.1); }
.h-status.pending { color: var(--warn); background: rgba(251, 191, 36, 0.1); }
.h-status.canceled { color: var(--muted); background: rgba(255, 255, 255, 0.06); }

.empty { color: var(--muted); font-size: 14px; padding: 14px 4px; }

.btn-logout { align-self: flex-start; }

/* ---------- Модалы ---------- */

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(4, 6, 11, 0.7);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  animation: fade-in 0.25s ease;
  overflow-y: auto;
}
@keyframes fade-in { from { opacity: 0; } }

.modal {
  position: relative;
  width: 100%;
  max-width: 420px;
  padding: 28px 26px;
  background: var(--card-strong);
  margin: auto;
  animation: rise-in 0.3s ease;
}
.modal h3 { font-size: 20px; margin-bottom: 14px; padding-right: 30px; }

.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 34px; height: 34px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--muted);
  font-size: 14px;
  cursor: pointer;
  transition: color 0.2s ease, border-color 0.2s ease;
}
.modal-close:hover { color: var(--text); border-color: var(--border-hover); }

/* ---------- Модал входа ---------- */

.login-message {
  padding: 10px 14px;
  border-radius: 10px;
  background: rgba(248, 113, 113, 0.1);
  border: 1px solid rgba(248, 113, 113, 0.3);
  color: var(--danger);
  font-size: 14px;
  margin-bottom: 14px;
}

.login-loading { display: flex; align-items: center; gap: 10px; color: var(--muted); padding: 18px 0; }

.login-body { display: flex; flex-direction: column; gap: 14px; }

.login-code-entry { display: flex; flex-direction: column; gap: 14px; padding-top: 4px; }

.login-code-input {
  width: 100%;
  font-size: 38px;
  font-weight: 700;
  letter-spacing: 0.35em;
  text-align: center;
  text-transform: uppercase;
  padding: 16px 10px 16px calc(10px + 0.35em); /* компенсация letter-spacing для центровки */
  border: 1px solid var(--border);
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.3);
  color: var(--accent-1);
  text-shadow: 0 0 24px rgba(34, 211, 238, 0.45);
  caret-color: var(--accent-1);
  outline: none;
}
.login-code-input:focus { border-color: var(--accent-1); box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.15); }
.login-code-input::placeholder { color: rgba(231, 236, 245, 0.25); text-shadow: none; }

.login-code-error { color: var(--danger); font-size: 14px; }

.login-hint { color: var(--muted); font-size: 13.5px; }

.login-qr { text-align: center; }
.login-qr img {
  width: 180px;
  height: 180px;
  border-radius: 14px;
  background: #fff;
  padding: 8px;
  margin-bottom: 6px;
}

.login-status { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 14px; justify-content: center; }

.login-expired, .login-error { display: flex; flex-direction: column; gap: 14px; padding: 10px 0; }
.login-error p { color: var(--danger); font-size: 14.5px; }

/* ---------- Модал оплаты ---------- */

.pay-plan { font-size: 14.5px; margin-bottom: 16px; }

.pay-methods { display: flex; flex-direction: column; gap: 10px; margin-bottom: 18px; }

.method-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 16px;
  border: 1px solid var(--border);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.04);
  cursor: pointer;
  transition: border-color 0.2s ease, box-shadow 0.25s ease;
}
.method-card:hover { border-color: var(--border-hover); }
.method-card input { position: absolute; opacity: 0; pointer-events: none; }
.method-card.selected {
  border-color: var(--accent-1);
  box-shadow: 0 0 0 1px var(--accent-1), 0 4px 22px rgba(34, 211, 238, 0.2);
}
.method-icon { font-size: 20px; }
.method-label { font-weight: 600; font-size: 15px; }
.method-sub { color: var(--muted); font-size: 12.5px; }

#modal-pay .btn-big { width: 100%; }
.pay-status { margin-top: 14px; color: var(--muted); font-size: 14px; text-align: center; }
.pay-empty { color: var(--muted); font-size: 14.5px; padding: 8px 0 4px; }

/* Промокод в модалах оплаты/продления */
#modal-pay .copy-row, #modal-renew .copy-row { margin-bottom: 12px; }
#pay-promo, #renew-promo { text-transform: uppercase; }
#pay-promo::placeholder, #renew-promo::placeholder { text-transform: none; }
.promo-hint { font-size: 13.5px; color: var(--danger); margin: -4px 0 12px; }
.promo-hint.ok { color: var(--ok); }

/* ---------- Продление по нику ---------- */

.renew-link {
  display: inline-block;
  margin-top: 16px;
  padding: 0;
  border: none;
  background: none;
  color: var(--muted);
  font-family: var(--font);
  font-size: 13.5px;
  text-align: left;
  cursor: pointer;
  text-decoration: underline;
  text-decoration-color: rgba(139, 146, 167, 0.4);
  text-underline-offset: 3px;
  transition: color 0.2s ease;
}
.renew-link:hover { color: var(--accent-1); }
#login-renew-link { margin-top: 18px; }

.renew-intro { margin-bottom: 16px; }
.renew-lookup-row { margin-bottom: 12px; }
.renew-account {
  font-size: 14px;
  color: var(--ok);
  margin-bottom: 14px;
}
.renew-h { font-size: 13.5px; color: var(--muted); font-weight: 600; margin-bottom: 8px; }
#modal-renew .pay-methods { margin-bottom: 14px; }
#modal-renew .btn-big { width: 100%; }
#modal-renew .method-sub s, #modal-renew s.method-sub { text-decoration: line-through; }

/* ---------- Оверлей результата оплаты ---------- */

.overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(4, 6, 11, 0.92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.overlay-card {
  width: 100%;
  max-width: 400px;
  padding: 36px 30px;
  text-align: center;
  background: var(--card-strong);
}
.overlay-icon { font-size: 42px; margin-bottom: 16px; display: flex; justify-content: center; }
.overlay-card h3 { font-size: 20px; margin-bottom: 8px; }
.overlay-actions { display: flex; flex-direction: column; gap: 10px; margin-top: 22px; }

/* ---------- Спиннер и тост ---------- */

.spinner {
  width: 18px; height: 18px; flex: none;
  border: 2px solid rgba(255, 255, 255, 0.15);
  border-top-color: var(--accent-1);
  border-radius: 50%;
  display: inline-block;
  animation: spin 0.8s linear infinite;
}
.spinner-big { width: 42px; height: 42px; border-width: 3px; }
@keyframes spin { to { transform: rotate(360deg); } }

.toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%);
  z-index: 300;
  max-width: min(92vw, 420px);
  padding: 12px 20px;
  border-radius: 13px;
  background: rgba(13, 17, 28, 0.95);
  border: 1px solid var(--border-hover);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  font-size: 14.5px;
  text-align: center;
  animation: toast-in 0.3s ease;
}
@keyframes toast-in { from { opacity: 0; transform: translate(-50%, 12px); } }

/* ---------- Адаптив ---------- */

@media (max-width: 920px) {
  .hero-inner { grid-template-columns: 1fr; padding-top: 48px; padding-bottom: 64px; gap: 36px; }
  .hero-panel { max-width: 480px; }
  .features-grid, .steps-grid, .plans-grid { grid-template-columns: repeat(2, 1fr); }
  .plan.popular { transform: none; }
}

@media (max-width: 640px) {
  /* Компактное меню: ссылки переезжают на вторую строку, скроллятся горизонтально */
  .nav-inner { flex-wrap: wrap; gap: 8px 16px; padding-top: 10px; padding-bottom: 10px; }
  .nav-auth { margin-left: auto; }
  .nav-links {
    order: 3;
    width: 100%;
    margin-left: 0;
    gap: 18px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 2px;
  }
  .nav-links::-webkit-scrollbar { display: none; }
  .nav-links a { white-space: nowrap; }
  .nav { background: rgba(7, 9, 15, 0.72); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border-bottom-color: var(--border); }

  .section { padding: 56px 0; }
  .features-grid, .steps-grid, .plans-grid { grid-template-columns: 1fr; }
  .hero-cta .btn { flex: 1; }
  .copy-row { flex-direction: column; }
  .cab-connect .btn-primary, .btn-trial, .btn-logout { align-self: stretch; }
  .status-actions .btn { flex: 1; }
  .footer-inner { flex-direction: column; align-items: flex-start; gap: 12px; }
  .login-code-input { font-size: 30px; }
  .login-qr img { width: 150px; height: 150px; }
}

/* ---------- Уважение к prefers-reduced-motion ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
  .grad-text {
    /* статичный градиент вместо бегущего */
    animation: none;
    background-position: 50% center;
  }
}
