html, body {
  height: 100%;
  overflow: hidden;
}

:root {
  --color-ink: #000;
  --color-link-muted: #777;
  --color-muted: rgba(0, 0, 0, 0.46);
  --color-line: rgba(0, 0, 0, 0.16);
  --color-paper: #fff;
  --color-surface-soft: rgba(255, 255, 255, 0.32);
  --site-page-gutter: clamp(24px, 4vw, 64px);
  --space-page-x: clamp(28px, 3.2vw, 58px);
  --space-section-y: clamp(22px, 5vw, 68px);
  --radius-none: 0;
  --radius-small: 4px;
  --shadow-soft: 0 18px 60px rgba(0, 0, 0, 0.08);
  --motion-smooth: 420ms cubic-bezier(0.65, 0, 0.35, 1);
  --text-primary: #000;
  --text-links: #777;
  --text-muted: rgba(0, 0, 0, 0.46);
  --line-soft: rgba(0, 0, 0, 0.16);
  --surface-soft: rgba(255, 255, 255, 0.32);
  --font-size-base: 16px;
  --font-weight-h1: 700;
  --font-weight-li: 400;
}

body {
  font-family: "Space Grotesk", sans-serif;
  font-size: var(--font-size-base);
  font-optical-sizing: auto;
  background-repeat: repeat;
  position: relative;
  z-index: 0;
  min-height: 100vh;
  margin: 0;
  display: grid;
  grid-template-columns: 40vw minmax(0, 1fr);
  overflow: hidden;
  transition: grid-template-columns var(--motion-smooth);
}

.main-navigation,
.case-study-body > .site-header,
.main-content {
  animation: pageFadeIn 800ms ease-out both;
}

body.is-page-exiting .main-navigation,
body.is-page-exiting.case-study-body > .site-header,
body.is-page-exiting .main-content {
  animation: pageFadeOut 420ms ease-in forwards;
}

@keyframes pageFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes pageFadeOut {
  from { opacity: 1; }
  to { opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .main-navigation,
  .case-study-body > .site-header,
  .main-content,
  body.is-page-exiting .main-navigation,
  body.is-page-exiting.case-study-body > .site-header,
  body.is-page-exiting .main-content {
    opacity: 1;
    animation: none;
  }

  .work-card--open-source-sj .work-card__preview {
    background: #E1F1F7;
    animation: none;
  }

  .open-source-sj-thumb,
  .open-source-sj-preview {
    opacity: 1;
    transform: none;
    animation: none;
  }

  .work-card--funfetti .work-card__preview,
  .shelf-selection-fx .char {
    opacity: 1;
    animation: none;
    transform: none;
  }

  .funfetti-preview {
    opacity: 1;
    animation: none;
    transform: none;
  }

  .main-navigation,
  body,
  .main-content,
  .content-nav,
  .fullscreen-toggle,
  .fullscreen-toggle__icon {
    transition: none;
  }

}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: url("./images/walltexture.jpg");
  background-repeat: repeat;
  opacity: 0.50; /* change this: 0 to 1 */
  z-index: -1;
}

@media (pointer: fine) and (prefers-reduced-motion: no-preference) {
  body.has-ink-cursor,
  body.has-ink-cursor a,
  body.has-ink-cursor button,
  body.has-ink-cursor input,
  body.has-ink-cursor textarea,
  body.has-ink-cursor select,
  body.has-ink-cursor label {
    cursor: none;
  }

  .ink-cursor {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 9999;
    width: 18px;
    height: 18px;
    opacity: 0;
    pointer-events: none;
    mix-blend-mode: multiply;
    transform: translate3d(-40px, -40px, 0) translate(-50%, -50%);
    transition:
      width 220ms cubic-bezier(0.2, 0.8, 0.2, 1),
      height 220ms cubic-bezier(0.2, 0.8, 0.2, 1),
      opacity 140ms ease;
    will-change: transform;
  }

  .ink-cursor-trail-layer {
    position: fixed;
    inset: 0;
    z-index: 9998;
    overflow: hidden;
    pointer-events: none;
    contain: layout paint;
    mix-blend-mode: multiply;
  }

  .ink-cursor::before,
  .ink-cursor::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 58% 42% 46% 54% / 44% 52% 48% 56%;
    background:
      radial-gradient(circle at 34% 32%, rgba(255, 255, 255, 0.2) 0 9%, transparent 10%),
      radial-gradient(circle at 52% 56%, rgba(0, 0, 0, 0.92) 0 48%, rgba(0, 0, 0, 0.68) 63%, transparent 72%);
    box-shadow:
      0 0 0 1px rgba(0, 0, 0, 0.16),
      0 7px 14px rgba(0, 0, 0, 0.14);
    transition:
      border-radius 220ms ease,
      filter 220ms ease,
      opacity 180ms ease,
      transform 220ms ease;
  }

  .ink-cursor::after {
    inset: 4px -3px -2px 5px;
    opacity: 0.32;
    filter: blur(4px);
    transform: rotate(18deg);
  }

  .ink-cursor.is-visible {
    opacity: 1;
  }

  .ink-cursor.is-over-interactive {
    width: 24px;
    height: 24px;
  }

  .ink-cursor.is-over-interactive::before {
    border-radius: 44% 56% 42% 58% / 56% 40% 60% 44%;
    filter: saturate(1.2) contrast(1.1);
    transform: rotate(-8deg);
  }

  .ink-cursor.is-over-card {
    width: 36px;
    height: 25px;
  }

  .ink-cursor.is-over-card::before {
    border-radius: 68% 32% 62% 38% / 48% 58% 42% 52%;
    box-shadow:
      0 0 0 1px rgba(0, 0, 0, 0.18),
      0 8px 18px rgba(0, 0, 0, 0.18);
    filter: blur(0.2px) contrast(1.12);
    transform: rotate(5deg);
  }

  .ink-cursor.is-over-card::after {
    inset: 5px -8px -3px 8px;
    opacity: 0.42;
    filter: blur(5px);
  }

  .ink-cursor.is-over-text {
    width: 13px;
    height: 21px;
    opacity: 0.78;
  }

  .ink-cursor.is-over-text::before {
    border-radius: 42% 58% 46% 54% / 70% 34% 66% 30%;
    transform: rotate(12deg);
  }

  .ink-cursor.is-pressed {
    width: 14px;
    height: 14px;
    opacity: 0.86;
  }

  .ink-cursor.is-pressed::before {
    filter: blur(0.8px) contrast(1.24);
    transform: scale(0.82);
  }

  .ink-cursor-drop {
    position: fixed;
    top: var(--y);
    left: var(--x);
    width: var(--size);
    height: calc(var(--size) * 0.82);
    pointer-events: none;
    border-radius: 62% 38% 52% 48% / 48% 62% 38% 52%;
    background:
      radial-gradient(circle at 36% 34%, rgba(255, 255, 255, 0.16) 0 8%, transparent 9%),
      radial-gradient(circle at 50% 52%, rgba(0, 0, 0, 0.72) 0 48%, rgba(0, 0, 0, 0.34) 64%, transparent 75%);
    filter: blur(0.2px);
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.68) rotate(0deg);
    animation: inkDropDissipate var(--duration) ease-out forwards;
  }

  @keyframes inkDropDissipate {
    0% {
      opacity: 0.46;
      transform: translate(-50%, -50%) scale(0.56) rotate(0deg);
      filter: blur(0);
    }

    42% {
      opacity: 0.28;
    }

    100% {
      opacity: 0;
      transform:
        translate(
          calc(-50% + var(--drift-x)),
          calc(-50% + var(--drift-y))
        )
        scale(1.86)
        rotate(var(--rotate));
      filter: blur(5px);
    }
  }
}

h1, p  {
  color: var(--text-primary);
}

.about >  p > a {
color: var(--text-links);
}

 


nav.main-navigation ul.nav-links {
  padding-left: 0;
  padding-top: 70px;
}



nav .nav-links li {
  list-style-type: none;
  margin-bottom: 25px;
}

.nav-link-fx {
  --hover-ease: cubic-bezier(0.11, 0.82, 0.39, 0.92);
  position: relative;
  display: inline-flex;
  align-items: center;
  overflow: hidden;
  padding: 0 0 0.12em;
  color: inherit;
  line-height: 1.16;
  text-decoration: none;
  cursor: pointer;
}

button.nav-link-fx {
  appearance: none;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
}

.nav-word {
  display: flex;
}

.nav-word--clone {
  position: absolute;
  top: 0;
  left: 0;
  transform: translateY(100%);
}

.nav-link-fx .char {
  display: inline-block;
  transition: transform 0.5s var(--hover-ease);
  transition-delay: calc(var(--char-index) * 0.02s);
}

.nav-link-fx:hover .nav-word--original .char,
.nav-link-fx:hover .nav-word--clone .char {
  transform: translateY(-100%);
}

/* Shared site header: stable brand, centered navigation, and one divider. */
.site-header {
  position: relative;
  z-index: 10;
  width: 100%;
  min-height: 68px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 32px;
  flex: 0 0 auto;
  margin: 0 auto;
  padding-inline: max(
    var(--site-page-gutter),
    calc((100% - 1480px) / 2 + var(--site-page-gutter))
  );
  box-sizing: border-box;
}

.site-header::after {
  position: absolute;
  right: auto;
  bottom: 0;
  left: 50%;
  width: 100vw;
  height: 1px;
  content: "";
  background: var(--line-soft);
  transform: translateX(-50%);
}

.site-header__brand {
  justify-self: start;
  color: var(--text-primary);
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
}

.site-header__nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(18px, 3vw, 38px);
  min-width: 0;
}

.site-header__nav .nav-link-fx {
  flex: 0 0 auto;
  font-size: 14px;
}

.main-navigation {
  z-index: 2;
  width: 100%;
  min-width: 0;
  height: 100vh;
  display: flex;
  padding: 8vw 2vw 2vw;
  overflow: hidden;
  box-sizing: border-box;
  position: relative;
  flex-direction: column;
  border-right: 1px solid rgba(0, 0, 0, 0.32);
  opacity: 1;
  transform: translateX(0);
  transition:
    padding var(--motion-smooth),
    opacity 220ms ease,
    border-color 220ms ease,
    transform var(--motion-smooth);
}

.main-navigation > header {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
}

.main-navigation footer {
  margin-top: auto;
  align-self: flex-start;
}

.main-navigation > header,
.main-navigation footer {
  transition:
    opacity 180ms ease,
    transform var(--motion-smooth);
}

.name-row {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.name-face-button {
  display: inline-grid;
  width: 34px;
  height: 34px;
  place-items: center;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
}

.name-face-button:focus-visible {
  outline: 1px solid currentColor;
  outline-offset: 3px;
}

.name-face {
  width: 30px;
  height: auto;
  display: block;
  transform-origin: center;
  transition:
    opacity 90ms ease,
    transform 140ms cubic-bezier(0.22, 0.8, 0.32, 1);
}

.name-face-button.is-reacting .name-face {
  width: 34px;
  transform: rotate(-5deg) scale(1.08);
}

.about h1 {
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-h1);
  margin: 0;
}

#bottomleft-corner {
  display: block;
  height: auto;
}

.main-content {
  flex: 1;
  min-width: 0;
  height: 100vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: stretch;
  padding: 2vw clamp(28px, 3.2vw, 58px) 2vw 2vw;
  box-sizing: border-box;
  transition:
    padding var(--motion-smooth);
}

.headerright-section {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 22px;
  width: 100%;
}

.fullscreen-toggle {
  position: relative;
  display: inline-grid;
  width: 34px;
  height: 34px;
  place-items: center;
  padding: 0;
  border: 1px solid var(--line-soft);
  background: rgba(255, 255, 255, 0.36);
  color: var(--text-primary);
  cursor: pointer;
  transition:
    background-color 180ms ease,
    color 180ms ease,
    transform 220ms ease,
    border-color 180ms ease;
}

.fullscreen-toggle:hover,
.fullscreen-toggle:focus-visible {
  background: #000;
  color: #fff;
  outline: none;
}

.fullscreen-toggle__icon {
  display: block;
  width: 18px;
  height: 18px;
  object-fit: contain;
  transition:
    filter 180ms ease,
    opacity 180ms ease;
}

.fullscreen-toggle:hover .fullscreen-toggle__icon,
.fullscreen-toggle:focus-visible .fullscreen-toggle__icon {
  filter: invert(1);
}

