/* Checkivo-matching case study layout supplements */
.cv-case-page {
  background: #fff;
  padding-left: 1rem;
  padding-right: 1rem;
}

@media (min-width: 1024px) {
  .cv-case-page {
    padding-left: 1.5rem;
    padding-right: 1.5rem;
  }
}

.cv-case-page .pso-case-study-hero {
  margin-top: 5.5rem;
}

@media (min-width: 1024px) {
  .cv-case-page .pso-case-study-hero {
    margin-top: 4.5rem;
  }
}

/* Hero: stacked on mobile, 2-col on desktop (Checkivo case-study-hero) */
.cv-case-page .cv-case-hero-grid {
  display: grid;
  gap: 2rem;
  align-items: center;
  max-width: 1152px;
  margin: 0 auto;
  padding: 2rem 0 1rem;
}

@media (min-width: 1024px) {
  .cv-case-page .cv-case-hero-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
    gap: 3rem;
    padding: 3rem 0 1.5rem;
  }
}

/* Story: portrait sidebar + richtext */
.cv-case-page .cv-case-story-grid {
  display: grid;
  gap: 2.5rem;
  max-width: 1152px;
  margin: 0 auto;
  padding: 3.5rem 0;
}

@media (min-width: 1024px) {
  .cv-case-page .cv-case-story-grid {
    grid-template-columns: minmax(200px, 280px) minmax(0, 1fr);
    gap: 3.5rem;
    align-items: start;
  }
}

.cv-case-page .cv-case-counters-inner {
  display: grid;
  gap: 2rem;
  max-width: 1152px;
  margin: 0 auto;
  padding: 3rem 0;
  text-align: center;
}

@media (min-width: 900px) {
  .cv-case-page .cv-case-counters-inner {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 2.5rem;
  }
}

.cv-case-page .cv-case-results-grid {
  display: grid;
  gap: 2rem;
  max-width: 1152px;
  margin: 0 auto;
  padding: 3rem 0;
}

@media (min-width: 1024px) {
  .cv-case-page .cv-case-results-grid {
    grid-template-columns: minmax(200px, 280px) minmax(0, 1fr);
    gap: 3.5rem;
    align-items: start;
  }
}

.cv-case-page .cv-case-cta-grid {
  display: grid;
  gap: 2rem;
  max-width: 1152px;
  margin: 0 auto;
  padding: 1rem 0 4rem;
}

@media (min-width: 900px) {
  .cv-case-page .cv-case-cta-grid {
    grid-template-columns: 1.2fr 0.8fr;
    gap: 3rem;
    align-items: center;
  }
}

.cv-case-page .pso-case-study-hero .pso-image img,
.cv-case-page .pso-profile-picture .pso-image img,
.cv-case-page .cv-case-hero-media {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  display: block;
}

.cv-case-page .cv-case-hero-media-wrap {
  position: relative;
  min-height: 280px;
  height: 100%;
  overflow: hidden;
  border-radius: 0.75rem;
  background: #f3f3f4;
}

/* Absolutely fill the hero frame — no letterboxing / empty edges */
.cv-case-page .cv-case-hero-media-wrap > .cv-case-hero-media {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
}

@media (min-width: 768px) {
  .cv-case-page .cv-case-hero-media-wrap {
    min-height: 360px;
  }
}

@media (min-width: 1024px) {
  .cv-case-page .cv-case-hero-media-wrap {
    min-height: 480px;
  }
}

.cv-case-page .pso-profile-picture {
  margin: 0 auto 1.5rem;
  height: 215px;
  width: 155px;
  overflow: hidden;
  border-radius: 9999px;
}

@media (min-width: 768px) {
  .cv-case-page .pso-profile-picture {
    height: 275px;
    width: 200px;
  }
}

.cv-case-page .pso-profile-picture img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cv-case-page .cv-case-side-logo {
  max-width: 10rem;
  width: 100%;
  height: auto;
  margin: 1.25rem auto 0;
  display: block;
}

.cv-case-page .cv-case-quote-mark {
  color: #6b6b6b;
  display: block;
  text-align: left;
  font-size: 3rem;
  line-height: 1.4;
}

.cv-case-page .cv-case-pullquote {
  display: block;
  text-align: left;
  font-weight: 700;
  font-style: normal;
  font-size: 1.125rem;
  line-height: 1.4;
}

@media (min-width: 640px) {
  .cv-case-page .cv-case-pullquote {
    font-size: 1.25rem;
  }
}

@media (min-width: 1024px) {
  .cv-case-page .cv-case-pullquote {
    font-size: 1.5rem;
  }
}

