/* ============================================================
   CHKSTEPAN — split-world portfolio study (from a written prompt)
   Upper world: pure white pitch. Lower world: absolute black,
   the name as terrain. Artefacts pinned across the divide.
   Type: Anton (terrain) · Archivo (everything human-sized)
   ============================================================ */

:root {
  --white: #ffffff;
  --black: #000000;
  --ink: #111111;
  --green: #00b140;           /* the single green CTA */
  --paper: #f6f3ea;           /* aged print stock */
  --paper-shadow: rgba(0, 0, 0, 0.35);
  --font-terrain: "Anton", sans-serif;
  --font-body: "Archivo", "Helvetica Neue", Arial, sans-serif;
}

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

body {
  font-family: var(--font-body);
  background: var(--black);
  overflow-x: hidden;
}

/* ---------- the split ---------- */

.split {
  --divide: 50%; /* one variable drives the divide; GSAP scrubs it on scroll */
  position: relative;
  height: 100svh;
  display: grid;
  grid-template-rows: var(--divide) 1fr;
}

.world--white {
  background: var(--white);
  color: var(--ink);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1.5rem 4.5rem; /* extra bottom room: artefacts live near the divide */
}

.world--black {
  background: var(--black);
  overflow: hidden;
  display: flex;
  align-items: flex-end;
}

/* ---------- the pitch (upper world) ---------- */

.pitch {
  max-width: 34rem;
  text-align: center;
}

.pitch__kicker {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #888;
  margin-bottom: 1rem;
}

.pitch__copy {
  font-size: clamp(1rem, 2vw, 1.2rem);
  line-height: 1.55;
  margin-bottom: 1.6rem;
}

.cta {
  display: inline-block;
  background: var(--green);
  color: var(--white);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0.9rem 1.9rem;
  transition: background-color 0.25s ease;
}

.cta:hover, .cta:focus-visible { background: #009436; }
.cta:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }

/* ---------- the name as terrain (lower world) ---------- */

.name-track {
  white-space: nowrap;
  line-height: 0.78;
}

.name {
  display: inline-block;
  font-family: var(--font-terrain);
  /* wide enough to bleed past both edges at any viewport */
  font-size: clamp(9rem, 30vw, 42rem);
  letter-spacing: -0.015em;
  color: var(--white);
  margin-left: -0.08em;
  transform: translateX(0);
  animation: drift 90s linear infinite alternate;
  will-change: transform;
}

@keyframes drift {
  from { transform: translateX(0); }
  to   { transform: translateX(-6%); }
}

@media (prefers-reduced-motion: reduce) {
  .name { animation: none; }
}

/* ---------- About: straddling the divide ---------- */

.about-link {
  position: absolute;
  left: 50%;
  top: var(--divide, 50%);
  transform: translate(-50%, -50%);
  z-index: 3;
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0.4rem 0.9rem;
  /* white text + difference blend = black on the white half,
     white on the black half — it belongs to neither world */
  color: var(--white);
  mix-blend-mode: difference;
}

.about-link:hover, .about-link:focus-visible {
  text-decoration: underline;
  text-underline-offset: 6px;
}

/* ---------- artefacts across the divide ---------- */

.artefacts {
  position: absolute;
  left: 0; right: 0;
  top: var(--divide, 50%);
  height: 0;
  z-index: 2;
}

.artefact {
  position: absolute;
  box-shadow: 0 14px 34px var(--paper-shadow);
}

/* grain so print pieces read as paper, not panels */
.artefact--clipping::after,
.artefact--book::after,
.artefact--photo::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.06 0'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* tape + pins — corkboard evidence */
.tape {
  position: absolute;
  width: 74px;
  height: 24px;
  background: rgba(255, 248, 220, 0.65);
  border-left: 1px dashed rgba(0,0,0,0.12);
  border-right: 1px dashed rgba(0,0,0,0.12);
  z-index: 2;
}
.tape--tl { top: -12px; left: -22px; transform: rotate(-38deg); }
.tape--tr { top: -10px; right: -24px; transform: rotate(32deg); }

.pin {
  position: absolute;
  top: -8px;
  left: 50%;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #ff6b5e, #c22218 70%);
  box-shadow: 0 3px 5px rgba(0,0,0,0.45);
  z-index: 2;
}

/* 1 — magazine clipping */
.artefact--clipping {
  width: 250px;
  left: 6%;
  top: -78px;
  transform: rotate(-7deg);
  background: var(--paper);
  padding: 1rem 1.1rem 1.2rem;
  clip-path: polygon(0 3%, 7% 0, 100% 1%, 99% 96%, 90% 100%, 42% 97%, 2% 99%);
}

