/* g2k.studio. Paper, ink and chrome. One fixed canvas sits behind the page;
   the see-through sections ([data-scene]) show it, the sheets cover it. */

:root {
  --paper: #EDEEF0;
  --white: #F7F8F9;
  --ink: #0E0E0E;
  --muted: #5D6166;
  --faint: rgba(14, 14, 14, 0.16);
  --rule: rgba(14, 14, 14, 0.14);
  --butter: #F3E47A;
  --sans: "Archivo", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --gutter: clamp(16px, 3.2vw, 48px);
  --head: 76px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: var(--head); }
body {
  background: var(--paper);
  color: var(--ink);
  font: 400 16px / 1.45 var(--sans);
  font-stretch: 100%;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; height: auto; }
ol, ul { list-style: none; }
html.over-mark { cursor: pointer; }

.sr-only {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}
.label {
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  line-height: 1.3;
}
.label a { border-bottom: 1px solid var(--rule); transition: border-color 0.2s; }
.label a:hover { border-color: currentColor; }
.muted { color: var(--muted); }
.num { font-variant-numeric: tabular-nums; margin-right: 0.9em; color: var(--muted); }

/* ---- canvas and stages ---- */
.webgl {
  position: fixed; inset: 0; width: 100%; height: 100%;
  z-index: 0; pointer-events: none;
}
[data-mode="still"] .webgl { display: none; }
main, .foot { position: relative; z-index: 1; }
.stage { pointer-events: none; }
.still { display: none; width: 100%; height: 100%; object-fit: contain; }
[data-mode="still"] .still[src] { display: block; }

/* ---- header: one line of type that reads on paper and on ink ---- */
.top {
  position: fixed; top: 0; left: 0; right: 0; z-index: 10;
  display: flex; justify-content: space-between; align-items: center;
  height: var(--head); padding: 0 var(--gutter);
  color: #fff; mix-blend-mode: difference;
}
.brand, .nav {
  font-size: 13px; font-weight: 500; text-transform: uppercase; letter-spacing: 0.12em;
}
.nav { display: flex; gap: clamp(18px, 3vw, 40px); }
.nav a, .brand { padding: 8px 0; border-bottom: 1px solid transparent; transition: border-color 0.2s; }
.nav a:hover { border-color: currentColor; }

/* ---- hero ---- */
.hero {
  position: relative;
  height: 100vh; height: 100svh;
  min-height: 560px;
  padding: 0 var(--gutter);
}
.hero-stage { position: absolute; left: var(--gutter); right: var(--gutter); top: 13%; bottom: 25%; }
.corner { position: absolute; top: calc(var(--head) + 4px); color: var(--muted); }
.corner-tl { left: var(--gutter); }
.corner-tr { right: var(--gutter); }
.hero-foot {
  position: absolute; left: var(--gutter); right: var(--gutter); bottom: clamp(20px, 4vh, 40px);
  display: flex; justify-content: space-between; align-items: flex-end; gap: 24px;
}
.hero-title {
  font-size: clamp(34px, 5.4vw, 84px);
  font-weight: 500; font-stretch: 112%;
  line-height: 0.95; letter-spacing: -0.035em;
  max-width: 9.5em;
}
.hero-side { display: grid; gap: 14px; justify-items: end; text-align: right; }
.tape {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--butter); color: var(--ink);
  padding: 7px 10px 6px;
}
.dot {
  width: 7px; height: 7px; border-radius: 50%; background: var(--ink);
  animation: blink 1.6s steps(2, jump-none) infinite;
}
@keyframes blink { 50% { opacity: 0; } }

/* Text arrives once, in a short stagger. */
.rise { animation: rise 0.9s cubic-bezier(0.2, 0.7, 0.1, 1) both; }
.hero-title.rise { animation-delay: 0.5s; }
.hero-side.rise { animation-delay: 0.65s; }
.corner.rise { animation-delay: 0.8s; }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } }

/* ---- sections ---- */
.section-head {
  display: flex; justify-content: space-between; align-items: baseline;
  padding: 0 var(--gutter);
}
.sheet { background: var(--white); }

/* ---- 01 what we do: the list scrolls, the mark stays and changes room ---- */
.disciplines { padding-top: clamp(60px, 10vh, 120px); }
.disciplines-grid {
  display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  padding: 0 var(--gutter);
}
.disciplines-stage {
  grid-column: 2; grid-row: 1;
  position: sticky; top: 18vh; height: 64vh;
}
.disciplines-list { grid-column: 1; grid-row: 1; padding: 6vh 0 18vh; }
.discipline { min-height: 66vh; display: flex; align-items: center; }
.discipline-text {
  color: var(--faint);
  transition: color 0.25s;
}
.discipline-text.is-lit { color: var(--ink); }
.discipline-text .num { display: block; margin-bottom: 18px; color: inherit; }
.discipline-name {
  font-size: clamp(64px, 11vw, 172px);
  font-weight: 500; font-stretch: 118%;
  line-height: 0.86; letter-spacing: -0.045em;
  margin-left: -0.04em;
}
.discipline-text p { font-size: clamp(17px, 1.5vw, 21px); max-width: 24ch; margin-top: 22px; line-height: 1.35; }

