/* ===========================================================
   designwithanish — variant 02  (editorial / minimal — "Twoo" direction)
   =========================================================== */

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

:root {
  --black: #0a0a0a;
  --white: #f4f3f0;
  --pure-white: #ffffff;
  --paper: #eceae5;          /* light gray for the work page */
  --muted: #8b8b87;
  --muted-dark: #6c6c68;
  --line: rgba(244, 243, 240, 0.16);
  --line-dark: rgba(10, 10, 10, 0.14);

  --pad: clamp(20px, 4vw, 56px);
  --maxw: 1680px;

  --f-body: 'Manrope', system-ui, sans-serif;
  --f-display: 'Manrope', system-ui, sans-serif;

  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
body {
  font-family: var(--f-body);
  background: var(--black);
  color: var(--white);
  font-size: 16px;
  line-height: 1.5;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
img, video { display: block; max-width: 100%; height: auto; }
::selection { background: var(--white); color: var(--black); }

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

/* ---------- type scale ---------- */
.display {
  font-family: var(--f-display);
  font-weight: 700;
  line-height: 0.96;
  letter-spacing: -0.03em;
  font-size: clamp(2.8rem, 9vw, 9rem);
}
.h2 {
  font-family: var(--f-display);
  font-weight: 600;
  line-height: 1.0;
  letter-spacing: -0.02em;
  font-size: clamp(2rem, 5.5vw, 5rem);
}
.eyebrow {
  font-family: var(--f-body);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  color: var(--muted);
  font-weight: 500;
}
.lead {
  font-size: clamp(1rem, 1.4vw, 1.15rem);
  line-height: 1.32;
  max-width: 46ch;
}

/* ---------- layout helpers ---------- */
.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding-inline: var(--pad); }
section { position: relative; }

/* ---------- top nav ---------- */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: clamp(18px, 2.2vw, 30px) var(--pad);
  mix-blend-mode: difference;            /* logo flips with bg */
  color: #fff;
}
.logo {
  font-family: var(--f-display);
  font-weight: 600;
  font-size: 1.18rem;
  letter-spacing: -0.01em;
}
.logo sup { font-size: 0.5em; top: -0.7em; }
.logo-img { height: 30px; width: auto; display: block; }
/* centered nav symbol */
.nav-symbol {
  position: absolute; left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  display: block; line-height: 0;
}
.nav-symbol img { height: 34px; width: 34px; display: block; transition: transform 0.3s var(--ease); }
.nav-symbol:hover img { transform: scale(1.08); }
@media (max-width: 640px) { .nav-symbol img { height: 28px; width: 28px; } }
.nav-links { display: flex; gap: clamp(14px, 2vw, 30px); font-size: 0.92rem; }
.nav-links a { position: relative; }
.nav-links a::after {
  content: ''; position: absolute; left: 0; bottom: -3px; width: 100%; height: 1px;
  background: currentColor; transform: scaleX(0); transform-origin: right;
  transition: transform 0.4s var(--ease);
}
.nav-links a:hover::after { transform: scaleX(1); transform-origin: left; }

/* ---------- HERO ---------- */
.hero { min-height: 100svh; display: flex; flex-direction: column; justify-content: space-between; padding-top: clamp(96px, 14vh, 160px); padding-bottom: clamp(28px, 5vh, 56px); overflow: hidden; }

