/* ============ Future ============ */

/* ============ Final CTA ============ */
.final-cta {
  text-align: center;
}
.final-cta h2 {
  font-size: clamp(28px, 4vw, 42px);
}
.final-cta p {
  margin-top: 16px;
  color: var(--ink-soft);
  font-size: 16.5px;
  max-width: 52ch;
  margin-inline: auto;
}
.final-cta .waitlist-form {
  margin-top: 30px;
}

/* ============ Sub-blocks ============ */
.ending .final-cta {
  margin-top: 0;
}
.ending {
  position: relative;
  background: #15130f;
  box-shadow: 0 0 0 100vmax #15130f;
  clip-path: inset(0 -100vmax);
  padding-block: 120px;
}
.ending .final-cta h2 {
  color: #faf9f5;
}
.ending .final-cta p {
  color: rgba(250, 249, 245, 0.68);
}
.ending .waitlist-form {
  background: #ffffff;
  border-color: transparent;
  height: 60px;
  box-sizing: border-box;
  align-items: center;
}
.ending .waitlist-form .wl-field input {
  color: #15130f;
}
.ending .waitlist-form .wl-field input::placeholder {
  color: #9a9689;
}
.ending .waitlist-form .btn-primary {
  background: #15130f;
  color: #faf9f5;
}
/* ---- Ending headline: words + image tiles (Figma frame 1.3) ---- */
.final-cta h2.mosaic {
  display: flex;
  flex-direction: column;
  gap: clamp(8px, 1.2vw, 18px);
  flex: none;
  width: min(calc(var(--vw) - 32px), 1000px);
  max-width: none;
  margin: 0 0 0 calc(50% - min(var(--vw) / 2 - 16px, 500px));
  padding-inline: 0;
  box-sizing: border-box;
  font: 400 clamp(24px, 3.8vw, 55px) / 1 var(--sans);
  letter-spacing: -0.01em;
  color: #ffffff;
  text-align: left;
  /* the tiles are windows onto one shared photo laid over the whole headline */
  --mzh: clamp(28px, 4.85vw, 70px);
  position: relative;
}
.mz-row {
  display: flex;
  align-items: center;
  gap: clamp(10px, 1.7vw, 25px);
}
.mz-w {
  flex: none;
  white-space: nowrap;
}
.mz-img {
  --mzh: clamp(28px, 4.85vw, 70px);
  display: block;
  height: var(--mzh);
  border-radius: 8px;
  clip-path: inset(0 round 8px);
  background: #222;
  transition:
    height 0.45s cubic-bezier(0.22, 0.8, 0.24, 1),
    margin-top 0.45s cubic-bezier(0.22, 0.8, 0.24, 1),
    border-radius 0.45s,
    clip-path 0.45s;
}
/* hover: tile grows taller; its row opens up smoothly so no words get covered */
@media (hover: hover) {
  /* same as before (the row opens up so no words are covered), but it opens UPWARD:
       the headline shifts up by the extra height and gives it back with a negative bottom margin,
       so everything from the hovered row down - and the form - stays put */
  .mz-img:hover {
    height: calc(var(--mzh) * 2);
    border-radius: 12px;
    clip-path: inset(0 round 12px);
  }
  /* headline box has a FIXED height and stacks its rows from the bottom, so a growing row can only push
       the rows above it upward - nothing below (the form) ever moves, not even by a pixel during the animation */
  .final-cta h2.mosaic {
    --mzh: clamp(28px, 4.85vw, 70px);
    --mzg: clamp(8px, 1.2vw, 18px);
    height: calc(var(--mzh) * 3 + var(--mzg) * 2);
    justify-content: flex-end;
    overflow: visible;
  }
}
@media (prefers-reduced-motion: reduce) {
  .mz-img {
    transition: none;
  }
}
/* positioned against the headline, not the tile, so every tile shows its own part of the
   photo; it reaches one tile height above the headline for rows pushed up by a hover */
