/* ═══════════════════════════════════════════════════════════
   ANDREA TOMAS — VFX Portfolio
   Cinematic dark · Earth Orbiter (sci-fi/pro) · Inter
═══════════════════════════════════════════════════════════ */

@font-face {
  font-family: 'Earth Orbiter';
  src: url('../assets/fonts/earthorbiterbold.ttf') format('truetype');
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@200;300;400;500;600&display=swap');

/* ── Reset ── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  font-family: 'Inter', system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-weight: 300;
  background: #000;
  color: #fff;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  letter-spacing: 0.012em;
}
@media (prefers-reduced-motion: reduce){
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
a { text-decoration: none; color: inherit; }
img, video { display: block; max-width: 100%; }
iframe { display: block; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
@media (hover: none), (pointer: coarse) { button { cursor: pointer; } }

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: #000; }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.18); border: 3px solid #000; border-radius: 100px; }
::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.32); }
::selection { background: #6e3aff; color: #fff; }

/* ── Tokens ── */
:root {
  --bg:        #000;
  --bg-2:      #06060a;
  --bg-3:      #0c0c14;
  --card:      #14141a;
  --ink:       #ffffff;
  --muted:     rgba(255,255,255,0.62);
  --muted-2:   rgba(255,255,255,0.42);
  --muted-3:   rgba(255,255,255,0.25);
  --line:      rgba(255,255,255,0.18);
  --line-2:    rgba(255,255,255,0.28);

  --violet:    #6e3aff;
  --violet-2:  #b69dff;
  --violet-3:  #4a1fb0;
  --magenta:   #d63aff;
  --cyan:      #3ad7ff;
  --gold:      #ffb547;

  --display:   'Earth Orbiter', "Helvetica Neue", system-ui, sans-serif;
  --body:      'Inter', system-ui, sans-serif;
  --ease:      cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --container: 1280px;
}

/* ════════════════════════════
   FILM GRAIN
════════════════════════════ */
body::after {
  content: "";
  position: fixed; inset: 0;
  pointer-events: none;
  z-index: 9000;
  opacity: 0.05;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='240' height='240'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.95' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 0.7 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  animation: grain 8s steps(8) infinite;
}
@keyframes grain {
  0%   { transform: translate(0, 0); }
  10%  { transform: translate(-3%, -2%); }
  20%  { transform: translate(2%, -5%); }
  30%  { transform: translate(-3%, 4%); }
  40%  { transform: translate(3%, 2%); }
  50%  { transform: translate(-2%, -3%); }
  60%  { transform: translate(4%, 1%); }
  70%  { transform: translate(-3%, 4%); }
  80%  { transform: translate(2%, -2%); }
  90%  { transform: translate(-1%, 3%); }
  100% { transform: translate(0, 0); }
}

/* ════════════════════════════
   CUSTOM CURSOR
════════════════════════════ */
.cursor {
  position: fixed; top: 0; left: 0;
  width: 8px; height: 8px;
  background: transparent;
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  mix-blend-mode: difference;
  opacity: 0;
  transition: width .25s var(--ease), height .25s var(--ease), background-color .25s var(--ease), opacity .2s var(--ease), border-color .2s var(--ease);
  will-change: transform;
}
.cursor.is-hover {
  width: 48px; height: 48px;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.6);
  opacity: 1;
}
.cursor.is-violet {
  background: var(--violet);
  width: 56px; height: 56px;
}
@media (hover: none), (pointer: coarse) { .cursor { display: none; } }

/* Touch ripple — quick violet circle that fades out where the user taps,
   replacing the desktop hover-cursor on mobile/tablet. */
.tap-ripple {
  position: fixed;
  width: 56px; height: 56px;
  margin-left: -28px; margin-top: -28px;
  border-radius: 50%;
  border: 1px solid rgba(182,157,255,0.7);
  background: rgba(182,157,255,0.14);
  pointer-events: none;
  z-index: 9999;
  animation: tapRipple .55s ease-out forwards;
}
@keyframes tapRipple {
  0%   { transform: scale(0.45); opacity: 1; }
  100% { transform: scale(2);    opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .tap-ripple { animation-duration: .01ms; }
}

/* ════════════════════════════
   SCROLL PROGRESS
════════════════════════════ */
.scroll-progress {
  position: fixed; top: 0; left: 0; right: 0;
  height: 2px;
  z-index: 200;
  background: linear-gradient(90deg, var(--violet) 0%, var(--magenta) 50%, var(--violet-2) 100%);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.06s linear;
}

/* ════════════════════════════
   BG VIDEO (ambient section bg)
════════════════════════════ */
.bg-video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  z-index: 0;
  opacity: 0.18;
  pointer-events: none;
  filter: contrast(1.05) saturate(0.9);
}
/* On phones, hide the heavy 4K bg videos and rely on the section's gradient
   backgrounds instead. Saves 30-50MB of video downloads on mobile data. */
@media (max-width: 720px) {
  .bg-video { display: none !important; }
}
.bg-video-overlay {
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at center, transparent 0%, rgba(0,0,0,0.55) 80%, rgba(0,0,0,0.85) 100%);
  z-index: 1;
  pointer-events: none;
}
/* Soft top + bottom mask variant — used by reel-stack, ai-showreel and about
   so each section dissolves into the adjacent dark sections without a seam.
   The mid-zone is dark-but-translucent so the underlying video texture reads
   through, while the top 20% and bottom 20% fade to pure black. */
.bg-video-overlay--soft {
  background:
    linear-gradient(180deg,
      #000 0%,
      rgba(0,0,0,0.85) 8%,
      rgba(0,0,0,0.55) 22%,
      rgba(0,0,0,0.55) 78%,
      rgba(0,0,0,0.85) 92%,
      #000 100%),
    radial-gradient(ellipse at center, transparent 0%, rgba(0,0,0,0.25) 80%, rgba(0,0,0,0.4) 100%);
}
/* Reel chamber video sits behind the violet ambient at low opacity. Brightness
   lifted to 1.0 so the gradient video reads through the heavy overlay
   without making the section feel flat-dark. */
.bg-video--reel {
  opacity: 0.65;
  filter: contrast(1.05) saturate(1.1) brightness(1.0);
}
/* AI Showreel uses a brighter pass-through of its video so the reflection
   shimmer reads more clearly than the reel-chamber treatment. */
#ai-showreel .bg-video--reel {
  opacity: 0.85;
  filter: contrast(1.0) saturate(1.1) brightness(1.05);
}
/* Lighter overlay just for AI Showreel so the brightened video isn't
   immediately darkened back down. Keeps the soft top/bottom black fades for
   seamless section transitions but lifts the mid-zone. */
#ai-showreel .bg-video-overlay--soft {
  background:
    linear-gradient(180deg,
      #000 0%,
      rgba(0,0,0,0.75) 8%,
      rgba(0,0,0,0.3) 22%,
      rgba(0,0,0,0.3) 78%,
      rgba(0,0,0,0.75) 92%,
      #000 100%),
    radial-gradient(ellipse at center, transparent 0%, rgba(0,0,0,0.12) 80%, rgba(0,0,0,0.25) 100%);
}
/* About me sits inside .studies-exp-wrap, sharing its bg with Studies and
   Experience. No animated gradient required. */
/* Ensure section content sits above the bg-video layers regardless of static
   stacking quirks. */
#about > .container,
#ai-showreel > .container,
.reel-stack > section { position: relative; z-index: 2; }

/* ════════════════════════════
   AMBIENT ORBS
════════════════════════════ */
.ambient {
  position: absolute; inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 0;
}
.ambient::before, .ambient::after {
  content: "";
  position: absolute;
  width: 60vw; height: 60vw;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.32;
  animation: drift 24s ease-in-out infinite;
}
.ambient::before {
  background: radial-gradient(circle, var(--violet) 0%, transparent 70%);
  top: -25%; left: -15%;
}
.ambient::after {
  background: radial-gradient(circle, var(--cyan) 0%, transparent 70%);
  bottom: -25%; right: -15%;
  animation-delay: -12s;
  opacity: 0.18;
}
.ambient--violet::before { background: radial-gradient(circle, var(--violet) 0%, transparent 70%); }
.ambient--violet::after  { background: radial-gradient(circle, var(--magenta) 0%, transparent 70%); opacity: 0.22; }
.ambient--warm::before { background: radial-gradient(circle, var(--gold) 0%, transparent 70%); opacity: 0.14; }
.ambient--warm::after  { background: radial-gradient(circle, var(--magenta) 0%, transparent 70%); opacity: 0.16; }
.ambient--cool::before { background: radial-gradient(circle, var(--cyan) 0%, transparent 70%); opacity: 0.16; }
.ambient--cool::after  { background: radial-gradient(circle, var(--violet) 0%, transparent 70%); opacity: 0.20; }
@keyframes drift {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33%      { transform: translate(8%, -10%) scale(1.08); }
  66%      { transform: translate(-6%, 8%) scale(0.96); }
}

/* ════════════════════════════
   TYPE
════════════════════════════ */
h1, h2, h3, h4, h5 {
  font-family: var(--display);
  font-weight: 400;
  letter-spacing: 0.04em;
  line-height: 1.1;
}

p { margin: 0 0 1em; font-weight: 300; }

/* Centered section title */
.section-title {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(20px, 3vw, 40px);
  margin-bottom: clamp(40px, 6vw, 72px);
  position: relative; z-index: 2;
}
.section-title::before,
.section-title::after {
  content: "";
  flex: 1;
  max-width: 320px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
}
.section-title h2 {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(28px, 3.6vw, 48px);
  letter-spacing: 0.06em;
  color: var(--ink);
  text-align: center;
  white-space: nowrap;
  text-transform: uppercase;
}

