/* Site styles: tokens, base, type, shared pieces, then each page in order.
   Breakpoints: md 768px, lg 1024px. */

@view-transition {
  navigation: auto;
}

:root {
  --bg: #ededed;
  --ink: #000;
  --paragraph: rgba(0, 0, 0, 0.7);
  --black-80: rgba(0, 0, 0, 0.8);
  --black-40: rgba(0, 0, 0, 0.4);
  --black-30: rgba(0, 0, 0, 0.3);
  --black-25: rgba(0, 0, 0, 0.25);
  --black-12: rgba(0, 0, 0, 0.12);
  --line: rgba(0, 0, 0, 0.2);
  --light-fill: rgba(0, 0, 0, 0.04);
  --surface: #d9d9d9;

  --font-sans: "Geist", system-ui, sans-serif;
  --font-mono: var(--font-sans);

  --announce-h: 46px;
  --nav-h: 64px;
  --gutter: 20px;
  --rail: 89px;
  --hair: 0.5px;
  --ease: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-out-cubic: cubic-bezier(0.33, 1, 0.68, 1);

  /* set from js/main.js as the page scrolls */
  --melt: 1;
  --announce-offset: 0px;
}

@media (min-width: 768px) {
  :root {
    --nav-h: 56px;
    --gutter: 24px;
  }
}

@media (min-width: 1024px) {
  :root {
    --announce-h: 56px;
  }
}

/* Base ------------------------------------------------------------------ */

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

html:has(dialog[open]),
html:has(body.menu-open) {
  overflow: hidden;
}

