body:has(.case-hero),
body:has(a.case-card) {
  background: #f5f7fb;
}

.case-hero {
  background:
    radial-gradient(36rem 16rem at 100% 0%, rgba(21, 161, 219, 0.14), transparent 60%),
    linear-gradient(180deg, #fff 0%, #f5f7fb 100%);
  border-bottom: 1px solid #e7eaf0;
}

.case-hero h1 {
  color: #0f2744;
  font-size: clamp(1.7rem, 2.3vw, 2.25rem);
  line-height: 1.2;
}

.case-hero-crumb {
  color: #6b7280;
  font-size: 0.875rem;
}

.case-hero-crumb a {
  color: #0066cc;
  text-decoration: none;
}

.case-hero-crumb a:hover {
  text-decoration: underline;
}

.case-lead {
  color: #4b5563;
  font-size: 1.02rem;
  line-height: 1.65;
}

.case-hero-visual {
  position: relative;
  margin: 0 0 1.75rem;
}

.case-hero-photo {
  display: block;
  width: 100%;
  height: 23rem;
  object-fit: cover;
  object-position: 62% center;
  border-radius: 0.25rem;
}

.case-hero-card {
  position: absolute;
  left: 6%;
  bottom: -1.6rem;
  width: 78%;
  height: auto;
  filter: drop-shadow(0 1rem 1.4rem rgba(15, 39, 68, 0.22));
}

.case-hero-visual--card {
  margin-bottom: 0;
}

.case-hero-visual--card .case-hero-card {
  position: static;
  width: 100%;
}

.case-topic {
  height: 100%;
  padding: 1.5rem 1.4rem 1.35rem;
  background: #fff;
  border: 0;
  border-radius: 0.7rem;
}

.case-topic p:last-child {
  line-height: 1.65;
}

.case-mosaic {
  display: grid;
  grid-template-columns: 1.15fr 1fr 0.72fr;
  grid-auto-rows: 18rem;
  gap: 1rem;
}

.case-mosaic figure {
  margin: 0;
  min-height: 14rem;
  overflow: hidden;
  border-radius: 1.15rem;
  background: #e7eef6;
}

.case-mosaic img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

a.case-card,
a.case-card:hover,
a.case-card:focus,
a.case-card:focus-visible {
  display: flex;
  flex-direction: column;
  height: 100%;
  background: #fff;
  border-radius: 0.5rem;
  overflow: hidden;
  color: inherit;
  text-decoration: none;
}

a.case-card:hover h2 {
  color: #0066cc;
  text-decoration: none;
}

a.case-card h2,
a.case-card p {
  text-decoration: none;
}

a.case-card figure.case-card-photo {
  position: relative;
  aspect-ratio: 16 / 10;
  width: 100%;
  height: auto;
  margin: 0;
  background: #e8eef6;
  overflow: hidden;
  border-radius: 0;
}

a.case-card figure.case-card-photo img {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  max-height: none;
  object-fit: cover;
  border-radius: 0;
}

.case-card-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: #0066cc;
  font-weight: 600;
  text-align: center;
}

.case-card-body {
  padding: 1.2rem 1.35rem 1.35rem;
}

.case-shot-wide { grid-column: 1 / 3; }
.case-shot-tall { grid-column: 3; grid-row: span 2; }

.case-result {
  padding: 2rem 2.1rem;
  background:
    radial-gradient(28rem 12rem at 100% 0%, rgba(21, 161, 219, 0.16), transparent 60%),
    #fff;
  border: 1px solid #e7eaf0;
  border-radius: 1.35rem;
}

.case-stat {
  margin: 0.2rem 0 0;
  color: #0066cc;
  font-size: clamp(2.4rem, 4vw, 3.4rem);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.03em;
}

.case-stat-label {
  margin: 0.35rem 0 1rem;
  color: #0f2744;
  font-weight: 600;
}

.case-checks {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.case-checks li {
  display: flex;
  gap: 0.85rem;
  align-items: flex-start;
  padding: 0.95rem 1rem;
  background: #f5f7fb;
  border-radius: 0.9rem;
  line-height: 1.5;
}

.case-checks i {
  flex-shrink: 0;
  margin-top: 0.15rem;
  color: #0066cc;
  font-size: 1.15rem;
}

.case-story {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 2rem 2.5rem;
  align-items: center;
}

.case-story--flip .case-copy { order: 2; }

.case-story--text {
  grid-template-columns: 1fr;
}

.case-story p {
  line-height: 1.7;
}

.case-visual {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 24rem;
  margin: 0;
  padding: 1.25rem;
  overflow: hidden;
  background:
    radial-gradient(18rem 10rem at 80% 20%, rgba(21, 161, 219, 0.16), transparent 70%),
    linear-gradient(180deg, #fff 0%, #eef5fb 100%);
  border: 1px solid #e7eaf0;
  border-radius: 1.25rem;
}

.case-visual img {
  display: block;
  width: 100%;
  max-height: 26rem;
  object-fit: contain;
}

.case-visual--plain {
  min-height: 0;
  padding: 0;
  background: none;
  border: 0;
  border-radius: 0;
}

@media (max-width: 991.98px) {
  .case-hero-photo {
    height: 16rem;
  }

  .case-hero-card {
    left: 8%;
    width: 72%;
    bottom: -1.1rem;
  }

  .case-hero-visual--card .case-hero-card {
    left: auto;
    bottom: auto;
    width: 100%;
  }

  .case-mosaic {
    grid-template-columns: 1fr 1fr;
    grid-auto-rows: 14rem;
  }

  .case-shot-wide { grid-column: 1 / -1; }
  .case-shot-tall { grid-column: auto; grid-row: auto; }
  .case-story { grid-template-columns: 1fr; }
  .case-story--flip .case-copy { order: 0; }

  .case-visual {
    min-height: 18rem;
  }
}

@media (max-width: 575.98px) {
  .case-mosaic {
    grid-template-columns: 1fr;
    grid-template-rows: none;
  }

  .case-mosaic figure {
    min-height: 14rem;
  }

  .case-shot-wide,
  .case-shot-tall {
    grid-column: auto;
  }
}
