:root {
  --midnight: #0B1422;
  --deep: #15233A;
  --raised: #1E3150;
  --gilt: #E7B94C;
  --gilt-hi: #FFE3A1;
  --arcane: #5CC8F2;
  --parchment: #F4EBD6;
  --mist: #C2CBD8;
  --display: "Marcellus", "Palatino Linotype", Palatino, serif;
  --body: "Manrope", system-ui, sans-serif;
  --gutter: clamp(16px, 5vw, 64px);
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--midnight);
  color: var(--parchment);
  font: 400 1.0625rem/1.6 var(--body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; height: auto; }

a { color: inherit; }

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

/* Night sky behind everything: a moon glow top right, arcane haze bottom left, faint stars. */
.sky {
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(40rem 30rem at 85% 8%, rgba(231, 185, 76, .18), transparent 70%),
    radial-gradient(45rem 35rem at 0% 100%, rgba(92, 200, 242, .12), transparent 70%),
    radial-gradient(1px 1px at 20% 30%, rgba(244, 235, 214, .5), transparent),
    radial-gradient(1px 1px at 70% 60%, rgba(244, 235, 214, .4), transparent),
    radial-gradient(1.5px 1.5px at 40% 80%, rgba(244, 235, 214, .35), transparent),
    radial-gradient(1px 1px at 90% 40%, rgba(244, 235, 214, .4), transparent),
    var(--midnight);
}

/* Header */
.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem var(--gutter);
}

.brand img { width: clamp(180px, 24vw, 300px); }

.top nav { display: flex; align-items: center; gap: clamp(.75rem, 3vw, 2rem); font-weight: 500; }
.top nav a { text-decoration: none; color: var(--mist); }
.top nav a:hover { color: var(--parchment); }
.top nav .nav-cta { color: var(--gilt); }

@media (max-width: 520px) {
  .top nav a:not(.nav-cta) { display: none; }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  padding: .9rem 1.4rem;
  border-radius: 999px;
  font: 700 1rem/1 var(--body);
  text-decoration: none;
  cursor: pointer;
  border: 0;
  transition: transform .15s ease, box-shadow .15s ease;
}
.btn:active { transform: translateY(1px); }

.btn-gold {
  color: var(--midnight);
  background: linear-gradient(180deg, var(--gilt-hi), var(--gilt) 55%, #C8952E);
  box-shadow: 0 0 0 1px rgba(255, 227, 161, .5) inset, 0 8px 30px -8px rgba(231, 185, 76, .6);
}
.btn-gold:hover { box-shadow: 0 0 0 1px rgba(255, 227, 161, .7) inset, 0 10px 40px -6px rgba(231, 185, 76, .8); }


/* Official Google Play badge, used unaltered. */
.play-badge { display: inline-block; border-radius: 10px; }
.play-badge img { height: 52px; width: auto; }

.invited {
  display: flex;
  align-items: center;
  gap: 1.4rem;
  margin-top: 1.5rem;
  padding: 1.25rem;
  border-radius: 20px;
  background: rgba(21, 35, 58, .6);
  box-shadow: 0 0 0 1px rgba(92, 200, 242, .3) inset;
}
.invited h3 { font-size: 1.35rem; color: var(--arcane); }
.invited .qr-hint { margin: .3rem 0 .8rem; font-size: .9rem; }
.qr { flex: none; width: 132px; height: 132px; border-radius: 10px; box-shadow: 0 0 0 3px var(--gilt); }

/* A QR code is no use on the phone it should be scanned with. */
@media (max-width: 860px), (pointer: coarse) {
  .qr { display: none; }
  .invited .qr-hint { display: none; }
}

/* Hero */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
  align-items: center;
  gap: clamp(2rem, 5vw, 5rem);
  padding: clamp(2rem, 6vw, 5rem) var(--gutter) clamp(4rem, 8vw, 7rem);
  max-width: 1240px;
  margin: 0 auto;
}

.status {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  margin: 0 0 1.5rem;
  padding: .4rem .9rem .4rem .7rem;
  border-radius: 999px;
  background: rgba(92, 200, 242, .1);
  box-shadow: 0 0 0 1px rgba(92, 200, 242, .35) inset;
  color: var(--arcane);
  font-weight: 700;
  font-size: .9rem;
}

.pulse {
  width: .55rem;
  height: .55rem;
  border-radius: 50%;
  background: var(--arcane);
  box-shadow: 0 0 0 0 rgba(92, 200, 242, .7);
  animation: pulse 2.4s ease-out infinite;
}
@keyframes pulse { 70%, 100% { box-shadow: 0 0 0 .6rem rgba(92, 200, 242, 0); } }

