/* ================================================================
   GIULIO AMENDOLAGINE — Cinematographer
   styles.css
   ================================================================ */

/* ── RESET ───────────────────────────────────────────────────── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* ── SITE COLOUR ─────────────────────────────────────────────── */
:root {
  --site-bg: #ffffff;
  --site-border: #eeeeee;
}

/* ── BASE ────────────────────────────────────────────────────── */
html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100%;
  background: var(--site-bg);
}

body {
  background: var(--site-bg);
  color: #111111;
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 400;
  overflow-x: clip;
}

#page-wrapper {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--site-bg);
}

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

html:not(.native-cursor) body,
html:not(.native-cursor) a,
html:not(.native-cursor) button,
html:not(.native-cursor) [href],
html:not(.native-cursor) .nav__link,
html:not(.native-cursor) .mobile-menu__link,
html:not(.native-cursor) .hero__play,
html:not(.native-cursor) .hero__view-work,
html:not(.native-cursor) .hero__close,
html:not(.native-cursor) .card,
html:not(.native-cursor) .card__thumb {
  cursor: none;
}

.cursor {
  position: fixed;
  top: 0;
  left: 0;
  width: 60px;
  height: 60px;
  background: #111111;
  border: 1px solid rgba(255, 255, 255, 0.85);
  border-radius: 50%;
  pointer-events: none;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Inter', sans-serif;
  font-size: 0;
  color: #111111;
  transform: translate3d(-100px, -100px, 0) scale(0.133);
  transform-origin: center center;
  will-change: transform;
  contain: layout style;
  transition: background 0.1s ease, border-color 0.1s ease, color 0.1s ease;
  backface-visibility: hidden;
}

.cursor.is-hidden {
  display: none;
}

.cursor--active {
  background: transparent;
  border: 1px solid #111111;
  font-size: 0.55rem;
  letter-spacing: 0.15em;
}

.cursor--active.cursor--light {
  background: transparent;
  border-color: rgba(255, 255, 255, 0.88);
  color: #ffffff;
}

html.native-cursor .cursor {
  display: none;
}

/* ================================================================
   INTRO
   ================================================================ */

body.intro-active .cursor {
  opacity: 0;
  visibility: hidden;
}

body.intro-active {
  overflow: hidden;
  background: #ffffff;
}

/* ── Overlay ─────────────────────────────────────────────────── */
#intro-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #ffffff;
  z-index: 9999;
  align-items: center;
  justify-content: center;
}

/* Hide nav border during intro — it would flash distractingly */
body.intro-active .nav {
  border-bottom: none !important;
  box-shadow: none !important;
}

body.intro-active #intro-overlay {
  display: flex;
}

/* ── Name typography ─────────────────────────────────────────── */
#intro-name {
  display: flex;
  flex-wrap: wrap;
  gap: 2.5em;
  align-items: baseline;
  justify-content: center;
}

/* Each word is a clipping mask for the rising inner element */
.intro-word {
  overflow: hidden;
  display: inline-block;
}

.intro-word-inner {
  display: block;
  transform: translateY(105%);
  opacity: 0;
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 56px;
  font-weight: 300;
  letter-spacing: 0.3em;
  color: #111111;
  white-space: nowrap;
}

/* ── Page wrapper ────────────────────────────────────────────── */

body.intro-active:not(.intro-video-in) #page-wrapper {
  opacity: 0;
  pointer-events: none;
}

body.intro-active.intro-video-in #page-wrapper {
  opacity: 1;
  pointer-events: auto;
  transition: opacity 1.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ── Header reveal ───────────────────────────────────────────── */
body.intro-active .nav {
  border-bottom-color: transparent !important;
  pointer-events: none;
}

.nav__identity,
.nav__sticky,
.nav::before,
.nav::after {
  transition:
    opacity 2.1s cubic-bezier(0.16, 1, 0.3, 1),
    transform 2.1s cubic-bezier(0.16, 1, 0.3, 1);
}

body.site-home:not(.nav-visible) .nav__identity,
body.site-home:not(.nav-visible) .nav__sticky {
  opacity: 0;
  transform: translateY(28px);
}

body.site-home:not(.nav-visible) .nav::before,
body.site-home:not(.nav-visible) .nav::after {
  opacity: 0;
}

body.site-home:not(.nav-visible) .hero__view-work {
  opacity: 0;
  transform: translateY(20px);
}

body.nav-visible .nav__identity {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.35s;
}