.mz-img img {
  display: block;
  position: absolute;
  top: calc(var(--mzh) * -1);
  right: 0;
  bottom: 0;
  left: 0;
  width: 100%;
  height: calc(100% + var(--mzh));
  object-fit: cover;
}
.mz-grow {
  flex: 1 1 0;
  min-width: 0;
}
.mz-small {
  flex: 0 0 clamp(64px, 15vw, 200px);
}
.final-cta .waitlist-form {
  margin-top: calc(clamp(48px, 6vw, 88px) + 40px);
}
@media (max-width: 520px) {
  .mz-small {
    flex-basis: 64px;
  }
}
.ending {
  padding-bottom: 40px;
}
.end-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 120px;
  padding-top: 32px;
  position: relative;
}
.end-footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  width: 100vw;
  height: 1px;
  transform: translateX(-50%);
  background: rgba(250, 249, 245, 0.12);
}
footer.end-footer {
  border-top: 0;
  padding: 0;
  min-height: 120px;
  box-sizing: border-box;
}
.ending {
  padding-bottom: 0;
}
.end-footer .logo {
  color: #faf9f5;
  font-size: 19px;
}
.end-footer .logo-mark {
  width: 34px;
  height: 20px;
  color: #faf9f5;
}
@media (max-width: 760px) {
  footer.end-footer {
    padding-block: 14px;
  }
}
/* footer: copyright left, brand-colored socials bottom-right */
.foot-brand {
  margin-right: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.foot-row {
  display: flex;
  align-items: center;
}
.legal {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
}
.legal a {
  color: rgba(250, 249, 245, 0.62);
  text-decoration: none;
  transition: color 0.2s ease;
}
.legal a:hover {
  color: #faf9f5;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.legal a:focus-visible {
  outline: 2px solid #9089ff;
  outline-offset: 3px;
  border-radius: 3px;
}
.legal span {
  color: rgba(250, 249, 245, 0.3);
}
.socials {
  display: flex;
  align-items: center;
  gap: 12px;
}
.soc {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 38px;
  min-width: 38px;
  border-radius: 999px;
  color: #fff;
  text-decoration: none;
  transition:
    transform 0.2s ease,
    filter 0.2s ease;
}
.soc svg {
  width: 18px;
  height: 18px;
  display: block;
}
.soc:hover {
  transform: translateY(-2px);
  filter: brightness(1.08);
}
.soc:focus-visible {
  outline: 2px solid #9089ff;
  outline-offset: 3px;
}
.soc-dc {
  background: #5865f2;
}
.soc-dc svg {
  width: 20px;
  height: 20px;
}
.soc-ig {
  background: radial-gradient(
    circle at 30% 107%,
    #fdf497 0%,
    #fdf497 5%,
    #fd5949 45%,
    #d6249f 60%,
    #285aeb 90%
  );
}
.soc-mail {
  background: #564ce0;
}
.soc-x {
  background: #000;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.22);
}
.soc-x svg {
  width: 15px;
  height: 15px;
}
@media (max-width: 760px) {
  .ending .final-cta {
    margin-top: 64px;
  }
}

/* ============ Waitlist form ============ */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.waitlist-form {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  width: 100%;
  max-width: 460px;
  margin: 34px auto 0;
  padding: 6px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  box-shadow: var(--shadow-sm);
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}
.waitlist-form:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 16%, transparent);
}
.waitlist-form.invalid {
  border-color: var(--accent-2);
}
.wl-field {
  flex: 1;
  min-width: 0;
  display: flex;
}
.wl-field input {
  flex: 1;
  min-width: 0;
  height: 46px;
  padding: 0 8px 0 18px;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font: 500 16px/1 var(--sans);
}
.wl-field input::placeholder {
  color: var(--ink-faint);
}
.waitlist-form .btn {
  height: 46px;
  padding: 0 22px;
}
.waitlist-form {
  position: relative;
}
@media (max-width: 420px) {
  .waitlist-form .btn {
    padding: 0 16px;
    font-size: 14px;
  }
  .wl-field input {
    padding-left: 14px;
  }
}

/* ============ Footer ============ */
footer {
  border-top: 1px solid var(--line);
  padding-block: 40px;
}