.hero-top {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1fr);
  align-items: stretch;
  min-height: clamp(210px, 30vh, 330px);
  margin-top: clamp(8px, 2.5vh, 24px);
}
/* cell padding so text clears the rules; first cell flush-left under the logo */
.hero-top .col { position: relative; padding: clamp(22px, 2.4vw, 30px) clamp(20px, 2vw, 30px) 0; }
.hero-top .col:first-child { padding-left: 0; }
/* vertical dividers between cells (draw down on load) */
.hero-top .col:not(:first-child)::before {
  content: ''; position: absolute; left: 0; top: 0; width: 1px; height: 100%;
  background: var(--line); transform: scaleY(0); transform-origin: top;
  animation: ruleDrawY 0.85s var(--ease) 1s forwards;
}
/* right edge line — closes the frame */
.hero-top .col:last-child::after {
  content: ''; position: absolute; right: 0; top: 0; width: 1px; height: 100%;
  background: var(--line); transform: scaleY(0); transform-origin: top;
  animation: ruleDrawY 0.85s var(--ease) 1.1s forwards;
}
/* top & bottom horizontal rules (draw across on load) */
.hero-top .gl {
  position: absolute; left: 0; width: 100%; height: 1px; background: var(--line);
  transform: scaleX(0); transform-origin: left;
}
.hero-top .gl-top { top: 0; animation: ruleDrawX 1.1s var(--ease) 0.7s forwards; }
.hero-top .gl-bottom { bottom: 0; animation: ruleDrawX 1.1s var(--ease) 0.85s forwards; }
@keyframes ruleDrawX { to { transform: scaleX(1); } }
@keyframes ruleDrawY { to { transform: scaleY(1); } }
@media (prefers-reduced-motion: reduce) {
  .hero-top .gl,
  .hero-top .col:not(:first-child)::before,
  .hero-top .col:last-child::after { animation: none; transform: none; }
}

.hero-top .col p { font-size: 0.95rem; color: var(--muted); max-width: 34ch; line-height: 1.32; }
.hero-top .col a { color: var(--white); display: block; width: fit-content; }
.hero-top .col a:hover { color: var(--muted); }
.hero-top .col .label { color: var(--muted); font-size: 0.8rem; margin-bottom: 4px; }

.hero-headline { position: relative; z-index: 2; max-width: none; }
.hero .giant {
  position: absolute;
  right: -2vw;
  bottom: -6vh;
  font-family: var(--f-display);
  font-weight: 700;
  font-size: clamp(20rem, 52vw, 60rem);
  line-height: 0.72;
  letter-spacing: -0.04em;
  color: var(--white);
  z-index: 1;
  pointer-events: none;
  user-select: none;
}

/* ---------- generic dark section ---------- */
.block { padding-block: clamp(80px, 14vh, 200px); }
.block-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: clamp(32px, 6vw, 120px);
  align-items: start;
}
.offer-list { margin-top: 28px; display: flex; flex-direction: column; }
.offer-list li {
  list-style: none;
  display: flex; justify-content: space-between; gap: 16px;
  padding: 22px 0;
  border-top: 1px solid var(--line);
  font-family: var(--f-display); font-weight: 500;
  font-size: clamp(1.2rem, 2.4vw, 2rem);
  letter-spacing: -0.01em;
}
.offer-list li:last-child { border-bottom: 1px solid var(--line); }
.offer-list li span { font-family: var(--f-body); font-weight: 400; font-size: 0.85rem; color: var(--muted); align-self: center; }

.statement { padding-block: clamp(80px, 16vh, 220px); }
.statement .h2 { max-width: 18ch; }

/* ---------- WORK / PROJECT LIST ---------- */
.work-list { margin-top: clamp(32px, 6vh, 72px); position: relative; }
/* left gutter (desktop) where the hover preview lives */
@media (min-width: 861px) {
  .work-list { padding-left: var(--gutter, clamp(220px, 24vw, 360px)); }
}
.work-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 340px);
  gap: 24px;
  align-items: start;
  padding: clamp(22px, 3vw, 40px) 0;
  border-top: 1px solid var(--line);
  position: relative;
  transition: opacity 0.4s var(--ease);
}
.work-list:hover .work-row { opacity: 0.45; }
.work-list .work-row:hover { opacity: 1; }
.work-row:last-child { border-bottom: 1px solid var(--line); }
.work-row .title {
  font-family: var(--f-display); font-weight: 600;
  font-size: clamp(1.8rem, 4.4vw, 3.6rem);
  letter-spacing: -0.02em; line-height: 1;
}
.work-row .year { color: var(--muted); font-size: 0.92rem; padding-top: 0.5em; }
.work-row .tags { color: var(--muted); font-size: 0.92rem; padding-top: 0.5em; }
.work-row .tags span { display: block; }
.work-row .arrow { position: absolute; right: 0; top: 50%; transform: translateY(-50%); opacity: 0; transition: 0.4s var(--ease); }
.work-row:hover .arrow { opacity: 1; }

