@font-face {
  font-family: Kodchasan;
  src: url("../assets/portfolio/kodchasan-medium.woff2") format("woff2");
  font-style: normal;
  font-weight: 500;
  font-display: swap;
}

.logo-page {
  --case-spring: cubic-bezier(.25, .65, .35, 1);
  --case-toggle-duration: .7s;
  --case-toggle: var(--case-toggle-duration) var(--case-spring);
  --concept-spring: cubic-bezier(.2, .6, .3, 1);
  --carousel-slide-ease: cubic-bezier(.18, .64, .26, 1);
  --case-pad: 100px;
  --case-gap: 60px;
  --case-bottom: 50px;
  --case-divider: 12.5vw;
  --section-divider: calc(100vw / 12);
  --title-column: 1.2fr;
  --art-column: .8fr;
  --cover-hand-width: 13%;
  --cover-hand-font: 16px;
  --concepts-brand-size: 3.53cqw;
  --concepts-title-size: 12.259cqw;
  --concepts-hand-width: 81px;
  --summary-size: 18px;
  --summary-line-height: 1.6;
  --project-link-gap: .75;
  --gallery-aspect: 5;
  --gallery-item-count: 4;
}
@supports (animation-timing-function: linear(0, 1)) {
  .logo-page {
    /* Measured from Framer's cover resize, including its small rebound. */
    --case-spring: linear(0, .009 2.4%, .05 4.8%, .118 7.1%, .286 11.9%, .464 16.7%,
      .627 21.4%, .755 26.2%, .852 31%, .922 35.7%, .993 45.2%, 1.014 55.6%,
      1.014 64.3%, 1.009 73.8%, 1.003 85.7%, 1);
    --concept-spring: linear(0, .011 2.4%, .075 4.8%, .175 8.2%, .287 11.6%, .397 15%,
      .499 18.2%, .589 21.4%, .732 28.2%, .866 38%, .936 48.2%, .97 58.2%,
      .986 68.2%, .994 77.8%, .998 88%, 1);
    /* Framer slideshow spring, sampled over its 1.27s settling time. */
    --carousel-slide-ease: linear(0, .022 1.31%, .073 2.62%, .137 3.94%, .271 6.56%,
      .335 7.87%, .449 10.5%, .546 13.13%, .626 15.75%, .721 19.69%, .792 23.62%,
      .845 27.56%, .884 31.5%, .935 39.37%, .964 47.24%, .98 55.12%, .989 62.99%,
      .997 78.74%, .999 94.49%, 1);
  }
}

.logo-hero {
  --tile-entry-spring: cubic-bezier(.17, .65, .34, 1.16);
  --tile-pop-spring: cubic-bezier(.18, .7, .32, 1.35);
  --face-entry-spring: cubic-bezier(.19, .72, .3, 1.2);
  position: relative;
}
@supports (animation-timing-function: linear(0, 1)) {
  .logo-hero {
    --tile-entry-spring: linear(0, .036 3.1%, .125 6.3%, .243 9.4%, .372 12.5%, .5 15.6%,
      .618 18.8%, .808 25%, .933 31.3%, 1.002 37.5%, 1.032 43.8%, 1.038 50%,
      1.032 56.3%, 1.022 62.5%, 1.01 71.9%, 1.002 81.3%, .999 90.6%, 1);
    --tile-pop-spring: linear(0, .111 2.3%, .381 4.5%, .713 6.8%, 1.019 9.1%, 1.241 11.4%,
      1.355 13.6%, 1.37 15.5%, 1.294 18.2%, 1.105 21.8%, .938 25.5%, .861 30%,
      .915 34.5%, 1.017 40%, 1.051 44.5%, 1.034 49.1%, 1.004 53.2%, .981 59.1%,
      .986 63.6%, .998 68.2%, 1.007 73.6%, 1.002 81.8%, .997 88.6%, 1);
    --face-entry-spring: linear(0, .041 2.1%, .146 4.2%, .293 6.3%, .461 8.3%, .631 10.4%,
      .79 12.5%, .928 14.6%, 1.039 16.7%, 1.121 18.8%, 1.174 20.8%, 1.207 24.2%,
      1.19 27.5%, 1.131 31.7%, 1.062 35.8%, 1.004 40%, .969 44.2%, .957 49.2%,
      .969 55%, .99 61.3%, 1.005 67.5%, 1.009 73.3%, 1.007 79.2%, 1.002 85.8%, .999 91.7%, 1);
  }
}
.logo-hero .hero-archive img { opacity: var(--archive-opacity, 1); }
.logo-hero .hero-archive:focus-visible img { opacity: 1; }
.logo-hero .hero-grid-plane {
  background-image: url("../assets/logo/dots.svg");
  background-size: 512px 512px;
  opacity: .15;
  animation: grid-enter 1s var(--float) both, logo-grid-drift 10.24s linear infinite;
}
@keyframes logo-grid-drift { to { background-position-x: -512px; } }