.section-sub {
  text-align: center;
  font-family: var(--body);
  font-weight: 300;
  font-size: clamp(15px, 1.4vw, 18px);
  color: var(--muted);
  letter-spacing: 0.04em;
  margin-bottom: clamp(28px, 4vw, 48px);
  position: relative; z-index: 2;
}

/* ════════════════════════════
   LAYOUT
════════════════════════════ */
section { padding: clamp(72px, 9vw, 120px) 0; position: relative; }
.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 clamp(24px, 4vw, 56px);
  position: relative;
  z-index: 2;
}

/* ════════════════════════════
   NAV
════════════════════════════ */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: flex; align-items: center; justify-content: center;
  padding: 18px clamp(24px, 4vw, 56px);
  transition: background-color .4s var(--ease), padding .4s var(--ease), border-color .4s;
  border-bottom: 1px solid transparent;
  pointer-events: none;
}
.nav::before {
  content: "";
  position: absolute; left: clamp(24px, 4vw, 56px); top: 50%;
  height: 1px;
  width: calc(50% - 480px);
  background: rgba(255,255,255,0.22);
}
.nav::after {
  content: "";
  position: absolute; right: clamp(24px, 4vw, 56px); top: 50%;
  height: 1px;
  width: calc(50% - 480px);
  background: rgba(255,255,255,0.22);
}
.nav.is-scrolled {
  padding-top: 12px; padding-bottom: 12px;
  background: rgba(0,0,0,0.78);
  backdrop-filter: blur(20px) saturate(1.4);
  -webkit-backdrop-filter: blur(20px) saturate(1.4);
  border-bottom-color: rgba(255,255,255,0.06);
}
.nav__inner {
  display: flex; align-items: center; gap: clamp(16px, 2.4vw, 32px);
  pointer-events: auto;
}
.nav__inner a {
  font-family: var(--body);
  font-size: 14px;
  font-weight: 400;
  color: rgba(255,255,255,0.85);
  letter-spacing: 0.01em;
  position: relative;
  padding: 6px 2px;
  transition: color .3s var(--ease);
  white-space: nowrap;
}
.nav__inner a::after {
  content: "";
  position: absolute; left: 0; right: 0; bottom: 2px;
  height: 1px; background: currentColor;
  transform: scaleX(0); transform-origin: left;
  transition: transform .35s var(--ease);
}
.nav__inner a:hover { color: var(--ink); }
.nav__inner a:hover::after { transform: scaleX(1); }
.nav__inner a.is-active { color: var(--violet-2); }
.nav__inner a.is-active::after { transform: scaleX(1); background: linear-gradient(90deg, transparent, var(--violet-2), transparent); }

/* Nav CTA — compact pill with a violet sweep on hover, arrow slides in from
   the side. Anchors to #contact section at page bottom. */
.nav__cta {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--body);
  font-size: 12px; font-weight: 500;
  padding: 10px 22px;
  border: 1px solid rgba(255,255,255,0.85);
  border-radius: 100px;
  background: linear-gradient(120deg, rgba(255,255,255,0.95) 0%, rgba(255,255,255,0.95) 50%, rgba(110,58,255,0.95) 100%);
  background-size: 220% 100%;
  background-position: 0% 0%;
  color: #000 !important;
  margin-left: clamp(8px, 1.6vw, 20px);
  min-width: 120px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  overflow: hidden;
  transition: background-position .55s var(--ease), color .35s var(--ease), border-color .35s var(--ease), transform .35s var(--ease), box-shadow .35s var(--ease);
}
.nav__cta-text {
  position: relative; z-index: 1;
}
.nav__cta:hover {
  background-position: 100% 0%;
  color: #fff !important;
  border-color: rgba(182,157,255,0.95);
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(110,58,255,0.45), 0 0 0 1px rgba(182,157,255,0.4);
}
.nav__cta::after { display: none !important; }

.nav__toggle {
  display: none;
  position: absolute; right: clamp(24px, 4vw, 56px); top: 50%; transform: translateY(-50%);
  width: 28px; height: 22px;
  pointer-events: auto;
}
.nav__toggle span {
  position: absolute; left: 0; right: 0; height: 1.5px;
  background: var(--ink);
  transition: transform .35s var(--ease), top .35s var(--ease), opacity .35s var(--ease);
}
.nav__toggle span:nth-child(1) { top: 4px; }
.nav__toggle span:nth-child(2) { top: 12px; }
.nav__toggle span:nth-child(3) { top: 20px; }
.nav__toggle.is-open span:nth-child(1) { top: 12px; transform: rotate(45deg); }
.nav__toggle.is-open span:nth-child(2) { opacity: 0; }
.nav__toggle.is-open span:nth-child(3) { top: 12px; transform: rotate(-45deg); }

@media (max-width: 1100px) {
  .nav { justify-content: flex-end; padding-right: 80px; }
  .nav::before, .nav::after { display: none; }
  .nav__inner { display: none; }
  .nav__toggle { display: block; }
}

/* Mobile menu */
.mob-menu {
  position: fixed; inset: 0; z-index: 90;
  background: rgba(0,0,0,0.96);
  backdrop-filter: blur(20px);
  padding: 96px clamp(24px, 6vw, 56px) 32px;
  display: flex; flex-direction: column; justify-content: space-between;
  transform: translateY(-100%);
  transition: transform .55s var(--ease);
  visibility: hidden;
}
.mob-menu.is-open { transform: translateY(0); visibility: visible; }
.mob-menu__links { display: grid; gap: 12px; }
.mob-menu__links a {
  font-family: var(--display);
  font-size: clamp(20px, 5vw, 28px);
  font-weight: 400;
  letter-spacing: 0.06em;
  color: var(--ink);
  text-transform: uppercase;
}
.mob-menu__links a:hover { color: var(--violet-2); }
.mob-menu__meta {
  display: flex; gap: 20px; flex-wrap: wrap;
  border-top: 1px solid var(--line);
  padding-top: 20px;
  font-size: 12px; color: var(--muted);
}
.mob-menu__meta a { letter-spacing: 0.18em; text-transform: uppercase; }

/* ════════════════════════════
   HERO
════════════════════════════ */
.hero {
  position: relative;
  min-height: 100svh;
  padding: 100px clamp(24px, 4vw, 56px) 56px;
  display: flex; align-items: center;
  overflow: hidden;
  background: var(--bg);
}
/* Smooth fade-out at hero bottom into the next section */
.hero::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 240px;
  z-index: 4;
  pointer-events: none;
  background: linear-gradient(
    to bottom,
    transparent 0%,
    rgba(0,0,0,0.35) 35%,
    rgba(0,0,0,0.85) 75%,
    #000 100%
  );
}
@media (max-width: 720px){
  .hero::after { height: 160px; }
}
.hero__bg {
  position: absolute; inset: 0;
  z-index: 0;
}
.hero__bg::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(0,0,0,0.62) 0%, rgba(0,0,0,0.32) 35%, rgba(0,0,0,0.18) 70%, rgba(0,0,0,0.55) 100%);
  z-index: 2;
}
.hero__bg::before {
  content: "";
  position: absolute; inset: 0;
  background:
    radial-gradient(circle at 30% 70%, rgba(110,58,255,0.18) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(58,215,255,0.10) 0%, transparent 50%);
  z-index: 3;
  mix-blend-mode: screen;
  pointer-events: none;
}
.hero__bg-vimeo,
.hero__bg-video {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 100vw; height: 56.25vw;
  min-height: 100%; min-width: 177.78vh;
  pointer-events: none; border: 0;
  z-index: 1;
}
.hero__bg-video {
  /* HTML5 video element — object-fit: cover handles aspect cleanly inside the
     min-width/min-height cover-fit box. */
  object-fit: cover;
  background: #000;
}

.hero__inner {
  position: relative; z-index: 4;
  max-width: 760px;
  width: 100%;
}

.hero__title {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(44px, 8vw, 120px);
  line-height: 0.96;
  letter-spacing: 0.06em;
  color: var(--ink);
  margin-bottom: 28px;
  text-shadow: 0 4px 32px rgba(0,0,0,0.55);
  text-transform: uppercase;
}
.hero__sub {
  font-family: var(--body);
  font-weight: 200;
  font-size: clamp(17px, 1.8vw, 26px);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.92);
  margin-bottom: clamp(36px, 5vw, 56px);
  padding-left: clamp(8px, 1vw, 16px);
}

.hero__actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: clamp(56px, 8vw, 96px);
  padding-left: clamp(8px, 1vw, 16px);
}

.hero__trading {
  position: absolute;
  bottom: 56px; left: 50%;
  transform: translateX(-50%);
  z-index: 4;
  text-align: center;
}
.hero__trading-label {
  font-family: var(--body);
  font-weight: 300;
  font-size: 14px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.85);
  margin-bottom: 18px;
}
.hero__trading-logo {
  display: inline-block;
  transition: transform .35s var(--ease), opacity .35s var(--ease);
}
.hero__trading-logo img {
  height: clamp(84px, 9vw, 124px);
  width: auto;
  opacity: 0.95;
}
.hero__trading-logo:hover { transform: scale(1.04); opacity: 1; }

.hero__scroll-cue {
  position: absolute;
  right: clamp(24px, 4vw, 56px);
  bottom: 56px;
  z-index: 4;
  display: flex; flex-direction: column; align-items: center; gap: 16px;
  pointer-events: none;
}
.hero__scroll-cue span {
  font-family: var(--display);
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0.55em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.78);
  writing-mode: vertical-rl;
  text-shadow: 0 0 12px rgba(110,58,255,0.45);
  animation: scrollLabelPulse 3.6s ease-in-out infinite;
}
@keyframes scrollLabelPulse {
  0%, 100% { color: rgba(255,255,255,0.6); }
  50%      { color: rgba(214,171,255,0.95); }
}
/* Vertical rail with a glowing dot travelling down it.
   ::after is the rail (sits below the "Scroll" span in flex column order).
   ::before is the absolutely-positioned dot animating down the rail. */