/* anchored-left hover preview — glides vertically to the hovered row */
.work-preview {
  position: absolute;
  left: 0;
  top: 0;                                  /* JS sets --y (row centre) */
  width: clamp(200px, 22vw, 330px);
  transform: translateY(calc(var(--y, 0px) - 50%)) scale(0.94);
  transform-origin: left center;
  opacity: 0;
  pointer-events: none;
  z-index: 5;
  overflow: hidden;
  border-radius: 3px;
  box-shadow: 0 26px 70px rgba(0,0,0,0.5);
  transition: transform 0.6s var(--ease), opacity 0.45s var(--ease);
  will-change: transform, opacity;
}
.work-preview.show {
  opacity: 1;
  transform: translateY(calc(var(--y, 0px) - 50%)) scale(1);
}
.work-preview img { display: block; width: 100%; height: auto; }
/* unique reveal: clip-path wipe + lift each time the image changes */
.work-preview.swap img { animation: previewReveal 0.62s var(--ease); }
@keyframes previewReveal {
  0%   { clip-path: inset(0 0 100% 0); transform: translateY(14px) scale(1.05); }
  100% { clip-path: inset(0 0 0 0);    transform: translateY(0) scale(1); }
}
@media (max-width: 860px) { .work-preview { display: none; } }

/* ---------- PROJECT DETAIL ---------- */
.proj-hero { padding-top: clamp(120px, 18vh, 200px); padding-bottom: clamp(40px, 8vh, 90px); }
.proj-hero .display { max-width: 14ch; }
.proj-meta {
  margin-top: clamp(36px, 6vh, 72px);
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: clamp(28px, 5vw, 90px);
  align-items: start;
  border-top: 1px solid var(--line);
  padding-top: 32px;
}
.proj-meta .lead { color: var(--white); }
.meta-table { display: grid; grid-template-columns: auto 1fr; gap: 10px 28px; font-size: 0.92rem; }
.meta-table dt { color: var(--muted); }
.meta-table dd { text-align: right; }
.live-link { display: inline-block; margin-top: 24px; border-bottom: 1px solid currentColor; padding-bottom: 2px; }