body.nav-visible .nav__sticky {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.65s;
}

body.nav-visible .nav::before,
body.nav-visible .nav::after {
  opacity: 1;
  transition-delay: 0.2s;
}

body.nav-visible .nav,
body.nav-visible .hero__view-work {
  pointer-events: auto;
}

body.nav-visible .hero__view-work {
  opacity: 1;
  transform: translateY(0);
  transition:
    opacity 1.8s cubic-bezier(0.16, 1, 0.3, 1),
    transform 1.8s cubic-bezier(0.16, 1, 0.3, 1);
  transition-delay: 0.85s;
}

body.site-home:not(.nav-visible) .hero__view-work-text {
  transition: none;
}

body:not(.intro-active):not(.hero-cta-shown):not(.hero-cta-animate) .hero__view-work-text {
  opacity: 0;
  transform: translateY(16px);
}

body.hero-cta-animate .hero__view-work-text {
  animation: heroCtaReveal 2.4s cubic-bezier(0.16, 1, 0.3, 1) 0.65s forwards;
}

body.hero-cta-shown .hero__view-work-text {
  opacity: 0.78;
  transform: translateY(0);
  letter-spacing: 0.28em;
}

@keyframes heroCtaReveal {
  from {
    opacity: 0;
    transform: translateY(16px);
    letter-spacing: 0.18em;
  }
  to {
    opacity: 0.78;
    transform: translateY(0);
    letter-spacing: 0.28em;
  }
}

#intro-overlay.is-exiting {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.55s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ── Work grid hidden until hero dismissed ───────────────────── */
body:not(.work-revealed) .grid .card {
  opacity: 0;
  pointer-events: none;
}

body.work-revealed:not(.grid-introduced) .grid .card {
  opacity: 1;
  pointer-events: auto;
  animation: cardReveal 0.55s cubic-bezier(0.22, 1, 0.36, 1) both;
}

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

body.work-revealed:not(.grid-introduced) .grid .card:nth-child(1)  { animation-delay: 0.02s; }
body.work-revealed:not(.grid-introduced) .grid .card:nth-child(2)  { animation-delay: 0.05s; }
body.work-revealed:not(.grid-introduced) .grid .card:nth-child(3)  { animation-delay: 0.08s; }
body.work-revealed:not(.grid-introduced) .grid .card:nth-child(4)  { animation-delay: 0.11s; }
body.work-revealed:not(.grid-introduced) .grid .card:nth-child(5)  { animation-delay: 0.14s; }
body.work-revealed:not(.grid-introduced) .grid .card:nth-child(6)  { animation-delay: 0.17s; }
body.work-revealed:not(.grid-introduced) .grid .card:nth-child(7)  { animation-delay: 0.20s; }
body.work-revealed:not(.grid-introduced) .grid .card:nth-child(8)  { animation-delay: 0.23s; }
body.work-revealed:not(.grid-introduced) .grid .card:nth-child(9)  { animation-delay: 0.26s; }
body.work-revealed:not(.grid-introduced) .grid .card:nth-child(10) { animation-delay: 0.29s; }
body.work-revealed:not(.grid-introduced) .grid .card:nth-child(11) { animation-delay: 0.32s; }
body.work-revealed:not(.grid-introduced) .grid .card:nth-child(12) { animation-delay: 0.35s; }

body.work-revealed.grid-introduced .grid .card {
  opacity: 1;
  pointer-events: auto;
}

body.view-filter .about {
  display: none;
}

/* ================================================================
   NAVIGATION
   ================================================================ */
.nav {
  position: sticky;
  top: 0;
  z-index: 600;
  background: transparent;
  border-bottom: none;
  height: 120px;
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

/* Homepage — name scrolls away; tabs bar sticks */
.nav:has(.nav__sticky) {
  position: relative;
  top: auto;
  height: auto;
  display: block;
}

.nav:has(.nav__sticky) .nav__inner {
  gap: 0;
  padding: 0;
  position: relative;
  z-index: 1;
}

.nav:has(.nav__sticky) .nav__identity {
  padding: 28px 40px 18px;
}

.nav__sticky {
  position: sticky;
  top: 0;
  z-index: 601;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 14px 40px 16px;
}

.nav::before,
.nav__sticky::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--site-bg);
  z-index: -1;
  pointer-events: none;
  transition:
    background 0.45s ease,
    backdrop-filter 0.45s ease,
    opacity 2.1s cubic-bezier(0.16, 1, 0.3, 1),
    transform 2.1s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav::after,