.hero__scroll-cue::after {
  content: "";
  width: 1px; height: 72px;
  background: linear-gradient(to bottom,
    rgba(255,255,255,0) 0%,
    rgba(255,255,255,0.32) 18%,
    rgba(182,157,255,0.55) 50%,
    rgba(255,255,255,0.32) 82%,
    rgba(255,255,255,0) 100%);
}
.hero__scroll-cue::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--violet-2);
  box-shadow:
    0 0 10px rgba(182,157,255,0.95),
    0 0 22px rgba(110,58,255,0.7),
    0 0 40px rgba(110,58,255,0.35);
  animation: scrollDot 2.6s cubic-bezier(.55,.05,.35,1) infinite;
}
@keyframes scrollDot {
  0%   { transform: translate(-50%, -78px); opacity: 0; }
  18%  { opacity: 1; }
  82%  { opacity: 1; }
  100% { transform: translate(-50%, -6px); opacity: 0; }
}

@media (max-width: 720px){
  .hero__trading { bottom: 24px; }
  .hero__trading-label { font-size: 11px; }
  .hero__scroll-cue { display: none; }
}

/* ════════════════════════════
   BUTTONS
════════════════════════════ */
.btn {
  display: inline-flex; align-items: center; gap: 12px;
  font-family: var(--body);
  font-weight: 400;
  font-size: 14px;
  letter-spacing: 0.04em;
  padding: 13px 28px;
  border-radius: 100px;
  border: 1px solid rgba(255,255,255,0.85);
  background: transparent;
  color: var(--ink);
  position: relative;
  isolation: isolate;
  transition: color .35s var(--ease), border-color .35s var(--ease), transform .35s var(--ease), box-shadow .35s var(--ease);
  will-change: transform;
}
.btn::before {
  content: "";
  position: absolute; inset: 0;
  border-radius: 100px;
  background: linear-gradient(120deg, var(--violet) 0%, var(--magenta) 50%, var(--violet) 100%);
  transform: scale(0.4);
  opacity: 0;
  transition: transform .5s var(--ease), opacity .4s var(--ease);
  z-index: -1;
}
.btn svg { width: 16px; height: 16px; transition: transform .35s var(--ease); position: relative; z-index: 1; }
.btn span { position: relative; z-index: 1; }
.btn:hover {
  color: #fff;
  border-color: var(--violet);
  box-shadow: 0 16px 36px rgba(110,58,255,0.32);
}
.btn:hover::before { transform: scale(1.05); opacity: 1; }
.btn:hover svg { transform: translateX(4px); }

/* ════════════════════════════
   STUDIES + EXPERIENCE — shared bg wrapper (single video, not duplicated)
   Reduced inner padding so Victor Perez row sits closer to Experience.
════════════════════════════ */
.studies-exp-wrap {
  position: relative;
  isolation: isolate;
}
.studies-exp-wrap #about {
  padding-top: clamp(80px, 10vw, 140px);
  padding-bottom: clamp(48px, 6vw, 80px);
}
.studies-exp-wrap #studies {
  padding-top: clamp(48px, 7vw, 80px);
  padding-bottom: clamp(28px, 4vw, 48px);
}
.studies-exp-wrap #experience {
  padding-top: clamp(28px, 4vw, 48px);
  padding-bottom: clamp(56px, 8vw, 88px);
}
.studies-exp-wrap > .bg-video--shared {
  position: absolute;
  inset: -20px;
  width: calc(100% + 40px);
  height: calc(100% + 40px);
  z-index: 0;
  /* Heavier blur so the video reads as a soft texture rather than recognisable
     content. Inset is -20px and size +40px so the blur edges don't reveal
     the section bg. */
  filter: blur(14px) brightness(0.85) saturate(0.95);
}
.studies-exp-wrap > .bg-video-overlay { z-index: 1; }
.studies-exp-wrap #about,
.studies-exp-wrap #studies,
.studies-exp-wrap #experience {
  background: transparent;
  position: relative;
  z-index: 2;
}
/* Top fade-in from Hero (pure black). Extended 420px ramp with multiple
   stops so the dissolve is gradual and seamless. */
.studies-exp-wrap::before {
  content: "";
  position: absolute; top: 0; left: 0; right: 0;
  height: 420px;
  z-index: 1;
  background: linear-gradient(to bottom,
    #000 0%,
    rgba(0,0,0,0.92) 15%,
    rgba(0,0,0,0.7) 35%,
    rgba(0,0,0,0.4) 60%,
    transparent 100%);
  pointer-events: none;
}
/* Bottom fade-out into Projects. Extended 420px ramp matching Projects' top
   tone (#04040c) so the transition reads as one continuous gradient. */
.studies-exp-wrap::after {
  content: "";
  position: absolute; bottom: 0; left: 0; right: 0;
  height: 420px;
  z-index: 1;
  background: linear-gradient(to top,
    #04040c 0%,
    rgba(4,4,12,0.92) 15%,
    rgba(4,4,12,0.7) 35%,
    rgba(4,4,12,0.4) 60%,
    transparent 100%);
  pointer-events: none;
}

/* ════════════════════════════
   ABOUT — black + teal + slight purple (matches hero palette)
════════════════════════════ */
#about {
  /* Transparent — sits inside .studies-exp-wrap and uses the shared video bg
     (getty.mp4) + overlay rendered by the wrapper. The wrapper's ::before
     handles the fade-in from the hero, so #about doesn't need its own. */
  background: transparent;
  overflow: hidden;
  position: relative;
}

/* ════════════════════════════
   ABOUT
════════════════════════════ */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 0.85fr;
  gap: clamp(40px, 6vw, 88px);
  align-items: center;
}
@media (max-width: 880px){ .about-grid { grid-template-columns: 1fr; gap: 48px; } }

.about__copy p {
  font-family: var(--body);
  font-weight: 300;
  font-size: 15px;
  line-height: 1.85;
  color: rgba(255,255,255,0.86);
  margin-bottom: 18px;
  letter-spacing: 0.012em;
}
.about__copy p:last-child { margin-bottom: 0; }
.about__copy strong { font-weight: 500; color: var(--ink); }
.about__copy em { font-style: italic; color: var(--violet-2); }
.about__copy a {
  color: var(--violet-2);
  border-bottom: 1px solid rgba(182,157,255,0.4);
  transition: opacity .3s var(--ease);
}
.about__copy a:hover { opacity: 0.7; }

.about__portrait {
  margin: 0 auto;
  width: clamp(280px, 36vw, 420px);
  aspect-ratio: 1 / 1;
  border-radius: 18px;
  overflow: hidden;
  position: relative;
  background: var(--card);
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.12),
    0 30px 80px rgba(0,0,0,0.6),
    0 0 60px rgba(110,58,255,0.08);
}
.about__portrait::before {
  content: "";
  position: absolute; inset: -3px;
  border-radius: 20px;
  background: conic-gradient(from 0deg, var(--violet), var(--magenta), var(--cyan), var(--violet));
  opacity: 0;
  transition: opacity .6s var(--ease);
  z-index: -1;
  filter: blur(12px);
  animation: spin 12s linear infinite;
}
.about__portrait:hover::before { opacity: 0.45; }
.about__portrait img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 1.2s var(--ease);
  position: relative;
}
.about__portrait:hover img { transform: scale(1.04); }
@keyframes spin { to { transform: rotate(360deg); } }

/* ════════════════════════════
   STUDIES
════════════════════════════ */
.studies-list {
  display: grid;
  gap: 36px;
  max-width: 880px;
  margin: 0 auto;
  position: relative; z-index: 2;
}
.study-row {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 56px;
  align-items: center;
  padding: 8px 0;
}
@media (max-width: 720px){
  .study-row { grid-template-columns: 1fr; gap: 16px; text-align: center; }
}
.study-row__logo {
  height: 96px;
  display: flex; align-items: center; justify-content: center;
}
.study-row__logo img {
  max-height: 80px; max-width: 100%;
  object-fit: contain;
  filter: brightness(1.05);
}
/* Per-logo size tweaks so the row reads visually balanced even though each
   brand mark has different intrinsic proportions. */
.study-row__logo img[alt="Reading College"] { max-height: 92px; }
.study-row__logo img[alt="Escape Studios"]  { max-height: 56px; }
.study-row__title {
  font-family: var(--body);
  font-weight: 400;
  font-size: 16px;
  letter-spacing: 0.04em;
  color: var(--ink);
  margin-bottom: 6px;
  text-transform: uppercase;
}
.study-row__year {
  font-family: var(--body);
  font-weight: 300;
  font-size: 14px;
  color: var(--muted);
  letter-spacing: 0.02em;
}
.study-row__year strong { font-weight: 500; color: var(--violet-2); }

/* ════════════════════════════
   EXPERIENCE
════════════════════════════ */
.exp-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: clamp(40px, 5vw, 80px) clamp(48px, 6vw, 96px);
  max-width: 1080px;
  margin: 0 auto;
  position: relative; z-index: 2;
}

.exp-row {
  flex: 0 0 calc((100% - clamp(48px, 6vw, 96px)) / 2);
  max-width: calc((100% - clamp(48px, 6vw, 96px)) / 2);
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 32px;
  align-items: center;
}
.exp-row__logo img { transition: none; }
@media (max-width: 720px){ .exp-row { flex-basis: 100%; max-width: 100%; } }
.exp-row__logo {
  height: 80px;
  display: flex; align-items: center; justify-content: center;
}
.exp-row__logo img {
  max-height: 72px; max-width: 100%;
  object-fit: contain;
  filter: brightness(1.05);
}
.exp-row__role {
  font-family: var(--body);
  font-weight: 300;
  font-size: 15px;
  letter-spacing: 0.02em;
  color: rgba(255,255,255,0.88);
  line-height: 1.5;
}

