/*
 * Fieldwork: editorial art direction (2026-10-12), loaded after the shared demo bundle.
 * A light touch on an already architectural design: a near full-width headline set like a caption on the
 * building, a tracked info row along the top of the hero, a stronger veil behind the type on phones, and the
 * horizon photograph unmasking as it arrives.
 */

body[data-demo="fieldwork-architecture"] .hero .copy {
  max-width: none;
  width: 100%;
}

body[data-demo="fieldwork-architecture"] .hero .copy h1 {
  margin: 28px 0 32px;
  font-size: clamp(4.4rem, 12.6vw, 13rem);
  line-height: 0.8;
  letter-spacing: -0.075em;
}

body[data-demo="fieldwork-architecture"] .hero .copy p {
  max-width: 460px;
}

/* On wide screens the info row carries the eyebrow's words, so the eyebrow itself steps aside (still read aloud). */
@media (min-width: 801px) {
  body[data-demo="fieldwork-architecture"] .hero .copy > span {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
  }
}

/* A tracked info row along the top of the hero (from facts already on the page). */
body[data-demo="fieldwork-architecture"] .hero::before {
  content: "Residential architecture     Landscape     Texas     Founded 2014";
  position: absolute;
  top: 104px;
  left: 5vw;
  right: 5vw;
  z-index: 1;
  padding-bottom: 14px;
  border-bottom: 1px solid #ffffff2e;
  font: 600 0.58rem/1 "Demo Mono", monospace;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  white-space: pre;
  word-spacing: 1.4em;
  color: #e7e4dccc;
}

@media (max-width: 800px) {
  body[data-demo="fieldwork-architecture"] .hero::before {
    display: none;
  }

  /* Phones: the building takes the top half and fades into a dark ground for the copy, so the eyebrow never
     crosses the bright sky and the house stays visible. */
  body[data-demo="fieldwork-architecture"] .hero {
    background: #090c0c;
    isolation: isolate;
  }

  body[data-demo="fieldwork-architecture"] .hero > img {
    inset: 70px 0 auto !important;
    height: 46svh !important;
    object-position: 58% 45%;
    -webkit-mask-image: linear-gradient(to bottom, #000 62%, transparent 100%);
    mask-image: linear-gradient(to bottom, #000 62%, transparent 100%);
  }

  body[data-demo="fieldwork-architecture"] .hero .veil {
    background: linear-gradient(180deg, transparent 30%, #090c0c80 48%, #090c0c 60%);
  }

  body[data-demo="fieldwork-architecture"] .hero .copy h1 {
    font-size: clamp(3.4rem, 17vw, 5.6rem);
  }
}

@media (prefers-reduced-motion: no-preference) {
  @supports (animation-timeline: view()) {
    @keyframes fw-unmask {
      from {
        clip-path: inset(0 0 0 100%);
      }
      to {
        clip-path: inset(0);
      }
    }

    @keyframes fw-draw-in {
      from {
        opacity: 0;
        transform: translateY(24px);
      }
    }

    body[data-demo="fieldwork-architecture"] .project img,
    body[data-demo="fieldwork-architecture"] .fwDrawStage img {
      animation: fw-unmask linear both;
      animation-timeline: view();
      animation-range: entry 5% cover 40%;
    }

    body[data-demo="fieldwork-architecture"] .fieldSequence article {
      animation: fw-draw-in linear both;
      animation-timeline: view();
      animation-range: entry 0% entry 80%;
    }
  }
}

/* Depth (2026-10-12). Architecture is about depth and site: the building, the grid lines and the type sit on three planes and move at different rates. Pointer devices only; off under reduced motion. */
@media (prefers-reduced-motion: no-preference) and (hover: hover) and (pointer: fine) {
  body[data-demo="fieldwork-architecture"] .hero > img {
    translate: calc(var(--dx-px, 0) * -16px) calc(var(--dx-py, 0) * -10px);
    transition: translate 0.8s cubic-bezier(0.2, 0.7, 0.2, 1);
  }

  body[data-demo="fieldwork-architecture"] .hero > .grid {
    translate: calc(var(--dx-px, 0) * 8px) calc(var(--dx-py, 0) * 5px);
    transition: translate 0.8s cubic-bezier(0.2, 0.7, 0.2, 1);
  }

  body[data-demo="fieldwork-architecture"] .hero > .copy {
    translate: calc(var(--dx-px, 0) * 6px) calc(var(--dx-py, 0) * 4px);
    transition: translate 0.8s cubic-bezier(0.2, 0.7, 0.2, 1);
  }
}

/* Registered foreground layers: original source pixels, segmented alpha (2026-10-13). */
body[data-authored-demo][data-demo="fieldwork-architecture"] .hero { isolation: isolate; }
body[data-authored-demo][data-demo="fieldwork-architecture"] .hero > img { position:absolute; inset:0; width:100%; height:100%; object-fit:cover; object-position:center; pointer-events:none; scale:1.08; z-index:-5; }
body[data-authored-demo][data-demo="fieldwork-architecture"] .hero > .dx-foreground { z-index:-3; }
body[data-authored-demo][data-demo="fieldwork-architecture"] .hero > .veil { z-index:-1; }
body[data-authored-demo][data-demo="fieldwork-architecture"] .hero > .dx-light { z-index:-2; }
body[data-authored-demo][data-demo="fieldwork-architecture"] .hero > .grid { z-index:0; pointer-events:none; }
body[data-authored-demo][data-demo="fieldwork-architecture"] .hero > .copy, body[data-authored-demo][data-demo="fieldwork-architecture"] .hero > aside { z-index:1; }
@media(prefers-reduced-motion:no-preference) and (hover:hover) and (pointer:fine) { body[data-authored-demo][data-demo="fieldwork-architecture"] .hero > img { translate:calc(var(--dx-px,0) * -10px) calc(var(--dx-py,0) * -10px); } body[data-authored-demo][data-demo="fieldwork-architecture"] .hero > .dx-foreground { translate:calc(var(--dx-px,0) * -20px) calc(var(--dx-py,0) * -20px); } }
@media(prefers-reduced-motion:reduce) { body[data-authored-demo][data-demo="fieldwork-architecture"] .hero > img { animation:none!important; translate:none!important; transition:none!important; } }
