/* ============ TwoSeven Media ============ */
:root {
  --bg: #fbfbfd;
  --ink: #1d1d1f;
  --ink-soft: #6e6e73;
  --hairline: rgba(0, 0, 0, 0.08);
  --accent: #0071e3;
  --radius: 28px;
  --gutter: clamp(20px, 4vw, 64px);
  --font: "Inter", -apple-system, BlinkMacSystemFont, "SF Pro Display", "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 {
  font-family: var(--font);
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }

/* On devices with a fine pointer we hide the native cursor (custom cursor takes over) */
@media (hover: hover) and (pointer: fine) {
  body.custom-cursor, body.custom-cursor a, body.custom-cursor button { cursor: none; }
}

/* ============ Preloader ============ */
.preloader {
  position: fixed; inset: 0; z-index: 200;
  background: var(--bg);
  display: flex; align-items: center; justify-content: center;
}
.preloader__word {
  display: flex; overflow: hidden;
  font-size: clamp(28px, 5vw, 56px);
  font-weight: 800; letter-spacing: 0.28em;
}
.preloader__char { display: inline-block; transform: translateY(120%); }

/* ============ Custom cursor ============ */
.cursor { position: fixed; inset: 0; z-index: 150; pointer-events: none; display: none; }
@media (hover: hover) and (pointer: fine) { .cursor { display: block; } }
.cursor__dot {
  position: absolute; top: 0; left: 0;
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--ink);
  transform: translate(-50%, -50%);
  will-change: transform;
}
.cursor__ring {
  position: absolute; top: 0; left: 0;
  width: 40px; height: 40px; border-radius: 50%;
  border: 1.5px solid rgba(29, 29, 31, 0.35);
  transform: translate(-50%, -50%);
  display: flex; align-items: center; justify-content: center;
  transition: width 0.35s cubic-bezier(0.22, 1, 0.36, 1),
              height 0.35s cubic-bezier(0.22, 1, 0.36, 1),
              background-color 0.35s ease, border-color 0.35s ease;
  will-change: transform;
}
.cursor__label {
  font-size: 11px; font-weight: 600; letter-spacing: 0.14em;
  text-transform: uppercase; color: #fff;
  opacity: 0; transition: opacity 0.25s ease;
}
.cursor--hover .cursor__ring { width: 56px; height: 56px; background: rgba(29, 29, 31, 0.06); }
.cursor--play .cursor__ring {
  width: 92px; height: 92px;
  background: rgba(29, 29, 31, 0.82);
  border-color: transparent;
  backdrop-filter: blur(4px);
}
.cursor--play .cursor__label { opacity: 1; }
.cursor--play .cursor__dot { opacity: 0; }
.cursor--down .cursor__ring { transform: translate(-50%, -50%) scale(0.85); }

/* ============ Nav ============ */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}
.nav--hidden { transform: translateY(-110%); }
.nav__inner {
  margin: 14px var(--gutter) 0;
  padding: 12px 22px;
  display: flex; align-items: center; justify-content: space-between;
  border-radius: 999px;
  background: rgba(251, 251, 253, 0.72);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border: 1px solid var(--hairline);
}
.nav__logo { font-weight: 800; letter-spacing: 0.12em; font-size: 14px; }
.nav__logo span { font-weight: 400; color: var(--ink-soft); margin-left: 4px; }
.nav__links { display: flex; gap: 28px; }
.nav__links a {
  font-size: 14px; font-weight: 500; color: var(--ink-soft);
  transition: color 0.25s ease;
}
.nav__links a:hover { color: var(--ink); }
.nav__cta {
  font-size: 13px; font-weight: 600;
  padding: 9px 18px; border-radius: 999px;
  background: var(--ink); color: #fff;
  transition: background-color 0.25s ease, transform 0.25s ease;
}
.nav__cta:hover { background: #000; }

/* ============ Hero ============ */
.hero {
  position: relative;
  height: 100svh; min-height: 640px;
  display: flex; align-items: flex-end;
  overflow: clip;
}
.hero__media {
  position: absolute; inset: 0;
  overflow: hidden;
  will-change: transform, border-radius;
}
.hero__video, .hero__media img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
}
.hero__video { transform: scale(1.06); will-change: transform; }
.hero__scrim {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0.12) 45%, rgba(0,0,0,0.18) 100%);
}
.hero__content {
  position: relative; z-index: 2;
  padding: 0 var(--gutter) clamp(64px, 12vh, 140px);
  color: #fff;
}
.hero__title {
  font-size: clamp(52px, 9.5vw, 148px);
  font-weight: 700;
  line-height: 0.98;
  letter-spacing: -0.035em;
}
.line { display: block; overflow: hidden; padding-bottom: 0.08em; margin-bottom: -0.08em; }
.line__inner { display: inline-block; transform: translateY(115%); will-change: transform; }
.hero__sub {
  margin-top: 28px;
  font-size: clamp(15px, 1.6vw, 20px);
  font-weight: 500;
  color: rgba(255, 255, 255, 0.82);
  opacity: 0; transform: translateY(20px);
}
.hero__scrollcue {
  position: absolute; right: var(--gutter); bottom: 48px; z-index: 2;
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  color: rgba(255,255,255,0.75);
  font-size: 11px; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase;
}
.hero__scrollline {
  width: 1px; height: 56px;
  background: rgba(255,255,255,0.4);
  overflow: hidden; position: relative;
}
.hero__scrollline::after {
  content: ""; position: absolute; left: 0; top: -100%;
  width: 100%; height: 100%;
  background: #fff;
  animation: scrollcue 1.8s cubic-bezier(0.65, 0, 0.35, 1) infinite;
}
@keyframes scrollcue { 0% { top: -100%; } 55% { top: 0; } 100% { top: 100%; } }

