:root {
  color-scheme: dark;
  --void: #04040a;
  --night: #0a0916;
  --glass: rgba(255, 255, 255, 0.045);
  --glass-strong: rgba(255, 255, 255, 0.08);
  --ink: #f7f6ff;
  --ink-dim: #a9a7c8;
  --ink-faint: #8b89ab;
  --line: rgba(180, 178, 255, 0.14);
  --line-strong: rgba(180, 178, 255, 0.3);
  --magenta: #ff2fbe;
  --violet: #8b4dff;
  --cyan: #29d3ff;
  --accent-grad: linear-gradient(104deg, var(--magenta) 0%, var(--violet) 46%, var(--cyan) 100%);
  --radius-sm: 12px;
  --radius: 20px;
  --ease-out: cubic-bezier(0.22, 0.68, 0, 1);
  --ease-soft: cubic-bezier(0.4, 0, 0.2, 1);
}

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

html, body {
  min-height: 100%;
  background: var(--void);
  color: var(--ink);
  font-family: "Figtree", "Avenir Next", "Segoe UI", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

body {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100svh;
  padding: 24px 16px;
  position: relative;
}

.atmos {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
  background:
    radial-gradient(120% 80% at 50% -10%, #14102a 0%, transparent 60%),
    linear-gradient(180deg, #070612 0%, #04040a 45%, #06050f 100%);
}

.atmos__blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  will-change: transform;
}

.atmos__blob--magenta {
  top: -14%;
  left: -8%;
  width: 46vw;
  height: 46vw;
  background: radial-gradient(circle, rgba(255, 47, 190, 0.28), transparent 68%);
  animation: drift 24s var(--ease-soft) infinite;
}

.atmos__blob--cyan {
  top: 6%;
  right: -12%;
  width: 42vw;
  height: 42vw;
  background: radial-gradient(circle, rgba(41, 211, 255, 0.22), transparent 68%);
  animation: drift 30s var(--ease-soft) infinite reverse;
}

.atmos__blob--violet {
  bottom: -22%;
  left: 24%;
  width: 52vw;
  height: 52vw;
  background: radial-gradient(circle, rgba(139, 77, 255, 0.2), transparent 70%);
  animation: drift 36s var(--ease-soft) infinite;
}

@keyframes drift {
  0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(2%, -3%, 0) scale(1.08); }
}

@keyframes shimmer {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

.card {
  width: 100%;
  max-width: 400px;
  background: rgba(10, 9, 22, 0.72);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 40px 32px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  backdrop-filter: blur(16px);
  position: relative;
  z-index: 1;
}

.lockup {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  height: 32px;
  line-height: 0;
}

.lockup img {
  display: block;
  height: 32px;
  width: auto;
}

/* ── Avatars ── */
.avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid transparent;
  background:
    linear-gradient(var(--night), var(--night)) padding-box,
    var(--accent-grad) border-box;
}

.avatar--placeholder {
  background:
    linear-gradient(135deg, rgba(255, 47, 190, 0.16), rgba(41, 211, 255, 0.16)) padding-box,
    var(--accent-grad) border-box;
}

.inviter {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  text-align: center;
}

.headline {
  font-family: "Bricolage Grotesque", "Avenir Next", "Segoe UI", sans-serif;
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.15;
  color: var(--ink);
  text-wrap: balance;
}

.gradient-text {
  background: var(--accent-grad);
  background-size: 220% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  animation: shimmer 14s var(--ease-soft) infinite;
}

.subheadline {
  font-size: 0.9375rem;
  color: var(--ink-dim);
  line-height: 1.5;
}

.btn-primary {
  display: block;
  width: 100%;
  padding: 14px 26px;
  background: var(--accent-grad);
  background-size: 160% 100%;
  color: #0a0512;
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  text-align: center;
  text-decoration: none;
  border-radius: var(--radius-sm);
  box-shadow: 0 10px 30px -12px rgba(255, 47, 190, 0.55);
  transition:
    translate 180ms var(--ease-out),
    box-shadow 220ms var(--ease-out),
    opacity 180ms var(--ease-out);
}

.btn-primary:hover {
  translate: 0 -2px;
  box-shadow: 0 16px 40px -14px rgba(41, 211, 255, 0.6);
}

.btn-primary:active { translate: 0 0; }

.store-badges {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}

.store-badges a {
  display: block;
  line-height: 0;
  transition: translate 180ms var(--ease-out);
}

.store-badges a:hover { translate: 0 -2px; }

.store-badges img {
  height: 40px;
  width: auto;
}

.card--error .headline {
  font-size: 1.25rem;
}

@media (max-width: 720px) {
  .atmos__blob { filter: blur(60px); }
  .atmos__blob--magenta,
  .atmos__blob--cyan,
  .atmos__blob--violet {
    width: 80vw;
    height: 80vw;
  }
}

@media (prefers-reduced-motion: reduce) {
  .atmos__blob,
  .gradient-text {
    animation: none;
    will-change: auto;
  }
}

:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
  border-radius: 4px;
}
