/* ================================================
   EYE C — PRODUCTION PORTFOLIO
   Font: Helvetica Neue exclusively
   Themes: dark (default) / light
   ================================================ */

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

/* ── DARK THEME (default) ───────────────────── */
:root,
[data-theme="dark"] {
  --bg:        #000000;
  --bg-dim:    #080808;
  --fg:        #ffffff;
  --muted:     rgba(255, 255, 255, 0.42);
  --border:    rgba(255, 255, 255, 0.10);
  --nav-bg:    rgba(0, 0, 0, 0.94);
  --radial:    rgba(255, 255, 255, 0.03);
  --play-ring: rgba(255, 255, 255, 0.70);
  --play-halo: rgba(255, 255, 255, 0.08);
  --play-hover:rgba(255, 255, 255, 0.35);
  --count-col: rgba(255, 255, 255, 0.08);
  --foot-col:  rgba(255, 255, 255, 0.20);
  --silver:    linear-gradient(135deg, #6E6E6E 0%, #C8C8C8 35%, #E8E8E8 65%, #9A9A9A 100%);
  --font:      "Helvetica Neue", Helvetica, Arial, sans-serif;
}

/* ── LIGHT THEME ────────────────────────────── */
[data-theme="light"] {
  --bg:        #ffffff;
  --bg-dim:    #f0f0f0;
  --fg:        #000000;
  --muted:     rgba(0, 0, 0, 0.42);
  --border:    rgba(0, 0, 0, 0.10);
  --nav-bg:    rgba(255, 255, 255, 0.94);
  --radial:    rgba(0, 0, 0, 0.02);
  --play-ring: rgba(0, 0, 0, 0.65);
  --play-halo: rgba(0, 0, 0, 0.08);
  --play-hover:rgba(0, 0, 0, 0.35);
  --count-col: rgba(0, 0, 0, 0.08);
  --foot-col:  rgba(0, 0, 0, 0.25);
  --silver:    linear-gradient(135deg, #555555 0%, #909090 35%, #ABABAB 65%, #707070 100%);
}

/* ── SMOOTH THEME TRANSITION ────────────────── */
html {
  scroll-behavior: smooth;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color 360ms ease, color 360ms ease;
}

/* Native cursor stays visible while the preloader runs (.booting) —
   the custom eye cursor takes over on the first mouse move after boot */
body:not(.booting),
body:not(.booting) *,
body:not(.booting) *::before,
body:not(.booting) *::after {
  cursor: none !important;
}

body {
  overflow-x: hidden;
  background: var(--bg);
  transition: background-color 360ms ease;
}

/* ================================================
   CUSTOM CURSOR
   ================================================ */

.cursor {
  position: fixed;
  top: 0;
  left: 0;
  width: 28px;
  height: 14px;
  pointer-events: none;
  z-index: 9999;
  opacity: 0; /* hidden until the first real mouse move */
  transform: translate(-50%, -50%);
  transition: width 200ms ease, height 200ms ease, opacity 200ms ease;
  mix-blend-mode: difference;
  will-change: transform;
}

.cursor-eye {
  width: 100%;
  height: 100%;
  display: block;
}

.cursor.hover {
  width: 40px;
  height: 20px;
}

@keyframes cursorBlink {
  0%, 100% { transform: scaleY(1); }
  35%, 65%  { transform: scaleY(0.04); }
}

.cursor.blinking .cursor-eye {
  animation: cursorBlink 180ms ease-in-out forwards;
}

/* ================================================
   NAVIGATION
   ================================================ */

nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px 52px;
  background: transparent;
  /* whole nav renders white and inverts against whatever scrolls beneath —
     same treatment as the SCROLL indicator (children of a fixed element
     can't blend with the page, so the blend lives on the nav itself) */
  mix-blend-mode: difference;
  transition: background 320ms ease, padding 320ms ease, border-bottom 320ms ease;
}

/* Past the hero the nav gets a solid theme background:
   white text on black (dark) / black text on white (light) */
nav.scrolled {
  mix-blend-mode: normal;
  background: var(--nav-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 18px 52px;
  border-bottom: 1px solid var(--border);
}

nav.scrolled .nav-logo,
nav.scrolled .nav-wordmark,
nav.scrolled .nav-links a,
nav.scrolled .theme-toggle {
  color: var(--fg);
}

nav.scrolled .theme-toggle {
  border-color: var(--border);
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: #ffffff;
}

/* ── Live nav eye logo ── */
.nav-eye {
  height: 19px;
  width: auto;
  display: block;
  overflow: visible;
  transform-origin: center;
}

.nav-eye path {
  stroke: #ffffff;
  stroke-width: 7;
  fill: #ffffff;
  fill-opacity: 0;
  stroke-dasharray: 360;
  stroke-dashoffset: 360;
  animation:
    drawRing 720ms cubic-bezier(0.4, 0, 0.2, 1) 150ms forwards,
    preFill  460ms ease 830ms forwards;
}

.nav-eye circle {
  stroke: #000000;
  stroke-width: 5;
  fill: none;
  stroke-dasharray: 360;
  stroke-dashoffset: 360;
  animation: drawRing 720ms cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.nav-eye circle:nth-of-type(1) { animation-delay: 320ms; }
.nav-eye circle:nth-of-type(2) { animation-delay: 460ms; }

nav.scrolled .nav-eye path {
  stroke: var(--fg);
  fill: var(--fg);
}
nav.scrolled .nav-eye circle {
  stroke: var(--bg);
}

.nav-eye.blinking,
.nav-logo:hover .nav-eye {
  animation: eyeBlinkY 240ms ease-in-out;
}


.nav-wordmark {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.22em;
  color: #ffffff;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 40px;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 44px;
}

.nav-links a {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.20em;
  text-decoration: none;
  color: #ffffff;
  transition: opacity 200ms ease;
  opacity: 0.6;
}

.nav-links a:hover {
  opacity: 1;
}

/* ── THEME TOGGLE ──────────────────────────── */

.theme-toggle {
  background: none;
  border: 1px solid rgba(255,255,255,0.35);
  border-radius: 50%;
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  opacity: 0.6;
  transition: opacity 200ms ease, border-color 200ms ease;
  flex-shrink: 0;
}

.theme-toggle:hover {
  opacity: 1;
  border-color: rgba(255,255,255,0.8);
}

.theme-toggle svg {
  width: 14px;
  height: 14px;
  display: block;
}

/* closed eye shown in dark mode (open your eyes → light), open eye in light mode */
[data-theme="dark"]  .icon-eye-closed { display: block; }
[data-theme="dark"]  .icon-eye-open   { display: none;  }
[data-theme="light"] .icon-eye-closed { display: none;  }
[data-theme="light"] .icon-eye-open   { display: block; }

.theme-toggle svg { transform-origin: center; }
.theme-toggle.wink svg { animation: eyeBlinkY 320ms ease-in-out; }
[data-theme="light"] .tab-btn:not(.active) { opacity: 0.35; }

/* ================================================
   HERO
   ================================================ */

#aurora-canvas {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 1;
  z-index: 0;
  filter: blur(4px);
}

#hero {
  position: relative;
  height: 100vh;
  min-height: 600px;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  display: block;
  opacity: 0;
  transition: opacity 600ms ease;
}
.hero-bg.loaded { opacity: 1; }

/* ── Floating eyes ─────────────────────────── */
/* ── Hero video loader ── */
.hero-loader {
  position: absolute;
  inset: 0;
  z-index: 6;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
  transition: opacity 900ms ease;
  pointer-events: none;
}

.hero-loader.hidden {
  opacity: 0;
}

.hero-loader-eye {
  width: clamp(60px, 10vw, 110px);
  height: auto;
  stroke: var(--fg);
  stroke-width: 7;
  fill: none;
  animation: loaderBlink 2.4s ease-in-out infinite;
  transform-origin: center;
  transform-box: fill-box;
}

.hero-loader-eye path,
.hero-loader-eye circle {
  stroke: var(--fg);
}

@keyframes loaderBlink {
  0%, 100% { transform: scaleY(1);    opacity: 0.9; }
  42%       { transform: scaleY(0.04); opacity: 0.9; }
  52%       { transform: scaleY(0.04); opacity: 0.9; }
}

#hero-eyes {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  overflow: hidden;
  opacity: 1;
  transition: opacity 1.6s ease;
}
#hero-eyes.hidden {
  opacity: 0;
  pointer-events: none;
}

