/* flowstate.build: one stylesheet for the homepage, /support and the 404. */

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url(/assets/fonts/inter-latin.woff2) format("woff2");
}
@font-face {
  font-family: "Newsreader";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/assets/fonts/newsreader-latin.woff2) format("woff2");
}

:root {
  color-scheme: dark;
  --ground: #050506;
  --ink: #f3eee7;
  --ink-2: rgba(243, 238, 231, 0.74);
  --ink-3: rgba(243, 238, 231, 0.48);
  --ink-4: rgba(243, 238, 231, 0.36);
  --accent: #ff6b35;
  --glow: rgba(255, 107, 53, 0.075);
  --serif: "Newsreader", "Iowan Old Style", Georgia, serif;
  --sans: "Inter", -apple-system, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100svh;
  color: var(--ink);
  font: 16px/1.6 var(--sans);
  background:
    radial-gradient(56rem 36rem at 50% 34vh, var(--glow), transparent 62%),
    linear-gradient(160deg, #000 0%, var(--ground) 55%, #080708 100%);
  background-color: var(--ground);
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-underline-offset: 3px; }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; border-radius: 4px; }

/* The icon, the way the App Store shows it, lit from behind. */
.icon {
  width: 120px;
  height: 120px;
  border-radius: 27px;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.09),
    0 28px 90px -18px rgba(255, 107, 53, 0.42);
}

/* Homepage: Aura's shape. The note sits on the bottom edge. */
.hero {
  min-height: 100svh;
  display: grid;
  grid-template-rows: 1fr auto 1fr;
  justify-items: center;
  padding: 48px 16px 20px;
  text-align: center;
}
.hero > div { grid-row: 2; }
.mark { margin: 0; line-height: 0; }
.tagline {
  margin: 28px 0 0;
  font: 400 20px/1.42 var(--serif);
  letter-spacing: 0.005em;
}
.badge { display: inline-block; margin-top: 36px; line-height: 0; border-radius: 10px; }
.badge img { height: 54px; width: auto; }
.links { margin: 22px 0 0; font-size: 13px; color: var(--ink-3); }
.links a { color: var(--ink-3); }
.links a:hover { color: var(--ink-2); }
.links span { margin: 0 8px; }
/* What Google's homepage rule asks for, as quietly as it can be said. */
.note {
  grid-row: 3;
  align-self: end;
  max-width: 34rem;
  margin: 40px 0 0;
  font-size: 12px;
  line-height: 1.55;
  color: var(--ink-4);
  text-wrap: pretty;
}

/* Intro: the wheel alone, then it fades into the page (assets/intro.js). */
.stage {
  position: fixed;
  inset: 0;
  z-index: 2;
  display: none;
  place-items: center;
  padding: 0 16px;
  transition: opacity 0.7s ease, transform 0.9s cubic-bezier(0.2, 0.7, 0.2, 1), filter 0.7s ease;
}
html.intro .stage, .stage.out { display: grid; }
.stage.out { opacity: 0; transform: scale(0.97); filter: blur(3px); pointer-events: none; }
html.intro .rise { animation: none; opacity: 0; }

/* The wheel: "For the" fixed, the words roll and settle on creators. */
.wheel {
  --row: 1.04em;
  width: max-content;
  display: grid;
  grid-template-columns: auto auto;
  column-gap: 0.26em;
  align-items: center;
  font: 700 clamp(32px, 6.6vw, 64px)/1 var(--sans);
  letter-spacing: -0.035em;
  animation: wheel-in 0.5s ease both;
}
@keyframes wheel-in { from { opacity: 0; } }
.wheel .fixed { white-space: nowrap; }
.wheel .window { position: relative; height: calc(var(--row) * 5); overflow: hidden; }
.wheel .sizer { display: block; height: 0; visibility: hidden; }
.wheel .col { position: absolute; left: 0; top: 0; will-change: transform; }
.wheel .w { display: block; width: max-content; height: var(--row); line-height: var(--row); white-space: nowrap; }
/* Only the word it lands on carries the wordmark's gradient, lit as it settles. */
.wheel .w.final {
  background: linear-gradient(90deg, #f6ead6 0%, #f4c46a 48%, #ff7a3d 78%, #f0431f 100%);
  -webkit-background-clip: text;
  background-clip: text;
  transition: color 0.6s ease;
}
.wheel .w.final.lit { color: transparent; }

/* Entrance: one soft rise, off for reduced motion. */
.rise { animation: rise 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
.d1 { animation-delay: 0.08s; }
.d2 { animation-delay: 0.16s; }
.d3 { animation-delay: 0.24s; }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } }

/* The waitlist sheet behind the badge until the listing is public. It opens by
   script (assets/waitlist.js), or by #waitlist when scripts do not run. */
.sheet { position: fixed; inset: 0; z-index: 10; display: none; place-items: center; padding: 16px; }
html:not(.js) .sheet:target, .sheet.open { display: grid; }
html.sheet-open { overflow: hidden; }
.sheet .scrim {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.62);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  animation: fade 0.25s ease both;
}
.sheet .card {
  position: relative;
  width: min(100%, 24rem);
  padding: 32px 24px 20px;
  text-align: center;
  border-radius: 20px;
  background: #0f0d0d;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 180, 140, 0.12), 0 30px 80px -20px rgba(0, 0, 0, 0.8);
  animation: sheet-up 0.45s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}
.sheet .icon { width: 64px; height: 64px; border-radius: 15px; }
.sheet h2 { margin: 20px 0 8px; font: 400 24px/1.25 var(--serif); text-wrap: balance; }
.sheet .lede { margin: 0 0 20px; font-size: 15px; line-height: 1.5; color: var(--ink-2); text-wrap: pretty; }
.sheet input[type="email"] {
  width: 100%;
  height: 48px;
  padding: 0 14px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.04);
  color: var(--ink);
  font: 16px var(--sans);
}
.sheet input[type="email"]::placeholder { color: var(--ink-4); }
.sheet input[type="email"]:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.18); }
.sheet button {
  width: 100%;
  height: 48px;
  margin-top: 10px;
  border: 0;
  border-radius: 12px;
  background: var(--ink);
  color: #0b0a0a;
  font: 600 16px var(--sans);
  cursor: pointer;
}
.sheet button:disabled { opacity: 0.6; cursor: default; }
.sheet button:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.sheet .status { min-height: 20px; margin: 10px 0 0; font-size: 13px; color: #ff9566; }
.sheet .fine { margin: 12px 0 0; font-size: 12px; color: var(--ink-3); }
.sheet .fine a { color: var(--ink-3); }
.sheet .fine span { margin: 0 8px; }
.sheet .thanks { display: none; }
.sheet.done .ask { display: none; }
.sheet.done .thanks { display: block; }
.trap { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@keyframes sheet-up { from { opacity: 0; transform: translateY(16px) scale(0.98); } }
@keyframes fade { from { opacity: 0; } }

/* Support and the 404. */
.page { max-width: 34rem; margin: 0 auto; padding: 64px 16px 56px; }
.page .home { display: block; width: max-content; margin: 0 auto; line-height: 0; border-radius: 18px; }
.page .icon { width: 80px; height: 80px; border-radius: 18px; }
.page h1 { margin: 36px 0 14px; font: 400 34px/1.2 var(--serif); }
.page p { margin: 0 0 14px; color: var(--ink-2); text-wrap: pretty; }
.page p a { color: var(--ink); }
.page .links { margin-top: 36px; }
.lost { text-align: center; }
.lost p { font: 400 20px/1.42 var(--serif); color: var(--ink); margin-top: 28px; }
.lost .links { font: 13px/1.6 var(--sans); color: var(--ink-3); margin-top: 22px; }

@media (prefers-reduced-motion: reduce) {
  .rise, .wheel, .sheet .card, .sheet .scrim { animation: none; }
}
@media (max-width: 480px) {
  .hero .icon { width: 104px; height: 104px; border-radius: 23px; }
  .tagline { font-size: 18px; }
  .badge img { height: 50px; }
}