/* ============ Manifesto ============ */
.manifesto {
  padding: clamp(120px, 20vh, 240px) var(--gutter);
  max-width: 1200px; margin: 0 auto;
}
.manifesto__text {
  font-size: clamp(28px, 4.6vw, 64px);
  font-weight: 600;
  line-height: 1.14;
  letter-spacing: -0.025em;
}
.manifesto__text .w { opacity: 0.12; transition: none; }

/* ============ Section heads ============ */
.section-head { padding: 0 var(--gutter); margin-bottom: clamp(40px, 6vw, 80px); }
.section-head__eyebrow {
  display: block;
  font-size: 13px; font-weight: 600;
  letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 18px;
}
.section-head__title {
  font-size: clamp(40px, 6.5vw, 96px);
  font-weight: 700; line-height: 1.02; letter-spacing: -0.03em;
}

/* ============ Work ============ */
.work { padding: clamp(60px, 10vh, 120px) 0; }
.work__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(16px, 2.5vw, 36px);
  padding: 0 var(--gutter);
}
.work-card--full { grid-column: 1 / -1; }
.work-card { position: relative; }
.work-card__media {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 16 / 9;
  clip-path: inset(6% 4% round var(--radius));
  will-change: clip-path;
  background: #e8e8ed;
}
.work-card--half .work-card__media { aspect-ratio: 4 / 5; }
.work-card__video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  transform: scale(1.08);
  transition: transform 0.9s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}
.work-card:hover .work-card__video { transform: scale(1.02); }
.work-card__meta {
  display: flex; align-items: baseline; gap: 18px;
  padding: 20px 8px 0;
}
.work-card__meta h3 {
  font-size: clamp(20px, 2.2vw, 28px);
  font-weight: 700; letter-spacing: -0.02em;
  white-space: nowrap;
}
.work-card__meta p { font-size: 15px; color: var(--ink-soft); line-height: 1.5; }