.nav__sticky::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: var(--site-border);
  pointer-events: none;
  transition:
    background 0.45s ease,
    opacity 2.1s cubic-bezier(0.16, 1, 0.3, 1),
    transform 2.1s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Homepage at top — one unified translucent bar over the reel */
body:not(.work-revealed):not(.nav-tabs-pinned) .nav:has(.nav__sticky)::before {
  background: linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0.72) 0%,
    rgba(255, 255, 255, 0.52) 100%
  );
  backdrop-filter: blur(14px) saturate(1.05);
  -webkit-backdrop-filter: blur(14px) saturate(1.05);
}

body:not(.work-revealed):not(.nav-tabs-pinned) .nav:has(.nav__sticky)::after {
  background: rgba(255, 255, 255, 0.35);
}

/* Homepage scrolled — only the tab row keeps the backdrop */
.nav:has(.nav__sticky) .nav__sticky::before,
.nav:has(.nav__sticky) .nav__sticky::after {
  content: none;
}

body.nav-tabs-pinned .nav:has(.nav__sticky)::before,
body.nav-tabs-pinned .nav:has(.nav__sticky)::after {
  content: none;
}

body.nav-tabs-pinned:not(.work-revealed) .nav__sticky::before {
  content: '';
  background: linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0.78) 0%,
    rgba(255, 255, 255, 0.58) 100%
  );
  backdrop-filter: blur(14px) saturate(1.05);
  -webkit-backdrop-filter: blur(14px) saturate(1.05);
}

body.nav-tabs-pinned:not(.work-revealed) .nav__sticky::after {
  content: '';
  background: rgba(255, 255, 255, 0.35);
}

/* Over hero reel — other pages / project nav */
body:not(.work-revealed) .nav:not(:has(.nav__sticky))::before {
  background: linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0.72) 0%,
    rgba(255, 255, 255, 0.52) 100%
  );
  backdrop-filter: blur(14px) saturate(1.05);
  -webkit-backdrop-filter: blur(14px) saturate(1.05);
}

body:not(.work-revealed) .nav:not(:has(.nav__sticky))::after {
  background: rgba(255, 255, 255, 0.35);
}

