/* Drupal Asset Injector: CASE Study Index
 * Scope: exact path /case; selectors apply only inside .case-study-index.
 */
.case-study-index {
  width: 100%;
  max-width: 1536px;
  margin: 0 auto;
  padding: clamp(3.5rem, 7vw, 6.5rem) 1.5rem clamp(4.5rem, 8vw, 7rem);
  color: #243044;
}

.case-study-index-header {
  max-width: 900px;
  margin-bottom: clamp(2.5rem, 5vw, 4.5rem);
}

.case-study-index-eyebrow {
  margin: 0 0 .75rem;
  color: #087f76;
  font-size: .9rem;
  font-weight: 700;
  letter-spacing: .16em;
}

.case-study-index-header h2 {
  margin: 0 0 1.25rem;
  color: #172236;
  font-size: clamp(2.4rem, 5vw, 4.5rem);
  line-height: 1.15;
  letter-spacing: .02em;
}

.case-study-index-header > p:last-child {
  max-width: 760px;
  margin: 0;
  color: #536273;
  font-size: 1.05rem;
  line-height: 1.9;
}

.case-study-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.5rem;
}

.case-study-card {
  position: relative;
  display: flex;
  min-width: 0;
  min-height: 100%;
  flex-direction: column;
  padding: 2rem;
  overflow: hidden;
  border: 2px solid #cbdadd;
  border-top: 4px solid #0b9b8f;
  border-radius: .75rem;
  background: linear-gradient(145deg, #fff 0%, #f4f9fa 100%);
  box-shadow: 0 12px 28px rgba(23, 34, 54, .06);
  cursor: pointer;
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.case-study-card:hover {
  transform: translateY(-4px);
  border-color: #8fb9b7;
  border-top-color: #087f76;
  box-shadow: 0 18px 38px rgba(23, 34, 54, .11);
}

.case-study-card-number {
  margin: 0 0 1rem;
  color: #087f76;
  font-size: .82rem;
  font-weight: 700;
  letter-spacing: .14em;
}

.case-study-card h3 {
  min-height: 4.5em;
  margin: 0 0 1.4rem;
  color: #172236;
  font-size: clamp(1.25rem, 2vw, 1.55rem);
  line-height: 1.5;
}

.case-study-card h3 a {
  color: inherit;
  text-decoration: none;
}

.case-study-index a,
.case-study-index a:hover,
.case-study-index a:focus {
  text-decoration: none !important;
}

body:not(:has(form.layout-builder-form)) .case-study-card h3 a::after {
  position: absolute;
  inset: 0;
  content: "";
}

.case-study-card-results {
  display: grid;
  grid-template-columns: 1fr;
  margin: 0 0 1.35rem;
  padding: .35rem 0;
  border-top: 1px solid #cbdadd;
  border-bottom: 1px solid #cbdadd;
}

.case-study-card-result {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  min-width: 0;
  padding: .75rem 0;
  border-top: 1px solid #d9e4e6;
}

.case-study-card-result:first-child {
  border-top: 0;
}

.case-study-card-result strong,
.case-study-card-result span {
  display: block;
}

.case-study-card-result strong {
  order: 2;
  color: #087f76;
  font-size: 1.15rem;
  line-height: 1.25;
  letter-spacing: -.02em;
  white-space: nowrap;
}

.case-study-card-result span {
  order: 1;
  color: #687585;
  font-size: .8rem;
  line-height: 1.45;
}

.case-study-card-summary {
  margin: 0 0 1.5rem;
  color: #536273;
  font-size: .95rem;
  line-height: 1.8;
}

.case-study-card-action {
  margin: auto 0 0;
}

.case-study-card-action a {
  position: relative;
  z-index: 2;
  display: inline-flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  gap: .65rem;
  padding: .85rem 1rem;
  border: 2px solid #0b9b8f;
  border-radius: .4rem;
  background: #0b9b8f;
  color: #fff;
  font-size: .95rem;
  font-weight: 700;
  box-shadow: 0 7px 16px rgba(11, 155, 143, .18);
  text-decoration: none;
  transition: background-color .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.case-study-card-action a:hover,
.case-study-card-action a:focus {
  border-color: #087f76;
  background: #087f76;
  color: #fff;
  box-shadow: 0 10px 22px rgba(8, 127, 118, .26);
}

.case-study-card-action a span {
  transition: transform .2s ease;
}

.case-study-card:hover .case-study-card-action a span {
  transform: translateX(.3rem);
}

.case-study-card:focus-within {
  border-color: #087f76;
  outline: 3px solid rgba(11, 155, 143, .22);
  outline-offset: 3px;
}

@media (max-width: 720px) {
  .case-study-index {
    padding-right: 1.25rem;
    padding-left: 1.25rem;
  }

  .case-study-card-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .case-study-card {
    padding: 1.5rem;
  }

  .case-study-card h3 {
    min-height: 0;
  }
}
