/* ==========================================================
   GOWCREATES — cinematic scroll portfolio
   Ink black · Emerald accent · Cream typography
   ========================================================== */

@font-face {
  font-family: 'Anton';
  src: url('../vendor/fonts/anton-latin.woff2') format('woff2');
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: 'Inter';
  src: url('../vendor/fonts/inter-latin.woff2') format('woff2');
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --ink: #0a0a0a;
  --ink-2: #101010;
  --cream: #f2efe6;
  --cream-dim: rgba(242, 239, 230, 0.55);
  --emerald: #10b981;
  --emerald-dim: rgba(16, 185, 129, 0.35);
  --display: 'Anton', 'Arial Narrow', sans-serif;
  --body: 'Inter', 'Helvetica Neue', sans-serif;
}

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

html { scroll-behavior: auto; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }

body {
  background: var(--ink);
  color: var(--cream);
  font-family: var(--body);
  font-weight: 400;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--emerald); color: var(--ink); }

a { color: inherit; text-decoration: none; }
a:focus-visible, .btn:focus-visible {
  outline: 2px solid var(--emerald);
  outline-offset: 4px;
}

.accent { color: var(--emerald); }

/* ---------- Grain ---------- */
.grain {
  position: fixed;
  inset: -100px;
  z-index: 90;
  pointer-events: none;
  opacity: 0.07;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grainShift 0.9s steps(4) infinite;
}
@keyframes grainShift {
  0% { transform: translate(0, 0); }
  25% { transform: translate(-40px, 30px); }
  50% { transform: translate(30px, -45px); }
  75% { transform: translate(-25px, -20px); }
  100% { transform: translate(0, 0); }
}

/* ---------- Loader ---------- */
.loader {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: var(--ink);
  display: flex;
  align-items: center;
  justify-content: center;
}
.loader-inner { text-align: center; }
.loader-brand {
  display: block;
  height: clamp(56px, 10vw, 96px);
  width: auto;
  aspect-ratio: 1881 / 836;
  margin: 0 auto;
}
.loader-count {
  display: block;
  margin-top: 1.2rem;
  font-family: var(--display);
  font-size: clamp(3rem, 9vw, 7rem);
  color: var(--cream);
  font-variant-numeric: tabular-nums;
}
.loader-bar {
  width: min(320px, 60vw);
  height: 2px;
  margin: 1.6rem auto 0;
  background: rgba(242, 239, 230, 0.12);
  overflow: hidden;
}
.loader-bar span {
  display: block;
  height: 100%;
  width: 0%;
  background: var(--emerald);
}

/* ---------- Nav ---------- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.4rem clamp(1.2rem, 4vw, 3rem);
  background: linear-gradient(to bottom, rgba(10, 10, 10, 0.72), transparent);
  opacity: 0;
}
.nav-logo { display: block; }
.nav-logo img {
  height: clamp(34px, 4.5vw, 46px);
  width: auto;
  aspect-ratio: 1881 / 836;
  display: block;
}
.nav-cta {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  padding: 0.7rem 1.3rem;
  border: 1px solid rgba(242, 239, 230, 0.25);
  border-radius: 99px;
  transition: border-color 0.35s ease, color 0.35s ease, background 0.35s ease;
}
.nav-cta:hover {
  border-color: var(--emerald);
  color: var(--emerald);
}

/* ---------- Section kickers ---------- */
.section-kicker {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.3em;
  color: var(--cream-dim);
}
.section-kicker.centered { justify-content: center; }
.tick {
  width: 22px;
  height: 2px;
  background: var(--emerald);
  display: inline-block;
}

/* ==========================================================
   HERO
   ========================================================== */
.hero {
  height: 520vh;
  position: relative;
}
.hero-stage {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: hidden;
}
#orbitCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}
.hero-vignette {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at center, transparent 42%, rgba(10, 10, 10, 0.75) 100%),
    linear-gradient(to top, rgba(10, 10, 10, 0.85), transparent 32%);
  pointer-events: none;
}
.hero-copy {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: flex-start;
  padding: 0 clamp(1.2rem, 4vw, 3.4rem) clamp(2rem, 5vh, 4rem);
  pointer-events: none;
}
.hero-kicker {
  font-size: clamp(0.65rem, 1vw, 0.8rem);
  font-weight: 600;
  letter-spacing: 0.34em;
  color: var(--emerald);
  margin-bottom: 0.6rem;
  opacity: 0;
}
.hero-name {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(4.2rem, 16.5vw, 19rem);
  line-height: 0.9;
  letter-spacing: 0.02em;
  white-space: nowrap;
  overflow: hidden;
}
.hero-name .ltr {
  display: inline-block;
  will-change: transform, opacity;
}
.hero-sub {
  max-width: 46ch;
  margin-top: clamp(1rem, 2.5vh, 1.8rem);
  font-size: clamp(0.85rem, 1.25vw, 1.05rem);
  line-height: 1.65;
  color: var(--cream-dim);
}
.hero-sub .w { display: inline-block; will-change: transform, opacity; }