.content-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(18px, 3vw, 38px);
  min-width: 0;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-8px);
  transition:
    opacity 180ms ease,
    transform 260ms cubic-bezier(0.65, 0, 0.35, 1),
    visibility 0s linear 220ms;
  visibility: hidden;
}

.content-nav .nav-link-fx {
  font-size: 14px;
}

.is-content-fullscreen .main-navigation {
  width: 0;
  padding-right: 0;
  padding-left: 0;
  border-color: transparent;
  pointer-events: none;
  transform: translateX(-24px);
}

/* Music and Style Guide stay full-width on desktop; their sidebar returns on mobile. */
.locked-content-fullscreen .main-navigation {
  visibility: hidden;
}

body.is-content-fullscreen,
html.is-content-fullscreen body {
  grid-template-columns: 0 minmax(0, 1fr);
}

.is-content-fullscreen .main-navigation > header,
.is-content-fullscreen .main-navigation footer {
  opacity: 0;
  transform: translateX(-18px);
}

.is-content-fullscreen .main-content {
  width: 100%;
  overflow-y: auto;
  padding-top: 0;
  padding-left: clamp(28px, 3.2vw, 58px);
  scrollbar-gutter: stable;
}

@media (min-width: 901px) {
  .is-content-fullscreen .site-header {
    width: calc(100% + (2 * var(--space-page-x)));
    margin-left: calc(-1 * var(--space-page-x));
  }

  .locked-content-fullscreen .main-content {
    padding-right: 0;
    padding-left: 0;
  }

  .locked-content-fullscreen .site-header {
    width: 100%;
    margin-left: 0;
  }

  .locked-content-fullscreen.is-content-fullscreen .music-gallery,
  .locked-content-fullscreen.is-content-fullscreen .system-gallery {
    width: min(100%, 1480px);
    padding-right: var(--site-page-gutter);
    padding-left: var(--site-page-gutter);
  }

  .locked-content-fullscreen.is-content-fullscreen .music-panel {
    width: min(100%, 1240px);
    justify-self: center;
  }

  .locked-content-fullscreen.is-content-fullscreen .system-gallery > .system-section {
    width: min(100%, 1240px);
  }
}

.is-content-fullscreen .headerright-section {
  grid-template-columns: 34px minmax(0, 1fr) 34px;
}

.is-content-fullscreen .content-nav {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
  transition:
    opacity 200ms ease 90ms,
    transform 260ms cubic-bezier(0.65, 0, 0.35, 1) 70ms,
    visibility 0s;
  visibility: visible;
}

html.is-fullscreen-restoring body,
html.is-fullscreen-restoring .main-navigation,
html.is-fullscreen-restoring .main-navigation > header,
html.is-fullscreen-restoring .main-navigation footer,
html.is-fullscreen-restoring .main-content,
html.is-fullscreen-restoring .content-nav,
html.is-fullscreen-restoring .fullscreen-toggle,
html.is-fullscreen-restoring .fullscreen-toggle__icon {
  transition: none;
}

.work-gallery {
  flex: 1;
  width: min(100%, 1040px);
  min-height: 0;
  display: grid;
  grid-template-rows: auto 1fr;
  gap: clamp(22px, 4vw, 44px);
  align-content: center;
  margin-top: clamp(18px, 2vw, 24px);
  padding: clamp(22px, 5vw, 68px) clamp(18px, 4vw, 54px);
  padding-bottom: clamp(72px, 9vw, 128px);
  justify-self: center;
  box-sizing: border-box;
}

.is-content-fullscreen .work-gallery {
  flex: 0 0 auto;
  width: min(100%, 1240px);
  align-self: center;
  margin-top: 0;
  padding-top: 0;
  padding-bottom: clamp(72px, 9vw, 128px);
}

@media (min-width: 901px) {
  .work-body:not(.is-content-fullscreen) .main-content {
    overflow-y: auto;
  }

  body:not(.is-content-fullscreen) .work-gallery {
    flex: 0 0 auto;
    align-content: start;
    margin-top: 0;
  }

  .sandbox-index-body:not(.is-content-fullscreen) .sandbox-hub-page {
    gap: 0;
  }

  .sandbox-index-body:not(.is-content-fullscreen) .sandbox-hub {
    margin-top: 0;
  }
}

.is-content-fullscreen .music-gallery,
.is-content-fullscreen .system-gallery {
  width: min(100%, 1240px);
  align-self: center;
}

.is-content-fullscreen .music-shelf {
  justify-self: center;
}

.work-gallery__header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  border-bottom: 1px solid var(--line-soft);
  padding-bottom: 18px;
}

.work-gallery__header h2,
.work-gallery__header span {
  margin: 0;
  color: var(--text-primary);
  font-size: var(--font-size-base);
  font-weight: 500;
  letter-spacing: 0;
}

.work-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(180px, 1fr));
  column-gap: clamp(22px, 3.6vw, 54px);
  row-gap: clamp(30px, 3vw, 38px);
  align-content: start;
  align-items: start;
}

.is-content-fullscreen .work-grid {
  grid-template-columns: repeat(2, minmax(220px, 1fr));
  column-gap: clamp(18px, 2.8vw, 42px);
}

.work-card {
  position: relative;
  appearance: none;
  display: grid;
  width: 100%;
  gap: 12px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--text-primary);
  font: inherit;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}

.work-card__preview {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 1.42;
  overflow: hidden;
  border: 1px solid rgba(0, 0, 0, 0.055);
  background: rgba(232, 232, 232, 0.72);
  transition:
    opacity 180ms ease,
    transform 220ms ease,
    border-color 220ms ease;
}

.work-card__status {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 9px;
  border: 1px solid rgba(0, 0, 0, 0.28);
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.86);
  color: #000;
  font-family: "DM Mono", monospace;
  font-size: 10px;
  line-height: 1;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.work-card:hover .work-card__preview,
.work-card:focus-visible .work-card__preview {
  border-color: rgba(0, 0, 0, 0.16);
  opacity: 0.86;
  transform: translateY(-3px);
}

.work-card:focus-visible {
  outline: none;
}

.work-card__meta {
  display: grid;
  gap: 7px;
  opacity: 1;
  transform: none;
}

.work-card__meta strong {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.18;
}

.work-card__meta-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: baseline;
}

.work-card__tags {
  color: var(--text-muted);
  font-family: "DM Mono", monospace;
  font-size: 11px;
  line-height: 1.15;
  letter-spacing: 0;
  text-align: right;
  text-transform: uppercase;
  white-space: nowrap;
}

.work-card__caption {
  max-width: 58ch;
  color: rgba(0, 0, 0, 0.62);
  font-size: 13px;
  line-height: 1.35;
}

.work-card__preview-link {
  text-decoration: none;
}

.nav-link-fx--active {
  color: var(--text-primary);
}

.nav-link-fx--active::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: -5px;
  left: 0;
  height: 1px;
  background: currentColor;
}

.music-body .main-content {
  grid-column: 2;
  overflow-y: auto;
}

.design-system-body .main-content {
  grid-column: 2;
  overflow-y: auto;
}

.music-page {
  gap: clamp(18px, 3vw, 36px);
}

.music-gallery {
  width: min(100%, 980px);
  display: grid;
  gap: clamp(24px, 4vw, 46px);
  padding: clamp(22px, 5vw, 68px) clamp(18px, 4vw, 54px);
  box-sizing: border-box;
}

.music-gallery__header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  border-bottom: 1px solid var(--line-soft);
  padding-bottom: 18px;
}

.music-gallery__header h2,
.music-gallery__header p,
.music-gallery__header span,
.music-panel__label,
.music-panel__intro h3,
.listening-board__top h3 {
  margin: 0;
}

.music-gallery__header h2,
.music-gallery__header span {
  color: var(--text-primary);
  font-size: var(--font-size-base);
  font-weight: 500;
  letter-spacing: 0;
}

.music-gallery__header p {
  max-width: 520px;
  margin-top: 10px;
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.45;
}

.music-gallery__header span,
.music-panel__label,
.listening-board__top > span,
.spotify-board__link,
.track-list > li > span,
.track-list em {
  font-family: "DM Mono", monospace;
  font-size: 11px;
  font-style: normal;
  font-weight: 400;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.music-panel {
  display: grid;
  gap: clamp(26px, 4vw, 48px);
}

.music-panel__intro {
  display: grid;
  gap: 10px;
  max-width: 690px;
}

.music-panel__label {
  color: var(--text-muted);
}

.music-panel__intro h3,
.listening-board__top h3 {
  color: var(--text-primary);
  font-size: clamp(24px, 4vw, 46px);
  font-weight: 500;
  line-height: 0.96;
}

.music-shelf {
  width: min(100%, 900px);
}

.music-shelf__scene {
  position: relative;
  min-height: 300px;
  height: clamp(320px, 31vw, 430px);
  overflow: hidden;
  isolation: isolate;
}

.music-shelf__scene::after {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  content: "";
  background-image: url("./images/music/shelf.png");
  background-size: cover;
  background-position: center 64%;
  background-repeat: no-repeat;
  clip-path: polygon(8.5% 65.5%, 91.5% 65.5%, 91.5% 71.5%, 8.5% 71.5%);
}

.music-shelf__image {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center 64%;
}

.music-shelf__cases {
  position: absolute;
  right: clamp(30px, 10%, 100px);
  bottom: 29%;
  left: clamp(30px, 10%, 100px);
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: end;
  gap: clamp(12px, 3vw, 34px);
}

.music-shelf__status {
  position: relative;
  z-index: 3;
  grid-column: 1 / -1;
  justify-self: center;
  margin: 0;
  padding: 7px 10px;
  border: 1px solid rgba(0, 0, 0, 0.18);
  background: rgba(255, 255, 255, 0.72);
  color: var(--text-muted);
  font-size: 12px;
  line-height: 1.3;
}

.shelf-cd {
  position: relative;
  isolation: isolate;
  justify-self: center;
  width: min(100%, clamp(104px, 14.2vw, 164px));
  aspect-ratio: 1;
  color: var(--text-primary);
  text-decoration: none;
  filter: drop-shadow(0 14px 14px rgba(0, 0, 0, 0.18));
  transform-origin: 50% 100%;
  transition:
    filter 180ms ease,
    transform 180ms ease;
}

.shelf-cd::before {
  position: absolute;
  inset: 3%;
  z-index: 0;
  content: "";
  border-radius: 50%;
  background-image: url("./images/music/cd-transparent.png");
  background-position: center;
  background-repeat: no-repeat;
  background-size: contain;
  opacity: 0;
  transform: translateX(4%) rotate(-18deg);
  transform-origin: center;
  transition:
    opacity 180ms ease,
    transform 260ms ease;
}

.shelf-cd--1 {
  transform: translateY(-17px);
}

.shelf-cd--2 {
  transform: translateY(-17px);
}

.shelf-cd--3 {
  transform: translateY(-17px);
}

.shelf-cd:hover,
.shelf-cd:focus-visible,
.shelf-cd.is-active {
  z-index: 2;
  filter: drop-shadow(0 22px 20px rgba(0, 0, 0, 0.27));
}

.shelf-cd:hover::before,
.shelf-cd:focus-visible::before,
.shelf-cd.is-active::before {
  opacity: 1;
  transform: translateX(46%) rotate(16deg);
}

.shelf-cd--1:hover,
.shelf-cd--1:focus-visible {
  transform: translateY(-17px);
}

.shelf-cd--2:hover,
.shelf-cd--2:focus-visible {
  transform: translateY(-17px);
}

.shelf-cd--3:hover,
.shelf-cd--3:focus-visible {
  transform: translateY(-17px);
}

.shelf-cd:focus-visible {
  outline: 1px solid currentColor;
  outline-offset: 6px;
}

.shelf-cd__artwork {
  position: absolute;
  display: block;
}

.shelf-cd__artwork {
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.11);
  box-shadow: 0 10px 18px rgba(0, 0, 0, 0.12);
}

.music-shelf-player {
  display: grid;
  gap: 14px;
  margin-bottom: -24px;
}

.music-shelf-player__top {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  padding-top: 16px;
}

.music-shelf-player__top h3 {
  margin: 0;
  color: var(--text-primary);
  font-size: clamp(18px, 2.2vw, 26px);
  font-weight: 500;
  line-height: 1;
}

