/* Shared editorial layout for the Work case studies. */
.work-case {
  --ink: #121212;
  --paper: #fff;
  --muted: #5d5d5d;
  --line: #d7d7d7;
  --accent: #c8124c;
  --accent-ink: #fff;
  --gutter: clamp(20px, 4vw, 56px);
  --max: 1240px;
  --ease: cubic-bezier(.16, 1, .3, 1);
  --sans: Archivo, 'Helvetica Neue', Arial, sans-serif;
  --serif: 'Bespoke Serif', Georgia, 'Times New Roman', serif;
  --display: Tanker, Archivo, Impact, sans-serif;
  color: var(--ink);
  font: 400 16px/1.65 var(--sans);
}
:where(.work-case) :where(h1,h2,h3,p,figure) { margin: 0; }
.work-case :is(h1,h2,h3) { font-weight: 400; }
:where(.work-case) img { display: block; max-width: 100%; height: auto; }
.work-case a { color: inherit; }
.case-motion [data-reveal] { opacity: 0; transform: translateY(28px); transition: opacity .9s var(--ease), transform 1.1s var(--ease); transition-delay: var(--d, 0s); }
.case-motion [data-reveal].is-in { opacity: 1; transform: none; }
.work-case .btn { display: inline-flex; align-items: center; justify-content: center; gap: 12px; min-height: 52px; padding: 0 28px; border-radius: 99px; font: 700 16px var(--sans); text-decoration: none; }
:where(.work-case) .wrap { max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }
.work-case .wrap { --indent: clamp(0px, 7vw, 110px); }

.a-crumbs { max-width: var(--max); margin: 0 auto; padding: clamp(28px, 4vw, 56px) var(--gutter) 22px calc(var(--gutter) + clamp(0px, 7vw, 110px)); display: flex; flex-wrap: wrap; gap: 6px; font-family: var(--display); font-size: 15px; letter-spacing: .02em; text-transform: uppercase; }
.a-crumbs a { text-decoration: none; }
.a-crumbs a:hover { color: var(--accent); }
.a-crumbs [aria-current] { color: var(--accent); }