.scroll-hint {
  position: absolute;
  right: clamp(1.2rem, 4vw, 3.4rem);
  bottom: clamp(2rem, 5vh, 4rem);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.8rem;
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.34em;
  color: var(--cream-dim);
}
.scroll-line {
  width: 1px;
  height: 56px;
  background: rgba(242, 239, 230, 0.2);
  position: relative;
  overflow: hidden;
}
.scroll-line::after {
  content: '';
  position: absolute;
  top: -50%;
  left: 0;
  width: 100%;
  height: 50%;
  background: var(--emerald);
  animation: scrollPulse 1.8s ease-in-out infinite;
}
@keyframes scrollPulse {
  0% { top: -50%; }
  100% { top: 110%; }
}

/* ==========================================================
   STATS
   ========================================================== */
.stats {
  position: relative;
  z-index: 2;
  background: var(--ink);
  padding: clamp(5rem, 12vh, 9rem) clamp(1.2rem, 4vw, 3.4rem);
  border-top: 1px solid rgba(242, 239, 230, 0.07);
  border-bottom: 1px solid rgba(242, 239, 230, 0.07);
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(2rem, 4vw, 3rem);
  max-width: 1500px;
  margin: 0 auto;
}
.stat { border-left: 1px solid rgba(242, 239, 230, 0.12); padding-left: clamp(1rem, 2vw, 1.8rem); }
.stat-num {
  display: block;
  font-family: var(--display);
  font-size: clamp(3.2rem, 7.5vw, 7.5rem);
  line-height: 1;
  color: var(--emerald);
  font-variant-numeric: tabular-nums;
}
.stat-label {
  display: block;
  margin-top: 0.9rem;
  font-size: clamp(0.7rem, 1vw, 0.85rem);
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--cream-dim);
}

/* ==========================================================
   PILLARS
   ========================================================== */
.pillars {
  height: 560vh;
  position: relative;
}
.pillars-stage {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: hidden;
}
.bg-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.stage-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to right, rgba(10, 10, 10, 0.88) 0%, rgba(10, 10, 10, 0.55) 55%, rgba(10, 10, 10, 0.35) 100%),
    linear-gradient(to top, rgba(10, 10, 10, 0.9), transparent 40%);
  pointer-events: none;
}
.pillars-content {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0 clamp(1.2rem, 4vw, 3.4rem);
}
.pillar-list {
  list-style: none;
  margin-top: 2.2rem;
  display: flex;
  flex-direction: column;
  gap: clamp(0.4rem, 1.4vh, 1rem);
}
.pillar {
  display: flex;
  align-items: baseline;
  gap: clamp(1rem, 2.5vw, 2.2rem);
  opacity: 0.1;
  transform: translateX(40px);
  will-change: transform, opacity;
}
.pillar-idx {
  font-size: clamp(0.7rem, 1vw, 0.9rem);
  font-weight: 600;
  letter-spacing: 0.2em;
  color: var(--emerald);
}
.pillar-name {
  font-family: var(--display);
  font-size: clamp(2.4rem, 7.2vw, 7.6rem);
  line-height: 1;
  text-transform: uppercase;
  letter-spacing: 0.015em;
}
.pillar.active .pillar-name { color: var(--cream); }
.pillar-progress {
  margin-top: 3rem;
  display: flex;
  align-items: center;
  gap: 1.2rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.25em;
  color: var(--cream-dim);
  font-variant-numeric: tabular-nums;
}
.pillar-bar {
  width: min(260px, 30vw);
  height: 2px;
  background: rgba(242, 239, 230, 0.12);
  overflow: hidden;
}
.pillar-bar span {
  display: block;
  height: 100%;
  width: 0%;
  background: var(--emerald);
}

/* ==========================================================
   WORK
   ========================================================== */