/* floating eyes use the white icon — invert it on a light background */
[data-theme="light"] #hero-eyes img { filter: invert(1); }

.float-eye {
  position: absolute;
  pointer-events: all;
  cursor: pointer;
  transform-origin: center center;
}

.float-eye svg {
  width: 100%;
  height: 100%;
  display: block;
}


@keyframes hf1 {
  0%   { transform: translate(0px, 0px)   rotate(0deg);  }
  25%  { transform: translate(38px,-28px)  rotate(7deg);  }
  50%  { transform: translate(12px,-52px)  rotate(-5deg); }
  75%  { transform: translate(-22px,-30px) rotate(9deg);  }
  100% { transform: translate(0px, 0px)   rotate(0deg);  }
}
@keyframes hf2 {
  0%   { transform: translate(0px, 0px)   rotate(0deg);  }
  30%  { transform: translate(-42px,-18px) rotate(-8deg); }
  65%  { transform: translate(-20px,-55px) rotate(6deg);  }
  100% { transform: translate(0px, 0px)   rotate(0deg);  }
}
@keyframes hf3 {
  0%   { transform: translate(0px, 0px)   rotate(0deg);  }
  20%  { transform: translate(25px,-40px)  rotate(11deg); }
  55%  { transform: translate(55px,-22px)  rotate(-4deg); }
  80%  { transform: translate(30px,-60px)  rotate(8deg);  }
  100% { transform: translate(0px, 0px)   rotate(0deg);  }
}
@keyframes hf4 {
  0%   { transform: translate(0px, 0px)   rotate(0deg);  }
  35%  { transform: translate(-35px,-45px) rotate(-9deg); }
  70%  { transform: translate(15px,-65px)  rotate(5deg);  }
  100% { transform: translate(0px, 0px)   rotate(0deg);  }
}
@keyframes hf5 {
  0%   { transform: translate(0px, 0px)   rotate(0deg);  }
  40%  { transform: translate(48px,-32px)  rotate(-6deg); }
  80%  { transform: translate(22px,-55px)  rotate(10deg); }
  100% { transform: translate(0px, 0px)   rotate(0deg);  }
}
@keyframes hf6 {
  0%   { transform: translate(0px, 0px)   rotate(0deg);  }
  45%  { transform: translate(-28px,-48px) rotate(7deg);  }
  90%  { transform: translate(18px,-30px)  rotate(-5deg); }
  100% { transform: translate(0px, 0px)   rotate(0deg);  }
}

