/* ============================================================
   CCE — OUR WORK LAYER
   Sits on top of brand.css + site.css + editorial.css. No new
   fonts, palette, radii or shadow conventions — the same tokens
   in a case-study posture: photography leads, the headline
   carries the weight, hairlines do the separating.
   Used by /our-work/ and by every /our-work/<slug>/ page.
   ============================================================ */

/* ---------- page shell ----------
   Our Work opens on paper rather than a full-bleed photograph, so the
   header is solid from the first pixel and scrolls with the page.
   (No id="edHeader" in the markup — editorial.js leaves it alone.) */
.wk .ed-header { position: sticky; top: 0; left: auto; right: auto; }

/* ============================================================
   1 · HERO — typographic, spacious, no metrics
   ============================================================ */
.wk-hero { padding-block: clamp(44px, 7vh, 92px) clamp(32px, 5vh, 64px); }
.wk-hero__h {
  font-family: var(--font-display); font-weight: var(--w-black);
  font-size: clamp(2.5rem, 6.4vw, 5.25rem); line-height: 0.98;
  letter-spacing: -0.05em; color: var(--ink);
  max-width: 16ch; text-wrap: balance;
}
.wk-hero__body {
  margin-top: clamp(22px, 2.6vw, 34px);
  max-width: 58ch; color: var(--body);
  font-size: clamp(1.02rem, 1.25vw, 1.2rem); line-height: 1.6;
}
.wk-hero__body p + p { margin-top: 16px; }

/* one wide establishing frame — the hero's only image */
.wk-heroband { overflow: hidden; background: var(--mist); }
.wk-heroband img {
  width: 100%; height: clamp(220px, 42vh, 520px); object-fit: cover;
  display: block;
}

/* ============================================================
   2 · SELECTED WORK INTRO — the transition, kept short
   ============================================================ */
.wk-intro { padding-block: clamp(56px, 8vh, 112px); }
.wk-intro .manifesto { align-items: start; }
.wk-intro__body { color: var(--body); max-width: 54ch; }
.wk-intro__body p + p { margin-top: 16px; }

/* ============================================================
   SHARED CASE FURNITURE
   ============================================================ */
.wk-rule { width: 44px; height: 3px; background: var(--yellow); border-radius: 2px; }

.wk-eyebrow {
  display: flex; align-items: baseline; flex-wrap: wrap; gap: 8px 14px;
  margin-top: 20px;
  font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.18em;
  text-transform: uppercase;
}
/* n-400, not n-300: these run at 0.7rem and n-300 lands at 3.4:1 on paper —
   under AA for text this size. */
.wk-eyebrow__n { color: var(--n-400); }
.wk-eyebrow__type { color: var(--n-500); }

.wk-case__t {
  font-family: var(--font-display); font-weight: var(--w-black);
  line-height: 1.02; letter-spacing: -0.042em; color: var(--ink);
  margin-top: 14px; text-wrap: balance;
}
.wk-case__t a { transition: color var(--dur) var(--ease); }
.wk-case__t a:hover { color: var(--n-600); }

/* capability tags — wrap freely, never a hover-only affordance */
.wk-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: clamp(18px, 2vw, 26px); list-style: none; }
.wk-tag {
  display: inline-flex; align-items: center; min-height: 30px; padding: 0 13px;
  border: 1px solid var(--hairline); border-radius: var(--r-pill);
  font-family: var(--font-mono); font-size: 0.66rem; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--n-500); white-space: nowrap;
}
@media (max-width: 420px) { .wk-tag { white-space: normal; } }

/* a labelled block: mono heading over prose */
.wk-block__h {
  font-family: var(--font-mono); font-weight: var(--w-med);
  font-size: 0.7rem; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--n-400); padding-bottom: 12px; margin-bottom: 16px;
  border-bottom: 1px solid var(--hairline);
}
/* a section label with no rule — used where the block below carries its own */
.wk-block__h--plain { border-bottom: 0; padding-bottom: 0; margin-bottom: 14px; }
.wk-block__p { color: var(--body); max-width: 60ch; }
.wk-block__p + .wk-block__p { margin-top: 14px; }

/* closing line — the sentence each case turns on */
.wk-case__closing {
  font-family: var(--font-display); font-weight: var(--w-bold);
  font-size: clamp(1.15rem, 1.75vw, 1.5rem); line-height: 1.28;
  letter-spacing: -0.025em; color: var(--ink); max-width: 46ch;
  border-left: 3px solid var(--yellow); padding-left: clamp(16px, 2vw, 24px);
}

/* the one supporting line the nonprofit case is allowed to carry */
.wk-aside {
  margin-top: 18px; font-family: var(--font-mono); font-size: 0.7rem;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--n-400);
}

