/* Case-study pages: loaded after css/site.css */

/* ── intro ── */
.case-intro { min-height: 0; }
.case-intro > .case-title { margin-top: clamp(120px, 16vw, 240px); }   /* same gap under "Home" on every page, whatever the title length */
.case-title { font-size: clamp(54px, 8.6vw, 124px); line-height: .9; margin-top: 18px; }
.case-title span > b { transform: translateY(105%); }
.case-title span:nth-child(2) > b { padding-left: 0; }
.meta { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.meta dt { font-size: 11px; text-transform: uppercase; letter-spacing: .03em; color: var(--muted); margin-bottom: 6px; }
.meta dd { margin: 0; }

/* ── images ── */
.hero-shot { background: var(--paper); padding: 0 var(--pad) var(--sy); }
.shot { margin: 0; }
.hero-shot > .shot { width: 100%; max-width: var(--container); margin: 0 auto; }
.shot img { width: 100%; height: auto; }
.shot figcaption, .post figcaption { margin-top: 14px; font-size: 13px; letter-spacing: .01em; color: var(--muted); }
.chapter--navy .shot figcaption { color: var(--on-dark-muted); }
.ph { display: grid; place-items: center; aspect-ratio: var(--ar, 16 / 9); background: rgba(30,40,60,.06); border: 1px dashed rgba(30,40,60,.25); font-size: 12px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); text-align: center; padding: 16px; }
.chapter--navy .ph { background: rgba(255,255,255,.06); border-color: rgba(255,255,255,.35); color: rgba(255,255,255,.75); }

/* ── chapters ── */
.chapter { padding: var(--sy) var(--pad); background: var(--mist); }
.chapter--paper { background: var(--paper); }
.chapter--navy { background: var(--navy); color: var(--white); }
.chapter > * { width: 100%; max-width: var(--container); margin-left: auto; margin-right: auto; }
.chapter__grid { display: grid; grid-template-columns: 1fr 1.25fr; gap: 40px 72px; margin-top: var(--after-label); }
.chapter--nolabel .chapter__grid { margin-top: 0; }
.chapter h2 { font-size: var(--mid); font-weight: 700; letter-spacing: -.03em; line-height: 1.02; margin: 0; text-wrap: balance; }
.chapter__text { max-width: 68ch; font-size: var(--body-lg); line-height: 1.5; color: var(--ink-soft); }
.chapter--navy .chapter__text { color: var(--on-dark); }
.chapter__text p { margin: 0 0 1em; }
.chapter__text p:last-child { margin-bottom: 0; }
.chapter__text .fields-intro { margin-top: 1.4em; }
.chapter__media { display: grid; gap: 24px; margin-top: var(--after-label); }
.chapter__media--2 { grid-template-columns: 1fr 1fr; }
.chapter__media--3 { grid-template-columns: repeat(3, 1fr); }
.fields { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 8px; }
.layers { margin-top: var(--after-label); }

/* ── post gallery (Team 79) ── */
.posts { display: grid; gap: 56px; margin-top: var(--after-label); }
.posts__label { font-size: 12px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin: 0 0 20px; padding-bottom: 14px; border-bottom: 1px solid var(--rule); }
.posts__grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
.post { margin: 0; }
.post img { width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; box-shadow: var(--shadow-post); }
.post figcaption { margin-top: 12px; }

/* ── closing quote ── */
.quote { position: relative; background: var(--ink); color: var(--white); padding: calc(var(--sy) + 32px) var(--pad); text-align: center; }
.quote > * { max-width: 1100px; margin-left: auto; margin-right: auto; }
.quote blockquote { margin: 0 auto; font-size: clamp(36px, 4.6vw, 66px); font-weight: 700; letter-spacing: -.03em; line-height: 1; text-wrap: balance; }
.quote__text + blockquote { margin-top: 48px; }
.quote__text { font-size: 18px; line-height: 1.5; max-width: 720px; margin: 40px auto 0; color: var(--on-dark-muted); }
.quote__text p { margin: 0 0 1em; }
.quote__sub { margin-top: 32px; font-size: 18px; color: var(--on-dark-muted); }

/* ── next project ── */
.next .label { padding-top: var(--sy); margin-bottom: 8px; }
.next .work a { padding: 64px 0; }