.hero-logo-wrap {
  position: relative;
  z-index: 1;
}

.hero-logo-svg {
  width: min(460px, 82vw);
  height: auto;
  display: block;
  transform-box: fill-box;
  transform-origin: center;
}

@keyframes eyeBlink {
  0%, 100% { transform: scaleY(1); }
  35%, 65% { transform: scaleY(0.04); }
}

.hero-logo-svg.blinking {
  animation: eyeBlink 220ms ease-in-out forwards;
}


/* Eye body: always black, visible on light bg, invisible on dark bg */
.hero-eye {
  opacity: 0;
  fill: #000000;
  animation: eyeFadeIn 500ms ease-out 820ms forwards;
  transition: stroke 360ms ease;
}

[data-theme="dark"]  .hero-eye { stroke: none; }
[data-theme="light"] .hero-eye { stroke: none; }

/* Right ring is always white — it sits inside the black eye body */
#ring-right {
  stroke: #ffffff !important;
}

#ring-left {
  stroke-dasharray: 528;
  stroke-dashoffset: 528;
  animation: drawRing 620ms cubic-bezier(0.4, 0, 0.2, 1) 120ms forwards;
}

#ring-right {
  stroke-dasharray: 528;
  stroke-dashoffset: 528;
  animation: drawRing 620ms cubic-bezier(0.4, 0, 0.2, 1) 280ms forwards;
}

@keyframes drawRing {
  to { stroke-dashoffset: 0; }
}

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

.hero-text {
  text-align: center;
}

.hero-title {
  font-size: clamp(60px, 25.6vw, 144px);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 0.88;
  color: var(--fg);
}

/* Per-letter eyelid-open reveal */
.hero-char {
  display: inline-block;
  opacity: 0;
  clip-path: inset(50% 0 50% 0);
  animation: eyeLidOpen 560ms cubic-bezier(0.22, 1.4, 0.56, 1) calc(1080ms + var(--i) * 72ms) forwards;
}
.hero-char--space {
  width: 0.32em;
}

@keyframes eyeLidOpen {
  from { opacity: 1; clip-path: inset(50% 0 50% 0); }
  to   { opacity: 1; clip-path: inset(0% 0 0% 0); }
}

.hero-studio {
  font-size: 13px;
  font-weight: 300;
  letter-spacing: 0.55em;
  color: var(--muted);
  text-align: center;
  text-transform: uppercase;
  margin-top: 18px;
  opacity: 0;
  animation: studioReveal 800ms cubic-bezier(0.16, 1, 0.3, 1) 1900ms forwards;
}

@keyframes studioReveal {
  from { opacity: 0; letter-spacing: 0.15em; transform: translateY(6px); }
  to   { opacity: 1; letter-spacing: 0.55em; transform: translateY(0); }
}



/* ── Contact: SEE → EYE C morph (scroll-triggered) ── */
.cslogan-first {
  display: inline-grid;
  vertical-align: baseline;
}

.cslogan-see,
.cslogan-eyec {
  grid-area: 1 / 1;
}

.cslogan-see {
  opacity: 0;
}
.cslogan-eyec {
  opacity: 0;
}

/* Fire when IntersectionObserver adds .visible to the h2 */
.contact-heading.visible .cslogan-see {
  animation: cSeeLoop 4400ms linear 300ms infinite;
}

.contact-heading.visible .cslogan-eyec {
  animation: cEyecLoop 4400ms linear 300ms infinite;
}

/* ── Looping cycle (4400ms total) ────────────────
   SEE:   0ms fade-in → hold → 1200ms fade-out
   EYE C: 1400ms fade-in → hold → 3400ms fade-out
   pause: 3800ms → 4400ms (~600ms)
   ──────────────────────────────────────────── */
@keyframes cSeeLoop {
  0%    { opacity: 0; filter: blur(8px);  transform: none; animation-timing-function: ease-out; }
  11.4% { opacity: 1; filter: blur(0);    transform: none; animation-timing-function: linear; }
  27.3% { opacity: 1; filter: blur(0);    transform: none; animation-timing-function: ease-in; }
  36.4% { opacity: 0; filter: blur(18px); transform: scaleX(0.78) translateY(-6px); }
  36.6% { opacity: 0; filter: blur(8px);  transform: none; }
  100%  { opacity: 0; filter: blur(8px);  transform: none; }
}

