.rbc-case-study {
  --case-warm: #f7efe4;
  --case-paper: #fffdf9;
  --case-ink: #203542;
  --case-muted: #655f59;
  color: var(--case-ink);
  background: var(--case-paper);
}

.rbc-case-study .wrap {
  width: min(calc(100% - 40px), 1200px);
  margin-inline: auto;
}

.rbc-case-study .breadcrumbs {
  padding-block: 18px 16px;
}

.rbc-case-study .breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  gap: 7px 9px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.rbc-case-study .breadcrumbs a {
  color: inherit;
  text-decoration: none;
}

.rbc-case-study .breadcrumbs a:hover {
  color: #74161b;
  text-decoration: underline;
}

.rbc-case-hero {
  padding: clamp(38px, 5vw, 76px) 0 clamp(50px, 6vw, 88px);
  overflow: hidden;
  background:
    radial-gradient(circle at 14% 0, rgba(179, 145, 84, .13), transparent 34%),
    linear-gradient(145deg, #fffdf9, var(--case-warm));
}

.rbc-case-hero__grid {
  display: grid;
  grid-template-columns: minmax(310px, .82fr) minmax(480px, 1.18fr);
  align-items: center;
  gap: clamp(34px, 6vw, 78px);
}

.rbc-case-hero__copy h1 {
  margin: 0 0 22px;
  color: var(--case-ink);
  font: 500 clamp(42px, 5vw, 68px)/1.04 var(--rbc-font-display, Georgia, serif);
  letter-spacing: -.045em;
  text-wrap: balance;
}

.rbc-case-study .eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 14px;
  color: #74161b;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.rbc-case-study .eyebrow::before {
  width: 28px;
  height: 1px;
  content: "";
  background: #b39154;
}

.rbc-case-hero__lead {
  max-width: 620px;
  margin: 0;
  color: var(--case-muted);
  font-size: clamp(17px, 1.5vw, 20px);
  line-height: 1.7;
}

.rbc-case-study .actions {
  display: flex;
  flex-wrap: wrap;
  gap: 11px;
  margin-top: 30px;
}

.rbc-case-study .button {
  min-height: 50px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 13px 21px;
  border: 1px solid transparent;
  border-radius: 3px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .07em;
  text-align: center;
  text-decoration: none;
  text-transform: uppercase;
}

