/* Gwan waitlist, take "Field": one screen, a centred poster. The words and the waitlist sit in the middle; the universe of tokens
   fills the screen around them, and the news and your alerts arrive at its edges as the app's notifications.
   Calm colour: stars mostly white and blue-white, the committed blue for Gwan and the interface, a soft coral for news.
   The one place green and red appear is the app's own: price direction and reads. No haze. */
@font-face { font-family: "Archivo"; src: url(fonts/Archivo-Variable.woff) format("woff"); font-weight: 100 900; font-stretch: 62% 125%; font-display: swap; }

.gwc { container-type: inline-size; }
.gw {
  --bg: #06080f;
  --panel: #0c111b;
  --ink: #edf1f8;
  --ink2: #b3bdcd;
  --label: #97a3b6;
  --neon: #91bfff;
  --neon-hi: #dcebff;
  --coral: #ff9c78;
  --on-neon: #0a1426;
  --font: "Archivo", "Gwan Sans", system-ui, sans-serif;
  --m: 40px;
  --screen: 100svh;
  --radius: 4px;
  --s-small: 0.875rem;
  --s-body: clamp(1rem, 0.95rem + 0.2cqi, 1.0625rem);
  --s-display: min(clamp(3.4rem, 9cqi, 8.5rem), calc(var(--screen) * 0.136));
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-expo: cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: clip;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: var(--s-body);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
html, body { margin: 0; background: #07090d; }
.gw *, .gw *::before, .gw *::after { box-sizing: border-box; }
:where(.gw) :where(h1, h2, h3, p, ol, ul, figure, fieldset, legend) { margin: 0; padding: 0; }
:where(.gw) fieldset { border: 0; min-width: 0; }
:where(.gw) a { color: inherit; }
.gw ::selection { background: var(--neon); color: var(--on-neon); }
.gw :focus-visible { outline: 2px solid var(--neon-hi); outline-offset: 3px; }
.gw p { text-wrap: pretty; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* ---------- the screen: the bar, the poster in the middle, the footer line; the sky behind all three ---------- */
.field { position: relative; display: grid; grid-template-rows: auto 1fr auto; min-height: var(--screen); }
.sky { position: absolute; inset: 0; z-index: 0; overflow: hidden; background: var(--bg); }
.sky-cv { display: block; width: 100%; height: 100%; }
.bar, .poster, .foot { position: relative; z-index: 1; }

.bar { display: flex; align-items: center; justify-content: center; height: clamp(64px, calc(var(--screen) * 0.098), 88px); padding: 0 var(--m); }
.brand { display: inline-flex; align-items: center; gap: 12px; font-size: 22px; font-weight: 600; letter-spacing: -0.01em; cursor: default; user-select: none; -webkit-user-select: none; }
.brand-mk svg { display: block; }

.poster { align-self: center; justify-self: center; display: grid; justify-items: center; width: fit-content; max-width: calc(100% - var(--m) * 2); padding-bottom: calc(var(--screen) * 0.025); text-align: center; }
.display { font-size: var(--s-display); font-weight: 600; line-height: 0.9; letter-spacing: 0.005em; text-transform: uppercase; font-variation-settings: "wdth" 125; font-stretch: 125%; }
.display .ln { display: block; }
.star-h { text-shadow: 0 0 1px rgba(237, 241, 248, 0.6), 0 0 16px rgba(145, 191, 255, 0.22); } /* taste-skill-ignore: starlight */
.say { max-width: 48ch; text-wrap: balance; margin: clamp(22px, calc(var(--screen) * 0.034), 32px) 0 clamp(24px, calc(var(--screen) * 0.038), 36px); color: var(--ink2); }

/* the waitlist: an email, one question that can be skipped, the confirmation; each step takes the last one's place */
.join { width: min(560px, 100%); text-align: left; }
.fld-row { display: flex; gap: 10px; }
.fld { flex: 1; min-width: 0; height: 52px; padding: 0 16px; border: 1px solid rgba(145, 191, 255, 0.45); border-radius: var(--radius); background: rgba(12, 17, 27, 0.96); color: var(--ink); font: 400 16px var(--font); outline: none; transition: border-color 200ms var(--ease-out), box-shadow 200ms var(--ease-out); }
.fld::placeholder { color: #6b778a; }
.fld:hover { border-color: rgba(145, 191, 255, 0.75); }
.fld:focus { border-color: var(--neon-hi); box-shadow: 0 0 14px rgba(145, 191, 255, 0.3); }
.fld[aria-invalid="true"] { border-color: #ff9d9d; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  height: 52px; padding: 0 24px; border: 0; border-radius: var(--radius);
  background: var(--neon); color: var(--on-neon);
  font: 600 var(--s-body)/1 var(--font); letter-spacing: 0.01em; text-decoration: none; white-space: nowrap; cursor: pointer;
  box-shadow: 0 0 0 1px rgba(220, 235, 255, 0.7) inset, 0 0 18px rgba(145, 191, 255, 0.32); /* taste-skill-ignore: lit bar */
  transition: box-shadow 240ms var(--ease-out), background-color 240ms var(--ease-out), transform 140ms var(--ease-out);
}
.btn:hover { background: var(--neon-hi); box-shadow: 0 0 0 1px #fff inset, 0 0 26px rgba(145, 191, 255, 0.5); }
.btn:active { transform: translateY(1px); }
.btn:disabled { cursor: default; background: rgba(145, 191, 255, 0.16); color: var(--ink2); box-shadow: 0 0 0 1px rgba(145, 191, 255, 0.32) inset; transform: none; }
.btn[aria-busy="true"] { cursor: progress; background: var(--neon); color: var(--on-neon); box-shadow: 0 0 0 1px rgba(220, 235, 255, 0.7) inset, 0 0 18px rgba(145, 191, 255, 0.32); }
.btn[aria-busy="true"]::before { content: ""; width: 14px; height: 14px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: gw-spin 700ms linear infinite; }
.fld:disabled { opacity: 0.7; }
@keyframes gw-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .btn[aria-busy="true"]::before { animation: none; } }
.su-fault { min-height: 1.5em; margin-top: 8px; color: #ff9d9d; font-size: var(--s-small); }
.su-note { color: var(--label); font-size: var(--s-small); text-align: center; }
.su[hidden] { display: none; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.q-t { margin-bottom: 4px; font-size: var(--s-body); font-weight: 600; text-align: center; width: 100%; }
.q-s { margin-bottom: 12px; color: var(--ink2); font-size: var(--s-small); text-align: center; }
.opts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.opt { position: relative; display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 9px 14px; border: 1px solid rgba(145, 191, 255, 0.26); border-radius: var(--radius); background: rgba(12, 17, 27, 0.96); font-size: 15px; line-height: 1.3; cursor: pointer; transition: border-color 200ms var(--ease-out), box-shadow 200ms var(--ease-out); }
.opt::before { content: ""; flex: none; width: 16px; height: 16px; border: 2px solid #6b778a; border-radius: 50%; }
.opt:hover { border-color: rgba(145, 191, 255, 0.6); }
.opt input { position: absolute; opacity: 0; pointer-events: none; }
.opt:has(input:checked) { border-color: var(--neon-hi); box-shadow: 0 0 12px rgba(145, 191, 255, 0.26); }
.opt:has(input:checked)::before { border: 5px solid var(--neon-hi); }
.opt:has(input:focus-visible) { outline: 2px solid var(--neon-hi); outline-offset: 2px; }
.acts { display: flex; align-items: center; justify-content: center; gap: 22px; margin-top: 14px; }
/* while the question is open the poster gives back a little room, so the whole step still fits a short screen */
.poster:has(.su[data-step="question"]:not([hidden])) { padding-bottom: 0; }
.poster:has(.su[data-step="question"]:not([hidden])) .say { margin-bottom: clamp(18px, calc(var(--screen) * 0.028), 28px); }
.skip { padding: 8px 0; border: 0; background: none; color: var(--ink2); font: 500 var(--s-body) var(--font); cursor: pointer; text-decoration: underline; text-underline-offset: 0.22em; }
.skip:hover { color: var(--ink); }
.su-done { text-align: center; }
.su-done .q-t { font-size: 1.25rem; margin-bottom: 8px; }
.su-done .q-s { max-width: 44ch; margin: 0 auto; overflow-wrap: anywhere; }
.su-done b { color: var(--ink); font-weight: 600; }
.su-done .again { margin-top: 14px; font-size: var(--s-small); }

/* the footer: one quiet line */
.foot { display: flex; align-items: center; justify-content: space-between; gap: 10px 32px; padding: 0 var(--m) 26px; font-size: 13px; color: var(--label); }
.foot-nav { display: flex; align-items: center; gap: 24px; }
.foot-nav a { color: var(--ink2); text-decoration: none; }
.foot-nav a:hover { color: var(--neon-hi); }

/* ---------- motion: the bar, the words and the form arrive once; the sky plays from the first second ---------- */
@media (prefers-reduced-motion: no-preference) {
  .js [data-intro] { opacity: 0; transform: translateY(14px); }
  .js .bar[data-intro] { transform: translateY(-12px); }
  .js .in [data-intro] { animation: rise 900ms var(--ease-expo) var(--d, 0ms) forwards; }
  .js [data-letters] .ch { opacity: 0; }
  .js .in [data-letters] .ch { animation: kindle 1100ms var(--ease-out) var(--dl, 0ms) forwards; }
}
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
/* a letter kindles like a star: a white point that opens into the letter */
@keyframes kindle {
  0% { opacity: 0; color: #fff; text-shadow: 0 0 0 #fff; filter: blur(3px); }
  30% { opacity: 1; color: #fff; text-shadow: 0 0 2px #fff, 0 0 14px rgba(220, 235, 255, 0.85); filter: none; }
  100% { opacity: 1; }
}

/* ---------- narrower ---------- */
@container (max-width: 1099px) {
  .gw { --m: 32px; }
}
/* a phone: the words and the form first, the sky opening below them, the footer under the sky */
@container (max-width: 719px) {
  .gw { --m: 18px; --s-body: 0.9375rem; --s-display: 15.6cqi; }
  .field { grid-template-rows: auto auto minmax(290px, 1fr) auto; }
  .bar { height: 64px; }
  .poster { align-self: start; padding: calc(var(--screen) * 0.02) 0 0; max-width: calc(100% - var(--m) * 2); }
  .say { margin: 16px 0 22px; line-height: 1.45; }
  .join { width: 100%; }
  .fld-row { flex-direction: column; }
  .fld { flex: none; }
  .fld-row .btn { width: 100%; }
  .opts { grid-template-columns: 1fr; gap: 6px; }
  .opt { min-height: 46px; padding: 9px 14px; }
  .foot { grid-row: 4; flex-direction: column; align-items: center; gap: 6px; padding: 0 var(--m) 18px; text-align: center; font-size: 12.5px; }
  .foot-nav { gap: 18px; }
}

/* Small legal controls use the existing font, panel and link colors. */
.su-note a { color: var(--ink2); text-underline-offset: 3px; }
.foot-nav { flex-wrap: wrap; justify-content: center; }
#waitlist-panel { box-sizing: border-box; width: min(640px, calc(100% - 32px)); max-height: calc(100svh - 48px); padding: 28px; border: 1px solid rgba(145, 191, 255, .45); border-radius: 4px; background: #0c111b; color: #edf1f8; font: 400 16px/1.6 "Archivo", system-ui, sans-serif; overflow: auto; }
#waitlist-panel::backdrop { background: rgba(0, 0, 0, .78); }
#waitlist-panel h2 { margin: 0 0 20px; font-size: 1.5rem; }
#waitlist-panel p { margin: 0 0 16px; }
#waitlist-panel a { color: #91bfff; overflow-wrap: anywhere; }
#waitlist-panel [hidden] { display: none; }
#waitlist-panel .panel-close { display: block; margin: 0 0 12px auto; }
#waitlist-panel .panel-small { color: #97a3b6; font-size: .875rem; }