.gallery { display: grid; gap: clamp(10px, 1.4vw, 18px); padding-bottom: clamp(60px, 10vh, 140px); }
.gallery.cols-1 { grid-template-columns: 1fr; }
.gallery.cols-2 { grid-template-columns: repeat(2, 1fr); }
.gallery.cols-3 { grid-template-columns: repeat(3, 1fr); }
.gallery figure { overflow: hidden; background: #161616; }
.gallery img, .gallery video { width: 100%; height: 100%; object-fit: cover; }
.gallery .span-2 { grid-column: span 2; }
.full-bleed { width: 100%; }

/* ---------- collage galleries (matches original site placement) ---------- */
/* case studies: full-width flush vertical stack */
.stack { display: flex; flex-direction: column; gap: 0; padding-bottom: clamp(60px, 10vh, 140px); }
.stack img, .stack video { width: 100%; display: block; position: relative; transition: transform 0.6s var(--ease), filter 0.5s var(--ease); }
.stack img:hover, .stack video:hover { transform: scale(1.012); filter: brightness(1.06); z-index: 2; }

/* image galleries: masonry collage with natural proportions */
.collage { columns: 3; column-gap: 16px; padding-bottom: clamp(60px, 10vh, 140px); }
.collage img {
  width: 100%; margin-bottom: 16px; display: block; break-inside: avoid;
  border-radius: 3px; background: #161616;
  transition: transform 0.5s var(--ease), box-shadow 0.5s var(--ease);
}
.collage img:hover { transform: scale(1.03); box-shadow: 0 24px 60px rgba(0,0,0,0.55); position: relative; z-index: 2; }

/* motion: masonry collage of looping videos */
.video-collage { columns: 2; column-gap: 16px; padding-bottom: clamp(60px, 10vh, 140px); }
.video-collage video {
  width: 100%; margin-bottom: 16px; display: block; break-inside: avoid;
  border-radius: 3px; background: #000;
  transition: transform 0.5s var(--ease), box-shadow 0.5s var(--ease);
}
.video-collage video:hover { transform: scale(1.02); box-shadow: 0 24px 60px rgba(0,0,0,0.55); position: relative; z-index: 2; }

@media (max-width: 900px) { .collage { columns: 2; } }
@media (max-width: 560px) { .collage, .video-collage { columns: 1; } }

/* ---------- horizontal motion-tile marquee (illustrations) ---------- */
.marquee-wall {
  display: flex; flex-direction: column; gap: clamp(10px, 1.2vw, 16px);
  padding-bottom: clamp(60px, 10vh, 140px);
  -webkit-mask-image: linear-gradient(to right, transparent, #000 4%, #000 96%, transparent);
          mask-image: linear-gradient(to right, transparent, #000 4%, #000 96%, transparent);
}
.marquee-row { overflow: hidden; }
.marquee-track {
  display: flex; gap: clamp(10px, 1.2vw, 16px); width: max-content;
  animation: mqLeft 70s linear infinite; will-change: transform;
}
.marquee-track.reverse { animation-name: mqRight; animation-duration: 84s; }
.marquee-wall:hover .marquee-track { animation-play-state: paused; }
.marquee-track img {
  height: clamp(150px, 21vh, 250px); width: auto; flex: 0 0 auto; display: block;
  border-radius: 3px; background: #161616;
  transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease), filter 0.4s var(--ease);
}
.marquee-track img:hover { transform: scale(1.05); box-shadow: 0 22px 55px rgba(0,0,0,0.55); position: relative; z-index: 2; }
@keyframes mqLeft  { from { transform: translateX(0); }      to { transform: translateX(-50%); } }
@keyframes mqRight { from { transform: translateX(-50%); }   to { transform: translateX(0); } }
@media (prefers-reduced-motion: reduce) {
  .marquee-track { animation: none; }
  .marquee-wall { -webkit-mask-image: none; mask-image: none; }
  .marquee-row { overflow-x: auto; }
}

/* ---------- résumé section ---------- */
.resume { border-top: 1px solid var(--line); }
.resume-row {
  display: flex; align-items: center; justify-content: space-between;
  gap: 28px; flex-wrap: wrap; padding-block: clamp(56px, 10vh, 130px);
}
.resume-row h2 { margin-top: 8px; }
.resume-row .lead { color: var(--muted); margin-top: 10px; }
.resume-btn {
  font-family: var(--f-display); font-weight: 600; letter-spacing: -0.01em;
  font-size: clamp(1rem, 1.3vw, 1.2rem); white-space: nowrap;
  border: 1px solid var(--white); border-radius: 999px; padding: 16px 30px;
  display: inline-flex; align-items: center; gap: 10px; transition: 0.3s var(--ease);
}
.resume-btn:hover { background: var(--white); color: var(--black); }

/* prev / next project */
.proj-next {
  border-top: 1px solid var(--line);
  padding-block: clamp(48px, 8vh, 90px);
  display: flex; align-items: baseline; justify-content: space-between; gap: 20px;
}
.proj-next a { font-family: var(--f-display); font-weight: 600; font-size: clamp(1.6rem, 4vw, 3rem); letter-spacing: -0.02em; }
.proj-next a:hover { color: var(--muted); }

/* ---------- CONTACT / FOOTER (light) ---------- */
.contact {
  background: var(--paper);
  color: var(--black);
  padding-top: clamp(80px, 14vh, 180px);
  padding-bottom: clamp(28px, 5vh, 48px);
  min-height: 100svh;
  display: flex; flex-direction: column; justify-content: space-between;
  position: relative; overflow: hidden;
}
.contact .eyebrow, .contact .muted { color: var(--muted-dark); }
.contact a:hover { color: var(--muted-dark); }
.contact .giant { color: var(--black); }
.contact-grid {
  position: relative; z-index: 2;
  display: grid; grid-template-columns: minmax(0,1.2fr) minmax(0,1fr); gap: clamp(28px, 5vw, 90px);
}
.contact-grid .lead { color: var(--black); }
.contact-links { display: flex; flex-direction: column; gap: 6px; margin-top: 8px; font-size: 1.05rem; }
.contact-foot {
  position: relative; z-index: 2;
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px;
  font-size: 0.85rem; color: var(--muted-dark);
  border-top: 1px solid var(--line-dark); padding-top: 20px; margin-top: 60px;
}
.email-big {
  font-family: var(--f-display); font-weight: 700; letter-spacing: -0.02em;
  font-size: clamp(1.3rem, 3.4vw, 2.4rem); line-height: 1.05; margin-top: 12px;
  display: inline-block; border-bottom: 2px solid var(--black); padding-bottom: 6px;
}
.email-big:hover { color: var(--muted-dark); border-color: var(--muted-dark); }

/* contact form (light) */
.contact .contact-grid { margin-top: clamp(36px, 5vw, 64px); align-items: start; }
.form-field {
  border-top: 1px solid var(--line-dark); padding: 16px 0;
  display: grid; grid-template-columns: 110px 1fr; gap: 16px; align-items: baseline;
}
.form-field:first-of-type { border-top: none; }
.form-field label { font-size: 0.8rem; color: var(--muted-dark); }
.form-field input, .form-field textarea {
  background: transparent; border: none; color: var(--black);
  font-family: var(--f-body); font-size: 1.05rem; width: 100%; resize: vertical;
}
.form-field input:focus, .form-field textarea:focus { outline: none; }
.form-field input::placeholder, .form-field textarea::placeholder { color: #b3b1a9; }
.form-submit {
  margin-top: 24px; background: var(--black); color: var(--paper); border: none;
  font-family: var(--f-body); font-weight: 600; font-size: 1rem;
  padding: 14px 32px; border-radius: 999px; cursor: pointer; transition: 0.25s var(--ease);
}
.form-submit:hover { background: var(--muted-dark); }
.form-status { margin-top: 14px; font-size: 0.95rem; min-height: 1.2em; color: var(--muted-dark); }

/* ---------- reveal animation ---------- */
.reveal { opacity: 0; transform: translateY(28px); }
.is-in { opacity: 1; transform: none; transition: opacity 1s var(--ease), transform 1s var(--ease); }
.reveal-line { overflow: hidden; }
.reveal-line > * { display: inline-block; transform: translateY(110%); transition: transform 0.9s var(--ease); }
.reveal-line.is-in > * { transform: none; }

/* ---------- page transition overlay ---------- */
.curtain {
  position: fixed; inset: 0; z-index: 100; background: var(--black);
  transform: translateY(100%); pointer-events: none;
}

/* ---------- responsive ---------- */
@media (max-width: 1040px) {
  .hero-top { grid-template-columns: 1fr 1fr; min-height: auto; gap: 4px 0; }
  .hero-top .col { padding: 18px 0 0; }
  .hero-top .col:not(:first-child)::before,
  .hero-top .col:last-child::after { display: none; }
  .hero-top .gl-bottom { display: none; }
  .block-grid, .proj-meta, .contact-grid { grid-template-columns: 1fr; }
  .work-row { grid-template-columns: 1fr auto; }
  .work-row .year { display: none; }
  .gallery.cols-3 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .hero-top { grid-template-columns: 1fr; gap: 18px; }
  .nav-links { gap: 14px; }
  .hero .giant { font-size: 56vw; bottom: -3vh; right: -4vw; }
  .gallery.cols-2, .gallery.cols-3 { grid-template-columns: 1fr; }
  .gallery .span-2 { grid-column: span 1; }
  .work-row .tags { display: none; }
  .proj-next { flex-direction: column; }
  .form-field { grid-template-columns: 1fr; gap: 6px; }
}
