@import url("https://fonts.googleapis.com/css2?family=Instrument+Sans:ital,wght@0,400;0,500;1,400&display=swap");

:root {
  --paper: #f7f7f4;
  --ink: #11110f;
  --muted: #96968f;
  --line: #d7d7d0;
  --gutter: clamp(20px, 2.6vw, 42px);
  --font: "Instrument Sans", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

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

html {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--paper);
  color: var(--ink);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
}

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

button {
  color: inherit;
  font: inherit;
}

.skip-link {
  position: fixed;
  z-index: 100;
  left: var(--gutter);
  top: 0;
  padding: 8px 12px;
  background: var(--ink);
  color: var(--paper);
  transform: translateY(-110%);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  position: fixed;
  z-index: 20;
  top: 0;
  left: 0;
  display: flex;
  width: 100%;
  align-items: flex-start;
  justify-content: space-between;
  padding: 25px var(--gutter);
  pointer-events: none;
  mix-blend-mode: normal;
}

.site-header a,
.site-header button {
  pointer-events: auto;
}

.site-name {
  font-size: clamp(18px, 1.7vw, 25px);
  font-weight: 500;
  letter-spacing: -0.025em;
  line-height: 1;
}

.language-switcher {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  letter-spacing: 0.02em;
}

.language-switcher button {
  border: 0;
  padding: 0;
  background: none;
  cursor: pointer;
  opacity: 0.35;
}

.language-switcher button[aria-pressed="true"] {
  opacity: 1;
}

#app {
  min-height: 100vh;
}

.directory {
  display: grid;
  min-height: 100vh;
  grid-template-columns: 1.45fr 1fr 0.85fr;
  gap: clamp(28px, 5vw, 90px);
  align-content: center;
  padding: 19vh var(--gutter) 16vh;
}

.directory.has-inline-video {
  align-content: start;
}

.directory-label,
.eyebrow {
  margin: 0 0 26px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1;
  letter-spacing: 0.04em;
}

.directory ul,
.external-links,
.index-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.directory li {
  margin: 0;
}

.directory li > .work-row {
  display: flex;
  width: fit-content;
  align-items: baseline;
  gap: 12px;
  border: 0;
  padding: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-size: clamp(24px, 2.75vw, 44px);
  letter-spacing: -0.045em;
  line-height: 1.08;
  text-align: left;
  transition: opacity 180ms ease;
}

.directory li > .work-row small {
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 0;
}

.directory li > .work-row:hover,
.directory li > .work-row:focus-visible,
.index-list a:hover,
.external-links a:hover,
.text-link:hover {
  opacity: 0.38;
}

.inline-video-panel {
  position: relative;
  z-index: 2;
  width: calc(100vw - (2 * var(--gutter)));
  margin: 22px 0 38px;
  background: var(--paper);
}

.inline-video-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--ink);
}

.inline-video-frame iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}

.inline-video-sound {
  position: absolute;
  right: 12px;
  bottom: 12px;
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 1px solid rgb(255 255 255 / 70%);
  border-radius: 50%;
  background: rgb(17 17 15 / 55%);
  color: #fff;
  cursor: pointer;
}

.inline-video-sound svg {
  width: 19px;
  height: 19px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.5;
}

.inline-video-sound svg path:first-child {
  fill: currentColor;
  stroke: none;
}

.inline-video-sound[aria-pressed="false"] .sound-waves,
.inline-video-sound[aria-pressed="true"] .mute-mark {
  display: none;
}

.inline-video-info {
  display: grid;
  grid-template-columns: minmax(150px, 0.8fr) minmax(260px, 1.7fr);
  gap: clamp(30px, 6vw, 90px);
  margin-top: 28px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

.inline-video-info-label h3 {
  margin: 0 0 6px;
  font-size: 16px;
  font-weight: 500;
}

.inline-video-info-label p {
  margin: 0;
  color: var(--muted);
  font-size: 10px;
}

.inline-video-copy {
  font-size: clamp(15px, 1.35vw, 19px);
  line-height: 1.44;
  letter-spacing: -0.015em;
}

.inline-video-copy p {
  margin: 0 0 0.85em;
}

.inline-video-copy p:last-child {
  margin-bottom: 0;
}

.home-footer {
  position: absolute;
  bottom: 25px;
  left: 0;
  display: flex;
  width: 100%;
  justify-content: space-between;
  padding: 0 var(--gutter);
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 0.03em;
}

.project-page {
  padding: 122px var(--gutter) 36px;
}

.project-heading {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  min-height: 29vh;
  padding-bottom: 32px;
}

.project-heading h1,
.info-page h1 {
  margin: 0;
  font-size: clamp(42px, 7.4vw, 122px);
  font-weight: 400;
  letter-spacing: -0.065em;
  line-height: 0.88;
}

.project-year {
  margin: 0 0 4px;
  color: var(--muted);
  font-size: 13px;
}

.gallery {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: clamp(26px, 7vw, 120px) clamp(16px, 2.8vw, 48px);
  padding: 10vh 0 18vh;
  border-top: 1px solid var(--line);
}

.gallery figure {
  margin: 0;
}

.gallery-image-button {
  display: block;
  width: 100%;
  margin: 0;
  border: 0;
  padding: 0;
  background: transparent;
  cursor: zoom-in;
}

.gallery figure:nth-child(5n + 1) {
  grid-column: 3 / span 8;
}

.gallery figure:nth-child(5n + 2) {
  grid-column: 1 / span 5;
}

.gallery figure:nth-child(5n + 3) {
  grid-column: 7 / span 6;
}

.gallery figure:nth-child(5n + 4) {
  grid-column: 2 / span 4;
}

.gallery figure:nth-child(5n + 5) {
  grid-column: 6 / span 7;
}

.gallery img {
  display: block;
  width: 100%;
  height: auto;
  background: #ecece7;
}

.project-video {
  padding: 10vh 0 18vh;
  border-top: 1px solid var(--line);
}

.project-page-video .project-video {
  margin-inline: calc(-1 * var(--gutter));
  padding-top: 0;
  border-top: 0;
}

.video-frame {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: var(--ink);
}

.video-frame iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}

