:root {
  --navy: #0a1a3a;
  --navy-2: #12285a;
  --white: #f5f8ff;
  --paper: #ffffff;
  --sky: #9cc0ff;
  --accent: #3d7bff;
  --accent-deep: #2a5fe0;
  --muted: #a9b6d3;
  --line: rgba(245, 248, 255, 0.14);
  --display: "Fraunces", Georgia, serif;
  --body: "Manrope", system-ui, sans-serif;
  --radius: 18px;
}

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

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.6;
  color: var(--white);
  background:
    radial-gradient(900px 600px at 85% 10%, rgba(61, 123, 255, 0.16), transparent 60%),
    radial-gradient(700px 500px at 0% 100%, rgba(156, 192, 255, 0.12), transparent 60%),
    var(--navy);
  overflow-x: hidden;
}

.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 50;
  opacity: 0.07;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

/* ---------- Header ---------- */
.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
  padding: 28px 28px 0;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--display);
  font-weight: 800;
  font-size: 1.5rem;
  letter-spacing: -0.02em;
  color: var(--white);
  text-decoration: none;
}

.logo-mark {
  display: inline-flex;
  gap: 4px;
  padding: 7px 8px;
  border-radius: 8px;
  background: var(--white);
}
.logo-mark i {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--accent);
}
.logo-mark i:last-child {
  background: transparent;
  border: 2px dashed var(--navy-2);
}

.tag {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 8px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--sky);
}
.tag::before {
  content: "";
  display: inline-block;
  width: 7px; height: 7px;
  margin-right: 8px;
  border-radius: 50%;
  background: var(--accent);
  vertical-align: 1px;
  animation: pulse 1.8s ease-in-out infinite;
}

/* ---------- Hero ---------- */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 56px;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  padding: 72px 28px 96px;
}

.eyebrow {
  margin: 0 0 20px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--sky);
}

h1 {
  margin: 0 0 28px;
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(2.8rem, 6.4vw, 5.6rem);
  line-height: 0.98;
  letter-spacing: -0.035em;
  font-variation-settings: "opsz" 144;
}
h1 em {
  font-style: italic;
  font-weight: 600;
  color: var(--accent);
}

.lede {
  max-width: 34em;
  margin: 0 0 40px;
  font-size: 1.12rem;
  color: var(--muted);
}
.lede strong { color: var(--white); font-weight: 600; }

/* ---------- Form ---------- */
.waitlist { max-width: 560px; }

.hp { position: absolute; left: -9999px; }

.field {
  display: flex;
  gap: 6px;
  padding: 6px;
  border-radius: 999px;
  background: var(--paper);
  box-shadow: 0 20px 50px -20px rgba(61, 123, 255, 0.45), 0 0 0 1px rgba(0, 0, 0, 0.04);
  transition: box-shadow 0.25s ease, transform 0.25s ease;
}
.field:focus-within {
  box-shadow: 0 24px 60px -18px rgba(61, 123, 255, 0.6), 0 0 0 3px rgba(61, 123, 255, 0.5);
}
.waitlist.has-error .field {
  box-shadow: 0 0 0 3px var(--accent);
  animation: shake 0.4s ease;
}

.field input {
  flex: 1;
  min-width: 0;
  padding: 14px 20px;
  border: 0;
  background: transparent;
  font: inherit;
  font-size: 1.05rem;
  color: var(--navy);
  outline: none;
}
.field input::placeholder { color: #8a97b3; }

.field button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 24px;
  border: 0;
  border-radius: 999px;
  background: var(--accent);
  color: var(--paper);
  font: inherit;
  font-weight: 700;
  font-size: 1rem;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.15s ease;
}
.field button:hover { background: var(--accent-deep); }
.field button:active { transform: scale(0.97); }
.field button:focus-visible { outline: 3px solid var(--sky); outline-offset: 2px; }
.btn-arrow { transition: transform 0.2s ease; }
.field button:hover .btn-arrow { transform: translateX(4px); }

.waitlist.is-loading button { pointer-events: none; opacity: 0.85; }
.waitlist.is-loading .btn-arrow {
  width: 16px; height: 16px;
  border: 2px solid rgba(255, 255, 255, 0.4);
  border-top-color: var(--paper);
  border-radius: 50%;
  font-size: 0;
  animation: spin 0.7s linear infinite;
}