@keyframes cEyecLoop {
  0%    { opacity: 0; filter: blur(20px); transform: scaleX(1.18) translateY(8px); }
  31.8% { opacity: 0; filter: blur(20px); transform: scaleX(1.18) translateY(8px); animation-timing-function: cubic-bezier(0.16, 1, 0.3, 1); }
  44.5% { opacity: 1; filter: blur(0);    transform: scaleX(1)    translateY(0);   animation-timing-function: linear; }
  77.3% { opacity: 1; filter: blur(0);    transform: scaleX(1)    translateY(0);   animation-timing-function: ease-in; }
  86.4% { opacity: 0; filter: blur(18px); transform: scaleX(0.78) translateY(-6px); }
  86.6% { opacity: 0; filter: blur(20px); transform: scaleX(1.18) translateY(8px); }
  100%  { opacity: 0; filter: blur(20px); transform: scaleX(1.18) translateY(8px); }
}

.hero-sound {
  position: absolute;
  bottom: 44px;
  right: 52px;
  z-index: 2;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  mix-blend-mode: difference;
  opacity: 0;
  animation: fadeIn 400ms ease-out 1200ms forwards;
  transition: opacity 400ms ease;
}

.hero-sound:hover { opacity: 0.7 !important; }

.sound-icon {
  width: 22px;
  height: 22px;
  display: block;
}

.hero-sound .sound-on  { display: none; }
.hero-sound .sound-off { display: block; }
.hero-sound.unmuted .sound-on  { display: block; }
.hero-sound.unmuted .sound-off { display: none; }

.hero-scroll {
  position: absolute;
  bottom: 44px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  opacity: 0;
  animation: fadeIn 400ms ease-out 1200ms forwards;
  transition: opacity 400ms ease;
  z-index: 1;
  mix-blend-mode: difference;
}

.scroll-line {
  width: 1px;
  height: 52px;
  background: linear-gradient(to bottom, transparent, #ffffff);
  animation: scrollPulse 2s ease-in-out 1200ms infinite;
}

@keyframes scrollPulse {
  0%, 100% { opacity: 0.5; transform: scaleY(1); }
  50%       { opacity: 0.15; transform: scaleY(0.6); }
}

.scroll-label {
  color: #ffffff;
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.28em;
}

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

/* ================================================
   MARQUEE
   ================================================ */

.marquee-wrap {
  overflow: hidden;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 15px 0;
  background: var(--bg);
  white-space: nowrap;
  user-select: none;
  transition: background-color 360ms ease, border-color 360ms ease;
}

.marquee-track {
  display: inline-flex;
  animation: marquee 22s linear infinite;
}

.marquee-track span {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.22em;
  color: var(--muted);
}

@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* ================================================
   SHOWREEL
   ================================================ */

#reel {
  position: relative;
  height: 100vh;
  min-height: 500px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 36px;
  background: var(--bg-dim);
  transition: background-color 360ms ease;
}

#reel::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 50%, var(--radial) 0%, transparent 70%);
  pointer-events: none;
}

.reel-label {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.28em;
  color: var(--muted);
}

.play-btn {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  border: 1.5px solid var(--play-ring);
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 300ms ease, border-color 300ms ease;
  position: relative;
  color: var(--fg);
}

.play-btn::before {
  content: '';
  position: absolute;
  inset: -10px;
  border-radius: 50%;
  border: 1px solid var(--play-halo);
  transition: inset 300ms ease, opacity 300ms ease;
}

.play-btn:hover {
  transform: scale(1.12);
  border-color: var(--play-hover);
}

.play-btn:hover::before {
  inset: -20px;
  opacity: 0;
}

.play-btn svg {
  width: 18px;
  height: 18px;
  margin-left: 3px;
}

/* play icon fill adapts to theme */
.play-btn polygon {
  fill: var(--fg);
}

/* ================================================
   SELECTED WORK
   ================================================ */

#work {
  padding: 120px 52px 60px;
  background: var(--bg);
  transition: background-color 360ms ease;
}

.work-tabs {
  display: flex;
  align-items: baseline;
  gap: 32px;
  margin-bottom: 56px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
}

.tab-btn {
  background: none;
  border: none;
  padding: 0;
  font: 700 clamp(28px, 3.8vw, 52px)/1 'Helvetica Neue', Helvetica, Arial, sans-serif;
  letter-spacing: -0.020em;
  text-transform: uppercase;
  color: var(--fg);
  opacity: 0.18;
  filter: blur(3px);
  cursor: pointer;
  transition: opacity 280ms ease, filter 280ms ease;
}

.tab-btn.active {
  opacity: 1;
  filter: none;
}

.tab-btn:hover {
  opacity: 0.55;
  filter: none;
}

.tab-btn.active:hover {
  opacity: 1;
}

/* ── Work Grid ── */
.work-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 3px;
}

.work-card {
  position: relative;
  cursor: pointer;
  overflow: hidden;
}

.card-thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #0a0a0a;
}

.card-thumb-placeholder {
  width: 100%;
  height: 100%;
  background: #0a0a0a;
}

.card-thumb img,
.card-thumb video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 600ms ease;
  pointer-events: none;
  user-select: none;
  -webkit-user-drag: none;
}

.card-overlay {
  z-index: 2;
}

.work-card:hover .card-thumb img,
.work-card:hover .card-thumb video {
  transform: scale(1.04);
}

.card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.62) 0%, rgba(0,0,0,0.10) 55%, transparent 100%);
  opacity: 0;
  transition: opacity 360ms ease;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 20px 22px;
}