/* CTA — text link with a real 44px target, distinguishable by its rule */
.wk-cta {
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px;
  font-family: var(--font-display); font-weight: var(--w-semi); font-size: 0.95rem;
  color: var(--ink); border-bottom: 1px solid var(--ink);
  transition: gap var(--dur) var(--ease), color var(--dur) var(--ease);
}
.wk-cta:hover { gap: 14px; }

/* ============================================================
   CASE — shared frame
   ============================================================ */
.wk-case { border-top: 1px solid var(--hairline); padding-block: clamp(56px, 8vh, 120px); }
.wk-case__media { border-radius: var(--r-ed); overflow: hidden; background: var(--mist); }
.wk-case__media img { width: 100%; height: 100%; object-fit: cover; transition: transform var(--dur-slow) var(--ease-out); }
.wk-case:hover .wk-case__media img { transform: scale(1.02); }

/* ---------- flagship: full-width frame, then an editorial spread ---------- */
.wk-case--lead .wk-case__media { aspect-ratio: 16 / 9; }
@media (max-width: 640px) { .wk-case--lead .wk-case__media { aspect-ratio: 4 / 3; } }

.wk-lead__head {
  display: grid; grid-template-columns: 1.2fr 0.8fr;
  gap: clamp(24px, 4vw, 72px); align-items: start;
  margin-top: clamp(28px, 3.6vw, 52px);
}
@media (max-width: 900px) { .wk-lead__head { grid-template-columns: 1fr; gap: 22px; align-items: start; } }
.wk-case--lead .wk-case__t { font-size: clamp(2rem, 4.2vw, 3.4rem); max-width: 18ch; }
/* ---------- preview copy ----------
   The index carries a summary and the proof, nothing more. Both surfaces reuse
   .wk-outcomes and .wk-metrics, so the overview and the case pages stay one
   visual system rather than two. */
.wk-lead__summary, .wk-case__summary { color: var(--body); max-width: 52ch; }
.wk-lead__summary p + p, .wk-case__summary p + p { margin-top: 14px; }
.wk-lead__summary { margin-top: clamp(18px, 2vw, 24px); }
.wk-lead__proof { margin-top: clamp(32px, 4vw, 60px); }
.wk-case__cta { margin-top: clamp(24px, 3vw, 40px); }
@media (min-width: 901px) { .wk-lead__head .wk-tags { justify-content: flex-end; } }

.wk-lead__cols {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: clamp(28px, 4vw, 72px);
  margin-top: clamp(36px, 5vw, 72px);
}
@media (max-width: 860px) { .wk-lead__cols { grid-template-columns: 1fr; gap: 32px; } }

/* ---------- supporting cases: asymmetric, alternating ---------- */
.wk-case--std .wk-case__grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: clamp(28px, 4.5vw, 80px); align-items: start;
}
.wk-case--std .wk-case__media { aspect-ratio: 3 / 2; }
@media (min-width: 901px) {
  /* the frame holds beside the text while it scrolls. 3:2 rather than a taller
     crop: the case photography is landscape, and a portrait frame cut subjects
     out of the side of it. */
  .wk-case--std .wk-case__media { aspect-ratio: 3 / 2; position: sticky; top: 108px; }
  /* alternate the frame between left and right so four cases never read as
     four identical rows. DOM order stays image-first for mobile. */
  .wk-case--flip .wk-case__media { order: 2; }
  /* mirror the tracks too, so the frame is the same size on either side —
     otherwise the flipped case takes the wider column and its photograph
     renders larger than its neighbours' */
  .wk-case--flip .wk-case__grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 900px) {
  .wk-case--std .wk-case__grid { grid-template-columns: 1fr; gap: 26px; }
  .wk-case--std .wk-case__media { aspect-ratio: 3 / 2; }
}
.wk-case__body > * + * { margin-top: clamp(26px, 3vw, 38px); }
.wk-case__body .wk-eyebrow { margin-top: 20px; }
.wk-case__body .wk-case__t { margin-top: 14px; font-size: clamp(1.7rem, 2.9vw, 2.5rem); max-width: 20ch; }
.wk-case__body .wk-tags { margin-top: 18px; }

/* ---------- outcomes: hairline rows, not boxes ---------- */
.wk-outcomes { list-style: none; border-top: 1px solid var(--hairline); }
.wk-outcomes li { padding-block: 14px; border-bottom: 1px solid var(--hairline); }
.wk-outcomes strong {
  display: block; color: var(--ink); font-weight: var(--w-semi);
  font-size: 1.02rem; line-height: 1.3; letter-spacing: -0.01em; margin-bottom: 5px;
}
.wk-outcomes span { color: var(--body); display: block; max-width: 56ch; }

/* ============================================================
   FLAGSHIP · four-stage progression
   ============================================================ */