body {
  margin: 0;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--ink);
  font: 400 16px/1.5 var(--font-sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

main {
  flex: 1;
  min-height: 100dvh;
}

a {
  color: inherit;
  text-decoration: none;
}

img,
svg {
  display: block;
}

button,
input {
  font: inherit;
  color: inherit;
  border-radius: 0;
}

button {
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
}

h1,
h2,
h3,
p,
figure,
ul {
  margin: 0;
}

h1,
h2,
h3 {
  font-weight: 400;
}

ul {
  padding: 0;
  list-style: none;
}

[hidden] {
  display: none !important;
}

::selection {
  background: #000;
  color: #fff;
}

:focus-visible {
  outline: 1px solid currentColor;
  outline-offset: 3px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.skip {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 200;
  padding: 8px 12px;
  background: #fff;
  font-size: 14px;
  transform: translateY(-300%);
}

.skip:focus {
  transform: none;
}

/* Type ------------------------------------------------------------------ */

.t-display,
.t-h1,
.t-h2,
.t-h3,
.t-h4,
.t-h5,
.t-h6 {
  font-family: var(--font-sans);
  font-weight: 400;
  line-height: 1.32;
  letter-spacing: -0.02em;
}

.t-display { font-size: 81px; letter-spacing: -0.04em; }
.t-h1 { font-size: 65px; letter-spacing: -0.03em; }
.t-h2 { font-size: 52px; }
.t-h3 { font-size: 41px; }
.t-h4 { font-size: 33px; }
.t-h5 { font-size: 27px; }
.t-h6 { font-size: 21px; }

.t-p,
.t-p-bold {
  font-size: 17px;
  line-height: 1.6;
}

.t-p-bold {
  font-weight: 500;
}

.t-small {
  font-size: 14px;
  line-height: 1.4;
}

.t-sub,
.t-tiny,
.t-mono-12 {
  font-family: var(--font-mono);
  letter-spacing: -0.02em;
}

.t-sub { font-size: 14px; line-height: 1.4; }
.t-mono-12 { font-size: 12px; line-height: 1.4; }
.t-tiny { font-size: 12px; line-height: 0.85; }

.t-nav {
  font-size: 16px;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.muted {
  color: var(--paragraph);
}

/* Desktop swaps: an element takes one size on phones and another from lg up. */
@media (min-width: 1024px) {
  .lg-display { font-size: 81px; letter-spacing: -0.04em; }
  .lg-h1 { font-size: 65px; letter-spacing: -0.03em; }
  .lg-h2 { font-size: 52px; letter-spacing: -0.02em; }
  .lg-h3 { font-size: 41px; letter-spacing: -0.02em; }
  .lg-sub { font-size: 14px; }
}

/* Placeholders -----------------------------------------------------------
   A grey block with a cross marks every image slot. Put an <img> inside the
   block and it fills the slot and hides the cross and label. */

.ph {
  position: relative;
  overflow: hidden;
  background-color: var(--surface);
  background-image:
    linear-gradient(to top right, transparent calc(50% - 0.5px), var(--black-12) calc(50% - 0.5px), var(--black-12) calc(50% + 0.5px), transparent calc(50% + 0.5px)),
    linear-gradient(to bottom right, transparent calc(50% - 0.5px), var(--black-12) calc(50% - 0.5px), var(--black-12) calc(50% + 0.5px), transparent calc(50% + 0.5px));
}

.ph[data-label]::after {
  content: attr(data-label);
  position: absolute;
  top: 50%;
  left: 50%;
  padding: 4px 8px;
  background: var(--surface);
  color: rgba(0, 0, 0, 0.5);
  font: 11px/1.2 var(--font-mono);
  white-space: nowrap;
  transform: translate(-50%, -50%);
}

.ph > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.ph--contain > img {
  object-fit: contain;
}

.ph:has(> img) {
  background: none;
}

.ph[data-label]:has(> img)::after {
  content: none;
}

/* Button ---------------------------------------------------------------- */

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px 32px;
  overflow: hidden;
  background: #000;
  color: #fff;
  font-family: var(--font-mono);
  font-size: 14px;
  line-height: 0.85;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  white-space: nowrap;
  transition: transform 0.15s;
}

.btn:active {
  transform: scale(0.98);
}

.btn svg {
  flex: none;
  width: 7px;
  height: 7px;
  transition: transform 0.15s;
}

.btn:hover svg {
  transform: translateX(4px);
}

.btn--cta {
  width: 100%;
  padding: 16px 90px;
}

.btn--block {
  width: 100%;
  padding-block: 20px;
}

@media (min-width: 1024px) {
  .btn--cta {
    width: fit-content;
  }
}

/* Announcement bar ------------------------------------------------------ */

.announce {
  position: absolute;
  inset: 0 0 auto 0;
  z-index: 41;
  background: #000;
  color: #fff;
}

.announce-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  height: var(--announce-h);
}

.announce-link {
  position: relative;
  z-index: 41;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  align-content: center;
  justify-content: center;
  gap: 2px 8px;
  width: 100%;
  height: 100%;
  padding: 0 11px;
  text-align: center;
  text-wrap: pretty;
}

.announce-more {
  display: none;
  align-items: center;
  gap: 8px;
  opacity: 0.5;
  transition: opacity 0.15s;
}

.announce-more::before {
  content: "";
  flex: none;
  width: 2.88px;
  height: 2.88px;
  background: currentColor;
}

.announce-more span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.announce-more svg {
  width: 14px;
  height: 14px;
  transition: transform 0.2s ease-out;
}

.announce-link:hover .announce-more {
  opacity: 1;
}

.announce-link:hover .announce-more svg {
  transform: translateX(4px);
}

@media (min-width: 1024px) {
  /* no stacking context here, so the link can sit above the fixed nav */
  .announce {
    z-index: auto;
    background: transparent;
  }

  .announce-inner {
    padding: 0 var(--gutter);
  }

  .announce-link {
    max-width: calc(100% - 352px);
    margin: 0 auto;
    padding: 0;
  }

  .announce-more {
    display: inline-flex;
  }
}

/* Nav -------------------------------------------------------------------
   White over a dark hero, black everywhere else. It slides away on the way
   down the page and comes back on the way up. */

.nav {
  position: fixed;
  top: var(--announce-offset);
  left: 0;
  right: 0;
  z-index: 40;
  color: #000;
  transition: transform 0.35s var(--ease), color 0.3s var(--ease);
}

.nav.is-light {
  color: #fff;
}

.nav.is-away {
  transform: translateY(calc(-100% - var(--announce-offset)));
}

.nav::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: rgba(237, 237, 237, 0.72);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  opacity: 0;
  transition: opacity 0.3s var(--ease);
}

.nav.is-frosted::before {
  opacity: 1;
}

.nav-inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 20px;
}

.nav-mark {
  display: flex;
  flex: none;
  align-items: center;
}

.nav-mark svg {
  width: auto;
  height: 23px;
}

.nav-links {
  display: none;
  align-items: center;
  gap: 24px;
}

.nav-links a,
.nav-links button {
  transition: opacity 0.15s;
}