.work-card:hover .card-overlay {
  opacity: 1;
}

.card-index {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: rgba(255,255,255,0.5);
  display: block;
  margin-bottom: 6px;
}

.card-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.card-title {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #fff;
}

.card-meta {
  display: none;
}

.card-tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 7px;
}

.card-tag {
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.14em;
  color: rgba(255,255,255,0.7);
  border: 1px solid rgba(255,255,255,0.22);
  padding: 2px 7px;
  border-radius: 2px;
  text-transform: uppercase;
}

/* ── Project Modal ── */
.project-modal {
  position: fixed;
  inset: 0;
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.76);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 380ms ease;
  padding: 40px 20px;
}

.project-modal.open {
  opacity: 1;
  pointer-events: all;
}

.modal-window {
  position: relative;
  width: min(960px, 94vw);
  background: #0d0d0d;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  /* transform/opacity managed by JS */
}

.modal-nav {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  z-index: 502;
  background: none;
  border: none;
  color: rgba(255,255,255,0.35);
  font-size: 28px;
  padding: 16px 24px;
  transition: color 200ms ease, opacity 200ms ease;
  opacity: 0;
  pointer-events: none;
}

.project-modal.open .modal-nav {
  opacity: 1;
  pointer-events: all;
}

.modal-nav--prev { left: 24px; }
.modal-nav--next { right: 24px; }

.modal-nav:hover { color: #fff; }

.modal-nav.hidden { opacity: 0 !important; pointer-events: none !important; }

.modal-close {
  position: absolute;
  top: 16px;
  right: 22px;
  z-index: 10;
  background: none;
  border: none;
  color: rgba(255,255,255,0.55);
  font-size: 18px;
  cursor: pointer;
  transition: color 200ms ease;
  line-height: 1;
}

.modal-close:hover {
  color: #fff;
}

.modal-media {
  width: 100%;
  overflow: hidden;
  line-height: 0;
}

.modal-gif {
  width: 100%;
  height: auto;
  max-height: 62vh;
  object-fit: contain;
  display: block;
  pointer-events: none;
  user-select: none;
  -webkit-user-drag: none;
}

.modal-media {
  position: relative;
}

.modal-media::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
}

.modal-youtube {
  display: none;
  width: 100%;
  aspect-ratio: 16/9;
  border: none;
}

.modal-video {
  display: none;
  width: 100%;
  max-height: 62vh;
  object-fit: contain;
  background: #000;
}

.modal-info {
  flex-shrink: 0;
  padding: 24px 36px 28px;
  border-top: 1px solid rgba(255,255,255,0.07);
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto auto;
  gap: 0 40px;
  align-items: start;
}

.modal-header {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 10px;
}

.modal-index {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: rgba(255,255,255,0.30);
}

.modal-tags {
  display: flex;
  gap: 8px;
}

.modal-tag {
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.16em;
  color: rgba(255,255,255,0.38);
  border: 1px solid rgba(255,255,255,0.10);
  padding: 3px 9px;
  text-transform: uppercase;
}

.modal-title {
  font-size: clamp(22px, 2.8vw, 38px);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1;
  color: #fff;
  grid-column: 1;
  align-self: center;
}

.modal-description {
  font-size: 13px;
  font-weight: 300;
  line-height: 1.68;
  color: rgba(255,255,255,0.42);
  grid-column: 2;
  max-width: 280px;
  align-self: center;
}

.modal-credits {
  display: none;
}

.modal-credit-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 10px 0;
  border-bottom: 1px solid rgba(255,255,255,0.07);
}

.credit-role {
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: rgba(255,255,255,0.35);
}

.credit-name {
  font-size: 12px;
  font-weight: 300;
  letter-spacing: 0.04em;
  color: #fff;
}

.silver-text {
  background: var(--silver);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ================================================
   SERVICES
   ================================================ */

#services {
  position: relative;
  overflow: hidden;
  padding: 60px 52px 140px;
  background: var(--bg);
  transition: background-color 360ms ease;
}

.services-title,
.services-list {
  position: relative;
  z-index: 1;
}

.services-title {
  font-size: clamp(38px, 5.5vw, 68px);
  font-weight: 700;
  letter-spacing: -0.020em;
  margin-bottom: 56px;
}

.services-list {
  list-style: none;
}

.service-item {
  border-top: 1px solid var(--border);
  cursor: default;
  pointer-events: none;
}

.service-item:last-child {
  border-bottom: 1px solid var(--border);
}

.service-header {
  display: flex;
  align-items: center;
  gap: 32px;
  padding: 26px 0;
  transition: transform 260ms ease;
}

.service-item:not(.open):hover .service-header {
  transform: translateX(10px);
}

.service-number {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.16em;
  color: var(--muted);
  width: 28px;
  flex-shrink: 0;
  padding-top: 6px;
}

.service-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.service-name {
  font-size: clamp(18px, 3vw, 30px);
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--fg);
  -webkit-text-fill-color: var(--fg);
  display: block;
  transition: background 260ms ease, -webkit-text-fill-color 260ms ease;
}