.wk-stages {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 1px; background: var(--hairline);
  border-block: 1px solid var(--hairline);
  margin-top: clamp(36px, 5vw, 72px);
}
@media (max-width: 900px) { .wk-stages { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .wk-stages { grid-template-columns: 1fr; } }
.wk-stage { background: var(--paper); padding: clamp(22px, 2.4vw, 32px) clamp(18px, 2vw, 28px); }
.wk-stage__n { font-family: var(--font-mono); font-size: 0.68rem; letter-spacing: 0.18em; color: var(--n-400); }
.wk-stage__t {
  font-family: var(--font-display); font-weight: var(--w-bold);
  font-size: clamp(1.05rem, 1.4vw, 1.25rem); letter-spacing: 0.02em;
  text-transform: uppercase; color: var(--ink); margin: 14px 0 10px;
}
.wk-stage p { color: var(--body); font-size: 0.95rem; }

/* ============================================================
   FLAGSHIP · verified results
   ============================================================ */
.wk-metrics {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px; background: var(--hairline);
  border-block: 1px solid var(--hairline);
  margin-top: clamp(28px, 3.2vw, 44px);
}
@media (max-width: 860px) { .wk-metrics { grid-template-columns: 1fr; } }
/* Tablet doesn't inherit the cramped desktop row: the figures stack, but the
   value and its wording sit side by side so the width is not left empty.
   Still one column of rows — nothing scrolls sideways. */
@media (min-width: 561px) and (max-width: 860px) {
  .wk-metric { display: grid; grid-template-columns: minmax(0, 12em) 1fr; column-gap: clamp(20px, 3.5vw, 44px); align-items: start; }
  .wk-metric__v { grid-column: 1; grid-row: 1 / span 2; }
  .wk-metric__l { grid-column: 2; grid-row: 1; margin-top: 0; max-width: 48ch; }
  .wk-metric__note { grid-column: 2; grid-row: 2; max-width: 48ch; }
}
.wk-metric { background: var(--paper); padding: clamp(24px, 2.8vw, 38px) clamp(18px, 2vw, 28px); min-width: 0; }
.wk-metric__v {
  font-family: var(--font-display); font-weight: var(--w-black);
  font-size: clamp(1.65rem, 3vw, 2.6rem); line-height: 1.04;
  letter-spacing: -0.04em; color: var(--ink);
  overflow-wrap: break-word; text-wrap: balance;
}
.wk-metric__l { color: var(--body); margin-top: 14px; max-width: 34ch; }
/* evidence note — kept with the figure it qualifies, never dropped */
.wk-metric__note {
  margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--hairline-soft);
  color: var(--n-400); font-size: 0.85rem; line-height: 1.5; max-width: 38ch;
}

/* ============================================================
   7 · ACROSS OUR PRACTICE — a compact index, not six cards
   ============================================================ */
.wk-practice { border-top: 1px solid var(--hairline); padding-block: clamp(56px, 8vh, 112px); }
.wk-practice__list {
  list-style: none;
  display: grid; grid-template-columns: 1fr 1fr;
  column-gap: clamp(32px, 5vw, 96px);
  border-top: 1px solid var(--hairline);
  margin-top: clamp(28px, 3.6vw, 52px);
}
@media (max-width: 760px) { .wk-practice__list { grid-template-columns: 1fr; } }
.wk-practice__list li {
  display: grid; grid-template-columns: 4ch 1fr; gap: clamp(12px, 2vw, 24px);
  align-items: baseline;
  padding-block: clamp(16px, 1.8vw, 24px);
  border-bottom: 1px solid var(--hairline);
}
.wk-practice__n { font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.16em; color: var(--n-400); }
.wk-practice__t {
  font-family: var(--font-display); font-weight: var(--w-bold);
  font-size: clamp(1.1rem, 1.7vw, 1.45rem); line-height: 1.22;
  letter-spacing: -0.025em; color: var(--ink);
}

/* ============================================================
   8 · CLOSING CTA — clean, confident, no photography
   ============================================================ */
.wk-close { border-top: 1px solid var(--hairline); padding-block: clamp(64px, 9vh, 128px); }
.wk-close__grid { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: clamp(24px, 4vw, 80px); align-items: center; }
@media (max-width: 900px) { .wk-close__grid { grid-template-columns: 1fr; gap: 26px; } }
.wk-close__h {
  font-family: var(--font-display); font-weight: var(--w-black);
  font-size: clamp(2rem, 3.8vw, 3.25rem); line-height: 1.02;
  letter-spacing: -0.045em; color: var(--ink); max-width: 16ch; text-wrap: balance;
}
.wk-close p { color: var(--body); max-width: 52ch; }
.wk-close .btnrow { margin-top: clamp(24px, 3vw, 36px); }

/* ============================================================
   CASE-STUDY DETAIL — the reusable template
   ============================================================ */