body.work-revealed .nav:not(:has(.nav__sticky))::before {
  background: var(--site-bg);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

body.work-revealed .nav:not(:has(.nav__sticky))::after {
  background: var(--site-border);
}

body.work-revealed:not(.nav-tabs-pinned) .nav:has(.nav__sticky)::before {
  background: var(--site-bg);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

body.work-revealed:not(.nav-tabs-pinned) .nav:has(.nav__sticky)::after {
  background: var(--site-border);
}

body.work-revealed.nav-tabs-pinned .nav__sticky::before {
  content: '';
  background: var(--site-bg);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

body.work-revealed.nav-tabs-pinned .nav__sticky::after {
  content: '';
  background: var(--site-border);
}

.nav__inner {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
  padding: 0 40px;
  position: relative;
  will-change: opacity, transform;
}

/* Row 1: Identity */
.nav__identity {
  display: flex;
  align-items: baseline;
  gap: 14px;
}

/* Identity as link (project pages) */
.nav__identity-link {
  display: flex;
  align-items: baseline;
  gap: 14px;
  text-decoration: none;
  color: inherit;
}

.nav__name {
  font-family: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
  font-size: 1.35rem;
  font-weight: 600;
  letter-spacing: 0.32em;
  color: #0d0d0d;
  text-transform: uppercase;
  line-height: 1;
}

.nav__role {
  font-family: 'Manrope', 'Inter', system-ui, sans-serif;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  color: #7a7a7a;
  text-transform: uppercase;
  line-height: 1;
}

/* Row 2: Menu links */
.nav__menu {
  display: flex;
  align-items: center;
  gap: 42px;
}

.nav__link {
  font-family: 'Manrope', 'Inter', system-ui, sans-serif;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: #111111;
  line-height: 1;
  transition: opacity 0.35s ease, color 0.35s ease;
}

.nav__link:hover {
  opacity: 0.55;
}

.nav__link.is-active {
  opacity: 1;
  font-weight: 700;
}

.nav__link::after {
  content: '';
  display: block;
  width: 100%;
  height: 1px;
  background: currentColor;
  margin-top: 9px;
  transform: scaleX(0);
  transform-origin: center;
  opacity: 0;
  transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1),
              opacity 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav__link.is-active::after {
  transform: scaleX(1);
  opacity: 0.3;
}

.nav__menu .nav__link:not(.is-active) {
  opacity: 0.4;
}

/* Back link (project pages) */
.nav__back {
  position: absolute;
  left: 40px;
  top: 50%;
  transform: translateY(-50%);
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 400;
  font-size: 11px;
  letter-spacing: 0.22em;
  color: #999999;
  text-transform: uppercase;
  transition: color 0.3s ease;
}

.nav__back:hover {
  color: #111111;
}

/* Hamburger — hidden on desktop */
.nav__hamburger {
  display: none;
  position: absolute;
  right: 40px;
  top: 50%;
  transform: translateY(-50%);
  flex-direction: column;
  gap: 6px;
  width: 24px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px 0;
}

.nav__sticky .nav__hamburger {
  right: 40px;
}

.hamburger__line {
  display: block;
  width: 24px;
  height: 1px;
  background: #111111;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.nav__hamburger[aria-expanded="true"] .hamburger__line:nth-child(1) {
  transform: translateY(3.5px) rotate(45deg);
}

.nav__hamburger[aria-expanded="true"] .hamburger__line:nth-child(2) {
  transform: translateY(-3.5px) rotate(-45deg);
}

/* ================================================================
   MOBILE OVERLAY MENU
   ================================================================ */
.mobile-menu {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 200;
  background: var(--site-bg);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 36px;
}

.mobile-menu.is-open {
  display: flex;
}

.mobile-menu__close {
  position: absolute;
  top: 36px;
  right: 40px;
  background: none;
  border: none;
  cursor: pointer;
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 300;
  font-size: 18px;
  color: #333333;
}

.mobile-menu__nav {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 32px;
}

.mobile-menu__link {
  font-family: 'Manrope', 'Inter', system-ui, sans-serif;
  font-weight: 600;
  font-size: 12px;
  letter-spacing: 0.32em;
  color: #333333;
  text-transform: uppercase;
  transition: opacity 0.3s ease;
}

.mobile-menu__link:hover {
  opacity: 0.6;
}

/* ================================================================
   HERO OVERLAY
   ================================================================ */
.hero-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  background: transparent;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 500;
  opacity: 1;
  transition: opacity 1s cubic-bezier(0.4, 0, 0.2, 1);
}

.hero-overlay.is-hidden {
  opacity: 0;
  pointer-events: none;
}

body.scroll-locked {
  overflow: hidden;
}

/* ================================================================
   HERO — Static poster with inline showreel
   ================================================================ */
.hero {
  height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--site-bg);
  width: 100%;
}

.hero__poster {
  position: relative;
  width: 100%;
  flex: 1;
  overflow: hidden;
  background: var(--site-bg);
}


/* Video layer — sits above poster, fades in on play */
.hero__video {
  position: absolute;
  inset: 0;
  z-index: 3;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.7s ease;
}

.hero__video iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

.hero__poster.is-playing .hero__video {
  opacity: 1;
  pointer-events: auto;
}

/* Close button — revealed when video is playing */
.hero__close {
  position: absolute;
  top: 18px;
  right: 22px;
  z-index: 5;
  background: none;
  border: none;
  color: #ffffff;
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 300;
  font-size: 20px;
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
  line-height: 1;
  padding: 8px;
}

.hero__poster.is-playing .hero__close {
  opacity: 0.55;
  pointer-events: auto;
}

.hero__close:hover {
  opacity: 1 !important;
}

/* CTA group — lower third of hero */
.hero__ctas {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  padding-bottom: 13vh;
  gap: 26px;
  transition: opacity 0.4s ease;
  pointer-events: auto;
}

.hero__poster.is-playing .hero__ctas {
  opacity: 0;
  pointer-events: none;
}

/* Play Showreel button */
.hero__play {
  background: none;
  border: none;
  cursor: pointer;
  padding: 100px 150px 20px 150px;
  margin: -100px -150px -20px -150px;
  transition: transform 0.3s ease;
}

@keyframes heroPlayPulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.55; }
}

.hero__play-text {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.9rem;
  font-weight: 500;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: #1a1a1a;
  position: relative;
  padding-bottom: 7px;
  display: block;
  animation: heroPlayPulse 3.5s ease-in-out infinite;
  transition: letter-spacing 0.5s ease;
}

.hero__play:hover .hero__play-text {
  letter-spacing: 0.65em;
}

