:root {
  --black: #000000;
  --chrome: #edeef0;
  --silver: #c9ccd1;
  --steel: #9aa0a8;
  --gunmetal: #2a2d32;
  --dim: #5d626a;

  --mark-w: min(86vw, 1080px);
  --tail: 0.4415; /* left edge of the 7's tail, as a share of the wordmark width */

  --ease-out: cubic-bezier(.12, .9, .18, 1);
  --ease-io: cubic-bezier(.65, 0, .35, 1);

  color-scheme: dark;
}

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

html {
  -webkit-text-size-adjust: 100%;
  background: var(--black);
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  grid-template-rows: 1fr auto;
  background: var(--black);
  color: var(--chrome);
  font-family: "Lexend", system-ui, sans-serif;
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Film grain. Overlay keeps black areas truly black and only textures the light. */
body::after {
  content: "";
  position: fixed;
  inset: -50%;
  pointer-events: none;
  z-index: 10;
  opacity: .18;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 1s steps(6) infinite;
}

@keyframes grain {
  0%   { transform: translate(0, 0); }
  20%  { transform: translate(-3%, 2%); }
  40%  { transform: translate(2%, -4%); }
  60%  { transform: translate(-4%, -1%); }
  80%  { transform: translate(3%, 3%); }
  100% { transform: translate(0, 0); }
}

/* Studio light overhead, nudged by the pointer */
.softbox {
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 55vw 38vh at var(--lx, 50%) var(--ly, 30%), rgba(255, 255, 255, .045), transparent 70%),
    radial-gradient(ellipse 120% 90% at 50% 40%, transparent 55%, rgba(0, 0, 0, .9));
  opacity: 0;
  animation: fade-in 2.4s .2s ease forwards;
}

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

/* ---------- Stage ---------- */

.stage {
  position: relative;
  width: var(--mark-w);
  margin: 0 auto;
  align-self: center;
  padding: clamp(40px, 9vh, 120px) 0 48px;
}

.mark {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}

/* Bars arrive from the right as streaks of light, like the lines in the monogram */
.bar {
  transform-box: fill-box;
  transform-origin: left center;
  animation: streak-in 1.15s var(--ease-out) calc(var(--d) + .1s) both;
}

@keyframes streak-in {
  0%   { transform: translateX(900%) scaleX(6); opacity: 0; }
  12%  { opacity: 1; }
  100% { transform: none; opacity: 1; }
}

.trail {
  transform-box: fill-box;
  transform-origin: left center;
  opacity: 0;
  animation: trail 1.6s var(--ease-out) calc(var(--d) + .25s) both;
}

@keyframes trail {
  0%   { opacity: 0; transform: scaleX(1); }
  14%  { opacity: .65; }
  100% { opacity: 0; transform: scaleX(.02); }
}

/* S and N are traced in hairline, then filled */
.traced {
  stroke: #fff;
  stroke-width: .28;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  fill-opacity: 0;
  animation:
    trace 1.5s var(--ease-io) calc(.35s + var(--d, 0s)) forwards,
    fill-up .7s ease calc(1.55s + var(--d, 0s)) forwards;
}

@keyframes trace { to { stroke-dashoffset: 0; } }
@keyframes fill-up { to { fill-opacity: 1; stroke-opacity: 0; } }

/* The 7 is drawn last, top bar then the long drop below the baseline */
.pen {
  fill: none;
  stroke: #fff;
  stroke-width: 8;
  stroke-linecap: butt;
  stroke-linejoin: miter;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  animation: trace 1s var(--ease-io) 1.05s forwards;
}

.bloom {
  opacity: 0;
  animation: bloom 2.2s ease-out 1.85s forwards;
}

@keyframes bloom {
  0%   { opacity: 0; }
  18%  { opacity: .55; }
  100% { opacity: .1; }
}

.floor {
  opacity: 0;
  animation: floor 2s ease 2.1s forwards;
}

@keyframes floor { to { opacity: .34; } }

.floor-line {
  transform-box: view-box;
  transform-origin: 128.1px 61.61px;
  transform: scaleX(0);
  animation: floor-line 1.8s var(--ease-out) 1.9s forwards;
}

@keyframes floor-line {
  0%   { transform: scaleX(0); opacity: 1; }
  100% { transform: scaleX(1); opacity: .7; }
}

.touch {
  opacity: 0;
  animation: touch 1.6s ease-out 1.88s forwards;
}

@keyframes touch {
  0%   { opacity: 0; }
  12%  { opacity: 1; }
  100% { opacity: .22; }
}

.models-letter {
  stroke-dasharray: 1 1.2;
  stroke-dashoffset: 1;
  opacity: 0;
  animation:
    fade-in .2s linear calc(2.15s + var(--i) * .08s) forwards,
    trace .9s var(--ease-io) calc(2.15s + var(--i) * .08s) forwards,
    solid 1ms linear calc(3.06s + var(--i) * .08s) forwards;
}

