:root {
  color-scheme: dark;
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  background: #000;
  color: #f4f4f7;
}

* {
  box-sizing: border-box;
}

html {
  background: #000;
  scrollbar-width: none;
}

body {
  min-height: 500vh;
  margin: 0;
  background: #000;
  overflow-x: hidden;
  scrollbar-width: none;
}

html::-webkit-scrollbar,
body::-webkit-scrollbar,
.project-modal-copy::-webkit-scrollbar {
  display: none;
}

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

.page-shell {
  position: relative;
  min-height: 500vh;
  background: #000;
  isolation: isolate;
}

.stage {
  position: sticky;
  top: 0;
  width: 100%;
  height: 100vh;
  overflow: hidden;
}

#webgl-stage {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  z-index: 1;
  cursor: grab;
  touch-action: pan-y;
}

#webgl-stage.is-dragging {
  cursor: grabbing;
}

#webgl-stage.is-hovering-photo {
  cursor: pointer;
}

.html-intro-layer,
.html-content-layer,
.photo-label-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.html-intro-layer {
  z-index: 0;
}

.html-content-layer {
  z-index: 3;
}

.photo-label-layer {
  z-index: 2;
}

.photo-label {
  position: absolute;
  left: 0;
  top: 0;
  display: none;
  margin: 0;
  color: #fff;
  font-size: 0.56rem;
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: 0.08em;
  opacity: 0.42;
  text-transform: uppercase;
  white-space: nowrap;
  text-shadow:
    -1px -1px 0 #000,
    1px -1px 0 #000,
    -1px 1px 0 #000,
    1px 1px 0 #000,
    0 0 4px rgb(0 0 0 / 0.9);
  transform: translate(0, calc(-100% - 0.35rem));
  transition: opacity 0.3s ease;
  will-change: left, top, opacity;
}

.photo-label.is-visible {
  display: block;
}

.photo-label.is-hovered {
  opacity: 1;
}

.photo-label span {
  display: block;
}

.project-modal {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: none;
  background: #000;
}

.project-modal.is-open {
  display: block;
}

.project-modal-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.project-modal-close {
  position: absolute;
  top: 0rem;
  left: 0rem;
  z-index: 2;
  color: #fff;
  font-size: 2rem;
  line-height: 2rem;
  width: 2.8rem;
  height: 2.4rem;
  text-decoration: none;
  text-align: center;
  background: #0003;
  text-shadow: 0 1px 2px rgb(0 0 0 / 1);
  -webkit-backdrop-filter: blur(7px);
  backdrop-filter: blur(7px);
}

.project-modal-copy {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 1;
  display: none;
  width: 50%;
  padding: clamp(2rem, 5vw, 5rem);
  overflow-y: auto;
  background: #0003;
  color: #fff;
  scrollbar-width: none;
  -webkit-backdrop-filter: blur(7px);
  backdrop-filter: blur(7px);
}

.project-modal-copy.is-active {
  display: block;
}

.project-modal-copy h2 {
  max-width: 14ch;
  margin-bottom: 2rem;
  font-size: clamp(2rem, 5vw, 5.5rem);
  line-height: 0.95;
  text-transform: uppercase;
}

.project-modal-copy p {
  max-width: 38rem;
  margin-bottom: 1.35rem;
  color: rgb(255 255 255 / 0.88);
  font-size: clamp(1rem, 1.6vw, 1.35rem);
  line-height: 1.65;
}

.intro,
.content-panel {
  position: absolute;
  width: min(34rem, calc(100vw - 2rem));
  pointer-events: auto;
  text-wrap: balance;
}

.intro {
  top: clamp(2rem, 8vh, 5rem);
  left: clamp(1rem, 3vw, 6rem);
  pointer-events: none;
}

.eyebrow {
  margin: 0 0 0.75rem;
  color: #fff;
  font-size: 0.78rem;
  letter-spacing: 4px;
  font-weight: 700;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  max-width: 11ch;
  font-size: clamp(2.45rem, 7vw, 6.4rem);
  line-height: 0.92;
  letter-spacing: 0;
  color: #000;
  text-shadow: 0 0 1px #fff, 0 0 1px #fff, 0 0 1px #fff, 0 0 1px #fff, 0 0 2px #fff, 0 0 2px #fff, 0 0 2px #fff;
}

h2 {
  margin-bottom: 0.7rem;
  font-size: clamp(1.2rem, 2vw, 1.7rem);
  line-height: 1.05;
  letter-spacing: 0;
}

.intro p:last-child,
.content-panel p {
  max-width: 32rem;
  color: rgb(226 229 241 / 0.76);
  font-size: clamp(0.95rem, 1.6vw, 1.1rem);
  line-height: 1.55;
}

.intro p:last-child {
  margin-top: 1.25rem;
}

.content-panel {
  padding-left: 1rem;
  border-left: 1px solid rgb(133 164 255 / 0.55);
}

.panel-a {
  right: clamp(1rem, 7vw, 7rem);
  top: 18vh;
}

.panel-b {
  left: clamp(1rem, 8vw, 8rem);
  bottom: 13vh;
}

.panel-c {
  left: auto;
  right: clamp(1rem, 4vw, 8rem);
  width: 18rem;
  bottom: 8vh;
}

@media (max-width: 760px) {
  .intro {
    top: 2rem;
    left: 1rem;
  }

  h1 {
    max-width: 9ch;
  }

  .content-panel {
    width: min(18rem, calc(100vw - 2rem));
  }

  .panel-a {
    top: 44vh;
    right: 1rem;
  }

  .panel-b {
    bottom: 14vh;
    left: 1rem;
  }

  .panel-c {
    display: none;
  }
}