@media (max-width: 720px){
  .exp-row { grid-template-columns: 1fr; gap: 12px; text-align: center; }
  .exp-row__logo { justify-content: center; }
}

/* CV download CTA — fills the gap below the experience grid */
.exp-cv {
  display: flex;
  justify-content: center;
  margin-top: clamp(48px, 6vw, 80px);
  position: relative;
  z-index: 2;
}
.exp-cv__btn {
  /* Slightly larger than default .btn to feel like a primary action */
  padding: 16px 32px;
  font-size: 14px;
  letter-spacing: 0.18em;
}
.exp-cv__btn svg { width: 16px; height: 16px; }

/* ════════════════════════════
   PROJECTS
════════════════════════════ */
.projects {
  /* Darker base than before with blue + teal-green accents alongside the
     violet. Linear gradient fades to pure black at the bottom 25% so the
     section dissolves seamlessly into the Trusted-by clients strip below. */
  background:
    radial-gradient(1000px 700px at 18% 25%, rgba(50,100,210,0.26) 0%, transparent 65%),
    radial-gradient(900px 650px at 82% 30%, rgba(90,60,180,0.22) 0%, transparent 65%),
    radial-gradient(1100px 700px at 50% 60%, rgba(40,180,160,0.18) 0%, transparent 65%),
    linear-gradient(180deg, #04040c 0%, #060818 25%, #050714 55%, #02030a 80%, #000 100%);
  overflow: hidden;
}
.projects::before {
  content: "";
  position: absolute; inset: 0;
  background:
    radial-gradient(2px 2px at 12% 18%, rgba(255,255,255,0.92), transparent 60%),
    radial-gradient(1px 1px at 28% 42%, rgba(255,255,255,0.75), transparent 60%),
    radial-gradient(1px 1px at 47% 14%, rgba(180,200,255,0.75), transparent 60%),
    radial-gradient(2px 2px at 62% 78%, rgba(255,255,255,0.85), transparent 60%),
    radial-gradient(1px 1px at 79% 32%, rgba(255,255,255,0.6), transparent 60%),
    radial-gradient(1px 1px at 91% 65%, rgba(220,200,255,0.7), transparent 60%),
    radial-gradient(2px 2px at 8% 88%, rgba(255,255,255,0.65), transparent 60%),
    radial-gradient(1px 1px at 38% 62%, rgba(255,255,255,0.55), transparent 60%),
    radial-gradient(1px 1px at 55% 92%, rgba(180,200,255,0.6), transparent 60%),
    radial-gradient(2px 2px at 70% 8%, rgba(255,255,255,0.75), transparent 60%),
    radial-gradient(1px 1px at 19% 73%, rgba(200,220,255,0.7), transparent 60%),
    radial-gradient(1.5px 1.5px at 44% 28%, rgba(255,255,255,0.65), transparent 60%),
    radial-gradient(1px 1px at 67% 51%, rgba(220,180,255,0.55), transparent 60%),
    radial-gradient(1.5px 1.5px at 82% 12%, rgba(255,255,255,0.6), transparent 60%);
  background-size: 500px 500px;
  background-repeat: repeat;
  opacity: 0.95;
  animation: starsDrift 48s linear infinite;
  pointer-events: none;
  z-index: 0;
}
.projects::after {
  content: "";
  position: absolute; inset: 0;
  background:
    radial-gradient(1px 1px at 20% 30%, white, transparent 70%),
    radial-gradient(1px 1px at 60% 70%, white, transparent 70%),
    radial-gradient(1px 1px at 35% 80%, white, transparent 70%),
    radial-gradient(1px 1px at 85% 20%, white, transparent 70%),
    radial-gradient(1px 1px at 11% 55%, rgba(180,200,255,0.7), transparent 70%),
    radial-gradient(1px 1px at 73% 38%, rgba(255,255,255,0.7), transparent 70%),
    radial-gradient(1px 1px at 47% 92%, rgba(220,200,255,0.6), transparent 70%);
  background-size: 280px 280px;
  background-repeat: repeat;
  opacity: 0.65;
  animation: starsDrift2 26s linear infinite;
  pointer-events: none;
  z-index: 0;
}
@keyframes starsDrift  { to { background-position: 500px 500px; } }
@keyframes starsDrift2 { to { background-position: -280px 280px; } }

.proj-band {
  text-align: center;
  font-family: var(--body);
  font-weight: 300;
  font-size: clamp(16px, 1.5vw, 18px);
  letter-spacing: 0.06em;
  color: rgba(255,255,255,0.95);
  margin: clamp(28px, 4vw, 48px) 0 clamp(20px, 3vw, 32px);
  position: relative; z-index: 2;
}

.posters {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: clamp(14px, 1.6vw, 22px);
  max-width: 1180px;
  margin: 0 auto;
  position: relative; z-index: 2;
  --poster-cols: 6;
  --poster-gap: clamp(14px, 1.6vw, 22px);
}
@media (max-width: 1100px){ .posters { --poster-cols: 5; } }
@media (max-width: 880px) { .posters { --poster-cols: 4; } }
@media (max-width: 600px) { .posters { --poster-cols: 3; --poster-gap: 10px; } }
@media (max-width: 400px) { .posters { --poster-cols: 2; } }

.poster {
  flex: 0 0 calc((100% - (var(--poster-cols) - 1) * var(--poster-gap)) / var(--poster-cols));
  max-width: calc((100% - (var(--poster-cols) - 1) * var(--poster-gap)) / var(--poster-cols));
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 6px;
  background: rgba(0,0,0,0.4);
  box-shadow: 0 12px 28px rgba(0,0,0,0.5);
  transition: transform .45s var(--ease), box-shadow .45s var(--ease);
}
.poster img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  transition: transform 1s var(--ease), filter .5s var(--ease);
}
.poster:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 50px rgba(0,0,0,0.7), 0 0 0 1px rgba(182,157,255,0.4), 0 0 32px rgba(110,58,255,0.18);
}
.poster:hover img { transform: scale(1.04); }

.poster__overlay {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 14px 12px 12px;
  background: linear-gradient(180deg, transparent 55%, rgba(0,0,0,0.92) 100%);
  opacity: 0;
  transition: opacity .35s var(--ease);
}
.poster:hover .poster__overlay { opacity: 1; }
.poster__title {
  font-family: var(--display);
  font-weight: 400;
  font-size: 13px;
  letter-spacing: 0.06em;
  color: var(--ink);
  margin-bottom: 2px;
  line-height: 1.15;
  text-transform: uppercase;
}
.poster__meta {
  font-family: var(--body);
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.7);
}

.poster--soon img { filter: brightness(0.85) saturate(0.85); }

/* ════════════════════════════
   CLIENTS STRIP
════════════════════════════ */
#clients {
  background: var(--bg);
  padding-top: clamp(20px, 2.4vw, 32px);
  padding-bottom: clamp(96px, 11vw, 140px);
}
.clients-strip__label {
  text-align: center;
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(11px, 1.1vw, 13px);
  letter-spacing: 0.42em;
  text-transform: uppercase;
  color: rgba(182,157,255,0.85);
  margin: 0 0 clamp(28px, 3.5vw, 40px);
}
.clients-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(32px, 4.5vw, 64px);
  flex-wrap: wrap;
  max-width: 1100px;
  margin: 0 auto;
}
.clients-strip__item {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  /* Per-brand sizing — Netflix/BBC pulled smaller, Disney/Prime nudged larger */
  height: 40px;
}
.clients-strip__item--sm { height: 30px; }
.clients-strip__item--lg { height: 52px; }
.clients-strip__item img {
  max-height: 100%;
  width: auto;
  max-width: 200px;
  object-fit: contain;
  transition: filter .4s var(--ease), transform .4s var(--ease);
  filter: drop-shadow(0 0 0 rgba(182,157,255,0));
}
.clients-strip__item:hover img {
  transform: translateY(-2px);
  filter:
    drop-shadow(0 0 12px rgba(182,157,255,0.55))
    drop-shadow(0 0 28px rgba(110,58,255,0.35));
}
@media (max-width: 720px){
  .clients-strip { gap: 24px; }
  .clients-strip__item    { height: 30px; }
  .clients-strip__item--sm { height: 22px; }
  .clients-strip__item--lg { height: 40px; }
}