.music-shelf-player__top p {
  margin: 0;
}

.music-shelf-player__top [data-spotify-shelf-meta] {
  margin-top: 5px;
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.35;
}

.music-shelf-player__top a {
  flex: 0 0 auto;
  color: var(--text-primary);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
}

.music-shelf-player__top a:hover,
.music-shelf-player__top a:focus-visible {
  text-decoration: underline;
}

.music-shelf-player iframe {
  display: block;
  width: 100%;
  height: 152px;
  border: 0;
  background: #fff;
}

.shelf-selection-fx {
  --hover-ease: cubic-bezier(0.11, 0.82, 0.39, 0.92);
  position: relative;
  display: flex;
  width: fit-content;
  max-width: 100%;
  overflow: hidden;
  line-height: inherit;
  white-space: nowrap;
}

.shelf-selection-fx .nav-word {
  line-height: inherit;
}

.shelf-selection-fx .nav-word--clone {
  inset: 0 auto auto 0;
}

.shelf-selection-fx .char {
  display: inline-block;
  backface-visibility: hidden;
  transition: transform 0.5s var(--hover-ease);
  transition-delay: calc(var(--char-index) * 0.02s);
  will-change: transform;
}

.shelf-selection-fx.is-swapping .nav-word--original .char,
.shelf-selection-fx.is-swapping .nav-word--clone .char {
  transform: translateY(-100%);
}

.album-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(16px, 2.6vw, 34px);
}

.album-card {
  display: grid;
  gap: 13px;
  min-width: 0;
}

.album-card__cover {
  position: relative;
  display: block;
  aspect-ratio: 1;
  overflow: hidden;
  border: 1px solid rgba(0, 0, 0, 0.085);
  background: #fff;
}

.album-card__cover::before,
.album-card__cover::after,
.album-card__cover > span {
  content: "";
  position: absolute;
  display: block;
}

.album-card__cover::before {
  inset: 12%;
  border: 1px solid rgba(0, 0, 0, 0.18);
}

.album-card__cover::after {
  right: 14%;
  bottom: 14%;
  left: 14%;
  height: 1px;
  background: rgba(0, 0, 0, 0.24);
}

.album-card__cover > span {
  width: 28%;
  aspect-ratio: 1;
  border-radius: 50%;
}

.album-card--pulse .album-card__cover {
  background:
    linear-gradient(135deg, rgba(255, 107, 129, 0.24), transparent 56%),
    #fff;
}

.album-card--pulse .album-card__cover > span {
  top: 20%;
  left: 18%;
  background: #ff6b81;
}

.album-card--signal .album-card__cover {
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.08) 1px, transparent 1px),
    linear-gradient(180deg, rgba(0, 0, 0, 0.06) 1px, transparent 1px),
    #f7f8ff;
  background-size: 18px 18px;
}

.album-card--signal .album-card__cover > span {
  top: 36%;
  left: 36%;
  background: #2867ff;
}

.album-card--groove .album-card__cover {
  background:
    radial-gradient(circle at 50% 50%, transparent 0 16%, rgba(0, 0, 0, 0.11) 17% 18%, transparent 19% 30%, rgba(0, 0, 0, 0.11) 31% 32%, transparent 33%),
    #fff8d8;
}

.album-card--groove .album-card__cover > span {
  top: 50%;
  left: 50%;
  width: 12%;
  background: #ffb000;
  transform: translate(-50%, -50%);
}

.album-card h4,
.album-card p,
.track-list strong,
.track-list p {
  margin: 0;
}

.album-card h4,
.track-list strong {
  color: var(--text-primary);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.15;
}

.album-card p,
.track-list p {
  color: var(--text-muted);
  font-size: 12px;
  line-height: 1.35;
}

.listening-board {
  border-top: 1px solid var(--line-soft);
  padding-top: clamp(22px, 3vw, 34px);
}

.spotify-board {
  display: grid;
  gap: 18px;
  border-top: 1px solid var(--line-soft);
  padding-top: clamp(22px, 3vw, 34px);
}

.listening-board__top {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
}

.listening-board__top > div {
  display: grid;
  gap: 10px;
}

.listening-board__top > span,
.track-list > li > span,
.track-list em {
  color: var(--text-muted);
}

.spotify-board__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  padding: 0 12px;
  border: 1px solid var(--line-soft);
  color: var(--text-primary);
  text-decoration: none;
  transition:
    background 160ms ease,
    border-color 160ms ease;
}

.spotify-board__link:hover,
.spotify-board__link:focus-visible {
  border-color: rgba(0, 0, 0, 0.34);
  background: rgba(255, 255, 255, 0.48);
}

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

.top-tracks {
  display: grid;
  gap: 14px;
}

.top-tracks__status,
.top-tracks__meta {
  margin: 0;
  color: var(--text-muted);
  font-size: 12px;
  line-height: 1.45;
}

.top-tracks__meta {
  font-family: "DM Mono", monospace;
  font-size: 11px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.top-tracks__list {
  display: grid;
  grid-auto-flow: column;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: repeat(5, minmax(0, auto));
  column-gap: clamp(24px, 4vw, 56px);
  gap: 0;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--line-soft);
  list-style: none;
}

.top-track {
  display: grid;
  grid-template-columns: 34px 64px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  min-height: 100px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line-soft);
}

.top-track__number {
  color: var(--text-muted);
  font-family: "DM Mono", monospace;
  font-size: 11px;
  letter-spacing: 0.04em;
}

.top-track__artwork-button {
  position: relative;
  width: 64px;
  aspect-ratio: 1;
  padding: 0;
  border: 0;
  display: block;
  background: transparent;
  cursor: pointer;
}

.top-track__artwork-button::before,
.top-track__artwork-button::after {
  position: absolute;
  inset: 0;
  z-index: 1;
  content: "";
  opacity: 0;
  pointer-events: none;
  transition: opacity 160ms ease;
}

.top-track__artwork-button::before {
  background: rgba(0, 0, 0, 0.44);
}

.top-track__artwork-button::after {
  width: 0;
  height: 0;
  margin: auto;
  border-top: 10px solid transparent;
  border-bottom: 10px solid transparent;
  border-left: 15px solid #fff;
  transform: translateX(2px);
}

.top-track__artwork-button:focus-visible {
  outline: 1px solid currentColor;
  outline-offset: 4px;
}

.top-track__artwork-button:hover::before,
.top-track__artwork-button:hover::after,
.top-track__artwork-button:focus-visible::before,
.top-track__artwork-button:focus-visible::after {
  opacity: 1;
}

.top-track__artwork-button:hover .top-track__artwork,
.top-track__artwork-button:focus-visible .top-track__artwork {
  border-color: rgba(0, 0, 0, 0.34);
}

.top-track__artwork {
  width: 100%;
  height: 100%;
  display: block;
  border: 1px solid rgba(0, 0, 0, 0.1);
  object-fit: cover;
  background: #fff;
}

.top-track__details {
  min-width: 0;
  display: grid;
  gap: 5px;
}

.top-track__title {
  color: var(--text-primary);
  font-size: clamp(18px, 2vw, 26px);
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
}

.top-track__title:hover,
.top-track__title:focus-visible {
  text-decoration: underline;
  text-underline-offset: 0.12em;
}

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

.top-track__artist,
.top-track__album {
  margin: 0;
  color: var(--text-muted);
  font-size: 12px;
  line-height: 1.25;
}

.top-track__artist {
  color: var(--text-primary);
}

.track-list {
  display: grid;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--line-soft);
  list-style: none;
}

.track-list li {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  min-height: 72px;
  border-bottom: 1px solid var(--line-soft);
}

.design-system-page {
  gap: clamp(18px, 3vw, 36px);
}

.system-gallery {
  width: min(100%, 980px);
  display: grid;
  gap: clamp(26px, 4vw, 50px);
  padding: var(--space-section-y) clamp(18px, 4vw, 54px);
  box-sizing: border-box;
}

.system-gallery__header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  border-bottom: 1px solid var(--line-soft);
  padding-bottom: 18px;
}

.system-gallery__header h2,
.system-gallery__header p,
.system-gallery__header span,
.system-kicker,
.system-section h3,
.system-section p,
.system-section h4,
.component-demo h4,
.system-notes dt,
.system-notes dd {
  margin: 0;
}

.system-gallery__header h2,
.system-gallery__header span,
.system-section__top h3 {
  color: var(--text-primary);
  font-size: var(--font-size-base);
  font-weight: 500;
  letter-spacing: 0;
}

.system-gallery__header p,
.system-section__top p,
.system-body-copy,
.system-notes dd {
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.45;
}

.system-gallery__header p {
  max-width: 560px;
  margin-top: 10px;
}

.system-gallery__header span,
.system-kicker,
.component-demo__top span,
.system-pill,
.type-samples span,
.token-card code,
.system-notes dt {
  font-family: "DM Mono", monospace;
  font-size: 11px;
  font-style: normal;
  font-weight: 400;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.system-section {
  display: grid;
  gap: clamp(18px, 3vw, 28px);
  border-top: 1px solid var(--line-soft);
  padding-top: clamp(22px, 3.4vw, 40px);
}

.system-gallery__header + .system-section {
  border-top: 0;
  padding-top: 0;
}

.system-section > h3,
.type-sample--statement,
.case-study-sample__story h4 {
  max-width: 780px;
  color: var(--text-primary);
  font-size: clamp(24px, 4vw, 46px);
  font-weight: 500;
  line-height: 0.98;
}

.system-body-copy {
  max-width: 620px;
}

.system-section__top {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}

.system-section__top p {
  max-width: 440px;
  text-align: right;
}

.system-kicker,
.component-demo__top span,
.system-pill,
.type-samples span,
.token-card code,
.system-notes dt {
  color: var(--text-muted);
}

.token-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(14px, 2vw, 24px);
}

.token-card {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.token-swatch {
  display: block;
  aspect-ratio: 1.35;
  border: 1px solid var(--line-soft);
}

.token-swatch--ink {
  background: var(--color-ink);
}

.token-swatch--muted {
  background: var(--color-muted);
}

.token-swatch--line {
  background: var(--color-line);
}

.token-swatch--paper {
  background: var(--color-paper);
}

.token-card strong {
  color: var(--text-primary);
  font-size: 13px;
  font-weight: 600;
}

.token-card code {
  overflow: hidden;
  text-overflow: ellipsis;
  text-transform: none;
  white-space: nowrap;
}

.type-samples {
  display: grid;
  gap: 20px;
}

.type-samples > div {
  display: grid;
  gap: 8px;
  border-top: 1px solid var(--line-soft);
  padding-top: 16px;
}

.type-sample--title {
  color: var(--text-primary);
  font-size: var(--font-size-base);
  font-weight: 500;
}

.type-sample--mono {
  color: var(--text-primary);
  font-family: "DM Mono", monospace;
  font-size: 12px;
  letter-spacing: 0.04em;
}

.component-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(18px, 2.8vw, 34px);
  align-items: start;
}

.component-demo {
  display: grid;
  gap: 22px;
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--line-soft);
  background: rgba(255, 255, 255, 0.28);
}

.component-demo__top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
}

.component-demo h4,
.case-study-sample h4 {
  color: var(--text-primary);
  font-size: 15px;
  font-weight: 600;
}

.button-row,
.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.link-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 14px;
  border: 1px solid var(--line-soft);
  background: rgba(255, 255, 255, 0.42);
  color: var(--text-primary);
  font-size: 13px;
  line-height: 1;
  text-decoration: none;
  transition:
    background-color 180ms ease,
    border-color 180ms ease,
    color 180ms ease,
    transform 180ms ease;
}

.link-button:hover,
.link-button:focus-visible {
  border-color: #000;
  background: #000;
  color: #fff;
  outline: none;
  transform: translateY(-2px);
}

.link-button--dark {
  background: #000;
  border-color: #000;
  color: #fff;
  font: inherit;
  font-size: 13px;
  cursor: pointer;
}

.system-pill {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 10px;
  border: 1px solid var(--line-soft);
  background: rgba(255, 255, 255, 0.32);
}

.component-demo--card {
  grid-column: span 1;
}

.system-card-sample {
  pointer-events: none;
}

.system-card-sample .work-card__meta {
  position: static;
  opacity: 1;
  transform: none;
}