/* ---- 02 selected work ---- */
.work { padding: clamp(80px, 14vh, 160px) 0 clamp(60px, 10vh, 120px); }
.case {
  display: grid; grid-template-columns: minmax(0, 8fr) minmax(0, 4fr); gap: clamp(24px, 4vw, 64px);
  align-items: end;
  padding: clamp(32px, 6vh, 64px) var(--gutter) 0;
}
.case-media { position: relative; padding: 4% 9% 12% 0; }
.shot { background: var(--paper); box-shadow: 0 1px 0 var(--rule), 0 30px 60px -30px rgba(14, 14, 14, 0.35); }
.shot-desktop { border-radius: 6px; overflow: hidden; border: 1px solid var(--rule); }
.shot-desktop::before {
  content: ""; display: block; height: 22px; border-bottom: 1px solid var(--rule);
  background:
    radial-gradient(circle at 12px 11px, var(--faint) 3.5px, transparent 4px),
    radial-gradient(circle at 26px 11px, var(--faint) 3.5px, transparent 4px),
    radial-gradient(circle at 40px 11px, var(--faint) 3.5px, transparent 4px),
    var(--white);
}
.shot-phone {
  position: absolute; right: 0; bottom: 0; width: 23%;
  border-radius: 18px; overflow: hidden; border: 5px solid var(--ink);
}
.case-mark {
  position: absolute; right: 12%; top: -7%; width: 30%;
  transform: rotate(-6deg);
  filter: drop-shadow(0 18px 18px rgba(14, 14, 14, 0.22));
}
.case-title {
  font-size: clamp(56px, 8vw, 128px);
  font-weight: 500; font-stretch: 118%;
  line-height: 0.86; letter-spacing: -0.045em;
}
.case-dek { font-size: clamp(18px, 1.6vw, 22px); line-height: 1.35; margin: 22px 0 22px; max-width: 22ch; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 22px; }
.tags li { border: 1px solid var(--ink); border-radius: 99px; padding: 6px 12px 5px; }
.more { padding: clamp(48px, 8vh, 96px) var(--gutter) 0; }

/* ---- 03 how we work ---- */
.process { padding: clamp(60px, 10vh, 120px) 0 clamp(80px, 14vh, 160px); border-top: 1px solid var(--rule); }
.steps {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(20px, 3vw, 48px);
  padding: clamp(32px, 6vh, 64px) var(--gutter) 0;
}
.steps li { border-top: 1px solid var(--ink); padding-top: 18px; }
.step-num { font-size: 12px; font-weight: 500; color: var(--muted); font-variant-numeric: tabular-nums; }
.steps h3 {
  font-size: clamp(40px, 4.6vw, 72px); font-weight: 500; font-stretch: 112%;
  letter-spacing: -0.04em; line-height: 0.95; margin: 28px 0 16px;
}
.steps p { font-size: 17px; max-width: 26ch; line-height: 1.4; }

/* ---- contact: the mark comes back, in the studio's own light ---- */
.contact {
  min-height: 100vh; min-height: 100svh;
  display: flex; flex-direction: column; align-items: center; justify-content: flex-end;
  gap: 22px; text-align: center;
  padding: var(--head) var(--gutter) clamp(64px, 12vh, 120px);
}
.contact-stage { width: min(100%, 900px); flex: 1 1 auto; min-height: 240px; max-height: 46vh; }
.contact-title {
  font-size: clamp(34px, 5vw, 76px); font-weight: 500; font-stretch: 112%;
  letter-spacing: -0.035em; line-height: 0.98; max-width: 12em;
}
.contact-mail {
  font-size: clamp(22px, 2.6vw, 36px); font-weight: 500; letter-spacing: -0.01em;
  border-bottom: 2px solid var(--ink); padding-bottom: 2px;
}
.contact-mail:hover { background: var(--butter); }

/* ---- footer ---- */
.foot { background: var(--ink); color: var(--paper); overflow: hidden; }
.foot .label a { border-color: rgba(237, 238, 240, 0.3); }
.foot-row {
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 14px 28px;
  padding: 36px var(--gutter) 0;
}
.foot .tape { color: var(--ink); }
.masthead {
  font-size: 16.4vw; font-weight: 500; font-stretch: 118%;
  letter-spacing: -0.06em; line-height: 0.78; white-space: nowrap;
  margin: 8vh 0 0 -0.04em; transform: translateY(0.12em);
}

/* ---- phones ---- */
@media (max-width: 760px) {
  :root { --head: 60px; }
  .brand, .nav { font-size: 12px; }
  .nav { gap: 16px; }
  .hero-stage { top: 13%; bottom: 33%; left: 8px; right: 8px; }
  .hero-foot { flex-direction: column; align-items: flex-start; gap: 18px; }
  .hero-side { justify-items: start; text-align: left; }
  .hero-title { font-size: clamp(36px, 11vw, 52px); }

  .disciplines-grid { grid-template-columns: minmax(0, 1fr); }
  .disciplines-stage {
    grid-column: 1; top: calc(var(--head) + 4px); height: 34svh; z-index: -1;
  }
  .disciplines-list { grid-row: 2; padding: 0 0 20svh; margin-top: -2svh; }
  .discipline { min-height: 44svh; align-items: flex-start; }
  .discipline-name { font-size: clamp(54px, 17vw, 84px); }
  .discipline-text p { margin-top: 14px; }

  .case { grid-template-columns: minmax(0, 1fr); }
  .case-media { padding: 10% 7% 14% 0; }
  .shot-phone { width: 28%; border-width: 3px; border-radius: 12px; }
  .shot-desktop::before { height: 14px; background-size: 70% 100%; background-repeat: no-repeat; }
  .discipline-text { transition: color 0.25s, opacity 0.25s; }
  .discipline-text.is-past { opacity: 0; }
  .steps { grid-template-columns: minmax(0, 1fr); gap: 36px; }
  .steps h3 { margin: 16px 0 10px; }
  .contact-stage { max-height: 34svh; }
  .foot-row { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .rise, .dot { animation: none; }
  .discipline-text { transition: none; }
}