.logo-mark {
  --hero-motion-delay: 1s;
  position: absolute;
  top: 50%;
  left: 37%;
  width: max(35%, 420px);
  aspect-ratio: 1.01205;
  transform: translate(-50%, -50%) perspective(500px) rotateY(15deg);
  transform-style: preserve-3d;
  container-type: inline-size;
}
.logo-letter-grid {
  position: absolute;
  z-index: 1;
  top: 13.45cqw;
  left: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4.76cqw 5.05cqw;
  width: 72%;
  transform-style: preserve-3d;
}
.logo-tile {
  /* Framer keeps the raised glyph a fixed distance from the tile's right edge. */
  --letter-shift: calc(24.2857cqw - 14px);
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  container-type: inline-size;
  perspective: 5000px;
  transform-style: preserve-3d;
  animation: logo-tile-enter .8s var(--tile-entry-spring) .5s both;
}
.logo-tile-red {
  --enter-x: -300px;
  --enter-y: -300px;
  --letter-duration: 2s;
  --letter-shift: calc(32.1429cqw - 25px);
}
.logo-tile-pink { --enter-x: 300px; --enter-y: -300px; --letter-duration: 2.1s; }
.logo-tile-green {
  --enter-x: -300px;
  --enter-y: 300px;
  --letter-duration: 2.2s;
  --letter-shift: calc(25.7143cqw - 16px);
}
.logo-tile-orange { --enter-x: 300px; --enter-y: 300px; --letter-duration: 2.3s; }
.logo-tile-content {
  position: relative;
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
}
.logo-tile img { width: 100%; }
.logo-tile span, .logo-tile-content::after {
  position: absolute;
  inset: 51% auto auto 50%;
  transform: translate(-50%, -50%);
  color: #fff;
  font-size: 54cqw;
  font-weight: 500;
  line-height: 1;
}
.logo-tile span { z-index: 1; }
.logo-tile-content::after {
  content: attr(data-letter);
  color: #000;
  opacity: 0;
  filter: blur(0);
}
@media (prefers-reduced-motion: no-preference) {
  :is(.logo-tile-green, .logo-tile-orange) .logo-tile-content {
    animation: logo-tile-pop 1.1s var(--tile-pop-spring) both;
  }
  .logo-tile span, .logo-tile-content::after {
    --letter-delay: calc(var(--hero-motion-delay) + var(--letter-duration));
    animation: logo-letter-lift var(--letter-duration) var(--float) var(--letter-delay) infinite alternate;
  }
  .logo-tile-content::after { animation-name: logo-letter-shadow; }
}
@keyframes logo-tile-enter {
  from { opacity: 0; transform: translate(var(--enter-x), var(--enter-y)) scale(.5); }
}
@keyframes logo-tile-pop { from { opacity: 0; transform: scale(.5); } }
@keyframes logo-letter-lift {
  to { transform: translate(-50%, -50%) translate3d(var(--letter-shift), 0, 40px); }
}
@keyframes logo-letter-shadow { to { opacity: .5; filter: blur(7px); } }