.case-study-sample {
  display: grid;
  grid-template-columns: minmax(220px, 0.42fr) minmax(0, 1fr);
  border: 1px solid var(--line-soft);
  background: rgba(255, 255, 255, 0.28);
}

.case-study-sample aside,
.case-study-sample__story {
  min-width: 0;
}

.case-study-sample aside {
  display: grid;
  align-content: start;
  gap: 16px;
  padding: clamp(20px, 3vw, 34px);
  border-right: 1px solid var(--line-soft);
}

.case-study-sample aside p:not(.system-kicker) {
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.45;
}

.case-study-sample__story {
  display: grid;
  gap: 22px;
  padding: clamp(20px, 3vw, 34px);
}

.case-study-sample__story figure {
  position: relative;
  overflow: hidden;
  aspect-ratio: 1.72;
  margin: 0;
  border: 1px solid rgba(0, 0, 0, 0.055);
  background: #fff;
}

.case-study-sample__story img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.case-study-sample__story > div {
  display: grid;
  gap: 10px;
}

.system-notes {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(18px, 2.8vw, 34px);
  margin: 0;
}

.system-notes div {
  display: grid;
  gap: 8px;
  min-width: 0;
  border-top: 1px solid var(--line-soft);
  padding-top: 14px;
}

html.case-study-root {
  height: auto;
  min-height: 100%;
  overflow-x: hidden;
  overflow-y: auto;
}

html.case-study-root body.case-study-body {
  height: auto;
  display: block;
  min-height: 100vh;
  overflow: visible;
}

.case-study-nav {
  position: relative;
  z-index: 10;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) 34px;
  align-items: center;
  gap: 22px;
  width: 100%;
  padding: 2vw clamp(28px, 3.2vw, 58px);
  box-sizing: border-box;
}

.case-study-nav__slot {
  width: 34px;
  height: 34px;
}

.case-study-nav__links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(18px, 3vw, 38px);
  min-width: 0;
}

.case-study-nav__links .nav-link-fx {
  font-size: 14px;
}

.case-study-page {
  width: min(100% - 48px, 1180px);
  margin: 0 auto;
  padding: clamp(36px, 6vw, 86px) 0 clamp(64px, 10vw, 140px);
}

.case-study-hero {
  display: grid;
  grid-template-columns: minmax(220px, 0.34fr) minmax(0, 1fr);
  gap: clamp(32px, 6vw, 86px);
  align-items: start;
  border-bottom: 1px solid var(--line-soft);
  padding-bottom: clamp(44px, 7vw, 86px);
}

.case-study-hero__meta {
  position: sticky;
  top: 86px;
  display: grid;
  gap: 30px;
}

.case-study-back,
.case-study-actions a {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid rgba(0, 0, 0, 0.24);
  color: var(--text-primary);
  font-family: "DM Mono", monospace;
  font-size: 11px;
  text-decoration: none;
  transition:
    background-color 180ms ease,
    color 180ms ease,
    transform 180ms ease;
}

.case-study-back:hover,
.case-study-back:focus-visible,
.case-study-actions a:hover,
.case-study-actions a:focus-visible {
  background: #000;
  color: #fff;
  outline: none;
  transform: translateY(-2px);
}

.case-study-hero__meta dl {
  display: grid;
  margin: 0;
}

.case-study-hero__meta div {
  display: grid;
  gap: 8px;
  padding: 15px 0;
  border-top: 1px solid var(--line-soft);
}

.case-study-hero__meta dt,
.case-study-kicker,
.case-study-placeholder span,
.case-study-feature-grid span,
.case-study-figure figcaption {
  color: var(--text-muted);
  font-family: "DM Mono", monospace;
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.case-study-hero__meta dd {
  margin: 0;
  color: var(--text-primary);
  font-size: 13px;
  line-height: 1.35;
}

.case-study-hero__intro {
  display: grid;
  gap: 22px;
}

.case-study-kicker,
.case-study-hero__intro h1,
.case-study-hero__intro p,
.case-study-section h2,
.case-study-section h3,
.case-study-copy p,
.case-study-list,
.case-study-figure,
.case-study-figure figcaption,
.case-study-placeholder p,
.case-study-placeholder strong {
  margin: 0;
}

.case-study-hero__intro h1 {
  max-width: 760px;
  color: var(--text-primary);
  font-size: clamp(34px, 4.4vw, 56px);
  font-weight: 600;
  line-height: 1.04;
  letter-spacing: 0;
}

.case-study-hero__intro > p {
  max-width: 700px;
  color: rgba(0, 0, 0, 0.68);
  font-size: clamp(17px, 1.45vw, 21px);
  line-height: 1.35;
}

.case-study-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding-top: 8px;
}

.case-study-actions a {
  min-width: 132px;
}

.case-study-section,
.case-study-figure--wide {
  margin-top: clamp(52px, 8vw, 104px);
}

.case-study-section {
  display: grid;
  gap: clamp(22px, 4vw, 42px);
  border-top: 1px solid var(--line-soft);
  padding-top: clamp(28px, 4vw, 52px);
}

.case-study-section--split {
  grid-template-columns: minmax(220px, 0.48fr) minmax(0, 1fr);
  gap: clamp(32px, 6vw, 86px);
}

.case-study-problem-grid {
  display: grid;
  grid-template-columns: minmax(220px, 0.48fr) minmax(0, 1fr);
  gap: clamp(32px, 6vw, 86px);
  margin-bottom: clamp(12px, 2vw, 22px);
}

.case-study-problem-heading {
  display: grid;
  align-content: start;
  gap: 18px;
  max-width: 420px;
}

.case-study-section--split > div:first-child {
  display: grid;
  align-content: start;
  gap: 18px;
}

.case-study-section h2 {
  max-width: 760px;
  color: var(--text-primary);
  font-size: clamp(17px, 1.45vw, 21px);
  font-weight: 500;
  line-height: 1.35;
}

.case-study-section__top {
  display: grid;
  gap: 18px;
}

.case-study-iteration-layout {
  display: grid;
  grid-template-columns: minmax(220px, 0.48fr) minmax(0, 1fr);
  gap: clamp(32px, 6vw, 86px);
  align-items: start;
}

.case-study-iteration-layout--stacked {
  grid-template-columns: 1fr;
}

.case-study-iteration-media {
  display: grid;
  gap: clamp(18px, 3vw, 34px);
}

.case-study-copy {
  display: grid;
  gap: 18px;
}

.case-study-copy p,
.case-study-list li,
.case-study-feature-grid p,
.case-study-placeholder p {
  color: rgba(0, 0, 0, 0.68);
  font-size: 16px;
  line-height: 1.48;
}

.case-study-list {
  display: grid;
  gap: 14px;
  padding: 0;
  list-style: none;
}

.case-study-list li {
  position: relative;
  padding: 16px 0 16px 34px;
  border-top: 1px solid var(--line-soft);
}

.case-study-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 24px;
  width: 12px;
  height: 12px;
  background: #000;
}

.case-study-list--columns {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: clamp(22px, 4vw, 54px);
}

.case-study-figure {
  display: grid;
  gap: 12px;
}

.case-study-figure--framed {
  border: 1px solid rgba(0, 0, 0, 0.09);
  background: rgba(0, 0, 0, 0.035);
  padding: clamp(18px, 2.8vw, 34px);
}

.case-study-figure img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid rgba(0, 0, 0, 0.09);
  background: #fff;
}

.case-study-figure--framed img {
  border: 0;
}

.case-study-figure--wide img {
  aspect-ratio: 16 / 10;
  object-fit: contain;
}

.case-study-figure--scroll {
  border: 1px solid rgba(0, 0, 0, 0.09);
  background: rgba(0, 0, 0, 0.035);
}

.case-study-scroll-frame {
  max-height: 780px;
  overflow: auto;
  padding: clamp(18px, 2.8vw, 34px);
}

.case-study-scroll-frame img {
  border: 0;
}

.case-study-figure--zoom-scroll .case-study-scroll-frame {
  height: min(72vh, 760px);
  max-height: none;
  overflow-x: hidden;
  padding: clamp(14px, 2vw, 24px);
  overscroll-behavior: contain;
}

.case-study-figure--zoom-scroll .case-study-scroll-frame img {
  width: 100%;
  max-width: 100%;
}

.case-study-figure--compact-scroll {
  width: min(100%, 820px);
  margin-right: auto;
  margin-left: auto;
}

.case-study-figure--compact-scroll .case-study-scroll-frame {
  max-height: 500px;
  padding: clamp(14px, 2vw, 24px);
}

.case-study-figure--scroll figcaption {
  padding: 0 clamp(18px, 2.8vw, 34px) clamp(14px, 2vw, 24px);
}

.case-study-figure--phone {
  align-self: start;
  border: 1px solid rgba(0, 0, 0, 0.08);
  background: rgba(0, 0, 0, 0.035);
}

.case-study-phone-frame {
  max-height: 780px;
  overflow-x: hidden;
  overflow-y: auto;
  padding: clamp(12px, 1.8vw, 18px);
}

.case-study-phone-frame img {
  box-sizing: border-box;
  width: 100%;
  max-width: 375px;
  margin: 0 auto;
  border-color: rgba(0, 0, 0, 0.06);
}

.case-study-figure--phone figcaption {
  padding: 0 clamp(18px, 2.8vw, 34px) clamp(14px, 2vw, 24px);
}

.case-study-figure figcaption {
  line-height: 1.4;
}

.case-study-media-grid,
.case-study-feature-grid,
.case-study-audit-list,
.case-study-flow-steps {
  display: grid;
  gap: clamp(18px, 3vw, 34px);
}

.case-study-media-grid--two {
  grid-template-columns: minmax(0, 1fr) minmax(180px, 0.36fr);
}

.case-study-media-grid--balanced {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.case-study-media-grid--comparison {
  gap: clamp(24px, 4vw, 48px);
}

.case-study-media-grid--three {
  grid-template-columns: minmax(0, 1.4fr) repeat(2, minmax(0, 1fr));
}

.case-study-media-grid--four,
.case-study-feature-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.case-study-flow-layout {
  display: grid;
  gap: clamp(18px, 3vw, 34px);
}

.case-study-flow-steps {
  grid-template-columns: 1fr;
  gap: 0;
}

.case-study-placeholder,
.case-study-feature-grid article {
  display: grid;
  align-content: start;
  gap: 12px;
  min-height: 280px;
  padding: 18px;
  border: 1px dashed rgba(0, 0, 0, 0.24);
  background: rgba(255, 255, 255, 0.28);
}

.case-study-placeholder strong,
.case-study-feature-grid h3 {
  color: var(--text-primary);
  font-size: clamp(19px, 2.4vw, 30px);
  font-weight: 600;
  line-height: 1.02;
}

.case-study-feature-grid article {
  min-height: 260px;
  border-style: solid;
}

.case-study-flow-steps article {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 16px;
  padding: 14px 0;
}

.case-study-flow-steps span {
  color: var(--text-muted);
  font-family: "DM Mono", monospace;
  font-size: 11px;
  letter-spacing: 0.04em;
}

.case-study-flow-steps h3 {
  margin: 0;
  color: var(--text-primary);
  font-size: 15px;
  font-weight: 500;
  line-height: 1.4;
}

.case-study-flow-steps p {
  color: rgba(0, 0, 0, 0.68);
  font-size: 14px;
  line-height: 1.45;
  margin: 4px 0 0;
}

.case-study-audit-list {
  align-content: start;
  gap: 22px;
}

.case-study-audit-list article {
  display: block;
  padding: 0;
}

.case-study-audit-list span {
  color: var(--text-muted);
  font-family: "DM Mono", monospace;
  font-size: 11px;
  letter-spacing: 0.04em;
}

.case-study-audit-list h3,
.case-study-audit-list p {
  margin: 0;
}

.case-study-audit-list h3 {
  color: var(--text-primary);
  font-size: 16px;
  font-weight: 600;
  line-height: 1.48;
}

.case-study-audit-list p {
  margin-top: 2px;
  color: rgba(0, 0, 0, 0.68);
  font-size: 16px;
  line-height: 1.48;
}

.case-study-reveal {
  opacity: 0;
  transform: translateY(34px);
  transition:
    opacity 560ms ease var(--reveal-delay, 0ms),
    transform 700ms cubic-bezier(0.16, 1, 0.3, 1) var(--reveal-delay, 0ms);
}

.case-study-reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.work-card--open-source-sj .work-card__preview {
  display: grid;
  place-items: stretch;
  isolation: isolate;
  background: #E1F1F7;
}

.open-source-sj-preview {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  transform: scale(1);
  transition: transform 620ms cubic-bezier(0.65, 0, 0.35, 1);
}

.work-card--open-source-sj:hover .open-source-sj-preview,
.work-card--open-source-sj:focus-visible .open-source-sj-preview {
  transform: scale(1.025);
}

.code-rain-background {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
  background: #222222;
  opacity: 1;
}

.code-rain-canvas {
  display: block;
  width: 100%;
  height: 100%;
  opacity: 0.42;
}

.open-source-sj-thumb {
  position: relative;
  z-index: 1;
  display: block;
  width: auto;
  height: min(58%, 118px);
  max-width: 72%;
  object-fit: contain;
  opacity: 1;
  transform: none;
}

.work-card--rainbow .work-card__preview {
  display: grid;
  place-items: center;
  container-type: inline-size;
  background: #fff;
}

.work-card--ink .work-card__preview,
.work-card--hourglass .work-card__preview {
  display: grid;
  place-items: center;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.28), transparent 42%),
    rgba(232, 232, 232, 0.72);
}

