/* =====================================================================
   STATE MACHINE  —  body[data-state="lobby" | "transition" | "projects"]
   Each section fades in/out based on the current state.
   ===================================================================== */

/* ===== Cinema video (full-bleed background, sits behind everything) ===== */
.cinema {
  position: fixed; inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
  background: var(--ink);
}
.cinema video {
  position: absolute;
  top: 50%; left: 50%;
  min-width: 100%; min-height: 100%;
  width: auto; height: auto;
  translate: -50% -50%;
  /* Slight overscale so JS parallax drift never reveals viewport edges */
  scale: 1.08;
  object-fit: cover;
  opacity: 0;
  transition: opacity 200ms var(--ease-out);
  will-change: transform;
}
.cinema video.is-active { opacity: 1; }
/* Subtle vignette over the video for focus */
.cinema::after {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at center, transparent 40%, rgba(0,0,0,0.55) 100%);
  pointer-events: none;
}
/* Placeholder pattern shown when no video file is present yet */
.cinema__placeholder {
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse at center, rgba(45, 212, 191, 0.06) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 100%, rgba(45, 212, 191, 0.12) 0%, transparent 60%),
    linear-gradient(180deg, #000 0%, #060606 50%, #0A0A0A 100%);
  display: grid; place-items: center;
  color: rgba(255, 255, 255, 0.15);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
}

/* ===== NAV — floating liquid-glass pill, persistent across states ===== */
.nav {
  position: fixed;
  top: var(--pad-y);
  left: 50%;
  translate: -50% 0;
  z-index: 100;
  display: flex; align-items: center; gap: 28px;
  padding: 10px 14px 10px 24px;
  background: var(--glass-bg);
  backdrop-filter: blur(28px) saturate(180%);
  -webkit-backdrop-filter: blur(28px) saturate(180%);
  border: 1px solid var(--glass-border);
  border-radius: var(--glass-radius-pill);
  box-shadow:
    inset 0 1px 0 var(--glass-highlight),
    inset 0 -1px 0 var(--glass-shade),
    0 8px 32px rgba(0, 0, 0, 0.32);
  opacity: 0;
  animation: navFadeIn 1.2s 0.6s var(--ease-out) forwards;
}
.nav__logo {
  font-family: var(--font-display);
  font-weight: 800;
  text-transform: lowercase;
  letter-spacing: -0.02em;
  font-size: 14px;
  color: var(--paper);
  white-space: nowrap;
}
.nav__logo .reg {
  font-size: 0.55em; vertical-align: super; color: var(--turquoise); margin-left: 2px;
}
.nav__divider {
  width: 1px; height: 18px; background: var(--line-2); margin: 0 4px;
}
.nav__links { display: flex; gap: 4px; }
.nav__links a {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--paper-dim);
  padding: 8px 14px;
  border-radius: var(--glass-radius-pill);
  transition: color 240ms var(--ease-out), background 240ms var(--ease-out);
}
.nav__links a:hover { color: var(--paper); background: rgba(255,255,255,0.06); }
.nav__links a.is-active { color: var(--turquoise); background: var(--turquoise-soft); }

@keyframes navFadeIn { to { opacity: 1; } }

/* ===== LOBBY STATE  — POLAROIDX wordmark blurs in, cinema video paused at frame 0 ===== */
.lobby {
  position: fixed; inset: 0;
  z-index: 10;
  display: grid; place-items: center;
  opacity: 0;
  transition: opacity 700ms var(--ease-out);
  pointer-events: none;
  /* 3D perspective context so the wordmark can tilt in space */
  perspective: 1400px;
  perspective-origin: 50% 50%;
}

/* Ambient dust particles — canvas sits behind the wordmark, fades with .lobby */
.lobby__dust {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  mix-blend-mode: screen;     /* particles only ADD light, never darken */
  z-index: 0;
}
body[data-state="lobby"] .lobby {
  opacity: 1;
  pointer-events: auto;
}

.lobby__wordmark {
  font-family: var(--font-display);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -0.055em;
  line-height: 0.88;
  font-size: clamp(44px, 17vw, 280px);
  color: var(--paper);
  white-space: nowrap;
  user-select: none;
  text-align: center;
  /* Blur-in entrance — pure blur, no fly */
  opacity: 0;
  filter: blur(60px);
  animation: wordmarkBlurIn 1.6s 0.4s var(--ease-out) forwards;
  /* 3D-ready so JS can tilt/drift it inside the cinema room */
  transform-style: preserve-3d;
  will-change: transform;
  position: relative;
  z-index: 1;       /* sit above the dust canvas */
}
.lobby__wordmark .x {
  color: var(--turquoise);
  margin-left: -0.03em;
  text-shadow:
    0 0 30px rgba(45, 212, 191, 0.6),
    0 0 80px rgba(45, 212, 191, 0.35);
  /* Independent transform plane — the X parallaxes closer to the viewer */
  display: inline-block;
  transform-style: preserve-3d;
  will-change: transform;
}
@keyframes wordmarkBlurIn {
  0%   { opacity: 0; filter: blur(60px); }
  50%  { opacity: 0.7; filter: blur(20px); }
  100% { opacity: 1; filter: blur(0); }
}

.lobby__eyebrow {
  position: fixed;
  top: calc(var(--pad-y) + 70px);
  left: 50%;
  translate: -50% 0;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.45em;
  text-transform: uppercase;
  white-space: nowrap;
  max-width: 100vw;
  color: var(--paper-mut);
  opacity: 0;
  animation: navFadeIn 1.2s 1.6s var(--ease-out) forwards;
}

.lobby__sub {
  position: fixed;
  bottom: calc(var(--pad-y) + 80px);
  left: 50%;
  translate: -50% 0;
  width: max-content;
  max-width: calc(100vw - 2 * var(--pad-x));
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0 14px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--paper-mut);
  text-align: center;
  opacity: 0;
  animation: navFadeIn 1.2s 1.9s var(--ease-out) forwards;
}
.lobby__sub b { color: var(--paper); font-weight: 500; }
/* Each half stays whole — the line breaks at the separator, never mid-phrase */
.lobby__sub-line { white-space: nowrap; }
.lobby__sub-sep { color: var(--paper-faint); }