.logo-face {
  position: absolute;
  top: 75.7%;
  left: 76%;
  width: 43%;
  transform: translate(-50%, -50%);
  animation: logo-face-enter 1.2s var(--face-entry-spring) 1s both;
}
.logo-face-swing {
  transform-origin: top center;
  animation: logo-face-swing 1.5s var(--float) var(--hero-motion-delay) infinite alternate both;
}
.logo-face-tile { width: 100%; }
.logo-face-features {
  position: absolute;
  width: 54.95%;
  height: 38.54%;
  right: -3.3%;
  bottom: 6.25%;
  container-type: inline-size;
}
.logo-face-eye {
  position: absolute;
  width: 16cqw;
  height: 16cqw;
  transform: translate(-50%, -50%) rotate(13deg);
}
.logo-face-eye-left { left: 36.5%; top: 20.95%; }
.logo-face-eye-right { left: 71.5%; top: 31.75%; }
.logo-face-mouth {
  position: absolute;
  top: 72.3%;
  left: 48.5%;
  width: 89%;
  transform: translate(-50%, -50%);
}
@media (prefers-reduced-motion: no-preference) {
  .logo-face-eye, .logo-face-mouth {
    /* Framer's three blinks recur every 3.6s. Begin on the fully open frame. */
    animation: logo-face-blink 3.6s linear calc(var(--hero-motion-delay) + .1s) infinite;
  }
  .logo-face-mouth { animation-name: logo-face-mouth; }
}
@keyframes logo-face-enter { from { opacity: 0; transform: translate(-50%, calc(-50% - 400px)); } }
@keyframes logo-face-swing { from { transform: rotate(10deg); } to { transform: rotate(-10deg); } }
@keyframes logo-face-blink {
  0%, 38.8889%, 44.4444%, 83.3333%, 88.8889%, 94.4444%, 100% { height: 16cqw; }
  41.6667%, 86.1111%, 97.2222% { height: 3px; }
}
@keyframes logo-face-mouth {
  0%, 38.8889%, 44.4444%, 100% { transform: translate(-50%, -50%) rotate(0deg); }
  41.6667% { transform: translate(-50%, -50%) rotate(-7deg); }
}

.logo-case + .logo-case { margin-top: var(--case-divider); }
.logo-cases { padding-bottom: var(--section-divider); overflow-x: clip; }
.logo-case {
  --summary-width: 60%;
}
.logo-case.is-light {
  --title-column: .8fr;
  --art-column: 1.2fr;
  --summary-width: 100%;
  --cover-hand-width: 19.5%;
}
.logo-case-content {
  width: min(100%, var(--stage-width));
  margin-inline: auto;
  padding: var(--case-pad) var(--case-pad) var(--case-bottom);
}
.logo-overview {
  display: grid;
  grid-template-columns: minmax(0, var(--title-column)) minmax(0, var(--art-column));
  gap: var(--case-gap);
  transition: grid-template-columns var(--case-toggle);
}
.logo-overview.is-measuring {
  position: absolute;
  inset: 0 auto auto 0;
  visibility: hidden;
  pointer-events: none;
}
.logo-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 0;
  padding-top: 20px;
  container-type: inline-size;
}
.armor { --title-size: 18.902cqw; }
.maha { --title-size: 31.3477cqw; }
.tea { --title-size: 23.847cqw; }
.logo-project-title {
  margin: 0;
  font-size: var(--title-size);
  font-weight: 500;
  line-height: 1;
}
.logo-summary {
  width: var(--summary-width);
  margin: 50px 0 0;
  font-size: var(--summary-size);
  font-weight: 500;
  line-height: var(--summary-line-height);
  overflow-wrap: break-word;
  transition: width var(--case-toggle);
}
.logo-summary > p { margin: 0; }
.logo-project-link {
  display: inline-block;
  margin-top: calc(var(--project-link-gap) * 1em);
  color: #fff;
  text-decoration: underline;
  text-underline-offset: .2em;
}
.logo-cue {
  position: relative;
  flex: 0 0 auto;
  font-weight: 500;
  line-height: 1.2;
}
.logo-cue span {
  position: absolute;
  top: 50%;
  right: calc(100% + 10px);
  transform: translateY(-50%);
  text-align: right;
}
.logo-cue img { width: 100%; height: 100%; object-fit: contain; }
.cover-cue {
  align-self: flex-end;
  width: var(--cover-hand-width);
  aspect-ratio: 1.5;
  font-size: var(--cover-hand-font);
  margin-top: 40px;
  transition: width var(--case-toggle);
}
.logo-summary:has(.logo-project-link) + .cover-cue {
  /* Use the space between the description and the cue for the project link. */
  margin-top: max(0px, calc(40px - var(--summary-size) * (var(--project-link-gap) + var(--summary-line-height))));
}
.cover-pointer {
  position: absolute;
  inset: 0;
  background: url("../assets/portfolio/hand-gallery.svg") center / contain no-repeat;
}
.logo-cover {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  place-items: center;
  align-self: stretch;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: 50px;
  background: #000;
  box-shadow: inset 16px 16px 64px #ffffff26;
  cursor: pointer;
}
.logo-cover::before {
  content: '';
  position: absolute;
  inset: auto 0 -10px;
  height: 10px;
  border-radius: inherit;
  background: #fff;
  transition: height var(--case-toggle), bottom var(--case-toggle);
}
.logo-cover img {
  position: relative;
  grid-area: 1 / 1;
  width: 100%;
  height: auto;
  aspect-ratio: 8 / 9;
  object-fit: contain;
}
.logo-cover-dark, .logo-cover-light { transition: opacity var(--case-toggle); }
.logo-cover-light { opacity: 0; }
.logo-cover[aria-pressed="true"]::before { bottom: 0; height: var(--cover-paper-height, 100%); }
.logo-cover[aria-pressed="true"] .logo-cover-dark { opacity: 0; }
.logo-cover[aria-pressed="true"] .logo-cover-light { opacity: 1; }
.logo-cover:focus-visible { outline-offset: 3px; }