.clipping__over {
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: #b3402e;
  margin-bottom: 0.45rem;
}

.clipping__head {
  font-family: var(--font-terrain);
  font-size: 1.3rem;
  line-height: 1.02;
  text-transform: uppercase;
  color: #161616;
  margin-bottom: 0.5rem;
}

.clipping__body {
  font-size: 0.68rem;
  line-height: 1.45;
  color: #3d3a33;
}

/* 2 — book cover */
.artefact--book {
  width: 150px;
  height: 208px;
  left: 21%;
  top: -60px;
  transform: rotate(4deg);
  background: #e8352a;
  color: var(--paper);
  padding: 1.1rem 0.9rem;
}

.book__spine {
  position: absolute;
  left: 10px; top: 0; bottom: 0;
  width: 2px;
  background: rgba(0,0,0,0.28);
}

.book__title {
  font-family: var(--font-terrain);
  font-size: 1.7rem;
  line-height: 0.95;
  letter-spacing: 0.01em;
  margin: 0.4rem 0 0 0.6rem;
}

.book__author {
  position: absolute;
  bottom: 0.9rem;
  left: 1.5rem;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.2em;
}

/* 3 — racing car card */
.artefact--card {
  width: 210px;
  right: 16%;
  top: -46px;
  transform: rotate(-3deg);
  background: #101010;
  border: 3px solid var(--paper); /* trading-card frame — keeps it visible on the black half */
  padding: 0.55rem 0.55rem 0.5rem;
}

.artefact--card svg { display: block; width: 100%; height: auto; }

.card__caption {
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  color: #cfcfc6;
  padding-top: 0.45rem;
  text-align: center;
}

/* 4 — photo print */
.artefact--photo {
  width: 168px;
  right: 7%;
  top: -84px;
  transform: rotate(6deg);
  background: var(--paper);
  padding: 0.6rem 0.6rem 2rem;
}

.photo__img {
  height: 118px;
  background:
    radial-gradient(circle at 70% 20%, rgba(255,255,255,0.35), transparent 45%),
    linear-gradient(160deg, #2f4f43 0%, #17281f 55%, #0c130e 100%);
}

.photo__caption {
  margin-top: 0.5rem;
  font-size: 0.62rem;
  font-style: italic;
  color: #6d685c;
  text-align: center;
}

/* 5 — round sticker */
.artefact--sticker {
  left: 38%;
  top: 30px;
  transform: rotate(-12deg);
  width: 92px;
  height: 92px;
  border-radius: 50%;
  background: var(--green);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 24px rgba(0,0,0,0.4);
}

.artefact--sticker p {
  font-family: var(--font-terrain);
  font-size: 1.15rem;
  color: var(--white);
  letter-spacing: 0.04em;
}

.artefact--sticker span { opacity: 0.65; margin-left: 2px; }

/* ---------- second beat: work & process ---------- */

.studio {
  background: var(--black);
  color: #eee;
  border-top: 1px solid #1c1c1c;
  padding: 5rem 1.5rem 6rem;
}

.studio__inner { max-width: 40rem; margin: 0 auto; }

.studio__kicker {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #777;
  margin-bottom: 1.4rem;
}

.work-list { list-style: none; margin-bottom: 2.5rem; }

.work-list li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 0;
  border-bottom: 1px solid #1c1c1c;
  font-size: 1rem;
}

.work-year { color: #777; }

.studio__note {
  font-size: 0.85rem;
  line-height: 1.6;
  color: #999;
  margin-bottom: 2rem;
}

.studio__note a { color: var(--green); }

.cta--invert { background: transparent; border: 1px solid var(--green); color: var(--green); }
.cta--invert:hover, .cta--invert:focus-visible { background: var(--green); color: var(--white); }

/* ---------- mobile ---------- */

@media (max-width: 640px) {
  .world--white { padding-bottom: 5.5rem; }

  .name { font-size: 34vw; }

  .artefact--clipping { width: 190px; left: -4%; top: -66px; }
  .artefact--book { width: 116px; height: 164px; left: 60%; top: -54px; }
  .artefact--book .book__title { font-size: 1.3rem; }
  .artefact--card { display: none; }           /* five is clutter at 375px */
  .artefact--photo { width: 132px; right: -6%; top: 26px; }
  .artefact--photo .photo__img { height: 92px; }
  .artefact--sticker { width: 72px; height: 72px; left: 10%; top: 36px; }
}