/* "Begin" call-to-action under the wordmark — liquid glass pill */
.lobby__cta {
  position: fixed;
  bottom: calc(var(--pad-y) + 32px);
  left: 50%;
  translate: -50% 0;
  opacity: 0;
  animation: navFadeIn 1.2s 2.2s var(--ease-out) forwards;
}

/* Bottom-left metadata */
.lobby__meta {
  position: fixed;
  bottom: var(--pad-y);
  left: var(--pad-x);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--paper-mut);
  opacity: 0;
  animation: navFadeIn 1.2s 2s var(--ease-out) forwards;
}
.lobby__meta .lbl { color: var(--paper-faint); margin-right: 8px; }

/* ===== TRANSITION STATE — video plays, wordmark fades away ===== */
body[data-state="transition"] .lobby {
  opacity: 0; pointer-events: none;
  filter: blur(8px);
  transition: opacity 600ms var(--ease-out), filter 600ms var(--ease-out);
}
body[data-state="transition"] .nav { opacity: 0.35; transition: opacity 500ms; }
body[data-state="transition"] .cinema { z-index: 50; }    /* video pops above lobby */

/* ===== PROJECTS STATE — Netflix-style sidebar + featured area ===== */
.projects {
  position: fixed; inset: 0;
  z-index: 20;
  display: grid;
  /* Left sidebar narrower than right featured area — like Netflix */
  grid-template-columns: minmax(280px, 28%) 1fr;
  gap: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 700ms var(--ease-out);
}
body[data-state="projects"] .projects {
  opacity: 1;
  pointer-events: auto;
}

/* ----- Right side: featured background ----- */
.projects__featured {
  position: relative;
  overflow: hidden;
  z-index: 1;
}
.projects__bg {
  position: absolute; inset: 0;
  z-index: 0;
}
.projects__bg-media {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  transition: opacity 700ms var(--ease-out), transform 1.2s var(--ease-out);
}
.projects__bg-media.is-leaving { opacity: 0; transform: scale(1.03); }
/* Gradient overlay so the top-right project name stays legible over any bg */
.projects__bg::after {
  content: '';
  position: absolute; inset: 0;
  background:
    linear-gradient(180deg,
      rgba(0,0,0,0.55) 0%,
      rgba(0,0,0,0.15) 30%,
      rgba(0,0,0,0.15) 60%,
      rgba(0,0,0,0.55) 100%),
    linear-gradient(270deg,
      rgba(0,0,0,0.45) 0%,
      transparent 35%);
  pointer-events: none;
}

/* Top-right: featured project name + meta */
.projects__featured-head {
  position: absolute;
  top: calc(var(--pad-y) + 90px);
  right: var(--pad-x);
  z-index: 5;
  text-align: right;
  max-width: 60%;
}
.projects__featured-eyebrow {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--turquoise);
  margin-bottom: 16px;
  display: inline-flex;
  align-items: center; gap: 10px;
}
.projects__featured-eyebrow .dot {
  width: 6px; height: 6px;
  background: var(--turquoise);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--turquoise-glow);
  animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%      { opacity: 0.55; transform: scale(0.8); }
}
.projects__featured-title {
  font-family: var(--font-display);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -0.045em;
  line-height: 0.88;
  font-size: clamp(40px, 6vw, 96px);
  color: var(--paper);
  text-shadow:
    0 2px 30px rgba(0, 0, 0, 0.6),
    0 8px 60px rgba(0, 0, 0, 0.4);
  /* Allow JS to fade-swap the text */
  transition: opacity 320ms var(--ease-out), transform 480ms var(--ease-out);
}
.projects__featured-title.is-leaving { opacity: 0; transform: translateY(-8px); }

.projects__featured-meta {
  display: flex; justify-content: flex-end; align-items: center;
  gap: 12px;
  margin-top: 22px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--paper-dim);
}
.projects__featured-meta .sep {
  width: 24px; height: 1px;
  background: var(--paper-faint);
}

/* Bottom-right: feature CTA + description */
.projects__featured-foot {
  position: absolute;
  bottom: var(--pad-y);
  right: var(--pad-x);
  z-index: 5;
  display: flex; flex-direction: column; align-items: flex-end;
  gap: 18px;
  max-width: 50%;
}
.projects__featured-desc {
  font-size: 14px;
  line-height: 1.55;
  color: var(--paper-dim);
  text-align: right;
  text-shadow: 0 1px 12px rgba(0,0,0,0.5);
}

/* ----- Left side: liquid-glass sidebar ----- */
.projects__sidebar {
  position: relative;
  z-index: 2;
  padding: calc(var(--pad-y) + 90px) 20px var(--pad-y) var(--pad-x);
  display: flex; flex-direction: column;
  gap: 18px;
  /* clip, not hidden — clip-margin lets card glows bleed past the sidebar edge */
  overflow: clip;
  overflow-clip-margin: 44px;
  /* The sidebar itself sits on the cinema bg with a strong glass effect */
  background: rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(36px) saturate(160%);
  -webkit-backdrop-filter: blur(36px) saturate(160%);
  border-right: 1px solid var(--glass-border);
  box-shadow: 4px 0 32px rgba(0, 0, 0, 0.45);
}

.projects__sidebar-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 6px;
}

/* Scrollable list of project cards */
.projects__list {
  list-style: none;
  display: flex; flex-direction: column;
  gap: 12px;
  overflow-y: auto;
  /* Room inside the scroll box for the 28px hover glow so it isn't clipped */
  padding: 32px 36px 32px 34px;
  margin: -18px -20px -32px -34px;
  flex: 1;
  /* Custom thin scrollbar */
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.15) transparent;
}
.projects__list::-webkit-scrollbar { width: 6px; }
.projects__list::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 3px;
}