.logo-concepts-heading {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
  margin-top: calc(100% / 7.14286);
  container-type: inline-size;
}
.logo-concepts-brand, .logo-concepts-title {
  margin: 0;
  font-weight: 500;
  line-height: 1;
}
.logo-concepts-brand { font-size: var(--concepts-brand-size); }
.logo-concepts-title { font-size: var(--concepts-title-size); }
.concepts-cue {
  --cue-x: 0px;
  --cue-y: 10px;
  --cue-label-entry: 20px 0;
  display: flex;
  justify-content: flex-end;
  width: var(--concepts-hand-width);
  aspect-ratio: 1.8;
  font-size: 12px;
}
.concepts-cue img {
  position: absolute;
  top: 0;
  right: 0;
  width: auto;
}
.concepts-cue span { right: calc(37% + 10px); }

.concept-carousel {
  --concept-gap: 40px;
  position: relative;
  aspect-ratio: var(--gallery-aspect);
  overflow: clip;
}
.concept-window {
  position: absolute;
  inset: 20px 20px 40px;
  touch-action: pan-y pinch-zoom;
  cursor: grab;
}
.concept-window.is-dragging { cursor: grabbing; }
.concept-track { position: relative; width: 100%; height: 100%; }
.concept-slide {
  position: absolute;
  inset: 0 auto 0 0;
  display: grid;
  place-items: center;
  width: calc((100% + var(--concept-gap)) / var(--gallery-item-count) - var(--concept-gap));
  padding: 0;
  border: 0;
  border-radius: 10px;
  background: transparent;
  overflow: hidden;
  transform: translateX(calc(var(--slot, 0) * (100% + var(--concept-gap)) + var(--drag-x, 0px)));
  transition: transform 1.27s var(--carousel-slide-ease);
  cursor: pointer;
}
.concept-slide.is-outside { visibility: hidden; }
.concept-slide.is-wrapping, .concept-window.is-dragging .concept-slide { transition: none; }
.concept-slide img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: none;
  user-select: none;
  transition: opacity .5s var(--concept-spring), scale .5s var(--concept-spring);
}
.concept-slide .concept-dark { z-index: 1; }
.concept-slide .concept-light { opacity: 0; scale: .5; }
.concept-slide[aria-pressed="true"] .concept-dark { opacity: 0; scale: .5; }
.concept-slide[aria-pressed="true"] .concept-light { opacity: 1; scale: 1; }
.concept-slide:focus-visible { outline-offset: -4px; }
.concept-dots {
  position: absolute;
  bottom: -10px;
  left: 50%;
  display: flex;
  padding: 0 5px;
  transform: translateX(-50%);
}
.concept-dots button {
  display: grid;
  place-items: center;
  width: 20px;
  height: 30px;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
}
.concept-dots button::after {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #fff3;
}
.concept-dots button[aria-current="true"]::after { background: white; }
.concept-dots button:focus-visible { outline-offset: -2px; }

.motion-ready .logo-project-title {
  --title-entry-x: -150px;
  --title-entry-y: -100px;
  --title-entry-scale: .5;
  transform: translate(calc(var(--title-entry-x) * var(--entry-left, 0)),
    calc(var(--title-entry-y) * var(--entry-left, 0))) scale(calc(1 - var(--title-entry-scale) * var(--entry-left, 0)));
}
.motion-ready .logo-summary { transform: translateY(calc(100px * var(--entry-left, 0))); }
.motion-ready .logo-cover { transform: translateY(calc(200px * var(--entry-left, 0))); }
.motion-ready :is(.logo-concepts-brand, .logo-concepts-title) {
  transform: translateX(calc(-200px * var(--entry-left, 0)));
}
.motion-ready .logo-cover:focus-visible { transform: none; }
@media (width >= 600px) {
  .motion-ready .concept-carousel { transition: opacity 2s var(--case-spring); }
  .motion-ready .concept-carousel > * { transition: translate 2s var(--case-spring); }
  .motion-ready .concept-carousel:not(.has-appeared, :focus-within) {
    opacity: 0;
  }
  .motion-ready .concept-carousel:not(.has-appeared, :focus-within) > * { translate: 300px 0; }
}

