:root {
  --bg: #070915;
  --bg-soft: #101529;
  --card: rgba(19, 25, 48, 0.82);
  --card-border: rgba(129, 140, 248, 0.22);
  --text: #eef2ff;
  --muted: #a8b0cf;
  --primary: #5b7cfa;
  --primary-2: #8b5cf6;
  --success: #34d399;
  --warning: #fbbf24;
  --danger: #fb7185;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.36);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background:
    radial-gradient(circle at 15% 10%, rgba(91, 124, 250, 0.26), transparent 28rem),
    radial-gradient(circle at 85% 0%, rgba(139, 92, 246, 0.22), transparent 26rem),
    var(--bg);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.page-shell {
  width: min(1120px, calc(100% - 32px));
  min-height: 100vh;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
}

.topbar, .footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 24px 0;
}

.brand, .nav-links a, .muted-link {
  color: var(--text);
  text-decoration: none;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
  box-shadow: 0 12px 32px rgba(91, 124, 250, 0.32);
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 14px;
}

.nav-links a, .muted-link {
  color: var(--muted);
}

.nav-links a:hover, .muted-link:hover { color: var(--text); }

main { flex: 1; }

.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.65fr);
  gap: 28px;
  align-items: center;
  padding: 72px 0;
}

.hero-content, .card, .hero-card {
  position: relative;
  border: 1px solid var(--card-border);
  background: var(--card);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.hero-content {
  padding: clamp(28px, 6vw, 64px);
  border-radius: 34px;
  overflow: hidden;
}

.hero-glow {
  position: absolute;
  inset: auto 20% 18% auto;
  width: 280px;
  height: 280px;
  border-radius: 999px;
  background: rgba(91, 124, 250, 0.2);
  filter: blur(80px);
}

.hero h1, .section-heading h1, .support-card h1, .error-card h1 {
  margin: 0;
  font-size: clamp(2.4rem, 7vw, 5.5rem);
  line-height: 0.95;
}

.lead, .section-heading p, .hero-card p, .support-card p, .error-card p, .login-card p {
  color: var(--muted);
  line-height: 1.7;
}

.lead { max-width: 680px; font-size: 1.15rem; }

.eyebrow {
  margin: 0 0 12px;
  color: #9fb3ff;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.actions, .action-list {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  border: 0;
  border-radius: 14px;
  padding: 12px 18px;
  color: var(--text);
  font: inherit;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

.btn:hover { transform: translateY(-1px); }

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
  box-shadow: 0 14px 38px rgba(91, 124, 250, 0.32);
}

.btn-secondary { background: rgba(91, 124, 250, 0.18); }
.btn-ghost { background: rgba(255, 255, 255, 0.08); }

.hero-card, .card {
  border-radius: 26px;
  padding: 26px;
}

.hero-card h2, .card h2 { margin: 0 0 12px; }

.status-dot {
  width: 14px;
  height: 14px;
  border-radius: 999px;
  margin-bottom: 60px;
  background: var(--success);
  box-shadow: 0 0 28px var(--success);
}

.section-narrow, .dashboard { padding: 42px 0 72px; }
.section-narrow { max-width: 920px; margin: 0 auto; }
.section-heading { margin-bottom: 28px; }
.section-heading h1 { font-size: clamp(2rem, 5vw, 4rem); }

.grid { display: grid; gap: 20px; }
.two-columns { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.dashboard-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }

.alert {
  margin: 0 0 20px;
  border-radius: 18px;
  padding: 16px 18px;
  border: 1px solid rgba(255, 255, 255, 0.12);
}
.alert-error { color: #fecdd3; background: rgba(251, 113, 133, 0.12); }
.alert-success { color: #bbf7d0; background: rgba(52, 211, 153, 0.12); }
.alert-warning { color: #fde68a; background: rgba(251, 191, 36, 0.12); }

.form-stack { display: grid; gap: 16px; margin-top: 20px; }
label { display: grid; gap: 8px; color: var(--muted); font-weight: 700; }
input, textarea {
  width: 100%;
  border: 1px solid rgba(129, 140, 248, 0.28);
  border-radius: 16px;
  padding: 14px 16px;
  color: var(--text);
  background: rgba(4, 7, 18, 0.72);
  font: inherit;
}
input:focus, textarea:focus { outline: 2px solid rgba(91, 124, 250, 0.42); }

.local-code {
  margin: 14px 0;
  border-radius: 16px;
  padding: 14px 16px;
  color: #dbeafe;
  background: rgba(91, 124, 250, 0.16);
}

.details { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 12px; margin: 0; }
.details dt { color: var(--muted); }
.details dd { margin: 0; overflow-wrap: anywhere; }

.badge { display: inline-flex; border-radius: 999px; padding: 5px 10px; font-weight: 800; }
.badge-ok { color: #bbf7d0; background: rgba(52, 211, 153, 0.16); }
.badge-muted { color: #fecdd3; background: rgba(251, 113, 133, 0.14); }

.vpn-card { grid-row: span 2; }
.vpn-key { min-height: 150px; resize: vertical; overflow-wrap: anywhere; word-break: break-word; }
.qr-box { margin-top: 18px; padding: 18px; border-radius: 22px; background: #fff; width: fit-content; }
.qr-box img { display: block; width: 190px; height: 190px; }
.empty-state { color: var(--muted); }
.wrap-anywhere { overflow-wrap: anywhere; }
.steps { color: var(--muted); line-height: 1.75; padding-left: 22px; }
.support-block { display: grid; min-height: 55vh; place-items: center; }
.support-card, .error-card { width: 100%; }
.footer { color: var(--muted); font-size: 0.92rem; }

@media (max-width: 760px) {
  .page-shell { width: min(100% - 24px, 1120px); }
  .topbar, .footer { align-items: flex-start; flex-direction: column; }
  .nav-links { justify-content: flex-start; }
  .hero, .two-columns, .dashboard-grid { grid-template-columns: 1fr; }
  .hero { padding: 28px 0 56px; }
  .details { grid-template-columns: 1fr; gap: 4px; }
  .actions .btn, .action-list .btn, .form-stack .btn { width: 100%; }
}