.form-msg {
  margin: 14px 0 0 22px;
  font-size: 0.88rem;
  color: var(--muted);
}
.waitlist.has-error .form-msg { color: #ffb3b3; font-weight: 600; }

/* ---------- Success ---------- */
.success {
  display: flex;
  align-items: center;
  gap: 18px;
  max-width: 560px;
  padding: 20px 24px;
  border-radius: var(--radius);
  background: var(--white);
  color: var(--navy);
  outline: none;
  animation: pop 0.5s cubic-bezier(0.2, 1.4, 0.4, 1) both;
}
.success[hidden] { display: none; }

.success-stamp {
  flex: none;
  display: grid;
  place-items: center;
  width: 56px; height: 56px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--paper);
  font-size: 1.6rem;
  font-weight: 800;
  transform: rotate(-12deg);
  box-shadow: inset 0 0 0 4px rgba(255, 255, 255, 0.25);
}
.success-title {
  margin: 0;
  font-family: var(--display);
  font-weight: 800;
  font-size: 1.35rem;
}
.success-text { margin: 2px 0 0; color: #4a5878; font-size: 0.98rem; }

/* ---------- Phone / Wallet visual ---------- */
.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
  animation: rise 1s 0.35s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.phone {
  position: relative;
  width: 320px;
  height: 600px;
  padding: 54px 18px 18px;
  border-radius: 48px;
  background: #050c1f;
  box-shadow:
    0 0 0 10px #13213f,
    0 0 0 11px rgba(245, 248, 255, 0.12),
    0 60px 120px -30px rgba(0, 0, 0, 0.8),
    0 30px 80px -40px rgba(61, 123, 255, 0.5);
  transform: rotate(4deg);
  overflow: hidden;
}

.phone-notch {
  position: absolute;
  top: 14px; left: 50%;
  width: 100px; height: 28px;
  border-radius: 20px;
  background: #000;
  transform: translateX(-50%);
}

.wallet-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 0 6px 18px;
  font-family: var(--body);
  font-weight: 700;
  font-size: 1.7rem;
  letter-spacing: -0.02em;
}
.plus {
  display: grid;
  place-items: center;
  width: 30px; height: 30px;
  border-radius: 50%;
  background: #16264a;
  font-size: 1.2rem;
  color: var(--accent);
}

.pass {
  border-radius: 16px;
}
.pass-back {
  height: 54px;
  margin-bottom: -14px;
  position: relative;
}
.pass-a { background: linear-gradient(135deg, #2b4c8c, #1f3a70); }
.pass-b { background: linear-gradient(135deg, #5a7fc4, #3f63a8); }

.pass-main {
  position: relative;
  padding: 18px;
  background: linear-gradient(160deg, var(--white) 0%, #e3ebfa 100%);
  color: var(--navy);
  box-shadow: 0 -8px 30px rgba(0, 0, 0, 0.35);
}

.pass-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 18px;
}
.pass-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--display);
  font-weight: 800;
  font-size: 1.05rem;
}
.pass-logo {
  display: grid;
  place-items: center;
  width: 34px; height: 34px;
  border-radius: 10px;
  background: var(--navy);
  font-size: 1rem;
}
.pass small {
  display: block;
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: #6a7a9c;
}
.pass-meta { text-align: right; }
.pass-meta b { font-size: 1.15rem; }

.stamps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  padding: 14px;
  border-radius: 12px;
  background: rgba(10, 26, 58, 0.06);
}
.stamps span {
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 2px dashed rgba(10, 26, 58, 0.25);
  font-size: 1.1rem;
  transition: background 0.3s ease, border-color 0.3s ease, transform 0.35s cubic-bezier(0.2, 1.6, 0.4, 1);
}
.stamps span.on {
  background: var(--accent);
  border: 2px solid var(--accent);
  transform: rotate(-10deg) scale(1.04);
  box-shadow: inset 0 0 0 3px rgba(255, 255, 255, 0.28);
}
.stamps span.on::after {
  content: "☕";
  font-size: 0.95rem;
  filter: grayscale(1) brightness(3);
}
.stamps span.gift { border-color: var(--sky); border-style: solid; }
.stamps span.gift.on::after { content: none; }
.stamps span.gift.on { background: var(--sky); border-color: var(--sky); }

.pass-bottom {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-top: 18px;
}
.pass-bottom b { font-family: var(--display); font-size: 1.1rem; }

.qr {
  width: 64px; height: 64px;
  border-radius: 8px;
  background:
    linear-gradient(90deg, var(--navy) 50%, transparent 0) 0 0 / 8px 8px,
    linear-gradient(var(--navy) 50%, transparent 0) 0 0 / 8px 8px;
  background-blend-mode: difference;
  border: 5px solid var(--paper);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.08);
  opacity: 0.85;
}