.work {
  position: relative;
  overflow: clip;
}
.work-video {
  position: sticky;
  top: 0;
  height: 100vh;
}
.work .stage-shade {
  position: absolute;
  background:
    linear-gradient(to bottom, rgba(10, 10, 10, 0.92) 0%, rgba(10, 10, 10, 0.68) 30%, rgba(10, 10, 10, 0.8) 100%);
}
.work-content {
  position: relative;
  z-index: 2;
  margin-top: -100vh;
  padding: clamp(6rem, 14vh, 10rem) clamp(1.2rem, 4vw, 3.4rem) clamp(6rem, 14vh, 10rem);
  max-width: 1500px;
  margin-left: auto;
  margin-right: auto;
}
.work-title {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(3rem, 9vw, 9.5rem);
  line-height: 0.92;
  margin: 1.6rem 0 clamp(3rem, 7vh, 5rem);
  text-transform: uppercase;
}
.work-title .outline {
  color: transparent;
  -webkit-text-stroke: 1.5px var(--cream);
}
.work-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(1rem, 2vw, 1.6rem);
}
.card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: clamp(1.6rem, 3vw, 2.6rem);
  min-height: clamp(300px, 42vh, 420px);
  background: rgba(12, 12, 12, 0.6);
  border: 1px solid rgba(242, 239, 230, 0.1);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  overflow: hidden;
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1),
              border-color 0.5s ease,
              background 0.5s ease;
  will-change: transform;
}
.card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(600px circle at var(--mx, 50%) var(--my, 50%), rgba(16, 185, 129, 0.1), transparent 45%);
  opacity: 0;
  transition: opacity 0.5s ease;
  pointer-events: none;
}
.card:hover {
  transform: translateY(-8px);
  border-color: var(--emerald-dim);
  background: rgba(14, 16, 14, 0.75);
}
.card:hover::before { opacity: 1; }
.card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 1.4rem;
}
.card-logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #f5f5f3;
  border-radius: 10px;
  padding: 0.7rem 1.1rem;
  height: clamp(58px, 7vw, 74px);
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}
.card-logo img {
  max-height: 100%;
  max-width: clamp(120px, 14vw, 180px);
  width: auto;
  object-fit: contain;
  display: block;
}
.card:hover .card-logo { transform: translateY(-4px); }
.card-name {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(1.7rem, 3vw, 2.8rem);
  line-height: 0.98;
  margin: 0 0 0.9rem;
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}
.card:hover .card-name { transform: translateX(8px); color: var(--cream); }
.card-pitch {
  font-size: clamp(0.85rem, 1.1vw, 1rem);
  line-height: 1.6;
  color: var(--cream);
  max-width: 44ch;
}
.card-brief {
  margin-top: 0.7rem;
  font-size: clamp(0.78rem, 0.95vw, 0.9rem);
  line-height: 1.65;
  color: var(--cream-dim);
  max-width: 52ch;
}
.card-tags {
  margin-top: auto;
  padding-top: 1.4rem;
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(242, 239, 230, 0.4);
}
.card-arrow {
  font-size: 1.5rem;
  color: var(--cream-dim);
  transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1), color 0.45s ease;
}
.card:hover .card-arrow {
  transform: translate(6px, -6px);
  color: var(--emerald);
}

/* ---------- Logo wall ---------- */
.logo-wall { margin-top: clamp(4rem, 9vh, 7rem); }
.wall-grid {
  margin-top: 2rem;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(0.9rem, 1.6vw, 1.4rem);
}
.wall-tile {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f5f5f3;
  border: 1px solid rgba(242, 239, 230, 0.1);
  border-radius: 12px;
  padding: clamp(1.4rem, 2.4vw, 2.2rem);
  height: clamp(120px, 16vw, 190px);
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.5s ease;
  will-change: transform;
}
.wall-tile img {
  max-width: 72%;
  max-height: 78%;
  object-fit: contain;
  display: block;
}
.wall-tile:hover {
  transform: translateY(-6px);
  box-shadow: 0 18px 44px rgba(16, 185, 129, 0.18);
}

/* ==========================================================
   SHOWREEL — 3D coverflow carousel
   ========================================================== */