.hero__play-text::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left center;
  opacity: 0;
  transition: transform 0.45s ease, opacity 0.45s ease;
}

.hero__poster:not(.is-playing):hover .hero__play-text {
  animation-play-state: paused;
  opacity: 1;
}

.hero__poster:not(.is-playing):hover .hero__play-text::after {
  transform: scaleX(1);
  opacity: 1;
}

/* View Work link — lighter, secondary hierarchy */
.hero__view-work {
  display: block;
  text-decoration: none;
  padding: 16px 32px;
  margin: 0;
  will-change: opacity, transform;
}

.hero__view-work-text {
  font-family: 'Cormorant Garamond', serif;
  font-size: 0.92rem;
  font-weight: 300;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.72);
  display: inline-block;
  padding: 11px 26px;
  border: 1px solid rgba(255, 255, 255, 0.32);
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  box-shadow: none;
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.35);
  transition: color 0.4s ease, letter-spacing 0.5s ease, background 0.4s ease, border-color 0.4s ease, opacity 0.4s ease;
}

.hero__view-work:hover .hero__view-work-text {
  color: rgba(255, 255, 255, 0.9);
  letter-spacing: 0.32em;
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.48);
}

/* Fullscreen showreel state */
body.showreel-active {
  overflow: hidden;
}

body.showreel-active .hero__poster {
  height: 100%;
}

/* ================================================================
   WORK GRID
   ================================================================ */
.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
  width: min(100%, 1080px);
  margin: 2px auto 0;
  background: var(--site-bg);
  transform: scale(0.96);
  flex: 1 0 auto;
  align-content: start;
  transition:
    transform 1.2s cubic-bezier(0.22, 1, 0.36, 1),
    width 0.55s cubic-bezier(0.22, 1, 0.36, 1),
    max-width 0.55s cubic-bezier(0.22, 1, 0.36, 1);
  transform-origin: center top;
}

/* Symmetrical centred layouts per filter tab */
.grid[data-layout="commercial-corporate"],
.grid[data-layout="narrative-films"],
.grid[data-layout="all"] {
  grid-template-columns: repeat(3, 1fr);
  width: min(100%, 1080px);
  margin-left: auto;
  margin-right: auto;
}

.grid[data-layout="documentary"] {
  grid-template-columns: 1fr;
  width: min(100%, 360px);
  margin-left: auto;
  margin-right: auto;
}

body.work-revealed .grid {
  transform: scale(1);
}

/* ── CARD ─────────────────────────────────────────────────────── */
.card {
  display: block;
  position: relative;
  overflow: hidden;
  cursor: pointer;
  transform: translate3d(0, 0, 0);
  transform-origin: center center;
  transition:
    opacity 0.3s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.3s cubic-bezier(0.22, 1, 0.36, 1);
  backface-visibility: hidden;
}

.card.is-filter-entering {
  opacity: 0;
  transform: scale(0.985) translate3d(0, 5px, 0);
  pointer-events: none;
  transition: none;
}

.card.is-filter-entering.is-filter-reveal {
  opacity: 1;
  transform: translate3d(0, 0, 0);
  transition:
    opacity 0.48s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.48s cubic-bezier(0.22, 1, 0.36, 1);
}

.grid.is-filtering .card.is-flipping {
  transition-property: transform;
  transition-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
}

.grid.is-filtering {
  position: relative;
  transition:
    width 0.55s cubic-bezier(0.22, 1, 0.36, 1),
    max-width 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

.card__thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #000000;
}

.card__image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #1a1a1a;
  transition: opacity 0.4s ease;
}

.card__info {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 1rem;
  opacity: 0;
  transition: opacity 0.3s ease;
  background: rgba(0,0,0,0.5);
  color: #ffffff;
}

.card__title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  display: block;
  text-align: center;
}

.card__category {
  font-family: 'Cormorant Garamond', serif;
  font-size: 0.625rem;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  display: block;
  text-align: center;
  margin-top: 0.35rem;
  opacity: 0.7;
}

/* Hover state */
.card:hover .card__image {
  opacity: 0.4;
}

.card:hover .card__info {
  opacity: 1;
}

/* ── Per-card image framing ───────────────────────────────────── */
[data-project="after"] img {
  object-fit: cover;
  object-position: center center;
  transform: scale(1.4);
}

[data-project="bloom"] img {
  object-fit: cover;
  object-position: 70% center;
  transform: scale(1.3);
}