.service-item:not(.open):hover .service-name {
  background: var(--silver);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.service-item.open .service-name {
  background: var(--silver);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.service-subs {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.service-subs li {
  font-size: 13px;
  font-weight: 300;
  letter-spacing: 0.04em;
  color: var(--muted);
  padding-left: 14px;
  position: relative;
}

.service-subs li::before {
  content: '—';
  position: absolute;
  left: 0;
  font-size: 11px;
  opacity: 0.5;
}

.service-arrow {
  font-size: 18px;
  color: var(--muted);
  flex-shrink: 0;
  transition: transform 380ms cubic-bezier(0.4, 0, 0.2, 1), color 260ms ease;
}

.service-item:not(.open):hover .service-arrow {
  transform: translateX(6px);
  color: var(--fg);
}

.service-item.open .service-arrow {
  transform: rotate(90deg);
  color: var(--fg);
}

/* ── Service accordion expand ── */
.service-expand {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 520ms cubic-bezier(0.4, 0, 0.2, 1);
}

.service-item.open .service-expand {
  grid-template-rows: 1fr;
}

.service-expand-inner {
  overflow: hidden;
}

.service-expand-content {
  padding: 4px 0 48px;
}

.service-sub-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
}

.service-sub-item {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.service-sub-visual {
  aspect-ratio: 16 / 9;
  background: var(--bg-dim);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  transition: border-color 300ms ease;
}

.service-sub-item:hover .service-sub-visual {
  border-color: rgba(255,255,255,0.25);
}

.service-sub-visual span {
  font-size: 8px;
  font-weight: 500;
  letter-spacing: 0.24em;
  color: var(--muted);
  opacity: 0.35;
}

.service-sub-visual img,
.service-sub-visual gif {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.service-sub-label {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.2em;
  color: var(--muted);
  text-transform: uppercase;
}

/* ================================================
   CONTACT
   ================================================ */

#contact {
  height: 100vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--bg);
  transition: background-color 360ms ease;
}

.contact-reel {
  overflow: hidden;
  flex-shrink: 0;
  mask-image: none;
  -webkit-mask-image: none;
}

.contact-reel-track {
  display: flex;
  gap: 4px;
  width: max-content;
  animation: reelScroll 40s linear infinite;
}

.contact-reel-track video {
  width: 180px;
  height: 101px;
  object-fit: cover;
  border-radius: 2px;
  flex-shrink: 0;
  pointer-events: none;
  transition: opacity 300ms ease;
}

.contact-reel-track video:hover {
  opacity: 1;
}

@keyframes reelScroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.contact-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: clamp(70px, 9vh, 120px) 52px clamp(20px, 3vh, 40px);
  min-height: 0;
}

.footer {
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0.16em;
  color: var(--foot-col);
  padding: clamp(16px, 2vh, 28px) 52px clamp(20px, 3vh, 36px);
  border-top: 1px solid var(--border);
  flex-shrink: 0;
}

.contact-heading {
  font-size: clamp(48px, 9vw, 120px);
  font-weight: 700;
  letter-spacing: -0.030em;
  line-height: 0.92;
  margin-bottom: clamp(24px, 4vh, 52px);
}

.contact-rows {
  border-top: 1px solid var(--border);
  flex: 1;
}

.contact-row {
  display: grid;
  grid-template-columns: 52px 1fr auto 32px;
  align-items: center;
  gap: 24px;
  padding: clamp(14px, 2vh, 22px) 0;
  border-bottom: 1px solid var(--border);
  text-decoration: none;
  color: var(--fg);
  position: relative;
  transition: transform 700ms cubic-bezier(0.25, 1, 0.5, 1);
}

/* Sliding highlight line grows across bottom border on hover */
.contact-row::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0;
  height: 1px;
  width: 0;
  background: var(--fg);
  transition: width 700ms cubic-bezier(0.25, 1, 0.5, 1);
}

.contact-row:hover {
  transform: translateX(20px);
}

.contact-row:hover::after {
  width: 100%;
}

.contact-row-num {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: var(--muted);
  transition: color 600ms ease, transform 700ms cubic-bezier(0.25, 1, 0.5, 1);
}

.contact-row:hover .contact-row-num {
  color: var(--fg);
  transform: translateY(-3px);
}

.contact-row-method {
  font-size: clamp(28px, 4.5vw, 56px);
  font-weight: 700;
  letter-spacing: -0.02em;
  display: inline-block;
  transition: background 600ms ease, -webkit-text-fill-color 600ms ease, transform 800ms cubic-bezier(0.25, 1, 0.5, 1), letter-spacing 700ms cubic-bezier(0.25, 1, 0.5, 1);
}

.contact-row:hover .contact-row-method {
  background: var(--silver);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  transform: translateY(-4px);
  letter-spacing: -0.01em;
}

.contact-row-value {
  font-size: clamp(11px, 1.2vw, 14px);
  font-weight: 300;
  letter-spacing: 0.04em;
  color: var(--muted);
  text-align: right;
  transition: color 600ms ease, transform 700ms cubic-bezier(0.25, 1, 0.5, 1);
}

.contact-row:hover .contact-row-value {
  color: var(--fg);
  transform: translateX(-4px) translateY(-2px);
}

.contact-row-arrow {
  font-size: 18px;
  color: var(--muted);
  transition: transform 700ms cubic-bezier(0.25, 1, 0.5, 1), color 500ms ease;
}