.reel {
  position: relative;
  z-index: 2;
  background: var(--ink);
  padding: clamp(5rem, 12vh, 9rem) 0 clamp(3rem, 7vh, 5rem);
  border-top: 1px solid rgba(242, 239, 230, 0.07);
  overflow: hidden;
}
.reel-head { text-align: center; padding: 0 clamp(1.2rem, 4vw, 3.4rem); }
.reel-title {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(3rem, 9vw, 9.5rem);
  line-height: 0.92;
  text-transform: uppercase;
  margin-top: 1.4rem;
}
.reel-title .outline {
  color: transparent;
  -webkit-text-stroke: 1.5px var(--cream);
}
.reel-stage {
  position: relative;
  height: clamp(300px, 56vh, 620px);
  margin-top: clamp(2rem, 5vh, 3.5rem);
  perspective: 1600px;
  touch-action: pan-y;
  user-select: none;
  -webkit-user-select: none;
}
.reel-card {
  position: absolute;
  top: 50%;
  left: 50%;
  aspect-ratio: 16 / 9;
  border-radius: 14px;
  overflow: hidden;
  background: #000;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
  cursor: grab;
  will-change: transform;
}
.reel-card:active { cursor: grabbing; }
.reel-card video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  pointer-events: none;
}
.reel-card-title {
  position: absolute;
  inset: 0;
  margin: 0;
  padding: 0 4%;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(2.2rem, 6vw, 5.6rem);
  line-height: 0.95;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--cream);
  text-shadow: 0 6px 40px rgba(0, 0, 0, 0.45);
  pointer-events: none;
}
.reel-sound {
  position: absolute;
  top: clamp(0.9rem, 2vh, 1.4rem);
  right: clamp(0.9rem, 2vh, 1.4rem);
  background: rgba(10, 10, 10, 0.55);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(242, 239, 230, 0.3);
  color: var(--cream);
  font-family: var(--body);
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  padding: 0.5rem 0.9rem;
  border-radius: 99px;
  cursor: pointer;
  transition: background 0.35s ease, color 0.35s ease, border-color 0.35s ease;
}
.reel-sound:hover {
  border-color: var(--emerald);
  color: var(--emerald);
}
.reel-sound.on {
  background: var(--emerald);
  border-color: var(--emerald);
  color: var(--ink);
}
.reel-chip {
  position: absolute;
  left: 50%;
  bottom: clamp(1rem, 3vh, 1.8rem);
  transform: translateX(-50%);
  background: var(--emerald);
  color: var(--ink);
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  padding: 0.55rem 1.1rem;
  border-radius: 99px;
  white-space: nowrap;
  pointer-events: none;
}
.reel-nav {
  display: flex;
  justify-content: center;
  gap: 0.7rem;
  margin-top: clamp(1.6rem, 4vh, 2.6rem);
}
.reel-btn {
  width: 64px;
  height: 40px;
  border-radius: 99px;
  border: 1px solid rgba(242, 239, 230, 0.25);
  background: transparent;
  color: var(--cream);
  font-family: var(--body);
  font-size: 1.05rem;
  cursor: pointer;
  transition: background 0.35s ease, color 0.35s ease, border-color 0.35s ease, transform 0.35s ease;
}
.reel-btn:hover, .reel-btn:focus-visible {
  background: var(--emerald);
  border-color: var(--emerald);
  color: var(--ink);
  transform: translateY(-2px);
}

/* ==========================================================
   FINALE
   ========================================================== */
.finale {
  position: relative;
  z-index: 2;
  background: var(--ink);
  padding-top: clamp(5rem, 12vh, 9rem);
  border-top: 1px solid rgba(242, 239, 230, 0.07);
  overflow: hidden;
}
.marquee { display: flex; flex-direction: column; gap: 0.6rem; }
.marquee-row {
  display: flex;
  white-space: nowrap;
  will-change: transform;
}
.marquee-row span {
  font-family: var(--display);
  font-size: clamp(3rem, 8.5vw, 9rem);
  line-height: 1;
  text-transform: uppercase;
  padding-right: 0.5em;
}
.marquee-row.reverse span {
  color: transparent;
  -webkit-text-stroke: 1.2px rgba(242, 239, 230, 0.45);
}
.finale-cta {
  text-align: center;
  padding: clamp(4rem, 10vh, 7rem) clamp(1.2rem, 4vw, 3.4rem);
}
.cta-buttons {
  margin-top: 2.4rem;
  display: flex;
  gap: 1.2rem;
  justify-content: center;
  flex-wrap: wrap;
}
.btn {
  font-size: clamp(0.75rem, 1vw, 0.9rem);
  font-weight: 600;
  letter-spacing: 0.18em;
  padding: 1.25rem 2.6rem;
  border-radius: 99px;
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1), background 0.4s ease, color 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease;
}
.btn-solid {
  background: var(--emerald);
  color: var(--ink);
}
.btn-solid:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 40px rgba(16, 185, 129, 0.3);
}
.btn-ghost {
  border: 1px solid rgba(242, 239, 230, 0.3);
  color: var(--cream);
}
.btn-ghost:hover {
  transform: translateY(-4px);
  border-color: var(--emerald);
  color: var(--emerald);
}
.footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 2rem clamp(1.2rem, 4vw, 3.4rem);
  border-top: 1px solid rgba(242, 239, 230, 0.07);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  color: var(--cream-dim);
}
.footer-link {
  transition: color 0.35s ease;
}
.footer-link:hover { color: var(--emerald); }

/* ==========================================================
   Responsive
   ========================================================== */
@media (max-width: 900px) {
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .work-grid { grid-template-columns: 1fr; }
  .wall-grid { grid-template-columns: repeat(2, 1fr); }
  .hero { height: 380vh; }
  .pillars { height: 460vh; }
  .hero-sub { max-width: 90%; }
  .scroll-hint { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .grain { animation: none; }
  .scroll-line::after { animation: none; }
}