@media (min-width: 761px) {
  .directory.has-inline-video .directory-column:not(.directory-works) {
    visibility: hidden;
  }
}

.collaboration-page {
  min-height: 100vh;
  padding: 118px var(--gutter) 46px;
}

.collaboration-page > .eyebrow {
  margin-bottom: 24px;
}

.collaboration-grid {
  display: flex;
  align-items: flex-start;
}

.collaboration-grid-column {
  width: calc(100% / 3);
  min-width: 0;
}

.collaboration-card {
  position: relative;
  display: block;
  width: 100%;
  min-width: 0;
  overflow: hidden;
  border: 0;
  padding: 0;
  background: #dadad4;
  break-inside: avoid;
  cursor: pointer;
  text-align: left;
  vertical-align: top;
}

.collaboration-card-media {
  display: block;
  width: 100%;
  overflow: hidden;
}

.collaboration-card img {
  display: block;
  width: 100%;
  height: auto;
  transition: filter 220ms ease, transform 420ms ease;
}

.collaboration-card-media-cropped img {
  height: 100%;
  object-fit: cover;
  object-position: var(--crop-position, center);
}

.collaboration-card-title {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-end;
  gap: 7px;
  padding: 18px;
  background: linear-gradient(to top, rgb(0 0 0 / 72%), transparent 58%);
  color: #fff;
  font-size: clamp(17px, 1.65vw, 28px);
  letter-spacing: -0.035em;
  line-height: 1.02;
  opacity: 0;
  transition: opacity 180ms ease;
}

.collaboration-card-title strong {
  font: inherit;
  font-weight: 400;
}

.collaboration-card-title small {
  max-width: 34em;
  font-size: 11px;
  letter-spacing: 0;
  line-height: 1.25;
  opacity: 0.78;
}

.collaboration-card:hover img,
.collaboration-card:focus-visible img {
  filter: brightness(0.66);
  transform: scale(1.015);
}

.collaboration-card:hover .collaboration-card-title,
.collaboration-card:focus-visible .collaboration-card-title {
  opacity: 1;
}

.collaboration-card-static {
  cursor: default;
}

.video-dialog {
  width: min(1120px, calc(100vw - (2 * var(--gutter))));
  max-width: none;
  margin: auto;
  border: 0;
  padding: 0;
  overflow: visible;
  background: transparent;
  color: #fff;
}

.video-dialog::backdrop {
  background: rgb(17 17 15 / 92%);
}

.video-dialog-frame {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.video-dialog-frame iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}

.video-dialog-title {
  margin: 12px 0 0;
  font-size: 13px;
}

.video-dialog-close {
  position: fixed;
  z-index: 2;
  top: 22px;
  right: 22px;
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid rgb(255 255 255 / 75%);
  border-radius: 50%;
  background: rgb(17 17 15 / 30%);
  color: #fff;
  cursor: pointer;
  font-size: 28px;
  font-weight: 300;
  line-height: 1;
}

.lightbox {
  width: 100vw;
  max-width: none;
  height: 100dvh;
  max-height: none;
  margin: 0;
  border: 0;
  padding: 34px clamp(72px, 8vw, 132px) 28px;
  overflow: hidden;
  background: transparent;
  color: #fff;
}

.lightbox::backdrop {
  background: rgb(17 17 15 / 86%);
  backdrop-filter: blur(1.5px);
}

.lightbox-figure {
  display: grid;
  width: 100%;
  height: 100%;
  grid-template-rows: minmax(0, 1fr) auto;
  gap: 12px;
  margin: 0;
}