@media (max-width: 900px) {
  .meta { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .meta > div:last-child:nth-child(odd) { grid-column: 1 / -1; }   /* an odd last item (Tools) gets the full row */
  .chapter__grid, .chapter__media--2, .chapter__media--3 { grid-template-columns: 1fr; }
  .posts__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
}
@media (prefers-reduced-motion: reduce) {
  .case-title span > b { transform: none; }
}
@media (max-width: 600px) {
  .case-title { font-size: clamp(40px, 13.6vw, 54px); }
}

.chapter__media + .chapter__media { margin-top: 48px; }   /* a second row of images under the first */

/* ── About page ── */
.services { list-style: none; margin: 0; padding: 0; font-size: var(--mid); line-height: 1.33; letter-spacing: -.01em; }
.quote__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 16px; margin-top: 48px; }
.bio__grid { max-width: var(--container); margin: 0 auto; }
.bio__text .chapter__text { columns: 2; column-gap: 72px; max-width: none; }
.bio__text .chapter__text p { break-inside: avoid; }
.bio__lead { max-width: none; margin: 0 0 48px; font-size: var(--mid); line-height: 1.2; letter-spacing: -.02em; text-wrap: pretty; }
.timeline { list-style: none; margin: var(--after-label) auto 0; padding: 0; max-width: var(--container); border-top: 1px solid var(--rule); }
.timeline__row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: 16px 72px; padding: 40px 0; border-bottom: 1px solid var(--rule); }
.timeline h3 { margin: 0; font-size: clamp(28px, 3vw, 40px); font-weight: 400; letter-spacing: -.02em; line-height: 1.1; }
.timeline__meta { margin: 8px 0 0; font-size: 13px; color: var(--muted); }
.timeline__what { font-size: var(--body-lg); line-height: 1.5; color: var(--ink-soft); }
.timeline__what p { margin: 0; }
.timeline__role { font-weight: 500; color: var(--ink); margin-bottom: 6px !important; }
@media (max-width: 900px) {
  .timeline__row { grid-template-columns: 1fr; }
  .bio__text .chapter__text { columns: 1; }
  }
/* About: section labels sit on the same left edge as the hero, photo and lists */
.label--start, .chapter h2.label--start { align-items: flex-start; text-align: left; max-width: var(--container); margin-left: auto; margin-right: auto; }
.chapter h2.label { font-size: 13px; letter-spacing: .03em; line-height: 1.2; }   /* section labels stay label-sized inside chapters */

/* each project takes one ink for its feature band */
.p-cyan .chapter--navy { background: var(--cyan); color: var(--key); }
.p-magenta .chapter--navy { background: var(--magenta); color: var(--white); }
.p-yellow .chapter--navy { background: var(--process-yellow); color: var(--key); }
.p-cyan .chapter--navy .label, .p-yellow .chapter--navy .label { color: var(--key); }
.p-magenta .chapter--navy .label { color: var(--white); }
.p-magenta .chapter--navy .chapter__text, .p-magenta .chapter--navy p, .p-magenta .chapter--navy i { color: var(--white); }   /* solid white: 5.1:1 on magenta (the 86% white was 3.95:1) */
.p-cyan .chapter--navy .chapter__text, .p-yellow .chapter--navy .chapter__text { color: var(--key); }
.p-cyan .chapter--navy .pill, .p-yellow .chapter--navy .pill { color: var(--key); }
.p-cyan .chapter--navy figcaption, .p-yellow .chapter--navy figcaption { color: rgba(22,22,22,.75); }

/* phones and narrow tablets (900px and below, where chapters stack into one column):
   chapter labels line up with the left-aligned text under them; the closing quote and next project stay centred */
@media (max-width: 900px) {
  .chapter .label { align-items: flex-start; text-align: left; }
  .posts__label { text-align: left; }
}

/* focus ring on the project feature bands: key black on cyan and yellow, white on magenta */
.p-cyan .chapter--navy :focus-visible, .p-yellow .chapter--navy :focus-visible { outline-color: var(--ink); }
.p-magenta .chapter--navy :focus-visible { outline-color: var(--white); }

/* AI motion: videos of different shapes sit side by side at one shared height; they stack on phones */
.chapter__media--videos { display: flex; flex-wrap: wrap; justify-content: center; align-items: flex-start; gap: 32px; }
.shot--video { margin: 0; }
.shot--video video { display: block; height: min(72vh, 640px); width: auto; max-width: 100%; background: var(--ink); }
@media (max-width: 600px) {
  .chapter__media--videos { flex-direction: column; align-items: center; gap: 40px; }
  .shot--video video { height: auto; width: 100%; max-height: 80vh; }
}