.wkart { padding-block: clamp(36px, 5vh, 72px) 0; }
.wkart__back {
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px;
  font-family: var(--font-mono); font-size: 0.68rem; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--n-400);
  transition: color var(--dur) var(--ease);
}
.wkart__back:hover { color: var(--ink); }
.wkart__h {
  font-family: var(--font-display); font-weight: var(--w-black);
  font-size: clamp(2.1rem, 4.6vw, 3.6rem); line-height: 1.0;
  letter-spacing: -0.048em; color: var(--ink);
  max-width: 18ch; margin-top: 14px; text-wrap: balance;
}
.wkart__summary {
  font-size: clamp(1.05rem, 1.4vw, 1.28rem); line-height: 1.5;
  color: var(--n-500); max-width: 54ch; margin-top: clamp(16px, 2vw, 24px);
}
.wkart__hero {
  margin-top: clamp(28px, 4vw, 56px);
  border-radius: var(--r-ed); overflow: hidden; background: var(--mist);
  aspect-ratio: 16 / 9;
}
/* the frame follows the case's own `imageRatio` so a 3:2 source is not
   cropped to a 16:9 letterbox */
.wkart__hero--3-2 { aspect-ratio: 3 / 2; }
.wkart__hero--4-3 { aspect-ratio: 4 / 3; }
@media (max-width: 640px) { .wkart__hero, .wkart__hero--3-2, .wkart__hero--4-3 { aspect-ratio: 4 / 3; } }
.wkart__hero img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- per-image focal point ----------
   Each frame can name its own focal point so a subject is not cropped out.
   `--pos` applies everywhere; `--pos-wide` takes over from 901px up, where the
   case frames change shape (16:9 / 4:5 on desktop vs 4:3 / 3:2 on mobile).
   Both are set inline per image; unset falls back to dead centre. */
.wk-case__media img,
.wkart__hero img,
.wkart__figure img { object-position: var(--pos, 50% 50%); }
@media (min-width: 901px) {
  .wk-case__media img,
  .wkart__hero img,
  .wkart__figure img { object-position: var(--pos-wide, var(--pos, 50% 50%)); }
}

/* ---------- supporting photography on a detail page ----------
   One frame between sections, in the prose column. Not a gallery, not a
   carousel — the same single-frame treatment as the hero, quieter. */
.wkart__figure {
  border-radius: var(--r-ed); overflow: hidden; background: var(--mist);
  aspect-ratio: 3 / 2;
}
.wkart__figure--16-9 { aspect-ratio: 16 / 9; }
.wkart__figure--3-2  { aspect-ratio: 3 / 2; }
.wkart__figure--2-1  { aspect-ratio: 2 / 1; }
.wkart__figure--4-5  { aspect-ratio: 4 / 5; }
.wkart__figure img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 640px) {
  /* a 2:1 band goes too letterboxed on a phone; give it back some height */
  .wkart__figure--2-1 { aspect-ratio: 3 / 2; }
}

/* body sections — a sticky mono label beside the prose */
.wkart__section { border-top: 1px solid var(--hairline); padding-block: clamp(36px, 5vw, 68px); }
.wkart__section:first-of-type { margin-top: clamp(40px, 5vw, 72px); }
.wkart__cols { display: grid; grid-template-columns: 0.42fr 1.58fr; gap: clamp(20px, 4vw, 72px); align-items: start; }
@media (max-width: 860px) { .wkart__cols { grid-template-columns: 1fr; gap: 18px; } }
/* section headings on the detail page read as mono labels, not as display
   type — the case title is the only thing meant to shout */
.wkart__label {
  font-family: var(--font-mono); font-weight: var(--w-med);
  font-size: 0.7rem; line-height: 1.5; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--n-400);
}
@media (min-width: 861px) { .wkart__label { position: sticky; top: 108px; } }
.wkart__prose { color: var(--body); max-width: 64ch; font-size: 1.03rem; }
/* what the work actually covered, where the copy is a list rather than prose */
.wkart__list { list-style: none; margin-top: 18px; border-top: 1px solid var(--hairline); max-width: 52ch; }
.wkart__list li { padding-block: 11px; border-bottom: 1px solid var(--hairline); color: var(--ink); }
.wkart__prose > * + * { margin-top: 18px; }

/* related capabilities + the two closing rails */
.wkart__caps { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; }
.wkart__foot {
  border-top: 1px solid var(--hairline); padding-block: clamp(28px, 3.4vw, 44px);
  display: flex; flex-wrap: wrap; gap: 12px 32px; align-items: center; justify-content: space-between;
}

@media (prefers-reduced-motion: reduce) {
  .wk-case__media img, .wk-cta { transition: none; }
  .wk-case:hover .wk-case__media img { transform: none; }
}
