:root {
  --blue: #0142AB;
  --blue-dark: #02307a;
  --ink: #0c1220;
  --muted: #5a6474;
  --muted-2: #8a93a3;
  --muted-3: #3c4658;
  --border: #d7dce4;
  --border-soft: #e6e9ef;
  --error: #c22f2f;
  --font: 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

* { box-sizing: border-box; }

/* Ensure the [hidden] attribute always wins over component display rules. */
[hidden] { display: none !important; }

html, body {
  margin: 0;
  padding: 0;
  background: #ffffff;
  color: var(--ink);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--blue); text-decoration: none; }
a:hover { color: var(--blue-dark); }

input::placeholder { color: #9aa3b2; }

/* ---------- Layout ---------- */
.page { min-height: 100vh; background: #ffffff; }
.container { max-width: 680px; margin: 0 auto; padding: 0 24px; }

.rule { border-top: 1px solid var(--border-soft); }
.divider { width: 48px; height: 2px; background: var(--blue); margin: 0 auto 64px; }

/* ---------- Top bar ---------- */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 24px 0;
}
.brand { display: flex; align-items: center; gap: 14px; }
.brand__logo {
  width: 44px; height: 44px;
  border-radius: 50%;
  display: block;
}
.brand__text { display: flex; flex-direction: column; gap: 2px; }
.brand__name {
  font-size: 15px; font-weight: 800;
  letter-spacing: -0.01em; color: var(--ink);
}
.brand__tagline {
  font-size: 11px; font-weight: 500;
  letter-spacing: 0.06em; color: var(--muted-2);
}
/* Hide the top-bar tagline on small screens to keep the header tidy. */
@media (max-width: 480px) {
  .brand__tagline { display: none; }
}

.badge {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 8px 16px;
  border: 1px solid var(--border);
  font-size: 11px; font-weight: 700;
  letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--muted); white-space: nowrap;
}
.badge__dot {
  width: 6px; height: 6px; background: var(--blue);
  animation: osBlink 2.4s ease-in-out infinite;
}

/* ---------- Hero ---------- */
.hero {
  display: flex; flex-direction: column; align-items: center;
  text-align: center; padding: 80px 0 64px;
}
.hero__logo {
  width: 88px; height: 88px;
  border-radius: 50%; display: block;
  margin-bottom: 36px;
}
.eyebrow {
  display: inline-flex; align-items: center; gap: 9px;
  margin: 0 0 20px;
  font-size: 12px; font-weight: 700;
  letter-spacing: 0.26em; text-transform: uppercase;
  color: var(--muted);
}
.eyebrow__dot {
  width: 6px; height: 6px; background: var(--blue);
  animation: osBlink 2.4s ease-in-out infinite;
}
.hero__title {
  margin: 0 0 24px;
  font-size: clamp(40px, 7vw, 64px);
  font-weight: 900; line-height: 1.05;
  letter-spacing: -0.025em; color: var(--blue);
  text-wrap: balance;
}
.hero__lede {
  margin: 0; max-width: 520px;
  font-size: 16px; font-weight: 400; line-height: 1.8;
  color: var(--muted); text-wrap: pretty;
}
.hero__lede strong { color: var(--ink); font-weight: 700; }

/* ---------- Waitlist ---------- */
.waitlist { padding: 0 0 96px; }

.section-head { text-align: center; margin-bottom: 40px; }
.section-head h2 {
  margin: 0 0 12px;
  font-size: clamp(24px, 3.4vw, 32px);
  font-weight: 800; letter-spacing: -0.015em; color: var(--ink);
}
.section-head p {
  margin: 0;
  font-size: 14.5px; line-height: 1.7;
  color: var(--muted); text-wrap: pretty;
}

.field-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
}
.field label,
.group-label {
  display: block;
  font-size: 11.5px; font-weight: 700;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--ink); margin-bottom: 10px;
}
.req { color: var(--blue); }
.opt {
  font-weight: 500; text-transform: none;
  letter-spacing: 0; color: var(--muted-2);
}

input[type="email"],
input[type="tel"],
.other-input {
  width: 100%;
  padding: 16px 18px;
  border: 1px solid var(--border);
  background: #ffffff; color: var(--ink);
  font-family: var(--font);
  font-size: 15.5px; font-weight: 500;
  outline: none;
  transition: border-color .2s, box-shadow .2s;
}
input[type="email"]:focus,
input[type="tel"]:focus,
.other-input:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(1, 66, 171, 0.12);
}

.spacer { height: 26px; }

.group-label { margin-bottom: 6px; }
.group-hint { margin: 0 0 16px; font-size: 13px; color: var(--muted-2); }