.cv-case-page .cv-case-side-quote {
  color: #4b5563;
  text-align: left;
  font-size: 1.125rem;
  font-weight: 700;
  line-height: 1.4;
}

@media (min-width: 1024px) {
  .cv-case-page .cv-case-side-quote {
    font-size: 1.5rem;
    line-height: 1.2;
  }
}

/* Fallback if sm:text-5xl missing from purged CSS */
.cv-case-page .cv-case-hero-title {
  font-size: 1.875rem;
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: -0.02em;
}

@media (min-width: 640px) {
  .cv-case-page .cv-case-hero-title {
    font-size: 3rem;
  }
}

.cv-case-page .cv-case-section-title {
  font-size: 1.5rem;
  line-height: 1.2;
  font-weight: 700;
  margin-bottom: 1rem;
}

@media (min-width: 640px) {
  .cv-case-page .cv-case-section-title {
    font-size: 2.25rem;
    margin-bottom: 1.5rem;
  }
}

.cv-case-page .cv-case-prose p {
  margin-bottom: 2rem;
  font-size: 1.05rem;
  line-height: 1.65;
  color: #141414;
}

.cv-case-page .cv-case-prose p:last-child {
  margin-bottom: 0;
}

.cv-case-page .cv-case-counters {
  opacity: 1 !important;
}

.cv-case-page .cv-case-counter-value {
  font-size: 1.875rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 0.5rem;
}

@media (min-width: 768px) {
  .cv-case-page .cv-case-counter-value {
    font-size: 2.25rem;
  }
}

@media (min-width: 1024px) {
  .cv-case-page .cv-case-counter-value {
    font-size: 3rem;
  }
}

.cv-case-page .cv-case-cta {
  border-radius: 1rem;
  background: #f7f7f8;
  padding: 2rem 1.5rem;
}

@media (min-width: 1024px) {
  .cv-case-page .cv-case-cta {
    padding: 2.5rem;
  }
}

.cv-case-page .cv-case-cta-list {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0 0;
}

.cv-case-page .cv-case-cta-list li {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin: 1rem 0;
  font-size: 1.05rem;
  line-height: 1.5;
}

.cv-case-page .cv-case-cta-list svg {
  flex-shrink: 0;
  margin-top: 0.15rem;
}

.cv-case-page .cv-case-cta-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 1.5rem;
  padding: 0.9rem 1.4rem;
  border-radius: 0.5rem;
  background: #141414;
  color: #fff !important;
  font-weight: 600;
  text-decoration: none !important;
}

.cv-case-page .cv-case-cta-btn:hover {
  background: #2a2a2a;
}

.cv-case-page .cv-case-back {
  display: inline-block;
  margin-bottom: 1.25rem;
  color: #141414;
  font-weight: 600;
  text-decoration: none;
}

.cv-case-page .cv-case-back:hover {
  text-decoration: underline;
}


/* Case hero: two images, fill full media column (no empty bottom) */
.cv-case-page .cv-case-hero-grid {
  align-items: stretch;
}
.cv-case-page .cv-case-hero-media-wrap--duo {
  display: grid;
  grid-template-rows: 1fr 1fr;
  gap: 0.55rem;
  min-height: 280px;
  height: 100%;
  background: transparent;
}
.cv-case-page .cv-case-hero-media-wrap--duo .cv-case-hero-media {
  width: 100%;
  height: 100%;
  min-height: 140px;
  object-fit: cover;
  object-position: center;
  border-radius: 0.65rem;
  display: block;
}
@media (min-width: 768px) {
  .cv-case-page .cv-case-hero-media-wrap--duo {
    min-height: 420px;
  }
}
@media (min-width: 1024px) {
  .cv-case-page .cv-case-hero-media-wrap--duo {
    min-height: 520px;
  }
}

/* Story column: second product photo under portrait */
.cv-case-page .cv-case-side-photo {
  margin-top: 1.5rem;
  width: 100%;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border-radius: 0.75rem;
  background: #f3f3f4;
}
.cv-case-page .cv-case-side-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}


/* Side product photo: fill frame edge-to-edge (no empty bottom) */
.cv-case-page .pso-card-portrait {
  display: flex;
  flex-direction: column;
  align-items: center;
  height: 100%;
}
.cv-case-page .cv-case-side-photo--fill {
  aspect-ratio: auto;
  align-self: stretch;
  flex: 1 1 auto;
  min-height: 260px;
  margin-top: 1.25rem;
  background: #0f0f10;
}
.cv-case-page .cv-case-side-photo--fill img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 28%;
  display: block;
}
