/* The Beta design's typography and quote treatment, layered over the
   existing About page so its playful objects and tilted pills remain. */
.about {
  --about-title-size: clamp(42px, 6.2125vw, 92px);
  /* Keep the reading type fluid across window sizes. */
  --about-body-size: clamp(17px, calc(16px + 0.235vw), 19px);
  --about-quote-size: clamp(16px, calc(15px + 0.235vw), 18px);
  background: #feffee;
  color: #061027;
}

@media (min-width: 1280px) {
  .about {
    --about-body-size: clamp(19px, calc(11px + 0.625vw), 23px);
    --about-quote-size: clamp(18px, calc(10px + 0.625vw), 22px);
  }
}

.about > section,
.about > article {
  padding-top: 60px;
  padding-bottom: 60px;
}

.about > .opener {
  min-height: clamp(460px, 45.3125vw, 680px);
  padding: 0;
  color: white;
  background: linear-gradient(rgba(0, 0, 0, 0.2), rgba(0, 0, 0, 0.2)), url('/img/about/header-sky-hires.jpg') center / cover;
}

.about-top {
  position: relative;
  width: 100%;
  height: 118px;
  padding: 20px 24px;
}

.about-top__home,
.about-top__social {
  position: absolute;
  z-index: 2;
  top: 20px;
  display: flex;
  align-items: center;
  color: white;
}

.about-top__home { left: 24px; right: auto; }
.about-top__social { display: none; left: auto; right: 24px; gap: 14px; min-height: 16px; }
.about-top__social a { display: inline-flex; color: inherit; }
.about-top__social svg { width: 14px; height: 14px; }
.about-top__home {
  font-family: var(--font-sans);
  font-size: 18px;
  line-height: 1.1;
  letter-spacing: -0.04em;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.about-top__home:focus-visible,
.about-top__social a:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 4px;
}

.about-top .wordmark { width: 150px; }

.opener__content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: clamp(330px, 29.6875vw, 450px);
  gap: 36px;
  padding: 12px 24px 30px;
}

.opener__title {
  font-size: var(--about-title-size);
  line-height: 0.9;
  letter-spacing: -0.04em;
}

.opener__byline {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 12px;
  line-height: 1.45;
  letter-spacing: -0.005em;
}

.opener__title .pixel { font-size: 1em; }
.opener .opener__title .pixel span { color: white; }
.opener__title .pixel span:last-child {
  font-family: var(--font-pixel);
  font-size: 1em;
  margin-left: 0;
}

/* The narration, essay, and close share the same Camera Plain rhythm. */
.kv__lede,
.about > .essay,
.close__copy {
  font-family: var(--font-sans);
  font-size: var(--about-body-size);
  font-weight: normal;
  line-height: 1.45;
  letter-spacing: -0.005em;
}

.about > .kv {
  background: #feffee;
  color: #061027;
  padding-top: 60px;
  padding-bottom: 0;
}

.kv__lede {
  max-width: 760px;
  margin: 0 auto 30px;
  font-size: var(--about-body-size);
  line-height: 1.45;
  letter-spacing: -0.005em;
}

.kv__collage { display: contents; }

.kv__scene {
  position: relative;
  container-type: inline-size;
  display: grid;
  grid-template-columns: 38.4615% 53.8455%;
  align-items: start;
  width: min(100%, clamp(780px, 60.94vw, 940px));
  min-height: clamp(543px, 42.42vw, 655px);
  margin: 0 auto;
  padding: 0;
}

.kv__envelope {
  position: absolute;
  left: 6%;
  top: 0;
  width: 60.77%;
  height: 100%;
  overflow: hidden;
}

.kv__envelope img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.kv__quote {
  position: relative;
  grid-column: 2;
  z-index: 1;
  width: 100%;
  /* 420px note, 36px inset and 18px type in Figma's 780px collage. */
  margin-top: 10cqw;
  padding: 4.61538cqw;
  background: #fefa8f;
  box-shadow: 0 1px 2px rgba(6, 16, 39, 0.08);
  transform: rotate(5.52deg);
  font-family: var(--font-serif);
  font-size: 2.30769cqw;
  line-height: 1.22;
  letter-spacing: 0;
}