.toast {
  position: absolute;
  left: 14px; right: 14px; bottom: 22px;
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(28, 46, 92, 0.82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  font-size: 0.82rem;
  line-height: 1.35;
  color: var(--white);
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.4s ease, transform 0.5s cubic-bezier(0.2, 1.3, 0.4, 1);
}
.toast.show { opacity: 1; transform: translateY(0); }
.toast-icon {
  flex: none;
  display: grid;
  place-items: center;
  width: 34px; height: 34px;
  border-radius: 9px;
  background: var(--accent);
}

.badge {
  position: absolute;
  padding: 10px 16px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
  box-shadow: 0 14px 40px -12px rgba(0, 0, 0, 0.6);
  animation: float 6s ease-in-out infinite;
}
.badge-apple { top: 70px; left: -6px; background: var(--white); color: var(--navy); }
.badge-google { bottom: 120px; right: -14px; background: var(--sky); color: var(--navy); animation-delay: -3s; }

/* ---------- Perks ---------- */
.perks {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 28px;
  border-top: 1px solid var(--line);
}
.perks article {
  padding: 40px 32px 48px 0;
}
.perks article + article {
  padding-left: 32px;
  border-left: 1px solid var(--line);
}
.num {
  font-family: var(--display);
  font-style: italic;
  font-size: 0.95rem;
  color: var(--accent);
}
.perks h2 {
  margin: 10px 0 10px;
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.45rem;
  line-height: 1.2;
  letter-spacing: -0.01em;
}
.perks p { margin: 0; color: var(--muted); font-size: 0.98rem; }

/* ---------- For who ---------- */
.for-who {
  display: flex;
  align-items: baseline;
  gap: 20px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 36px 28px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.for-who p {
  margin: 0;
  font-family: var(--display);
  font-style: italic;
  font-size: 1.3rem;
  color: var(--sky);
}
.for-who ul {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.for-who li {
  padding: 6px 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 0.95rem;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.for-who li:hover { background: var(--white); color: var(--navy); border-color: var(--white); }
.for-who li:last-child { border-style: dashed; color: var(--muted); }

/* ---------- Footer ---------- */
.foot {
  display: flex;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
  padding: 28px 28px 40px;
  font-size: 0.85rem;
  color: var(--muted);
}

/* ---------- Thank-you page ---------- */
.thanks-page { display: grid; place-items: center; padding: 28px; }
.thanks { max-width: 620px; text-align: center; animation: pop 0.6s cubic-bezier(0.2, 1.3, 0.4, 1) both; }
.thanks .success-stamp.big { width: 96px; height: 96px; margin: 0 auto 28px; font-size: 2.6rem; }
.thanks h1 { font-size: clamp(2.4rem, 6vw, 4rem); }
.thanks .lede { margin: 0 auto 32px; }
.back { color: var(--accent); font-weight: 700; text-decoration: none; }
.back:hover { text-decoration: underline; }

/* ---------- Motion ---------- */
.reveal { animation: rise 0.8s calc(var(--d, 0) * 0.1s) cubic-bezier(0.2, 0.8, 0.2, 1) both; }

@keyframes rise { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }
@keyframes pop { from { opacity: 0; transform: scale(0.92); } to { opacity: 1; transform: none; } }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.3; } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .hero { grid-template-columns: 1fr; gap: 64px; padding-top: 48px; }
  .hero-visual { order: 2; }
  .perks { grid-template-columns: 1fr; }
  .perks article, .perks article + article { padding: 32px 0; border-left: 0; }
  .perks article + article { border-top: 1px solid var(--line); }
  .for-who { flex-direction: column; gap: 14px; }
}

@media (max-width: 560px) {
  body { font-size: 16px; }
  .top { padding: 20px 20px 0; }
  .tag { display: none; }
  .hero { padding: 40px 20px 72px; }
  .field { flex-direction: column; border-radius: 22px; }
  .field input { padding: 14px 16px; }
  .field button { justify-content: center; border-radius: 16px; }
  .form-msg { margin-left: 4px; }
  .phone { width: 280px; height: 540px; transform: rotate(2deg); }
  .badge-apple { left: 0; }
  .badge-google { right: 0; }
  .perks, .for-who, .foot { padding-left: 20px; padding-right: 20px; }
  .foot { flex-direction: column; gap: 6px; }
}