.lightbox-image {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: contain;
}

.lightbox-caption {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  font-size: 12px;
  line-height: 1.2;
}

.lightbox-counter {
  color: rgb(255 255 255 / 70%);
  font-variant-numeric: tabular-nums;
}

.lightbox-close,
.lightbox-arrow {
  position: fixed;
  z-index: 2;
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid rgb(255 255 255 / 75%);
  border-radius: 50%;
  background: rgb(17 17 15 / 22%);
  color: #fff;
  cursor: pointer;
  font-size: 22px;
  line-height: 1;
}

.lightbox-close {
  top: 24px;
  right: 24px;
  font-size: 28px;
  font-weight: 300;
}

.lightbox-previous,
.lightbox-next {
  top: 50%;
  transform: translateY(-50%);
}

.lightbox-previous {
  left: 20px;
}

.lightbox-next {
  right: 20px;
}

.lightbox-close:hover,
.lightbox-arrow:hover,
.lightbox-close:focus-visible,
.lightbox-arrow:focus-visible {
  background: #fff;
  color: var(--ink);
}

.gallery-paciente figure:nth-child(5n + 1) {
  grid-column: 2 / span 10;
}

.gallery-paciente figure:nth-child(5n + 2) {
  grid-column: 1 / span 7;
}

.gallery-paciente figure:nth-child(5n + 3) {
  grid-column: 6 / span 7;
}

.project-text {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(280px, 2fr);
  gap: clamp(40px, 10vw, 160px);
  padding: 11vh 0 16vh;
  border-top: 1px solid var(--line);
}

.project-text-label h2 {
  margin: 0 0 6px;
  font-size: 18px;
  font-weight: 500;
}

.project-text-label p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.project-copy,
.long-copy {
  max-width: 760px;
  font-size: clamp(18px, 1.55vw, 25px);
  line-height: 1.4;
  letter-spacing: -0.02em;
}

.project-copy p,
.long-copy p {
  margin: 0 0 1.2em;
}

.project-copy h3,
.inline-video-copy h3 {
  margin: 0 0 1.2em;
  font: inherit;
  font-weight: 500;
}

.project-copy strong,
.inline-video-copy strong {
  font-weight: 500;
}

.project-link {
  border-bottom: 1px solid currentColor;
  transition: opacity 180ms ease;
}

.project-link:hover,
.project-link:focus-visible {
  opacity: 0.42;
}

.project-copy ul,
.inline-video-copy ul {
  margin: 0 0 1.2em;
  padding: 0;
  list-style: none;
}

.project-copy li,
.inline-video-copy li {
  position: relative;
  margin: 0 0 0.45em;
  padding-left: 1em;
}

.project-copy li::before,
.inline-video-copy li::before {
  position: absolute;
  left: 0;
  content: "–";
}

.project-copy p:last-child,
.long-copy p:last-child {
  margin-bottom: 0;
}

.project-navigation {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1px solid var(--line);
}

.project-navigation a {
  display: flex;
  min-height: 130px;
  flex-direction: column;
  justify-content: space-between;
  padding: 22px 0;
  transition: opacity 180ms ease;
}

.project-navigation a:last-child {
  align-items: flex-end;
  border-left: 1px solid var(--line);
  padding-left: var(--gutter);
  text-align: right;
}

.project-navigation a:hover {
  opacity: 0.38;
}

.project-navigation small {
  color: var(--muted);
  font-size: 10px;
  text-transform: uppercase;
}

.project-navigation span {
  font-size: clamp(20px, 2.2vw, 34px);
  letter-spacing: -0.04em;
}

.info-page {
  min-height: 100vh;
  padding: 28vh var(--gutter) 12vh;
}

.info-page > .eyebrow {
  margin-bottom: 28px;
}

.bio-grid {
  display: grid;
  grid-template-columns: minmax(230px, 0.75fr) minmax(300px, 1.5fr);
  gap: clamp(40px, 9vw, 150px);
  align-items: start;
  margin-top: 13vh;
  padding-top: 36px;
  border-top: 1px solid var(--line);
}

.bio-grid img {
  display: block;
  width: 100%;
  max-width: 520px;
}

.bio-cv {
  margin-top: 18vh;
}

.cv-section {
  display: grid;
  grid-template-columns: minmax(180px, 0.75fr) minmax(300px, 1.5fr);
  gap: clamp(40px, 9vw, 150px);
  padding: 30px 0 13vh;
  border-top: 1px solid var(--line);
}

.cv-section h2 {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.04em;
  line-height: 1.2;
  text-transform: uppercase;
}

.cv-entry {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  gap: 18px;
  padding-bottom: 30px;
}

.cv-entry:last-child {
  padding-bottom: 0;
}

.cv-year {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.48;
}