/* Individual project card — thumbnail on top, info beneath, all in glass */
.project {
  position: relative;
  /* Never shrink below content height — otherwise the 16:9 thumb collapses to 0
     and the meta line gets clipped on shorter viewports. The list scrolls instead. */
  flex: 0 0 auto;
  display: flex; flex-direction: column;
  padding: 0;
  overflow: hidden;
  background: var(--glass-bg);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid var(--glass-border);
  border-radius: var(--glass-radius);
  box-shadow:
    inset 0 1px 0 var(--glass-highlight),
    inset 0 -1px 0 var(--glass-shade),
    0 4px 16px rgba(0, 0, 0, 0.18);
  cursor: pointer;
  transition:
    transform 380ms var(--ease-out),
    background 320ms var(--ease-out),
    border-color 320ms var(--ease-out),
    box-shadow 480ms var(--ease-out);
}
.project:hover,
.project.is-active {
  transform: translateX(8px);
  background: var(--glass-bg-deeper);
  border-color: var(--turquoise);
  box-shadow:
    inset 0 1px 0 var(--glass-border-bright),
    0 0 0 1px var(--turquoise-glow),
    0 0 28px var(--turquoise-glow),
    0 8px 24px rgba(0, 0, 0, 0.28);
}
.project.is-active::before {
  /* Active-state accent — turquoise bar on the left edge */
  content: '';
  position: absolute;
  left: -1px; top: 14px; bottom: 14px;
  width: 3px;
  background: var(--turquoise);
  border-radius: 2px;
  box-shadow: 0 0 8px var(--turquoise-glow);
  z-index: 2;
}

/* Thumbnail — 16:9 preview at the top of each card */
.project__thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  min-height: 96px;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(45, 212, 191, 0.08), rgba(0, 0, 0, 0.5));
  border-bottom: 1px solid var(--glass-border);
}
.project__thumb img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 1.2s var(--ease-out), filter 600ms var(--ease-out);
  filter: grayscale(0.15) brightness(0.82) contrast(1.04);
}
.project:hover .project__thumb img,
.project.is-active .project__thumb img {
  transform: scale(1.07);
  filter: grayscale(0) brightness(1.04) contrast(1.05);
}
.project__thumb::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(0,0,0,0.45) 100%);
  pointer-events: none;
}

/* Body — number / title / meta beneath the thumb */
.project__body {
  padding: 14px 18px 16px;
  display: flex; flex-direction: column; gap: 4px;
}

.project__num {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.22em;
  color: var(--paper-mut);
  margin-bottom: 2px;
}
.project:hover .project__num,
.project.is-active .project__num { color: var(--turquoise); }

.project__title {
  font-family: var(--font-display);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: -0.02em;
  font-size: 18px;
  line-height: 1.1;
  color: var(--paper);
}

.project__meta {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--paper-mut);
  margin-top: 4px;
}

/* Sidebar footer */
.projects__sidebar-foot {
  margin-top: 12px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  display: flex; flex-direction: column; gap: 6px;
}

/* ===== Responsive ===== */
/* Phones: the card list becomes a full-screen swipe stack, one project per
   screen, each carrying its own frame. */
.swipe-hint { display: none; }

@media (max-width: 880px) {
  .projects { grid-template-columns: 1fr; }
  .projects__sidebar {
    position: absolute; inset: 0;
    height: auto; padding: 0; gap: 0;
    border: 0; box-shadow: none;
    background: transparent;
    backdrop-filter: none; -webkit-backdrop-filter: none;
    overflow: hidden;
  }
  .projects__sidebar-head,
  .projects__sidebar-foot { display: none; }

  .projects__list {
    height: 100dvh;
    margin: 0; padding: 0; gap: 0;
    scroll-snap-type: y mandatory;
    overscroll-behavior-y: contain;
    -webkit-overflow-scrolling: touch;
  }
  .project {
    height: 100dvh; min-height: 100dvh;
    scroll-snap-align: start; scroll-snap-stop: always;
    justify-content: flex-end;
    padding: 0; border: 0; border-radius: 0;
    background: #000; box-shadow: none;
    backdrop-filter: none; -webkit-backdrop-filter: none;
  }
  .project:hover,
  .project.is-active {
    transform: none;
    background: #000;
    border-color: transparent;
    box-shadow: none;
  }
  .project.is-active::before { display: none; }

  .project__thumb {
    position: absolute; inset: 0;
    aspect-ratio: auto; min-height: 0;
    border-bottom: 0;
  }
  .project__thumb img,
  .project:hover .project__thumb img,
  .project.is-active .project__thumb img { transform: none; filter: none; }
  .project__thumb::after {
    background: linear-gradient(180deg,
      rgba(0,0,0,0.55) 0%, rgba(0,0,0,0.05) 26%,
      rgba(0,0,0,0.1) 46%, rgba(0,0,0,0.88) 100%);
  }

  .project__body {
    position: relative; z-index: 2;
    padding: 0 22px calc(var(--pad-y) + 58px);
    gap: 6px;
  }
  .project__title {
    font-weight: 900; letter-spacing: -0.04em;
    font-size: clamp(34px, 11vw, 56px);
  }
  .project__num,
  .project.is-active .project__num { font-size: 11px; }
  .project__meta { font-size: 11px; }

  /* The hero overlay text duplicates the card while browsing */
  body[data-state="projects"] .projects__featured-head,
  body[data-state="projects"] .projects__featured-foot {
    opacity: 0; pointer-events: none;
  }
  .projects__featured-head { max-width: 90%; }
  .projects__featured-foot { max-width: 90%; }

  .swipe-hint {
    position: absolute; z-index: 6;
    left: 50%; translate: -50% 0;
    bottom: calc(var(--pad-y) + 14px);
    display: flex; align-items: center; gap: 9px;
    font-family: var(--font-mono);
    font-size: 10px; letter-spacing: 0.3em; text-transform: uppercase;
    color: var(--paper-dim);
    pointer-events: none;
    transition: opacity 500ms var(--ease-out);
  }
  .swipe-hint svg { animation: swipeBob 1.9s var(--ease-out) infinite; }
  .swipe-hint.is-gone { opacity: 0; }
  body:not([data-state="projects"]) .swipe-hint { opacity: 0; }
}
@keyframes swipeBob {
  0%, 100% { transform: translateY(2px); opacity: 0.5; }
  50%      { transform: translateY(-3px); opacity: 1; }
}