@media (900px <= width < 1200px) {
  .logo-page {
    --section-divider: calc(100vw / 9);
    --gallery-aspect: 5.625;
    --gallery-item-count: 3;
  }
  .logo-mark { width: min(47%, 420px); }
}
@media (600px <= width < 900px) {
  .logo-page {
    --menu-top: 70px;
    --case-pad: 50px;
    --case-gap: 40px;
    --section-divider: calc(100vw / 6);
    --art-column: 1fr;
    --cover-hand-width: 24%;
    --cover-hand-font: 12px;
    --concepts-title-size: 14.0105cqw;
    --concepts-hand-width: 16%;
    --summary-size: 16px;
    --gallery-aspect: 4.28571;
    --gallery-item-count: 3;
  }
  .logo-case { --summary-width: 100%; }
  .armor { --concepts-brand-size: 4.315cqw; }
  .logo-case.is-light { --cover-hand-width: 30%; }
  .logo-mark { left: 39%; width: min(53%, 420px); }
  .logo-hero .hero-grid-plane { left: auto; right: -112px; }
}
@media (width < 600px) {
  .logo-page {
    --case-pad: 0px;
    --case-gap: 40px;
    --case-bottom: 20px;
    --case-divider: 25vw;
    --section-divider: 100px;
    --cover-hand-font: 12px;
    --concepts-brand-size: 18px;
    --concepts-title-size: 14.0105cqw;
    --summary-size: 14px;
    --gallery-item-count: 1;
  }
  .logo-mark {
    --hero-motion-delay: 0s;
    left: 45%;
    width: min(66%, 250px);
    aspect-ratio: .605187;
    transform: translate(-50%, -50%) perspective(500px) rotateY(27deg);
  }
  .logo-letter-grid {
    top: 0;
    left: 50%;
    translate: -50% 0;
    width: 96%;
  }
  .logo-face { top: 80%; left: 56%; width: 58%; }
  .logo-hero .hero-design { aspect-ratio: .160622; }
  .logo-cases { padding-top: 12.5vw; }
  .logo-case-content { width: 90%; }
  .logo-overview { grid-template-columns: minmax(0, 1fr); }
  .logo-copy { padding-top: 0; }
  .logo-summary { width: 100%; margin-top: 30px; }
  .cover-cue, .concepts-cue {
    --cue-x: 0px;
    --cue-y: 10px;
    --cue-label-entry: 20px 0;
    align-self: center;
    width: 25%;
    min-height: 3.6em;
    aspect-ratio: 1.8;
  }
  .logo-cue .pointer-cue-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
  }
  .logo-cue span {
    position: static;
    flex: 0 0 41px;
    transform: none;
  }
  .cover-pointer {
    background-image: url("../assets/portfolio/hand-archive.svg");
  }
  .cover-pointer, .concepts-cue img {
    position: static;
    flex: none;
    width: auto;
    height: 100%;
    aspect-ratio: 2 / 3;
  }
  .logo-concepts-heading {
    align-items: center;
    gap: 30px;
    margin-top: calc(100% / 8);
  }
  .concept-carousel { height: 240px; aspect-ratio: auto; }
  .motion-ready .logo-project-title {
    --title-entry-x: -63px;
    --title-entry-y: 50px;
    --title-entry-scale: .4;
  }
  .motion-ready .tea .logo-project-title { --title-entry-scale: .5; }
  .motion-ready .armor .logo-project-title { opacity: calc(1 - var(--entry-left, 0)); }
}

@media (prefers-reduced-motion: reduce) {
  .logo-hero .hero-grid-plane, .logo-tile, .logo-face, .logo-face-swing { animation: none; }
  .logo-overview, .logo-summary, .cover-cue, .logo-cover::before, .logo-cover img, .concept-slide, .concept-slide img {
    transition: none;
  }
}