.cv-items p {
  max-width: 860px;
  margin: 0 0 9px;
  font-size: clamp(15px, 1.15vw, 18px);
  letter-spacing: -0.01em;
  line-height: 1.48;
}

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

.text-link {
  display: inline-block;
  border-bottom: 1px solid currentColor;
  font-size: 13px;
  letter-spacing: 0.02em;
  transition: opacity 180ms ease;
}

.contact-details {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 18px;
}

.contact-email,
.contact-phone {
  display: inline-block;
  margin-top: 0;
  font-size: clamp(22px, 3.5vw, 54px);
  letter-spacing: -0.055em;
  line-height: 1;
  border-bottom: 0.04em solid currentColor;
}

.external-links {
  display: flex;
  gap: 28px;
  margin-top: 44px;
  color: var(--muted);
  font-size: 13px;
}

.index-list {
  margin-top: 13vh;
  border-top: 1px solid var(--line);
}

.index-list a {
  display: flex;
  justify-content: space-between;
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
  font-size: clamp(24px, 4vw, 62px);
  letter-spacing: -0.05em;
  transition: opacity 180ms ease;
}

.blog-entry {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(280px, 2fr);
  gap: clamp(40px, 10vw, 160px);
  margin-top: 13vh;
  padding-top: 36px;
  border-top: 1px solid var(--line);
}

.blog-entry-heading p {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 12px;
}

.blog-entry-heading h2 {
  margin: 0;
  font-size: clamp(24px, 3.2vw, 50px);
  font-weight: 400;
  letter-spacing: -0.045em;
  line-height: 1;
}

.pending-page > p:last-child {
  margin-top: 13vh;
  color: var(--muted);
  font-size: 13px;
}

@media (max-width: 760px) {
  .site-header {
    padding-top: 20px;
  }

  .directory {
    min-height: auto;
    grid-template-columns: 1fr;
    gap: 54px;
    padding-top: 27vh;
    padding-bottom: 130px;
  }

  .directory li > .work-row {
    font-size: clamp(27px, 9vw, 42px);
  }

  .inline-video-info {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .home-footer {
    position: relative;
    bottom: auto;
    padding-bottom: 20px;
  }

  .project-page {
    padding-top: 94px;
  }

  .project-heading {
    min-height: 26vh;
  }

  .gallery {
    display: block;
    padding: 38px 0 100px;
  }

  .project-video {
    padding: 38px 0 100px;
  }

  .gallery figure {
    width: 100%;
    margin-bottom: 30px;
  }

  .gallery figure:nth-child(even) {
    width: 82%;
    margin-left: auto;
  }

  .gallery-paciente figure:nth-child(even) {
    width: 100%;
  }

  .project-text,
  .bio-grid,
  .cv-section,
  .blog-entry {
    grid-template-columns: 1fr;
    gap: 44px;
  }

  .project-text {
    padding: 70px 0 100px;
  }

  .project-copy,
  .long-copy {
    font-size: 18px;
  }

  .project-navigation a {
    min-height: 108px;
  }

  .info-page {
    padding-top: 24vh;
  }

  .bio-grid,
  .index-list {
    margin-top: 9vh;
  }

  .bio-cv {
    margin-top: 13vh;
  }

  .cv-section {
    gap: 30px;
    padding-bottom: 11vh;
  }

  .cv-entry {
    grid-template-columns: 62px minmax(0, 1fr);
    gap: 14px;
    padding-bottom: 26px;
  }

  .cv-items p {
    font-size: 15px;
  }

  .contact-email,
  .contact-phone {
    margin-top: 0;
    font-size: clamp(21px, 5.6vw, 34px);
  }

  .external-links {
    flex-direction: column;
    gap: 10px;
  }

  .collaboration-page {
    padding: 102px 10px 24px;
  }

  .collaboration-page > .eyebrow {
    margin-left: 10px;
  }

  .collaboration-grid {
    display: flex;
  }

  .collaboration-grid-column {
    width: 50%;
  }

  .collaboration-grid .collaboration-card {
    width: 100%;
    aspect-ratio: auto;
  }

  .collaboration-card-title {
    padding: 10px;
    font-size: 13px;
    opacity: 1;
  }

  .video-dialog {
    width: calc(100vw - 20px);
  }

  .video-dialog-close {
    top: 12px;
    right: 12px;
  }

  .lightbox {
    padding: 64px 14px 18px;
  }

  .lightbox-close {
    top: 14px;
    right: 14px;
  }

  .lightbox-arrow {
    top: auto;
    bottom: 10px;
    width: 38px;
    height: 38px;
    transform: none;
  }

  .lightbox-previous {
    left: 14px;
  }

  .lightbox-next {
    right: 14px;
  }

  .lightbox-caption {
    padding: 0 48px;
    text-align: center;
  }

  .lightbox-title {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
  }
}