/* Poster frame stands in until the reveal clip is decoded */
body.is-mobile .cinema {
  background: #000 url('../img/posters/cinema-first.jpg') center / cover no-repeat;
}
body.is-mobile .cinema__placeholder { display: none; }

/* Fit the nav to narrow devices instead of letting it run off the edges */
@media (max-width: 560px) {
  .nav {
    left: var(--pad-x); right: var(--pad-x);
    translate: none;
    justify-content: space-between;
    gap: 8px;
    padding: 8px 10px 8px 14px;
  }
  .nav__divider { display: none; }
  .nav__links { gap: 0; }
  .nav__links a { font-size: 10px; letter-spacing: 0.1em; padding: 9px 8px; }
}
@media (max-width: 420px) {
  .lobby__eyebrow { font-size: 9px; letter-spacing: 0.3em; }
  .lobby__sub { font-size: 10px; letter-spacing: 0.22em; }
  .lobby__sub-sep { display: none; }
  .nav { padding: 7px 8px 7px 10px; gap: 6px; }
  .nav__logo { font-size: 14px; letter-spacing: -0.02em; }
  .nav__links a { font-size: 9px; letter-spacing: 0.06em; padding: 9px 5px; }
}
@media (max-width: 360px) {
  /* Four labels plus the wordmark no longer fit — the mark carries the brand */
  .nav__logo { font-size: 0; }
  .nav__logo .reg { font-size: 15px; vertical-align: baseline; margin-left: 0; }
  .nav__links a { padding: 9px 4px; }
}


/* =====================================================================
   SHEET STATES — case study · about · contact
   Full-viewport scrollable panels over the held cinema frame.
   ===================================================================== */
.sheet {
  position: fixed; inset: 0; z-index: 30;
  opacity: 0; pointer-events: none;
  transition: opacity 700ms var(--ease-out);
}
.sheet::before {
  content: ''; position: absolute; inset: 0;
  background: rgba(0, 0, 0, 0.86);
  backdrop-filter: blur(40px) saturate(140%);
  -webkit-backdrop-filter: blur(40px) saturate(140%);
}
body[data-state="case"]    .sheet--case.is-open,
body[data-state="about"]   .sheet--about,
body[data-state="contact"] .sheet--contact { opacity: 1; pointer-events: auto; }

.sheet__scroll {
  position: absolute; inset: 0;
  overflow-y: auto; overscroll-behavior: contain;
  padding: calc(var(--pad-y) + 108px) var(--pad-x) calc(var(--pad-y) + 80px);
  scrollbar-width: thin; scrollbar-color: rgba(255,255,255,0.15) transparent;
}
.sheet__scroll::-webkit-scrollbar { width: 6px; }
.sheet__scroll::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.15); border-radius: 3px; }

.sheet__inner {
  position: relative;
  max-width: 1040px; margin: 0 auto;
  display: flex; flex-direction: column; gap: clamp(40px, 5vw, 76px);
}
.sheet__back {
  align-self: flex-start;
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--paper-mut);
  transition: color 240ms var(--ease-out);
}
.sheet__back:hover { color: var(--turquoise); }

.section-label { display: flex; align-items: center; gap: 18px; }
.section-label::after { content: ''; height: 1px; flex: 1; background: var(--line); }

/* ---- Media / content placeholders ---- */
.slot {
  position: relative;
  background: repeating-linear-gradient(135deg, rgba(255,255,255,0.05) 0 8px, rgba(255,255,255,0.015) 8px 16px);
  border: 1px dashed rgba(255,255,255,0.2);
  border-radius: var(--glass-radius);
  display: grid; place-items: center; text-align: center;
}
.slot span {
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.24em; line-height: 2;
  text-transform: uppercase; color: var(--paper-mut); padding: 0 22px;
}
.slot--player { aspect-ratio: 16 / 9; border-radius: var(--glass-radius-lg); }
.slot--still  { aspect-ratio: 4 / 5; }
.slot--wide   { aspect-ratio: 16 / 10; }
.slot--quote  { min-height: 190px; }

/* ---- Case study ---- */
.case__head { display: flex; flex-direction: column; gap: 18px; }
.case__title {
  font-family: var(--font-display); font-weight: 900; text-transform: uppercase;
  letter-spacing: -0.045em; line-height: 0.9;
  font-size: clamp(44px, 7vw, 104px); color: var(--paper);
}
.case__lede {
  font-size: clamp(16px, 1.4vw, 19px); line-height: 1.55;
  color: var(--paper-dim); max-width: 52ch; text-wrap: pretty;
}
.case__player { position: relative; width: 100%; overflow: hidden; border-radius: var(--glass-radius-lg); }
.case__player video { width: 100%; height: 100%; object-fit: cover; display: block; }

.facts {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 1px; background: var(--line);
  border: 1px solid var(--line); border-radius: var(--glass-radius); overflow: hidden;
}
.fact { background: rgba(255,255,255,0.02); padding: 24px 26px; display: flex; flex-direction: column; gap: 10px; }
.fact__k { font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.22em; text-transform: uppercase; color: var(--paper-mut); }
.fact__v { font-size: 15px; line-height: 1.5; color: var(--paper); }
.fact--result { background: var(--turquoise-soft); }
.fact--result .fact__v {
  font-family: var(--font-display); font-weight: 800; letter-spacing: -0.03em;
  font-size: clamp(30px, 3.4vw, 44px); line-height: 1; color: var(--turquoise);
}
.fact__note { font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--paper-mut); }

.case__cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: clamp(28px, 4vw, 56px); }
.case__col { display: flex; flex-direction: column; gap: 14px; }
.case__h {
  font-family: var(--font-display); font-weight: 700; text-transform: uppercase;
  letter-spacing: -0.02em; font-size: 20px; color: var(--paper);
}
.case__p { font-size: 15px; line-height: 1.65; color: var(--paper-dim); text-wrap: pretty; max-width: 58ch; }