.rbc-case-study .button-primary {
  color: #fff;
  background: linear-gradient(135deg, #8b242a, #571014);
}

.rbc-case-study .button-secondary {
  color: #74161b;
  border-color: #b39154;
  background: #fff;
}

.rbc-case-study :where(a, button):focus-visible {
  outline: 3px solid rgba(179, 145, 84, .65);
  outline-offset: 3px;
}

.rbc-case-hero__media {
  position: relative;
  margin: 0;
}

.rbc-case-hero__media::before {
  position: absolute;
  z-index: 0;
  inset: 18px -18px -18px 18px;
  content: "";
  border: 1px solid rgba(179, 145, 84, .48);
}

.rbc-case-hero__media img {
  position: relative;
  z-index: 1;
  width: 100%;
  height: auto;
  display: block;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  box-shadow: 0 28px 70px rgba(52, 34, 22, .18);
}

.rbc-case-facts {
  color: #fff;
  background: #571014;
}

.rbc-case-facts__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.rbc-case-facts__grid > div {
  min-height: 112px;
  display: grid;
  align-content: center;
  gap: 7px;
  padding: 24px;
  border-right: 1px solid rgba(255, 255, 255, .16);
}

.rbc-case-facts__grid > div:last-child {
  border-right: 0;
}

.rbc-case-facts span {
  color: #e5cda0;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.rbc-case-facts strong {
  color: #fff;
  font-size: 16px;
  line-height: 1.4;
}

.rbc-case-content {
  overflow: hidden;
}

.rbc-case-content > section {
  padding: clamp(58px, 7vw, 96px) 0;
}

.rbc-case-content > section:nth-child(even) {
  background: #faf5ee;
}

.rbc-case-split {
  width: min(calc(100% - 40px), 1200px);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(380px, 1.05fr);
  align-items: center;
  gap: clamp(34px, 6vw, 78px);
  margin-inline: auto;
}

.rbc-case-split.is-image-left .rbc-case-media {
  order: -1;
}

.rbc-case-copy {
  max-width: 610px;
}

.rbc-case-copy h2,
.rbc-case-gallery-head h2,
.rbc-case-outcome h2 {
  margin: 0 0 18px;
  color: var(--case-ink);
  font: 500 clamp(33px, 4vw, 50px)/1.1 var(--rbc-font-display, Georgia, serif);
  letter-spacing: -.035em;
  text-wrap: balance;
}

.rbc-case-copy p,
.rbc-case-gallery-head p,
.rbc-case-outcome p {
  margin: 0;
  color: var(--case-muted);
  font-size: 17px;
  line-height: 1.78;
}

.rbc-case-copy p + p,
.rbc-case-outcome p + p {
  margin-top: 18px;
}

.rbc-case-media {
  margin: 0;
}

.rbc-case-media img,
.rbc-case-gallery img {
  width: 100%;
  height: auto;
  display: block;
  background: #eee1d0;
  box-shadow: 0 18px 48px rgba(55, 39, 27, .14);
}

.rbc-case-media figcaption {
  margin-top: 12px;
  color: #746b64;
  font-size: 13px;
  line-height: 1.55;
}

.rbc-case-gallery-wrap,
.rbc-case-outcome {
  width: min(calc(100% - 40px), 1200px);
  margin-inline: auto;
}

.rbc-case-gallery-head {
  max-width: 780px;
  margin-bottom: 34px;
}

.rbc-case-gallery {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.rbc-case-gallery figure {
  margin: 0;
}

.rbc-case-gallery figure:first-child {
  grid-row: span 2;
}

.rbc-case-gallery figure:first-child img {
  height: 100%;
  object-fit: cover;
}

.rbc-case-gallery figcaption {
  margin-top: 10px;
  color: #746b64;
  font-size: 13px;
}

.rbc-case-outcome {
  max-width: 880px;
  padding-block: 6px;
  text-align: center;
}

.rbc-case-outcome .eyebrow {
  justify-content: center;
}

.rbc-case-outcome p {
  max-width: 800px;
  margin-inline: auto;
}

@media (max-width: 900px) {
  .rbc-case-hero__grid,
  .rbc-case-split {
    grid-template-columns: 1fr;
  }

  .rbc-case-hero__media,
  .rbc-case-split.is-image-left .rbc-case-media {
    order: 0;
  }

  .rbc-case-facts__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .rbc-case-facts__grid > div:nth-child(2) {
    border-right: 0;
  }

  .rbc-case-facts__grid > div:nth-child(-n + 2) {
    border-bottom: 1px solid rgba(255, 255, 255, .16);
  }
}

@media (max-width: 620px) {
  .rbc-case-study .wrap,
  .rbc-case-split,
  .rbc-case-gallery-wrap,
  .rbc-case-outcome {
    width: min(calc(100% - 28px), 1200px);
  }

  .rbc-case-hero {
    padding-top: 28px;
  }

  .rbc-case-hero__copy h1 {
    font-size: clamp(38px, 11vw, 50px);
  }

  .rbc-case-study .actions {
    display: grid;
  }

  .rbc-case-study .button {
    width: 100%;
  }

  .rbc-case-hero__media::before {
    inset: 9px -7px -7px 9px;
  }

  .rbc-case-facts__grid {
    grid-template-columns: 1fr;
  }

  .rbc-case-facts__grid > div,
  .rbc-case-facts__grid > div:nth-child(2) {
    min-height: 84px;
    padding: 18px 14px;
    border-right: 0;
    border-bottom: 1px solid rgba(255, 255, 255, .16);
  }

  .rbc-case-facts__grid > div:last-child {
    border-bottom: 0;
  }

  .rbc-case-gallery {
    grid-template-columns: 1fr;
  }

  .rbc-case-gallery figure:first-child {
    grid-row: auto;
  }

  .rbc-case-gallery figure:first-child img {
    height: auto;
  }
}


/* HUSARIA and Brzostek: display complete square hero photographs. */
body.postid-5464 .rbc-case-hero__media img,
body.postid-5468 .rbc-case-hero__media img {
  width: 100%;
  height: auto;
  aspect-ratio: auto;
  object-fit: contain;
  object-position: center;
}