/* Hero */
.a-hero { position: relative; margin: 0 clamp(12px, 1.5vw, 20px); padding-bottom: clamp(70px, 9vw, 150px); }
.a-hero-media { position: relative; height: clamp(300px, 52vh, 560px); overflow: hidden; background: #111; animation: a-band 1.4s var(--ease) both; }
.a-hero-media::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,0) 35%, rgba(0,0,0,.55) 100%); }
.a-hero-img { width: 100%; height: 118%; object-fit: cover; transform: translateY(calc(var(--p, 0) * -14%)); will-change: transform; animation: a-zoom 1.8s var(--ease) both; }
.a-hero-text { position: absolute; left: calc(var(--gutter) + clamp(0px, 7vw, 110px) - clamp(12px, 1.5vw, 20px)); right: var(--gutter); bottom: 0; }
.a-eyebrow { font-family: var(--display); font-size: clamp(18px, 2vw, 28px); color: #fff; text-transform: uppercase; letter-spacing: .01em; margin-bottom: clamp(6px, 1vw, 14px); animation: a-rise 1s .35s var(--ease) both; }
.a-title { font-family: var(--display); color: var(--accent); text-transform: uppercase; font-size: clamp(64px, 12.5vw, 210px); line-height: .84; letter-spacing: -.01em; overflow: hidden; padding-bottom: .04em; }
.a-title span { display: block; animation: a-rise 1.1s .25s var(--ease) both; }
.work-case .a-crumbs [aria-current],
.work-case .a-title { color: #000; }
.work-case .a-title {
  width: fit-content;
  margin-left: -.045em;
  padding-inline: .045em;
  background: var(--paper);
}
@keyframes a-band { from { clip-path: inset(0 0 100% 0); } to { clip-path: inset(0); } }
@keyframes a-zoom { from { scale: 1.12; } to { scale: 1; } }
@keyframes a-rise { from { transform: translateY(105%); opacity: 0; } to { transform: none; opacity: 1; } }

/* Lede */
.a-intro { padding-top: clamp(40px, 6vw, 80px); padding-bottom: clamp(56px, 7vw, 104px); }
.a-lede { margin-left: var(--indent); max-width: 30ch; font-family: var(--serif); font-size: clamp(27px, 3.5vw, 50px); line-height: 1.1; letter-spacing: -.015em; }
.a-intro-with-press {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: clamp(28px, 6vw, 84px);
  padding-right: calc(var(--gutter) + var(--indent));
}
.a-intro-press {
  border-top: 1px solid var(--ink);
  padding-top: 10px;
  min-width: 128px;
}
.a-intro-press h2 {
  font: 600 13px/1.3 var(--sans);
  margin-bottom: 10px;
}
.a-intro-press .press-item {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
}
.a-intro-press .press-item::after { content: "↗" / ""; font-size: 21px; }
.a-intro-press .press-item:hover { color: var(--accent); }
.a-intro-press .press-mark { height: 45px; width: auto; }
@media (max-width: 640px) {
  .a-intro-with-press { grid-template-columns: 1fr; gap: 24px; }
  .a-intro-press { display: flex; align-items: center; justify-content: space-between; padding-top: 9px; }
  .a-intro-press h2 { margin: 0; }
  .a-intro-press .press-mark { height: 42px; }
}

/* Body */
.a-body { font-size: 17px; line-height: 1.7; }
.a-cols { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 6vw, 88px); padding-bottom: clamp(64px, 8vw, 120px); }
.a-cols p { padding-left: var(--indent); }
.a-cols p + p { padding-left: 0; padding-right: var(--indent); }
.a-row { display: grid; grid-template-columns: minmax(0, 1.18fr) minmax(0, 1fr); align-items: center; gap: clamp(28px, 5vw, 80px); margin-bottom: clamp(56px, 7vw, 112px); }
.a-row--right { grid-template-columns: minmax(0, 1fr) minmax(0, 1.18fr); }
.a-row-media { margin: 0; position: relative; }
.a-row-media img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.a-row-media.is-tall img { aspect-ratio: 4 / 5; max-height: 86vh; object-position: 50% 35%; }
.a-row:has(.is-tall) { grid-template-columns: minmax(0, .82fr) minmax(0, 1fr); }
.a-row--left .a-row-text { padding-right: max(var(--gutter), calc((100vw - var(--max)) / 2 + var(--gutter))); }
.a-row--right .a-row-text { padding-left: max(var(--gutter), calc((100vw - var(--max)) / 2 + var(--gutter) + clamp(0px, 7vw, 110px))); }
.a-row-text { display: grid; gap: 1.2em; max-width: calc(52ch + 200px); }
.a figcaption { font-size: 13px; color: var(--muted); margin-top: 10px; padding-inline: var(--gutter); }
/* Wipe reveal: a paper panel slides off (keeps the image observable for lazy loading). */
.case-motion .a-row-media[data-reveal] { opacity: 1; transform: none; overflow: hidden; }
.case-motion .a-row-media[data-reveal]::after { content: ''; position: absolute; inset: 0 0 auto; height: 100%; background: var(--paper); transform-origin: 100% 50%; transition: transform 1.3s var(--ease); }
.case-motion .a-row--right .a-row-media[data-reveal]::after { transform-origin: 0 50%; }
.case-motion .a-row-media[data-reveal] img { scale: 1.08; transition: scale 1.6s var(--ease); }
.case-motion .a-row-media[data-reveal].is-in::after { transform: scaleX(0); }
.case-motion .a-row-media[data-reveal].is-in img { scale: 1; }

.a-statement { margin-top: clamp(24px, 4vw, 48px); margin-bottom: clamp(80px, 10vw, 150px); text-align: center; font-family: var(--serif); font-size: clamp(25px, 3vw, 42px); line-height: 1.15; letter-spacing: -.01em; max-width: 1060px; }

/* Mixed headings (existing words, split for type only) */
.a-mixed { text-align: center; line-height: .95; margin-bottom: clamp(28px, 4vw, 52px); }
.a-mixed .h-serif { font-family: var(--serif); font-size: clamp(36px, 5.2vw, 76px); letter-spacing: -.02em; }
.a-mixed .h-display { display: block; font-family: var(--display); font-size: clamp(44px, 6.6vw, 98px); text-transform: uppercase; color: var(--accent); }

/* Related */
.a-related { padding-bottom: clamp(72px, 9vw, 120px); }
.a-pills { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; }
.a-pill { display: inline-flex; align-items: center; gap: 12px; min-height: 52px; padding: 0 26px; border: 2px solid var(--ink); border-radius: 99px; font-weight: 600; text-decoration: none; transition: background-color .25s, color .25s, border-color .25s; }
.a-pill .arrow { transition: transform .35s var(--ease); }
.a-pill:hover { background: var(--accent); border-color: var(--accent); color: #fff; }
.a-pill:hover .arrow { transform: translateX(4px); }

/* CTA: an accent band whose corners round off as it arrives */
.a-cta { margin: 0 clamp(12px, 1.5vw, 20px); background: var(--accent); color: #fff; border-radius: calc((1 - var(--p, 1)) * 120px + 18px); transform: scale(calc(.94 + var(--p, 1) * .06)); transform-origin: 50% 0; }
.a-cta-inner { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 32px; padding-block: clamp(72px, 10vw, 150px); }
.a-cta h2 { font-family: var(--serif); font-size: clamp(36px, 5.6vw, 84px); line-height: 1.02; letter-spacing: -.02em; max-width: 16ch; }
.a-cta .btn { background: #fff; color: var(--ink); }
.a-allwork { padding-block: 40px 72px; }
.a-allwork a { font-weight: 700; text-decoration: none; display: inline-flex; gap: 10px; min-height: 44px; align-items: center; padding-left: var(--indent); }
.a-allwork a:hover { color: var(--accent); }

@media (max-width: 860px) {
  .work-case .wrap { --indent: 0px; }
  .a-crumbs { padding-left: var(--gutter); font-size: 13px; }
  .a-hero-text { left: calc(var(--gutter) - 12px); }
  .a-hero-media { height: 58vw; min-height: 260px; }
  .a-cols { grid-template-columns: 1fr; gap: 1.2em; }
  .a-cols p + p { padding-right: 0; }
  .a-row, .a-row--right { grid-template-columns: 1fr; gap: 24px; }
  .a-row--right .a-row-media { order: -1; }
  .a-row .a-row-text { padding-inline: var(--gutter); }
  .a-row-media.is-tall img { aspect-ratio: 4 / 5; max-height: 80vh; }
  .a-row:has(.is-tall) { grid-template-columns: 1fr; }
  .a-cta { border-radius: calc((1 - var(--p, 1)) * 48px + 14px); }
}

@media (prefers-reduced-motion: reduce) {
  .a-hero-img { transform: none; height: 100%; }
  .case-motion .a-row-media[data-reveal]::after { display: none; }
  .case-motion .a-row-media[data-reveal] img { scale: 1; }
  .a-cta { transform: none; border-radius: 18px; }
}
#main-content .work-case .a-title { font-family: var(--display); }
#main-content .a-intro-press h2 { font: 600 13px/1.3 var(--sans); }
body[data-page^="work/"] { --site-header-height: 84px; }
[data-page^="work/"] .header.site-header { min-height: var(--site-header-height); padding: 0 clamp(20px,4vw,56px); }
/* 3 Dec 2026: case studies now use the same wordmark as every other page. */
[data-page^="work/"] .site-header nav.desktop-nav { gap: clamp(16px,2.2vw,32px); font-size: 14px; }
[data-page^="work/"] .site-header nav.desktop-nav .nav-contact {
  min-height: 40px; padding: 0 20px; border: 0; border-radius: 99px;
  background: #c8124c; color: #fff; box-shadow: none; font-size: 14px; font-weight: 600;
}
[data-page^="work/"] .site-header nav.desktop-nav .nav-contact:hover { background: #b01043; }
@media (max-width: 860px) { body[data-page^="work/"] { --site-header-height: 68px; } }
@media (prefers-reduced-motion: reduce) { .case-motion [data-reveal] { opacity: 1; transform: none; } }

.case-context { margin: 0 0 14px var(--indent); font: 600 14px/1.3 var(--sans); }
.case-context::first-letter { text-transform: uppercase; }
.case-outlets { display: grid; justify-items: start; gap: 12px; }
.case-outlets .press-item { min-height: 44px; }
.case-outlets .mark-2 { filter: brightness(0); }
.case-gallery { display: grid; grid-template-columns: 1fr 1fr; align-items: start; gap: clamp(12px,1.5vw,20px); padding-inline: clamp(12px,1.5vw,20px); margin-bottom: clamp(64px,8vw,120px); }
.case-gallery figure:nth-child(2) { margin-top: clamp(40px,8vw,120px); }
.case-gallery figure:last-child:nth-child(odd) { grid-column: 1 / -1; }
.case-gallery figure:last-child:nth-child(odd) img { aspect-ratio: 21 / 9; }
.case-section, .case-reading, .case-archive { margin-bottom: clamp(60px,8vw,108px); }
.case-section .folio-section, .case-archive .folio-section { margin: 0; }
.work-case .case-reading { display: grid; gap: 1.5em; max-width: 82ch; }
.case-section-title { margin: 0 auto clamp(22px,3vw,42px); font-size: clamp(32px,4.5vw,60px); line-height: 1.08; }
.case-passage h3 { margin: 0 0 .5em; font-size: clamp(25px,3vw,44px); line-height: 1.12; }
.a-row-text .pull { margin: 0; }
.case-archive .print-archive { margin-bottom: 0; }
.case-logo-hero .a-hero-media { background: #e8e5df; display: grid; place-items: center; }
.case-logo-hero .a-hero-media::after { background: linear-gradient(transparent 60%,#0009); }
.case-logo-hero .a-hero-img {
  position: absolute; top: 7%; inset-inline: 0; margin-inline: auto;
  width: 100%; height: 62%; object-fit: contain; filter: brightness(0); transform: none;
}
.case-review { display: grid; gap: 2px; }
.case-review span { color: var(--muted); font-size: 13px; }
@media (max-width: 640px) {
  .case-logo-hero .a-hero-img { top: 5%; height: 55%; }
}
[data-page="work/daal-bass/"] .work-case { --accent: #ad370c; }
@media (max-width: 640px) {
  .case-gallery { grid-template-columns: minmax(0,1fr); }
  .case-gallery figure:nth-child(2) { margin-top: 0; }
  .case-gallery figure:last-child:nth-child(odd) img { aspect-ratio: 4 / 3; }
  .case-outlets { justify-items: end; }
  .a-intro-press:has(.press-item:nth-child(2)) { align-items: flex-start; }
  .a-intro-press:has(.press-item:nth-child(2)) h2 { padding-top: 12px; }
}