/* ============ Process — paper to picture ============ */
.process { position: relative; }
.process__pin {
  position: relative;
  height: 100svh; min-height: 640px;
  display: flex; align-items: center; justify-content: center;
  gap: clamp(32px, 5vw, 96px);
  overflow: clip;
  perspective: 1600px;
}
.process__rail {
  position: absolute; left: var(--gutter); top: 50%; z-index: 4;
  transform: translateY(-50%);
}
.process__eyebrow {
  display: block; margin-bottom: 28px;
  font-size: 13px; font-weight: 600;
  letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--ink-soft);
}
.process__steps { list-style: none; display: grid; gap: 18px; }
.process__step {
  display: flex; align-items: baseline; gap: 14px;
  opacity: 0.28;
  transition: opacity 0.4s ease;
}
.process__step.is-active { opacity: 1; }
.process__num {
  font-size: 13px; font-weight: 600; color: var(--ink-soft);
  font-variant-numeric: tabular-nums;
}
.process__label {
  font-size: clamp(22px, 2.6vw, 40px);
  font-weight: 700; letter-spacing: -0.02em;
}
.process__laptop {
  position: relative;
  transform-style: preserve-3d;
  will-change: transform;
}
.process__lid {
  position: relative;
  transform-origin: 50% 100%;
  transform-style: preserve-3d;
  will-change: transform;
}
/* MacBook screen shell — an overlay ring, so the picture never shifts */
.process__chrome {
  position: absolute;
  inset: -4.6% -3.2%;
  border-radius: clamp(18px, 2vw, 28px);
  background: linear-gradient(160deg, #313136 0%, #17171a 30%, #0a0a0c 68%, #26262b 100%);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.11),
    inset 0 0 0 2.5px rgba(0, 0, 0, 0.65),
    inset 0 1px 0 1px rgba(255, 255, 255, 0.05),
    0 54px 110px -36px rgba(0, 0, 0, 0.5),
    0 18px 42px -18px rgba(0, 0, 0, 0.34);
  opacity: 0;
  will-change: opacity;
}
.process__chrome::before {
  /* camera */
  content: "";
  position: absolute; top: 2.1%; left: 50%;
  transform: translateX(-50%);
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #0a0e14;
  box-shadow:
    inset 0 0 2px 1px rgba(66, 88, 122, 0.55),
    0 0 0 1.5px rgba(255, 255, 255, 0.06);
}
/* aluminium body the lid closes onto */
.process__deck {
  position: absolute; top: 100%; left: 50%;
  width: 124%;
  height: clamp(10px, 1.5vw, 17px);
  transform: translate(-50%, 1px) scaleY(0);
  transform-origin: 50% 0%;
  background: linear-gradient(180deg, #f2f2f6 0%, #d8d8de 10%, #bcbcc4 55%, #84848d 90%, #5b5b64 100%);
  border-radius: 2px 2px clamp(10px, 1.2vw, 16px) clamp(10px, 1.2vw, 16px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.6),
    inset 0 -1px 1px rgba(0, 0, 0, 0.22);
  opacity: 0;
  will-change: transform, opacity;
}
.process__deck::after {
  /* thumb scoop */
  content: "";
  position: absolute; top: 0; left: 50%;
  transform: translateX(-50%);
  width: 12.5%; height: 44%;
  background: linear-gradient(180deg, #85858e 0%, #b7b7bf 85%);
  border-radius: 0 0 10px 10px;
  box-shadow: inset 0 2px 3px rgba(0, 0, 0, 0.28);
}
.process__shadow {
  position: absolute;
  top: calc(100% + clamp(12px, 1.8vw, 20px)); left: 50%;
  transform: translateX(-50%);
  width: 110%; height: 30px;
  border-radius: 50%;
  background: radial-gradient(ellipse at center, rgba(0, 0, 0, 0.28) 0%, rgba(0, 0, 0, 0) 62%);
  opacity: 0;
  will-change: opacity;
}
.process__frame {
  position: relative;
  width: min(900px, 56vw);
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  overflow: hidden;
  background: #f4efe3; /* warm ivory paper */
  box-shadow: 0 30px 70px -30px rgba(0, 0, 0, 0.28);
  will-change: transform;
}
.process__lines {
  position: absolute; inset: 0; z-index: 3;
  width: 100%; height: 100%;
}
.pl-stroke {
  stroke: #4d4a44; stroke-width: 3; fill: none;
  stroke-linecap: round; stroke-linejoin: round;
}
.pl-note {
  font-family: "Caveat", cursive;
  font-size: 44px; fill: #4d4a44;
  opacity: 0;
}
.process__stage {
  position: absolute; inset: 0; z-index: 2;
  width: 100%; height: 100%;
  object-fit: cover;
  opacity: 0;
}
.process__shot {
  position: absolute; inset: 0; z-index: 3;
  width: 100%; height: 100%;
  opacity: 0;
  will-change: transform, opacity;
}
.process__brief {
  position: absolute; z-index: 3;
  top: 12%; left: 8%;
  max-width: 70%;
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: clamp(13px, 1.5vw, 22px);
  line-height: 1.7;
  color: #4d4a44;
  white-space: pre-line;
}
.process__cursor {
  display: inline-block;
  width: 0.55em; height: 1.05em;
  margin-left: 2px;
  background: #4d4a44;
  vertical-align: text-bottom;
  animation: briefblink 1.05s steps(1) infinite;
}
@keyframes briefblink { 0%, 60% { opacity: 1; } 61%, 100% { opacity: 0; } }
.process__filmcaption {
  position: absolute; z-index: 4;
  left: clamp(20px, 4vw, 64px); bottom: clamp(18px, 4vh, 48px);
  font-size: clamp(20px, 2.6vw, 40px);
  font-weight: 700; letter-spacing: -0.025em;
  color: #fff;
  text-shadow: 0 2px 22px rgba(0, 0, 0, 0.5);
  opacity: 0;
}
@media (max-width: 820px) {
  .process__pin { flex-direction: column; justify-content: center; gap: 0; }
  .process__rail {
    left: 50%; top: 10svh;
    transform: translateX(-50%);
    text-align: center;
    width: max-content;
  }
  .process__eyebrow { margin-bottom: 12px; }
  .process__steps { grid-auto-flow: column; gap: 13px; justify-content: center; }
  .process__step { flex-direction: column; align-items: center; gap: 3px; }
  .process__label { font-size: 13px; }
  .process__num { font-size: 10px; }
  .process__laptop { margin-top: 10svh; }
  .process__frame { width: 92vw; }
  .pl-note { font-size: 58px; }
  .process__brief { font-size: 12px; line-height: 1.6; }
}
@media (prefers-reduced-motion: reduce) {
  .process__filmcaption { opacity: 1 !important; }
  .process__lines, .process__brief, .process__shot,
  .process__chrome, .process__deck, .process__shadow { display: none; }
  #stage3 { opacity: 1; }
  .process__step { opacity: 1; }
}

/* ============ Contact signature ============ */
.contact__signature {
  margin: 44px auto 0;
  width: clamp(120px, 14vw, 190px);
}
.signature__svg { width: 100%; height: auto; display: block; }

/* ============ Clients ============ */
.clients {
  padding: clamp(100px, 16vh, 200px) 0;
  text-align: center;
}
.clients .section-head__eyebrow { margin-bottom: 48px; }
.marquee {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(to right, transparent, #000 12%, #000 88%, transparent);
  mask-image: linear-gradient(to right, transparent, #000 12%, #000 88%, transparent);
}
.marquee__track { display: flex; width: max-content; will-change: transform; }
.marquee__group {
  display: flex; align-items: center;
  gap: clamp(56px, 7vw, 110px);
  padding-right: clamp(56px, 7vw, 110px);
}
.marquee__group img {
  height: clamp(30px, 3.6vw, 48px);
  width: auto; max-width: 160px;
  object-fit: contain;
  filter: grayscale(1) opacity(0.55);
  transition: filter 0.4s ease;
  mix-blend-mode: multiply;
}
.marquee__group img:hover { filter: grayscale(0) opacity(1); }

/* ============ Social — pinned phone chapter ============ */
.social { position: relative; }
.social__pin {
  position: relative;
  height: 100svh; min-height: 640px;
  display: flex; align-items: center; justify-content: center;
  overflow: clip;
  perspective: 1400px;
}
.social__eyebrow {
  position: absolute; top: clamp(20px, 4vh, 44px); left: 50%;
  transform: translateX(-50%);
  font-size: 13px; font-weight: 600;
  letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--ink-soft);
}
.social__type {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  pointer-events: none;
}
.social__line {
  position: absolute;
  left: var(--gutter);
  font-size: clamp(44px, 8vw, 128px);
  font-weight: 700; letter-spacing: -0.035em;
  line-height: 0.98;
  white-space: nowrap;
  text-align: left;
  color: var(--ink);
  will-change: transform, opacity, filter;
}
.social__line--2 { opacity: 0; }
.social__stage { position: relative; z-index: 2; }
.social__phone {
  position: relative;
  width: min(320px, 68vw, 40svh);
  aspect-ratio: 393 / 830;
  padding: 11px;
  border-radius: clamp(40px, 7vw, 56px);
  background: linear-gradient(145deg, #3a3a3e 0%, #101012 30%, #060607 70%, #2c2c30 100%);
  box-shadow:
    inset 0 0 0 2px rgba(255, 255, 255, 0.06),
    0 40px 80px -24px rgba(0, 0, 0, 0.45),
    0 12px 28px rgba(0, 0, 0, 0.22);
  transform-style: preserve-3d;
  will-change: transform;
}
/* side buttons */
.social__phone::before,
.social__phone::after {
  content: "";
  position: absolute;
  background: #1a1a1d;
  border-radius: 2px;
}
.social__phone::before { left: -2px; top: 22%; width: 3px; height: 11%; } /* volume */
.social__phone::after { right: -2px; top: 26%; width: 3px; height: 8%; }  /* power */
.social__island {
  position: absolute; top: calc(11px + 12px); left: 50%; z-index: 3;
  transform: translateX(-50%);
  width: 27%; height: 26px;
  background: #000;
  border-radius: 999px;
}
.social__phone video {
  width: 100%; height: 100%;
  object-fit: cover;
  border-radius: clamp(30px, 5.6vw, 45px);
  background: #000;
}
.social__sub {
  position: absolute; bottom: clamp(24px, 6vh, 64px); left: 50%; z-index: 3;
  transform: translateX(-50%);
  width: min(560px, 84vw);
  text-align: center;
  font-size: clamp(14px, 1.5vw, 17px);
  color: var(--ink-soft); line-height: 1.55;
  opacity: 0;
}
@media (max-width: 820px) {
  /* narrow screens: headline reads above the phone instead of beside it */
  .social__type { align-items: flex-start; padding-top: 9svh; }
  .social__line { font-size: clamp(30px, 9vw, 56px); }
  .social__stage { margin-top: 16svh; }
  .social__phone { width: min(300px, 62vw, 28svh); }
  .social__sub { bottom: 3svh; font-size: 13px; }
}
@media (prefers-reduced-motion: reduce) {
  .social__line--1, .social__sub { opacity: 1 !important; }
  .social__line--2 { display: none; }
}

/* ============ Services ============ */
.services { padding: clamp(60px, 10vh, 120px) 0 clamp(80px, 12vh, 160px); }
.services__list {
  list-style: none;
  margin: 0 var(--gutter);
  border-top: 1px solid var(--hairline);
}
.service {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 24px;
  padding: clamp(36px, 5vw, 64px) 8px;
  border-bottom: 1px solid var(--hairline);
}
.service__num {
  font-size: 14px; font-weight: 600; color: var(--ink-soft);
  padding-top: 10px;
}
.service__body h3 {
  font-size: clamp(28px, 3.6vw, 52px);
  font-weight: 700; letter-spacing: -0.025em;
  margin-bottom: 14px;
}
.service__body p {
  font-size: clamp(15px, 1.4vw, 18px);
  color: var(--ink-soft); line-height: 1.6;
  max-width: 640px;
}

/* ============ About ============ */
.about {
  padding: clamp(100px, 18vh, 220px) var(--gutter);
  background: var(--ink);
  color: #f5f5f7;
}
.about__text {
  max-width: 1100px; margin: 0 auto;
  font-size: clamp(26px, 4vw, 56px);
  font-weight: 600; line-height: 1.16; letter-spacing: -0.025em;
}
.about__text .w { opacity: 0.18; }

/* ============ Contact ============ */
.contact {
  padding: clamp(120px, 20vh, 260px) var(--gutter);
  text-align: center;
}
.contact__title {
  font-size: clamp(48px, 9vw, 140px);
  font-weight: 700; line-height: 1; letter-spacing: -0.035em;
  margin: 24px 0 48px;
}
.contact__btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: clamp(18px, 2.4vw, 28px) clamp(32px, 4.5vw, 56px);
  border-radius: 999px;
  background: var(--ink); color: #fff;
  font-size: clamp(15px, 1.8vw, 22px); font-weight: 600;
  letter-spacing: -0.01em;
  transition: background-color 0.3s ease;
  will-change: transform;
}
.contact__btn:hover { background: var(--accent); }
.contact__phone { margin-top: 28px; font-size: 15px; color: var(--ink-soft); }
.contact__phone a:hover { color: var(--ink); }

/* ============ Footer ============ */
.footer { border-top: 1px solid var(--hairline); }
.footer__inner {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px;
  padding: 28px var(--gutter);
  font-size: 13px; color: var(--ink-soft);
}
.footer a:hover { color: var(--ink); }

/* ============ Reveal helpers ============ */
.reveal { opacity: 0; transform: translateY(36px); will-change: transform, opacity; }
.reveal-line { opacity: 0; transform: translateY(44px); will-change: transform, opacity; }

/* ============ Responsive ============ */
@media (max-width: 820px) {
  .nav__links { display: none; }
  .work__grid { grid-template-columns: 1fr; }
  .work-card--half .work-card__media { aspect-ratio: 16 / 10; }
  .work-card__meta { flex-direction: column; gap: 6px; }
  .service { grid-template-columns: 48px 1fr; gap: 14px; }
  .hero__scrollcue { display: none; }
}

/* ============ Reduced motion ============ */
@media (prefers-reduced-motion: reduce) {
  .line__inner, .hero__sub, .reveal, .reveal-line { opacity: 1 !important; transform: none !important; }
  .manifesto__text .w, .about__text .w { opacity: 1 !important; }
  .hero__scrollline::after { animation: none; }
  .preloader { display: none; }
}