.section-label__link {
  order: 1;
  color: rgba(255,255,255,0.42);
  text-decoration: none;
  letter-spacing: 0.04em;
  transition: color 0.25s ease;
}
.section-label__link:hover { color: rgba(255,255,255,0.75); }

.reels { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
@media (max-width: 720px) {
  .reels {
    grid-template-columns: none;
    grid-auto-flow: column;
    grid-auto-columns: 78%;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 4px;
  }
  .reels::-webkit-scrollbar { display: none; }
  .reel { scroll-snap-align: center; }
}
.reel {
  position: relative;
  aspect-ratio: 9 / 16;
  border: 1px solid var(--line);
  border-radius: var(--glass-radius);
  overflow: hidden;
  background: #000;
}
/* Crop Instagram's embed chrome: scale the iframe up so the 9:16 video fills
   the frame and the white header/footer + black side bars fall outside it. */
.reel iframe {
  position: absolute;
  left: -25%; top: -14%;
  width: 150%; height: 250%;
  border: 0; display: block;
}

.proof  { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 16px; }
.stills { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 16px; }
.still {
  position: relative; overflow: hidden;
  border: 1px solid var(--line); border-radius: var(--glass-radius); background: #000;
  aspect-ratio: 4 / 5;
  transition: border-color 0.35s ease, box-shadow 0.45s ease, transform 0.45s ease;
}
.still--video { cursor: pointer; }
.still--video:hover, .still--video:focus-within {
  border-color: rgba(64, 224, 208, 0.45);
  box-shadow: 0 0 0 1px rgba(64, 224, 208, 0.25), 0 18px 60px -18px rgba(64, 224, 208, 0.55);
  transform: translateY(-3px);
}
.still video { transition: filter 0.45s ease, transform 0.6s ease; filter: saturate(0.85) brightness(0.82); }
.still--video:hover video, .still--video:focus-within video { filter: none; transform: scale(1.03); }
.still--video.is-touch video { filter: none; }
/* Touch: explicit play affordance over the poster frame */
.still__play {
  position: absolute; left: 50%; top: 50%;
  translate: -50% -50%;
  width: 52px; height: 52px;
  display: grid; place-items: center;
  border: 1px solid rgba(255,255,255,0.55);
  border-radius: 50%;
  background: rgba(0,0,0,0.34);
  backdrop-filter: blur(6px);
  pointer-events: none;
  transition: opacity 260ms var(--ease-out);
  z-index: 2;
}
.still__play::before {
  content: '';
  width: 0; height: 0;
  margin-left: 4px;
  border-left: 13px solid var(--paper);
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
}
.still--video.is-playing .still__play { opacity: 0; }
.still video { width: 100%; height: 100%; object-fit: cover; object-position: 50% 0%; display: block; }

/* Photo stills — same frame, gentler treatment than the BTS clips */
.still img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  filter: saturate(0.92) brightness(0.9);
  transition: filter 0.45s ease, transform 0.6s ease;
}
.still--photo:hover img, .still--photo:focus-within img { filter: none; transform: scale(1.03); }
.still--photo:hover { border-color: rgba(255,255,255,0.22); transform: translateY(-3px); }
.stills--wide { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.stills--wide .still { aspect-ratio: 3 / 2; }
.still--band { aspect-ratio: 21 / 9; }
/* Whole frame, uncropped — height follows the image */
.still--full { aspect-ratio: auto; }
.still--full img { height: auto; object-fit: contain; }
/* Orientation-aware photo cells — a landscape photo must not inherit the 9:16 reel shape */
.still--land { aspect-ratio: 3 / 2; }
.still--port { aspect-ratio: 2 / 3; }
.still--tall { aspect-ratio: 9 / 16; }
/* Explicit column counts: auto-fit collapsed 3-up rows to 2 cols and orphaned the last cell */
.stills--trio { grid-template-columns: repeat(3, 1fr); }
.stills--port { grid-template-columns: repeat(3, 1fr); }
/* Collage row: 5 across, so ten portraits fill two rows exactly */
.stills--five { grid-template-columns: repeat(5, 1fr); }
.stills--five .still { aspect-ratio: 2 / 3; }
/* One ratio per row — mixed ratios left dead space under the shorter cells */
.stills--port .still { aspect-ratio: 2 / 3; }
.stills--trio .still { aspect-ratio: 3 / 2; }
.stills--wide { align-items: start; }
@media (max-width: 900px) {
  .stills--trio, .stills--port { grid-template-columns: repeat(2, 1fr); }
  .stills--five { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .stills--trio, .stills--port { grid-template-columns: 1fr; }
  .stills--five { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 700px) {
  .still--band { aspect-ratio: 4 / 3; }
}

.closer {
  display: flex; flex-direction: column; gap: 14px;
  padding: clamp(28px, 3.4vw, 48px) clamp(26px, 3vw, 44px);
  border: 1px solid var(--line); border-radius: var(--glass-radius);
  background: rgba(255,255,255,0.02);
}
.closer__text {
  font-size: clamp(19px, 2.1vw, 27px); line-height: 1.4;
  color: var(--paper); max-width: 44ch; text-wrap: pretty;
}
.closer__ask {
  font-family: var(--font-display); font-weight: 800; text-transform: uppercase;
  letter-spacing: -0.03em; line-height: 1;
  font-size: clamp(28px, 4vw, 52px); color: var(--turquoise);
}

.case__foot {
  display: flex; flex-wrap: wrap; gap: 18px; justify-content: space-between; align-items: center;
  padding-top: 30px; border-top: 1px solid var(--line);
}

/* ---- About: crossfading portrait, 5s a frame, 0.5s dissolve ---- */
.pfp {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: #000;
  border: 1px solid rgba(255,255,255,0.10);
}
.pfp__frame {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.5s linear;
}
.pfp__frame.is-on { opacity: 1; }
/* Chin-in-hand frame is much taller than 3:4 — fill, but anchor to the top so the head stays whole */
.pfp__frame:nth-child(5) { object-position: 50% 0%; }
@media (prefers-reduced-motion: reduce) {
  .pfp__frame { transition: none; }
}

/* ---- About ---- */
.about__grid { display: grid; grid-template-columns: minmax(230px, 330px) 1fr; gap: clamp(28px, 4vw, 64px); align-items: start; }
.about__copy { display: flex; flex-direction: column; gap: 20px; }
.about__title {
  font-family: var(--font-display); font-weight: 900; text-transform: uppercase;
  letter-spacing: -0.04em; line-height: 0.92; font-size: clamp(34px, 4.4vw, 60px); color: var(--paper);
}
.about__p { font-size: 16px; line-height: 1.65; color: var(--paper-dim); max-width: 56ch; text-wrap: pretty; }
.about__list { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 20px; margin-top: 6px; }
.about__item { display: flex; flex-direction: column; gap: 8px; padding-top: 16px; border-top: 1px solid var(--line); }

/* ---- Client quote ---- */
.numbers {
  display: grid; grid-template-columns: 1fr; gap: 1px;
  background: var(--line);
  border: 1px solid var(--line); border-radius: var(--glass-radius); overflow: hidden;
  align-content: start;
}
.numbers__item {
  background: rgba(255,255,255,0.02);
  padding: clamp(20px, 2.2vw, 28px) clamp(22px, 2.4vw, 30px);
  display: flex; flex-direction: column; gap: 8px;
}
.numbers__v {
  font-family: var(--font-display); font-weight: 800; letter-spacing: -0.03em;
  font-size: clamp(30px, 3.4vw, 44px); line-height: 1; color: var(--turquoise);
}
.numbers__k { font-size: 15px; line-height: 1.4; color: var(--paper); }

.numbers--row { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 560px) { .numbers--row { grid-template-columns: 1fr; } }

.logos {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 1px; background: var(--line);
  border: 1px solid var(--line); border-radius: var(--glass-radius); overflow: hidden;
}
.logos__item {
  background: rgba(255,255,255,0.02);
  display: flex; align-items: center; justify-content: center;
  padding: clamp(28px, 3vw, 40px) clamp(24px, 2.6vw, 34px);
  min-height: 190px;
}
.logos__item img {
  max-width: 100%; max-height: 44px; width: auto; height: auto;
  object-fit: contain; display: block;
  opacity: 0.62; transition: opacity 0.3s ease;
}
.logos__item:hover img { opacity: 1; }
.logos__invert { filter: invert(1); }
.logos__item img.logos__mark { max-height: 78px; }
.logos__item img.logos__lg { max-height: 160px; }
.logos__item img.logos__md { max-height: 100px; }
.logos__item img.logos__sm { max-height: 80px; }
.logos__names { color: var(--paper-mut); line-height: 1.8; }
@media (max-width: 900px) { .logos { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .logos { grid-template-columns: repeat(2, 1fr); } .logos__item { min-height: 120px; padding: 22px 18px; } .logos__item img.logos__lg { max-height: 92px; } }

.quote {
  display: flex; flex-direction: column; gap: 16px; margin: 0;
  padding: clamp(22px, 2.4vw, 32px);
  border: 1px solid var(--glass-border);
  border-radius: var(--glass-radius);
  background: var(--glass-bg);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.08);
}
.quote__stars { display: flex; gap: 5px; }
.quote__stars svg { width: 15px; height: 15px; fill: var(--turquoise); }
.quote__text {
  margin: 0; text-wrap: pretty;
  font-family: var(--font-display); font-weight: 700; letter-spacing: -0.02em;
  font-size: clamp(19px, 1.9vw, 27px); line-height: 1.28; color: var(--paper);
}
.quote__by { display: flex; flex-direction: column; gap: 5px; }
.quote__handle {
  font-size: 14px; color: var(--paper-mut); text-decoration: none;
  transition: color 240ms var(--ease-out);
}
.quote__handle:hover { color: var(--turquoise); }

/* ---- Namesake frame ---- */
.namesake {
  display: grid; grid-template-columns: minmax(240px, 420px) 1fr;
  gap: clamp(24px, 3vw, 44px); align-items: center;
  padding: clamp(18px, 2vw, 28px);
  text-decoration: none; color: inherit;
  border: 1px solid var(--glass-border);
  border-radius: var(--glass-radius);
  background: var(--glass-bg);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.08);
  transition: border-color 260ms var(--ease-out), box-shadow 260ms var(--ease-out), transform 260ms var(--ease-out);
}
.namesake:hover {
  border-color: var(--turquoise);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.14), 0 0 34px var(--turquoise-glow);
}
.namesake__img { width: 100%; display: block; border-radius: 6px; }
.namesake__meta { display: flex; flex-direction: column; gap: 14px; }
.namesake__cta {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-mono, inherit); font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--turquoise);
}
@media (max-width: 720px) { .namesake { grid-template-columns: 1fr; } }