.nav-links a:hover,
.nav-links button:hover,
.nav-toggle:hover {
  opacity: 0.64;
}

.nav-links a[aria-current="page"] {
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}

.nav-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 48px;
  transition: opacity 0.15s;
}

.nav-toggle span {
  position: relative;
  display: block;
  width: 36px;
  height: 13px;
}

.nav-toggle span::before,
.nav-toggle span::after {
  content: "";
  position: absolute;
  left: 0;
  width: 36px;
  height: 1px;
  background: currentColor;
  transition: transform 0.3s var(--ease);
}

.nav-toggle span::before { top: 0; }
.nav-toggle span::after { bottom: 0; }

.menu-open .nav-toggle span::before { transform: translateY(6px) rotate(20deg); }
.menu-open .nav-toggle span::after { transform: translateY(-6px) rotate(-20deg); }

.menu-open .nav {
  color: #000;
  transform: none;
}

.menu {
  position: fixed;
  inset: 0;
  z-index: 39;
  display: flex;
  flex-direction: column;
  padding: 120px 20px 32px;
  background: var(--bg);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s var(--ease), visibility 0.3s;
}

.menu-open .menu {
  opacity: 1;
  visibility: visible;
}

.menu > * {
  padding: 12px 0;
  text-align: left;
  border-top: var(--hair) solid var(--line);
}

.menu > :last-child {
  border-bottom: var(--hair) solid var(--line);
}

/* Soft dark fade behind the nav while it sits over the hero image. */
.melt-shade,
.melt-blur {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 39;
  height: calc(var(--announce-h) + var(--nav-h) + 32px);
  opacity: var(--melt);
  pointer-events: none;
}

.melt-shade {
  background-image: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.56) 0,
    rgba(0, 0, 0, 0.46) var(--announce-h),
    rgba(0, 0, 0, 0.3) calc(var(--announce-h) + var(--nav-h)),
    rgba(0, 0, 0, 0.13) calc(var(--announce-h) + var(--nav-h) + 16px),
    rgba(0, 0, 0, 0.04) calc(var(--announce-h) + var(--nav-h) + 26px),
    transparent calc(var(--announce-h) + var(--nav-h) + 32px)
  );
}