/* ════════════════════════════
   VFX SHOWREEL
════════════════════════════ */
#vfx-showreel { background: var(--bg); }
.glow-frame {
  max-width: 1100px;
  margin: 0 auto;
  position: relative;
  border-radius: 10px;
  padding: 1.5px;
  background: linear-gradient(135deg, var(--violet) 0%, var(--violet-2) 30%, var(--violet) 60%, var(--violet-3) 100%);
  background-size: 250% 250%;
  animation: glow-shift 8s ease-in-out infinite;
  /* Extended halo — additional softer ring at 240px so the glow trails out
     beyond the frame's edges and dissolves gradually instead of clipping. */
  box-shadow:
    0 0 24px rgba(110,58,255,0.45),
    0 0 80px rgba(110,58,255,0.32),
    0 0 160px rgba(110,58,255,0.18),
    0 0 240px rgba(110,58,255,0.10);
  z-index: 2;
}
@keyframes glow-shift {
  0%, 100% { background-position: 0% 50%; }
  50%      { background-position: 100% 50%; }
}
.glow-frame--silver {
  background: linear-gradient(135deg, #ffffff 0%, #e0e0f0 30%, #ffffff 60%, #c8c8d8 100%);
  background-size: 250% 250%;
  box-shadow:
    0 0 24px rgba(255,255,255,0.22),
    0 0 60px rgba(255,255,255,0.14),
    0 0 120px rgba(255,255,255,0.08);
}
.glow-frame__inner {
  background: #000;
  border-radius: 9px;
  overflow: hidden;
  position: relative;
}

.vfx-reel-frame {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #000;
  overflow: hidden;
}
.vfx-reel-frame__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.vfx-gate {
  position: absolute;
  inset: 0;
  display: flex; align-items: center; justify-content: center;
  flex-direction: column;
  gap: 28px;
  padding: clamp(32px, 6vw, 72px);
  background:
    radial-gradient(900px 320px at 50% 100%, rgba(110,58,255,0.32), transparent 60%),
    radial-gradient(600px 200px at 50% 0%, rgba(214,58,255,0.16), transparent 60%),
    linear-gradient(135deg, rgba(10,8,22,0.94) 0%, rgba(5,3,9,0.96) 100%);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  z-index: 2;
  transition: opacity .5s var(--ease), visibility .5s var(--ease);
}
.vfx-gate.is-unlocked {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.vfx-gate__label {
  font-family: var(--body);
  font-weight: 300;
  font-size: clamp(16px, 1.6vw, 20px);
  letter-spacing: 0.04em;
  color: rgba(255,255,255,0.85);
}
.vfx-gate__field {
  display: flex; align-items: center; gap: 14px;
  width: min(100%, 480px);
  border-bottom: 1px solid rgba(255,255,255,0.45);
  padding-bottom: 8px;
  transition: border-color .3s var(--ease);
}
.vfx-gate__field:focus-within { border-color: var(--violet-2); }
.vfx-gate__field input {
  flex: 1;
  background: transparent;
  border: 0;
  outline: none;
  font-family: var(--body);
  font-weight: 300;
  font-size: 15px;
  letter-spacing: 0.02em;
  color: var(--ink);
  padding: 6px 0;
  cursor: text;
}
.vfx-gate__field input::placeholder { color: rgba(255,255,255,0.5); }
.vfx-gate__field button {
  width: 36px; height: 36px;
  border-radius: 8px;
  background: var(--violet);
  color: #fff;
  display: grid; place-items: center;
  transition: background-color .3s var(--ease), transform .3s var(--ease);
}
.vfx-gate__field button:hover { background: var(--violet-2); transform: translateX(2px); }
.vfx-gate__field button svg { width: 14px; height: 14px; }

.vfx-gate.is-shake { animation: shake 0.5s; }
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-6px); }
  75% { transform: translateX(6px); }
}

.vfx-gate__cta { margin-top: 8px; }
.vfx-gate__msg {
  font-family: var(--body);
  font-size: 12px;
  color: var(--violet-2);
  margin-top: 8px;
  min-height: 18px;
  letter-spacing: 0.04em;
}
.vfx-gate__msg--err { color: #ff6e8a; }

/* ════════════════════════════
   VFX & AI — 5 video tiles, subtle galaxy bg, smooth blends
════════════════════════════ */
/* Shared backdrop wrapper for VFX Showreel + VFX & AI so they read as one
   continuous violet-lit chamber. The .ambient inside .reel-stack provides
   the soft violet glow that floods through both sections. Sections inside
   are transparent so the wrapper bg shows through everywhere. */
.reel-stack {
  position: relative;
  /* Black-dominant base with soft violet glow above AND below the showreel
     frame so the glow fades symmetrically rather than ending in a sharp cut.
     Subtle blue/teal accents add depth without taking over. */
  background:
    /* Violet wash above showreel frame */
    radial-gradient(1100px 600px at 50% 25%, rgba(110,58,255,0.18) 0%, transparent 65%),
    /* Violet wash below showreel frame — mirrors the top so the glow doesn't
       cut sharply where #vfx-showreel ends and #vfx-ai begins */
    radial-gradient(1100px 600px at 50% 55%, rgba(110,58,255,0.16) 0%, transparent 65%),
    /* Atmospheric blue + teal at corners for chromatic interest */
    radial-gradient(900px 700px at 18% 28%, rgba(50,100,200,0.14) 0%, transparent 70%),
    radial-gradient(800px 600px at 82% 80%, rgba(40,180,170,0.10) 0%, transparent 70%),
    #020208;
  overflow: hidden;
}
/* Remove the cyan secondary blob from the ambient inside reel-stack so it
   doesn't fight the violet wash — keep just the violet glow on top. */
.reel-stack > .ambient::after { display: none; }
.reel-stack > .ambient {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}
.reel-stack > section { background: transparent; position: relative; z-index: 1; }
/* Generous bottom padding so the showreel's violet glow halo has room to
   dissolve naturally before VFX & AI begins, instead of being clipped by
   the section boundary. */
#vfx-showreel { padding-bottom: clamp(80px, 10vw, 140px); }
#vfx-ai { padding-top: clamp(48px, 7vw, 96px); }
/* Faint star drift, very subtle */
#vfx-ai > .galaxy {
  position: absolute; inset: 0; z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(1px 1px at 18% 22%, rgba(255,255,255,0.55), transparent 65%),
    radial-gradient(1px 1px at 42% 68%, rgba(180,200,255,0.5), transparent 65%),
    radial-gradient(1.5px 1.5px at 73% 35%, rgba(255,255,255,0.6), transparent 65%),
    radial-gradient(1px 1px at 88% 80%, rgba(220,200,255,0.4), transparent 65%),
    radial-gradient(1px 1px at 32% 88%, rgba(255,255,255,0.45), transparent 65%);
  background-size: 600px 600px;
  background-repeat: repeat;
  opacity: 0.45;
  animation: starsDrift 200s linear infinite;
}
#vfx-ai::before {
  content: "";
  position: absolute; top: 0; left: 0; right: 0;
  height: 220px;
  background: linear-gradient(to bottom, #000 0%, transparent 100%);
  z-index: 1;
  pointer-events: none;
}
#vfx-ai::after {
  content: "";
  position: absolute; bottom: 0; left: 0; right: 0;
  height: 220px;
  background: linear-gradient(to top, #000 0%, transparent 100%);
  z-index: 1;
  pointer-events: none;
}
/* Container override — wider for VFX & AI to allow 30% bigger tiles */
#vfx-ai .container { max-width: 1640px; }

.vfx-ai-track {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: clamp(10px, 1.4vw, 20px);
  position: relative; z-index: 2;
}
.vfx-ai-track--3 { grid-template-columns: repeat(3, 1fr); }
/* Static row container for VFX & AI breakdowns — mirrors Kepler's .ai-strip-track
   layout pattern but without the marquee animation. .ai-strip-item children keep
   their flex-friendly width clamp from the existing rule (lines 1449-1459). */
.vfx-ai-row {
  display: flex;
  flex-wrap: wrap;
  gap: clamp(10px, 1.4vw, 20px);
  justify-content: center;
  position: relative; z-index: 2;
}
@media (max-width: 1100px){ .vfx-ai-track { grid-template-columns: repeat(4, 1fr); } .vfx-ai-track--3 { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 880px) { .vfx-ai-track { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 600px) { .vfx-ai-track, .vfx-ai-track--3 { grid-template-columns: repeat(2, 1fr); gap: 10px; } }

.vfx-ai-tile {
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  background: var(--card);
  border-radius: 4px;
  transition: transform .4s var(--ease), box-shadow .4s var(--ease);
  cursor: pointer;
}
.vfx-ai-tile:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 36px rgba(0,0,0,0.65), 0 0 0 1px rgba(182,157,255,0.32);
}
/* Iframe fill — Kepler approach.
   Default: iframe matches container exactly. Vimeo background=1 mode applies
   object-fit:cover to the video element inside the iframe, so portrait/square
   videos fill the portrait tile naturally.
   .is-landscape: JS adds this class for landscape sources, sizing iframe wider
   so the video shows more horizontally (less heavy side-crop). */
.vfx-ai-tile iframe {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  border: 0;
  pointer-events: none;
}
.vfx-ai-tile.is-landscape iframe {
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 225%;
  height: 100%;
}
.vfx-ai-tile__placeholder {
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at center, rgba(110,58,255,0.18), transparent 70%), #0a0a14;
}
.vfx-ai-tile__open-cue {
  position: absolute;
  bottom: 10px; right: 10px;
  width: 32px; height: 32px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: rgba(0,0,0,0.55);
  backdrop-filter: blur(8px);
  color: #fff;
  font-size: 14px;
  z-index: 3;
  pointer-events: none;
  opacity: 0;
  transition: opacity .35s var(--ease);
}
.vfx-ai-tile:hover .vfx-ai-tile__open-cue { opacity: 1; }

/* ════════════════════════════
   SOFTWARE — 5×4 centered grid, uniform icons
════════════════════════════ */
#software {
  background: var(--bg);
  position: relative;
  overflow: hidden;
  /* Tighten the bottom so AI Showreel sits closer. */
  padding-bottom: clamp(40px, 5vw, 64px);
}