/* ---- Contact ---- */
.contact__email {
  font-family: var(--font-display); font-weight: 800; letter-spacing: -0.03em;
  font-size: clamp(24px, 4.4vw, 60px); color: var(--paper); word-break: break-word;
  transition: color 240ms var(--ease-out);
}
.contact__email:hover { color: var(--turquoise); }

/* Mail picker — desktop click offers webmail; touch goes straight to mailto */
.mailpick { position: relative; display: inline-block; max-width: 100%; }
.mailpick__menu {
  position: absolute; left: 0; top: calc(100% + 10px); z-index: 30;
  display: flex; flex-direction: column; min-width: 200px;
  padding: 6px; gap: 2px;
  background: var(--glass-bg-deeper, rgba(16,16,18,0.92));
  border: 1px solid var(--line); border-radius: 10px;
  backdrop-filter: blur(18px);
  box-shadow: 0 18px 44px rgba(0,0,0,0.44);
  opacity: 0; visibility: hidden; transform: translateY(-6px);
  transition: opacity 200ms var(--ease-out), transform 200ms var(--ease-out), visibility 200ms;
}
.mailpick.is-open .mailpick__menu { opacity: 1; visibility: visible; transform: none; }
.mailpick--up .mailpick__menu { top: auto; bottom: calc(100% + 10px); transform: translateY(6px); }
.mailpick--up.is-open .mailpick__menu { transform: none; }
.mailpick__opt {
  appearance: none; background: none; border: 0; text-align: left;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--paper); padding: 11px 14px; border-radius: 6px; cursor: pointer;
  transition: color 160ms var(--ease-out), background 160ms var(--ease-out);
}
.mailpick__opt:hover { color: var(--turquoise); background: var(--turquoise-soft); }
@media (max-width: 560px) {
  .contact__email { font-size: clamp(20px, 7.4vw, 34px); line-height: 1.1; }
  .mailpick { display: block; width: 100%; }
  .mailpick__menu { left: 0; right: 0; min-width: 0; }
  .mailpick__opt { font-size: 12px; padding: 14px 16px; }
}
.contact__rows { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 24px; }
.contact__row { display: flex; flex-direction: column; gap: 8px; padding-top: 18px; border-top: 1px solid var(--line); }
.contact__row a { transition: color 240ms var(--ease-out); }
.contact__row a:hover { color: var(--turquoise); }

