:root {
  --deep: #081619;
  --teal: #0c2a2e;
  --teal-2: #123a3f;
  --brass: #b9944b;
  --brass-hi: #d8b56a;
  --ivory: #efe7d8;
  --ivory-dim: #b9b2a4;
  --orange: #c8622c;
  --cognac: #9a5b34;
  --walnut: #2a1d15;
  --line: rgba(185, 148, 75, 0.35);

  --font-display: "Cormorant Garamond", Georgia, serif;
  --font-label: "Oswald", "Arial Narrow", sans-serif;
  --font-body: "Source Sans 3", system-ui, sans-serif;
}

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

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(ellipse 90% 60% at 50% 0%, var(--teal-2) 0%, transparent 70%),
    linear-gradient(180deg, var(--teal) 0%, var(--deep) 55%, #050d0f 100%);
  background-color: var(--deep);
  color: var(--ivory);
  font: 400 1.0625rem/1.65 var(--font-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--brass-hi); text-underline-offset: 3px; }
a:hover { color: var(--ivory); }
:focus-visible { outline: 2px solid var(--brass-hi); outline-offset: 3px; }

.embers {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

.hero, main, .footer { position: relative; z-index: 1; }

/* ---------- Hero ---------- */

.hero {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 48px 16px 64px;
}

.hero__logo { margin: 0; width: min(560px, 88vw); }

.phoenix-btn {
  all: unset;
  display: block;
  cursor: pointer;
  border-radius: 8px;
  touch-action: manipulation; /* no double-tap zoom, so rapid taps all register */
  -webkit-tap-highlight-color: transparent;
  -webkit-touch-callout: none;
  user-select: none;
}
.phoenix-btn:focus-visible { outline: 2px solid var(--brass-hi); outline-offset: 8px; }
.phoenix-btn img { filter: drop-shadow(0 0 28px rgba(216, 181, 106, 0.18)); transition: filter .4s; }
.phoenix-btn:hover img { filter: drop-shadow(0 0 36px rgba(216, 181, 106, 0.35)); }
.phoenix-btn.is-poked { animation: flutter .45s ease; }

/* ---------- Opening sequence (see js/intro.js) ---------- */

.intro-stage, .intro-canvas, .intro-flash, .flyer { display: none; }

.js-intro .intro-stage {
  display: block;
  position: fixed;
  inset: 0;
  z-index: 4;
  background: radial-gradient(ellipse 80% 60% at 50% 70%, #0a1416 0%, #020506 70%);
}
.intro-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 5;
  pointer-events: none;
}
.intro-canvas.is-live { display: block; }
.intro-flash {
  position: fixed;
  inset: 0;
  z-index: 7;
  pointer-events: none;
  opacity: 0;
  background: radial-gradient(circle at var(--fx, 50%) var(--fy, 50%), #fff6df 0%, rgba(255, 190, 110, .85) 25%, rgba(200, 98, 44, .35) 55%, transparent 80%);
}
.intro-flash.is-live { display: block; }

.js-intro .flyer {
  display: block;
  position: fixed;
  top: 0;
  left: 0;
  z-index: 6;
  pointer-events: none;
  opacity: 0;
  will-change: transform, opacity, filter;
}
.flyer__bird {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
  filter: drop-shadow(0 0 14px rgba(255, 200, 120, .7)) drop-shadow(0 0 44px rgba(200, 98, 44, .55));
}
/* Pivot points are in the SVG's 480x372 user units (shoulders sit just above the breast ring). */
.flyer__bird g { transform-box: view-box; }
.flyer__bird #wing-left { transform-origin: 228px 222px; }
.flyer__bird #wing-right { transform-origin: 252px 222px; }
.flyer__bird #tail { transform-origin: 240px 240px; }
.flyer__bird #halo { opacity: 0; } /* the halo appears with the logo on landing */

.flyer.is-flapping .flyer__bird { animation: flare .6s ease-in-out infinite; }
.flyer.is-flapping #wing-left { animation: flap-left .6s ease-in-out infinite; }
.flyer.is-flapping #wing-right { animation: flap-right .6s ease-in-out infinite; }
.flyer.is-flapping #tail { animation: tail-sway 1.2s ease-in-out infinite; }
.flyer.is-flapping #head, .flyer.is-flapping #body { animation: bob .6s ease-in-out infinite; }

/* Each beat starts and ends at rest so flapping can stop cleanly between beats. */
@keyframes flap-left {
  0%, 100% { transform: none; }
  35%      { transform: rotate(14deg); }
  72%      { transform: rotate(-24deg) scaleY(.9); }
}
@keyframes flap-right {
  0%, 100% { transform: none; }
  35%      { transform: rotate(-14deg); }
  72%      { transform: rotate(24deg) scaleY(.9); }
}
@keyframes tail-sway {
  0%, 100% { transform: none; }
  25%      { transform: rotate(-5deg); }
  75%      { transform: rotate(5deg); }
}
@keyframes bob {
  72% { transform: translateY(5px); }
}
@keyframes flare { /* each downstroke flares brighter */
  72% { filter: brightness(1.2) drop-shadow(0 0 20px rgba(255, 210, 140, .95)) drop-shadow(0 0 60px rgba(230, 110, 40, .75)); }
}

/* Logo: phoenix appears where the flyer lands; the name burns in left to right. */
.phoenix-btn { position: relative; }
.logo-hot { display: none; }

.js-intro .hero__logo img,
.js-intro .hero > :not(.hero__logo) { opacity: 0; }

.js-intro.is-landed .hero__logo .logo-main {
  opacity: 1;
  -webkit-mask: linear-gradient(#000, #000) top / 100% 67.5% no-repeat,
                linear-gradient(90deg, #000 0 45%, transparent 55% 100%) 100% 0 / 300% 100% no-repeat;
          mask: linear-gradient(#000, #000) top / 100% 67.5% no-repeat,
                linear-gradient(90deg, #000 0 45%, transparent 55% 100%) 100% 0 / 300% 100% no-repeat;
}
.js-intro.is-landed .logo-hot {
  display: block;
  position: absolute;
  inset: 0;
  opacity: 1;
  clip-path: inset(67.5% 0 0 0);
  filter: sepia(1) saturate(9) hue-rotate(-18deg) brightness(1.15) drop-shadow(0 0 6px rgba(255, 130, 50, .95));
  -webkit-mask: linear-gradient(90deg, transparent 0 40%, #000 47% 53%, transparent 60% 100%) 100% 0 / 300% 100% no-repeat;
          mask: linear-gradient(90deg, transparent 0 40%, #000 47% 53%, transparent 60% 100%) 100% 0 / 300% 100% no-repeat;
}
.js-intro.is-burning .logo-main,
.js-intro.is-burning .logo-hot { animation: burn var(--burn, 1.5s) cubic-bezier(.45, .1, .4, 1) forwards; }
.js-intro.is-burning .logo-main { animation-name: burn-main; }
@keyframes burn { to { -webkit-mask-position: 0 0; mask-position: 0 0; } }
@keyframes burn-main {
  to { -webkit-mask-position: top, 0 0; mask-position: top, 0 0; }
}

.js-intro.is-landed .hero > :not(.hero__logo) { opacity: 1; transition: opacity .9s ease .5s; }
.js-intro.is-landed .hero > :nth-child(3) { transition-delay: .75s; }
.js-intro.is-landed .hero > :nth-child(4),
.js-intro.is-landed .hero > :nth-child(5) { transition-delay: 1s; }
.js-intro.is-landed .hero > :nth-child(6) { transition-delay: 1.25s; }
.js-intro.is-landed .hero > :nth-child(7) { transition-delay: 1.5s; }
.js-intro.is-landed .hero > .replay { transition-delay: 2s; }

.replay {
  display: none;
  position: absolute;
  top: 16px;
  right: 16px;
  font: 400 .72rem/1 var(--font-label);
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--ivory-dim);
  background: none;
  border: 1px solid transparent;
  border-radius: 2px;
  padding: 10px 12px;
  cursor: pointer;
}
.replay:hover { color: var(--brass-hi); border-color: var(--line); }
.motion-ok .replay { display: block; }

@keyframes rise {
  from { opacity: 0; transform: translateY(40px) scale(.96); filter: blur(6px); }
  to   { opacity: 1; transform: none; filter: none; }
}
@keyframes flutter {
  30% { transform: translateY(-6px) scale(1.02); }
  60% { transform: translateY(2px) scale(.995); }
}

.eyebrow {
  font: 500 .8rem/1.4 var(--font-label);
  letter-spacing: .32em;
  text-transform: uppercase;
  color: var(--brass);
  margin: 40px 0 8px;
}

.hero__date {
  font: 500 clamp(1.75rem, 5vw, 2.6rem)/1.1 var(--font-display);
  margin: 0 0 24px;
}

.countdown {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(8px, 2.5vw, 20px);
  width: min(520px, 100%);
}
.countdown__unit {
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 14px 4px 10px;
  background: rgba(8, 22, 25, 0.55);
  backdrop-filter: blur(2px);
}
.countdown__unit span {
  display: block;
  font: 600 clamp(1.9rem, 7vw, 3rem)/1 var(--font-display);
  font-variant-numeric: tabular-nums;
}
.countdown__unit small {
  display: block;
  margin-top: 6px;
  font: 400 .68rem/1 var(--font-label);
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--ivory-dim);
}
.countdown__open {
  font: 500 1.6rem/1.3 var(--font-display);
  color: var(--brass-hi);
  margin: 0;
}

.promise {
  font: 500 clamp(1.3rem, 3.6vw, 1.7rem)/1.35 var(--font-display);
  margin: 32px 0 28px;
}
.promise em { color: var(--brass-hi); }

.btn {
  display: inline-block;
  font: 500 .9rem/1 var(--font-label);
  letter-spacing: .24em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--ivory);
  border: 1px solid var(--brass);
  border-radius: 2px;
  padding: 16px 28px;
  background: transparent;
  cursor: pointer;
  transition: background .25s, color .25s;
}
.btn:hover { background: var(--brass); color: var(--deep); }
.btn--solid { background: var(--brass); color: var(--deep); width: 100%; }
.btn--solid:hover { background: var(--brass-hi); }
.btn[disabled] { opacity: .6; cursor: progress; }

/* ---------- Sections ---------- */

main section {
  width: min(960px, 100%);
  margin: 0 auto;
  padding: 72px 16px;
  text-align: center;
}

.section-title {
  font: 500 clamp(2rem, 6vw, 3rem)/1.1 var(--font-display);
  margin: 0 0 16px;
}
.section-title::after {
  content: "";
  display: block;
  width: 64px;
  height: 1px;
  background: var(--brass);
  margin: 20px auto 0;
}
.section-lede { color: var(--ivory-dim); max-width: 36em; margin: 0 auto 32px; }

.intro p { max-width: 38em; margin: 0 auto 18px; font-size: 1.125rem; }
.intro__name { color: var(--ivory-dim); }
.intro__name strong { color: var(--brass-hi); font-weight: 600; }

/* ---------- Reveals ---------- */

.reveal-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  text-align: left;
}

.reveal {
  position: relative;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 24px;
  background: linear-gradient(160deg, rgba(18, 58, 63, .6), rgba(8, 22, 25, .8));
  overflow: hidden;
}
.reveal--finale { grid-column: 1 / -1; }
.reveal__num {
  font: 400 .72rem/1 var(--font-label);
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--brass);
  margin: 0 0 10px;
}
.reveal__title { font: 600 1.7rem/1.15 var(--font-display); margin: 0 0 12px; }
.reveal p { margin: 0 0 10px; }
.reveal__kicker { font-style: italic; font-family: var(--font-display); font-size: 1.15rem; color: var(--brass-hi); }

.reveal__lock {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ivory-dim);
  font: 400 .8rem/1.4 var(--font-label);
  letter-spacing: .16em;
  text-transform: uppercase;
}
.reveal__lock svg { flex: none; color: var(--brass); }
.reveal.is-locked .reveal__title { color: var(--ivory-dim); }
.reveal.is-locked::after {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(135deg, transparent 0 14px, rgba(185, 148, 75, .04) 14px 15px);
  pointer-events: none;
}
.reveal.is-new { animation: ignite 1.4s ease both; }
@keyframes ignite {
  from { box-shadow: 0 0 0 rgba(200, 98, 44, 0); }
  30%  { box-shadow: 0 0 40px rgba(200, 98, 44, .45); border-color: var(--orange); }
  to   { box-shadow: 0 0 0 rgba(200, 98, 44, 0); }
}

/* ---------- Signup ---------- */

.join { max-width: 560px; }
.signup { text-align: left; display: grid; gap: 18px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 420px) { .field-row { grid-template-columns: 1fr; gap: 18px; } }
.field label, .consent span { font-size: .95rem; }
.field label { display: block; margin-bottom: 6px; font-weight: 600; }
.optional { font-weight: 400; color: var(--ivory-dim); }
.field input {
  width: 100%;
  font: inherit;
  color: var(--ivory);
  background: rgba(8, 22, 25, .7);
  border: 1px solid var(--line);
  border-radius: 2px;
  padding: 12px 14px;
}
.field input:focus { border-color: var(--brass-hi); outline: none; box-shadow: 0 0 0 2px rgba(216, 181, 106, .25); }
.field input[aria-invalid="true"] { border-color: var(--orange); }

.consent { display: flex; gap: 12px; align-items: flex-start; color: var(--ivory-dim); }
.consent span { font-size: .82rem; line-height: 1.5; }
.consent input { accent-color: var(--brass); width: 18px; height: 18px; margin-top: 2px; flex: none; }

.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.signup__status { margin: 0; min-height: 1.5em; text-align: center; }
.signup__status.is-error { color: #e58a5a; }
.signup__status.is-success { color: var(--brass-hi); font: 500 1.35rem/1.35 var(--font-display); }

/* ---------- Hiring ---------- */

.roles {
  list-style: none;
  padding: 0;
  margin: 0 auto 32px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}
.roles li {
  font: 500 .95rem/1 var(--font-label);
  letter-spacing: .18em;
  text-transform: uppercase;
  border: 1px solid var(--line);
  padding: 14px 18px;
  border-radius: 2px;
}
.hiring__soon { color: var(--ivory-dim); margin: 0; }

/* ---------- Footer ---------- */

.footer {
  text-align: center;
  padding: 64px 16px 40px;
  border-top: 1px solid var(--line);
  margin-top: 40px;
}
.footer__mark {
  all: unset;
  display: block;
  width: 72px;
  margin: 0 auto 20px;
  opacity: .9;
  cursor: pointer;
  border-radius: 4px;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  -webkit-touch-callout: none;
  user-select: none;
  transition: opacity .3s, filter .3s;
}
.footer__mark:hover { opacity: 1; filter: drop-shadow(0 0 12px rgba(216, 181, 106, .5)); }
.footer__mark:focus-visible { outline: 2px solid var(--brass-hi); outline-offset: 6px; }
.footer__mark.is-poked { animation: flutter .45s ease; }
.footer address { font-style: normal; font: 500 1.35rem/1.35 var(--font-display); }
.footer address a { color: var(--ivory); text-decoration: none; }
.footer address a:hover { color: var(--brass-hi); }
.footer__river {
  font: 400 .75rem/1 var(--font-label);
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--brass);
  margin: 12px 0 24px;
}
.social { list-style: none; padding: 0; margin: 0 0 32px; display: flex; justify-content: center; gap: 28px; }
.social a {
  font: 500 .85rem/1 var(--font-label);
  letter-spacing: .22em;
  text-transform: uppercase;
  text-decoration: none;
}
.footer__whisper { font-size: .75rem; color: rgba(239, 231, 216, .18); margin: 0 0 12px; }
.footer__whisper:hover { color: rgba(239, 231, 216, .5); }
.footer__legal { font-size: .8rem; color: var(--ivory-dim); margin: 0; }
.nobr { white-space: nowrap; }

/* ---------- Secret ---------- */

.secret {
  width: min(460px, calc(100vw - 32px));
  border: 1px solid var(--brass);
  border-radius: 4px;
  padding: 36px 28px 28px;
  text-align: center;
  color: var(--ivory);
  background: radial-gradient(ellipse at top, var(--teal-2), var(--deep) 75%);
  box-shadow: 0 0 80px rgba(200, 98, 44, .35);
}
.secret::backdrop { background: rgba(3, 8, 9, .8); backdrop-filter: blur(3px); }
.secret[open] { animation: rise .7s cubic-bezier(.2, .7, .2, 1) both; }
.secret__mark { width: 96px; margin: 0 auto; }
.secret .eyebrow { margin-top: 16px; }
.secret h2 { font: 600 2.2rem/1.1 var(--font-display); margin: 0 0 16px; }
.secret p { margin: 0 0 12px; }
.secret__phrase {
  font: italic 500 1.6rem/1.3 var(--font-display);
  color: var(--brass-hi);
  padding: 12px 0;
}
.secret__fine { font-size: .78rem; color: var(--ivory-dim); margin-bottom: 24px !important; }

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