.chips {
  display: flex; flex-wrap: wrap; gap: 10px;
  margin-bottom: 8px;
}
.chip {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 12px 18px;
  border: 1px solid var(--border);
  background: #ffffff; color: var(--muted-3);
  cursor: pointer;
  font-family: var(--font);
  font-size: 13.5px; font-weight: 600;
  transition: border-color .3s cubic-bezier(.2,.7,.2,1),
              background .3s cubic-bezier(.2,.7,.2,1),
              color .3s cubic-bezier(.2,.7,.2,1),
              transform .25s cubic-bezier(.2,.7,.2,1);
}
.chip__icon { display: flex; align-items: center; color: inherit; }
.chip:hover {
  border-color: var(--blue); color: var(--blue);
  transform: translateY(-2px);
}
.chip:active { transform: scale(.97); }
.chip[aria-pressed="true"] {
  border-color: var(--blue); background: var(--blue); color: #ffffff;
}
.chip[aria-pressed="true"]:hover {
  border-color: var(--blue-dark); background: var(--blue-dark);
  color: #ffffff; transform: translateY(-2px);
}
.chip__tick {
  display: flex; align-items: center; justify-content: center;
  width: 16px; height: 16px;
  background: #ffffff; color: var(--blue);
  font-size: 10px; font-weight: 800; border-radius: 50%;
}

.other-input { margin-top: 16px; font-size: 14.5px; animation: osRise .35s ease both; }

.submit-btn {
  width: 100%; margin-top: 34px;
  padding: 19px 28px;
  border: none; cursor: pointer;
  font-family: var(--font);
  font-size: 15px; font-weight: 800;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: #ffffff; background: var(--blue);
  transition: background .2s, transform .2s;
}
.submit-btn:hover { background: var(--blue-dark); transform: translateY(-2px); }
.submit-btn:active { transform: translateY(0); }
.submit-btn:disabled { opacity: .6; cursor: default; transform: none; }

.fineprint {
  margin: 18px 0 0; text-align: center;
  font-size: 12.5px; color: var(--muted-2);
}

.error {
  margin: 8px 0 0;
  font-size: 13px; font-weight: 600; color: var(--error);
}
#category-error { margin-top: 0; }

/* ---------- Success ---------- */
.success { text-align: center; padding: 24px 0; animation: osRise .45s ease both; }
.success__check {
  width: 72px; height: 72px; margin: 0 auto 24px;
  display: flex; align-items: center; justify-content: center;
  background: var(--blue); color: #ffffff;
  font-size: 30px; font-weight: 800;
}
.success h2 {
  margin: 0 0 12px;
  font-size: clamp(22px, 3.2vw, 30px);
  font-weight: 800; color: var(--ink);
}
.success p {
  margin: 0 auto; max-width: 420px;
  font-size: 14.5px; line-height: 1.75;
  color: var(--muted); text-wrap: pretty;
}
.success__email {
  display: inline-block;
  margin-top: 22px; padding: 11px 18px;
  border: 1px solid var(--border);
  font-size: 14px; line-height: 1.5; color: var(--muted);
  max-width: 100%; text-align: center;
  overflow-wrap: anywhere; /* only the long email token breaks, never "notify" */
}
.success__email strong {
  color: var(--ink); font-weight: 700;
  white-space: nowrap; /* keep the address on one line when it fits */
}
@media (max-width: 480px) {
  /* On phones, stack the label above the address for a clean wrap. */
  .success__email strong { display: block; white-space: normal; margin-top: 2px; }
}
.success__resubscribe {
  display: block; width: fit-content; margin: 18px auto 0; padding: 0;
  border: none; background: none; cursor: pointer;
  font-family: var(--font); font-size: 13px; font-weight: 600;
  color: var(--muted-2);
  text-decoration: underline; text-underline-offset: 3px;
  transition: color .2s;
}
.success__resubscribe:hover { color: var(--blue); }

/* ---------- Socials ---------- */
.socials {
  display: flex; justify-content: center; gap: 16px;
  padding: 0 0 48px;
}
.social {
  display: flex; align-items: center; justify-content: center;
  width: 48px; height: 48px; border-radius: 50%;
  border: 1px solid var(--border);
  background: #ffffff; color: var(--muted-3);
  transition: border-color .3s, background .3s, color .3s,
              transform .25s cubic-bezier(.2,.7,.2,1);
}
.social:hover {
  border-color: var(--blue); background: var(--blue);
  color: #ffffff; transform: translateY(-3px);
}

/* ---------- Footer ---------- */
.footer {
  border-top: 1px solid var(--border-soft);
  padding: 28px 0 40px;
  display: flex; flex-wrap: wrap;
  align-items: center; justify-content: space-between;
  gap: 12px;
  font-size: 12px; color: var(--muted-2);
}
.footer strong { color: var(--ink); }

/* ---------- Animations ---------- */
@keyframes osRise {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes osBlink {
  0%, 100% { opacity: 1; }
  50% { opacity: .25; }
}

.reveal { animation: osRise .8s cubic-bezier(.2,.7,.2,1) both; }
.topbar.reveal { animation-duration: .7s; }
.reveal--delay { animation-delay: 0s; }
.reveal--delay-2 { animation-delay: .15s; }

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