.melt-blur {
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  -webkit-mask-image: linear-gradient(to bottom, #000 0, rgba(0, 0, 0, 0.6) calc(var(--announce-h) + var(--nav-h)), transparent calc(var(--announce-h) + var(--nav-h) + 32px));
  mask-image: linear-gradient(to bottom, #000 0, rgba(0, 0, 0, 0.6) calc(var(--announce-h) + var(--nav-h)), transparent calc(var(--announce-h) + var(--nav-h) + 32px));
}

.menu-open .melt-shade,
.menu-open .melt-blur {
  opacity: 0;
  transition: opacity 0.3s var(--ease);
}

@media (min-width: 768px) {
  .nav-inner {
    padding: 16px var(--gutter);
  }

  .nav-mark svg {
    height: 24px;
  }

  .nav-links {
    display: flex;
  }

  .nav-toggle,
  .menu {
    display: none;
  }
}

@media (min-width: 1024px) {
  .melt-shade,
  .melt-blur {
    height: calc(var(--nav-h) + 160px);
  }

  .melt-shade {
    background-image: linear-gradient(
      to bottom,
      rgba(0, 0, 0, 0.76) 0,
      rgba(0, 0, 0, 0.66) var(--nav-h),
      rgba(0, 0, 0, 0.5) calc(var(--nav-h) + 28px),
      rgba(0, 0, 0, 0.32) calc(var(--nav-h) + 64px),
      rgba(0, 0, 0, 0.18) calc(var(--nav-h) + 100px),
      rgba(0, 0, 0, 0.08) calc(var(--nav-h) + 132px),
      transparent calc(var(--nav-h) + 160px)
    );
  }

  .melt-blur {
    -webkit-backdrop-filter: blur(14px);
    backdrop-filter: blur(14px);
    -webkit-mask-image: linear-gradient(to bottom, #000 0, #000 var(--nav-h), rgba(0, 0, 0, 0.55) calc(var(--nav-h) + 48px), rgba(0, 0, 0, 0.22) calc(var(--nav-h) + 100px), transparent calc(var(--nav-h) + 160px));
    mask-image: linear-gradient(to bottom, #000 0, #000 var(--nav-h), rgba(0, 0, 0, 0.55) calc(var(--nav-h) + 48px), rgba(0, 0, 0, 0.22) calc(var(--nav-h) + 100px), transparent calc(var(--nav-h) + 160px));
  }
}

/* Frame: the two side rails ---------------------------------------------- */

.top {
  width: 100%;
}

.top-rails {
  display: none;
}

.shell {
  width: 100%;
}

.shell-main {
  min-width: 0;
}

.rail {
  display: none;
  flex: none;
  width: var(--rail);
  border-inline: var(--hair) solid var(--line);
}

@media (min-width: 1024px) {
  .top {
    position: relative;
  }

  .top > :first-child {
    position: relative;
    z-index: 10;
  }

  .top-rails {
    display: block;
    position: absolute;
    top: 56px;
    bottom: 0;
    left: 0;
    right: 0;
    max-width: 1440px;
    margin: 0 auto;
    pointer-events: none;
  }

  .top-rails .rail {
    display: block;
    position: absolute;
    top: 0;
    bottom: 0;
  }

  .top-rails .rail:first-child { left: 20px; }
  .top-rails .rail:last-child { right: 20px; }

  .shell {
    display: flex;
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 20px;
  }

  .shell-main {
    flex: 1;
  }

  .shell > .rail {
    display: block;
  }
}

/* Home: hero ------------------------------------------------------------ */

.hero {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.hero-media {
  position: relative;
  width: 100%;
  height: 84.25vw;
  overflow: hidden;
}

.hero-image {
  position: absolute;
  inset: 0;
}

/* Matches the photo's own backdrop, so the smaller image blends into the header. */
.hero-image:has(> img) {
  background: linear-gradient(to right, #e7e6e4, #d5d3d1);
}

.hero-image > img {
  top: 12%;
  left: 50%;
  width: auto;
  max-width: 100%;
  height: 76%;
  object-fit: contain;
  transform: translateX(-50%);
  -webkit-mask-image: linear-gradient(to right, transparent, #000 10%, #000 83%, transparent), linear-gradient(to bottom, transparent, #000 10%, #000 90%, transparent);
  mask-image: linear-gradient(to right, transparent, #000 10%, #000 83%, transparent), linear-gradient(to bottom, transparent, #000 10%, #000 90%, transparent);
  -webkit-mask-composite: source-in;
  mask-composite: intersect;
}

.hero-title {
  flex: none;
  padding: 8.1vw 20px;
  text-align: center;
}

@media (prefers-reduced-motion: no-preference) {
  .hero-image {
    animation: hero-enter 0.6s var(--ease) backwards;
    --hero-opacity: 0.01;
  }

  .hero-title {
    animation: hero-enter 0.5s var(--ease) 0.25s backwards;
    --hero-y: 8px;
  }
}

@keyframes hero-enter {
  from {
    opacity: var(--hero-opacity, 0);
    transform: translateY(var(--hero-y, 0px));
  }
}

@media (min-width: 1024px) {
  .hero {
    height: 100svh;
  }

  .hero-media {
    flex: 1;
    height: auto;
    min-height: 0;
  }

  .hero-title {
    padding: 12px 20px 24px;
  }
}

@media (min-width: 1024px) and (max-height: 820px) {
  .hero-title {
    padding-block: 10px;
  }
}

/* Home: story ----------------------------------------------------------- */

.carousel-track {
  position: relative;
  height: 410px;
  overflow: hidden;
  touch-action: pan-y;
  user-select: none;
}

.carousel-track figure {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 20px;
  opacity: 0;
  transform: translateX(24px);
  transition: opacity 0.5s var(--ease-out-cubic), transform 0.5s var(--ease-out-cubic);
}

.carousel-track figure.is-before {
  transform: translateX(-24px);
}

.carousel-track figure.is-active {
  opacity: 1;
  transform: none;
}

.carousel-track .ph {
  width: 96%;
  max-width: 100%;
  height: var(--h);
}

/* Product photos are 4:3 and share the page's light grey backdrop. */
.story-image {
  aspect-ratio: 4 / 3;
}

.carousel-track .story-image {
  height: auto;
}

.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 8px;
}

.carousel-dots span {
  width: 24px;
  height: 1px;
  background: #000;
  opacity: 0.2;
  transition: opacity 0.3s;
}

.carousel-dots .is-active {
  opacity: 1;
}

.story {
  position: relative;
  margin-top: -20px;
}

.story-visual {
  display: none;
}

.story-text {
  max-width: 768px;
  padding: 40px 20px 60px;
}

.story-text-inner {
  display: flex;
  flex-direction: column;
  gap: 40px;
}

.story-text .btn {
  align-self: flex-start;
}

.prose p {
  margin-bottom: 1.6em;
  font-size: 17px;
  line-height: 1.6;
  color: var(--paragraph);
}

.prose p:last-child {
  margin-bottom: 0;
}

.prose ul {
  margin-bottom: 1.6em;
  padding-left: 1.1em;
  list-style: square;
}

.prose ul:last-child {
  margin-bottom: 0;
}

.prose li {
  margin-bottom: 0.8em;
  font-size: 17px;
  line-height: 1.6;
  color: var(--paragraph);
}

.prose li::marker {
  color: var(--black-30);
}

.prose strong {
  font-weight: 500;
  color: var(--ink);
}

.prose h3 {
  margin-bottom: 27.2px;
  font-size: 21px;
  line-height: 1.32;
  letter-spacing: -0.02em;
}

@media (min-width: 1024px) {
  .carousel {
    display: none;
  }

  .story {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-top: 0;
  }

  .story::before {
    content: "";
    position: absolute;
    inset-block: 0;
    left: 50%;
    width: 1px;
    background: var(--black-12);
    pointer-events: none;
  }

  .story-visual {
    display: block;
  }

  .story-sticky {
    position: sticky;
    top: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100vh;
  }

  .story-frames {
    position: relative;
    width: 100%;
    height: 70vh;
  }

  .story-frames figure {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.4s var(--ease-out-cubic);
  }

  .story-frames .ph {
    width: var(--w);
    aspect-ratio: var(--ar);
    transform: scale(1.015);
    transition: transform 0.4s var(--ease-out-cubic);
  }

  .story-frames .story-image {
    width: 92%;
    aspect-ratio: 4 / 3;
  }

  .story-frames .is-active {
    opacity: 1;
  }

  .story-frames .is-active .ph {
    transform: none;
  }

  .story-text {
    padding: 80px 70px;
  }
}

/* Team grid (join) and feature grid (home): one layout -------------------- */

.team,
.features {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
  padding: 60px 20px;
  border: var(--hair) solid var(--line);
}

.team--join {
  border-bottom: 0;
}

.team-grid,
.features-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 48px 16px;
  width: 100%;
}

.person {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}

.portrait {
  width: 100%;
  aspect-ratio: 31 / 30;
}

.person-body {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
}

.person-meta {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  overflow-wrap: break-word;
}

@media (min-width: 1024px) {
  .team,
  .features {
    gap: 40px;
    padding: 80px var(--rail);
    border-inline: 0;
  }

  .team-grid,
  .features-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    max-width: 1044px;
  }

  .portrait {
    aspect-ratio: 249 / 203;
  }
}

/* Home: a feature card is one button, picture over title, that opens the
   feature view. */

.feature {
  min-width: 0;
}

.feature-open {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 100%;
  text-align: left;
}

.feature-shot {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
}

.feature-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

@media (prefers-reduced-motion: no-preference) {
  .feature-shot > img {
    transition: transform 0.5s var(--ease);
  }

  .feature-open:hover .feature-shot > img {
    transform: scale(1.03);
  }
}

/* Home: hiring band -------------------------------------------------------- */

.band {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 110px 0;
  border: var(--hair) solid var(--line);
  border-top: 0;
  text-align: center;
}

/* Last on the page, the footer's top line closes it. */
.band:last-child {
  border-bottom: 0;
}

.band > span {
  width: 276px;
  transition: color 0.15s;
}

.band:hover > span {
  color: var(--black-80);
}

.band .arrow {
  display: inline-block;
  transition: transform 0.3s;
}

.band:hover .arrow {
  transform: translateX(5px);
}

@media (min-width: 1024px) {
  .band {
    border-inline: 0;
  }

  .band > span {
    width: auto;
  }
}

/* Text pages: privacy notice, page not found ---------------------------- */

.doc {
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
  padding: 120px 20px 110px;
}

.doc-head {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 56px;
}

.doc--short .doc-head {
  margin-bottom: 40px;
}

.doc .prose h3 {
  margin-top: 48px;
  margin-bottom: 16px;
}

.prose a {
  text-decoration: underline;
  text-decoration-color: var(--black-30);
  text-underline-offset: 3px;
  transition: text-decoration-color 0.15s;
}

.prose a:hover {
  text-decoration-color: currentColor;
}

@media (min-width: 1024px) {
  .doc {
    padding: 180px 40px 160px;
  }

  .doc--short {
    min-height: 70vh;
  }
}

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

.footer {
  position: relative;
  z-index: 37;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  border-top: var(--hair) solid var(--line);
}

.footer-art {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  overflow: hidden;
}

/* The mark runs the full width, larger than the space it sits in: the
   frame stops partway down and its curve sweeps out through the bottom. */
.footer-art .ph {
  width: 100%;
  aspect-ratio: 390 / 170;
}

.footer-art .ph > img {
  opacity: 0.56;
}

.footer-base {
  width: 100%;
  padding: 50px 20px 20px;
  border-top: var(--hair) solid var(--line);
}

.footer-stack {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 32px;
  width: 100%;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
}

.footer-links a {
  white-space: nowrap;
  transition: opacity 0.15s;
}

.footer-links a:hover {
  opacity: 0.64;
}

.footer-mobile {
  display: flex;
  flex-direction: column;
  gap: 40px;
  width: 100%;
}

.footer-display {
  font-size: clamp(36px, -6.08px + 15.2vw, 60px);
  line-height: 1.32;
  letter-spacing: -0.02em;
  white-space: nowrap;
  /* keep the tagline short: it is sized to fill one line on a phone */
  max-width: 100%;
  overflow: hidden;
}

.footer-row {
  display: none;
}

.footer-address {
  flex: none;
  font-style: normal;
}

.footer-address a {
  transition: opacity 0.15s;
}

.footer-address a:hover {
  opacity: 0.64;
}

@media (min-width: 768px) {
  .footer-base {
    padding-inline: var(--gutter);
    padding-bottom: var(--gutter);
  }

  .footer-links {
    column-gap: 24px;
  }
}

@media (min-width: 1024px) {
  .footer-base {
    padding-top: 60px;
  }

  .footer-stack {
    align-items: stretch;
    gap: 20px;
  }

  .footer-mobile {
    display: none;
  }

  .footer-row {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    width: 100%;
  }

  .footer-row .t-h1 {
    white-space: nowrap;
    transform: translateX(-5px);
  }

  .footer-row .t-h1,
  .footer-address {
    text-box: trim-both cap alphabetic;
  }

  .footer-row .btn {
    flex: none;
    width: auto;
  }
}

/* Access dialog --------------------------------------------------------- */

.access {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: var(--line);
  color: var(--ink);
  opacity: 0;
  transition: opacity 0.3s var(--ease), overlay 0.3s allow-discrete, display 0.3s allow-discrete;
}

.access[open] {
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
}

@starting-style {
  .access[open] {
    opacity: 0;
  }
}

.access::backdrop {
  background: transparent;
}

.access-panel {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: 100%;
  height: 100dvh;
  max-height: 100dvh;
  overflow: hidden;
  background: var(--bg);
  border: var(--hair) solid var(--line);
}

.access-close {
  position: absolute;
  top: 20px;
  right: 20px;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: #000;
  color: #fff;
}

.access-close svg {
  width: 18px;
  height: 18px;
}

.access-media {
  position: relative;
  flex: none;
  height: 283px;
  overflow: hidden;
}

.access-media .ph {
  position: absolute;
  inset: 10px 20px;
}

/* The sidebar shot fills the column, cropped to keep the menu in view. */
#access .access-media .ph:has(> img) {
  inset: 0;
}

#access .access-media .ph > img {
  object-position: 40% 0;
}

.access-body {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 24px;
  padding: 20px 20px 50px;
}

.access-title {
  font-size: 41px;
  line-height: 1.18;
  letter-spacing: -0.02em;
  white-space: pre-line;
}

.access-note {
  max-width: 323px;
  color: var(--black-80);
}

.access-form {
  display: flex;
  flex-direction: column;
  gap: 32px;
  width: 100%;
}

.access-form input {
  width: 100%;
  padding: 12px 10px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.5);
  color: var(--ink);
  font-size: 17px;
  line-height: 1.6;
}

.access-form input::placeholder {
  color: var(--black-25);
}

.access-form input:focus {
  outline: 1px solid var(--black-30);
  outline-offset: -1px;
}

.access-status {
  display: none;
  width: 100%;
  min-height: 17px;
  color: var(--black-40);
}

.access-status:not(:empty) {
  display: block;
}

@media (min-width: 768px) {
  .access {
    background: var(--black-25);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
  }

  .access-panel {
    flex-direction: row;
    justify-content: flex-start;
    width: 1000px;
    max-width: calc(100vw - 40px);
    height: 674px;
    max-height: calc(100dvh - 80px);
    margin: 40px 0;
  }

  .access-media {
    width: 50%;
    height: auto;
    border-right: var(--hair) solid var(--line);
  }

  .access-media .ph {
    inset: 50px;
  }

  .access-body {
    width: 50%;
    gap: 48px;
    padding: 60px;
  }

  .access-title {
    font-size: 65px;
    line-height: 0.99;
    letter-spacing: -0.03em;
  }

  .access-status {
    display: block;
  }
}

/* Feature view: the access dialog's shell, holding one feature's picture
   and text. Stacked on phones and tablets, side by side from lg up. */

.access--feature .access-panel {
  justify-content: flex-start;
  overflow-y: auto;
}

.access--feature .access-media {
  height: auto;
  aspect-ratio: 4 / 3;
}

.access--feature .access-media .ph {
  inset: 0;
}

.access--feature .access-body {
  justify-content: flex-start;
  gap: 16px;
  padding: 28px 20px 50px;
}

.feature-text {
  display: flex;
  flex-direction: column;
  gap: 12px;
  color: var(--paragraph);
}

@media (min-width: 768px) {
  .access--feature .access-panel {
    flex-direction: column;
    width: 560px;
    height: auto;
  }

  .access--feature .access-media {
    width: 100%;
    border-right: 0;
    border-bottom: var(--hair) solid var(--line);
  }

  .access--feature .access-body {
    width: 100%;
    padding: 36px 40px 44px;
  }
}

@media (min-width: 1024px) {
  /* The picture is 62% of the panel and 4:3, so the panel's height is 0.465
     of its width; the second limit keeps that inside the window. */
  .access--feature .access-panel {
    flex-direction: row;
    width: min(1120px, (100dvh - 80px) * 2.15);
  }

  .access--feature .access-media {
    width: 62%;
    border-right: var(--hair) solid var(--line);
    border-bottom: 0;
  }

  .access--feature .access-body {
    justify-content: center;
    width: 38%;
    padding: 48px;
  }
}

/* Role view: the access dialog's shell with text only. */

.access--role .access-panel {
  justify-content: flex-start;
  overflow-y: auto;
}

.access--role .access-body {
  justify-content: flex-start;
  gap: 20px;
  padding: 88px 20px 50px;
}

.access--role .btn {
  margin-top: 12px;
}

@media (min-width: 768px) {
  .access--role .access-panel {
    width: 600px;
    height: auto;
  }

  .access--role .access-body {
    width: 100%;
    padding: 56px 48px 48px;
  }
}

/* Join ------------------------------------------------------------------ */

.join-hero {
  display: flex;
  flex-direction: column;
  padding: 104px 20px 0;
  overflow: hidden;
}

.join-hero-head {
  display: flex;
  flex-direction: column;
  gap: 50px;
  width: 100%;
  max-width: 1042px;
  margin: 0 auto;
}

.join-hero-title {
  text-align: center;
  text-wrap: balance;
}

.join-features {
  display: none;
}

.join-feature {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  text-align: center;
}

.join-feature .t-p {
  max-width: 400px;
  text-wrap: balance;
}

.join-media {
  position: relative;
  flex: none;
  width: 100%;
  height: 400px;
  margin: 32px auto 0;
  overflow: hidden;
}

.join-media::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  z-index: 2;
  height: 136px;
  background: linear-gradient(transparent 0%, transparent 30%, rgba(237, 237, 237, 0.12) 55%, rgba(237, 237, 237, 0.45) 75%, var(--bg) 100%);
  pointer-events: none;
}

.join-media .ph {
  position: absolute;
  inset: 0;
}

.join-media .ph > img {
  object-position: top;
}

@media (prefers-reduced-motion: no-preference) {
  .join-hero-title {
    animation: hero-enter 0.4s var(--ease) 0.125s backwards;
  }

  .join-features {
    animation: hero-enter 0.3s cubic-bezier(0.25, 0.1, 0.35, 1) backwards;
  }

  .join-media {
    animation: hero-enter 0.4s var(--ease) backwards;
    --hero-y: 20px;
  }
}

.roles {
  padding: 50px 0 110px;
}

.roles-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 60px;
  width: 100%;
  max-width: 695px;
  margin: 0 auto;
  padding: 0 20px;
}