/* Once drawn, drop the dash so closed letters (O, D) join cleanly */
@keyframes solid { to { stroke-dasharray: none; stroke-dashoffset: 0; } }

.sheen {
  opacity: .9;
  transform: skewX(-24deg);
  mix-blend-mode: screen;
}

/* ---------- Copy ---------- */

.copy {
  position: relative;
  margin-top: calc(var(--mark-w) * -0.012);
  padding-left: calc(var(--mark-w) * var(--tail));
  max-width: 100%;
}

.headline {
  margin: 0 0 1.1rem;
  font-family: "Lexend Exa", "Lexend", sans-serif;
  font-weight: 300;
  font-size: clamp(1.3rem, .9rem + 1.25vw, 2.05rem);
  line-height: 1.22;
  letter-spacing: -.01em;
  color: var(--chrome);
}

.headline .line { display: block; }
.headline .line + .line { color: var(--steel); }

.lede {
  margin: 0 0 2rem;
  max-width: 38ch;
  text-wrap: pretty;
  font-size: 1rem;
  line-height: 1.65;
  color: var(--steel);
}

.headline .line,
.lede,
.signup {
  opacity: 0;
  animation: rise 1.1s var(--ease-out) forwards;
}

.headline .line:nth-child(1) { animation-delay: 2.45s; }
.headline .line:nth-child(2) { animation-delay: 2.6s; }
.lede                        { animation-delay: 2.8s; }
.signup                      { animation-delay: 2.95s; }

@keyframes rise {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: none; }
}

/* ---------- Sign-up ---------- */

.signup { max-width: 27rem; }

.signup label {
  display: block;
  margin-bottom: .7rem;
  font-size: .875rem;
  font-weight: 400;
  color: var(--silver);
}

.field {
  display: flex;
  align-items: stretch;
  padding: 4px;
  border: 1px solid var(--gunmetal);
  border-radius: 3px;
  background: rgba(255, 255, 255, .025);
  transition: border-color .25s ease, background-color .25s ease;
}

.field:focus-within {
  border-color: var(--steel);
  background: rgba(255, 255, 255, .04);
}

.field input[type="email"] {
  flex: 1;
  min-width: 0;
  height: 44px;
  padding: 0 12px;
  border: 0;
  background: transparent;
  color: var(--chrome);
  font: inherit;
  font-size: 1rem;
  outline: none;
}

.field input::placeholder { color: var(--dim); }

/* Bot trap. display:none keeps browser autofill from filling it for real people. */
.hp { display: none; }

.signup button {
  position: relative;
  overflow: hidden;
  flex: none;
  height: 44px;
  padding: 0 20px;
  border: 0;
  border-radius: 2px;
  background: var(--chrome);
  color: var(--black);
  font-family: "Lexend Exa", "Lexend", sans-serif;
  font-weight: 400;
  font-size: .8rem;
  letter-spacing: .02em;
  cursor: pointer;
  transition: background-color .25s ease;
}

.signup button::after {
  content: "";
  position: absolute;
  inset: 0 auto 0 -60%;
  width: 50%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .95), transparent);
  transform: skewX(-24deg);
  transition: none;
}

.signup button:hover { background: #fff; }

.signup button:hover::after {
  left: 130%;
  transition: left .7s var(--ease-out);
}

.signup button:focus-visible,
.foot a:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 3px;
}

.signup button[disabled] { cursor: progress; opacity: .7; }

.status {
  min-height: 1.5em;
  margin: .8rem 0 0;
  font-size: .875rem;
  color: var(--steel);
}

.status.is-error { color: #e8b4ae; }

.signup.is-done .field { display: none; }
.signup.is-done label { display: none; }
.signup.is-done .status {
  margin-top: 0;
  font-size: 1rem;
  color: var(--chrome);
  animation: rise .9s var(--ease-out);
}

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

.foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 22px clamp(16px, 4vw, 40px) max(22px, env(safe-area-inset-bottom));
  font-size: .78rem;
  color: var(--dim);
  opacity: 0;
  animation: fade-in 1.4s 3.2s ease forwards;
}

.foot p { margin: 0; }

.monogram {
  width: 18px;
  height: auto;
  color: var(--steel);
}

@keyframes fade-in { to { opacity: 1; } }

/* ---------- Small screens ---------- */

@media (max-width: 760px) {
  :root { --mark-w: calc(100vw - 32px); }

  .stage { padding-top: clamp(48px, 14vh, 120px); }

  .copy {
    margin-top: 8px;
    padding-left: 0;
  }

  .headline { font-size: clamp(1.25rem, 5.4vw, 1.6rem); }
}

@media (max-width: 340px) {
  .field { flex-direction: column; gap: 4px; }
  .signup button { width: 100%; }
}

/* ---------- Reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    animation-delay: 0s !important;
    transition-duration: 1ms !important;
  }

  body::after { animation: none; }
}