.work-card--bizznest .work-card__preview {
  aspect-ratio: 1076 / 720;
  display: grid;
  place-items: stretch;
  border: 0;
  background: rgba(0, 0, 0, 0.055);
}

.work-body .work-card--bizznest .work-card__preview {
  aspect-ratio: 1076 / 720;
}

.bizznest-thumb {
  display: grid;
  place-items: stretch;
}

.bizznest-thumb__video,
.bizznest-thumb__poster {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  transform: none;
}

.bizznest-thumb__video {
  pointer-events: none;
}

.bizznest-thumb__poster {
  display: none;
}

.work-card--bizznest .work-card__meta-head {
  grid-template-columns: 1fr;
  gap: 4px;
}

.work-card--bizznest .work-card__tags {
  text-align: left;
  white-space: normal;
}

@media (prefers-reduced-motion: reduce) {
  .bizznest-thumb__video {
    display: none;
  }

  .bizznest-thumb__poster {
    display: block;
  }
}

.bizznest-page .case-study-figure--wide img {
  background: #d94f98;
  object-fit: cover;
}

.bizznest-page-preview {
  overflow: hidden;
}

.bizznest-page .bizznest-page-preview__video {
  display: block;
  width: 100%;
  aspect-ratio: 1076 / 720;
  object-fit: contain;
  background: rgba(0, 0, 0, 0.055);
  pointer-events: none;
}

.bizznest-page .case-study-phone-frame {
  background: #f7f7f5;
}

.bizznest-page .bizznest-responsive-preview-grid {
  align-items: start;
}

.work-card--funfetti .work-card__preview {
  display: grid;
  place-items: stretch;
  isolation: isolate;
  background: #fff7e7;
}

.funfetti-preview {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  transform: scale(1);
  transition: transform 620ms cubic-bezier(0.65, 0, 0.35, 1);
}

.work-card--funfetti:hover .funfetti-preview,
.work-card--funfetti:focus-visible .funfetti-preview {
  transform: scale(1.025);
}

.work-card--john-tello .work-card__preview {
  display: grid;
  place-items: stretch;
  isolation: isolate;
  background: #d9e0e4;
}

.john-tello-thumb__clouds,
.john-tello-thumb__clouds img {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
}

.john-tello-thumb__clouds {
  z-index: 0;
  overflow: hidden;
}

.john-tello-thumb__clouds img {
  object-fit: cover;
  object-position: center;
  transform: scale(1.02);
  transition: transform 620ms cubic-bezier(0.65, 0, 0.35, 1);
}

.work-card--john-tello .work-card__meta-head {
  grid-template-columns: 1fr;
  gap: 4px;
}

.work-card--john-tello .work-card__tags {
  text-align: left;
  white-space: normal;
}

.work-card--john-tello:hover .john-tello-thumb__clouds img,
.work-card--john-tello:focus-visible .john-tello-thumb__clouds img {
  transform: scale(1.06);
}

.work-card--lingualoop .work-card__preview {
  display: grid;
  place-items: stretch;
  isolation: isolate;
  background: #f5f1f0;
}

.lingualoop-thumb__image {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top left;
  transform: scale(1.01);
  transition: transform 620ms cubic-bezier(0.65, 0, 0.35, 1);
}

.work-card--lingualoop .work-card__meta-head {
  grid-template-columns: 1fr;
  gap: 4px;
}

.work-card--lingualoop .work-card__tags {
  text-align: left;
  white-space: normal;
}

.work-card--lingualoop:hover .lingualoop-thumb__image,
.work-card--lingualoop:focus-visible .lingualoop-thumb__image {
  transform: scale(1.045);
}

.project-status-note {
  max-width: 700px;
  border-left: 2px solid #000;
  padding-left: 14px;
  color: rgba(0, 0, 0, 0.72);
  font-size: 15px;
  line-height: 1.45;
}

.lingualoop-preview picture {
  display: block;
}

.lingualoop-preview img {
  background: #f5f1f0;
}

.lingualoop-feature-grid article {
  min-height: 230px;
}

.rainbow-thumb__brand {
  display: flex;
  align-items: center;
  gap: clamp(6px, 4cqw, 14px);
  max-width: 88%;
  transform: translateY(2px);
}

.rainbow-thumb__logo {
  position: relative;
  width: clamp(16px, 10cqw, 30px);
  height: clamp(12px, 7cqw, 21px);
  display: inline-block;
  flex: 0 0 auto;
}

.rainbow-thumb__tile {
  position: absolute;
  width: 39%;
  aspect-ratio: 1;
  opacity: 0;
  mix-blend-mode: multiply;
  animation: rainbowThumbTile 4.6s ease infinite;
}

.rainbow-thumb__tile--cyan {
  left: 0;
  top: 20%;
  background: rgba(0, 174, 239, 0.78);
  animation-delay: 0s;
}

.rainbow-thumb__tile--yellow {
  left: 25%;
  top: 0;
  background: rgba(255, 222, 0, 0.82);
  animation-delay: 0.08s;
}

.rainbow-thumb__tile--magenta {
  left: 15%;
  top: 38%;
  background: rgba(236, 0, 140, 0.76);
  animation-delay: 0.16s;
}

.rainbow-thumb__word {
  display: flex;
  gap: clamp(1px, 1.1cqw, 3px);
  min-width: 0;
  font-family: "DM Mono", monospace;
  font-size: clamp(9px, 6cqw, 15px);
  font-weight: 500;
  letter-spacing: 0.18em;
  line-height: 1;
  text-transform: uppercase;
}

.rainbow-thumb__word span {
  display: inline-block;
  opacity: 0;
  animation: rainbowThumbLetter 4.6s ease infinite;
  animation-delay: calc(0.32s + (var(--letter-index, 0) * 0.035s));
}

.rainbow-thumb__word span:nth-child(1) { --letter-index: 0; }
.rainbow-thumb__word span:nth-child(2) { --letter-index: 1; }
.rainbow-thumb__word span:nth-child(3) { --letter-index: 2; }
.rainbow-thumb__word span:nth-child(4) { --letter-index: 3; }
.rainbow-thumb__word span:nth-child(5) { --letter-index: 4; }
.rainbow-thumb__word span:nth-child(6) { --letter-index: 5; }
.rainbow-thumb__word span:nth-child(7) { --letter-index: 6; }
.rainbow-thumb__word span:nth-child(9) { --letter-index: 7; }
.rainbow-thumb__word span:nth-child(10) { --letter-index: 8; }
.rainbow-thumb__word span:nth-child(11) { --letter-index: 9; }

.rainbow-thumb__word .rainbow-thumb__space {
  width: clamp(4px, 3.2cqw, 9px);
  opacity: 1;
  animation: none;
}

@keyframes rainbowThumbTile {
  0% {
    opacity: 0;
    transform: translate(-14px, -10px) rotate(-8deg) scale(0.72);
  }
  12%,
  72% {
    opacity: 1;
    transform: translate(0, 0) rotate(0deg) scale(1);
  }
  86%,
  100% {
    opacity: 0;
    transform: translateY(-4px) scale(0.96);
  }
}

@keyframes rainbowThumbLetter {
  0%,
  7% {
    opacity: 0;
    transform: translateY(9px);
  }
  18%,
  72% {
    opacity: 1;
    transform: translateY(0);
  }
  86%,
  100% {
    opacity: 0;
    transform: translateY(-4px);
  }
}

.work-card--placeholder .work-card__preview {
  opacity: 0.42;
}

.work-card--placeholder .work-card__preview::before,
.work-card--placeholder .work-card__preview::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  background: rgba(0, 0, 0, 0.12);
  transform: translate(-50%, -50%);
}

.work-card--placeholder .work-card__preview::before {
  width: 42%;
  height: 1px;
}

.work-card--placeholder .work-card__preview::after {
  width: 1px;
  height: 38%;
}

#topright-corner {
  display: block;
  height: auto;
}

body.is-project-open {
  overflow: hidden;
}

.project-modal {
  position: fixed;
  inset: 0;
  z-index: 30;
  display: grid;
  place-items: center;
  padding: clamp(20px, 4vw, 64px);
  box-sizing: border-box;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 240ms ease, visibility 240ms ease;
}

.project-modal.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.project-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.58);
  backdrop-filter: blur(5px);
}

.project-modal__panel {
  position: relative;
  width: min(1180px, 100%);
  height: min(88vh, 860px);
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(0, 0, 0, 0.28);
  border-radius: 4px;
  background-color: #f4f4ef;
  background-image: url("./images/walltexture.jpg");
  background-repeat: repeat;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.32);
  opacity: 0;
  transform: translateY(22px) scale(0.985);
  transition: opacity 280ms ease, transform 360ms cubic-bezier(0.16, 1, 0.3, 1);
}

.project-modal.is-open .project-modal__panel {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.project-modal__topbar {
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 12px 0 18px;
  border-bottom: 1px solid var(--line-soft);
  box-sizing: border-box;
  background: rgba(244, 244, 239, 0.9);
}

.project-modal__count,
.project-modal__label,
.project-modal__meta dt {
  font-family: "DM Mono", monospace;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0;
  text-transform: uppercase;
}

.project-modal__count,
.project-modal__label {
  color: rgba(0, 0, 0, 0.5);
}

.project-modal__close {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  background: transparent;
  color: #000;
  font: inherit;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.project-modal__close:hover,
.project-modal__close:focus-visible {
  background: #000;
  color: #fff;
  outline: none;
}

.project-modal__layout {
  min-height: 0;
  flex: 1;
  display: grid;
  grid-template-columns: minmax(250px, 300px) minmax(0, 1fr);
}

.project-modal__rail {
  min-width: 0;
  display: flex;
  flex-direction: column;
  padding: 30px 26px 24px;
  border-right: 1px solid var(--line-soft);
  box-sizing: border-box;
  background: rgba(244, 244, 239, 0.72);
}

.project-modal__rail h2,
.project-modal__rail p,
.project-modal__story h3,
.project-modal__story p,
.project-modal__story figure {
  margin: 0;
}

.project-modal__rail h2 {
  margin-top: 14px;
  font-size: 36px;
  font-weight: 600;
  line-height: 0.98;
}

.project-modal__summary {
  margin-top: 18px !important;
  color: rgba(0, 0, 0, 0.64);
  font-size: 14px;
  line-height: 1.45;
}

.project-modal__meta {
  display: grid;
  margin: 30px 0 0;
}

.project-modal__meta div {
  display: grid;
  grid-template-columns: 58px 1fr;
  gap: 12px;
  padding: 12px 0;
  border-top: 1px solid var(--line-soft);
}

.project-modal__meta dd,
.project-modal__meta dt {
  margin: 0;
}

.project-modal__meta dt {
  color: rgba(0, 0, 0, 0.44);
}

.project-modal__meta dd {
  font-size: 12px;
  line-height: 1.35;
}

.project-modal__links {
  display: grid;
  gap: 8px;
  margin-top: auto;
  padding-top: 26px;
}

.project-modal__links a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 36px;
  padding: 0 10px;
  border: 1px solid rgba(0, 0, 0, 0.24);
  color: #000;
  font-family: "DM Mono", monospace;
  font-size: 11px;
  text-decoration: none;
}

.project-modal__links a:hover,
.project-modal__links a:focus-visible {
  background: #000;
  color: #fff;
  outline: none;
}

.project-modal__story {
  min-width: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  background: rgba(255, 255, 255, 0.58);
}

.project-modal__story:focus {
  outline: none;
}

.project-modal__hero {
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-bottom: 1px solid var(--line-soft);
  background: #fff;
}

.project-modal__hero video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

.project-modal__statements {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-bottom: 1px solid var(--line-soft);
}

.project-modal__statements section {
  min-height: 260px;
  padding: 28px;
  box-sizing: border-box;
}

.project-modal__statements section + section {
  border-left: 1px solid var(--line-soft);
}

.project-modal__statements h3 {
  margin-top: 18px;
  font-size: 28px;
  font-weight: 500;
  line-height: 1.08;
}

.project-modal__outcome,
.project-modal__details {
  padding: 34px 28px;
  border-bottom: 1px solid var(--line-soft);
}

.project-modal__outcome > p:last-child {
  max-width: 720px;
  margin-top: 18px;
  font-size: 19px;
  line-height: 1.4;
}

.project-modal__details ul {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
  margin: 20px 0 0;
  padding: 0;
  border-top: 1px solid var(--line-soft);
}

.project-modal__details li {
  min-height: 72px;
  display: flex;
  align-items: center;
  padding: 14px 18px 14px 0;
  border-bottom: 1px solid var(--line-soft);
  color: rgba(0, 0, 0, 0.72);
  font-size: 13px;
  line-height: 1.35;
  list-style: none;
  box-sizing: border-box;
}

.project-modal__details li:nth-child(even) {
  padding-left: 18px;
  border-left: 1px solid var(--line-soft);
}

.project-modal__pager {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 28px 30px;
}

.project-modal__pager button {
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid rgba(0, 0, 0, 0.24);
  background: transparent;
  color: #000;
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}

.project-modal__pager button:hover,
.project-modal__pager button:focus-visible {
  background: #000;
  color: #fff;
  outline: none;
}

.resume-modal {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  padding: clamp(18px, 3vw, 46px);
  box-sizing: border-box;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.resume-modal.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.resume-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.42);
  backdrop-filter: blur(5px);
}