.tools-grid {
  display: flex;
  flex-direction: column;
  gap: clamp(20px, 2.8vw, 36px);
  max-width: 1240px;
  margin: 0 auto;
  position: relative; z-index: 2;
  --tool-gap: clamp(10px, 1vw, 14px);
}
.tools-row {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: clamp(20px, 2.4vw, 36px);
  align-items: center;
  padding-bottom: clamp(16px, 2vw, 24px);
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.tools-row:last-child { border-bottom: 0; padding-bottom: 0; }
.tools-row__label {
  font-family: var(--display);
  font-weight: 400;
  font-size: 13px;
  letter-spacing: 0.42em;
  text-transform: uppercase;
  color: rgba(182,157,255,0.95);
  margin: 0;
  text-align: right;
  padding-right: 16px;
  position: relative;
}
.tools-row__label::after {
  content: "";
  position: absolute;
  right: 0; top: 50%;
  width: 1px; height: 28px;
  transform: translateY(-50%);
  background: linear-gradient(to bottom, transparent, rgba(110,58,255,0.7), transparent);
}
.tools-row__items {
  display: flex;
  flex-wrap: wrap;
  gap: var(--tool-gap);
  align-items: stretch;
}
@media (max-width: 880px){
  .tools-row { grid-template-columns: 1fr; gap: 16px; }
  .tools-row__label { text-align: center; padding-right: 0; padding-bottom: 8px; }
  .tools-row__label::after { right: 50%; top: auto; bottom: 0; transform: translateX(50%); width: 28px; height: 1px; background: linear-gradient(90deg, transparent, rgba(110,58,255,0.7), transparent); }
  .tools-row__items { justify-content: center; }
}

.tool {
  flex: 0 0 110px;
  width: 110px;
  background: linear-gradient(160deg, rgba(255,255,255,0.05) 0%, rgba(255,255,255,0.02) 100%);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 14px;
  padding: 16px 6px 12px;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 10px;
  text-align: center;
  transition: background-color .35s var(--ease), border-color .35s var(--ease), transform .35s var(--ease), box-shadow .35s var(--ease);
  height: 116px;
}
@media (max-width: 480px){ .tool { flex-basis: 92px; width: 92px; height: 102px; padding: 12px 4px 8px; } }
.tool:hover {
  background: linear-gradient(160deg, rgba(110,58,255,0.10) 0%, rgba(255,255,255,0.03) 100%);
  border-color: rgba(182,157,255,0.4);
  transform: translateY(-3px);
  box-shadow: 0 12px 24px rgba(110,58,255,0.16);
}
.tool__icon {
  width: 48px; height: 48px;
  display: grid; place-items: center;
  flex-shrink: 0;
}
.tool__icon img {
  width: 44px; height: 44px;
  object-fit: contain;
  display: block;
}
.tool__name {
  font-family: var(--body);
  font-weight: 400;
  font-size: 11px;
  letter-spacing: 0.04em;
  color: rgba(255,255,255,0.88);
  line-height: 1.25;
  display: flex; align-items: center;
  min-height: 28px;
}

/* ════════════════════════════
   AI SHOWREEL
════════════════════════════ */
/* AI Showreel — background provided by .bg-video--reel + soft overlay (same
   gradient video as the reel-stack chamber, so the page has a unified look). */
#ai-showreel {
  position: relative;
  /* Reduced top padding so this section sits much closer to Software above. */
  padding-top: clamp(40px, 6vw, 80px);
  padding-bottom: clamp(60px, 7vw, 96px);
  background: #000;
  overflow: hidden;
}

/* AI Showreel — Vimeo official embed wrapper (16:9 frame). */
.ai-reel-embed {
  position: relative;
  width: 100%;
  padding-top: 56.25%;
  background: #000;
}
.ai-reel-embed iframe {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  border: 0;
}

.ai-reel-player {
  aspect-ratio: 16 / 9;
  position: relative;
  cursor: pointer;
  overflow: hidden;
  background: #000;
}
.ai-reel-player iframe {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.ai-reel-player.is-landscape iframe {
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 225%;
  height: 100%;
}
.ai-reel-player__placeholder {
  position: absolute; inset: 0;
  display: grid; place-items: center;
  background:
    radial-gradient(800px 400px at 50% 50%, rgba(64,64,128,0.25), transparent 60%),
    linear-gradient(180deg, #0a0a14 0%, #020205 100%);
  color: rgba(255,255,255,0.45);
  font-family: var(--display);
  font-size: clamp(16px, 1.8vw, 22px);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.ai-reel-player__thumb {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  filter: brightness(0.85);
  transition: filter .35s var(--ease), transform .8s var(--ease);
}
.ai-reel-player:hover .ai-reel-player__thumb {
  filter: brightness(1);
  transform: scale(1.02);
}
.ai-reel-player.is-playing .ai-reel-player__thumb { display: none; }
.ai-reel-player__play {
  position: absolute; inset: 50% 50% auto auto;
  transform: translate(50%, -50%);
  width: 88px; height: 88px;
  z-index: 2;
  color: var(--ink);
  filter: drop-shadow(0 4px 24px rgba(0,0,0,0.65));
  transition: transform .35s var(--ease);
}
.ai-reel-player__play:hover { transform: translate(50%, -50%) scale(1.06); }
.ai-reel-player.is-playing .ai-reel-player__play,
.ai-reel-player.is-playing .ai-reel-player__placeholder { display: none; }

/* AI Visuals subtitle (above the strip) */
.ai-visuals-sub {
  text-align: center;
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(14px, 1.5vw, 18px);
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: rgba(182,157,255,0.95);
  margin: clamp(56px, 8vw, 88px) 0 clamp(28px, 4vw, 48px);
  position: relative; z-index: 2;
}

/* ════════════════════════════
   AI VISUALS STRIP — auto-scrolling 4:5 video tiles, full-bleed
════════════════════════════ */
.ai-strip-wrap {
  position: relative;
  margin-top: clamp(48px, 6vw, 72px);
  overflow: hidden;
  z-index: 2;
  /* Break out of the section container to span full viewport width */
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  width: 100vw;
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 3%, #000 97%, transparent 100%);
          mask-image: linear-gradient(90deg, transparent 0%, #000 3%, #000 97%, transparent 100%);
}
.ai-strip {
  display: flex;
  gap: 8px;
  width: max-content;
  animation: aiScroll 180s linear infinite;
  will-change: transform;
}
.ai-strip:hover { animation-play-state: paused; }
.ai-strip-item {
  flex: 0 0 auto;
  width: clamp(220px, 22vw, 320px);
  aspect-ratio: 4 / 5;
  position: relative;
  overflow: hidden;
  background: var(--card);
  border-radius: 6px;
  transition: transform .4s var(--ease), box-shadow .4s var(--ease);
  cursor: pointer;
}
.ai-strip-item:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 16px 36px rgba(0,0,0,0.65), 0 0 0 1px rgba(182,157,255,0.42), 0 0 32px rgba(110,58,255,0.22);
  z-index: 5;
}
/* Same fill strategy as VFX & AI tiles. */
.ai-strip-item iframe {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  border: 0;
  pointer-events: none;
}
.ai-strip-item.is-landscape iframe {
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 225%;
  height: 100%;
}
.ai-strip-item__placeholder {
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at center, rgba(110,58,255,0.15), transparent 70%), #0a0a14;
}
@keyframes aiScroll {
  to { transform: translateX(-50%); }
}

/* ════════════════════════════
   AI BUSINESS — mixed-orientation horizontal gallery
   (images preserve native aspect via fixed height + auto width)
════════════════════════════ */
.ai-business-sub {
  text-align: center;
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(13px, 1.4vw, 17px);
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: rgba(182,157,255,0.85);
  margin: clamp(56px, 7vw, 88px) 0 clamp(20px, 3vw, 28px);
  position: relative; z-index: 2;
}
.ai-business-wrap {
  position: relative;
  z-index: 2;
  overflow: hidden;
  /* Full-bleed like the AI strip */
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  width: 100vw;
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 3%, #000 97%, transparent 100%);
          mask-image: linear-gradient(90deg, transparent 0%, #000 3%, #000 97%, transparent 100%);
}
.ai-business-track {
  display: flex;
  gap: 10px;
  width: max-content;
  animation: aiBusinessScroll 200s linear infinite;
  will-change: transform;
  align-items: stretch;
}
.ai-business-track:hover { animation-play-state: paused; }
@keyframes aiBusinessScroll {
  to { transform: translateX(-50%); }
}
.ai-business-item {
  flex: 0 0 auto;
  height: clamp(280px, 36vw, 440px);
  position: relative;
  overflow: hidden;
  background: #0a0a14;
  border-radius: 4px;
  cursor: pointer;
  transition: transform .4s var(--ease), box-shadow .4s var(--ease);
}
.ai-business-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 36px rgba(0,0,0,0.65), 0 0 0 1px rgba(182,157,255,0.42), 0 0 32px rgba(110,58,255,0.22);
  z-index: 5;
}
.ai-business-item img {
  height: 100%;
  width: auto;
  display: block;
  transition: transform 1s var(--ease);
}
.ai-business-item:hover img { transform: scale(1.04); }
.ai-business-item--video {
  /* PAP video source is 4:5 portrait — frame matches source so cover-fill is exact. */
  aspect-ratio: 4 / 5;
}
.ai-business-item--video iframe {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  /* Slight oversize so any aspect drift from Vimeo's player gets clipped cleanly. */
  width: 104%;
  height: 104%;
  border: 0;
  pointer-events: none;
}
.ai-business-item--video.is-landscape iframe {
  /* Already landscape so iframe matches container — keep as-is */
}
@media (max-width: 720px) {
  .ai-business-item { height: clamp(220px, 50vw, 320px); }
  .ai-business-track { animation-duration: 280s; }
}

/* ════════════════════════════
   OTHER WORK
════════════════════════════ */
#other-work { background: var(--bg); }
.ow-track {
  display: flex;
  gap: clamp(6px, 0.8vw, 12px);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  padding-bottom: 4px;
}
.ow-track::-webkit-scrollbar { display: none; }
.ow-item {
  flex: 0 0 auto;
  width: clamp(220px, 22vw, 320px);
  aspect-ratio: 4 / 5;
  scroll-snap-align: start;
  overflow: hidden;
  background: var(--card);
  cursor: zoom-in;
  position: relative;
  border-radius: 4px;
}
.ow-item img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 1s var(--ease), filter .5s var(--ease);
}
.ow-item:hover img { transform: scale(1.04); filter: brightness(1.05); }

.ow-wrap { position: relative; z-index: 2; }

.carousel-arrow {
  position: absolute; top: 50%; transform: translateY(-50%);
  z-index: 5;
  width: 44px; height: 44px;
  display: grid; place-items: center;
  background: rgba(0,0,0,0.85);
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 50%;
  color: var(--ink);
  font-size: 22px; font-family: var(--body);
  transition: background-color .3s var(--ease), border-color .3s var(--ease), transform .3s var(--ease);
}
.carousel-arrow--prev { left: -8px; }
.carousel-arrow--next { right: -8px; }
.carousel-arrow:hover { background: var(--violet); border-color: var(--violet); transform: translateY(-50%) scale(1.06); }
@media (max-width: 720px){ .carousel-arrow { width: 38px; height: 38px; font-size: 18px; } }

/* ════════════════════════════
   CONTACT
════════════════════════════ */
#contact {
  padding-block: clamp(120px, 16vw, 200px);
  background: var(--bg);
  position: relative;
  overflow: hidden;
  isolation: isolate;
}
.contact-bg {
  position: absolute; inset: 0;
  z-index: 0;
  overflow: hidden;
  background: #000;
}
.contact-bg__video {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  /* Cover-fit any viewport: 16:9 source oversized to fill both dimensions. */
  width: 100vw;
  height: 56.25vw;
  min-height: 100%;
  min-width: 177.78vh;
  pointer-events: none;
  border: 0;
  /* Brighter so the source video reads through the overlay. */
  filter: brightness(0.78) saturate(0.95);
}
/* Top edge fades from black so it blends seamlessly into AI Showreel above. */
.contact-bg__overlay {
  position: absolute; inset: 0;
  background:
    radial-gradient(900px 600px at 50% 50%, rgba(0,0,0,0.18) 0%, transparent 70%),
    linear-gradient(180deg,
      #000 0%,
      rgba(0,0,0,0.55) 8%,
      rgba(0,0,0,0.35) 30%,
      rgba(0,0,0,0.4) 60%,
      rgba(0,0,0,0.7) 100%);
  z-index: 1;
}
#contact > .container { position: relative; z-index: 2; }
.contact-headline {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(28px, 4.4vw, 60px);
  letter-spacing: 0.06em;
  line-height: 1.2;
  color: var(--ink);
  text-align: center;
  margin: 0 auto clamp(28px, 4vw, 40px);
  max-width: 22ch;
  text-transform: uppercase;
  position: relative; z-index: 2;
}
.contact-email {
  display: inline-flex; align-items: center; gap: 14px;
  font-family: var(--body);
  font-weight: 300;
  font-size: clamp(18px, 2.2vw, 28px);
  letter-spacing: 0.04em;
  color: var(--ink);
  border-bottom: 1px solid rgba(255,255,255,0.32);
  padding-bottom: 8px;
  transition: color .3s var(--ease), border-color .3s var(--ease);
}
.contact-email svg { width: 22px; height: 22px; transition: transform .3s var(--ease); }
.contact-email:hover { color: var(--violet-2); border-color: var(--violet-2); }
.contact-email:hover svg { transform: translateX(6px); }

