/* Foster Place extends the studio's existing editorial language. */
.foster-case { --case-space: clamp(48px, 7vw, 100px); }
.foster-case h1, .foster-case h2, .foster-case h3, .foster-case p, .foster-case dl, .foster-case dd { margin: 0; }
.foster-case h1 { font: 650 clamp(2.5rem, 5.2vw, 5.25rem)/1.03 var(--sans); letter-spacing: -.035em; text-wrap: balance; }
.foster-case h2 { font: 400 clamp(2rem, 3.7vw, 3.5rem)/1.08 var(--serif); letter-spacing: -.025em; text-wrap: balance; }
.foster-case h3 { font: 650 1.125rem/1.3 var(--sans); }
.foster-case p { max-width: 65ch; }
.foster-case p + p { margin-top: 18px; }
.foster-case a { text-underline-offset: 5px; }
.foster-case__opening, .foster-case__chapter, .foster-case__close { padding-inline: max(var(--gutter), calc((100vw - var(--max)) / 2)); }
.foster-case__opening { padding-top: calc(var(--bar-h) + 24px); padding-bottom: 32px; background: var(--graphite); color: var(--on-dark); }
.foster-case__back { display: inline-flex; min-height: 44px; align-items: center; color: var(--on-dark); margin-bottom: 24px; }
.foster-case__hero { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.3fr); gap: clamp(24px, 4vw, 64px); align-items: center; }
.foster-case__hero > div { display: grid; gap: 24px; justify-items: start; }
.foster-case__thesis { font: 400 clamp(1.65rem, 2.4vw, 2.5rem)/1.12 var(--serif); }
.foster-case__hero .link-arrow { color: var(--on-dark); }
.foster-case__figure { margin: 0; min-width: 0; }
.foster-case__figure > a { display: block; }
.foster-case__figure img { display: block; width: 100%; height: auto; background: var(--paper-2); }
.foster-case__figure figcaption { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 0 16px; padding-top: 10px; font-size: .9375rem; color: var(--muted); }
.foster-case__figure figcaption a { display: inline-flex; min-height: 44px; align-items: center; color: inherit; flex-shrink: 0; }
.foster-case__figure figcaption strong { display: block; font-weight: 600; color: var(--ink-2); }
.foster-case__figure--apartment-detail figcaption,
.foster-case__figure--inquiry-detail figcaption { font-size: 1rem; }
.foster-case__opening figcaption { color: var(--on-dark-muted); }
.foster-case__scope { display: flex; flex-wrap: wrap; gap: 24px 64px; padding-top: 28px; margin-top: 36px !important; border-top: 1px solid var(--on-dark-muted); font-size: .9375rem; }
.foster-case__scope dt { color: var(--on-dark-muted); margin-bottom: 4px; }
.foster-case__chapter { padding-block: var(--case-space); scroll-margin-top: calc(var(--bar-h) + 24px); }
.foster-case__chapter--paper { background: var(--paper-2); }
.foster-case__intro { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 32px clamp(32px, 7vw, 110px); margin-bottom: 40px; }
.foster-case__comparison { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px; }
.foster-case__comparison h3 { margin-bottom: 20px; }
.foster-case__comparison .foster-case__figure > a { display: flex; align-items: center; aspect-ratio: 1521 / 633; background: var(--paper-2); }
.foster-case__comparison > div > p { margin-top: 12px; }
.foster-case__note { color: var(--muted); font-size: .9375rem; }
.foster-case__comparison + .foster-case__note { margin-top: 28px; }
.foster-case__photos { display: grid; grid-template-columns: minmax(0, .75fr) minmax(0, 1.25fr); align-items: center; gap: 40px clamp(32px, 5vw, 80px); }
.foster-case__photos h2 { margin-bottom: 24px; }
.foster-case__close { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr); gap: 32px 64px; align-items: center; padding-block: var(--case-space); }
.foster-case__close h2 { margin-bottom: 24px; }
.foster-case__actions { display: grid; gap: 24px; justify-items: start; justify-self: end; }
/* The closing bridge sentence sits in the narrow actions column; cap its line length so it wraps readably. */
.foster-case__bridge { max-width: 30rem; }
.foster-case .link-arrow { min-height: 44px; }
.foster-case :focus-visible { outline: 3px solid currentColor; outline-offset: 6px; }
@media (max-width: 860px) {
  .foster-case__hero, .foster-case__intro, .foster-case__comparison, .foster-case__photos, .foster-case__close { grid-template-columns: minmax(0, 1fr); }
  .foster-case__hero { gap: 32px; }
  .foster-case__hero > div { gap: 18px; }
  .foster-case__scope { gap: 20px 36px; margin-top: 24px !important; }
  .foster-case__intro { margin-bottom: 28px; gap: 24px; }
  .foster-case__comparison { gap: 40px; }
  .foster-case__actions { justify-self: start; }
}
/* Frame the relevant interface detail on phones; full-size links retain the complete captures. */
@media (max-width: 600px) {
  .foster-case__figure--apartment-detail > a,
  .foster-case__figure--inquiry-detail > a { position: relative; overflow: hidden; }
  .foster-case__figure--apartment-detail > a { aspect-ratio: 640 / 490; }
  .foster-case__figure--inquiry-detail > a { aspect-ratio: 720 / 235; }
  .foster-case__figure--apartment-detail img,
  .foster-case__figure--inquiry-detail img { position: absolute; max-width: none; }
  .foster-case__figure--apartment-detail img { width: 225%; left: -12.5%; top: -22.44898%; }
  .foster-case__figure--inquiry-detail img { width: 200%; left: -17.36111%; top: -117.02128%; }
}