/* ---- Booking ---- */
.booking { display: flex; flex-direction: column; gap: 18px; align-items: flex-start; }
.booking__p { margin: 0; max-width: 52ch; font-size: 15px; line-height: 1.6; color: var(--paper-dim, var(--paper)); text-wrap: pretty; }
.booking__q {
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--paper-mut);
}
.booking__chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: -8px; }
.booking__other {
  width: min(320px, 100%); margin-top: -6px;
  font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.06em;
  color: var(--paper); background: var(--glass-bg, rgba(255,255,255,0.05));
  border: 1px solid var(--line); border-radius: 999px;
  padding: 13px 18px; min-height: 44px; outline: none;
  transition: border-color 180ms var(--ease-out), box-shadow 180ms var(--ease-out);
}
.booking__other::placeholder { color: var(--paper-mut); }
.booking__other:focus { border-color: var(--turquoise); box-shadow: 0 0 22px var(--turquoise-glow); }
.booking__other[hidden] { display: none; }
.chip {
  appearance: none; cursor: pointer;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--paper); background: var(--glass-bg, rgba(255,255,255,0.05));
  border: 1px solid var(--line); border-radius: 999px;
  padding: 11px 18px; min-height: 44px;
  transition: color 180ms var(--ease-out), border-color 180ms var(--ease-out), background 180ms var(--ease-out);
}
.chip:hover { border-color: var(--turquoise); color: var(--turquoise); }
.chip[aria-checked="true"] {
  color: var(--turquoise); border-color: var(--turquoise); background: var(--turquoise-soft);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.14), 0 0 22px var(--turquoise-glow);
}
.btn--accent {
  color: var(--turquoise);
  border-color: var(--turquoise);
  background: var(--turquoise-soft);
}
.btn--accent:hover { box-shadow: inset 0 1px 0 rgba(255,255,255,0.16), 0 0 30px var(--turquoise-glow); }

/* ---- Socials ---- */.socials { display: flex; flex-direction: column; gap: 16px; }
.socials__list { display: flex; flex-wrap: wrap; gap: 12px; }
.social {
  display: inline-flex; align-items: center; gap: 12px;
  padding: 13px 20px 13px 16px;
  border: 1px solid var(--line); border-radius: 999px;
  color: var(--paper); text-decoration: none;
  font-size: 15px; letter-spacing: -0.01em;
  background: var(--glass-bg);
  backdrop-filter: blur(28px) saturate(180%);
  -webkit-backdrop-filter: blur(28px) saturate(180%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.10), 0 8px 24px rgba(0,0,0,0.35);
  transition: color 240ms var(--ease-out), border-color 240ms var(--ease-out), background 240ms var(--ease-out), box-shadow 240ms var(--ease-out);
}
.social:hover {
  color: var(--turquoise);
  border-color: var(--turquoise);
  background: var(--turquoise-soft);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.16), 0 0 28px var(--turquoise-glow);
}
.social__logo { width: 20px; height: 20px; flex: none; }

/* ---- A CTA with nothing behind it yet ---- */
.btn.is-disabled { opacity: 0.4; pointer-events: none; }

@media (max-width: 880px) {
  .about__grid { grid-template-columns: 1fr; }
  .sheet__scroll { padding-top: calc(var(--pad-y) + 92px); }
}


/* =====================================================================
   STAGE STATES — press a project: the sidebar animates out to the left,
   the featured background image STAYS, everything else stages in over it.
     body[data-state="feature"] → full-bleed featured frame (no case study yet)
     body[data-state="case"]    → same, with the case study staged over the image
   ===================================================================== */
.projects { transition: opacity 700ms var(--ease-out), grid-template-columns 760ms var(--ease-out); }
.projects__sidebar { transition: transform 760ms var(--ease-out), opacity 520ms var(--ease-out); will-change: transform; }

body[data-state="feature"] .projects,
body[data-state="case"]    .projects {
  opacity: 1; pointer-events: auto;
  grid-template-columns: 0 1fr;
}
body[data-state="feature"] .projects__sidebar,
body[data-state="case"]    .projects__sidebar {
  transform: translateX(-102%);
  opacity: 0;
  pointer-events: none;
}

/* In the case state the image carries the page — hide the featured overlay text */
body[data-state="case"] .projects__featured-head,
body[data-state="case"] .projects__featured-foot {
  opacity: 0; pointer-events: none;
  transition: opacity 380ms var(--ease-out);
}

/* Lighter scrim than the other sheets so the project image reads through */
.sheet--case::before {
  background: linear-gradient(90deg, rgba(0,0,0,0.91) 0%, rgba(0,0,0,0.82) 52%, rgba(0,0,0,0.66) 100%);
  backdrop-filter: blur(10px) saturate(120%);
  -webkit-backdrop-filter: blur(10px) saturate(120%);
}