.kv__quote-mark {
  position: absolute;
  z-index: 2;
  /* Preserve the exported artwork's bounds and 2.47-degree Figma rotation. */
  top: 15.0091cqw;
  left: 35.7696cqw;
  width: 53.8455cqw;
  aspect-ratio: 419.995 / 325.46;
  transform: rotate(2.47deg);
  pointer-events: none;
}

.kv__quote-mark::before {
  content: '';
  position: absolute;
  inset: -6.8% 0 0 -1.69%;
  background: url('/img/about/quote-mark-raised.svg') center / contain no-repeat;
}

.kv__quote p:first-of-type { text-indent: 0; }
.kv__quote-copy { text-box-trim: trim-both; text-box-edge: cap alphabetic; }
.kv__quote p { text-wrap: wrap; }
.kv__quote p + p { margin-top: 2.05128cqw; }
.kv__quote .kv__moral { color: #061027; font-weight: bold; }

.kv__portrait {
  position: absolute;
  z-index: 2;
  left: -3.72%;
  top: 31.68%;
  width: 37.18%;
  height: auto;
}

.kv__credit {
  max-width: 606px;
  margin: 12px auto 0;
  color: rgba(6, 16, 39, 0.4);
  transform: translate(-8px, -8px);
  font-family: var(--font-sans);
  font-size: 10px;
  line-height: 1.2;
  text-transform: uppercase;
  letter-spacing: 0;
}

.about > .essay {
  max-width: calc(760px + 2 * var(--gutter));
  padding-top: 60px;
  padding-bottom: 0;
}

.essay p + p {
  margin-top: 1.45em;
}

.essay__brand {
  margin: 20px auto 58px;
  text-align: center;
}

.brand-orbit {
  --orbit-radius-x: 45cqw;
  --orbit-radius-y: 13.5cqw;
  position: relative;
  left: 50%;
  width: min(1120px, calc(100vw - 32px));
  margin-top: 0;
  scroll-margin-top: 120px;
  transform: translateX(-50%);
  container-type: inline-size;
}

/* All the artwork shares one 3D space so the logo naturally hides the
   far side of the orbit, including through the gaps between letters. */
.brand-orbit__stage {
  position: relative;
  width: 100%;
  aspect-ratio: 2.3;
  perspective: 1400px;
  transform-style: preserve-3d;
}

.brand-orbit__logo,
.brand-orbit__item {
  position: absolute;
  top: 50%;
  left: 50%;
  display: block;
  height: auto;
  user-select: none;
  pointer-events: none;
}

.brand-orbit__logo {
  width: 62%;
  transform: translate(-50%, -50%) rotate(-4.11deg);
}

.brand-orbit__item {
  width: var(--size);
  pointer-events: auto;
  padding: 0;
  border: 0;
  background: none;
  transform-style: preserve-3d;
  will-change: transform;
  transform: translate(-50%, -50%) translate3d(var(--x), var(--y), var(--z)) rotate(var(--tilt));
}

/* Keep geometry in the stylesheet: production blocks inline style attributes. */
.brand-orbit__flower {
  --size: 12%;
  --x: 45.000cqw;
  --y: 0.000cqw;
  --z: 0.000cqw;
  --tilt: 8deg;
}

.brand-orbit__thread {
  --size: 11%;
  --x: 37.856cqw;
  --y: 7.299cqw;
  --z: 6.488cqw;
  --tilt: -8deg;
}

.brand-orbit__gameboy {
  --size: 14%;
  --x: 18.694cqw;
  --y: 12.280cqw;
  --z: 10.916cqw;
  --tilt: 12deg;
}

.brand-orbit__pretzel {
  --size: 13%;
  --x: -6.404cqw;
  --y: 13.363cqw;
  --z: 11.878cqw;
  --tilt: -12deg;
}

.brand-orbit__lemon {
  --size: 12%;
  --x: -29.469cqw;
  --y: 10.203cqw;
  --z: 9.069cqw;
  --tilt: 3deg;
}

.brand-orbit__card {
  --size: 12%;
  --x: -43.177cqw;
  --y: 3.803cqw;
  --z: 3.381cqw;
  --tilt: 14deg;
}

.brand-orbit__bike {
  --size: 18%;
  --x: -43.177cqw;
  --y: -3.803cqw;
  --z: -3.381cqw;
  --tilt: -8deg;
}

.brand-orbit__balloon {
  --size: 13%;
  --x: -29.469cqw;
  --y: -10.203cqw;
  --z: -9.069cqw;
  --tilt: -6deg;
}

.brand-orbit__film {
  --size: 12%;
  --x: -6.404cqw;
  --y: -13.363cqw;
  --z: -11.878cqw;
  --tilt: 4deg;
}

.brand-orbit__scrunchie {
  --size: 12%;
  --x: 18.694cqw;
  --y: -12.280cqw;
  --z: -10.916cqw;
  --tilt: 8deg;
}

.brand-orbit__sim {
  --size: 13%;
  --x: 37.856cqw;
  --y: -7.299cqw;
  --z: -6.488cqw;
  --tilt: -10deg;
}

.brand-orbit__item img {
  display: block;
  width: 100%;
  height: auto;
  transition: transform 180ms ease;
}

.brand-orbit button { cursor: pointer; }
.brand-orbit button:focus-visible { outline: 2px solid #061027; outline-offset: 6px; }
.brand-orbit__card { min-width: 44px; }

.brand-orbit__card-flipper {
  display: block;
  position: relative;
  transform-style: preserve-3d;
  transition: transform 280ms cubic-bezier(0.77, 0, 0.175, 1);
}
.brand-orbit__card[aria-pressed="true"] .brand-orbit__card-flipper { transform: rotateY(180deg); }
.brand-orbit__card img { backface-visibility: hidden; }
.brand-orbit__card .brand-orbit__card-back {
  position: absolute;
  top: 0;
  left: 18%;
  width: 64%;
  height: 100%;
  object-fit: contain;
  transform: rotateY(180deg);
  border-radius: 12%;
}

@media (hover: hover) and (pointer: fine) {
  .brand-orbit__item:not(.brand-orbit__card).is-hovered img {
    transform: translateY(-4px) scale(1.04);
  }

}

@media (prefers-reduced-motion: reduce) {
  .brand-orbit__item img,
  .brand-orbit__card-flipper { transition: none; }
  .brand-orbit__item:not(.brand-orbit__card).is-hovered img { transform: none; }

  .brand-orbit__item { will-change: auto; }
}

.about > .into {
  padding-top: 65px;
  padding-bottom: 100px;
}

.into__head { margin-bottom: 72px; }
.into__title { padding-bottom: 20px; }

.chips li {
  letter-spacing: 0.04em;
}

.about > .close {
  background: #fefa8f;
  color: #061027;
  text-align: center;
  padding-top: 60px;
  padding-bottom: 60px;
}

.close__eyes {
  position: relative;
  width: 180px;
  height: 138px;
  margin: 0 auto 50px;
}

/* Figma's 220px scene, fitted to the existing artwork slot. */
.googly-eyes {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 220px;
  height: 100.824px;
  transform: scale(0.818182);
  transform-origin: bottom left;
}
.googly-eye {
  position: absolute;
  top: 0;
  width: 100.824px;
  height: 100.824px;
  isolation: isolate;
}
.googly-eye--left { left: 0; }
.googly-eye--right { left: 119.18px; }
.googly-eye img { position: absolute; display: block; max-width: none; }
.googly-eye__edge { inset: 0; width: 100%; height: 100%; }
.googly-eye__shadow {
  left: 5.67px; top: 5.68px; width: 89.48px; height: 89.48px;
  transform: rotate(90deg);
}
.googly-eye__pupil {
  position: absolute; left: 23.51px; top: 41.64px;
  width: 53.8px; height: 53.8px;
}
.googly-eye__pupil img {
  left: -3.47%; top: -10.4%; width: 127.74%; height: 127.73%;
}
.googly-eye__highlight {
  left: -5.594px; top: -5.019px; width: 53.952px; height: 92.821px;
  mix-blend-mode: soft-light;
}

/* Exact two-second Figma tracks: 2364:16347, 16354, 16364, 16372. */
@keyframes googly-right-hop {
  0% { translate: 0 0; }
  4.377% { animation-timing-function: ease-in; translate: 0 0; }
  12.247% { animation-timing-function: ease-out; translate: 0 18.651px; }
  24.445% { translate: 0 -67.143px; }
  29.1% { animation-timing-function: cubic-bezier(.68,.351,.431,.797); translate: 0 -67.143px; }
  39.122%, 100% { translate: 0 0; }
}
@keyframes googly-right-pupil {
  0%, 10.512% { translate: 0 0; }
  24.445% { translate: 0 -35.189px; }
  39.122%, 100% { translate: 0 0; }
}
@keyframes googly-left-hop {
  0% { translate: 0 0; }
  13.056% { animation-timing-function: ease-in; translate: 0 0; }
  20.926% { animation-timing-function: ease-out; translate: 0 18.651px; }
  33.124% { translate: 0 -67.143px; }
  37.79% { animation-timing-function: cubic-bezier(.68,.351,.431,.797); translate: 0 -67.143px; }
  47.812%, 100% { translate: 0 0; }
}
@keyframes googly-left-pupil {
  0%, 19.324% { translate: 0 0; }
  33.257% { translate: 0 -35.189px; }
  47.933%, 100% { translate: 0 0; }
}
@media (prefers-reduced-motion: no-preference) {
  .googly-eye--right { animation: googly-right-hop 2s linear infinite; }
  .googly-eye--left { animation: googly-left-hop 2s linear infinite; }
  .googly-eye--right .googly-eye__pupil { animation: googly-right-pupil 2s linear infinite; }
  .googly-eye--left .googly-eye__pupil { animation: googly-left-pupil 2s linear infinite; }
}

@keyframes about-photo-enter {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes about-heading-enter {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: no-preference) {
  .about > .opener { animation: about-photo-enter 500ms ease both; }
  .opener__content {
    animation: about-heading-enter 500ms cubic-bezier(0.23, 1, 0.32, 1) 80ms both;
  }
}

.into__title,
.close__headline {
  max-width: 900px;
  margin: 0 auto;
  color: #061027;
  font-family: var(--font-serif);
  font-size: clamp(1.875rem, 4.65vw, 3.75rem);
  font-weight: normal;
  line-height: 0.9;
  letter-spacing: -0.04em;
}

.close__headline .pixel {
  display: inline-block;
  font-family: var(--font-pixel);
  white-space: nowrap;
}

.close__headline { font-size: var(--about-title-size); }

.close__headline .pixel span:nth-child(1) { color: #4c5bfe; }
.close__headline .pixel span:nth-child(2) { color: #006861; }
.close__headline .pixel span:nth-child(3) { color: #93d413; }
.close__headline .pixel span:nth-child(4) { color: #ffb2ed; }
.close__headline .pixel span:nth-child(5) { color: #ff5106; }
.close__headline .pixel span:nth-child(6) { color: #4c5bfe; }

.close__copy {
  max-width: 760px;
  margin: 50px auto 0;
}

.close__copy p + p {
  margin-top: 0;
}

.close .waitlist--come {
  margin: 48px auto 16px;
}

.come__copy {
  max-width: 760px;
  margin: 0 auto;
  color: #061027;
  font-size: 12px;
  text-align: center;
}

@media (max-width: 1180px) {
  .about > .into {
    padding-top: 50px;
  }
}

@media (max-width: 700px) {
  .about { --about-title-size: clamp(30px, 10vw, 60px); }
  .about > section,
  .about > article {
    padding-top: 48px;
    padding-bottom: 48px;
  }

  .about > .opener {
    min-height: 400px;
    padding: 0;
  }

  .about-top { height: 110px; padding: 24px; }
  .about-top .wordmark { width: 128px; }
  .about-top__home { top: 20px; }
  .about-top__social { display: none; }
  .brand-orbit { width: 100vw; --orbit-radius-x: 45cqw; }
  .into__head { margin-bottom: 56px; }
  .opener__content { min-height: 250px; padding: 12px 24px 36px; gap: 28px; }
  .opener__title { max-width: 100%; white-space: normal; }
  .opener__byline { font-size: 14px; }

  .about > .kv { padding-top: 40px; padding-bottom: 0; }
  .kv__lede, .about > .essay, .close__copy { line-height: 1.48; }
  .kv__lede { margin-bottom: 28px; }

  .kv__collage {
    /* The collage extends beyond the reading column, as in the 382px frame. */
    position: relative;
    display: block;
    width: min(100vw, 480px);
    margin-inline: calc((100% - min(100vw, 480px)) / 2);
    container-type: inline-size;
  }

  .kv__scene {
    width: 100%;
    min-height: 0;
    grid-template-columns: 22.258% 79%;
    padding: 20.57cqw 0 28.41cqw;
  }

  .kv__envelope {
    left: -16.325cqw;
    top: -4.029cqw;
    width: 106.806cqw;
    height: 122.513cqw;
    overflow: visible;
    transform: rotate(-6.08deg);
  }
  .kv__envelope img {
    top: 4.37%;
    left: 4.41%;
    width: 91.18%;
    height: 91.03%;
    object-fit: cover;
  }
  .kv__quote {
    margin-top: 0;
    padding: 24px;
    font-size: clamp(14px, 4.1885cqw, 20px);
    transform: rotate(5.52deg);
  }
  .kv__quote-mark {
    top: calc(27.57cqw + 16px);
    left: 9.42cqw;
    width: 31.7822cqw;
    aspect-ratio: 121.408 / 74.239;
  }
  .kv__quote-mark::before {
    inset: 0;
    background-image: url('/img/about/quote-mark-mobile.svg');
  }
  .kv__quote p + p { margin-top: 4.1885cqw; }
  .kv__portrait {
    left: -14.408cqw;
    top: auto;
    bottom: 1.707cqw;
    width: 48.694cqw;
    margin: 0;
  }
  .kv__credit {
    position: absolute;
    left: 27.487cqw;
    bottom: 8.513cqw;
    width: 58.377cqw;
    max-width: none;
    margin: 0;
    font-size: clamp(9px, 2.6178cqw, 12px);
    line-height: 1.2;
    color: rgba(6, 16, 39, 0.7);
    transform: none;
    text-align: left;
    text-wrap: wrap;
  }

  .about > .essay {
    padding-top: 28px;
  }

  .essay p + p {
    margin-top: 1.2em;
  }

  .essay__brand {
    margin: 12px auto 32px;
  }

  .essay__brand-intro { padding-bottom: 12px; }

  .about > .into {
    padding-top: 40px;
    padding-bottom: 70px;
  }

  .chips li {
    letter-spacing: 0.06em;
    max-width: 100%;
    text-align: center;
    text-wrap: balance;
  }

  .into__title { padding-bottom: 0; font-size: clamp(30px, 8vw, 48px); line-height: 1; text-wrap: balance; }
  .into__title br { display: none; }
  .close__headline { line-height: 1; text-wrap: balance; }

  .about > .close {
    padding-top: 60px;
    padding-bottom: 60px;
  }

  .close__copy {
    margin-top: 32px;
  }

  .close__copy p { display: inline; }
  .close__copy p + p { margin: 0; }

}