.contact-row:hover .contact-row-arrow {
  transform: translate(4px, -4px);
  color: var(--fg);
}


/* ================================================
   REVEAL ANIMATIONS
   ================================================ */

.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 720ms ease, transform 720ms ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}


.service-item:nth-child(1) { transition-delay: 0ms;   }
.service-item:nth-child(2) { transition-delay: 80ms;  }
.service-item:nth-child(3) { transition-delay: 160ms; }
.service-item:nth-child(4) { transition-delay: 240ms; }

/* ================================================
   RESPONSIVE — TABLET
   ================================================ */

@media (max-width: 1024px) {
  nav,
  nav.scrolled {
    padding-left: 32px;
    padding-right: 32px;
  }

  #work,
  #services {
    padding-left: 32px;
    padding-right: 32px;
  }

  #contact { padding: 120px 32px 64px; }

  .about-grid {
    grid-template-columns: 1fr;
    gap: 64px;
  }

  .work-grid {
    grid-template-columns: repeat(2, 1fr); /* already default */
  }

  .modal-info {
    grid-template-columns: 1fr;
  }

  .modal-description {
    grid-column: 1;
    max-width: 100%;
  }

  .service-expand-content {
    grid-template-columns: 1fr;
  }
}

/* ================================================
   RESPONSIVE — MOBILE
   ================================================ */

@media (max-width: 640px) {
  nav,
  nav.scrolled {
    padding: 16px 20px;
  }

  .nav-wordmark { display: none; }

  .nav-right {
    gap: 20px;
  }

  .nav-links {
    gap: 20px;
  }

  .nav-links a {
    font-size: 9px;
    letter-spacing: 0.14em;
  }

  #hero { gap: 32px; }

  .work-grid {
    grid-template-columns: 1fr;
    gap: 2px;
  }

  #work,
  #services { padding: 80px 20px 100px; }

  #contact {
    padding: 100px 20px 60px;
    min-height: unset;
  }

  .contact-heading { margin-bottom: 44px; }
  .count           { font-size: 44px; }
  .hero-scroll     { bottom: 28px; }
}

/* ================================================
   EYE SYSTEM — shared blink
   ================================================ */

@keyframes eyeBlinkY {
  0%, 100% { transform: scaleY(1); }
  40%, 60% { transform: scaleY(0.06); }
}

/* ================================================
   PRELOADER — the eye opens, vision focuses
   ================================================ */

body.booting { overflow: hidden; }

#hero { transition: filter 1100ms ease; }
body.booting #hero { filter: blur(18px); }

.preloader {
  position: fixed;
  inset: 0;
  z-index: 1000;
  pointer-events: none;
}

.preloader-lid {
  position: absolute;
  left: 0;
  width: 100%;
  height: 50.2%;
  background: var(--bg);
  transition: transform 780ms cubic-bezier(0.7, 0, 0.2, 1);
}

.preloader-lid--top    { top: 0; }
.preloader-lid--bottom { bottom: 0; }

.preloader.open .preloader-lid--top    { transform: translateY(-101%); }
.preloader.open .preloader-lid--bottom { transform: translateY(101%); }

.preloader-eye-wrap {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: clamp(150px, 20vw, 250px);
  transition: opacity 340ms ease;
}

.preloader.open .preloader-eye-wrap { opacity: 0; }

.preloader-eye {
  width: 100%;
  height: auto;
  display: block;
  overflow: visible;
  transform-origin: center;
  animation: eyeBlinkY 260ms ease-in-out 1650ms;
}

/* Almond: outline draws in, then fills — white oval on black (dark),
   black oval on white (light), exactly like icon_white / icon_black */
.preloader-eye path {
  stroke: var(--fg);
  stroke-width: 4;
  fill: var(--fg);
  fill-opacity: 0;
  stroke-dasharray: 360;
  stroke-dashoffset: 360;
  animation:
    drawRing 700ms cubic-bezier(0.4, 0, 0.2, 1) 60ms forwards,
    preFill  460ms ease 680ms forwards;
}

@keyframes preFill {
  to { fill-opacity: 1; }
}

/* Pupils: two interlocked rings drawn in the background colour
   over the filled almond; left ring carries the brand gradient */