[data-project="art-exhibition"] img {
  object-position: center 60%;
  transform: scale(1.2);
}

[data-project="lucky-saints"] img {
  object-position: 60% center;
  transform: scale(1.1);
}

/* ================================================================
   ABOUT
   ================================================================ */
body.view-about #work {
  display: none;
}

body.view-about .about {
  animation: sectionFadeIn 0.55s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes sectionFadeIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.about {
  border-top: 1px solid var(--site-border);
  margin-top: 40px;
  background: var(--site-bg);
}

/* ── Hero image ─────────────────────────────────────────────── */
.about__hero {
  position: relative;
  width: 100%;
  height: 70vh;
  overflow: hidden;
}

.about__hero-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 45%;
  display: block;
}

.about__hero-gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 50%, rgba(0,0,0,0.5) 100%);
}

.about__hero-name {
  position: absolute;
  bottom: 20px;
  left: 24px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.about__hero-title {
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 300;
  font-size: 11px;
  letter-spacing: 0.25em;
  color: #ffffff;
  text-transform: uppercase;
  line-height: 1;
  opacity: 0.6;
}

.about__hero-role {
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 300;
  font-size: 9px;
  letter-spacing: 0.2em;
  color: #ffffff;
  opacity: 0.5;
  text-transform: uppercase;
}

/* ── Two-column body ────────────────────────────────────────── */
.about__body {
  max-width: 1100px;
  margin: 0 auto;
  padding: 80px 40px;
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 40px;
  align-items: start;
}

.about__text {
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 300;
  font-size: 16px;
  line-height: 1.9;
  color: #444444;
}

.about__contact {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: flex-end;
}

.about__email {
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 300;
  font-size: 12px;
  letter-spacing: 0.25em;
  color: #999999;
  transition: color 0.3s ease;
}

.about__email:hover {
  color: #111111;
}

.about__social {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: flex-end;
}

.about__social-link {
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 300;
  font-size: 12px;
  letter-spacing: 0.25em;
  color: #999999;
  text-transform: uppercase;
  transition: color 0.3s ease;
}

.about__social-link:hover {
  color: #111111;
}

/* ================================================================
   FOOTER
   ================================================================ */
.footer {
  flex-shrink: 0;
  margin-top: auto;
  border-top: 1px solid var(--site-border);
  background: var(--site-bg);
  padding: 56px 24px 48px;
}

.footer__inner {
  max-width: 720px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 28px;
  text-align: center;
}

.footer__signature {
  display: block;
  line-height: 0;
  opacity: 0.88;
  transition: opacity 0.35s ease;
}

.footer__signature:hover {
  opacity: 1;
}

.footer__signature-img {
  display: block;
  width: min(220px, 62vw);
  height: auto;
  margin: 0 auto;
}

.footer__social {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 22px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer__social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  color: #888888;
  transition: color 0.35s ease, transform 0.35s ease;
}

.footer__social-link:hover {
  color: #1a1a1a;
  transform: translateY(-1px);
}

.footer__icon {
  width: 18px;
  height: 18px;
}

.footer__icon rect,
.footer__icon circle:not([fill]) {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
}

.footer__icon path,
.footer__icon circle[fill] {
  fill: currentColor;
  stroke: none;
}

.footer__legal {
  margin: 0;
}

.footer__legal-link {
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 400;
  font-size: 10px;
  font-style: italic;
  letter-spacing: 0.04em;
  color: #ababab;
  text-decoration: none;
  transition: color 0.35s ease;
}

.footer__legal-link:hover {
  color: #666666;
}

/* ================================================================
   PROJECT DETAIL PAGES
   ================================================================ */
.project-page {
  max-width: 960px;
  margin: 0 auto;
  padding: 60px 40px 100px;
}

.project-hero {
  width: 100%;
  background: #000000;
}

.project-hero__media {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
}

.project-hero__placeholder {
  position: absolute;
  inset: 0;
  background: #1a1a1a;
}

.project-meta {
  display: flex;
  align-items: baseline;
  gap: 20px;
  margin: 48px 0 20px;
}

.project-meta__title {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-weight: 300;
  font-size: 40px;
  letter-spacing: 0.04em;
  color: #111111;
  line-height: 1.1;
}

.project-meta__category {
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 400;
  font-size: 11px;
  letter-spacing: 0.22em;
  color: #999999;
  text-transform: uppercase;
  white-space: nowrap;
}

.project-description {
  max-width: 620px;
  margin-top: 28px;
}

.project-description p {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-weight: 300;
  font-size: 18px;
  line-height: 1.75;
  color: #555555;
}

.project-description p + p {
  margin-top: 20px;
}

.project-gallery {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px;
  margin-top: 60px;
}

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

.project-gallery__item {
  position: relative;
  overflow: hidden;
}

.project-gallery__placeholder {
  width: 100%;
  aspect-ratio: 3 / 2;
  background: #e8e8e8;
  display: block;
}

.project-gallery__placeholder--tall {
  aspect-ratio: 2 / 3;
}

/* ================================================================
   TOUCH / NO-HOVER — always-readable project labels
   ================================================================ */
@media (hover: none), (pointer: coarse) {
  .card__info {
    opacity: 1;
    justify-content: flex-end;
    align-items: flex-start;
    text-align: left;
    padding: 48px 14px 14px;
    background: linear-gradient(
      to top,
      rgba(0, 0, 0, 0.72) 0%,
      rgba(0, 0, 0, 0.28) 42%,
      transparent 72%
    );
  }

  .card__title,
  .card__category {
    text-align: left;
  }

  .card__title {
    font-size: 0.78rem;
    letter-spacing: 0.18em;
  }

  .card:hover .card__image {
    opacity: 1;
  }
}

/* ================================================================
   RESPONSIVE — TABLET (≤ 768px)
   ================================================================ */
@media (max-width: 768px) {

  .intro-word-inner { font-size: 32px; }

  /* Mobile nav: no hamburger — show scrollable filter tabs instead */
  .nav__hamburger,
  .mobile-menu {
    display: none !important;
  }

  .nav:not(:has(.nav__sticky)) { height: 100px; }

  .nav__inner {
    gap: 10px;
    padding: 0;
  }

  .nav:has(.nav__sticky) .nav__identity {
    flex-direction: column;
    align-items: center;
    gap: 7px;
    padding: 16px 20px 6px;
    padding-left: max(20px, env(safe-area-inset-left));
    padding-right: max(20px, env(safe-area-inset-right));
  }

  .nav__identity-link {
    flex-direction: column;
    align-items: center;
    gap: 7px;
  }

  .nav__name {
    font-size: 0.95rem;
    letter-spacing: 0.18em;
    text-align: center;
  }

  .nav__role {
    display: block;
    font-size: 0.58rem;
    letter-spacing: 0.3em;
    color: #8a8a8a;
    text-align: center;
  }

  .nav__sticky {
    display: block;
    width: 100%;
    min-height: 0;
    padding: 2px 0 12px;
  }

  .nav__menu {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 22px;
    width: 100%;
    max-width: 100%;
    padding: 4px 20px 2px;
    padding-left: max(20px, env(safe-area-inset-left));
    padding-right: max(20px, env(safe-area-inset-right));
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    overscroll-behavior-x: contain;
  }

  .nav__menu::-webkit-scrollbar {
    display: none;
  }

  .nav__link {
    flex: 0 0 auto;
    white-space: nowrap;
    font-size: 0.62rem;
    letter-spacing: 0.16em;
    padding: 8px 0;
  }

  .nav__link::after {
    margin-top: 7px;
  }

  .nav__back { display: none; }

  .hero__ctas {
    padding-bottom: max(10vh, calc(24px + env(safe-area-inset-bottom)));
  }

  .hero__view-work {
    padding: 12px 16px;
  }

  .hero__view-work-text {
    font-size: 0.82rem;
    letter-spacing: 0.2em;
    padding: 12px 20px;
  }

  .grid,
  .grid[data-layout="commercial-corporate"],
  .grid[data-layout="narrative-films"],
  .grid[data-layout="all"] {
    grid-template-columns: repeat(2, 1fr);
    width: 100%;
    max-width: none;
    gap: 3px;
    margin-top: 8px;
  }

  .grid[data-layout="documentary"] {
    grid-template-columns: 1fr;
    width: min(100%, 520px);
  }

  .about__body {
    grid-template-columns: 1fr;
    padding: 60px 24px;
    padding-left: max(24px, env(safe-area-inset-left));
    padding-right: max(24px, env(safe-area-inset-right));
  }
  .about__contact { align-items: flex-start; }
  .about__social  { align-items: flex-start; }

  .footer {
    padding: 48px 20px 40px;
    padding-left: max(20px, env(safe-area-inset-left));
    padding-right: max(20px, env(safe-area-inset-right));
    padding-bottom: max(40px, calc(24px + env(safe-area-inset-bottom)));
  }

  .footer__signature-img {
    width: min(180px, 70vw);
  }
  .about__hero-name  { bottom: 24px; left: 24px; }
  .about__hero-title { font-size: 24px; }

  .project-page  { padding: 40px 24px 80px; }
  .project-meta  { flex-direction: column; gap: 8px; }
  .project-meta__title { font-size: 30px; }
  .project-gallery { grid-template-columns: 1fr; }
}

/* ================================================================
   RESPONSIVE — MOBILE (≤ 640px)
   ================================================================ */
@media (max-width: 640px) {

  .intro-word-inner { font-size: 24px; }

  .nav__name {
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 0.14em;
  }

  .nav__role {
    font-size: 0.55rem;
    letter-spacing: 0.28em;
  }

  .nav__menu {
    gap: 18px;
    padding-left: max(16px, env(safe-area-inset-left));
    padding-right: max(16px, env(safe-area-inset-right));
  }

  .nav__link {
    font-size: 0.58rem;
    letter-spacing: 0.14em;
    font-weight: 600;
  }

  .grid,
  .grid[data-layout="commercial-corporate"],
  .grid[data-layout="narrative-films"],
  .grid[data-layout="all"],
  .grid[data-layout="documentary"] {
    grid-template-columns: 1fr;
    width: 100%;
    max-width: none;
    margin-top: 12px;
    margin-left: 0;
    margin-right: 0;
    gap: 8px;
  }

  .card__thumb {
    aspect-ratio: 16 / 10;
  }

  .card__info {
    opacity: 1;
    justify-content: flex-end;
    align-items: flex-start;
    text-align: left;
    padding: 56px 16px 16px;
    background: linear-gradient(
      to top,
      rgba(0, 0, 0, 0.75) 0%,
      rgba(0, 0, 0, 0.3) 45%,
      transparent 75%
    );
  }

  .card__title,
  .card__category {
    text-align: left;
  }

  .card__title {
    font-size: 0.95rem;
    letter-spacing: 0.16em;
  }

  .card__category {
    font-size: 0.68rem;
  }

  .card:hover .card__image {
    opacity: 1;
  }

  .about__body   { padding: 48px 20px; }
  .about__text   { font-size: 15px; line-height: 1.75; }
  .about__hero   { height: 58vh; height: 58dvh; }
  .about__hero-name  { bottom: 20px; left: 20px; }
  .about__hero-title { font-size: 20px; letter-spacing: 0.2em; }

  .footer__social {
    gap: 18px;
  }

  .footer__legal {
    font-size: 0.65rem;
    letter-spacing: 0.12em;
    padding: 0 8px;
  }

  .project-page  { padding: 32px 20px 60px; }
  .project-meta__title { font-size: 26px; }
}

@media (prefers-reduced-motion: reduce) {
  body.intro-active.intro-video-in #page-wrapper,
  body.nav-visible .nav__identity,
  body.nav-visible .nav__sticky,
  body.nav-visible .nav::before,
  body.nav-visible .nav::after,
  body.nav-visible .hero__view-work,
  body.hero-cta-animate .hero__view-work-text,
  body.hero-cta-shown .hero__view-work-text,
  #intro-overlay.is-exiting {
    transition: none;
    animation: none;
  }

  body.intro-active:not(.nav-visible) .nav__identity,
  body.intro-active:not(.nav-visible) .nav__sticky,
  body.site-home:not(.nav-visible) .nav__identity,
  body.site-home:not(.nav-visible) .nav__sticky,
  body.intro-active:not(.nav-visible) .nav::before,
  body.intro-active:not(.nav-visible) .nav::after,
  body.site-home:not(.nav-visible) .nav::before,
  body.site-home:not(.nav-visible) .nav::after {
    opacity: 1;
    transform: none;
  }

  body.site-home:not(.nav-visible) .hero__view-work,
  body.nav-visible .hero__view-work {
    opacity: 1;
    transform: none;
  }

  body.intro-active .hero__view-work-text,
  body.hero-cta-shown .hero__view-work-text {
    opacity: 0.78;
    transform: none;
  }

  body.intro-active .nav {
    border-bottom-color: var(--site-border) !important;
  }

  body.work-revealed .grid .card {
    animation: none;
  }

  .card {
    transition: none;
    will-change: auto;
  }
}