.roles-inner > h2 {
  text-align: center;
}

.roles-main {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 60px;
  width: 100%;
}

.roles-block {
  display: flex;
  flex-direction: column;
  gap: 60px;
  width: 100%;
}

.roles-controls {
  display: flex;
  flex-direction: column;
  gap: 40px;
  width: 100%;
}

.roles-search {
  position: relative;
  width: 100%;
}

.roles-search input {
  display: block;
  width: 100%;
  padding: 12px 32px 12px 28px;
  border: 0;
  border-bottom: var(--hair) solid var(--line);
  background: transparent;
  transition: border-color 0.15s;
}

.roles-search input::placeholder {
  color: var(--paragraph);
}

.roles-search input:focus {
  outline: none;
  border-color: var(--paragraph);
}

.roles-search input::-webkit-search-cancel-button {
  appearance: none;
}

.roles-search svg {
  position: absolute;
  top: 50%;
  left: 0;
  width: 16px;
  height: 16px;
  color: var(--black-40);
  transform: translateY(-50%);
  pointer-events: none;
}

.roles-tabs {
  position: relative;
  width: 100%;
  margin: -5px 0;
  padding: 5px 0;
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 40px, #000 calc(100% - 40px), transparent);
  mask-image: linear-gradient(90deg, transparent, #000 40px, #000 calc(100% - 40px), transparent);
}

.roles-tabs::-webkit-scrollbar {
  display: none;
}

.roles-tabs-track {
  position: relative;
  display: flex;
  align-items: center;
  gap: 20px;
  width: max-content;
  padding: 0 50%;
}

.roles-tabs button {
  flex: none;
  font-size: 17px;
  line-height: 1.6;
  white-space: nowrap;
  text-align: center;
  opacity: 0.1;
  transition: opacity 0.2s;
}

.roles-tabs button[data-near="0"] { opacity: 1; font-weight: 500; }
.roles-tabs button[data-near="1"] { opacity: 0.4; }
.roles-tabs button[data-near="2"] { opacity: 0.2; }

.roles-list {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  row-gap: 30px;
  width: 100%;
}

.role {
  position: relative;
  width: 100%;
  min-width: 0;
}

.role-open {
  position: absolute;
  inset: 0;
  z-index: 10;
}

.role p {
  position: absolute;
  top: 0;
  left: 0;
  width: max-content;
  padding: 12px 18px;
  background: var(--light-fill);
}

.role h3 {
  min-width: 0;
  padding: 46px 20px 0 0;
  overflow-wrap: break-word;
  transition: transform 0.3s;
}

.role:hover h3 {
  transform: translateX(8px);
}

.roles-empty {
  color: var(--paragraph);
  text-align: center;
}

.roles-main > .btn {
  width: 320px;
  max-width: 100%;
}

@media (min-width: 1024px) {
  .join-hero {
    padding: 85px 48px 0;
  }

  .join-hero-head {
    justify-content: space-between;
    gap: 0;
    height: 276px;
  }

  .join-features {
    display: flex;
    justify-content: space-between;
    gap: 40px 20px;
    width: 100%;
    margin: 0 auto;
  }

  .join-media {
    max-width: 1042px;
    margin-top: 50px;
  }

  .join-media::after {
    height: 200px;
  }

  .roles {
    padding: 80px 0;
  }

  .roles-inner {
    padding: 0;
  }

  .roles-main {
    gap: 80px;
  }

  .roles-block {
    gap: 50px;
  }

  .roles-controls {
    gap: 30px;
  }

  .roles-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 40px 20px;
  }

  .role p {
    padding-block: 8px;
  }

  .role h3 {
    padding-top: 40px;
  }
}

/* Motion preferences ---------------------------------------------------- */

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

  @view-transition {
    navigation: none;
  }
}