.resume-modal__panel {
  position: relative;
  width: min(860px, 100%);
  height: min(88vh, 900px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: #f7f7f3;
  border: 1px solid rgba(0, 0, 0, 0.24);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.28);
  transform: translateY(18px) scale(0.985);
}

.resume-modal.is-open .resume-modal__panel {
  transform: translateY(0) scale(1);
}

.resume-modal__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  padding: 16px 18px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.18);
}

.resume-modal__eyebrow,
.resume-modal__header h2 {
  margin: 0;
  color: var(--text-primary);
}

.resume-modal__eyebrow {
  font-family: "DM Mono", monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}

.resume-modal__header h2 {
  margin-top: 2px;
  font-size: var(--font-size-base);
  font-weight: 700;
}

.resume-modal__actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.resume-modal__download,
.resume-modal__close {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid rgba(0, 0, 0, 0.24);
  background: transparent;
  color: var(--text-primary);
  font: inherit;
  font-size: 13px;
  text-decoration: none;
  cursor: pointer;
}

.resume-modal__download:hover,
.resume-modal__close:hover {
  background: #000;
  color: #fff;
}

.resume-modal__frame {
  flex: 1;
  width: 100%;
  border: 0;
  background: #fff;
}

.triangle {
  width: 10px;
}

.sandbox-index-body .main-content {
  overflow-y: auto;
}

.sandbox-index-body.is-content-fullscreen .main-content {
  grid-column: 2;
}

.sandbox-hub-page {
  gap: clamp(18px, 3vw, 36px);
}

.sandbox-hub {
  width: min(100%, 1040px);
  display: grid;
  gap: clamp(22px, 4vw, 44px);
  margin-top: clamp(18px, 2vw, 24px);
  padding: clamp(22px, 5vw, 68px) clamp(18px, 4vw, 54px);
  padding-bottom: clamp(88px, 12vw, 150px);
  box-sizing: border-box;
}

.is-content-fullscreen .sandbox-hub {
  width: min(100%, 1240px);
  align-self: center;
  margin-top: 0;
  padding-top: clamp(30px, 4vw, 48px);
  padding-bottom: clamp(72px, 9vw, 128px);
}

.is-content-fullscreen .sandbox-hub-page {
  gap: 0;
}

.sandbox-hub__header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 24px;
  border-bottom: 1px solid var(--line-soft);
  padding-bottom: 18px;
}

.sandbox-hub__header h2,
.sandbox-hub__header p,
.sandbox-hub__header span {
  margin: 0;
  letter-spacing: 0;
}

.sandbox-hub__header h2,
.sandbox-hub__header span {
  color: var(--text-primary);
  font-size: var(--font-size-base);
  font-weight: 500;
}

.sandbox-hub__header p {
  max-width: 54ch;
  margin-top: 8px;
  color: rgba(0, 0, 0, 0.62);
  font-size: 13px;
  line-height: 1.38;
}

.sandbox-project-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(180px, 1fr));
  column-gap: clamp(22px, 3.6vw, 54px);
  row-gap: clamp(30px, 3vw, 38px);
  align-items: start;
}

.sandbox-project-card {
  display: grid;
  gap: 12px;
  color: var(--text-primary);
  text-align: left;
  text-decoration: none;
}

.sandbox-project-card:focus-visible {
  outline: none;
}

.sandbox-project-card__preview {
  position: relative;
  display: grid;
  width: 100%;
  aspect-ratio: 1.42;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(0, 0, 0, 0.055);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.28), transparent 42%),
    rgba(232, 232, 232, 0.72);
  transition:
    opacity 180ms ease,
    transform 220ms ease,
    border-color 220ms ease;
}

.sandbox-project-card:hover .sandbox-project-card__preview,
.sandbox-project-card:focus-visible .sandbox-project-card__preview {
  border-color: rgba(0, 0, 0, 0.16);
  opacity: 0.88;
  transform: translateY(-3px);
}

.sandbox-project-card__meta {
  display: grid;
  gap: 7px;
}

.sandbox-project-card__meta-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: baseline;
}

.sandbox-project-card__meta strong {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.18;
}

.sandbox-project-card__meta-head span {
  color: var(--text-muted);
  font-family: "DM Mono", monospace;
  font-size: 11px;
  line-height: 1.15;
  letter-spacing: 0;
  text-align: right;
  text-transform: uppercase;
  white-space: nowrap;
}

.sandbox-project-card__caption {
  max-width: 58ch;
  color: rgba(0, 0, 0, 0.62);
  font-size: 13px;
  line-height: 1.35;
}