.preloader-eye circle {
  stroke: var(--bg);
  stroke-width: 5;
  fill: none;
  stroke-dasharray: 360;
  stroke-dashoffset: 360;
  animation: drawRing 640ms cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.preloader-eye circle:nth-of-type(1) { stroke: url(#pre-ring-grad); animation-delay: 950ms; }
.preloader-eye circle:nth-of-type(2) { animation-delay: 1100ms; }

/* ================================================
   CURSOR 2.0 — pupil looks where you move
   ================================================ */

.cursor-look { will-change: transform; }

.cursor-pupil {
  transform-box: fill-box;
  transform-origin: center;
  transition: transform 240ms ease;
}

.cursor.view { width: 54px; height: 27px; }
.cursor.view .cursor-pupil { transform: scale(1.45); }

/* ================================================
   HERO SCROLL — mini eye glances down
   ================================================ */

.scroll-eye-mini {
  width: 26px;
  height: 13px;
  overflow: visible;
}

.scroll-eye-pupil {
  animation: pupilGlanceDown 2.6s ease-in-out infinite;
}

@keyframes pupilGlanceDown {
  0%, 50%, 100% { transform: translateY(0); }
  65%, 85%      { transform: translateY(2.6px); }
}

/* ================================================
   WORK — tab switch blinks, cards open like eyelids
   ================================================ */

.grid-stage {
  position: relative;
  overflow: hidden;
}

.grid-lid {
  position: absolute;
  left: 0;
  width: 100%;
  height: 50.5%;
  background: var(--bg);
  z-index: 5;
  pointer-events: none;
  transition: transform 280ms cubic-bezier(0.7, 0, 0.3, 1);
}

.grid-lid--top    { top: 0;    transform: translateY(-101%); }
.grid-lid--bottom { bottom: 0; transform: translateY(101%);  }

.grid-stage.lids-closed .grid-lid--top,
.grid-stage.lids-closed .grid-lid--bottom { transform: translateY(0); }

.work-card.card-in .card-thumb {
  animation: lidReveal 560ms cubic-bezier(0.22, 1, 0.36, 1) var(--d, 0ms) backwards;
}

@keyframes lidReveal {
  from { clip-path: inset(50% 0 50% 0); }
  to   { clip-path: inset(0 0 0 0); }
}

/* ================================================
   MODAL — media opens like an eye
   ================================================ */

.project-modal.open .modal-media {
  animation: mediaEyeOpen 640ms cubic-bezier(0.16, 1, 0.3, 1) 100ms backwards;
}

@keyframes mediaEyeOpen {
  from { clip-path: ellipse(105% 0% at 50% 50%); }
  to   { clip-path: ellipse(105% 110% at 50% 50%); }
}

/* ================================================
   CONTACT — the watcher eye
   ================================================ */

#contact { position: relative; }

.contact-content {
  position: relative;
  z-index: 1;
}

.watcher-eye {
  position: absolute;
  top: clamp(60px, 11vh, 130px);
  right: 5vw;
  width: clamp(180px, 26vw, 430px);
  height: auto;
  pointer-events: none;
  z-index: 0;
  overflow: visible;
  transform-origin: center;
  opacity: 0.55;
}

.watcher-eye path,
.watcher-eye circle {
  stroke: var(--fg);
  stroke-width: 2.5;
  fill: none;
  stroke-dasharray: 360;
  stroke-dashoffset: 360;
}

.watcher-eye.visible path                  { animation: drawRing 900ms cubic-bezier(0.4, 0, 0.2, 1) 150ms forwards; }
.watcher-eye.visible circle:nth-of-type(1) { animation: drawRing 900ms cubic-bezier(0.4, 0, 0.2, 1) 380ms forwards; }
.watcher-eye.visible circle:nth-of-type(2) { animation: drawRing 900ms cubic-bezier(0.4, 0, 0.2, 1) 560ms forwards; }

.watcher-eye.blinking { animation: eyeBlinkY 240ms ease-in-out; }

.we-look { will-change: transform; }

.we-pupil {
  transform-box: fill-box;
  transform-origin: center;
  transition: transform 360ms cubic-bezier(0.22, 1, 0.36, 1);
}

.watcher-eye.dilated .we-pupil { transform: scale(1.18); }

/* ================================================
   SCROLL PROGRESS EYE — opens as you scroll
   ================================================ */

#scroll-eye {
  position: fixed;
  right: 30px;
  bottom: 28px;
  z-index: 90;
  width: 54px;
  height: 30px;
  background: none;
  border: none;
  padding: 0;
  opacity: 0;
  pointer-events: none;
  transform: translateY(10px);
  transition: opacity 400ms ease, transform 400ms ease;
  mix-blend-mode: difference;
}

#scroll-eye.show {
  opacity: 0.85;
  pointer-events: auto;
  transform: none;
}

#scroll-eye:hover { opacity: 1; }

#scroll-eye svg {
  width: 100%;
  height: 100%;
  display: block;
  overflow: visible;
  transform-origin: center;
}

#scroll-eye svg.blinking { animation: eyeBlinkY 240ms ease-in-out; }

#scroll-eye path,
#scroll-eye circle {
  stroke: #ffffff;
  stroke-width: 6;
  fill: none;
}

.se-inner {
  transition: clip-path 180ms linear;
}

.se-look { will-change: transform; }

/* ================================================
   POLISH — selection, touch, reduced motion
   ================================================ */

::selection { background: var(--fg); color: var(--bg); }

@media (max-width: 640px) {
  .watcher-eye { width: 46vw; opacity: 0.35; }
  #scroll-eye  { right: 16px; bottom: 16px; width: 44px; height: 24px; }
}

@media (hover: none) {
  .cursor { display: none; }
  *, *::before, *::after { cursor: auto !important; }
}

@media (prefers-reduced-motion: reduce) {
  .preloader { display: none; }
  body.booting { overflow: auto; }
  body.booting #hero { filter: none; }
  .nav-eye path, .nav-eye circle,
  .watcher-eye path, .watcher-eye circle {
    animation: none;
    stroke-dashoffset: 0;
    fill-opacity: 1;
  }
  .scroll-eye-pupil { animation: none; }
}