.contact-center { text-align: center; position: relative; z-index: 2; }

/* Contact card grid — centered, no headline/email bar above. */
.contact-cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(320px, 1fr));
  gap: 22px;
  max-width: 880px;
  margin: clamp(56px, 7vw, 88px) auto 0;
  position: relative; z-index: 2;
  justify-content: center;
}
@media (max-width: 720px){ .contact-cards { grid-template-columns: 1fr; max-width: 480px; } }

.contact-card {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 22px 26px;
  background: rgba(8, 8, 14, 0.55);
  -webkit-backdrop-filter: blur(14px);
          backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
  color: var(--ink);
  transition: border-color .3s var(--ease), background-color .3s var(--ease), transform .3s var(--ease), box-shadow .3s var(--ease);
}
.contact-card:not(.contact-card--static):hover {
  border-color: rgba(182, 157, 255, 0.55);
  background: rgba(20, 12, 36, 0.65);
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(110, 58, 255, 0.22), 0 0 0 1px rgba(182, 157, 255, 0.25);
}
.contact-card__icon {
  flex: 0 0 56px;
  width: 56px; height: 56px;
  display: grid; place-items: center;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  color: rgba(214, 171, 255, 0.95);
  overflow: hidden;
}
.contact-card__icon svg { width: 24px; height: 24px; }
/* IMDb wordmark badge — high-contrast yellow, no SVG glyph confusion */
.contact-card__icon--imdb {
  background: #f5c518;
  border-color: rgba(0, 0, 0, 0.2);
  color: #000;
}
.contact-card__icon--imdb span {
  font-family: var(--display);
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.04em;
  color: #000;
}
/* Studio card uses the Kepler Visuals logo image */
.contact-card__icon--logo {
  background: rgba(255, 255, 255, 0.04);
  padding: 6px;
}
.contact-card__icon--logo img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  filter: brightness(1.1);
}
.contact-card__body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.contact-card__label {
  font-family: var(--display);
  font-weight: 400;
  font-size: 11px;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: rgba(214, 171, 255, 0.9);
}
.contact-card__value {
  font-family: var(--body);
  font-weight: 300;
  font-size: 16px;
  letter-spacing: 0.01em;
  color: rgba(255, 255, 255, 0.94);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.contact-card--static {
  cursor: default;
}

/* ════════════════════════════
   FOOTER
════════════════════════════ */
.footer {
  background: var(--bg);
  border-top: 1px solid var(--line);
  padding: 28px 0;
  font-family: var(--body);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--muted-2);
  position: relative; z-index: 2;
}
.footer .container {
  display: flex; justify-content: space-between; align-items: center;
  gap: 16px; flex-wrap: wrap;
}
.footer a { color: rgba(255,255,255,0.78); border-bottom: 1px solid var(--line); padding-bottom: 1px; }
.footer a:hover { color: var(--violet-2); border-color: var(--violet-2); }

/* ════════════════════════════
   LIGHTBOX
════════════════════════════ */
.lightbox {
  display: none;
  position: fixed; inset: 0;
  z-index: 1000;
  background: rgba(0,0,0,0.96);
  backdrop-filter: blur(20px);
  align-items: center; justify-content: center;
  padding: clamp(20px, 4vw, 64px);
}
.lightbox.is-open { display: flex; }
.lightbox__content {
  position: relative;
  display: flex; align-items: center; justify-content: center;
  width: 100%; height: 100%;
}
.lightbox img { max-width: min(94vw, 1400px); max-height: 88vh; object-fit: contain; }
.lightbox.is-video .lightbox__content {
  width: min(94vw, 1400px);
  aspect-ratio: 16 / 9;
  max-height: 88vh;
  background: #000;
  border-radius: 6px;
  overflow: hidden;
}
.lightbox.is-video iframe {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  border: 0;
}
.lightbox__counter {
  position: absolute;
  bottom: 24px; left: 50%; transform: translateX(-50%);
  font-family: var(--body);
  font-size: 11px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.6);
  pointer-events: none;
}
.lightbox button {
  position: absolute;
  width: 52px; height: 52px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.18);
  color: var(--ink);
  font-size: 22px;
  transition: background-color .3s var(--ease), border-color .3s var(--ease);
  z-index: 10;
}
.lightbox button:hover { background: var(--violet); border-color: var(--violet); }
.lightbox__close { top: 24px; right: 24px; font-size: 28px; }
.lightbox__prev  { left: 24px; top: 50%; transform: translateY(-50%); }
.lightbox__next  { right: 24px; top: 50%; transform: translateY(-50%); }

/* ════════════════════════════
   BACK TO TOP
════════════════════════════ */
.btt {
  position: fixed; bottom: 24px; right: 24px; z-index: 80;
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: rgba(255,255,255,0.06);
  color: var(--ink);
  border: 1px solid rgba(255,255,255,0.18);
  opacity: 0; pointer-events: none;
  transform: translateY(10px);
  transition: opacity .35s var(--ease), transform .35s var(--ease), background-color .3s var(--ease);
}
.btt.is-visible { opacity: 1; pointer-events: auto; transform: translateY(0); }
.btt:hover { background: var(--violet); border-color: var(--violet); }
.btt svg { width: 14px; height: 14px; stroke: currentColor; stroke-width: 1.5; fill: none; }

/* ════════════════════════════
   REVEAL
════════════════════════════ */
[data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .9s var(--ease), transform .9s var(--ease);
}
[data-reveal].is-visible { opacity: 1; transform: translateY(0); }

/* ════════════════════════════
   RESPONSIVE — mobile + tablet polish
════════════════════════════ */
@media (max-width: 1024px) {
  .hero__title { font-size: clamp(48px, 14vw, 96px); }
  .hero__sub { font-size: clamp(15px, 2.4vw, 20px); }
  /* AI strip tile size scaled down for tablet */
  .ai-strip-item { width: clamp(180px, 28vw, 240px); }
  /* VFX & AI grid switches earlier */
  #vfx-ai .container { max-width: 100%; padding: 0 clamp(20px, 3vw, 40px); }
}