/* Case content stages in, block by block */
@keyframes stageIn { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
body[data-state="case"] .sheet--case .sheet__inner > * { animation: stageIn 720ms var(--ease-out) backwards; }
body[data-state="case"] .sheet--case .sheet__inner > *:nth-child(1) { animation-delay: 200ms; }
body[data-state="case"] .sheet--case .sheet__inner > *:nth-child(2) { animation-delay: 280ms; }
body[data-state="case"] .sheet--case .sheet__inner > *:nth-child(3) { animation-delay: 360ms; }
body[data-state="case"] .sheet--case .sheet__inner > *:nth-child(4) { animation-delay: 440ms; }
body[data-state="case"] .sheet--case .sheet__inner > *:nth-child(5) { animation-delay: 520ms; }
body[data-state="case"] .sheet--case .sheet__inner > *:nth-child(6) { animation-delay: 600ms; }
body[data-state="case"] .sheet--case .sheet__inner > *:nth-child(7) { animation-delay: 660ms; }
body[data-state="case"] .sheet--case .sheet__inner > *:nth-child(8) { animation-delay: 720ms; }
body[data-state="case"] .sheet--case .sheet__inner > *:nth-child(9) { animation-delay: 770ms; }
body[data-state="case"] .sheet--case .sheet__inner > *:nth-child(n+10) { animation-delay: 820ms; }

/* Floating back control for the full-bleed featured state */
.stage-back {
  position: fixed;
  top: calc(var(--pad-y) + 96px); left: var(--pad-x);
  z-index: 60;
  opacity: 0; pointer-events: none;
  transform: translateX(-10px);
  transition: opacity 480ms var(--ease-out) 300ms, transform 480ms var(--ease-out) 300ms;
}
body[data-state="feature"] .stage-back { opacity: 1; pointer-events: auto; transform: none; }


/* =====================================================================
   FULL-BLEED FEATURED MEDIA
   .projects__bg is now a direct child of .projects, so the image/video
   covers the whole viewport and the sidebar's glass has something to blur.
   ===================================================================== */
.projects__bg { position: absolute; inset: 0; z-index: 0; }
.projects__featured { background: none; }
.projects__sidebar {
  background: rgba(0, 0, 0, 0.38);
  backdrop-filter: blur(48px) saturate(150%);
  -webkit-backdrop-filter: blur(48px) saturate(150%);
}
/* Keep the sidebar column legible over bright frames */
.projects__bg::after {
  background:
    linear-gradient(180deg, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0.15) 30%, rgba(0,0,0,0.15) 60%, rgba(0,0,0,0.55) 100%),
    linear-gradient(90deg, rgba(0,0,0,0.5) 0%, transparent 34%, transparent 66%, rgba(0,0,0,0.4) 100%);
}


/* ---- About: turquoise haze as the backdrop ---- */
.sheet--about {
  background-image: url('../img/about-bg.jpg');
  background-size: cover;
  background-position: 20% 50%;
}
/* Heavier on the right, where the haze is brightest, so the copy holds */
.sheet--about::before {
  background: linear-gradient(100deg, rgba(0,0,0,0.90) 0%, rgba(0,0,0,0.74) 45%, rgba(0,0,0,0.44) 100%);
  backdrop-filter: blur(3px) saturate(115%);
  -webkit-backdrop-filter: blur(3px) saturate(115%);
}

/* ---- Contact: BTS frame as the backdrop ---- */
.sheet--contact {
  background-image: url('../img/bts-shot.jpg');
  background-size: cover;
  background-position: 50% 42%;
}
.sheet--contact::before {
  background: linear-gradient(90deg, rgba(0,0,0,0.90) 0%, rgba(0,0,0,0.78) 46%, rgba(0,0,0,0.52) 100%);
  backdrop-filter: blur(6px) saturate(115%);
  -webkit-backdrop-filter: blur(6px) saturate(115%);
}

.about__p .hl {
  font-style: normal;
  color: var(--turquoise);
  font-weight: 600;
}


/* =====================================================================
   LIGHTBOX — press a photo still, it flies forward to full size.
   ===================================================================== */
.still--photo { cursor: zoom-in; }

.lightbox {
  position: fixed; inset: 0; z-index: 900;
  display: grid; place-items: center;
  /* Bottom band is reserved for the caption, so the frame can never sit on it */
  padding: 4dvh 4vw 56px;
  opacity: 0; pointer-events: none;
  transition: opacity 220ms ease;
}
.lightbox.is-open { opacity: 1; pointer-events: auto; }
.lightbox__scrim {
  position: absolute; inset: 0;
  background: rgba(0, 0, 0, 0.88);
  backdrop-filter: blur(14px) saturate(0.9);
  -webkit-backdrop-filter: blur(14px) saturate(0.9);
  border: 0; cursor: zoom-out;
}
.lightbox__img {
  position: relative;
  max-width: min(1400px, 92vw); max-height: calc(88dvh - 44px);
  width: auto; height: auto;
  object-fit: contain;
  display: block;
  border: 1px solid var(--line-2);
  border-radius: 6px;
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.7);
  transform-origin: top left;
  will-change: transform;
}
.lightbox__close {
  position: absolute; top: 18px; right: 20px;
  width: 40px; height: 40px;
  display: grid; place-items: center;
  color: var(--paper-dim);
  border: 1px solid var(--line-2); border-radius: 50%;
  background: var(--glass-bg, rgba(255,255,255,0.06));
  backdrop-filter: blur(10px);
  transition: color 200ms ease, border-color 200ms ease, transform 200ms ease;
}
.lightbox__close:hover { color: var(--turquoise); border-color: var(--turquoise); transform: rotate(90deg); }
.lightbox__cap {
  position: absolute; left: 0; right: 0; bottom: 16px;
  text-align: center;
  color: var(--paper-mut);
  padding: 0 24px;
}
body.is-lightboxed { overflow: hidden; }
@media (max-width: 700px) {
  .lightbox { padding: 2dvh 2vw 52px; }
  .lightbox__img { max-width: 96vw; max-height: calc(82dvh - 40px); }
}
@media (prefers-reduced-motion: reduce) {
  .lightbox__img { transition: none !important; }
}