.sandbox-preview-ink {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.sandbox-preview-ink .ink-symbiote {
  animation: sandbox-ink-float 8s ease-in-out infinite;
  pointer-events: none;
}

.sandbox-preview-ink .ink-symbiote-canvas {
  cursor: inherit;
  touch-action: auto;
}

@keyframes sandbox-ink-float {
  0%,
  100% {
    transform: translate3d(-2%, 3%, 0) rotate(-2deg);
  }

  35% {
    transform: translate3d(4%, -4%, 0) rotate(2deg);
  }

  70% {
    transform: translate3d(-3%, -1%, 0) rotate(-1deg);
  }
}

@media (prefers-reduced-motion: reduce) {
  .sandbox-preview-ink .ink-symbiote {
    animation: none;
  }
}

.sandbox-preview-poster {
  position: relative;
  display: block;
  width: min(62%, 260px);
  aspect-ratio: 1;
}

.sandbox-preview-poster {
  width: min(58%, 230px);
  border: 1px solid rgba(0, 0, 0, 0.13);
  background:
    radial-gradient(circle at 50% 40%, rgba(190, 170, 116, 0.58), transparent 30%),
    repeating-linear-gradient(90deg, rgba(0, 0, 0, 0.035) 0 1px, transparent 1px 7px),
    #f1efe3;
}

.sandbox-preview-poster span {
  position: absolute;
  display: block;
}

.sandbox-preview-poster span:nth-child(1) {
  left: 18%;
  top: 12%;
  width: 8px;
  height: 72%;
  background: rgba(0, 0, 0, 0.72);
}

.sandbox-preview-poster span:nth-child(2) {
  right: 18%;
  top: 12%;
  width: 8px;
  height: 64%;
  background: rgba(0, 0, 0, 0.72);
}

.sandbox-preview-poster span:nth-child(3) {
  left: 50%;
  top: 50%;
  width: 30%;
  height: 40%;
  border-radius: 48% 52% 56% 44% / 60% 42% 58% 40%;
  background: rgba(168, 143, 86, 0.72);
  filter: blur(1px);
  transform: translate(-50%, -36%);
}

.sandbox-preview-poster-image {
  display: block;
  width: min(72%, 300px);
  height: 88%;
  object-fit: contain;
  filter: contrast(1.04);
  mix-blend-mode: multiply;
}

.sandbox-body {
  min-height: 100vh;
  display: block;
  overflow: hidden;
  background: #efefea;
}

.sandbox-page {
  position: relative;
  width: 100vw;
  height: 100vh;
  min-height: 100vh;
  overflow: hidden;
  color: var(--text-primary);
}

.sandbox-track {
  display: flex;
  width: 200vw;
  height: 100%;
  will-change: transform;
  transition: transform 760ms cubic-bezier(0.77, 0, 0.175, 1);
}

.sandbox-installation {
  position: relative;
  flex: 0 0 100vw;
  width: 100vw;
  height: 100%;
  min-height: 520px;
  overflow: hidden;
  isolation: isolate;
}

.sandbox-visual {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 520px;
  overflow: hidden;
  isolation: isolate;
}

.hero-visual {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.hero-visual::before {
  content: "";
  position: absolute;
  inset: clamp(18px, 3vw, 44px);
  z-index: 1;
  border: 1px solid rgba(0, 0, 0, 0.14);
  pointer-events: none;
}

.ink-symbiote {
  position: absolute;
  inset: 0;
  z-index: 3;
  contain: layout paint;
  overflow: hidden;
}

.ink-symbiote-canvas {
  display: block;
  width: 100%;
  height: 100%;
  cursor: crosshair;
  touch-action: none;
}

.sandbox-back,
.sandbox-center-ink,
.sandbox-nav {
  position: fixed;
  z-index: 8;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  border: 1px solid rgba(0, 0, 0, 0.22);
  background: rgba(239, 239, 234, 0.72);
  color: var(--text-primary);
  font-family: "DM Mono", monospace;
  font-size: 12px;
  line-height: 1;
  text-decoration: none;
  backdrop-filter: blur(8px);
}

.sandbox-back,
.sandbox-center-ink {
  top: clamp(18px, 3vw, 34px);
  padding: 0 12px;
}

.sandbox-back {
  left: clamp(18px, 3vw, 34px);
}

.sandbox-center-ink {
  right: clamp(18px, 3vw, 34px);
  cursor: pointer;
  transition:
    opacity 180ms ease,
    visibility 180ms ease,
    background 160ms ease,
    color 160ms ease;
}

.sandbox-back:hover,
.sandbox-back:focus-visible,
.sandbox-center-ink:hover,
.sandbox-center-ink:focus-visible,
.sandbox-nav:hover,
.sandbox-nav:focus-visible {
  background: #000;
  color: #fff;
}

.sandbox-body[data-sandbox-slide="1"] .sandbox-center-ink {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.sandbox-nav {
  top: 68%;
  width: clamp(38px, 4.8vw, 54px);
  height: clamp(38px, 4.8vw, 54px);
  padding: 0;
  border-radius: 999px;
  cursor: pointer;
  font-size: clamp(18px, 2vw, 24px);
  transform: translateY(-50%);
  transition:
    opacity 180ms ease,
    background 160ms ease,
    color 160ms ease,
    transform 180ms ease;
}

.sandbox-nav--prev {
  left: clamp(16px, 2.6vw, 34px);
}

.sandbox-nav--next {
  right: clamp(16px, 2.6vw, 34px);
}

.sandbox-nav:disabled {
  opacity: 0;
  pointer-events: none;
}

.sandbox-installation--poster {
  background:
    radial-gradient(circle at 50% 12%, rgba(255, 255, 255, 0.65), transparent 34%),
    linear-gradient(106deg, rgba(0, 0, 0, 0.035), transparent 18% 82%, rgba(0, 0, 0, 0.04)),
    #f2f0e5;
}

.poster-installation {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 520px;
  overflow: hidden;
  color: #050505;
}

.poster-installation::before {
  content: "";
  position: absolute;
  inset: clamp(18px, 3vw, 44px);
  z-index: 1;
  border: 1px solid rgba(0, 0, 0, 0.13);
  pointer-events: none;
}

.poster-installation::after {
  content: "";
  position: absolute;
  inset: -10%;
  z-index: 2;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.055), transparent 12% 88%, rgba(0, 0, 0, 0.045)),
    radial-gradient(circle at 50% 48%, transparent 0 36%, rgba(255, 255, 255, 0.36) 58%, transparent 76%);
  mix-blend-mode: multiply;
}

.poster-grain {
  position: absolute;
  inset: -20%;
  z-index: 3;
  pointer-events: none;
  opacity: 0.42;
  background-image:
    radial-gradient(circle at 15% 22%, rgba(0, 0, 0, 0.12) 0 1px, transparent 1px),
    radial-gradient(circle at 68% 77%, rgba(255, 255, 255, 0.26) 0 1px, transparent 1px),
    repeating-linear-gradient(97deg, rgba(0, 0, 0, 0.035) 0 1px, transparent 1px 7px);
  background-size: 13px 17px, 19px 23px, 100% 100%;
  filter: blur(0.2px);
  animation: poster-grain-drift 11s steps(6) infinite;
}

.poster-sand-stage {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 4;
  width: min(68vw, 720px);
  height: min(88vh, 880px);
  transform: translate(-50%, -50%);
  filter: blur(0.85px) contrast(1.06);
  mix-blend-mode: multiply;
}

.poster-sand-stage::after {
  content: "";
  position: absolute;
  inset: 2% 3%;
  display: block;
  pointer-events: none;
  background:
    radial-gradient(circle at 50% 49%, rgba(240, 240, 226, 0.34), transparent 4%),
    linear-gradient(90deg, rgba(242, 240, 229, 0.18), transparent 10% 90%, rgba(242, 240, 229, 0.2));
  mix-blend-mode: screen;
}

.poster-sand-canvas {
  display: block;
  width: 100%;
  height: 100%;
  opacity: 0.96;
}

.poster-type {
  position: absolute;
  z-index: 5;
  margin: 0;
  font-family: "DM Mono", monospace;
  font-size: clamp(11px, 1vw, 15px);
  font-weight: 500;
  line-height: 1.58;
  letter-spacing: 0;
  writing-mode: vertical-rl;
  text-orientation: mixed;
}

.poster-type--left {
  left: clamp(28px, 3vw, 48px);
  top: clamp(78px, 10vh, 108px);
  font-size: clamp(18px, 2vw, 28px);
  line-height: 1.2;
}

.poster-type--right {
  right: clamp(28px, 3vw, 52px);
  top: clamp(34px, 4vh, 60px);
  font-size: clamp(17px, 2vw, 26px);
  line-height: 1.18;
}

.poster-type--lower-left {
  left: clamp(82px, 7.2vw, 118px);
  bottom: clamp(34px, 6vh, 86px);
  max-height: min(46vh, 470px);
}

.poster-type--lower-right {
  right: clamp(82px, 7.5vw, 128px);
  bottom: clamp(34px, 6vh, 84px);
  max-height: min(38vh, 390px);
}

@keyframes poster-sand-breathe {
  0%,
  100% {
    transform: translate(-50%, -48%) scale(1);
    filter: blur(0.25px) contrast(1.06);
  }

  50% {
    transform: translate(-50%, -48%) scale(1.012, 0.996);
    filter: blur(0.55px) contrast(1.02);
  }
}

@keyframes poster-grain-drift {
  0% {
    transform: translate3d(0, 0, 0);
  }

  100% {
    transform: translate3d(-3%, 2%, 0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .work-card--open-source-sj .work-card__preview {
    background: #E1F1F7;
    animation: none;
  }

  .code-rain-canvas {
    opacity: 0.2;
  }

  .open-source-sj-thumb,
  .open-source-sj-preview,
  .rainbow-thumb__tile,
  .rainbow-thumb__word span {
    opacity: 1;
    transform: none;
    animation: none;
  }

  .project-modal,
  .project-modal__panel {
    transition: none;
  }

  .case-study-reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .sandbox-track {
    transition: none;
  }

  .poster-grain,
  .poster-sand-stage {
    animation: none;
  }
}

@media (max-width: 900px) {
  html,
  body {
    height: auto;
    overflow: auto;
  }

  body {
    min-height: 100vh;
    display: block;
  }

  body.is-project-open {
    overflow: hidden;
  }

  .main-navigation {
    display: flex;
    flex-basis: auto;
    width: 100%;
    height: auto;
    min-height: auto;
    padding: 36px 24px 22px;
    border-right: 0;
    border-bottom: 1px solid hsla(0, 0%, 7%, .2);
  }

  .fullscreen-toggle,
  .content-nav {
    display: none;
  }

  nav.main-navigation ul.nav-links {
    padding-top: 28px;
  }

  .main-content {
    height: auto;
    min-height: 78vh;
    padding: 24px;
  }

  .site-header {
    min-height: 0;
    grid-template-columns: minmax(0, 1fr);
    align-items: start;
    gap: 18px;
    padding: 20px 24px 16px;
  }

  .site-header__nav {
    justify-content: flex-start;
    gap: 18px;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    padding-bottom: 4px;
    scrollbar-width: none;
  }

  .site-header__nav::-webkit-scrollbar {
    display: none;
  }

  .is-content-fullscreen .site-header {
    width: calc(100% + 48px);
    margin-top: -24px;
    margin-left: -24px;
  }

  .is-content-fullscreen .main-navigation {
    display: flex;
  }

  .locked-content-fullscreen .main-navigation {
    width: 100%;
    height: auto;
    min-height: auto;
    padding: 36px 24px 22px;
    border-right: 0;
    border-bottom: 1px solid hsla(0, 0%, 7%, .2);
    pointer-events: auto;
    transform: none;
    visibility: visible;
  }

  .locked-content-fullscreen .main-navigation > header,
  .locked-content-fullscreen .main-navigation footer {
    opacity: 1;
    transform: none;
  }

  .is-content-fullscreen .main-content {
    width: auto;
    padding: 24px;
  }

  .sandbox-index-body .headerright-section {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    gap: 16px;
  }

  .sandbox-index-body .headerright-section > span[aria-hidden="true"] {
    display: none;
  }

  .sandbox-index-body .content-nav {
    display: flex;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 12px 18px;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: none;
  }

  .music-body .main-content {
    overflow-y: visible;
  }

  .design-system-body .main-content {
    overflow-y: visible;
  }

  .work-gallery {
    grid-template-columns: 1fr;
    padding: 34px 0 86px;
  }

  .work-grid {
    grid-template-columns: 1fr;
    gap: 26px;
  }

  .work-card__meta {
    gap: 6px;
  }

  .work-card__meta-head {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .work-card__tags {
    text-align: left;
    white-space: normal;
  }

  .work-card__caption {
    max-width: none;
  }

  .music-gallery {
    padding: 34px 0;
  }

  .music-shelf__scene {
    min-height: 260px;
    height: clamp(270px, 74vw, 360px);
  }

  .music-shelf__cases {
    right: 8%;
    bottom: 28%;
    left: 8%;
    gap: 10px;
  }

  .shelf-cd {
    width: min(100%, 94px);
  }

  .music-shelf-player__top {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  .music-shelf-player {
    margin-bottom: -10px;
  }

  .music-shelf-player iframe {
    height: 152px;
  }

  .system-gallery {
    padding: 34px 0;
  }

  .music-gallery__header,
  .system-gallery__header,
  .system-section__top,
  .listening-board__top {
    align-items: flex-start;
    flex-direction: column;
  }

  .top-tracks__list {
    grid-auto-flow: row;
    grid-template-columns: 1fr;
    grid-template-rows: none;
    column-gap: 0;
  }

  .top-track {
    grid-template-columns: 32px 64px minmax(0, 1fr);
    gap: 12px;
    min-height: 96px;
  }

  .top-track__artwork-button {
    width: 64px;
  }

  .system-section__top p {
    text-align: left;
  }

  .token-grid,
  .component-grid,
  .system-notes {
    grid-template-columns: 1fr;
  }

  .case-study-sample {
    grid-template-columns: 1fr;
  }

  .case-study-sample aside {
    border-right: 0;
    border-bottom: 1px solid var(--line-soft);
  }

  .case-study-body {
    min-height: 100vh;
    display: block;
    overflow: auto;
  }

  .case-study-nav {
    grid-template-columns: 1fr;
    gap: 18px;
    overflow-x: auto;
    padding: 18px 24px;
  }

  .case-study-nav__slot,
  .case-study-nav > .triangle {
    display: none;
  }

  .case-study-nav__links {
    justify-content: flex-start;
    min-width: max-content;
  }

  .case-study-page {
    width: min(100% - 36px, 100%);
    padding: 34px 0 72px;
  }

  .case-study-hero,
  .case-study-section--split,
  .case-study-problem-grid,
  .case-study-iteration-layout,
  .case-study-media-grid--two,
  .case-study-media-grid--balanced,
  .case-study-media-grid--three,
  .case-study-media-grid--four,
  .case-study-flow-layout,
  .case-study-feature-grid,
  .case-study-list--columns {
    grid-template-columns: 1fr;
  }

  .case-study-hero {
    gap: 34px;
  }

  .case-study-hero__meta {
    position: static;
    order: 2;
  }

  .case-study-hero__intro h1 {
    font-size: clamp(34px, 11vw, 48px);
  }

  .case-study-hero__intro > p {
    font-size: 17px;
  }

  .case-study-section h2 {
    font-size: 17px;
  }

  .case-study-scroll-frame,
  .case-study-phone-frame {
    max-height: 560px;
  }

  .case-study-placeholder,
  .case-study-feature-grid article {
    min-height: 220px;
  }

  .album-grid {
    grid-template-columns: 1fr;
  }

  .album-card {
    grid-template-columns: minmax(96px, 34%) minmax(0, 1fr);
    align-items: end;
  }

  .track-list li {
    grid-template-columns: 34px minmax(0, 1fr);
    gap: 12px;
    padding: 16px 0;
  }

  .track-list em {
    grid-column: 2;
  }

  .project-modal {
    place-items: stretch;
    padding: 0;
  }

  .project-modal__panel {
    width: 100%;
    height: 100dvh;
    max-height: none;
    overflow-y: auto;
    border: 0;
    border-radius: 0;
  }

  .project-modal__topbar {
    position: sticky;
    top: 0;
    z-index: 2;
  }

  .project-modal__layout {
    display: block;
  }

  .project-modal__rail {
    padding: 28px 24px 24px;
    border-right: 0;
    border-bottom: 1px solid var(--line-soft);
  }

  .project-modal__rail h2 {
    font-size: 32px;
  }

  .project-modal__links {
    margin-top: 24px;
    padding-top: 0;
  }

  .project-modal__story {
    overflow: visible;
  }

  .project-modal__hero {
    aspect-ratio: 1 / 0.78;
  }

  .project-modal__statements {
    grid-template-columns: 1fr;
  }

  .project-modal__statements section {
    min-height: 0;
    padding: 26px 24px 32px;
  }

  .project-modal__statements section + section {
    border-top: 1px solid var(--line-soft);
    border-left: 0;
  }

  .project-modal__statements h3 {
    font-size: 22px;
  }

  .project-modal__outcome,
  .project-modal__details {
    padding: 30px 24px;
  }

  .project-modal__outcome > p:last-child {
    font-size: 17px;
  }

  .project-modal__details ul {
    grid-template-columns: 1fr;
  }

  .project-modal__details li:nth-child(even) {
    padding-left: 0;
    border-left: 0;
  }

  .project-modal__pager {
    padding: 20px 24px 34px;
  }

  .resume-modal {
    padding: 14px;
  }

  .resume-modal__panel {
    height: 86vh;
  }

  .resume-modal__header {
    flex-direction: column;
    gap: 12px;
  }

  .resume-modal__actions {
    width: 100%;
  }

  .resume-modal__download,
  .resume-modal__close {
    flex: 1;
    justify-content: center;
  }

  .sandbox-hub {
    padding: 34px 0 72px;
  }

  .sandbox-hub__header {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }

  .sandbox-project-grid {
    grid-template-columns: 1fr;
  }

  .sandbox-project-card__meta-head {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .sandbox-project-card__meta-head span {
    text-align: left;
    white-space: normal;
  }

  .sandbox-project-card__caption {
    max-width: none;
  }

  .sandbox-body {
    height: 100vh;
    overflow: hidden;
  }

  .sandbox-page {
    height: 100vh;
  }

  .sandbox-track,
  .sandbox-installation,
  .sandbox-visual {
    min-height: 100vh;
  }

  .hero-visual::before {
    inset: 14px;
  }

  .sandbox-back,
  .sandbox-center-ink {
    top: 14px;
    min-height: 30px;
    padding: 0 10px;
  }

  .sandbox-back {
    left: 14px;
  }

  .sandbox-center-ink {
    right: 14px;
  }

  .sandbox-nav {
    width: 38px;
    height: 38px;
  }

  .sandbox-nav--prev {
    left: 12px;
  }

  .sandbox-nav--next {
    right: 12px;
  }

  .poster-installation::before {
    inset: 14px;
  }

  .poster-sand-stage {
    width: 92vw;
    height: 74vh;
    transform: translate(-50%, -48%);
  }

  .poster-type {
    font-size: 10px;
    line-height: 1.42;
  }

  .poster-type--left {
    left: 20px;
    top: 72px;
    font-size: 16px;
  }

  .poster-type--right {
    right: 22px;
    top: 62px;
    font-size: 15px;
  }

  .poster-type--lower-left {
    left: 58px;
    bottom: 24px;
    max-height: 34vh;
  }

  .poster-type--lower-right {
    right: 22px;
    bottom: 24px;
    max-height: 30vh;
  }
}

/* Work homepage: always-full-width editorial layout. */
body.work-body {
  min-height: 100%;
  display: block;
  overflow-x: hidden;
  overflow-y: auto;
  transition: none;
}

.work-body .main-content {
  width: 100%;
  height: auto;
  min-height: 100vh;
  overflow: visible;
  display: block;
  padding: 0;
}

.portfolio-header {
  width: 100%;
  border-bottom: 1px solid var(--line-soft);
}

.portfolio-header__inner {
  width: min(100%, 1480px);
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  margin: 0 auto;
  padding: 0 clamp(24px, 4vw, 64px);
  box-sizing: border-box;
}

.portfolio-brand {
  flex: 0 0 auto;
  color: var(--text-primary);
  font-size: 14px;
  line-height: 1;
  text-decoration: none;
}

.portfolio-brand strong {
  font-weight: 600;
}

.portfolio-header__nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: clamp(18px, 2.4vw, 34px);
  min-width: 0;
}

.portfolio-header__nav .nav-link-fx {
  font-size: 13px;
}

.portfolio-intro {
  width: min(100% - 48px, 760px);
  display: grid;
  justify-items: center;
  gap: 16px;
  margin: 0 auto;
  padding: 44px 0 30px;
  text-align: center;
}

.portfolio-intro__face.name-face-button {
  width: 52px;
  height: 52px;
}

.portfolio-intro__face .name-face {
  width: 46px;
}

.portfolio-intro__face.name-face-button.is-reacting .name-face {
  width: 50px;
}

.face-discovery {
  margin: -6px 0 -4px;
  opacity: 0;
  font-family: "DM Mono", monospace;
  font-size: 10px;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  transform: translateY(-3px);
  transition: opacity 180ms ease, transform 180ms ease;
}

.face-discovery.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.face-discovery a {
  color: var(--text-muted);
  text-underline-offset: 3px;
}

.face-discovery a:hover,
.face-discovery a:focus-visible {
  color: var(--text-primary);
}

.system-version {
  appearance: none;
  padding: 2px 0;
  border: 0;
  border-bottom: 1px solid transparent;
  background: transparent;
  color: var(--text-primary);
  font-family: "DM Mono", monospace;
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
}

.system-version:hover,
.system-version:focus-visible,
.system-version[aria-expanded="true"] {
  border-bottom-color: currentColor;
  outline: none;
}

.system-xray {
  display: grid;
  gap: 24px;
  margin-top: calc(-1 * clamp(14px, 2vw, 24px));
  padding: clamp(18px, 2.5vw, 28px);
  border: 1px solid var(--line-soft);
  background: rgba(255, 255, 255, 0.38);
}

.system-xray[hidden] {
  display: none;
}

.system-xray__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
}

.system-xray__header > div {
  display: grid;
  gap: 8px;
}

.system-xray__header h3 {
  margin: 0;
  color: var(--text-primary);
  font-size: 18px;
  font-weight: 500;
}

.system-xray__close {
  appearance: none;
  padding: 0 0 3px;
  border: 0;
  border-bottom: 1px solid currentColor;
  background: transparent;
  color: var(--text-muted);
  font-family: "DM Mono", monospace;
  font-size: 10px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
}

.system-xray__close:hover,
.system-xray__close:focus-visible {
  color: var(--text-primary);
  outline: none;
}

.system-xray__tokens {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px 28px;
  margin: 0;
}

.system-xray__tokens div {
  display: grid;
  gap: 7px;
  min-width: 0;
  border-top: 1px solid var(--line-soft);
  padding-top: 10px;
}

.system-xray__tokens dt,
.system-xray__tokens dd {
  margin: 0;
}

.system-xray__tokens dt {
  color: var(--text-muted);
  font-family: "DM Mono", monospace;
  font-size: 9px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.system-xray__tokens dd {
  overflow-wrap: anywhere;
  color: var(--text-primary);
  font-size: 13px;
}

.error-body {
  min-height: 100vh;
  display: block;
  overflow-x: hidden;
  overflow-y: auto;
}

.error-body .main-content {
  width: 100%;
  min-height: 100vh;
  height: auto;
  display: block;
  overflow: visible;
  transform: none;
}

.error-page {
  width: min(100% - (2 * var(--site-page-gutter)), 760px);
  min-height: calc(100vh - 69px);
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  align-content: center;
  gap: 24px 30px;
  margin: 0 auto;
  padding: 64px 0 96px;
  box-sizing: border-box;
}

.error-page__face.name-face-button {
  width: 64px;
  height: 64px;
  align-self: start;
}

.error-page__face .name-face {
  width: 56px;
}

.error-page__face.name-face-button.is-reacting .name-face {
  width: 60px;
}

.error-page__copy {
  display: grid;
  gap: 16px;
}

.error-page__label,
.error-page__path {
  margin: 0;
  color: var(--text-muted);
  font-family: "DM Mono", monospace;
  font-size: 10px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.error-page h1,
.error-page p {
  margin: 0;
}

.error-page h1 {
  color: var(--text-primary);
  font-size: clamp(34px, 7vw, 74px);
  font-weight: 500;
  line-height: 0.94;
}

.error-page__message {
  max-width: 520px;
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.5;
}

.error-page__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 22px;
  margin-top: 8px;
}

.error-page__actions a {
  color: var(--text-primary);
  font-size: 13px;
  text-underline-offset: 4px;
}

@media (max-width: 700px) {
  .system-xray__tokens {
    grid-template-columns: 1fr 1fr;
  }

  .error-page {
    grid-template-columns: 1fr;
    align-content: start;
    padding-top: 72px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .face-discovery {
    transition: none;
  }
}

.portfolio-intro h1 {
  max-width: 720px;
  margin: 0;
  color: var(--text-primary);
  font-size: 21px;
  font-weight: 400;
  line-height: 1.28;
  letter-spacing: 0;
  text-wrap: balance;
}

.portfolio-intro__contact {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 6px 9px;
  margin: 0;
  color: var(--text-muted);
  font-family: "DM Mono", monospace;
  font-size: 10px;
  line-height: 1.4;
  letter-spacing: 0;
  text-transform: uppercase;
}

.portfolio-intro__contact a {
  color: inherit;
  text-underline-offset: 3px;
}

.work-body .work-gallery {
  width: min(100%, 1480px);
  min-height: 0;
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 26px;
  align-content: start;
  margin: 0 auto;
  padding: 0 var(--site-page-gutter) 112px;
  box-sizing: border-box;
}

.work-filter {
  display: flex;
  align-items: flex-end;
  gap: 34px;
  border-bottom: 1px solid var(--line-soft);
}

.work-filter__tab {
  position: relative;
  appearance: none;
  min-height: 44px;
  padding: 0 0 12px;
  border: 0;
  background: transparent;
  color: var(--text-muted);
  font-family: "Space Grotesk", sans-serif;
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0;
  cursor: pointer;
}

.work-filter__tab::after {
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 1px;
  content: "";
  background: transparent;
}

.work-filter__tab:hover,
.work-filter__tab:focus-visible,
.work-filter__tab.is-active {
  color: var(--text-primary);
}

.work-filter__tab:focus-visible {
  outline: 1px solid currentColor;
  outline-offset: 4px;
}

.work-filter__tab.is-active::after {
  background: currentColor;
}

.work-body .work-grid,
.work-body.is-content-fullscreen .work-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 28px;
  row-gap: 36px;
}

.work-card.is-filtered-out {
  display: none;
}

.work-body .work-card {
  gap: 10px;
}

.work-body .work-card__preview {
  aspect-ratio: 1.48;
}

.work-body .work-card:hover .work-card__preview,
.work-body .work-card:focus-visible .work-card__preview {
  border-color: rgba(0, 0, 0, 0.18);
  opacity: 0.96;
  transform: none;
}

.work-body .work-card__meta {
  gap: 6px;
}

.work-body .work-card__meta strong {
  font-size: 14px;
}

.work-body .work-card__caption {
  max-width: 72ch;
  font-size: 13px;
  line-height: 1.38;
}

@media (max-width: 900px) {
  body.work-body {
    min-height: 100vh;
  }

  .work-body .main-content,
  .work-body.is-content-fullscreen .main-content {
    width: 100%;
    min-height: 100vh;
    padding: 0;
  }

  .portfolio-header__inner {
    min-height: 0;
    align-items: flex-start;
    flex-direction: column;
    gap: 20px;
    padding: 24px;
  }

  .portfolio-header__nav {
    width: 100%;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 14px 24px;
  }

  .portfolio-intro {
    width: min(100% - 48px, 680px);
    padding: 42px 0 30px;
  }

  .portfolio-intro h1 {
    font-size: 19px;
  }

  .work-body .work-gallery,
  .work-body.is-content-fullscreen .work-gallery {
    width: 100%;
    padding: 0 24px 84px;
  }

  .work-body .work-grid,
  .work-body.is-content-fullscreen .work-grid {
    column-gap: 22px;
    row-gap: 30px;
  }

}

@media (max-width: 700px) {
  .work-body .work-grid,
  .work-body.is-content-fullscreen .work-grid {
    grid-template-columns: 1fr;
    justify-items: center;
  }

  .work-body .work-card {
    width: min(100%, 620px);
  }

  .work-body .work-card__preview {
    aspect-ratio: 1.48;
  }
}

@media (max-width: 520px) {
  .site-header__nav {
    gap: 16px;
  }

  .site-header__nav .nav-link-fx {
    font-size: 12px;
  }

  .portfolio-header__inner {
    padding: 22px 18px;
  }

  .portfolio-header__nav {
    gap: 12px 18px;
  }

  .portfolio-header__nav .nav-link-fx {
    font-size: 12px;
  }

  .portfolio-intro {
    width: calc(100% - 36px);
    gap: 14px;
    padding: 34px 0 26px;
  }

  .portfolio-intro h1 {
    font-size: 18px;
    line-height: 1.3;
  }

  .portfolio-intro__contact {
    max-width: 320px;
    font-size: 9px;
  }

  .work-body .work-gallery,
  .work-body.is-content-fullscreen .work-gallery {
    padding-right: var(--site-page-gutter);
    padding-left: var(--site-page-gutter);
  }

  .work-filter {
    gap: 26px;
  }

  .work-body .work-card__meta-head {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .work-body .work-card__tags {
    text-align: left;
    white-space: normal;
  }
}