@media (max-width: 720px) {
  .section-title h2 { font-size: clamp(22px, 6vw, 32px); }
  .section-title::before, .section-title::after { max-width: 80px; }
  .hero__title { font-size: clamp(44px, 16vw, 80px); padding-left: 0; letter-spacing: 0.04em; }
  .hero__sub { padding-left: 0; }
  .hero__actions { padding-left: 0; }
  .about-grid { gap: 32px; }
  .about__portrait { width: clamp(220px, 60vw, 320px); }
  .study-row { gap: 16px; }
  .study-row__logo { height: 72px; }
  .study-row__logo img { max-height: 64px; }
  /* Tiles smaller on phone */
  .vfx-ai-track { gap: 8px; }
  .ai-strip-item { width: clamp(150px, 42vw, 200px); }
  .ai-strip { gap: 6px; }
  /* Reduce film grain on mobile (perf) */
  body::after { opacity: 0.03; }
  /* Section padding tightened */
  section { padding: clamp(48px, 8vw, 80px) 0; }
}

@media (max-width: 480px) {
  .hero__trading-logo img { height: 56px; }
  .hero__trading-label { font-size: 10px; }
  .ai-strip-item { width: 140px; }
  .ai-strip { animation-duration: 240s; }
  .tools-row__items { gap: 8px; }
}

/* ════════════════════════════
   RESPONSIVE — V2 mobile + tablet pass
════════════════════════════ */
@media (max-width: 1024px) {
  /* Projects: force exactly 2 posters per row on tablet */
  .posters { --poster-cols: 2 !important; --poster-gap: 14px !important; }

  /* Hero: keep title contained and bg visible across portrait tablets */
  .hero__title { font-size: clamp(40px, 9vw, 80px); }
  .hero__inner { padding: 0 clamp(20px, 4vw, 40px); }
  .hero__bg-vimeo {
    /* Larger min coverage so hero bg stays edge-to-edge on portrait viewports */
    width: max(100vw, 220vh);
    height: max(56.25vw, 100vh);
  }

  /* Software section title — prevent the long string from cutting/overflowing */
  #software .section-title h2 {
    font-size: clamp(20px, 4.4vw, 32px);
    line-height: 1.2;
    word-break: keep-all;
    text-wrap: balance;
  }
  #software .section-title::before,
  #software .section-title::after { max-width: 60px; }
}

@media (max-width: 720px) {
  /* Projects: also 2 per row on phones (overrides earlier --poster-cols rules) */
  .posters { --poster-cols: 2 !important; --poster-gap: 12px !important; }

  /* Tighten section padding overall on phones */
  section { padding: clamp(40px, 7vw, 64px) 0; }
  /* Shrink the gap between AI Visuals and Contact */
  #ai-showreel { padding-bottom: clamp(20px, 4vw, 40px); }
  /* Shrink contact section padding so the page doesn't have huge dead air */
  #contact { padding-block: clamp(56px, 9vw, 96px); }
  /* Footer / bottom space — pull tight */
  .footer { padding: clamp(20px, 4vw, 32px) 0; }

  /* VFX Showreel password gate — make sure it's visible and inputs are tappable */
  .vfx-gate {
    padding: clamp(24px, 6vw, 36px);
    gap: 18px;
  }
  .vfx-gate__label { font-size: 14px; }
  .vfx-gate__field {
    width: 100%;
    max-width: 320px;
  }
  .vfx-gate__field input {
    font-size: 15px;
    padding: 8px 0;
    min-width: 0;
    flex: 1;
  }
  .vfx-gate__field button {
    flex-shrink: 0;
  }
  .vfx-gate__cta {
    font-size: 11px;
    padding: 10px 18px;
  }

  /* Software title — explicit phone size so it never truncates */
  #software .section-title h2 {
    font-size: clamp(18px, 5.6vw, 24px);
    line-height: 1.25;
    padding: 0 8px;
    text-wrap: balance;
  }

  /* Hero CTA buttons stack full-width for thumb reach */
  .hero__actions { gap: 12px; }
  .hero__actions .btn { width: 100%; max-width: 280px; justify-content: center; }
}

@media (max-width: 480px) {
  /* Even tighter contact padding on small phones */
  #contact { padding-block: clamp(40px, 8vw, 72px); }
  /* Project posters can stay 2-up — already set above; just tighten gap further */
  .posters { --poster-gap: 10px !important; }
}

/* Disable heavy animations / filters when user prefers reduced motion */
@media (prefers-reduced-motion: reduce) {
  .ai-strip { animation: none !important; }
  .projects::before, .projects::after { animation: none !important; }
  #vfx-ai > .galaxy { animation: none !important; }
  .ambient::before, .ambient::after { animation: none !important; }
  body::after { animation: none !important; }
  .vfx-ai__row { animation: none !important; }
}

/* Save data — disable bg videos when user has Save-Data on */
@media (prefers-reduced-data: reduce) {
  .bg-video { display: none !important; }
}

/* Print */
@media print {
  .nav, .mob-menu, .lightbox, .btt, .cursor, .scroll-progress, .bg-video { display: none !important; }
  body { background: #fff; color: #000; cursor: auto; }
  body::after { display: none; }
}

/* ════════════════════════════
   VFX + AI carousel (V2 build)
════════════════════════════ */
.vfx-ai__row-wrap {
  position: relative;
  z-index: 2;
  overflow: hidden;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  width: 100vw;
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 4%, #000 96%, transparent 100%);
          mask-image: linear-gradient(90deg, transparent 0%, #000 4%, #000 96%, transparent 100%);
}
.vfx-ai__row {
  display: flex;
  gap: 20px;
  width: max-content;
  padding: 4px 0 16px;
  animation: vfxAiScroll 80s linear infinite;
  will-change: transform;
}
.vfx-ai__row:hover { animation-play-state: paused; }
/* Shift by 50% + half of one gap so the duplicate set lands exactly where the
   original started, eliminating the snap-back at loop boundary. The 10px
   correction equals half of the 20px gap between tiles. */
@keyframes vfxAiScroll {
  to { transform: translateX(calc(-50% - 10px)); }
}
/* AI Visuals carousel — slowed to match the AI Social Media & Advertisement
   track's 200s pace so they read as a unified pair below each other. */
.vfx-ai__row--reverse { animation-duration: 200s; }
/* Reverse direction modifier — content scrolls left-to-right instead of
   right-to-left. Uses animation-direction so we don't need a second keyframe. */
.vfx-ai__row--reverse { animation-direction: reverse; }
.vfx-ai__tile {
  position: relative;
  flex: 0 0 auto;
  width: clamp(240px, 26vw, 340px);
  aspect-ratio: 4 / 5;
  border-radius: 6px;
  overflow: hidden;
  background: var(--card);
  border: 1px solid var(--line);
  cursor: pointer;
  transition: border-color 0.3s var(--ease), transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}
.vfx-ai__tile:hover {
  border-color: var(--violet);
  transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(110,58,255,0.32), 0 0 0 1px rgba(182,157,255,0.4);
  z-index: 3;
}
/* Subtle expand cue on hover */
.vfx-ai__tile::after {
  content: "⛶";
  position: absolute;
  bottom: 10px; right: 10px;
  width: 32px; height: 32px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: rgba(0,0,0,0.55);
  backdrop-filter: blur(8px);
  color: #fff;
  font-size: 14px;
  z-index: 4;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.35s var(--ease);
}
.vfx-ai__tile:hover::after { opacity: 1; }
.vfx-ai__tile iframe {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  border: 0;
}
.vfx-ai__tile.is-landscape iframe {
  height: 100%;
  width: 222.22%;
}
.vfx-ai__tile.is-portrait iframe {
  width: 100%;
  height: 155%;
}

/* VFX & AI section ONLY — taller 9:16 portrait tiles with their own cover-fill
   math. AI Visuals carousel and any other reuse of .vfx-ai__tile remain at the
   default 4:5 ratio. */
#vfx-ai .vfx-ai__tile {
  aspect-ratio: 9 / 16;
  width: clamp(200px, 22vw, 280px);
}
#vfx-ai .vfx-ai__tile.is-landscape iframe {
  height: 100%;
  width: 320%;
}
#vfx-ai .vfx-ai__tile.is-portrait iframe {
  width: 100%;
  height: 110%;
}

@media (max-width: 720px) {
  .vfx-ai__row { justify-content: flex-start; padding-left: 24px; padding-right: 24px; margin: 0 -24px; }
  .vfx-ai__tile { width: 78vw; }
  #vfx-ai .vfx-ai__tile { width: 65vw; }
}

/* ════════════════════════════
   VFX + AI fullscreen lightbox
════════════════════════════ */
.vfx-ai__lightbox {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: rgba(0, 0, 0, 0.94);
  -webkit-backdrop-filter: blur(20px);
          backdrop-filter: blur(20px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 56px 32px 32px;
  cursor: auto;
  opacity: 0;
  transition: opacity 0.35s var(--ease);
}
.vfx-ai__lightbox.is-open {
  display: flex;
  opacity: 1;
}
.vfx-ai__lightbox-content {
  position: relative;
  background: #000;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(182, 157, 255, 0.2);
}
.vfx-ai__lightbox-content.is-landscape {
  width: min(92vw, 1280px);
  aspect-ratio: 16 / 9;
}
.vfx-ai__lightbox-content.is-portrait {
  height: min(88vh, 900px);
  aspect-ratio: 9 / 16;
}
.vfx-ai__lightbox-content iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.vfx-ai__lightbox-close {
  position: absolute;
  top: 16px; right: 16px;
  width: 44px; height: 44px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 50%;
  color: #fff;
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  transition: background 0.3s var(--ease), border-color 0.3s var(--ease), transform 0.3s var(--ease);
  z-index: 2;
}
.vfx-ai__lightbox-close:hover {
  background: rgba(110, 58, 255, 0.4);
  border-color: rgba(182, 157, 255, 0.7);
  transform: scale(1.05);
}
@media (prefers-reduced-motion: reduce) {
  .vfx-ai__row { animation: none; }
}