h1, h2, h3 { font-family: var(--display); font-weight: 400; line-height: 1.1; margin: 0; }

h1 {
  font-size: clamp(2.6rem, 6.2vw, 4.75rem);
  letter-spacing: -.01em;
  background: linear-gradient(175deg, #FFF6DD 10%, var(--gilt) 60%, #B98424 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  max-width: 13ch;
}

.lede { font-size: clamp(1.1rem, 1.8vw, 1.3rem); color: var(--mist); max-width: 34rem; margin: 1.5rem 0 2rem; }

.actions { display: flex; flex-wrap: wrap; gap: .8rem; }

.fine { font-size: .875rem; color: var(--mist); opacity: .8; margin: 1rem 0 0; }

/* Phone and scanner mockup */
.stage {
  position: relative;
  justify-self: center;
  perspective: 1200px;
  width: min(320px, 78vw);
}

.phone {
  position: relative;
  aspect-ratio: 9 / 19;
  padding: 10px;
  border-radius: 44px;
  background: linear-gradient(145deg, #2A3C5C, #0E1828 60%, #1B2A44);
  box-shadow:
    0 0 0 1.5px rgba(231, 185, 76, .55),
    0 0 60px -10px rgba(92, 200, 242, .45),
    0 40px 80px -30px rgba(0, 0, 0, .8);
  transform: rotateY(var(--ry, -10deg)) rotateX(var(--rx, 4deg));
  transform-style: preserve-3d;
  transition: transform .4s cubic-bezier(.2, .7, .2, 1);
}

.screen {
  position: relative;
  height: 100%;
  border-radius: 34px;
  overflow: hidden;
  background: #05090F;
}

.shot { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 2; }

/* Sweeps the blue scan frame in the screenshot once the page loads. */
.scanline {
  position: absolute;
  z-index: 3;
  left: 15%;
  right: 15%;
  top: 25%;
  height: 3px;
  border-radius: 3px;
  background: var(--arcane);
  box-shadow: 0 0 18px 4px rgba(92, 200, 242, .7);
  opacity: 0;
  animation: frame-sweep 1.6s .6s cubic-bezier(.45, 0, .55, 1) 2 alternate forwards;
}
@keyframes frame-sweep {
  0% { top: 25%; opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { top: 61%; opacity: 0; }
}

.mock { position: absolute; inset: 0; display: flex; flex-direction: column; font-size: 12px; }

.mock-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 2.2rem 1rem .6rem;
  color: var(--parchment);
}
.mock-bar .x { opacity: .8; }
.mock-bar .dest {
  padding: .3rem .7rem;
  border-radius: 999px;
  background: rgba(21, 35, 58, .85);
  box-shadow: 0 0 0 1px rgba(231, 185, 76, .4) inset;
  font-weight: 500;
}

.viewfinder {
  position: relative;
  flex: 1;
  display: grid;
  place-items: center;
  /* Blurred wooden table under the camera. */
  background:
    radial-gradient(circle at 50% 45%, rgba(255, 210, 140, .12), transparent 60%),
    repeating-linear-gradient(95deg, #2A1D14 0 14px, #2F2117 14px 22px, #271B12 22px 40px);
}

.card {
  position: relative;
  width: 62%;
  aspect-ratio: 63 / 88;
  padding: 6%;
  border-radius: 6%;
  background: #121212;
  display: flex;
  flex-direction: column;
  gap: 4%;
  box-shadow: 0 14px 30px rgba(0, 0, 0, .6);
  transform: rotate(-3deg);
  overflow: hidden;
}
.card > div:not(.foil) { border-radius: 3px; }
.card-name {
  padding: 3% 5%;
  background: linear-gradient(#D8CFC0, #BDB2A0);
  color: #1A1A1A;
  font: 400 .78rem/1.2 var(--display);
}
.card-art {
  flex: 1.3;
  background:
    radial-gradient(circle at 62% 38%, #FFE7A3 0 14%, rgba(255, 231, 163, .4) 15%, transparent 34%),
    linear-gradient(170deg, transparent 52%, #142844 53%),
    conic-gradient(from 200deg at 45% 80%, #0F2240, #1F4C7C, #0F2240),
    #1F4C7C;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .5);
}
.card-type {
  padding: 2% 5%;
  background: linear-gradient(#D8CFC0, #BDB2A0);
  color: #1A1A1A;
  font: 400 .62rem/1.2 var(--display);
}
.card-text {
  flex: 1;
  background:
    linear-gradient(#8A7F6E, #8A7F6E) 8% 25% / 80% 2px no-repeat,
    linear-gradient(#8A7F6E, #8A7F6E) 8% 45% / 70% 2px no-repeat,
    linear-gradient(#8A7F6E, #8A7F6E) 8% 65% / 76% 2px no-repeat,
    #E6DFD2;
}

/* Holographic foil sheen; it follows the pointer through --fx. */
.foil {
  position: absolute;
  inset: 0;
  pointer-events: none;
  mix-blend-mode: color-dodge;
  opacity: .55;
  background: linear-gradient(115deg,
    transparent calc(var(--fx, 40%) - 30%),
    rgba(92, 200, 242, .55) calc(var(--fx, 40%) - 12%),
    rgba(255, 227, 161, .7) var(--fx, 40%),
    rgba(214, 140, 255, .45) calc(var(--fx, 40%) + 12%),
    transparent calc(var(--fx, 40%) + 30%));
  transition: background-position .3s;
}

.corner { position: absolute; width: 22px; height: 22px; border: 3px solid var(--arcane); filter: drop-shadow(0 0 6px var(--arcane)); }
.corner.tl { top: 12%; left: 12%; border-right: 0; border-bottom: 0; border-top-left-radius: 8px; }
.corner.tr { top: 12%; right: 12%; border-left: 0; border-bottom: 0; border-top-right-radius: 8px; }
.corner.bl { bottom: 12%; left: 12%; border-right: 0; border-top: 0; border-bottom-left-radius: 8px; }
.corner.br { bottom: 12%; right: 12%; border-left: 0; border-top: 0; border-bottom-right-radius: 8px; }

/* The one orchestrated moment: the beam sweeps the card, then the match slides up. */
.beam {
  position: absolute;
  left: 10%;
  right: 10%;
  top: 12%;
  height: 3px;
  border-radius: 3px;
  background: var(--arcane);
  box-shadow: 0 0 18px 4px rgba(92, 200, 242, .7);
  opacity: 0;
  animation: sweep 1.6s .5s cubic-bezier(.45, 0, .55, 1) 2 alternate forwards;
}
@keyframes sweep {
  0% { top: 12%; opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { top: 88%; opacity: 0; }
}

.sheet {
  margin: 0 .6rem .9rem;
  padding: .8rem .9rem;
  border-radius: 18px;
  background: rgba(21, 35, 58, .95);
  box-shadow: 0 0 0 1px rgba(231, 185, 76, .35) inset;
  color: var(--parchment);
  transform: translateY(130%);
  animation: rise .5s 3.6s cubic-bezier(.2, .9, .3, 1.2) forwards;
}
@keyframes rise { to { transform: translateY(0); } }

.hit { display: flex; align-items: center; justify-content: space-between; gap: .5rem; }
.hit strong { display: block; font: 400 .95rem/1.2 var(--display); color: var(--gilt); }
.hit span { color: var(--mist); font-size: .7rem; }
.qty { display: flex; align-items: center; gap: .55rem; font-weight: 700; }
.qty b { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--raised); font-weight: 500; }
.sheet-row { display: flex; align-items: center; justify-content: space-between; margin-top: .7rem; color: var(--mist); font-size: .7rem; }
.add { padding: .35rem .9rem; border-radius: 999px; background: var(--gilt); color: var(--midnight); font-weight: 700; }

.seal {
  position: absolute;
  top: 44%;
  left: -15%;
  display: grid;
  place-items: center;
  width: 76px;
  height: 76px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, var(--gilt-hi), var(--gilt) 50%, #A87420);
  color: var(--midnight);
  font: 400 1.05rem/1 var(--display);
  box-shadow: 0 0 0 4px rgba(11, 20, 34, .9), 0 0 0 5px rgba(231, 185, 76, .6), 0 10px 30px rgba(0, 0, 0, .5);
  transform: rotate(12deg);
}

@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; text-align: left; }
  .stage { margin-top: 1rem; }
  .seal { left: -6%; }
}

/* Features */
.features {
  max-width: 1120px;
  margin: 0 auto;
  padding: clamp(3rem, 7vw, 6rem) var(--gutter);
}

.features h2, .beta h2 {
  font-size: clamp(2rem, 4.2vw, 3.2rem);
  color: var(--parchment);
  max-width: 20ch;
}

.features-intro { margin: 1.25rem 0 0; max-width: 56ch; color: var(--mist); font-size: 1.125rem; }

.lead-feature {
  position: relative;
  margin: 3rem 0;
  padding: clamp(1.5rem, 4vw, 3rem);
  border-radius: 28px;
  background:
    radial-gradient(30rem 16rem at 100% 0%, rgba(92, 200, 242, .16), transparent 70%),
    linear-gradient(160deg, var(--deep), rgba(21, 35, 58, .4));
  box-shadow: 0 0 0 1px rgba(92, 200, 242, .3) inset;
}
.lead-feature h3 { font-size: clamp(1.6rem, 3vw, 2.2rem); color: var(--arcane); margin-bottom: 1rem; }
.lead-feature p { max-width: 60ch; color: var(--mist); margin: 0 0 .8rem; }
.lead-feature p:last-child { color: var(--parchment); margin: 0; }

.feature-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  column-gap: clamp(2rem, 5vw, 4rem);
}
.feature-list li {
  padding: 1.5rem 0 1.5rem 1.4rem;
  border-left: 2px solid rgba(231, 185, 76, .35);
  margin-bottom: 1rem;
}
.feature-list h3 { font-size: 1.4rem; color: var(--gilt); margin-bottom: .4rem; }
.feature-list p { margin: 0; color: var(--mist); max-width: 46ch; }

/* Beta */
.beta {
  max-width: 1120px;
  margin: 0 auto;
  padding: clamp(3rem, 7vw, 6rem) var(--gutter) clamp(4rem, 8vw, 7rem);
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}
@media (max-width: 860px) { .beta { grid-template-columns: 1fr; } }

.beta-copy p { color: var(--mist); max-width: 40ch; }

.steps { counter-reset: step; list-style: none; padding: 0; margin: 2rem 0 0; }
.steps li {
  counter-increment: step;
  position: relative;
  padding: 0 0 1.4rem 3.2rem;
  max-width: 36ch;
}
.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: -.2rem;
  display: grid;
  place-items: center;
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 50%;
  font: 400 1.1rem/1 var(--display);
  color: var(--gilt);
  box-shadow: 0 0 0 1.5px var(--gilt) inset;
}

.apply {
  display: grid;
  gap: 1.1rem;
  padding: clamp(1.25rem, 4vw, 2.25rem);
  border-radius: 28px;
  background: linear-gradient(170deg, rgba(30, 49, 80, .85), rgba(21, 35, 58, .85));
  box-shadow: 0 0 0 1px rgba(231, 185, 76, .35) inset, 0 30px 60px -30px rgba(0, 0, 0, .7);
}
.apply label { display: grid; gap: .4rem; font-weight: 500; }
.apply em { font-style: normal; color: var(--mist); font-weight: 400; }
.apply small { color: var(--mist); font-size: .85rem; }
.apply input, .apply select, .apply textarea {
  width: 100%;
  padding: .8rem 1rem;
  border-radius: 12px;
  border: 1px solid rgba(194, 203, 216, .25);
  background: rgba(11, 20, 34, .7);
  color: var(--parchment);
  font: inherit;
}
.apply input::placeholder, .apply textarea::placeholder { color: rgba(194, 203, 216, .55); }
.apply input:focus, .apply select:focus, .apply textarea:focus { outline: none; border-color: var(--arcane); box-shadow: 0 0 0 3px rgba(92, 200, 242, .25); }
.apply [aria-invalid="true"] { border-color: #F97066; }
.apply .btn { justify-self: start; }
.apply .btn[disabled] { opacity: .6; cursor: progress; }
.trap { display: none; }
.privacy { margin: 0; font-size: .85rem; color: var(--mist); }
.form-status { margin: 0; min-height: 1.6em; font-weight: 500; }
.form-status.ok { color: var(--arcane); }
.form-status.err { color: #F97066; }

/* Footer */
footer {
  display: grid;
  justify-items: center;
  gap: .5rem;
  padding: 3rem var(--gutter) 4rem;
  text-align: center;
  font-size: .85rem;
  color: var(--mist);
  border-top: 1px solid rgba(231, 185, 76, .15);
}
footer p { margin: 0; max-width: 70ch; }
footer a { color: var(--gilt); text-underline-offset: 3px; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .pulse, .beam, .scanline { animation: none; }
  .sheet { animation: none; transform: none; }
  .phone { transition: none; }
}
